MutationEnvelope

cart · /core·type

Wraps a with an idempotency key for transport across the server-action boundary. Used by implementations to carry the key alongside the mutation payload.

Properties

idempotencyKey
string
mutation

Example

const envelope: MutationEnvelope = {
  mutation: { kind: 'add-line', variantId: 'v_1', quantity: 1 },
  idempotencyKey: crypto.randomUUID(),
};
await submitMutation(envelope);

RunCartAdapterContractOpts runCartAdapterContract CartCapabilityUnsupportedError CartError CartNotFoundError CartProviderError CartUserError CartAdapter

Sourcetypes.ts:221Edit the JSDoc directly

On this page