Checkout

Sell tickets from your own site: hold them, take the buyer's details, then payment.

Create a checkout session

POST/api/v1/checkout/sessions

Holds the tickets, usually for 15 minutes (until expires_at), and gives back a session. Then either send the buyer to its url (hosted checkout on the company's EOS shop) or call complete with their details (your own checkout).

Permissioncheckout:write (Create checkouts)
Publishable keyWorks with one, from your allowed web addresses
Idempotency-KeyAccepted. How retries stay safe

Body (JSON)

event_idintegerRequired
The event.
itemsarray of objectsRequired
What to hold: ticket_type_id and quantity for each line.
ticket_type_idintegerRequired
A ticket type of the event.
quantityintegerRequired
How many, within the ticket type's limits.
discount_codestring
A code to apply.
metadataobject
Up to 20 string keys and values of your own.

Errors it can give

  • 404not_foundNo such object in this company.
  • 422not_on_saleThe event's tickets are not on sale (announced or cancelled), or the company is not taking orders.
  • 422unavailableA ticket type is sold out, off sale, or the quantity is outside its limits.
  • 422discount_invalidThe discount code does not work on this event.
Request
curl -X POST "https://eos.aveoevents.com/api/v1/checkout/sessions" \
  -H "Authorization: Bearer $EOS_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"event_id":41,"items":[{"ticket_type_id":9001,"quantity":2}],"metadata":{"basket":"8812"}}'
201 response
{
  "object": "checkout_session",
  "id": "cs_9f2c4e1a7b3d5f8e0a6c2b4d",
  "status": "open",
  "event_id": 41,
  "order_id": "O-7KQ2M4X",
  "url": "https://eos.aveoevents.com/acme-events/checkout-link/eyJhbGciOi...",
  "expires_at": "2026-11-20T10:30:00.000Z",
  "currency": "GBP",
  "amount_items": 50,
  "booking_fee": 1,
  "booking_fee_payer": "buyer",
  "amount_total": 51,
  "discount_code": null,
  "items": [
    {
      "ticket_type_id": 9001,
      "product_id": 812,
      "name": "General admission",
      "quantity": 2,
      "unit_price": 25,
      "total": 50,
      "price_before_discount": null
    }
  ],
  "payment": null,
  "metadata": {
    "basket": "8812"
  },
  "created_at": "2026-11-20T10:15:00.000Z"
}

Every field of the response: the checkout session object.

Get a checkout session

GET/api/v1/checkout/sessions/{id}

The session as it stands: still open, complete (the order is placed) or expired.

Permissioncheckout:write (Create checkouts)
Publishable keyWorks with one, from your allowed web addresses

Path parameters

idstringRequired
The session id.

Errors it can give

Request
curl "https://eos.aveoevents.com/api/v1/checkout/sessions/cs_9f2c4e1a7b3d5f8e0a6c2b4d" \
  -H "Authorization: Bearer $EOS_API_KEY"
200 response
{
  "object": "checkout_session",
  "id": "cs_9f2c4e1a7b3d5f8e0a6c2b4d",
  "status": "open",
  "event_id": 41,
  "order_id": "O-7KQ2M4X",
  "url": "https://eos.aveoevents.com/acme-events/checkout-link/eyJhbGciOi...",
  "expires_at": "2026-11-20T10:30:00.000Z",
  "currency": "GBP",
  "amount_items": 50,
  "booking_fee": 1,
  "booking_fee_payer": "buyer",
  "amount_total": 51,
  "discount_code": null,
  "items": [
    {
      "ticket_type_id": 9001,
      "product_id": 812,
      "name": "General admission",
      "quantity": 2,
      "unit_price": 25,
      "total": 50,
      "price_before_discount": null
    }
  ],
  "payment": null,
  "metadata": {
    "basket": "8812"
  },
  "created_at": "2026-11-20T10:15:00.000Z"
}

Every field of the response: the checkout session object.

Complete a checkout session

POST/api/v1/checkout/sessions/{id}/complete

Places the order with the buyer's details. Free orders are done and tickets are emailed. For card, the response's payment block has what Stripe's Payment Element needs (the amount is the order plus AVEO's booking fee); the order is paid and the tickets emailed as soon as Stripe confirms. Tickets paid at the door are free online, so an order of only those is done at once.

