How StateSet iCommerce works

Resolve the exception.
Verify every handoff.

A customer sees one request. Your team sees an order, a warehouse, a payment, and a support conversation. StateSet coordinates the agreed actions and keeps the remaining work visible.

Recorded engine test · September 12, 2026

Follow the request through to the record.

Inspect three cases from one recorded run of StateSet’s commerce engine. Scripted requests used synthetic data in a temporary database. No live storefront, warehouse, AI reasoning, or payment provider was connected.

Cancellation confirmed

Cancel the order. Release its reserved stock.

An unpaid, unfulfilled test order is canceled. A separate inventory read confirms the reserved units are available again.

Order state
cancelled
Units released
2
Available units
1 → 3
  1. 01 · Recorded call 6

    Create the original order

    2 units are requested and the engine returns the original order ID.

  2. 02 · Recorded call 9

    Cancel that same order

    The response retains the order ID and reports cancelled. Its payment status remains pending; no refund was issued.

  3. 03 · Recorded call 10

    Read the inventory back

    Reserved units change from 4 to 2. Stock on hand remains 5.

Inspect the original calls and responses
[
  {
    "sequence": 6,
    "actor": "buyer-02",
    "method": "orders.createExact",
    "input": {
      "customerId": "59b07498-70aa-4017-9316-957439e326ca",
      "currency": "USD",
      "stockPolicy": "reject_if_insufficient",
      "items": [
        {
          "sku": "MERIDIAN-SENSOR",
          "name": "Meridian sensor modules",
          "quantity": 2,
          "unitPrice": "12.34"
        }
      ]
    },
    "result": {
      "id": "98b915bc-9ab7-40a9-b690-fa77818af68b",
      "orderNumber": "ORD-1789244128-291228-00000001",
      "customerId": "59b07498-70aa-4017-9316-957439e326ca",
      "status": "pending",
      "totalAmount": 24.68,
      "totalAmountExact": "24.68",
      "currency": "USD",
      "paymentStatus": "pending",
      "fulfillmentStatus": "unfulfilled",
      "items": [
        {
          "id": "2076f03f-634f-435b-816f-ded0f6491bff",
          "sku": "MERIDIAN-SENSOR",
          "name": "Meridian sensor modules",
          "quantity": 2,
          "unitPrice": 12.34,
          "unitPriceExact": "12.34",
          "total": 24.68,
          "totalExact": "24.68"
        }
      ],
      "version": 1,
      "createdAt": "2026-09-12T20:15:28.291233198+00:00",
      "updatedAt": "2026-09-12T20:15:28.291233198+00:00"
    },
    "status": "succeeded",
    "recordedAt": "2026-09-12T20:15:28.292Z"
  },
  {
    "sequence": 8,
    "actor": "seller-01",
    "method": "inventory.getStock",
    "input": {
      "sku": "MERIDIAN-SENSOR"
    },
    "result": {
      "sku": "MERIDIAN-SENSOR",
      "name": "Meridian sensor modules",
      "totalOnHand": "5",
      "totalAllocated": "4",
      "totalAvailable": "1"
    },
    "status": "succeeded",
    "recordedAt": "2026-09-12T20:15:28.298Z"
  },
  {
    "sequence": 9,
    "actor": "buyer-02",
    "method": "orders.cancel",
    "input": {
      "id": "98b915bc-9ab7-40a9-b690-fa77818af68b"
    },
    "result": {
      "id": "98b915bc-9ab7-40a9-b690-fa77818af68b",
      "orderNumber": "ORD-1789244128-291228-00000001",
      "customerId": "59b07498-70aa-4017-9316-957439e326ca",
      "status": "cancelled",
      "totalAmount": 24.68,
      "totalAmountExact": "24.68",
      "currency": "USD",
      "paymentStatus": "pending",
      "fulfillmentStatus": "unfulfilled",
      "items": [
        {
          "id": "2076f03f-634f-435b-816f-ded0f6491bff",
          "sku": "MERIDIAN-SENSOR",
          "name": "Meridian sensor modules",
          "quantity": 2,
          "unitPrice": 12.34,
          "unitPriceExact": "12.34",
          "total": 24.68,
          "totalExact": "24.68"
        }
      ],
      "version": 2,
      "createdAt": "2026-09-12T20:15:28.291233198+00:00",
      "updatedAt": "2026-09-12T20:15:28.298914973+00:00"
    },
    "status": "succeeded",
    "recordedAt": "2026-09-12T20:15:28.300Z"
  },
  {
    "sequence": 10,
    "actor": "seller-01",
    "method": "inventory.getStock",
    "input": {
      "sku": "MERIDIAN-SENSOR"
    },
    "result": {
      "sku": "MERIDIAN-SENSOR",
      "name": "Meridian sensor modules",
      "totalOnHand": "5",
      "totalAllocated": "2",
      "totalAvailable": "3"
    },
    "status": "succeeded",
    "recordedAt": "2026-09-12T20:15:28.301Z"
  }
]

