checkout

Create a checkout session for a quote.

Retries carrying the same X-Idempotency-Key attach to the existing session and return its identifiers; omitting the key deliberately creates a fresh attempt. The session expires at the quote's expiry or 24 hours after creation, whichever comes first.

post/checkout/v1/session

Request

  • Base URL
    https://api.us.junction.com
  • URL
    https://api.us.junction.com/checkout/v1/session
  • Auth
    API key in header x-vital-api-key

Headers

X-Idempotency-Keystring nullable

Request body

quote_idstring uuid required
user_idstring uuid required

Response

Successful Response

checkout_session_idstring uuid required
status'unpaid' | 'paid' | 'expired' | 'cancelled' required

ℹ️ This enum is non-exhaustive.

pay_beforestring date-time required
payment_resource_idstring nullable required

ID of the Stripe Checkout Session (cs_...) or PaymentIntent (pi_...) collecting payment. null until the payment resource is created.

order_idstring uuid nullable required
order_transaction_idstring uuid nullable required
appointment_hold_status'pending' | 'held' | 'failed' required

Public view of the checkout's PSC appointment hold. None on the snapshot means no appointment was requested. held covers both a live vendor hold and the attached appointment (appointment_id set); failed covers every way the hold ended without one (slot gone, PSC unreachable, released on expiry, cancellation, or operator request). ℹ️ This enum is non-exhaustive.

appointment_idstring uuid nullable required
payment_resource_urlstring nullable

Stripe-hosted payment page URL, for the checkout_session payment method. Returned only by the create, get and confirm endpoints while status is unpaid; always null in webhooks.

payment_resource_client_secretstring nullable

Client secret for confirming the Stripe PaymentIntent with Stripe.js, for the payment_intent payment method. Returned only by the create, get and confirm endpoints while status is unpaid; always null in webhooks.

Example response

{
  "pay_before": "2021-01-01T00:00:00Z"
}

Changes

    • info

      added the new optional request property

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status