Created
March 20, 2014 23:26
-
-
Save stefanbuck/9676259 to your computer and use it in GitHub Desktop.
Get twitter favs with request in node.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var oauth = { | |
consumer_key: config.twitter.clientID, | |
consumer_secret: config.twitter.clientSecret, | |
token: twitterUser.token, | |
token_secret: twitterUser.tokenSecret | |
}; | |
var params = { | |
user_id: twitterUser.id, | |
count: 200 | |
} | |
request({ | |
oauth: oauth, | |
url: 'https://api.twitter.com/1.1/favorites/list.json?' + qs.stringify(params) | |
}, function (err, request, body) { | |
res.jsonp(body); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment