POST /<WHATSAPP_BUSINESS_ACCOUNT_ID>/phone_numbers
{ "cc": "<CC>", "phone_number": "<PHONE_NUMBER>", "verified_name": "<VERIFIED_NAME>" }
| Placeholder | Description | Example Value |
|---|---|---|
<CC>String | Required. The phone number’s country calling code. | 1 |
<PHONE_NUMBER>String | Required. The phone number, with or without the country calling code. | 15551234 |
<VERIFIED_NAME>String | Required. The phone number’s display name. | Lucky Shrub |
{ "id": "<ID>" }
| Placeholder | Description | Example Value |
|---|---|---|
<ID> | An unverified WhatsApp Business Phone Number ID. | 106540352242922 |
curl 'https://graph.facebook.com/v25.0/102290129340398/phone_numbers' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer EAAH7...' \
-d '{
"cc": "1",
"phone_number": "14195551518",
"verified_name": "Lucky Shrub"
}'
{ "id": "110200345501442" }
POST /<WHATSAPP_BUSINESS_PHONE_NUMBER_ID>/request_code
?code_method=<CODE_METHOD>
&language=<LANGUAGE>
| Placeholder | Description | Example Value |
|---|---|---|
<CODE_METHOD> | Required. Indicates how you want the verification code delivered to the business phone number. Values can be SMS or VOICE. | SMS |
<LANGUAGE> | Required. Indicates language used in delivered verification code. | en_US |
{ "success": <SUCCESS> }
| Placeholder | Description | Example Value |
|---|---|---|
<SUCCESS> | Boolean indicating success or failure. Upon success, the API will respond with true and a verification code will be sent to the business phone number using the method specified in your request. | true |
curl -X POST 'https://graph.facebook.com/v25.0/110200345501442/request_code?code_method=SMS&language=en_US' \
-H 'Authorization: Bearer EAAJB...'
{ "success": true }
WhatsApp code 123-830
POST /<WHATSAPP_BUSINESS_PHONE_NUMBER_ID>/verify_code
?code=<CODE>
| Placeholder | Description | Example Value |
|---|---|---|
<CODE>String | Required. Verification code, without the hyphen. | 123830 |
{ "success": <SUCCESS> }
| Placeholder | Description | Example Value |
|---|---|---|
<SUCCESS> | Boolean indicating success or failure. Upon success, the API will respond with true, indicating that the business phone number has been verified. | true |
curl -X POST 'https://graph.facebook.com/v25.0/110200345501442/verify_code?code=123830' \
-H 'Authorization: Bearer EAAJB...'
{ "success": true }
POST /<BUSINESS_PHONE_NUMBER_ID>/register
{ "messaging_product": "whatsapp", "pin": "<PIN>" }
| Placeholder | Description | Example Value |
|---|---|---|
<PIN>String | Required. If the verified business phone number already has two-step verification enabled, set this value to the number’s 6-digit two-step verification PIN. If you do not recall the PIN, you can update it. If the verified business phone number does not have two-step verification enabled, set this value to a 6-digit number. This will be the business phone number’s two-step verification PIN. | 123456 |
true, indicating successful registration.{ "success": <SUCCESS> }
| Placeholder | Description | Example Value |
|---|---|---|
<SUCCESS> | Boolean indicating success or failure. Upon success, the API will respond with true, indicating successful registration. | true |
curl 'https://graph.facebook.com/v25.0/110200345501442/register' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer EAAJB...' \
-d '
{
"messaging_product": "whatsapp",
"pin": "123456"
}'
{ "success": true }