Skip to main content

Verify a number

POST 

/whatsapp/verifyNumber

Part 2: you verify the code you received, and now the number is verified and belongs to you.

This API allows you to add a number to your account, in order to use the Step 2: Onboarding API. In order to use the number, we must verify the number. You can request the verification code by SMS or by a phone call. This is part 2 of Step 1: Register a number.

This process is a two-part process:

  • Part 1: you register the number by asking for the verification code. After submitting the registerNumber API, you will get an SMS or a phone call with a 6-digit verification code.
  • Part 2: you verify the code you received (this page). Now the number is verified and belongs to you.

Registered phone numbers will wait in your account for 90 days, until expiration. During this time you must create an account with that number (Step 2: Onboarding). If you did not create an account with that phone number, after 90 days you will have to register the number again.

Settings​

SettingValue
URLhttps://partners.99digital.co.il/api/whatsapp/verifyNumber
MethodJSON via POST
HeaderAuthorization: Bearer {{access_token}} — the access token can be received from the Access Token API.

Requires the Add new number permission (Verified Numbers).

Body​

ParameterDescription / ExampleMaximum lengthRemarksMandatory
whatsappThe same WhatsApp number you used to request the code with the registerNumber API20Use the country code and the number, digits only, without +. For example: 972501234567Yes
codeThe 6-digit code66 digits, numbers only. Remove any hyphens if the code received by SMS contains any. You can try up to 3 times.Yes

Response​

{
"status": "OK",
"whatsapp": "972501234567",
"expiration": 1737109621,
"reason": 1
}

Response explained​

ParameterDescription
statusOK or FAIL. "OK" means the verification was successful. "FAIL" means error.
whatsappThe WhatsApp number.
expirationThe expiration timestamp (Unix time, in seconds), 90 days from now. Create the WhatsApp account with this number before then.
reasonThe status explanation — see the table below.
ReasonExplanation
1Not FAIL: the status is OK.
2Wrong credentials: the Authorization header is missing or not Bearer <token>, or this endpoint doesn't accept the token's type (account-scoped and onboarding tokens are rejected).
3The access token does not exist or has expired. Please generate another one with the Access Token API.
4The WhatsApp number is empty or wrong (digits only, up to 20).
7The number you are trying to verify has already been verified by you.
10code is empty or not a 6-digit number.
11The WhatsApp number you are trying to verify is not a number that is waiting to be verified (in your account). Please use the registerNumber API (part 1) first.
12The code is wrong, please try again. You can try up to 3 times.
15Unknown error, please contact support. Also returned when the request body is not valid JSON.

Request​

Responses​

The request was processed. Both a successful and a failed request answer with HTTP 200 — check status, and reason when it is FAIL.