The connected-system test

For a connected cancellation, verify customer authority, the warehouse cutoff and hold, any payment reversal, and the customer notification with the actual providers.

Evaluate your real workflow →

Engine 1.30.0 · @stateset/embedded

Run 888465af-dba0-46c7-bc91-005bdcaa8419

Download the complete original record ↓

Illustrative workflow · not a live customer execution

“Can you cancel my order before it ships?”

This example shows the acceptance criteria for a configured cancellation. The permitted sequence depends on the merchant’s policy and the connected providers.

  1. 01 · Customer support

    Identify the request

    Match the customer to the original order and identify exactly what they want canceled.

    Evidence to inspect: Verified identity and original order reference

  2. 02 · Order and fulfillment systems

    Check whether it can still stop

    Check current fulfillment state and request the warehouse hold required by the agreed cancellation policy.

    Evidence to inspect: Current order state and warehouse acknowledgment

  3. 03 · Commerce and payment providers

    Complete the permitted changes

    After the required hold is confirmed, cancel the eligible order and process the authorized financial action.

    Evidence to inspect: Provider references for the cancellation and refund

  4. 04 · Operations and support

    Verify the result and notify

    Reconcile the required records, report the actual result, and attach the evidence to the customer issue.

    Evidence to inspect: Completion record, unresolved states, and customer update

The exception is part of the evaluation.

Already shipped

Apply the agreed post-shipment policy or hand the issue to its owner. A cancellation request alone does not establish that fulfillment stopped.

Warehouse has not responded

Keep the issue pending, preserve context, and notify the operator. Do not report a completed cancellation without the required confirmation.

Payment response is ambiguous

Reconcile the provider result before another attempt. Use supported duplicate protection and escalate when the final state cannot be established.

Record the evidence in your evaluation →

Start with the customer issue.

CX handles the issue and its approved commerce action. Add OMS when your operation also needs order intake, fulfillment coordination, or exception recovery. Their scope and completion milestones are agreed separately.

One issue, one CX tier.

Under the CX pricing model, one distinct completed issue is charged at its highest applicable outcome tier. Internal calls and retries do not add units. Separately delivered OMS orchestration has its own defined milestone; invoking a function does not create a new order charge.

See billing definitions →

Published customer stories

See the workflow and the result together.

ARMRA

98%

faster order-cancellation resolution

Within 30 days, alongside a 90% reduction for subscription cancellations.

Read the customer story →

Sincerely Yours

80%

of ticket volume handled

While reducing time to resolution by 90% and saving more than 30 hours monthly.

Read the customer story →

These are results from the named customer deployments. They do not establish results for every workflow or qualify a new warehouse, transportation, or EDI rollout.

Bring an exception your team handles today.

We’ll map the systems, identify the decisions, and define what evidence would demonstrate a completed result.

Plan the first workflow