tags:

views:

273

answers:

2
+1  Q: 

Twitter API from

I have created a page on my site where users can post directly to their twitter accounts using a form on my site. I am using curl to send the data. However, when they post something it says it was posted "from API" I would like to change that to my sitename/link. I read something about doing it through OAUTH but I do not want my users to have to leave my site and go to twitter. I just want to show my site there. Any help is appreciated.

+1  A: 

This link might help you a bit http://www.sakana.fr/blog/2007/03/18/scripting-twitter-with-curl/

And for changing the client shown, pass the source variable, something like this should work:

curl --basic --user username:password --data status="Having fun with cURL" http://twitter.com/statuses/update.xml?source=MySuperClient
Lonecat
I think you meant source variable in the query string?
spoon16
I tried passing the source with the request but now instead of saying from API it says from web. Any ideas?
ngreenwood6
If you check out the "More Information" in my answer, you will see that twitter no longer allows custom client names without Oauth, and you have to register a custom name anyways.
kersny
@spoon16 yeah I meant source
Lonecat
+2  A: 

You are going to have to use Oauth, the original method was discontinued. Before that, though, you have to register your application here: New Client.

More information: Here

kersny
obviously you cant read since I said I dont want to use oauth because I dont want users to have to leave my site.
ngreenwood6
I dont know how to implement oauth to make it so users dont have to leave my site.
ngreenwood6
Unfortunatly, Oauth is your only choice if you want a custom name.
kersny