Send a Truecaller message
Parameters
Recipient phone number. Accepts local format (without country code, where applicable), country code without
+, or E.164 with + prefix — for example 08012345678, 2348012345678, +2348012345678, or +14155552671. Required unless contact or group is provided.The message text to deliver. Maximum of 3 pages.
Your registered sender ID. Register a sender ID on your dashboard before use.
Routing type for the sender ID. Accepted values:
transactional or promotional.A publicly accessible URL on your server. Sling sends a
POST request to this URL when the delivery status changes. Only used when instant is false. See the callbacks guide for payload details.Controls delivery mode. See the section below for the difference between
true and false.When
true, Sling falls back to SMS if the message cannot be delivered over Truecaller.Sender ID used for the SMS fallback when
fallback_sms is true. For example, Sling while your Truecaller sender is Brand.The ID of a saved contact from your Sling contact list. Use instead of
to.The ID of a contact group. Sends the message to every contact in the group. Use instead of
to.Instant vs. async delivery
Theinstant parameter controls whether Sling processes the message synchronously or queues it for background delivery.
- instant: true
- instant: false
Sling processes the message immediately and returns the result — success or failure — directly in the API response. Use this when you need to confirm delivery in real time before proceeding in your application logic.The response will include a
status of "success" or a failure detail, allowing you to handle the outcome synchronously.SMS fallback
Set
fallback_sms to true and Sling will re-send the message as a standard SMS if delivery over Truecaller is not possible. Use fallback_sms_sender to set the SMS Sender ID for that fallback (for example, Sling when your Truecaller sender is Brand).Responses
Success
Errors
When
instant is false, store the message_id from the response to correlate it with the callback payload your server receives when delivery completes.