Messages

A message is one text over one channel. contact may list up to 100 numbers, separated by commas. channel here is the CPaaS product id (1 = SMS), not an Alaris SMS connection type (TX/RX/TR). You create it with POST /messages; the platform answers 202 Accepted immediately and reports the actual delivery lifecycle asynchronously — via webhooks and EDRs.

{
  "contact":    "905063565285",
  "channel":    1,
  "senderId":   "Routeon",
  "payload":    { "text": "Hello from Routeon" },
  "webhook":    "https://your.app/hooks/routeon",
  "clientInfo": "batchId=2026-06-30"
}

Key fields

Field Type Required Meaning
contact string Yes The recipient. For phone-based channels: the number with country code, digits only, no + (e.g. 905063565285). For Email: the address. For Push: the device token.
channel integer Yes Channel enum — see the table below. 1 = SMS.
senderId string Yes An Active Sender ID registered for this channel.
payload object One of Channel-specific content. For SMS: { "text": "..." }. Mutually exclusive with template.
template object One of Reference to a stored content template: { "id": <template_id>, "params": { ... } }. params is required even when empty ({}).
webhook string No Delivery-status callback URL for this message; overrides the Sender-level and key-level webhook.
clientInfo string No Free-form correlation tag (e.g. batchId=..., your internal order ID). Stored on the message’s EDR and returned in GET /edrs, so you can tie platform records back to your own system.
isOtp boolean No Mark one-time-password traffic. When true, the message body is masked in logs and reports. See OTP.
successOn string No When the platform considers this send successful: sent (default), delivered, or seen. Only meaningful as part of an omnimessage cascade.
timeout integer No Seconds to wait for the successOn state before an omnimessage cascade falls through to the next step. Default 1200; maximum 259200 (72 hours). Only meaningful inside a cascade.

payload and template are exclusive: send arbitrary content with payload, or reference a stored template by ID with template.

Response identifiers

{
  "error": false,
  "data": {
    "channel": 1,
    "transactionId": "95e3e0da-9684-4ba4-88a3-e9207ddeca05",
    "messageId": "6719b5f4-36af-4fba-b111-49ff07f4f96b"
  }
}
Field Use it for
messageId The primary handle for the message. Correlate messageStatus webhooks, query GET /edrs?messageIds=..., and quote it to support. Persist it.
transactionId Internal transaction identifier — keep it for support enquiries.

Channels

The channel field is an integer enum used across all message-related endpoints:

Code Channel Sendable via API today
1 SMS Yes
2 RCS Not yet activated
3 Viber Not yet activated
4 WhatsApp Not yet activated
6 WeChat Not yet activated
7 Email Not yet activated
8 Telegram Gateway Yes
10 Push Not yet activated
11 TTS (voice) Not yet activated
13 Mobile Push Portal only — not available via the API
14 FlashCall Portal only — not available via the API

Currently SMS (1) and Telegram Gateway (8) are activated for sending. The other channels are documented for integration preview; contact your account manager about activation for your account. Call GET /channels to discover the channel types exposed to your account.

SMS content and segmentation

For SMS the payload is a single field:

{ "text": "Your message text" }
  • One segment holds 160 characters with GSM 7-bit encoding, or 70 characters with Unicode encoding (any character outside the GSM alphabet — e.g. Cyrillic, emoji — switches the whole message to Unicode).
  • Segmentation is done by the platform (longMessageMode: split, split_sar, single_id_split, payload, or cut), not by the mobile operator. The default is cut: text longer than 140 bytes is truncated. Automatic splitting happens only when you set a split mode. Each segment that is sent is billed. See Balance & pricing.
  • There is no pre-send moderation of free-form SMS text, but operators may apply their own content filters per country.
  • For OTP messages set isOtp: true so the code is masked in logs and EDR reports.

Omnimessages (fallback cascades)

POST /omnimessages sends a multi-channel fallback cascade to one contact — for example Telegram Gateway first, SMS as the fallback. It is not a batch endpoint; for many recipients use multiple calls or the Broadcast API.

  • messages[] is an ordered list of steps, each with its own channel, senderId, payload/template, successOn, and timeout. Each step may override contact (e.g. switch to an email address for an Email step).
  • A step succeeds when it reaches its successOn state (sent / delivered / seen) within timeout. On success the cascade stops — later steps are neither attempted nor billed.
  • If the platform receives an immediate negative status (unreachable, rejected), it skips the timeout and falls through to the next step at once.
  • Optional cooldown (0–86400 seconds) blocks further cascades to the same contact if every step fails.
  • The response carries one omniTransactionId for the whole cascade plus a messageId per step. omniTransactionId is echoed in every status webhook; use the per-step messageIds for EDR lookups.

Lifecycle

POST /messages → 202 accepted → sent → delivered → (displayed)
                                  └──→ failed / undeliverable

Full state machine and status semantics: Delivery statuses.

See the API Reference: POST /messages, POST /omnimessages, GET /channels, GET /edrs, GET /templates.