1
votes

Twitter API 1.0 doesn't need an access token. The following line returns a XML file: https://api.twitter.com/1/statuses/user_timeline.xml?screen_name=neodev2010

Result: Valid XML

Cause API 1.0 is deprecated we need to switch to API 1.1: https://api.twitter.com/1.1/statuses/user_timeline.xml?screen_name=neodev2010

Result: Error: Bad Authentication data

I just found examples for API 1.1 based on large PHP classes. How is it possible to authentication via GET parameters?

Which parameters are missing to get a valid response?

  • access_token=123
  • access_secret=345
  • oauth_access_token=678
  • oauth_access_token_secret=910
  • consumer_key=234
2

2 Answers

1
votes

You can't authenticate to Twitter via a simple GET request. You need to use their OAuth system which involves passing a few pieces of information back and forth.

I strongly advise you to find a script or a library where someone has already implemented OAuth and build your application on that. OAuth is not easy to implement, and there's no reason to write new OAuth implementations when there are so many available for free.

1
votes

REST API 1.1 only support 'json' format of output.

SO use following endpoint along with your authentication data

https://api.twitter.com/1.1/statuses/user_timeline.json?screen_name=neodev2010