You probably already solved your problem, but for someone else who is struggling with this, here is my solution:
var Twit = require('twit'); var T = new Twit({ consumer_key: '' , consumer_secret: '' , access_token: '' , access_token_secret: '' }) var options = { screen_name: 'sandagolcea', count: 3 }; T.get('statuses/user_timeline', options , function(err, data) { for (var i = 0; i < data.length ; i++) { console.log(data[i].text); } })
This shows my last 3 tweets :) Hooray!
Sanda source share