Telnyx API Documentation
Explore the Telnyx product suite to learn more about intelligent features, tutorials, and more.
Messaging
Programmatically send and receive SMS and MMS
Phone Numbers
Search for, buy and configure phone numbers.
Call Control
Programmatically make, manage and route calls.
SIP Trunking
Instantly scale voice connections with Elastic SIP Trunking.
Try Now
Telnyx helps you connect the people, devices, and applications that power your business. Follow our messaging quickstart to start building your integration.
Messaging Profiles are the simplest way for you to configure your inbound and outbound messaging settings. An SMS-capable phone number is SMS-enabled by assigning it to a Messaging Profile.
curl -X POST \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--header "Authorization: Bearer YOUR_API_KEY" \
--data '{"name": "Summer Campaign"}' \
https://api.telnyx.com/v2/messaging_profiles
Search for a messaging capable phone number.
curl -X GET \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--header "Authorization: Bearer YOUR_API_KEY" \
--globoff "https://api.telnyx.com/v2/available_phone_numbers?filter[features][]=sms&filter[features][]=mms"
To use the Messaging API, you’ll need an SMS-capable phone number purchased from, or ported into, the Telnyx platform. If purchasing a new number, select the SMS number feature when searching. In general, numbers that are ported in will be messaging-capable.
curl -X POST \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--header "Authorization: Bearer YOUR_API_KEY" \
--data '{
"phone_numbers": [{"phone_number": "+18665552368"}]
}' \
https://api.telnyx.com/v2/number_orders
Include your API Key in the Authorization
request header, and add the source (from
) and destination (to
) phone numbers, and the message’s content (text
) into the payload.
curl -X POST \
--header "Content-Type: application/json" \
--header "Accept: application/json" \
--header "Authorization: Bearer YOUR_API_KEY" \
--data '{
"from": "+18665552368",
"to": "+18665552367",
"text": "Hello, World!"
}' \
https://api.telnyx.com/v2/messages
