---
title: "Events"
description: "Emit your own custom events (e.g. `cart.updated`) onto the Unitpost event bus from your backend. Subscribed webhook endpoints receive them, and they can trigger automations."
url: https://www.unitpost.com/docs/api/events
section: API reference
updated: 2026-12-01
---
# Events

## Events

> Emit your own custom events (e.g. `cart.updated`) onto the Unitpost event bus from your backend. Subscribed webhook endpoints receive them, and they can trigger automations.

Full schemas: [OpenAPI 3.1](https://www.unitpost.com/api/v1/openapi.json). HTML reference: https://www.unitpost.com/docs/automations#events.

## Operations

### `POST /api/v1/events`

Emit a custom event

Send a custom event from your backend onto the Unitpost event bus — e.g. `cart.updated` or `order.completed`. Event names are your own bare, lowercase dotted identifiers (reserved platform prefixes like `email.` or `contact.` are rejected); deliveries carry `source: "customer"` so they're always distinguishable from built-in platform events. Link the event to a contact with `email` and/or `contact_id`, and pass an `idempotency_key` to make retried requests emit exactly once. Webhook endpoints subscribed to the event name receive it (see [Create a webhook endpoint](https://www.unitpost.com/docs/platform/post-webhooks)), and it can trigger automations. New event names are registered to your workspace vocabulary automatically on first use.

An event starts a run in every live automation whose custom-event trigger names it, resumes runs waiting for it, and can meet a goal. Each automation's policy decides who starts: one live run per person at a time by default (`maxConcurrentRunsPerSubject`; a journey that tells runs apart by the event's own data allows up to 10), its re-entry rule, and `no_consent`: no run starts for a person every message of the journey would skip for consent, and nothing is billed (`guard_trips.no_consent` in the stats). So it can send: emit a test event only when that is what you want. An `email` no contact has becomes a contact when a live automation that needs one starts from the event (subscribed, its address's consent source `event`, no topic choices, counted against the plan's contacts); `create_contact: false` opts out and the answer's `warnings` says so. At the contact limit nothing is made and no run starts. Requires the `events:emit` capability.

Reference: https://www.unitpost.com/docs/automations/post-events ([Markdown](https://www.unitpost.com/docs/automations/post-events.md))

### `GET /api/v1/events/definitions`

List event definitions

The custom events your backend has sent: each name, when it was last seen, and the top-level payload keys seen with it (read as `event.data.<key>`; keys and types only, never values). Build a custom-event trigger or an `event.data` condition from it instead of guessing. The whole vocabulary comes back in one page (at most 500 names), most recently seen first. Requires the `automations:read` capability.

Reference: https://www.unitpost.com/docs/automations/get-events-definitions ([Markdown](https://www.unitpost.com/docs/automations/get-events-definitions.md))

## Related

- [Automations](https://www.unitpost.com/docs/api/automations): Event-driven journeys as versioned JSON graphs: create a draft (blank, from a blueprint, or with a full definition), validate it, publish it, and read the per-run step ledger. Ids are `atm_…` (automation) and `run_…` (run). Build in this order: `GET /automations/catalog` → `GET /automations/blueprints` → `GET /events/definitions` → `POST /automations` → `POST /automations/{id}/validate` → `POST /automations/{id}/simulate` → `POST /automations/{id}/publish`. Publishing, resuming, enrolling, retrying and skipping a wait can send, and need `automations:publish`.
- [SMS](https://www.unitpost.com/docs/api/sms): Send transactional and marketing SMS, and track each message's delivery lifecycle. Marketing sends require recipient consent and honor recipient-local quiet hours. Included on paid plans: on the free plan, `POST /sms` returns `403` with `limit_reached` and `feature_not_in_plan` on `smsChannel` in `error.details[]`. Each segment is billed from the workspace's monthly sending allowance at the recipient country's published rate.
- [SMS templates](https://www.unitpost.com/docs/api/sms-templates): Reusable plain-text SMS bodies with per-recipient `{{variables}}`. Draft → published like email templates; only published templates can be sent by an SMS campaign.
