curl --location --request DELETE 'https://api.weya.live/backend/api/whatsapp/delete-whatsapp-number/6891f1d0c45d123456789abc' \
--header 'x-api-key: YOUR_API_KEY'
{
"status": true,
"code": 200,
"message": "Whatsapp number deleted successfully",
"errorMessage": null,
"data": []
}
Phone Numbers
Delete WhatsApp Number
Remove a connected WhatsApp number from your workspace.
DELETE
/
api
/
whatsapp
/
delete-whatsapp-number
/
{phoneNumberId}
curl --location --request DELETE 'https://api.weya.live/backend/api/whatsapp/delete-whatsapp-number/6891f1d0c45d123456789abc' \
--header 'x-api-key: YOUR_API_KEY'
{
"status": true,
"code": 200,
"message": "Whatsapp number deleted successfully",
"errorMessage": null,
"data": []
}
Overview
Permanently delete one of your WhatsApp integrations. For apro integration, Weya also tries to remove its AiSensy subscription; if that fails, the integration is still deleted.
The API doesn’t check whether a WhatsApp agent is assigned to the number.
This can’t be undone. To use the number again, connect it again with Create WhatsApp Integration; it gets a new ID.
Prerequisites
- An API key for your workspace
- The integration ID (
_idfrom Get WhatsApp Numbers), connected by the user who owns the API key
Request
curl --location --request DELETE 'https://api.weya.live/backend/api/whatsapp/delete-whatsapp-number/6891f1d0c45d123456789abc' \
--header 'x-api-key: YOUR_API_KEY'
Response
{
"status": true,
"code": 200,
"message": "Whatsapp number deleted successfully",
"errorMessage": null,
"data": []
}
Error Handling
Errors returnstatus: false, with the reason in errorMessage.
- 400 Bad Request –
Invalid Phone Number ID. - 401 Unauthorized – Missing or invalid API key.
- 404 Not Found –
WhatsApp number not found: it doesn’t exist, is already deleted, or wasn’t connected by the user who owns the API key. - 429 Too Many Requests – More than 1,000 WhatsApp requests in 15 minutes from your IP address.
- 500 Internal Server Error – Unexpected server error.
Was this page helpful?

