Skip to content

Purchase phone number

Initiate purchasing a WhatsApp phone number. Payment-first flow: the user does not pick a specific number. The system either creates a Stripe Checkout Session (first number) or increments the existing subscription quantity and provisions inline (subsequent numbers).

Requires a paid plan. The maximum number of phone numbers is determined by the user's plan.

POST /v1/whatsapp/phone-numbers/purchase

Initiate purchasing a WhatsApp phone number. Payment-first flow: the user does not pick a specific number. The system either creates a Stripe Checkout Session (first number) or increments the existing subscription quantity and provisions inline (subsequent numbers).

Requires a paid plan. The maximum number of phone numbers is determined by the user's plan.

Request body

Content-Type: application/json

  • profileId (string) required — Profile to associate the number with

Example:

json

{
  "profileId": "507f1f77bcf86cd799439011"
}

Responses

200 — Either a checkout URL (first number) or the provisioned phone number (subsequent numbers).

one of:

    • message (string)
  • checkoutUrl (string)
    • message (string)
  • phoneNumber (object)

400 — Plan limit reached or profileId required

401

403 — A paid plan is required