Email

Send an event

POSThttps://api.smsedge.com/v2/email/events

Tells SMSEdge that something happened to a person, so an automatic email (a trigger) can start.

Use events for emails that follow something in your app, such as a signup, a paid order or a cart left without checkout. The email can wait first and check conditions, and you can change it without changing your code.

  1. Make an API campaign with the template (see Send an email).
  2. On that campaign, add a trigger: When = API event (from your backend), Event name = the name you send here, for example order_paid. Set the wait and the follow-up.
  3. Call this endpoint when the event happens. The values in data fill {{{data.key}}} in the template.
  • Triggers check for new events every minute.
  • Each event is acted on once. The same person can get the email again with a new event.
  • Send an event_id to make a retry safe: the same ID is acted on once. Send the same body with the same ID.
  • Unsubscribed, blacklisted and bounced addresses are skipped.
  • An event that no trigger listens to is kept for 90 days.

Body params (JSON)

  • eventstringrequired

    Event name (letters, digits, _ . : -, maximum 64). It must be the same as the trigger's event name.

  • emailstringrequired

    Email address of the person.

  • datastringoptional

    JSON object of key: value for {{{data.key}}} in the template. Same rules as in Send an email.

  • event_idstringoptional

    Your ID for this event (letters, digits, _ . : -, maximum 128). Without it, every call is a new event.

Responses

  • 202The event is stored. triggers = the active triggers that listen to this event name.
  • 422A parameter is missing or not valid.
  • 403Triggers are not turned on for your account. Ask your account manager.
curl -X POST "https://api.smsedge.com/v2/email/events" \
  -H "X-API-KEY: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"event":"order_paid","email":"ann@example.com"}'
{
  "success": true,
  "data": {
    "event": "order_paid",
    "event_id": "order-A-17-paid",
    "email": "ann@example.com",
    "received_at": "2026-11-30 10:15:02",
    "triggers": 1
  },
  "errors": [],
  "response": {
    "code": 202,
    "description": "Accepted",
    "date": "2026-11-30 10:15:02"
  }
}

All requests need your API key in the X-API-KEY header. See Authentication.