Senlo
API reference

Send a triggered email

POST
/api/triggered

Queues one email from a trigger. The trigger must belong to the workspace the API key is scoped to, and must be a triggered (API) trigger.

A 200 means the email is queued, not that the provider accepted it. Delivery status shows up in the trigger's delivery log.

locale picks the trigger's template for that locale when one is set, otherwise the trigger's default template. The match is exact and case-sensitive.

Authorization

bearerAuth
headerAuthorizationBearer <token>

An API key from Workspace → API Keys, starting with snl_.

Request Body

application/json
  1. body
id?|

Trigger id. Either id or campaignId is required; id wins if both are sent.

campaignId?|Deprecated

Older name of id, still accepted.

to*string

The recipient. One address per request.

Formatemail
data?

Values for the template's merge tags, e.g. { "order": { "total": 42 } } for {{order.total}}.

locale?string

Picks the trigger's template for this locale (e.g. en, de). Exact, case-sensitive match.

subject?string

Replaces the template's subject for this send. Merge tags are resolved in it.

Response Body

The email is queued.

application/json
  1. response
success*boolean
message*string
Example Request
curl -X POST 'https://senlo.io/api/triggered' \  -H 'Content-Type: application/json' \  -d '{  "id": 12,  "to": "customer@example.com",  "locale": "en",  "data": {    "order": {      "number": "A-1049",      "total": "42.00"    }  }}'
Example Response
{  "success": true,  "message": "Email queued successfully"}