POST/dispatch/{bucketId}

Send a dispatch message

Параметры запроса

bucketIdstring
Обязательный

Project (bucket) identifier

x-api-keystring
Обязательный

API key passed in the request header for authentication

Тело запроса

CreateDispatchRequest
subjectstring
Обязательный

Message subject line

messageTypenumber
Обязательный

Delivery channel: 1 = Email, 2 = SMS, 3 = Push, 4 = Messenger

recipientsstring[]
Обязательный

Array of recipient addresses (email addresses, phone numbers, or channel-specific IDs)

htmlBase64Bodystring
Необязательный

Base64-encoded HTML message body. At least one of htmlBase64Body or plainBase64Body is required

plainBase64Bodystring
Необязательный

Base64-encoded plain-text message body. At least one of htmlBase64Body or plainBase64Body is required

providerIdstring
Необязательный

ID of the specific dispatch provider to use. If omitted, the matching dispatch rule is resolved automatically for the bucket

delaynumber
Необязательный

Delivery delay in seconds

envstring
Необязательный

Environment tag (e.g. production, staging)

timeStampnumber
Необязательный

Unix timestamp of the event (milliseconds). Defaults to server time if omitted

appNamestring
Необязательный

Name of the sending application. Defaults to "unknown" if omitted

appVersionstring
Необязательный

Version of the sending application

correlationIdstring
Необязательный

Caller-supplied correlation ID for distributed tracing

tagsstring[]
Необязательный

Arbitrary string tags attached to the message for filtering

userAgentstring
Необязательный

User-agent string of the originating client

ipstring
Необязательный

IP address of the originating client

runtimenumber
Необязательный

Runtime identifier byte

runtimeVersionstring
Необязательный

Runtime version string

Ответы

201Message accepted and enqueued for delivery.

тип: ApiResponse<bool>

successbooleanAlways true on success
resultbooleantrue when the message was successfully enqueued
errorsErrorDetail[]Empty on success
400Validation failed — subject, message body, recipients, or messageType missing; or no dispatch rule found for the bucket.

тип: ApiResponse<T>

isValidbooleanAlways false
validationErrorsValidationError[]List of validation failures
namestringField that failed validation
attemptedValueobjectValue that was submitted
messagestringHuman-readable validation message
401Unauthorized — API key is missing or invalid.
500Unexpected server error.

тип: ApiResponse<T>

successbooleanAlways false
errorsErrorDetail[]Server-side errors
correlationIdstringTrace ID
messagestringError message
stackstringStack trace (non-production only)

Оставаясь на сайте, Вы даете свое согласие на использование файлов cookie