You can tune the request by providing geo parameters like an ISO ZIP code, subdivision, and country code, and by city.
Key | Value | Examples |
---|---|---|
country | A two-letter country code (these codes are case insensitive) | US, GB |
subdivision | The alphanumeric second part (proceeding the separator) of a first-level subdivision code in the (prerequisite) country (case insensitive) | CA, LND |
city | A commonly spelled city name (temporarily case sensitive and inclusive of URL-encoded spaces and punctuation marks) in the (prerequisite) country. We always use the English (en) variant of the city name, which can be verified on GeoNames (as referenced in MaxMind’s documentation). | New York, London |
zipcode | A postal code. Please take a look at the limitations below. | 10001, OX2 |
country
key must always persist if any of the geo parameters is specified. Otherwise, HTTP 400 is returned.zipcode
: if specified, city
key is ignored.