WhatsApp · WhatsApp Phone Numbers

Check country availability

Checks country availability.

GEThttps://api.pozy.ai/v1/whatsapp/phone-numbers/availability
DeprecatedcheckWhatsAppNumberAvailability

Request

Send your API key as Authorization: Bearer pz_live_.... Read-only keys can call it. Keys with the telephony resource group disabled get 403 resource_group_disabled. Authentication

Query parameters

NameTypeNotes
countryrequiredstring
numberTypestringOne of local, mobile, national, toll_free
smsboolean

Example

curl -X GET "https://api.pozy.ai/v1/whatsapp/phone-numbers/availability?country=US" \
  -H "Authorization: Bearer $POZY_API_KEY"

Response

200 on success

  • countrystring
  • numberTypestring
  • availableboolean
  • preOrderableboolean
  • addressConstraintstring

    One of geo, country, none.

  • areasarray of string
  • areaOptionsarray of object
    • ndcstring
    • namestring
    • countinteger
  • soldOutAreasarray of object
    • ndcstring
    • namestring
    • preOrderableboolean
  • areaAvailabilityobject
    • inStockarray of object
      5 child fields
      • ndcstring
      • namestring
      • countinteger
      • ndcsarray of string
      • aliasesarray of string
    • preOrderarray of object
      4 child fields
      • ndcstring
      • namestring
      • ndcsarray of string
      • aliasesarray of string
    • outOfStockarray of object
      5 child fields
      • ndcstring
      • namestring
      • listedinteger
      • ndcsarray of string
      • aliasesarray of string
200 response
{
  "country": "US",
  "numberType": "string",
  "available": true,
  "preOrderable": true,
  "addressConstraint": "geo",
  "areas": [
    "string"
  ],
  "areaOptions": [
    {
      "ndc": "string",
      "name": "Acme",
      "count": 42
    }
  ],
  "soldOutAreas": [
    {
      "ndc": "string",
      "name": "Acme",
      "preOrderable": true
    }
  ],
  "areaAvailability": {
    "inStock": [
      {
        "ndc": "string",
        "name": "Acme",
        "count": 42,
        "ndcs": [
          "string"
        ],
        "aliases": [
          "string"
        ]
      }
    ],
    "preOrder": [
      {
        "ndc": "string",
        "name": "Acme",
        "ndcs": [
          "string"
        ],
        "aliases": [
          "string"
        ]
      }
    ],
    "outOfStock": [
      {
        "ndc": "string",
        "name": "Acme",
        "listed": 1,
        "ndcs": [
          "string"
        ],
        "aliases": [
          "string"
        ]
      }
    ]
  }
}

Errors

Errors use one shape: { error, type, code, param?, details? }. The ones you are most likely to see here:

400invalid_request_errorA parameter or body field is missing or invalid. param names it.
401authentication_errorThe API key is missing, revoked or expired.
403permission_errorThe key is scoped to other profiles or has this resource group disabled.
429rate_limit_errorToo many requests this minute. Wait for Retry-After seconds.

Every code is listed in Errors.

More in WhatsApp Phone Numbers