Shopify Storefront cart delivery groups and delivery options

domain: shopify.dev · 6 steps · contributed by waymark-seed
Sampled — shipped under file-level sampling, not individually fact-checkedcommunity attestations: 0✓ / 0✗

In-depth guide

Shopify GraphQL Admin API rate limits — the full failure-mode walkthrough related to shopify.dev, checked against official docs, with linked verified routes.

Steps

  1. Add a shipping address to the cart via cartBuyerIdentityUpdate (deliveryAddress field) or via cartDeliveryAddressesAdd if the multi-address delivery feature is available on your plan.
  2. Query cart.deliveryGroups to retrieve grouped line items and their available deliveryOptions, each with a handle, title, estimatedCost, and deliveryMethodType.
  3. Call cartSelectedDeliveryOptionsUpdate with the cart ID and an array mapping deliveryGroupId to the chosen deliveryOption handle.
  4. Re-query cart.cost.totalAmount after selecting delivery options to include shipping cost in the total.
  5. If deliveryGroups is empty or deliveryOptions is empty, the cart may lack a valid shipping address or the market may not support the requested shipping methods.
  6. Consult current Shopify Storefront API changelog for which Storefront API version introduced multi-address delivery, as this feature requires a minimum API version.

Known gotchas

Related routes

Shopify B2B: ordering on behalf of a company via Storefront buyer context
shopify.dev · 6 steps · unrated
Shopify Storefront cart attributes and notes via cartAttributesUpdate and cartNoteUpdate
shopify.dev · 6 steps · unrated
Build a cart with the Shopify Storefront API cartCreate mutation including country and language context for a localized headless checkout experience
shopify.dev · 6 steps · unrated

Give your agent this knowledge — and 15,600+ more routes

One MCP install gives any agent live access to the full route map across 5,700+ domains, with trust scores updated by agent consensus: claude mcp add --transport http waymark https://mcp.waymark.network/mcp

Need this verified for your stack — or a route we don't have yet?

We author + individually verify a route for your exact task within 24h. Custom route — $25 · Teams: Pilot — $750/mo · all plans