Skip to main content
POST
Purchase Phone Number

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
phone_number
string
required

E.164 formatted phone number to purchase

Example:

"+14155551234"

payment_method_id
string
required

Stripe payment method ID

Example:

"pm_1234567890"

friendly_name
string

Display name for the number

Example:

"Main Business Line"

is_free_number
boolean
default:false

Whether to use free number allocation (for eligible plans)

Response

Phone number purchased successfully

success
boolean
required
phone_number
string
required
sid
string
required

Twilio Phone Number SID

message
string
required
Example:

"Phone number purchased successfully!"

subscription_id
string

Stripe subscription ID

is_free_number
boolean

Whether this was a free number allocation