Swell · Arazzo Workflow

Swell Storefront Adjust Cart Item Quantity

Version 1.0.0

Read the session cart, then update the quantity of one of its line items.

1 workflow 1 source API 1 provider
View Spec View on GitHub CommerceHeadless CommerceAPI-FirstB2CB2BSubscriptionMarketplacesWholesaleStorefrontCheckoutPaymentsCartOrderCatalogInternationalizationArazzoWorkflows

Provider

swell-io

Workflows

storefront-adjust-cart-item-quantity
Get the cart, then change a line item's quantity.
Reads the session cart, then puts a new quantity on the specified cart item.
2 steps inputs: itemId, publicKey, quantity outputs: cartId
1
getCartStep
Retrieve the current session cart and its line items.
2
updateItemStep
Update the specified cart line item to the new quantity.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Swell Storefront Adjust Cart Item Quantity
  summary: Read the session cart, then update the quantity of one of its line items.
  description: >-
    A storefront cart-maintenance flow. The workflow retrieves the current
    session cart to confirm it exists and exposes its line items, then updates a
    specific cart item to a new quantity. Each step spells out its request
    inline, including the public-key authorization, so the flow can be read and
    executed without opening the underlying OpenAPI description.
  version: 1.0.0
sourceDescriptions:
- name: cartApi
  url: ../openapi/swell-io-cart-api-openapi.yml
  type: openapi
workflows:
- workflowId: storefront-adjust-cart-item-quantity
  summary: Get the cart, then change a line item's quantity.
  description: >-
    Reads the session cart, then puts a new quantity on the specified cart item.
  inputs:
    type: object
    required:
    - publicKey
    - itemId
    - quantity
    properties:
      publicKey:
        type: string
        description: Public storefront key, prefixed with pk_.
      itemId:
        type: string
        description: The cart line item id to adjust.
      quantity:
        type: integer
        description: The new quantity for the line item.
  steps:
  - stepId: getCartStep
    description: Retrieve the current session cart and its line items.
    operationId: frontendGetCart
    parameters:
    - name: Authorization
      in: header
      value: $inputs.publicKey
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      cartId: $response.body#/id
  - stepId: updateItemStep
    description: Update the specified cart line item to the new quantity.
    operationId: frontendUpdateCartItem
    parameters:
    - name: itemId
      in: path
      value: $inputs.itemId
    - name: Authorization
      in: header
      value: $inputs.publicKey
    requestBody:
      contentType: application/json
      payload:
        quantity: $inputs.quantity
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      cartId: $steps.getCartStep.outputs.cartId
  outputs:
    cartId: $steps.updateItemStep.outputs.cartId

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/swell-io-storefront-update-cart-item-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.