Skip to main content
View as Markdown

Error Handling - Messaging

Error Handling​

Validation errors return HTTP 400. Application-level errors follow this structure:

{
"code": "ERROR_CODE",
"message": "Description of the error"
}

Bulk Message Error Codes​

ErrorMeaning
noActiveGroupsAll specified groups are inactive
noActiveGroupUsersNo active users found in any specified group
someGroupsHaveNoActiveUsersSome groups have no active users

Retry strategy: For transient errors (HTTP 5xx, timeouts), retry with exponential backoff: 1s, 2s, 4s, with jitter, up to 3 retries. For client errors (HTTP 400, noActiveGroups, noActiveGroupUsers, validation errors), fix the request before retrying — these will not resolve on their own. For async operations (message delivery tracking), poll with increasing intervals (5s, 10s, 30s) rather than tight loops.