scraperwiki / twitter-search-tool

ScraperWiki tool to get Tweets matching a search term; tool now defunct, though the code is here for reference.
https://blog.scraperwiki.com/2014/08/the-story-of-getting-twitter-data-and-its-missing-middle/
Other
9 stars 7 forks source link

Search for tweets in a location #17

Closed zarino closed 10 years ago

zarino commented 11 years ago

When I use the near: search operator (documented here and linked to from the tool), I get an error…

details: {"errors":[{"code":44,"message":"near parameter is invalid"}]}.

This is because, hidden away on this page, Twitter warns us:

The near operator cannot be used by the Search API. Instead you should use the geocode parameter.

The "geocode parameter" is a whole new GET parameter, separate from the search string, which means there's no way for me to enter it using the 'Search for Tweets' search box.

The URL the tool needs to call is something like:

http://twitter.com/search?q=scraperwiki&geocode=37.78,-122.39,25mi
frabcus commented 10 years ago

This user https://app.intercom.io/apps/63b0c6d4bb5f0867b6e93b0be9b569fb3a7ab1e3/conversations/363051460 wants geocoding based on the location of the user.

This is so she can get only Tweets that are by a person from a particular country.

frabcus commented 10 years ago

I think we could use this API to let people choose the region by typing a name: https://dev.twitter.com/docs/api/1.1/get/geo/search

Then the geocode parameter on this to implement. https://dev.twitter.com/docs/api/1.1/get/search/tweets

frabcus commented 10 years ago

This is covered really by the timezone for now.