Docs

Create a checkout handoff

Create a stateless checkout seed and return 200 with an absolute /<lang>/booking?seed=<token> URL on the hosted checkout origin of this channel. lang is the web-store route locale: the applied locale's primary subtag when supported by web-store src/i18n-config.ts, otherwise its defaultLocale. The seed loc claim retains the applied locale derived from the validated Buchung-Locale header. Only checkout.createHandoff requires a supported Buchung-Locale: absence or malformed values return 400 validation_failed, and well-formed unsupported values return 400 locale_not_supported with details naming the requested and supported locales. Nothing is persisted. The signed seed carries SKUs and quantities only, never prices, and is valid 15 minutes; a second redemption is not guaranteed. expiresAt is seed validity only, not a reservation, a price freeze or a quote deadline. Listed prices are for display only; checkout revalidates price and availability. This creates no booking and reserves no capacity. Empty or malformed bodies return 400 validation_failed; foreign or non-offerable SKUs reject the entire request with 404 not_found and required per-item details. Sold-out SKUs return 200 with sold_out_at_handoff warnings. No verified storefront domain returns 409 storefront_domain_missing. A missing checkout signing key closes the API mount with 404 not_found in the shared error envelope and an api_misconfigured log line (R23); configuration errors never return 500 internal_error. Machine credentials never authorize storefront checkout handoffs. The rate limiter is client-scoped. Host caps storefront POST request bodies at 16 KiB before parsing.

Early access. Use the API base, channel key and allowed origins supplied by Buchung before running examples. Interactive API requests are disabled here.

POST
/v1/checkout/handoff

Create a stateless checkout seed and return 200 with an absolute //booking?seed= URL on the hosted checkout origin of this channel. lang is the web-store route locale: the applied locale's primary subtag when supported by web-store src/i18n-config.ts, otherwise its defaultLocale. The seed loc claim retains the applied locale derived from the validated Buchung-Locale header. Only checkout.createHandoff requires a supported Buchung-Locale: absence or malformed values return 400 validation_failed, and well-formed unsupported values return 400 locale_not_supported with details naming the requested and supported locales. Nothing is persisted. The signed seed carries SKUs and quantities only, never prices, and is valid 15 minutes; a second redemption is not guaranteed. expiresAt is seed validity only, not a reservation, a price freeze or a quote deadline. Listed prices are for display only; checkout revalidates price and availability. This creates no booking and reserves no capacity. Empty or malformed bodies return 400 validation_failed; foreign or non-offerable SKUs reject the entire request with 404 not_found and required per-item details. Sold-out SKUs return 200 with sold_out_at_handoff warnings. No verified storefront domain returns 409 storefront_domain_missing. A missing checkout signing key closes the API mount with 404 not_found in the shared error envelope and an api_misconfigured log line (R23); configuration errors never return 500 internal_error. Machine credentials never authorize storefront checkout handoffs. The rate limiter is client-scoped. Host caps storefront POST request bodies at 16 KiB before parsing.

Authorization

channelKey
headerX-Buchung-Channel-Key<token>

Required channel key for every storefront operation, including site.get. On every storefront read, Buchung-Locale is optional: omission or a well-formed but unsupported value applies the operator's default locale; a supported explicit value selects that exact locale, Content-Language always reports the applied locale, and Buchung-Locale-Fallback reports the requested value only when unsupported; malformed values return 400 validation_failed. Only checkout.createHandoff requires a supported Buchung-Locale: absence or malformed values return 400 validation_failed, and well-formed unsupported values return 400 locale_not_supported with details naming the requested and supported locales. Start with site.get to discover the operator's locales.

Header Parameters

Buchung-Locale*string

On every storefront read, Buchung-Locale is optional: omission or a well-formed but unsupported value applies the operator's default locale; a supported explicit value selects that exact locale, Content-Language always reports the applied locale, and Buchung-Locale-Fallback reports the requested value only when unsupported; malformed values return 400 validation_failed. Only checkout.createHandoff requires a supported Buchung-Locale: absence or malformed values return 400 validation_failed, and well-formed unsupported values return 400 locale_not_supported with details naming the requested and supported locales. Start with site.get to discover the operator's locales. See Language for syntax and normalization.

