This quickstart guide will show you how to start making your first simple Phone Validation API requests. Here are the steps to follow to get up and running with Phone Validation:
  • Create an account, if you don’t already have one
  • Create an API key for use with Phone Validation
  • Make a simple Phone Validation request

Creating an account and API key

Before you can start making any requests, you’ll need to have a valid Loqate account and an API key to use with Phone Validation. If you don’t have these set up already, you can:
  • Create an account at account.loqate.com
  • Create an API key by selecting the Add a service option within your account. See our Creating API Keys page for full details – we recommend creating a generic API key for use with Phone Validation

Making a simple Phone Validation request

With a valid account and API key, you can now start making Phone Validation requests. The endpoint to use is:
We don’t support API connections using HTTP – make sure you are using HTTPS for all requests.

Considerations

There are two ways of making a Phone Validation request:
  • With a country code in international format (i.e. using +44 for a UK phone number or +1 for a US/Canada number)
  • Without a country code, instead using the Country parameter with the relevant 2- or 3-digit ISO code (i.e. GB/GBR for the UK, or US/USA for the USA)
In the Example requests section below we’ll include an example for each method.

Example requests

Below we have provided some simple examples of Phone Validation requests. Both will result in the same level of detail in the response. You can copy and paste this example request into a tool such as Postman – just remember to replace the sample API key with your own valid API key.

Without the Country parameter

This example uses the international format (i.e. +44) so does not require the Country parameter.
GET https://api.addressy.com/PhoneNumberValidation/Interactive/Validate/v2.2/json3.ws?Key=AA11-AA11-AA11-AA11&Phone=+441244657333

With the Country parameter

This example uses a national format, with the Country parameter providing the ISO country code (i.e. GBR).
GET https://api.addressy.com/PhoneNumberValidation/Interactive/Validate/v2.2/json3.ws?Key=AA11-AA11-AA11-AA11&Phone=01244657333&Country=GBR

Example response

Both examples above will return the same response:
{
    "Items": [
        {
            "PhoneNumber": "+441244657333",
            "RequestProcessed": true,
            "IsValid": "Yes",
            "NetworkCode": "",
            "NetworkName": "BT",
            "NetworkCountry": "GB",
            "NationalFormat": "01244 657333",
            "CountryPrefix": 44,
            "NumberType": "Landline"
        }
    ]
}
As you can see, this response returns Yes in the IsValid field, showing that the inputted phone number is a valid one. It also provides a range of additional information about the phone number in question. See the Phone Validation API docs for information about specific response fields.

Further reading

Now that you’ve made your first Phone Validation API requests, here are some additional resources that you might find useful as you continue setting up your integration: