tired/api/docs/getting-started

docs · read in 5 min

getting started — your first curl

two minutes, one curl. we'll create an event, print a ticket, and listen for a webhook. you'll need a free account and an api key.

1. get an api key

sign in at studio.tired.events and open settings → api keys. create a test key (they start with sk_test_) — no billing implications, sandbox data.

note

test vs. live. sk_test_ keys hit sandbox data; nothing charges, nothing emails. sk_live_ keys are real. we colour them differently in studio so you don't paste the wrong one into a cron at 2am.

2. create an event

curl · create event
curl -X POST https://api.tired.events/v2/events \
  -H "authorization: bearer sk_test_…" \
  -H "content-type: application/json" \
  -d '{
    "title": "sade yancey, late set",
    "venue_id": "ven_01HX…",
    "doors_at": "2026-05-17T20:00-04:00",
    "tickets": [
      { "name": "general admission", "price_cents": 2500, "quantity": 120 }
    ]
  }'

you get back an event object with an id, a public url, and the ticket tiers. the event is in draft — flip status to on_sale when you're ready.

3. make a sale

for this walkthrough we'll fake one with the sandbox. in production, checkout happens at tired.events/e/<slug> or in your embedded checkout.

curl · sandbox order
curl -X POST https://api.tired.events/v2/sandbox/orders \
  -H "authorization: bearer sk_test_…" \
  -d '{ "event_id": "evt_…", "ticket_tier_id": "tkt_…", "quantity": 2 }'

the response includes an order with two tickets, each with a scan token and a wallet pass url.

4. listen for a webhook

in studio → webhooks, add an endpoint: https://your-app.dev/tired-hook. subscribe to order.created. we'll retry with backoff for 72 hours if you return non-2xx.

POST /tired-hook
x-tired-signature: t=1747...,v1=...
content-type: application/json

{
  "type": "order.created",
  "created_at": "2026-05-17T14:02:11Z",
  "data": {
    "order": { "id": "ord_…", "total_cents": 5400, "buyer_email": "…" },
    "tickets": [ { "id": "tik_…", "tier": "general admission" }, ... ]
  }
}

verify the x-tired-signature header with your endpoint secret before trusting anything. the webhooks page has code for node, python, ruby, and go.

5. next