right  Talk To Us!

Number lookup

Aculab cloud has a facility that allows you to check the line type and the carrier name of a phone number.

 This is a low level API. For information on higher level APIs see the Web Services Language Wrappers
  • Check

    This is used to check the phone number line type, carrier and country.

    Authorisation

    This API uses basic authentication, using your cloud account username and API Access Key.

    Username : cloudID/username (e.g. 1-2-0/bob@example.com)
    Password : API Access key

    Request:

    Url:https://ws.aculabcloud.net/number_lookup/v1/check
    Methods:GET

    ParameterValueDescription
    phone_numberstringinternational format of the specified phone number

    Returns on success:

    A JSON object containing the following parameters:

    ParameterTypeAvailabilityDescription
    number_foundboolAlwaystrue if details for the specified phone number were found
    country_namestringIf number_found is truethe country name assigned to the specified phone number
    country_codestringIf number_found is true the three-letter ISO 3166-1 alpha-3 country code assigned to the specified phone number
    line_typestringIf number_found is truethe line type of the specified phone number. One of the following: mobile, landline, toll_free, voip, other.
    carrierstringIf number_found is true the name of the carrier which the specified phone number is registered with

    Example:

    https://ws-1-2-0.aculabcloud.net/number_lookup/v1/check?phone_number=443069990123

    Response:

    If successful you will receive the example JSON response:

    {
        "number_found": true,
        "country_name": "United States",
        "country_code": "USA",
        "line_type": "mobile",
        "carrier": "United States Cellular Corp. (U.S. Cellular)"
    }

    or

    {
        "number_found": false
    }

    Or on error an HTTP error containing a JSON response. For example:

    {
        "error": {
            "code": "400 Bad Request",
            "text": "Invalid phone number format",
            "link": "https://www.aculab.com/cloud/web-services/number-lookup/",
            "datetime": "2022-02-03_15:41:58"
        },
        "request": {
            "url": "/number_lookup/v1/check",
            "datetime": "2022-02-03_15:41:58"
        }
    }

    Charging information

    Each call to this web service is charged at a standard rate, whether the supplied phone number is found or not.

    Cost information is available on the pricing page on the Cloud Console and will be reflected in the monthly account statements.