POST
/
api
/
v1
/
events
curl --request POST \
  --url https://api.trigger.dev/api/v1/events \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "event": {
    "name": "<string>",
    "payload": {},
    "context": {},
    "id": "<string>",
    "timestamp": "2023-11-07T05:31:56Z",
    "source": "<string>"
  },
  "options": {
    "deliverAt": "2023-11-07T05:31:56Z",
    "deliverAfter": 123,
    "accountId": "<string>"
  }
}'
{
  "id": "<string>",
  "name": "<string>",
  "payload": {},
  "context": {},
  "timestamp": "2023-11-07T05:31:56Z",
  "deliverAt": "2023-11-07T05:31:56Z",
  "deliveredAt": "2023-11-07T05:31:56Z",
  "cancelledAt": "2023-11-07T05:31:56Z"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
event
object
options
object

Response

200
application/json
Event successfully sent
id
string

The ID of the event that was sent.

name
string

The name of the event that was sent.

payload
object

A JSON object that represents the deserialized payload or context.

context
object

The context of the event that was sent. Null if no context was set.

timestamp
string

The timestamp of the event that was sent.

deliverAt
string | null

The timestamp when the event will be delivered. Null if not applicable.

deliveredAt
string | null

The timestamp when the event was delivered. Null if not applicable.

cancelledAt
string | null

The timestamp when the event was cancelled. Null if the event wasn't cancelled.