Find a location code
find_locationLooks up the numeric location code a place has, instead of guessing one. Countries are the markets keyword, domain and backlink tools take as locationCode; with countryCode, cities and regions of that country are looked up too, for search results and rank trackers. A misspelled name returns the nearest names. Free: it reads the saved location lists and never fetches anything; a country whose city list is not saved yet says so.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"query": "<query>"
},
"name": "find_location"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | A country, city or region name, such as 'Belgium' or 'Antwerp'. | |
| countryCode | No | Two-letter country code, such as 'be', to look up cities and regions in that country too. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| exact | Yes | ||
| places | Yes | ||
| countries | Yes | ||
| placesSaved | Yes |