Overview

The five steps of the checkout flow.

Once a customer finishes adding products to the cart, they go through checkout to place the order.

Keep this five-step API order. Do not skip a Store API step or reorder unless you are following a documented express-checkout flow. How many screens you use, and how they look, is UI — you may put email on the address form.

  1. Email — set cart email. Prefill for a logged-in customer.
  2. Address — shipping address (and billing if different).
  3. Shipping — listCartOptions, then addShippingMethod.
  4. Payment — listPaymentProviders for the cart's region_id, then the provider session (for example Stripe).
  5. Complete Cart — finish the payment action, sdk.store.cart.complete, then load the order.

On Next.js, each step is a server action in src/lib/data/cart.ts (or fulfillment/payment modules) that reads _aiminaabee_cart_id and _aiminaabee_jwt. After the order is placed, remove the cart cookie and send the shopper to your confirmation view.

Shipping and payment lists should fail soft ([]) so the shop can show an empty state.

See Build a Next.js Storefront.

Tip: The Express Checkout Tutorial is an optional client-side UI walkthrough. It is not the required look.