Phone Numbers
Buy Phone Number
Phone Numbers
Buy Phone Number
POST
/
phone-number
/
buy
curl --request POST \
--url https://api.vapi.ai/phone-number/buy \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"areaCode": "<string>",
"name": "<string>",
"assistantId": "<string>",
"serverUrl": "<string>",
"serverUrlSecret": "<string>"
}'
{
"id": "<string>",
"orgId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"stripeSubscriptionId": "<string>",
"stripeSubscriptionStatus": "<string>",
"stripeSubscriptionCurrentPeriodStart": "2023-11-07T05:31:56Z",
"number": "<string>",
"twilioAccountSid": "<string>",
"twilioAuthToken": "<string>",
"credentialId": "<string>",
"name": "<string>",
"assistantId": "<string>",
"serverUrl": "<string>",
"serverUrlSecret": "<string>"
}
Body
application/json
Response
201 - application/json
The response is of type object
.
Was this page helpful?
curl --request POST \
--url https://api.vapi.ai/phone-number/buy \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"areaCode": "<string>",
"name": "<string>",
"assistantId": "<string>",
"serverUrl": "<string>",
"serverUrlSecret": "<string>"
}'
{
"id": "<string>",
"orgId": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"stripeSubscriptionId": "<string>",
"stripeSubscriptionStatus": "<string>",
"stripeSubscriptionCurrentPeriodStart": "2023-11-07T05:31:56Z",
"number": "<string>",
"twilioAccountSid": "<string>",
"twilioAuthToken": "<string>",
"credentialId": "<string>",
"name": "<string>",
"assistantId": "<string>",
"serverUrl": "<string>",
"serverUrlSecret": "<string>"
}