Skip to main content
POST
Send Truecaller Image Message

Description

Sends a JPEG, PNG, or GIF. The URL is sent to Truecaller as given and must be a public http:// or https:// URL. Truecaller’s file size limit is 20 MB. mime_type is optional when the URL path ends in .jpg, .jpeg, .png, or .gif. The extension is taken from the path, not the query string. A missing type, or a type that is not an allowed image type, fails after queueing with 91405 (UNSUPPORTED_TRUECALLER_MEDIA_TYPE). A 200 means the message was queued.

Headers

string
required
Your API key for authentication. The workspace on the key must match x-workspace-id.
string
required
Workspace id that owns the API key.
string
required
application/json

Body

string
required
Phone number. An empty value is rejected immediately. After the message is queued, the number is normalized with the workspace country, so a local number is accepted. A number that cannot be normalized fails with code 90103 (INVALID_RECIPIENT_NUMBER).
string
required
Truecaller bot id from Settings → Channels → Truecaller. 24-character hex. An unknown bot fails after queueing with 91401 (INVALID_TRUECALLER_BOT_ID). A paused bot fails with 91402 (TRUECALLER_BOT_PAUSED).
integer
How long Truecaller keeps trying to deliver the message. Integer from 1 to 2419200 (28 days). Omit it to use the bot’s default TTL. When that default is 0, processing uses 86400 (24 hours). No delivery report by then marks the message failed. A value outside the range fails after queueing with 91406 (INVALID_TRUECALLER_TTL).
string
Stored on the delivery log with the send. There is no format check. The HTTP body posted to this URL is not defined by this API.
string
Stored on the delivery log with the send.
string
required
Public http:// or https:// URL of the image.
string
image/jpeg, image/png, or image/gif. Inferred from .jpg, .jpeg, .png, or .gif when omitted.
string
required
Required, including for media. 1 to 4096 Unicode code points. Whitespace alone is rejected.
array
Optional. Maximum 3. Count, text length, type, and the field that type requires (url, phone_number, or list.options) are checked immediately. action_tag shape, duplicate tags, link URL shape, phone shape, and unique list option ids and titles are checked after queueing. A failure after queueing uses 91404 (INVALID_TRUECALLER_MESSAGE).

Request Example

Response

boolean
true when the message was accepted onto the queue.
string
Truecaller request queued successfully on success. On validation failure, field errors joined with ; .
string
Present when success is true. UUID. Use it on the delivery-report API.