← all adapters

zuora-style

simulates Zuora REST API v1

restadapter v0.1.020 routes

verification

VMVM tier — no SDK suite yet· surface 20 · not implemented 8 · differs 5

use it

# add to stunt.yaml
services:
  zuora:
    adapter: embedded:zuora-style

# then
$ stunt up

The embedded: source extracts this adapter from the binary — no git clone, fully offline.

how to mock the Zuora REST API locally

Install stunt, paste the service block above into stunt.yaml, run stunt up — then point your client at localhost instead of Zuora REST API. It works offline, keeps state across requests and restarts, and every response is synthetic: the route shapes, status codes, pagination, and webhook delivery follow the real Zuora REST API v1 surface — the data is fake, the behavior is real.

backing stores

accountssubscriptionsusageinvoicespaymentspayment_methods

api surface (20)

generated from the adapter manifest — exactly what boots, nothing more

20 routes
GET/v1/accounts
POST/v1/accounts
GET/v1/accounts/{accountKey}
POST/v1/subscriptions
POST/v1/subscriptions/{subscriptionKey}/cancel
PUT/v1/subscriptions/{subscriptionKey}
GET/v1/subscriptions/{subscriptionKey}
POST/v1/usage
GET/v1/usage
GET/v1/invoices/{invoiceId}
GET/v1/payments
POST/v1/payments
POST/v1/payments/{paymentId}/unapply
GET/v1/payments/{paymentId}
POST/v1/payment-methods/credit-cards
POST/v1/transactions/billing/preview
POST/v1/action/query
POST/v1/webhooks
GET/v1/webhooks
DELETE/v1/webhooks/{id}

VM-verified behaviors (7)

  • an unknown bearer is 401
  • account create assigns an id and reads back
  • subscribing to a catalog plan prices the subscription
  • unknown accounts and empty plan lists are 400s
  • EndOfTerm cancel stays Active and a second cancel is rejected
  • ZOQL finds the account by name
  • webhook registration round-trips through the list

Not implemented (8)

  • No Orders API (POST /v1/orders, /v1/orders/preview)
  • No product catalog endpoints (/v1/catalog/products, rate plans)
  • No credit or debit memo endpoints (/v1/creditmemos, /v1/debitmemos)
  • No refunds endpoints (POST /v1/refunds, GET /v1/refunds/{id})
  • No bill runs or payment runs (/v1/bill-runs, /v1/payment_runs)
  • No subscription list by account (GET /v1/subscriptions/account/{key})
  • No invoice list endpoint (GET /v1/transactions/invoices)
  • No other /v1/action endpoints (queryMore, create, update, delete)

Differs from the real API (5)

  • ZOQL is pattern-matched: only SELECT fields FROM Object [WHERE Id = value] is supported
  • Synthetic calendar anchored at 2024-01-01; term and due dates track real time
  • Webhook reg via /v1/webhooks (real: Notifications UI only); deliveries JSON not form-encoded
  • List filter[] applies a single condition per request; multiple filters cannot be ANDed
  • Subscriptions become Active immediately on create; no Pending Activation state
want more of the Zuora REST API surface? adapters are YAML + Starlark — the authoring guide covers adding routes, fixtures, and state machines. Open an issue for anything big first, or just file a PR — merged routes ship in the next release.