v1
latestSwagger 2.02026-07-13153383.1 KB/1.0/search/cities
Search for a city.
Search for a city.
get/1.0/search/cities
Query parameters
countrystring
the city's country
namestring
name of the city
pinteger
the number of the result page you'd like to have
statestring
state the city lies in
stateCodestring
state code the city lies in
Response
Success
Example response
{
"cities": [
{
"id": "5357527",
"name": "Hollywood",
"stateCode": "CA",
"state": "California",
"coords": {
"long": -118.3267434,
"lat": 34.0983425
},
"country": {
"code": "US",
"name": "United States"
}
},
{
"id": "...",
"name": "...",
"stateCode": "...",
"state": "...",
"coords": {
"long": 12345,
"lat": 12345
},
"country": {
"code": "...",
"name": "..."
}
}
],
"total": 42,
"page": 1,
"itemsPerPage": 20
}