You should reformat your request from: $connection->get("user_timeline/{$username}.json?count={$number}");
to: $connection->get("statuses/user_timeline", array("screen_name" => $username, "count" => $number)); TwitterOAuth automatically adds the type. Abraham ------------- Abraham Williams | Hacker Advocate | http://abrah.am @abraham | http://projects.abrah.am | http://blog.abrah.am This email is: [ ] shareable [x] ask first [ ] private. On Wed, Aug 11, 2010 at 13:49, lucaswxp <lucas....@gmail.com> wrote: > Hello o/ > Into now, I have caught my latest tweets that way: > > file_get_contents("http://twitter.com/statuses/user_timeline/ > {$username}.json?count={$number}"); > > Actually, I used cURL, but I put that way to simplify the code. > > Well, with this new OAuth thing, I'm lost. > I'm triyng to use the TwitterOAuth Lib (http://github.com/abraham/ > twitteroauth), but, I'll have to sign in every time to autenthicate > myself? I don't understand very well... > > See, I know that I need: > $connection = new TwitterOAuth(MY_CONSUMER_KEY, MY_CONSUMER_SECRET, > $_SESSION['oauth_token'], > $_SESSION['oauth_token_secret']); > > $connection->get("user_timeline/{$username}.json?count={$number}"); > > But... I don't know where I get the "oauth_token" and > "oauth_token_secret" (it's necessary for what I want?). > I'll need all this just to get my latest tweets? > Help, pls! > (srry for the bad english)