Question about querying tweets based on date


#1

For a project that I’m working on I need to query only the most recent tweets. I saw in this topic -> How to get tweets for specific date duration? but when looking on the twitter search api documentation I can’t find information about the “since” parameter. It doesn’t work when I try top add the “since” parameter to my requests so I’m thinking it may be deprecated? If someone could point me in the right direction that would be great.


#2

Can you give more details around what you’re trying to do, how you’re trying to do it and what’s wrong with what’s happening?

An example of the API call you’re making, or just the parameter values you’re passing in, and some explanation of “doesn’t work” would help us help you.


#3

Here is my code for adding the “since” and “until” parameters to the request. I’m using twitter’s hbc java library’s.

StatusesFilterEndpoint endpoint = new StatusesFilterEndpoint();
endpoint.addQueryParameter(“since”, “10-10-2014”);
endpoint.addQueryParameter(“until”, “10-29-2014”);

What I mean by when I say the request doesn’t work is that the request goes through and I receive tweets, it’s just that I get tweets that were created at random times, not ones that were created in the time I specified in my request. I’m not receiving any error codes from their server so it seems like their server is just ignoring these parameters. I want to be able to query for the most recently created tweets and it seems like this is the only way to do so.

Thanks


#4

The problem is that since and until parameters don’t wotk with the statuses/filter endpoint.

To get tweets in the future use the statuses/filter endpoint. To get tweets in the recent past use the search/tweets endpoint with since and until parameters.


#5