Opérations disponibles
Provision WhatsApp deployment
This API request provisions a WhatsApp cluster. Once provisioned, the cluster progresses through the following deployment stages: INITIALIZING, CREATING_CLUSTER and CLUSTER_CREATED. When the CLUSTER_CREATED stage is reached an OTP voice call or SMS is sent to the specified number and the deployment status becomes CODE_SENT. When the OTP is received, call the Verify API to complete the process.
Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
44The international dialing code of the number being provisioned
8675309The WhatsApp number being provisioned.
AbCdEFGHiJK123456The certificate, which you can retrieve from your WhatsApp Business dashboard.
Note this value is refreshed whenever you click the View button.
smsThe method for delivering the OTP
smsvoice123456789123WABA ID of the WhatsApp Number
123456Required if you previously set a PIN when creating a WhatsApp number.
Exemple Demande
{
"country_code": "44",
"number": "8675309",
"vname_certificate": "AbCdEFGHiJK123456",
"method": "sms",
"waba_id": "123456789123",
"pin": "123456"
}{
"country_code": "44",
"number": "8675309",
"vname_certificate": "AbCdEFGHiJK123456",
"method": "sms",
"waba_id": "123456789123",
"pin": "123456"
}aaaaaaaa-bbbb-cccc-dddd-0123456789abThe Deployment id
The WhatsApp Business Account (WABA) ID of the WhatsApp number
44The international dialing code of the deployment e.g. 44 for the United Kingdom.
7700900000The phone number of the deployment (minus the international dialing code) e.g. 7700900000
abcd1234The API key associated with the deployment.
The current status of the deployment
INITIALIZINGThe current status of the deployment.
INITIALIZINGCREATING_CLUSTERCLUSTER_CREATEDCODE_SENTWRONG_CODECODE_VERIFIEDFINALIZINGREADYERRORDELETINGDELETEDInitializing deploymentDescription of the deployment status e.g. Invalid vname certificate
Exemple Réponse
{
"deployment_id": "aaaaaaaa-bbbb-cccc-dddd-0123456789ab",
"waba_id": "string",
"country_code": "44",
"number": "7700900000",
"api_key": "abcd1234",
"current_state": {
"title": "INITIALIZING",
"detail": "Initializing deployment"
}
}Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
aaaaaaaa-bbbb-cccc-dddd-0123456789abThe Deployment id
The WhatsApp Business Account (WABA) ID of the WhatsApp number
44The international dialing code of the deployment e.g. 44 for the United Kingdom.
7700900000The phone number of the deployment (minus the international dialing code) e.g. 7700900000
abcd1234The API key associated with the deployment.
The current status of the deployment
INITIALIZINGThe current status of the deployment.
INITIALIZINGCREATING_CLUSTERCLUSTER_CREATEDCODE_SENTWRONG_CODECODE_VERIFIEDFINALIZINGREADYERRORDELETINGDELETEDInitializing deploymentDescription of the deployment status e.g. Invalid vname certificate
Exemple Réponse
{
"deployment_id": "aaaaaaaa-bbbb-cccc-dddd-0123456789ab",
"waba_id": "string",
"country_code": "44",
"number": "7700900000",
"api_key": "abcd1234",
"current_state": {
"title": "INITIALIZING",
"detail": "Initializing deployment"
}
}Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
Opérations disponibles
Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
smssmsvoiceExemple Demande
{
"method": "sms"
}{
"method": "sms"
}Verify OTP
When a code is successfully verified, WhatsApp Manager will move the number from a CODE_VERIFIED state to a FINALIZING state where additional checks are made and it is assigned to your API Key. Once this is complete it will enter a READY state and the number is ready to use.
Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
674639OTP being submitted for verification
Exemple Demande
{
"code": "674639"
}{
"code": "674639"
}Opérations disponibles
Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
1139about your businessText to display in your profile's About section - max 139 characters.
1256123 main streetYour business address - max 256 characters.
1256your business descriptiona description of your business - max 256 characters
1128you@example.comYour business' email - max 128 characters
Food and GroceryYour business' industry - must be recognized by WhatsApp.
AutomotiveBeauty, Spa and SalonClothing and ApparelEducationEntertainmentEvent Planning and ServiceFinance and BankingFood and GroceryPublic ServiceHotel and LodgingMedical and HealthNon-profitProfessional ServicesShopping and RetailTravel and TransportationRestaurantOtherYour business' websites maximum of 2 websites, max website length: 256
Exemple Réponse
{
"about": "about your business",
"address": "123 main street",
"description": "your business description",
"email": "you@example.com",
"vertical": "Food and Grocery",
"websites": [
"https://example.com"
]
}Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
1139about your businessText to display in your profile's About section - max 139 characters.
1256123 main streetYour business address - max 256 characters.
1256your business descriptiona description of your business - max 256 characters
1128you@example.comYour business' email - max 128 characters
Food and GroceryYour business' industry - must be recognized by WhatsApp.
AutomotiveBeauty, Spa and SalonClothing and ApparelEducationEntertainmentEvent Planning and ServiceFinance and BankingFood and GroceryPublic ServiceHotel and LodgingMedical and HealthNon-profitProfessional ServicesShopping and RetailTravel and TransportationRestaurantOtherYour business' websites maximum of 2 websites, max website length: 256
Exemple Demande
{
"about": "about your business",
"address": "123 main street",
"description": "your business description",
"email": "you@example.com",
"vertical": "Food and Grocery",
"websites": [
"https://example.com"
]
}{
"about": "about your business",
"address": "123 main street",
"description": "your business description",
"email": "you@example.com",
"vertical": "Food and Grocery",
"websites": [
"https://example.com"
]
}1139about your businessText to display in your profile's About section - max 139 characters.
1256123 main streetYour business address - max 256 characters.
1256your business descriptiona description of your business - max 256 characters
1128you@example.comYour business' email - max 128 characters
Food and GroceryYour business' industry - must be recognized by WhatsApp.
AutomotiveBeauty, Spa and SalonClothing and ApparelEducationEntertainmentEvent Planning and ServiceFinance and BankingFood and GroceryPublic ServiceHotel and LodgingMedical and HealthNon-profitProfessional ServicesShopping and RetailTravel and TransportationRestaurantOtherYour business' websites maximum of 2 websites, max website length: 256
Exemple Réponse
{
"about": "about your business",
"address": "123 main street",
"description": "your business description",
"email": "you@example.com",
"vertical": "Food and Grocery",
"websites": [
"https://example.com"
]
}Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
https://www.example.com/img.pngURL pointing to a .png or .jpg. Image must be minimum 192px. max 640px x 640px. max 5MB.
Exemple Demande
{
"image_url": "https://www.example.com/img.png"
}{
"image_url": "https://www.example.com/img.png"
}Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
your-publisher-nameThe name of the publisher of the third-party stickerpack.
your-sticker-pack-nameThe name of the stickerpack.
https://itunes.apple.com/app/id3133333The link to the stickerpack in the Apple iOS App Store. The link follows the format https://itunes.apple.com/app/idXXXXXXXXX. To get your App Store link, refer to the instructions at https://stackoverflow.com/questions/4137426/get-itunes-link-for-app-before-submitting
https://play.google.com/store/apps/details?id=com.exampleThe link to the stickerpack in the Google Play store. The link follows the format https://play.google.com/store/apps/details?id=com.example where com.example is your app's package name.
Exemple Demande
{
"publisher": "your-publisher-name",
"name": "your-sticker-pack-name",
"ios_app_store_link": "https://itunes.apple.com/app/id3133333",
"android_app_store_link": "https://play.google.com/store/apps/details?id=com.example"
}{
"publisher": "your-publisher-name",
"name": "your-sticker-pack-name",
"ios_app_store_link": "https://itunes.apple.com/app/id3133333",
"android_app_store_link": "https://play.google.com/store/apps/details?id=com.example"
}Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
sticker-pack-namesticker-pack-publisherhttps://play.google.com/store/apps/details?id=com.examplehttps://itunes.apple.com/app/id3133333Exemple Réponse
{
"stickerpacks": [
{
"name": "sticker-pack-name",
"publisher": "sticker-pack-publisher",
"android_app_store_link": "https://play.google.com/store/apps/details?id=com.example",
"ios_app_store_link": "https://itunes.apple.com/app/id3133333"
}
]
}Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
idThe ID for the sticker media.
[
"🐥",
"😃"
]An array of the emojis included in the stickerpack.
Exemple Demande
{
"image_data_id": "id",
"emojis": [
"🐥",
"😃"
]
}{
"image_data_id": "id",
"emojis": [
"🐥",
"😃"
]
}Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
Authentification
| Clé | Description | Où | Exemple |
|---|---|---|---|
| Authorization | Votre jeton web JSON. | Headers | Bearer <JWT> |
Erreurs
Voici une liste non exhaustive des codes d'erreur susceptibles de se produire lors de l'utilisation de cette API.
Ces codes s'ajoutent à ceux de notre site codes d'erreur génériques.
| Code | Informations |
|---|---|
| number-in-use | Description Cannot use number because it's already in use by another deployment. Résolution Use the existing deployment. |
| invalid-json | Description The request body did not contain valid JSON Résolution Send a JSON request body, including a Content-Type header of application/json |
| unprocessable | Description Parameters were valid JSON but something was missing or wrongly formatted Résolution Fix the incorrect request parameters and try again |
| unprocessable-profile-update | Description Parameters were valid JSON but something was missing or wrongly formatted Résolution Fix the incorrect request parameters and try again |
| throttled | Description Too many requests have been made on this endpoint Résolution Wait a moment and try again |
| verification-failed | Description Verification step failed. Either because the provided code was incorrect or because too many attempts have been made Résolution Try again with the correct OTP, or call resend-otp |
| conflict-deployment-state | Description Deployment could not be modified because it is currently in a transitional state. Résolution If the deployment is transitioning into the state you want it in no action is required. If the state is |
| conflict-resend-otp | Description Could not resend OTP because the current state of the deployment did not allow it Résolution The deployment has either already finished, or is in an error state (in which case you should delete it and run it again). |