Skip to main content
POST
Create a studio-scoped guest checkout link

Authorizations

Authorization
string
header
required

Batch Relay scoped API key or an anonymous Test Mode session. Scope names document required capabilities. Anonymous sessions are sandbox-only and do not authorize studio, event, billing, or Live Mode operations.

Headers

Idempotency-Key
string
required
Required string length: 1 - 200
X-BatchRelay-Client-Surface
string

Untrusted optional analytics hint naming the calling client surface. It never affects authorization, routing, pricing, or behavior.

Required string length: 1 - 100
X-BatchRelay-Client-Version
string

Untrusted optional analytics hint naming the calling client version. It never affects authorization, routing, pricing, or behavior.

Required string length: 1 - 100
X-BatchRelay-Invocation-Mode
string

Untrusted optional analytics hint naming the invocation mode. It never affects authorization, routing, pricing, or behavior.

Required string length: 1 - 100

Path Parameters

studio_id
string
required

Stable public studio ID beginning with stu_. The API never selects a studio implicitly; a local CLI profile name is not a studio ID.

Required string length: 5 - 256
Pattern: ^stu_[A-Za-z0-9_-]+$

Body

application/json

The server resolves current published retail pricing and freezes the non-customizable quote. Client price, tax, payment, provider, recipient-contact, and token fields are not accepted.

event_id
string
required
Required string length: 1 - 240
recipient
object
required
sellable
object
required
customizable
boolean
default:false
expires_at
string<date-time>

Must be in the future and no later than seven days after creation.

promotion
object

Optional server-owned selector. When omitted, the active automatic storewide offer is selected. An invalid explicit selector returns an error and never falls back to a full-price URL.

Response

Created or idempotently replayed checkout link. An explicitly sandboxed creation includes preview_status=non_payable and no URL; an explicitly production creation is payable and returns share_url only once for a new Live Mode link.

Safe lifecycle projection. It excludes the token and recipient context. Machine prepare and recover may include opaque server-owned checkout session, intent, guest-link, and promotion identifiers; payment_url is returned only by a successful Live Mode prepare or recover response.

expires_at
string<date-time>
required
id
string
required
revocable
boolean
required
status
enum<string>
required
Available options:
active,
checkout_created,
fulfilled,
revoked,
expired
checkout_intent_id
string
read-only

Opaque server-owned checkout intent identifier.

currency
string
Allowed value: "USD"
discount_cents
integer
Required range: x >= 0
gross_subtotal_cents
integer
Required range: x >= 0

Opaque server-owned guest checkout-link identifier.

net_subtotal_cents
integer
Required range: x >= 0
offer
object
payment_state
enum<string>
Available options:
not_prepared,
open,
processing,
paid,
expired,
revoked,
non_payable
payment_url
string<uri>
read-only

Private Live Mode Stripe Checkout capability. Never log or persist it.

preview_status
string

Present only in a Test Mode response. It is an explicit non-payable result, not a browser URL or checkout capability.

Allowed value: "non_payable"
promotion
object

Server-owned proof of the promotion applied to the checkout session.

share_url
string<uri>
read-only

Live Mode bearer URL, returned only once in the first successful creation response. Treat as a secret.

stripe_checkout_session_id
string
read-only

Opaque server-owned Stripe Checkout Session identifier.

subtotal_cents
integer
Required range: x >= 0