Phone Numbers
Agent Subscribe
Assign an agent as the default for this number. Drops any subscribed webhook.
POST
cURL
Sets the number’s default routing to
agent and assigns the chosen agent
as the active bot. Any webhook subscribed to the number is dropped — call
POST /phone-numbers/{number}/subscribe/
to route to a webhook instead.
When applyToExisting is true, the new agent is written onto every
existing conversation on this number and the in-flight session is cleared
so the new agent picks up from scratch. Phone-number routing changes do
not dispatch subscription.activated / subscription.revoked webhook
events.
The agent must already be owned by or shared with the requesting user.
Sandbox numbers scope the change to the requesting user’s own conversation:
their activeAgent is set to the chosen agent and their conversation
routing is forced to agent so the agent flow runs for them. Other users
on the shared sandbox are unaffected.Authorizations
API key authentication. Pass your API key in the X-API-Key header.
Path Parameters
Body
application/json
Response
200 - application/json
Serializer for WhatsappNumber model.
Maximum string length:
15cURL