This Choreo Searches for places that can be attached to a statuses/update using a latitude and a longitude pair, an IP address, or a name. The documentation for this Twitter resource can be found here.
Here's an example of acceptable inputs:
ConsumerKey: {YOUR CONSUMER KEY}
ConsumerSecret {YOUR CONSUMER SECRET}
AccessToken: {YOUR ACCESS TOKEN}
AccessTokenSecret: {YOUR TOKEN SECRET}
Query: Toronto
The following is a sample of the JSON information returned by this Choreo:
{
"query": {
"params": {
"accuracy": 0,
"autocomplete": false,
"granularity": "neighborhood",
"query": "Toronto",
"trim_place": false
},
"type": "search",
"url": "https://api.twitter.com/1.1/geo/search.json?accuracy=0&query=Toronto&granularity=neighborhood&autocomplete=false&trim_place=false"
},
"result": {
"places": [
{
"attributes": {},
"bounding_box": {
"coordinates": [
[
[
-96.647415,
44.566715
],
[
-96.630435,
44.566715
],
[
-96.630435,
44.578118
],
[
-96.647415,
44.578118
]
]
],
"type": "Polygon"
},
"contained_within": [
{
"attributes": {},
"bounding_box": {
"coordinates": [
[
[
-104.057739,
42.479686
],
[
-96.436472,
42.479686
],
[
-96.436472,
45.945716
],
[
-104.057739,
45.945716
]
]
],
"type": "Polygon"
},
"country": "United States",
"country_code": "US",
"full_name": "South Dakota, US",
"id": "d06e595eb3733f42",
"name": "South Dakota",
"place_type": "admin",
"url": "https://api.twitter.com/1.1/geo/id/d06e595eb3733f42.json"
}
],
"country": "United States",
"country_code": "US",
"full_name": "Toronto, SD",
"id": "3e8542a1e9f82870",
"name": "Toronto",
"place_type": "city",
"url": "https://api.twitter.com/1.1/geo/id/3e8542a1e9f82870.json"
},
{
"attributes": {},
"bounding_box": {
"coordinates": [
[
[
-80.622815,
40.436469
],
[
-80.596567,
40.436469
],
[
-80.596567,
40.482566
],
[
-80.622815,
40.482566
]
]
],
"type": "Polygon"
},
"contained_within": [
{
"attributes": {},
"bounding_box": {
"coordinates": [
[
[
-84.820305,
38.403423
],
[
-80.518454,
38.403423
],
[
-80.518454,
42.327132
],
[
-84.820305,
42.327132
]
]
],
"type": "Polygon"
},
"country": "United States",
"country_code": "US",
"full_name": "Ohio, US",
"id": "de599025180e2ee7",
"name": "Ohio",
"place_type": "admin",
"url": "https://api.twitter.com/1.1/geo/id/de599025180e2ee7.json"
}
],
"country": "United States",
"country_code": "US",
"full_name": "Toronto, OH",
"id": "53d949149e8cd438",
"name": "Toronto",
"place_type": "city",
"url": "https://api.twitter.com/1.1/geo/id/53d949149e8cd438.json"
},
{
"attributes": {},
"bounding_box": {
"coordinates": [
[
[
-79.639128,
43.403221
],
[
-78.90582,
43.403221
],
[
-78.90582,
43.855466
],
[
-79.639128,
43.855466
]
]
],
"type": "Polygon"
},
"contained_within": [
{
"attributes": {},
"bounding_box": {
"coordinates": [
[
[
-95.155919,
41.676329
],
[
-74.339383,
41.676329
],
[
-74.339383,
56.852398
],
[
-95.155919,
56.852398
]
]
],
"type": "Polygon"
},
"country": "Canada",
"country_code": "CA",
"full_name": "Ontario, Canada",
"id": "89b2eb8b2b9847f7",
"name": "Ontario",
"place_type": "admin",
"url": "https://api.twitter.com/1.1/geo/id/89b2eb8b2b9847f7.json"
}
],
"country": "Canada",
"country_code": "CA",
"full_name": "Toronto, Ontario",
"id": "8f9664a8ccd89e5c",
"name": "Toronto",
"place_type": "city",
"url": "https://api.twitter.com/1.1/geo/id/8f9664a8ccd89e5c.json"
},
{
"attributes": {},
"bounding_box": {
"coordinates": [
[
[
-90.867234,
41.898723
],
[
-90.859467,
41.898723
],
[
-90.859467,
41.906811
],
[
-90.867234,
41.906811
]
]
],
"type": "Polygon"
},
"contained_within": [
{
"attributes": {},
"bounding_box": {
"coordinates": [
[
[
-96.639485,
40.375437
],
[
-90.140061,
40.375437
],
[
-90.140061,
43.501196
],
[
-96.639485,
43.501196
]
]
],
"type": "Polygon"
},
"country": "United States",
"country_code": "US",
"full_name": "Iowa, US",
"id": "3cd4c18d3615bbc9",
"name": "Iowa",
"place_type": "admin",
"url": "https://api.twitter.com/1.1/geo/id/3cd4c18d3615bbc9.json"
}
],
"country": "United States",
"country_code": "US",
"full_name": "Toronto, IA",
"id": "173d6f9c3249b4fd",
"name": "Toronto",
"place_type": "city",
"url": "https://api.twitter.com/1.1/geo/id/173d6f9c3249b4fd.json"
},
{
"attributes": {},
"bounding_box": {
"coordinates": [
[
[
-95.956873,
37.792724
],
[
-95.941288,
37.792724
],
[
-95.941288,
37.803752
],
[
-95.956873,
37.803752
]
]
],
"type": "Polygon"
},
"contained_within": [
{
"attributes": {},
"bounding_box": {
"coordinates": [
[
[
-102.051769,
36.993016
],
[
-94.588387,
36.993016
],
[
-94.588387,
40.003166
],
[
-102.051769,
40.003166
]
]
],
"type": "Polygon"
},
"country": "United States",
"country_code": "US",
"full_name": "Kansas, US",
"id": "27c45d804c777999",
"name": "Kansas",
"place_type": "admin",
"url": "https://api.twitter.com/1.1/geo/id/27c45d804c777999.json"
}
],
"country": "United States",
"country_code": "US",
"full_name": "Toronto, KS",
"id": "b90e4628bff4ad82",
"name": "Toronto",
"place_type": "city",
"url": "https://api.twitter.com/1.1/geo/id/b90e4628bff4ad82.json"
}
]
}
}