Redirect 401 Error using php Oauth Extension



I’m starting to build an OAuth Client via the php OAuth Extension provided via pecl.
While going on the example twitter Fetchtimeline from the redirect URL in my apps directs to my local machine.
after login in my twitter account the fetch timeline.php throws an Exception telling me: Invalid auth/bad request (got a 401, expected HTTP/1.1 20X or a redirect)

How do i get the example working?


I don’t know much about that particular OAuth library, but if you managed to get to the redirect step and everything was still working, then you’re likely mostly in good shape. Do you know much about how your OAuth library works? When fetching your timeline, are you using an access token? Do you know how to get more information from the 401 exception? Errors from the Twitter API contain messages that accompany the numerical code and those messages are very helpful when debugging cases like this.