The Send Message endpoint in the Aircall Public API allows you to send SMS or MMS messages from your Aircall phone numbers. This is useful when integrating external tools or custom applications that need to send messages as if they originated from Aircall.
Before using this endpoint, ensure you have reviewed the About Aircall Messaging API article, which explains the available messaging options, pricing, regulations, and rate limits.
Important: Sending messages through the API is available only on the Aircall Professional plan. To upgrade, contact our Customer Success team.
Set up an Aircall number for API messaging
To enable API based messaging, you must configure your Aircall number using the messages/configuration endpoint. This prepares the number to send messages through the API only (not through the Aircall app).
Steps:
- Make a POST request to the
messages/configurationAPI endpoint. - Use the GET endpoint to confirm the configuration if needed.
- Use the DELETE endpoint to remove the configuration if you ever need to disable API messaging.
Note: Configuration is required before you can send SMS or MMS messages through the API.
Send messages using the API
Once your number is configured, you can send messages by calling the messages/send endpoint.
Steps:
- Prepare your request body according to the API documentation.
- Make a POST request to the
messages/sendendpoint. - Review the response body to confirm message status.
Important: Messages sent through the API are not recorded or displayed anywhere in the Aircall platform.
Example response for a sent message
{
"id": "abcdSMc6Dc8ea2bc71ab19102c3de4f60ba18aa",
"status": "pending",
"direct_link": "https://api.aircall.io/v1/numbers/1234567/messages/abcdSMc6Dc8ea2bc71ab19102c3de4f60ba18aa",
"direction": "outbound",
"created_at": 1722758201825,
"sent_at": 1722758201825,
"updated_at": 1722758201825,
"raw_digits": "13023063029",
"number": {
"id": 84848484,
"direct_link": "https://api.aircall.io/v1/numbers/1234567",
"name": "US SMS line 1",
"digits": "+1 626-800-9000",
"country": "US",
"time_zone": "America/Chicago",
"open": true,
"created_at": "2024-07-17T13:12:10Z"
},
"body": "body of the message"
}
Receive inbound messages on your callback URL
When you configure your number for API messaging, you also specify a callback URL. This endpoint will receive any inbound messages or responses to messages you have sent.
Example payload for a received message
{
"resource": "message",
"event_name": "message.received",
"timestamp": 1722604989549,
"token": "91aa69db-c65e-42d9-85e7-g346b1h2204aa",
"data": {
"id": "abdcSM11da5992cb15eed9f21bcdb26d264bb40a",
"status": "received",
"direct_link": "https://api.aircall.io/v1/numbers/1234567/messages/abdcSM11da5992cb15eed9f21bcdb26d264bb40a",
"direction": "inbound",
"created_at": 1722604989549,
"sent_at": 1722604989549,
"updated_at": 1722604989549,
"raw_digits": "18704575426",
"number": {
"id": 84848484,
"direct_link": "https://api.aircall.io/v1/numbers/1234567",
"name": "US SMS line 1",
"digits": "+1 626-800-9000",
"country": "US",
"time_zone": "America/Chicago",
"open": true,
"created_at": "2024-07-17T13:12:10Z"
},
"body": "Body of the message received"
}
}
Tutorials and further learning
A technical tutorial is available that walks through a complete implementation of the Aircall SMS API. Reviewing this example can help you understand how to build your integration effectively.
Need additional support?
If you do not have development resources available, Aircall's Solutions Engineering team and certified Partners can help with custom implementations. Contact our Customer Success team to explore these options.