Overview
The hooks ingest endpoint receives telemetry events from the Promptster CLI and MCP server. This is the primary path through which session data enters Promptster. The CLI handles this automatically when a candidate runspromptster start — you only need to call this endpoint directly if you are building a custom integration.
Each call to POST /v1/hooks/ingest delivers a single event. The server normalizes the event kind, upserts the session, appends the event to the timeline, and enqueues background analytics jobs.
Ingest an event
POST /v1/hooks/ingest
Authentication: X-API-Key header with a valid candidate key (PST-XXXX-XXXX).
Rate limit: 100 requests per minute per API key.
Sessions are created automatically on first event ingest. You do not need to create a session before sending events.
Event envelope
string (UUID)
required
Stable event ID. Re-posting an event with the same
id is safe — the duplicate is silently ignored (idempotent).string
required
The session this event belongs to. Sessions are created on-demand the first time a new
sessionId is seen.string (ISO-8601)
required
Event timestamp, including timezone offset (e.g.
2026-04-01T10:15:00Z).string
required
Event type. See canonical kinds below.
object
required
Metadata about where the event originated.
object
The actor that triggered the event.
object
Attribution metadata for this event.
integer
required
Schema version. Use
1.object
required
Event-specific payload. Schema requirements vary by
kind — see the table below.Responses
201— Event accepted. Returns{ ok: true, id: "<event-id>" }.200— Event was a duplicate (sameidwas already processed). Returns{ ok: true, skipped: true }.400— Invalid event envelope or strict schema validation failed for the eventkind.401— Missing or invalidX-API-Key.429— Rate limit exceeded (100 req/min per key).
Canonical event kinds
Every event you send must have akind from this list. The data payload requirements differ by kind.
For
decision_event, the following data fields are indexed in the decisions table and surfaced in the reviewer dashboard:
