I am using twitter stream API with Javascript in order to collect tweets. The problem is that I am not using the extended mode and I don’t get the full tweet when it is greater than 140 characters. I have searched info and I discovered that I need to pass tweet_mode=extended in the request and the response will contain a full_text which is the tweet complete. The problem is that I don’t know where to write tweet_mode=extended. This is my code:
twitter.stream('statuses/filter', {track: word, function (stream) {
stream.on('data', function (tweet) {
console.log(tweet.text)
});
stream.on('error', function (error) {
console.log("error:", error);
})
})
2
Answers
Unfortunately the streaming API does not have the option to add the tweet_mode param
Documentation here: https://developer.twitter.com/en/docs/tweets/tweet-updates
This paragraph is of note to your concern:
As Van said, tweets in streaming API are mixed. So you can try this :