rubytwittertweetstream

TweetStream.track multiple keyword at once


I'm working with TweetStream gem in ruby and would like to know if there is a way to use

TweetStream::Client.new.track('key1', 'key2')

And track tweets with only BOTH keywords in them? The normal use tracks Tweets with either one in them.


Solution

  • According to Twitter Stream Api docs, you have to send a single search phrase (your 2 terms, separated by space):

    TweetStream::Client.new.track('key1 key2')