1. Checkout APIs
Salla Platform Docs
  • Overview
  • Authentication
  • Key Concepts
  • Usage Flows
  • Cart
    • Save guest cart data
      POST
    • Generate cart
      POST
    • Get cart
      GET
    • Assign cart to Customer
      POST
    • Apply cart coupon
      POST
    • Remove cart coupon
      DELETE
  • Cart Items
    • Add cart item
      POST
    • Update cart item
      PATCH
    • Delete cart item
      DELETE
  • Schemas
    • SuccessEnvelope
    • GuestDataRequest
    • GuestData
    • Error
    • Money
    • CartTotals
    • TotalLineItem
    • CartItem
    • AssignShippingRequest
    • CartItemsRequest
    • ProductIdentifier
    • CartItemEntry
    • RemoveItemsRequest
    • BadRequest
    • Unauthorized
    • Forbidden
    • NotFound
    • ValidationError
    • Currency
    • AmountLine
    • CartScope
    • CartFeatures
    • CartAmounts
    • CartDiscountEntry
    • CartOptionEntry
    • Cart
    • CartShipping
    • CartItemCreateRequest
    • CartItemUpdateRequest
    • ApplyCouponRequest
    • ErrorEnvelope
    • CartItemOptionInput
    • ErrorObject
    • GenerateCartRequest
Merchant
Merchant
  • Merchant API
  • Embedded SDK
  • Salla OAuth 2.0
Storefront
Storefront
  • Twilight Engine
  • Twilight SDK
  • Web Components
  • Ecommerce Events
  • Component Bundle
  • Checkout APIs
  • Change Log
App Functions
Partner APIs
Partner APIs
  • App API
  • Shipments & Fulfillment APIs
  • Salla AWB
  • Recurring Payments API
  • Billing System Salla partners
  • Communication Apps
Dev Tools
Dev Tools
  • Partners Agent Kit
  • Salla Apps Playbook
  • Salla CLI
Merchant
Merchant
  • Merchant API
  • Embedded SDK
  • Salla OAuth 2.0
Storefront
Storefront
  • Twilight Engine
  • Twilight SDK
  • Web Components
  • Ecommerce Events
  • Component Bundle
  • Checkout APIs
  • Change Log
App Functions
Partner APIs
Partner APIs
  • App API
  • Shipments & Fulfillment APIs
  • Salla AWB
  • Recurring Payments API
  • Billing System Salla partners
  • Communication Apps
Dev Tools
Dev Tools
  • Partners Agent Kit
  • Salla Apps Playbook
  • Salla CLI
Salla - Opensource
Salla - Developers Community
  1. Checkout APIs

Usage Flows

image.png

Usage Flows#

Common integration patterns for the Cart v2 APIs.
Paths in the diagrams are relative to the v2 cart base (e.g. /generate -> v2/checkout/generate, /{cart}/items -> v2/checkout/{cart}/items).

Guest Checkout Flow#

A visitor browses, adds items, optionally applies a coupon, then checks out without creating an account.
Notes:
identifier_type is one of id, variant_id, sku. identifier is the matching value.
Items are added/updated/removed one at a time; there is no bulk array body.

Authenticated User Flow (attach guest cart on sign-in)#

When a guest signs in mid-session, attach the existing guest cart to the authenticated user so checkout proceeds against the same cart.
Notes:
POST /{cart}/assign requires a Bearer JWT.
Returns 403 forbidden if the cart is already owned by a non-guest user.

Get Cart (refresh state)#

Read the current cart at any time with GET /{cart}. By default the response omits the items array; pass include_items=true to include line items.

Error Recovery — Cart no longer available#

If a stored cart id can no longer be used (expired, cleared, or not found), generate a new cart and replay the items.
Modified at 2026-07-29 11:46:05
Previous
Key Concepts
Next
Save guest cart data