Create New Phone Number Campaign
POST/phone_number_campaigns
Create New Phone Number Campaign
Request
- application/json
Body
required
phoneNumber Phonenumber (string)required
The phone number you want to link to a specified campaign.
campaignId Campaignid (string)required
The ID of the campaign you want to link to the specified phone number.
Responses
200: Successful Response
- application/json
default: Unexpected error
- application/json
Request samples
curl -L 'https://api.telnyx.com/10dlc/phone_number_campaigns' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <TOKEN>' \
-d '{
"phoneNumber": "+18005550199",
"campaignId": "4b300178-131c-d902-d54e-72d90ba1620j"
}'
Response samples
{
"phoneNumber": "+18005550199",
"brandId": "7ba705b7-22af-493f-addc-ac04b7ca071c",
"tcrBrandId": "BBRAND1",
"campaignId": "string",
"tcrCampaignId": "CCAMPA1",
"telnyxCampaignId": "3008dd9f-66d7-40e0-bf23-bf2d8d1a96ba",
"assignmentStatus": "ASSIGNED",
"createdAt": "2024-07-29T15:51:28.071Z",
"updatedAt": "2024-07-29T15:51:28.071Z"
}
{
"errors": [
{
"code": "string",
"title": "string",
"detail": "string",
"source": {
"pointer": "string",
"parameter": "string"
}
}
]
}