views:

12

answers:

1

I'm experimenting with this method "users lookup" from the Twitter API. Is there any way I can directly type the url in the browser and see the results? I am logged into Twitter, but I get the error message "basic authentication is not supported" when I type http://api.twitter.com/1/users/lookup.xml?user_id=12863272,3191321,9160152,8285392 (this is from their documentation page). What do I need to do to experiment with the API?

A: 
Time Machine
curl with copy-pasting? How?
You need to copy and paste the OAuth tokens.
Time Machine
Or even better: http://dev.twitter.com/console :D
Time Machine
I didn't understand. I am using a script/cron job to get my data, so console wouldn't be useful to me. Is there any way to pass OAuth tokens in the URL?
If using a script, simply install Twurl (option 3) and use Twurl. It's that simple.
Time Machine
is there no way to not depend on external tools? I mean, is there any way to do the authentication from my script itself?
Shell Script? Nopes, you need either cUrl or Twurl.
Time Machine
ok, with CURL and PHP, is there any way to do it without depending on external tools?
Yes. Use cUrl...
Time Machine
if I do curl http://api.twitter.com/1/users/lookup.xml?user_id=12863272,3191321,9160152,8285392, I get an authentication error
You first need to authenticate. http://dev.twitter.com/pages/auth
Time Machine
Basic authentication which you are using is not available anymore.
Time Machine
I didn't understand fully how I should use curl with oauth, I'll read through the oauth tutorial at twitter. thank you for your help.
okay, I found the library - http://github.com/abraham/twitteroauth