Permissioncheckout:write (Create checkouts)
Publishable keyWorks with one, from your allowed web addresses
Idempotency-KeyAccepted. How retries stay safe

Path parameters

idstringRequired
The session id.

Body (JSON)

buyerobjectRequired
Who is buying.
first_namestringRequired
First name.
last_namestringRequired
Last name.
emailstringRequired
Email.
attendeesarray of objects
One per ticket, in item order, when guests are named. Defaults to the buyer.
first_namestringRequired
First name.
last_namestringRequired
Last name.
emailstring
Email.
date_of_birthdate
YYYY-MM-DD. Required for a ticket type with an age limit; checked against the event's date and shown at the door.
payment_methodstring
card (the default and only method; pay_later is no longer offered). Ignored for free orders.card
marketingboolean
The buyer agreed to hear about future events.

Errors it can give

Request
curl -X POST "https://eos.aveoevents.com/api/v1/checkout/sessions/cs_9f2c4e1a7b3d5f8e0a6c2b4d/complete" \
  -H "Authorization: Bearer $EOS_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{"buyer":{"first_name":"Sam","last_name":"Taylor","email":"sam@example.com"},"payment_method":"card"}'
200 response
{
  "object": "checkout_session",
  "id": "cs_9f2c4e1a7b3d5f8e0a6c2b4d",
  "status": "complete",
  "event_id": 41,
  "order_id": "O-7KQ2M4X",
  "url": "https://eos.aveoevents.com/acme-events/checkout-link/eyJhbGciOi...",
  "expires_at": "2026-11-20T10:30:00.000Z",
  "currency": "GBP",
  "amount_items": 50,
  "booking_fee": 1,
  "booking_fee_payer": "buyer",
  "amount_total": 51,
  "discount_code": null,
  "items": [
    {
      "ticket_type_id": 9001,
      "product_id": 812,
      "name": "General admission",
      "quantity": 2,
      "unit_price": 25,
      "total": 50,
      "price_before_discount": null
    }
  ],
  "payment": {
    "method": "card",
    "amount": 51,
    "booking_fee": 1,
    "client_secret": "pi_3Q..._secret_...",
    "publishable_key": "pk_live_...",
    "stripe_account": "acct_1Q..."
  },
  "metadata": {
    "basket": "8812"
  },
  "created_at": "2026-11-20T10:15:00.000Z"
}

Every field of the response: the checkout session object.

Cancel a checkout session

POST/api/v1/checkout/sessions/{id}/cancel

Lets the held tickets go straight back on sale.

Permissioncheckout:write (Create checkouts)
Publishable keyWorks with one, from your allowed web addresses

Path parameters

idstringRequired
The session id.

Errors it can give

Request
curl -X POST "https://eos.aveoevents.com/api/v1/checkout/sessions/cs_9f2c4e1a7b3d5f8e0a6c2b4d/cancel" \
  -H "Authorization: Bearer $EOS_API_KEY"
200 response
{
  "object": "checkout_session",
  "id": "cs_9f2c4e1a7b3d5f8e0a6c2b4d",
  "status": "cancelled",
  "event_id": 41,
  "order_id": "O-7KQ2M4X",
  "url": "https://eos.aveoevents.com/acme-events/checkout-link/eyJhbGciOi...",
  "expires_at": "2026-11-20T10:30:00.000Z",
  "currency": "GBP",
  "amount_items": 50,
  "booking_fee": 1,
  "booking_fee_payer": "buyer",
  "amount_total": 51,
  "discount_code": null,
  "items": [
    {
      "ticket_type_id": 9001,
      "product_id": 812,
      "name": "General admission",
      "quantity": 2,
      "unit_price": 25,
      "total": 50,
      "price_before_discount": null
    }
  ],
  "payment": null,
  "metadata": {
    "basket": "8812"
  },
  "created_at": "2026-11-20T10:15:00.000Z"
}

Every field of the response: the checkout session object.