Match^[A-Za-z]{2,3}(-[A-Za-z0-9]{1,8}){0,3}$
Lengthlength <= 35

Request Body

application/json
  1. body

Create a stateless checkout seed using the validated Buchung-Locale header, with 1–10 lines and 1–10 booking units per line, matching the hosted storefront maximum. SKUs and handles are 1–128 ASCII characters because the hosted seed cookie carrier assumes ASCII. Quantity counts units of the selected sellable, never necessarily people. Nothing is persisted. The signed seed carries SKUs and quantities only, never prices, and is valid 15 minutes; a second redemption is not guaranteed. No capacity is reserved. Host caps the body at 16 KiB before parsing.

lines*array<>
Items1 <= items <= 10

Response Body

Stateless hosted-checkout handoff; nothing is persisted. The signed seed carries SKUs and quantities only, never prices, and is valid 15 minutes; a second redemption is not guaranteed. Listed prices are for display only. Checkout revalidates price and availability; no capacity is reserved and prices are not frozen. A sold-out SKU remains a successful handoff with a sold_out_at_handoff warning.

application/json
  1. response

Stateless hosted-checkout handoff; nothing is persisted. The signed seed carries SKUs and quantities only, never prices, and is valid 15 minutes; a second redemption is not guaranteed. Listed prices are for display only. Checkout revalidates price and availability; no capacity is reserved and prices are not frozen. A sold-out SKU remains a successful handoff with a sold_out_at_handoff warning.

locale*Language

Matched case-insensitively against the operator's supported locale codes and normalized to the stored code. On every storefront read, Buchung-Locale is optional: omission or a well-formed but unsupported value applies the operator's default locale; a supported explicit value selects that exact locale, Content-Language always reports the applied locale, and Buchung-Locale-Fallback reports the requested value only when unsupported; malformed values return 400 validation_failed. Only checkout.createHandoff requires a supported Buchung-Locale: absence or malformed values return 400 validation_failed, and well-formed unsupported values return 400 locale_not_supported with details naming the requested and supported locales. Start with site.get to discover the operator's locales. Accepted locale codes form a closed set per operator, discovered from Site.locales; syntactically valid codes do not imply support. Management uses explicit locales without fallback; unsupported locales return 400 validation_failed.

Match^[A-Za-z]{2,3}(-[A-Za-z0-9]{1,8}){0,3}$
Lengthlength <= 35
url*string

Absolute URL on the hosted checkout origin of this channel, with path and query //booking?seed=, where lang is the web-store route locale: the applied locale's primary subtag when supported by the web-store route locale configuration, otherwise that configuration's defaultLocale. The seed loc claim retains the applied locale. The supported route locale list comes from web-store src/i18n-config.ts; it is not the operator locale list. The signed seed carries SKUs and quantities only, never prices, and is valid 15 minutes; a second redemption is not guaranteed.

Match^[Hh][Tt][Tt][Pp][Ss]?:\/\/\S+$
Formaturi
expiresAt*string

Seed validity only: 15 minutes from issuance. It is not a reservation, a price freeze or a quote deadline.

Match^\d{4}-\d{2}-\d{2}T(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z|[+-](?:[01]\d|2[0-3]):[0-5]\d)$
Formatdate-time
lines*array<>
Items1 <= items <= 10
warnings*array<>
Example Request
curl -X POST 'https://api.buchungapp.com/v1/checkout/handoff' \  -H 'Buchung-Locale: string' \  -H 'Content-Type: application/json' \  -d '{  "lines": [    {      "sku": "string",      "quantity": 1    }  ]}'
Example Response
{  "locale": "string",  "url": "http://example.com",  "expiresAt": "2019-08-24T14:15:22Z",  "lines": [    {      "sku": "string",      "quantity": 1,      "listedTotal": {        "amount": 0,        "currency": "string",        "amountBeforeDiscounts": 0,        "hasPromotion": true      },      "listedUnitPrice": {        "amount": 0,        "currency": "string",        "amountBeforeDiscounts": 0,        "hasPromotion": true      }    }  ],  "warnings": [    {      "sku": "string",      "code": "sold_out_at_handoff"    }  ]}