@usethrottle/checkout-sdk
    Preparing search index...

    Interface ThrottleCheckoutProps

    interface ThrottleCheckoutProps {
        baseUrl?: string;
        onCancelled?: () => void;
        onFailed?: (args: { code: string; message: string }) => void;
        onSucceeded?: (
            args: {
                currency?: string;
                lineItems?: SucceededLineItem[];
                orderId: string;
                paymentId: string;
                subscriptionId?: string;
                total?: number;
            },
        ) => void;
        onTelemetry?: (event: TelemetryEvent) => void;
        parentOrigin?: string;
        sessionId: string;
        theme?: BrandTheme;
    }
    Index
    baseUrl?: string

    Base URL of the deployed checkout-web app.

    onCancelled?: () => void

    Fired when the user cancels checkout.

    onFailed?: (args: { code: string; message: string }) => void

    Fired once when payment fails terminally.

    onSucceeded?: (
        args: {
            currency?: string;
            lineItems?: SucceededLineItem[];
            orderId: string;
            paymentId: string;
            subscriptionId?: string;
            total?: number;
        },
    ) => void

    Fired once when payment completes successfully. Analytics fields (total/currency/lineItems, minor units) are present when the checkout page supplied them — fire gtag/fbq purchase events with value = total / 100.

    onTelemetry?: (event: TelemetryEvent) => void

    Optional sink for all lifecycle events — pipe to Datadog / Segment / custom analytics.

    parentOrigin?: string

    Parent origin where this embed is mounted (e.g. https://shop.example.com). Must be in the merchant's allowed_origins list.

    sessionId: string

    Throttle checkout session id (cs_*). Required.

    theme?: BrandTheme

    Optional brand theming forwarded to the hosted checkout page.