Create a Key
Sign up for an Ideal Postcodes account. Accounts and API keys are free. Once signed in, you may create keys via your dashboard and use them to query for addressing data.
Implement & Test
All keys are instantly usable on our API with test requests. We provide a wide range of test methods to allow you to develop a rigorous and correct implementation. Test requests do not affect your lookup balance.
To take your key live and query genuine addressing data, you will need to purchase a lookup balance for your key. Requests that retrieve addressing data (i.e. using the
/postcodes API) will deduct one lookup from your balance. You can also setup automated top-ups to reload your balance when it runs low.
- Retrieve addresses for a postcode
- Search for an address
- Quickly integrate postcode lookups on a web form
- Retrieve postcodes for a geolocation
- Find out the current state of a key
- Retrieve usage history for a key
All API methods are either a GET, POST or OPTIONS request.
The API communicates over both HTTPS and plain HTTP using IPv4 and IPv6. Please use HTTPS whenever possible.
We use appropriate HTTP status codes where possible to indicate the request status.
All responses are returned in JSON.
Most requests require an API key for authentication. Authenticate by passing an
api_key as part of the query string.
Alternatively, query string authentication can be return in the
Authorization header using the following scheme,
Authorization: IDEALPOSTCODES api_key="iddqd" [other_key="foo"]
This API is versioned with a simple prefix in the URL. The current version is
/v1/. We will maintain backwards-compatibility by releasing breaking changes under a new version.
Please note that we consider the following changes backwards-compatible:
- Adding new properties to existing API responses
- Adding new API endpoints
- Adding new optional request parameters to existing API endpoints
- Changing the order of properties in existing API responses
A successful lookup is accompanied with a HTTP status code of 200 and a response code of 2000 (found in the body).
An error has occurred if the HTTP status code is not 200. Errors can range from the a benign 404 (resource not found) to more urgent errors (your API Key ran out of credit, failed authentication, etc).
Note that JSONP requests respond with a HTTP status code of 200 as all other responses are ignored by most browsers.
Each method has a simple testing procedure available which does not affect your account balance. You can find these methods here.
JSONP requests are supported. Simply include a
callback= in your request as a query parameter and your result will be returned wrapped in a function designated by your request.
Requests that affect your balance may be annotated with arbitrary metadata. This data is stored along with your lookup history and can be queried at a later date via the API or the dashboard. We call the ability to label your requests tagging.
Each IP address is rate limited at 10 requests per second for version 1 of the API. Tripping the rate limit will result in a 503 response.
If you expect to breach the limit please contact us and we can move you to an endpoint with a higher limit.
Our documentation and demos make heavy use of our community key
iddqd, which allows convenient access for trialing the API.
Although many restrictions on this key are relaxed to allow developers make test requests, this key has a limit of 15 lookups per IP address per day as well as a daily usage cap. If you hit any limit restrictions, you can continue testing the API by creating a key of your own and using our free test methods.
Please be kind with the community key. We're trusting everyone to use it responsibly so that other developers may quickly trial the API. Thank you!