POST
/eventsCreate an event
Creates a new event with a name and an optional payload schema. The name cannot start with the reserved resend: prefix, and schema fields support the types string, number, boolean, and date.
- IdempotentThe SDK sends
Idempotency-Key, so a retried request is only applied once.
Event name and optional flat payload schema.
namestringrequired
The name of the event. Cannot start with the reserved `resend:` prefix.
schemaobjectoptional
An optional flat key/type map defining the event payload schema. Supported types are `string`, `number`, `boolean`, and `date`.
201Returns an object containing the created event's UUID in `id` and the response object type.
objectstringoptional
Type of the response object.
idstringoptional
The ID of the created event.
Error handling
name is required and cannot start with the reserved resend: prefix. If provided, schema must be a flat key/type map using string, number, boolean, or date values.