Skip to main content

Get cart content for store

GET 

/api/v1/sdk/cart/:storeId

This endpoint retrieves the customer's cart contents for a specific store. Cart items are grouped by brand for better organization.

Authentication: Requires customer authentication (JWT token with verified phone). Optional API key for additional store validation.

Use Cases:

  • Displaying cart contents in checkout UI
    • Cart review before payment
    • Cart synchronization across devices
    • Pre-checkout validation

Response Structure:

  • Items grouped by brand with brand information
    • Product details including images, variants, and pricing
    • Availability status for each item
    • Subtotals, taxes, and grand total

Error Scenarios:

  • 404 NOT FOUND - Store doesn't exist or customer has no cart (Error code: STORE_NOT_FOUND or CART_EMPTY)
    • 401 UNAUTHORIZED - Customer not authenticated or invalid token (Error code: UNAUTHORIZED)
    • 403 FORBIDDEN - API key doesn't have access to this store (Error code: NO_STORE_ACCESS)

Request​

Responses​

Cart retrieved successfully with all items grouped by brand