Show HN: StripeWorld – a synthetic Stripe API for RL and testing Kiln-AI released StripeWorld, a stateful synthetic copy of Stripe's Billing and Payments API built on its Seahaven framework, covering 155 Stripe API operations across 25 tables pinned to API version 2026-08-26.dahlia. StripeWorld runs hundreds of private Stripe accounts in one process, each starting from a chosen fixture with controlled clock, ids and randomness, and logs every row a run changes so agent evals, RL and tests can be graded on outcomes rather than transcripts. Unlike Stripe test mode, which shares one account, or stripe-mock, which keeps no state, StripeWorld is stateful across calls and speaks Stripe's HTTP API and MCP tools, though it omits webhook delivery and covers only Billing and Payments core. A stateful Stripe sandbox for agent evals, RL and tests Built with Seahaven https://github.com/Kiln-AI/Seahaven . Quick Start getting-started • Examples examples • Built with Seahaven Agents that use Stripe need somewhere to practise. Test suites need somewhere to charge cards. Real Stripe is one shared account you can't reset, and a mock forgets every write the moment it answers. Stripe World is a stateful copy of Stripe's Billing and Payments API. Run a hundred private Stripe accounts in one process, each starting from a state you chose, with every row each one changed logged for you to check. Stripe World is a Seahaven demo. It was built to show what a Seahaven https://github.com/Kiln-AI/Seahaven world can be. If you want a realistic copy of your system, for your agents or your tests, that's what Seahaven is for. Not affiliated with Stripe. Stripe's field names, enum values and id prefixes are reused as API vocabulary under the MIT licence of Stripe's OpenAPI spec; see THIRD PARTY LICENSES.md https://github.com/Kiln-AI/stripe world/blob/main/THIRD PARTY LICENSES.md . Try it on Hugging Face Spaces → https://huggingface.co/spaces/scosman/stripe world - 155 Stripe API operations across 25 tables , pinned to API version 2026-08-26.dahlia . Every object shape aligned to Stripe's OpenAPI spec. - A billing engine, not just CRUD. Subscriptions move through all eight statuses. Invoices go from draft to open to paid, void or uncollectible. Proration, dunning, credit notes and a balance ledger behave the way Stripe's do, and Stripe's test cards tok visa , tok visa chargeDeclinedInsufficientFunds , … succeed, decline and dispute on cue. - Stripe's own MCP tools. Agents get the same tools as Stripe's MCP server, so an agent that works here works against the real thing. - Stripe's own API/SDK. It also speaks Stripe's HTTP API. Point an official Stripe SDK at it and your code runs unchanged, apart from webhooks. - Checked against the real API. recordings of real Stripe API sessions are replayed against it in CI, and every object it returns is validated against Stripe's OpenAPI spec. | | Stripe World | Stripe test mode | stripe-mock | |---|---|---|---| | Stripe's real object shapes | ✅ | ✅ | ✅ | | Stateful across calls | ✅ | ✅ | ❌ | | Billing behaviour: subscriptions, invoices, declines | ✅ | ✅ | ❌ | | A private account for every run | ✅ | ❌ | ✅ | | Hundreds of runs in parallel | ✅ | ❌ rate-limited | ✅ | | Every run starts from a known state | ✅ | ❌ | ✅ | | Reproducible: same ids, same timestamps | ✅ | ❌ | ✅ | | Every change logged for grading | ✅ | events only | ❌ | | No API key or network needed | ✅ | ❌ | ✅ | | Webhook delivery | ❌ events are queryable | ✅ | ❌ | | All of Stripe's API | ❌ Billing and Payments core | ✅ | ✅ | stripe-mock https://github.com/stripe/stripe-mock is Stripe's own mock server. It answers every endpoint with a valid, canned response but keeps no state: a customer you create is not there when you list customers. Stripe test mode is the real thing, but every run shares one account, and your code can't reset it. Stripe World is built on Seahaven https://github.com/Kiln-AI/Seahaven , a framework for building synthetic worlds for agent evals, RL and testing. Seahaven provides: - Instances in milliseconds. Every run gets a private copy of a frozen starting state, a fixture , with its own SQLite database. - Reproducibility. The clock, ids and randomness are controlled: the same fixture and seed replay the same run. - A change log. Every row a run changed is recorded, so you grade the outcome, not the transcript. - Serving. OpenEnv for eval and RL harnesses and HTTP for software tests, each hosting hundreds of instances in one process; MCP for chat apps; and a web console to drive a world by hand. Stripe World supplies only what is specific to Stripe: the tables, the API operations and the billing rules. Each example runs from a checkout of this repository; Getting started getting-started has the three commands that make one. seahaven serve hosts Stripe World as an OpenEnv https://github.com/huggingface/OpenEnv environment, the open standard for RL environments. Every connection gets its own private Stripe account. Open http://127.0.0.1:8000/console to drive one by hand. uv run --extra serve seahaven serve This script, rollouts.py , runs 100 episodes at once against that server. Each starts from the same fixture and is graded on what changed in its account: python import asyncio from seahaven.openenv import SeahavenClient TASK = "Sign up jenny@example.com as a customer." async def run agent env, tools, task : Your agent goes here: hand tools to your model and run its tool calls with env.call . This stand-in makes the two calls a good agent would. account = await env.call "list available accounts or orgs" .result "accounts" 0 await env.call "stripe api write", stripe api operation id="PostCustomers", parameters={"email": "jenny@example.com"}, stripe context=account "stripe context" , livemode=account "livemode" , def grade state - float: Grade what changed in the account, not what the agent said it did. rows = state.state "db" "log" signed up = any row "table" == "customers" and row "op" == "insert" and row "after" "email" == "jenny@example.com" for row in rows return 1.0 if signed up else 0.0 async def episode seed: int - float: async with SeahavenClient base url="http://127.0.0.1:8000" as env: A private Stripe account, copied from the empty fixture. await env.reset fixture="empty", seed=seed tools = await env.list tools the eight Stripe MCP tools, as JSON schemas await run agent env, tools, TASK return grade await env.state async def main : rewards = await asyncio.gather episode seed for seed in range 100 print f"{len rewards } episodes, mean reward {sum rewards / len rewards }" asyncio.run main uv run --extra serve python rollouts.py Kiln https://kiln.tech connects to the same server as an OpenEnv client. To use the hosted copy instead of a local server, see Connecting to the published world connecting-to-the-published-world . serve http.py serves Stripe's HTTP API. Every /worlds/