Skip to main content

Documentation Index

Fetch the complete documentation index at: https://alphabet-06152314.mintlify.app/llms.txt

Use this file to discover all available pages before exploring further.

This endpoint dispatches a subject and body through any combination of enabled channels simultaneously. You can target Email, SMS, Push, InApp, and Webhook in a single request — the API fans the message out to each specified channel concurrently and returns a per-channel result. The endpoint requires the AdminOnly authorization policy.

Endpoint

POST /api/v1/communications/send
Authorization: AdminOnly

Request body

subject
string
required
The message subject line. Used as the email subject for the Email channel and as a title for InApp and Push notifications.
body
string
required
The message body text. Set isHtml to true to render this as HTML in email clients.
channels
string[]
required
One or more channels to send through. Valid values: Email, Sms, Push, InApp, Webhook.
emailAddress
string
Recipient email address. Required when Email is included in channels.
phoneNumber
string
Recipient phone number in E.164 format (e.g. +97455555555). Required when Sms is included in channels.
userId
string
The GUID or string identifier of the target user. Required when InApp is included in channels.
pushToken
string
Device push token for the recipient. Required when Push is included in channels.
webhookUrl
string
The URL to POST the message payload to. Required when Webhook is included in channels.
isHtml
boolean
When true, the body field is rendered as HTML in email clients. Has no effect on non-email channels. Defaults to false.

Response

200 OK — returns CommunicationBatchResponseDto.
results
object[]
One entry per channel included in the request.
400 Bad Request — returns ProblemDetails when dispatch failed entirely or the request body is invalid.
A 200 OK response does not mean every channel succeeded. Check each item in results — a channel-level failure is reported there while the overall HTTP status remains 200.

Example

{
  "subject": "System maintenance",
  "body": "A scheduled maintenance window starts at 22:00 UTC.",
  "channels": ["Email", "Sms", "InApp"],
  "emailAddress": "user@example.com",
  "phoneNumber": "+97455555555",
  "userId": "3f45ef0f-39d1-4d65-8eaa-5db7c0b8f763",
  "pushToken": null,
  "webhookUrl": null,
  "isHtml": false
}
curl -X POST "https://api.example.com/api/v1/communications/send" \
  -H "Authorization: Bearer <admin-token>" \
  -H "Content-Type: application/json" \
  -d '{
    "subject": "System maintenance",
    "body": "A scheduled maintenance window starts at 22:00 UTC.",
    "channels": ["Email", "Sms", "InApp"],
    "emailAddress": "user@example.com",
    "phoneNumber": "+97455555555",
    "userId": "3f45ef0f-39d1-4d65-8eaa-5db7c0b8f763",
    "pushToken": null,
    "webhookUrl": null,
    "isHtml": false
  }'

Example response

{
  "results": [
    { "channel": "Email", "success": true, "error": null },
    { "channel": "Sms", "success": true, "error": null },
    { "channel": "InApp", "success": false, "error": "User not found" }
  ]
}