Skip to main content

CheckoutSessionRequest

allowedPaymentMethodsstring[]nullable
amountinteger<int64>nullable

Base amount in minor currency units. Required when lineItems is empty. With lineItems, omit it to use their subtotal or send exactly that subtotal; discounts, shipping, and tax can change the final payable total.

Possible values: >= 1 and <= 99999999

cancelUrlstringnullable
captureMethodstringnullable
createSubscription objectnullable
endDatestring<date>nullable
intervalCheckoutSubscriptionIntervalrequired

Possible values: [DAILY, WEEKLY, MONTHLY, QUARTERLY, YEARLY]

intervalCountinteger<int32>nullable

Possible values: >= 1

maxCyclesinteger<int32>nullable

Possible values: >= 1

metadata objectnullable
property name*anynullable
planNamestringrequired

Possible values: non-empty

startDatestring<date>required
webhookUrlstringnullable
currencystringnullable
customerBinding objectnullable
externalRefstringrequired

Possible values: Value must match regular expression [0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}

externalRefSourcestring

Possible values: Value must match regular expression PEAK_POS

customerEmailstring<email>nullable
customerPrefill objectnullable
billingCitystringnullable

Possible values: <= 255 characters

billingCountrystringnullable

Possible values: Value must match regular expression ^[A-Z]{2}$

billingStatestringnullable

Possible values: <= 50 characters

billingStreetstringnullable

Possible values: <= 1024 characters

billingZipstringnullable

Possible values: <= 20 characters

emailstringnullable

Possible values: <= 255 characters

fullNamestringnullable

Possible values: <= 512 characters

phonestringnullable

Possible values: <= 50 characters

descriptionstringnullable
expiresIninteger<int64>nullable

Possible values: >= 60

lineItems object[]nullable
  • Array [
  • categoryCodestringnullable

    Tax-provider category code, matched against configured category tax rules.

    descriptionstringnullable
    namestringnullable
    priceIdstringnullable

    Catalog price identifier. The line is charged and stored at this price's unitAmount.

    quantityinteger<int32>

    Possible values: >= 1

    taxAmountinteger<int64>nullable

    Exact line tax in minor units, required only in PRECOMPUTED mode. Not a per-unit amount.

    Possible values: >= 0

    taxablebooleannullable

    Whether a custom line is taxable. Catalog tax treatment is authoritative.

    unitPriceinteger<int64>nullable

    Unit price in minor currency units for a custom line without priceId. Must not be sent with priceId; catalog lines are charged at the catalog price.

    Possible values: >= 0

  • ]
  • locationIdstringnullable

    Possible values: <= 128 characters

    merchantIdstringnullable

    Possible values: <= 128 characters

    merchantReferencestringnullable

    Permanent idempotency identity for immutable, amount-only PRECOMPUTED commerce checkouts.

    Possible values: Value must match regular expression [A-Za-z0-9_-]{16,64}

    metadata objectnullable
    property name*anynullable
    promotionCodestringnullable

    Possible values: <= 50 characters

    promotionCodesstring[]nullable
    saveCardbooleannullable
    shippingAddressCollection objectnullable
    allowedCountriesstring[]nullable
    enabledboolean
    shippingOptions object[]nullable
  • Array [
  • amountinteger<int64>required

    Possible values: >= 0

    estimatedDaysMaxinteger<int32>nullable
    estimatedDaysMininteger<int32>nullable
    idstringrequired

    Possible values: non-empty

    namestringrequired

    Possible values: non-empty

  • ]
  • successUrlstringnullable
    taxModeCheckoutTaxMode

    Possible values: [AUTOMATIC, PRECOMPUTED]

    totalTaxinteger<int64>nullable

    Required in PRECOMPUTED mode: exact additional tax in minor units, equal to the sum of line taxAmount values. For an amount-only collection of an already tax-inclusive receivable, send 0; amount is then the entire payable balance.

    Possible values: >= 0

    webhookUrlstringnullable
    CheckoutSessionRequest
    {
    "allowedPaymentMethods": [
    "string"
    ],
    "amount": 0,
    "cancelUrl": "string",
    "captureMethod": "string",
    "createSubscription": {
    "endDate": "2024-07-29",
    "interval": "DAILY",
    "intervalCount": 0,
    "maxCycles": 0,
    "metadata": {},
    "planName": "string",
    "startDate": "2024-07-29",
    "webhookUrl": "string"
    },
    "currency": "string",
    "customerBinding": {
    "externalRef": "string",
    "externalRefSource": "string"
    },
    "customerEmail": "[email protected]",
    "customerPrefill": {
    "billingCity": "string",
    "billingCountry": "string",
    "billingState": "string",
    "billingStreet": "string",
    "billingZip": "string",
    "email": "string",
    "fullName": "string",
    "phone": "string"
    },
    "description": "string",
    "expiresIn": 0,
    "lineItems": [
    {
    "categoryCode": "string",
    "description": "string",
    "name": "string",
    "priceId": "string",
    "quantity": 0,
    "taxAmount": 0,
    "taxable": true,
    "unitPrice": 0
    }
    ],
    "locationId": "string",
    "merchantId": "string",
    "merchantReference": "string",
    "metadata": {},
    "promotionCode": "string",
    "promotionCodes": [
    "string"
    ],
    "saveCard": true,
    "shippingAddressCollection": {
    "allowedCountries": [
    "string"
    ],
    "enabled": true
    },
    "shippingOptions": [
    {
    "amount": 0,
    "estimatedDaysMax": 0,
    "estimatedDaysMin": 0,
    "id": "string",
    "name": "string"
    }
    ],
    "successUrl": "string",
    "taxMode": "AUTOMATIC",
    "totalTax": 0,
    "webhookUrl": "string"
    }