Country/location based data in twitter


i am fetching data from twitter and wants to put a geo-location filter while fetching the data.
country_code = ["US","IN"]
and location =["us"] but no luck
please help.

Thanks in advance

How do you fetch the data from twitter?
Using input plugin?

If you are using the twitter input plugin try this:

input {
twitter {
----your options
full_tweet => true
ignore_retweets => false
use_samples => false
languages => ["us"]

locations => "100,100"

locations edit

  • Value type is string
  • There is no default value for this setting.

A comma-separated list of longitude, latitude pairs specifying a set of bounding boxes to filter tweets by. See for more details.

you would have to handle it in a json filtering I guess going after the
"country": "Sweden",
"countryCode": "SE",
"name": "Sweden",
"parentid": 1,
"placeType": {
"code": 12,
"name": "Country"
"url": "",
"woeid": 23424954

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.