Ga naar hoofdinhoud

Cart

A richer cart model than the public API: supports multiple item types (tickets, donations, vouchers), exposes timeout, and lets you check out directly with a known customer.

MethodPathPurpose
GET/peppered/cart/{cartId}/summaryLightweight cart summary
GET/peppered/cart/{cartId}Full cart contents
POST/peppered/cart/{cartId}Add items to the cart
DELETE/peppered/cart/{cartId}/{itemId}Remove an item
DELETE/peppered/cart/{cartId}Empty/delete the cart
POST/peppered/cart/{cartId}/checkoutCheck out (create order)

Cart summary

GET /v1/:client_name/peppered/cart/{cartId}/summary

Lightweight response — just totals, no line-level detail. Useful for header-counters.

Response

200 OK

{
"cartId": "4DSMDACyPo8wLr8vFnTVUR6HzWC5tWGi",
"timeOut": "2026-04-22T14:35:00+02:00",
"numberOfItems": 3,
"amount": 73.50
}

Get cart

GET /v1/:client_name/peppered/cart/{cartId}

Full cart with all items.

Response

200 OKCartResource:

{
"cartId": "4DSMDACyPo8wLr8vFnTVUR6HzWC5tWGi",
"timeOut": "2026-04-22T14:35:00+02:00",
"numberOfItems": 2,
"amount": 49.00,
"cartItems": [
{
"itemType": "ticket",
"itemId": "azL0bNZdD1",
"eventId": 95,
"priceId": "2ePdA8q3BN",
"priceName": "Standard",
"description": "Hamlet — Grote Zaal",
"amount": 24.50
}
]
}

Add items to cart

POST /v1/:client_name/peppered/cart/{cartId}

Adds one or more items to the cart. Body is an array — you can add multiple items in one call.

Request body

Array of items, each with:

FieldTypeRequiredDescription
priceIdstringTicket type / discount ID
rankIdintegerRank ID (seat rank in the hall)
eventIdintegerEvent ID (for ticket items)
numberOfTicketsintegerQuantity (default 1)
seatIdstringSpecific seat for reserved-seating halls
[
{ "priceId": "2ePdA8q3BN", "rankId": 42, "eventId": 95, "numberOfTickets": 2 },
{ "priceId": "donation", "rankId": 0, "amount": 5.00 }
]

Response

200 OK — updated CartResource.


Delete cart item

DELETE /v1/:client_name/peppered/cart/{cartId}/{itemId}

Remove one item from the cart. Use the itemId from the cart response.

Response

200 OK — updated cart.


Delete entire cart

DELETE /v1/:client_name/peppered/cart/{cartId}

Abandons the cart completely — reserved seats are released.

Response

200 OK — empty body.


Checkout

POST /v1/:client_name/peppered/cart/{cartId}/checkout

Converts the cart into an order for a known customer. Unlike the public order endpoint, this endpoint requires an existing customerId.

Request body

FieldTypeRequiredDescription
customerIdintegerExisting customer ID (see Customers)
paymentMethodIdintegerPayment method ID (see Payment methods)
redirectURLstringRedirect URL after payment (for methods that need it)

Response

200 OK

{
"orderId": 12345,
"orderKey": "unique-identifier",
"url": "https://payment-provider-redirect-or-null"
}

For payment methods that don't require external redirect (cash, invoice), url may be null and the order is immediately final.


CartResource fields

FieldTypeDescription
cartIdstringUnique cart ID
timeOutISO datetimeWhen reserved seats expire
numberOfItemsintegerTotal item count
amountdecimalTotal price
cartItemsarrayLine items (see below)

Cart item fields

FieldTypeDescription
itemTypestringticket, donation, voucher, or other
itemIdstringUnique line-item ID (for delete)
eventIdinteger | nullEvent ID (for ticket items)
priceIdstringDiscount / price ID
priceNamestringHuman-readable price name
descriptionstringLine description
amountdecimalPrice of this line

See also: Customers · Orders · Payment methods