Channels and recipients
The channels you can send on, recipient types and how providers are chosen.
Channels
The channel field of a message is a lowercase channel code:
| Channel | Recipients | Attachments | OTP | Notes |
|---|---|---|---|---|
email | Email | Yes | No | subject is the email subject. |
sms | Phone | No | Yes | See OTP messages. |
push | DeviceToken only | No | No | Provider-specific options go in data. |
An unknown channel answers 404 message.channel_not_found. A channel you have not set up in the project (no active
provider in its chain) answers 422 message.no_active_provider.
Recipients
Each message has 1 to 10,000 recipients (the platform's default limit):
{ "type": "Email", "value": "jane@example.com", "variables": { "firstName": "Jane" } }Prop
Type
On the push channel every recipient must be a DeviceToken (422 message.push_requires_device_tokens).
Duplicates
Recipients are de-duplicated before dispatches are created, so each address receives the message once:
Emailis compared case-insensitively and trimmed (Jane@Example.com=jane@example.com).Phoneis compared by its digits and+only (+90 (532) 123 45 67=+905321234567).DeviceTokenis trimmed.
The first occurrence wins (including its variables), and recipientCount in the response is the number of unique
recipients.
Duplicates count towards the limit
The 10,000 limit is checked on the recipients array as you send it, before duplicates are removed. A request with
10,001 entries is rejected with 400 validation.failed (errors["Message.Recipients"]) even if fewer addresses are
unique. Remove duplicates on your side before sending large lists.
Large recipient lists
- The API answers
202only after every recipient and dispatch is stored, so a request with thousands of recipients takes a few seconds (about 7 seconds for 10,000 in our tests). Give your HTTP client a timeout of at least 30 seconds and retry with the same idempotency key. - The request body may be up to 30 MB; a larger body answers
413without acode. 10,000 email recipients take about 0.8 MB, so you only get close to it with large per-recipientvariables. - For more than 10,000 recipients, split the list into several messages.
Providers and the provider chain
You never pick a provider in the request. Each project has a provider chain per channel, an ordered list of provider registrations configured in the dashboard (Providers and Provider chains). The platform delivers through the first healthy provider of the chain and moves on to the next one when a provider is failing, so a single provider outage does not stop your messages.
Provider credentials are stored by the platform; your application never sees them.