I am trying to query the Twitter Search API for either a user, several users, a hashtag, several hashtags, or any combo of them. I am struggling with the syntax.
Multiple users (WORKS)
?q=from:user1 OR from:user2 OR from user3
Single hashtag (WORKS)
?q=with:#hashtag
Combo (BROKEN)
?q=from:user1 OR from:user2 OR with:#hash1 OR with:hash2
//returns most recent tweets and ignores my query altogether. No error
I do not want to query a specific hashtag from a specific user. I want either/or results. If I use the following syntax, it works, but it also searches the contents of the tweet, as opposed to just the hashtag, which is not as nice.
Contains search (WORKS)
?q=from:user1 OR hashtag1 OR hashtag2
Is there any way to accomplish what I am looking for or no? I have also tried the following
(BROKEN)
?q=from:user1 OR from:user2 OR with:hash1 OR hash2 OR hash3
Hope this make sense. I can clarify further if needed. (Note: I am using since_id and max_id in my actual environment, as well as rpp, but for the ease of this question, I left them out of my examples.)