Geocoding API

Geocoding API helps find the location coordinates of a known address, place, locality or administrative area, even if the query is incomplete or partly incorrect. It returns the complete postal address of the searched place along with relevant details.

Geocoding API is normally used in business workflows (likely machine-to-machine interactions) for handling full, incomplete, or unformatted addresses, and typos. For human-to-machine interaction - places/POIs search for both known or unknown places or for listing best known matches while the user is typing a query (letter-by-letter typing), use Discover, Browse or Autocomplete APIs for optimal results.

To make a Geocoding request use the following endpoint:

GET

https://api.nextbillion.io/orbis/geocode?key={your_api_key}&q={search_query}

Request Parameters

Loading..

Response Body

Loading..

Sample Request

The following query geocodes an address in Massachusetts, Boston.

1
curl --location 'https://api.nextbillion.io/orbis/geocode?key=<your_api_key>&in=circle:42.3148375,-71.0353054;r=100&q=Columbia Point, Dorchester&in=countryCode:USA&lang=en-US&'

Sample Response

1
{
2
"items": [...]
3
}

API Query Limits

  • NextBillion.ai allows a maximum rate limit of 2400 queries per minute or 40 queries/second for continuous requests.

API Error Codes

Response CodeDescriptionAdditional Notes
200

Normal success case.

Normal success case.

400

Input validation failed.

There is a missing or an invalid parameter or a parameter with an invalid value type is added to the request.

401

APIKEY not supplied or invalid.

This error occurs when the wrong API key is passed in the request or the key is missing altogether.

403

APIKEY is valid but does not have access to requested resources.

You might be querying for a geographical region which is not valid for your account or requesting a service which is not enabled for you.

404

Requested host/path not found.

This error occurs when a malformed hostname is used.

422

Could not process the request.

The request could not be completed for the given set of locations or parameter configuration.

429

Too many requests.

QPM reached or API request count quota reached.

500

Internal Service error.

There was an internal issue with NextBillion.ai services. You can reach out to support@nextbillion.ai for an explanation.