Hello, I am trying to get retweets with the v1 search_tweets endpoint. With the geocode parameter enabled, i am Not getting retweets. Without geocode, I am getting retweets. Are retweets disabled for this endpoint with geocode enabled ? Is there a v2 endpoint with geocode and retweets ? Heres a quick look at my code. Thanks for your time!
My understanding is that not all tweets have a geo, so if you can’t find anything with a geo, it’s possible that no one has a geo.
document says
Geolocalization: the search operator “near” isn’t available in the API, but there is a more precise way to restrict your query by a given location using the geocode parameter specified with the template “latitude,longitude,radius”, for example, “37.781157,-122.398720,1mi”. When conducting geo searches, the search API will first attempt to find Tweets which have lat/long within the queried geocode, and in case of not having success, it will attempt to find Tweets created by users whose profile location can be reverse geocoded into a lat/long within the queried geocode, meaning that is possible to receive Tweets which do not include lat/long information.
in v2 geo operator belongs to the advanced category and that only available in Academic Research access
https://developer.twitter.com/en/docs/twitter-api/tweets/search/integrate/build-a-query
1 Like
For v1.1 Premium Search: Operators by product | Docs | Twitter Developer Platform
Note: operators matching on place (Tweet geo) will only include matches from original tweets. Retweets do not contain any place data.
Your code is using tweepy.API — Twitter API v1.1 Reference — tweepy 4.5.0 documentation which is not premium, it’s calling Standard search API | Docs | Twitter Developer Platform (but this also has the same thing - it won’t return retweets for geo searches)
1 Like
system
closed
#4
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.