Skip to content

Commit

Permalink
Updated the twitter oauth dance. The comments weren't clear. Also rem…
Browse files Browse the repository at this point in the history
…oved token_key. No longer needed with twitter oauth.
  • Loading branch information
joemccann committed Aug 28, 2012
1 parent 07135d5 commit ed68b8d
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,13 +106,16 @@ var qs = require('querystring')
, url = 'https://api.twitter.com/oauth/request_token'
;
request.post({url:url, oauth:oauth}, function (e, r, body) {
// Assume by some stretch of magic you aquired the verifier
// Ideally, you would take the body in the response
// and construct a URL that a user clicks on (like a sign in button).
// The verifier is only available in the response after a user has
// verified with twitter that they are authorizing your app.
var access_token = qs.parse(body)
, oauth =
{ consumer_key: CONSUMER_KEY
, consumer_secret: CONSUMER_SECRET
, token: access_token.oauth_token
, verifier: VERIFIER
, verifier: access_token.oauth_verifier
, token_secret: access_token.oauth_token_secret
}
, url = 'https://api.twitter.com/oauth/access_token'
Expand Down

0 comments on commit ed68b8d

Please sign in to comment.