Whatsapp Phone Numbers

Update Connection ID for a WhatsApp Calling BYON number

Changed on

Set or clear the connection ID for a WhatsApp Calling BYON (Bring Your Own Number) phone number: the connection that inbound WhatsApp calls to the number are delivered to.

The update is processed asynchronously. A 202 response means the request was accepted, not that the routing changed. Check the result with GET /whatsapp/phone_numbers/{id}/calling_routing, which can return the previous value immediately after an update. An update for a number that is not a WhatsApp Calling number in the account returns 404.

The connection must belong to the same account and must not be a WhatsApp connection. Send connection_id: null to clear the routing; omitting connection_id is rejected. Numbers active on Telnyx are rejected, because they route through their own connection assignment.

Sub-users need update permission on connections, and read permission to check the result with GET.

patch/whatsapp/phone_numbers/{id}/calling_routing

Request

  • Base URL: https://api.telnyx.com/v2
  • URL: https://api.telnyx.com/v2/whatsapp/phone_numbers/{id}/calling_routing
  • Auth: HTTP bearer

Path parameters

idstring required

The BYON phone number in E.164 format. The leading + is optional.

Request body

Response

Update accepted for processing. The body echoes the requested routing; it does not confirm that the routing was applied.

Example response

{
  "data": {
    "record_type": "whatsapp_calling_routing",
    "phone_number": "+13125550100",
    "connection_id": "1234567890"
  }
}

Changes