Skip to content
Now in early access

The only mock API where
pet.owner_id
resolves to a real user.

Other mock servers return static JSON with random UUIDs. Testfly generates a real relational database from your OpenAPI spec — every foreign key points to a real record. Full CRUD. Semantic data. Zero backend code.

terminal
$ curl https://petstore.mock.testfly.com/pets

{
  "data": [
    { "id": "a1b2c3", "name": "Luna", "species": "cat", "owner_id": "u_7f8e" },
    { "id": "d4e5f6", "name": "Max", "species": "dog", "owner_id": "u_3a1b" }
  ],
  "meta": { "page": 1, "totalCount": 100, "totalPages": 5 }
}

How it works

From spec to live mock API in three steps

1

Upload your spec

Paste or upload any OpenAPI 2.0, 3.0, or 3.1 spec. YAML or JSON. Testfly parses schemas, detects relationships, and maps every route.

2

We generate your data

Our engine creates relationally-consistent fake data. Emails look like emails. Prices look like prices. Foreign keys reference real records.

3

Hit your mock API

Your mock is live at a dedicated subdomain. Use the Testfly dashboard, curl, the CLI, or any HTTP client. GET, POST, PUT, DELETE — every operation works against real data.

Why Testfly

Prism gives you static JSON. We give you a database.

Mock servers like Prism, Mockoon, and WireMock return canned responses. Testfly parses your spec, builds a real relational database, and gives you a fully stateful API with FK integrity across every endpoint.

Relational Consistency

Every foreign key references a real record. pet.owner_id always points to an actual user. No orphaned references.

Semantic Fake Data

Names look like names. Emails look like emails. Prices are realistic decimals. Our engine understands field semantics from column names and types.

Full CRUD Operations

POST creates real records. PUT updates them. DELETE removes them. GET returns paginated results with filtering and sorting. It's a real database.

Any OpenAPI Spec

Supports OpenAPI 2.0 (Swagger), 3.0, and 3.1. Handles allOf/oneOf/anyOf composition, nested objects, enums, and complex schemas out of the box.

Instant Provisioning

Upload a spec and your mock API is live within seconds. Each workspace gets its own subdomain and isolated data store. No configuration needed.

Simulated Conditions

Configure latency, error rates, and CORS per workspace. Test how your frontend handles slow responses, 500 errors, and edge cases.

Use cases

Built for teams that move fast

Frontend Development

Build your UI without waiting for the backend team. Get a fully functional API from day one. POST, PUT, DELETE all work — test complete user flows end to end.

QA & Integration Testing

Run integration tests against a predictable, isolated data set. Use seed values for reproducible test data. Reset the database anytime with one API call.

Rapid Prototyping

Design your API spec first, get a working mock immediately. Iterate on the spec, regenerate data, and keep prototyping without writing a single line of backend code.

Sales Demos

Show a fully working API to prospects with realistic data. No need to maintain a demo environment. Spin up a fresh workspace for every demo, tear it down after.

Typical workflow

From zero to mock API in five minutes

Everything can be done from the web dashboard or the API. No CLI required.

1

Create your account

Sign up from the Portal and create your organization. This sets up your team workspace and authentication in one step.

Dashboard Register → Create Organization

# Or use the API directly

POST /api/auth/register

{

  "organizationName": "Acme Corp",

  "email": "dev@acme.com",

  "password": "securepass123"

}

2

Create a workspace

A workspace is an isolated mock API environment. Give it a name, a slug (which becomes the URL prefix), and set how many rows of data to generate per table.

Dashboard Workspaces → New Workspace

Name

Pet Store API

Slug

pet-store

Rows per table

50

Seed (optional)

For reproducible data
3

Upload your OpenAPI spec

Paste your spec YAML or JSON into the dashboard (or POST it to the API). Testfly parses it, detects schemas and relationships, creates tables, and generates realistic data — all automatically.

Dashboard Workspace → Upload Spec
Parsing
Provisioning
Ready

Detected 4 resources: users, pets, orders, categories

Created 3 relationships: pet→user, order→pet, pet→category

Generated 200 rows with FK integrity across all tables

4

Explore and configure

Browse your generated resources, routes, and relationships in the dashboard. Configure workspace settings like simulated latency, error rates, and mock authentication.

Dashboard Workspace → Details
Overview Resources Routes Settings Usage
Mock URLpet-store.mock.testfly.com
StatusActive
Resources4 tables
Routes20 endpoints
Total Requests0
5

Hit your mock API

Start making requests from your frontend, test suite, or Postman. Every endpoint supports full CRUD with pagination, filtering, and sorting out of the box.

any HTTP client
# List pets with pagination
$ curl pet-store.mock.testfly.com/pets?page=1&pageSize=10
200 { "data": [...], "meta": { "totalCount": 50 } }

# Filter by species, sort by name
$ curl ".../pets?species=dog&sortBy=name"
200 { "data": [{ "name": "Bella", ... }] }

# Create, update, delete — all work
$ curl -X POST .../pets -d '{"name":"Rex","species":"dog"}'
201 Created

Developer experience

Every endpoint. Every method. Just works.

Testfly automatically generates routes from your OpenAPI spec. List, get, create, update, delete. Pagination, filtering, and sorting come built-in.

  • Paginated responses with ?page=2&pageSize=10
  • Filter by any field: ?status=active&species=cat
  • Sort by column: ?sortBy=name&sortDesc=true
  • Dedicated subdomain per workspace: petstore.mock.testfly.com
CRUD operations
# Create a new pet
$ curl -X POST petstore.mock.testfly.com/pets \
  -H "Content-Type: application/json" \
  -d '{"name": "Bella", "species": "dog"}'

201 Created
{ "id": "g7h8i9", "name": "Bella", "species": "dog" }

# Update it
$ curl -X PUT petstore.mock.testfly.com/pets/g7h8i9 \
  -d '{"name": "Bella Mae"}'

200 OK
{ "id": "g7h8i9", "name": "Bella Mae", "species": "dog" }

# Delete it
$ curl -X DELETE petstore.mock.testfly.com/pets/g7h8i9

204 No Content

Web dashboard

The Testfly Portal

Manage your entire mock API workflow from the browser. Create workspaces, upload specs, browse generated resources and routes, configure settings, and monitor usage — all from a visual dashboard. No terminal required.

  • Create workspaces and upload specs with a visual form
  • Browse resources, routes, and FK relationships in tabbed views
  • Configure latency, error rates, and mock auth per workspace
  • Monitor request counts, daily usage, and workspace health
app.testfly.com/workspaces

Workspaces

+ New Workspace

Pet Store API

pet-store.mock.testfly.com

4 resources 1,247 requests Active

Payments API

payments.mock.testfly.com

6 resources 3,891 requests Active

Inventory v2

inventory.mock.testfly.com

8 resources 56 requests Paused
testfly cli
# Install the CLI
$ dotnet tool install -g Testfly.Cli

# Set up and authenticate
$ testfly init
[OK] Created testfly.json

$ testfly auth set-key tf_live_abc123

# Create a workspace and upload a spec
$ testfly workspace create --name Petstore --slug petstore
[OK] Workspace created: 7f8e3a1b...

$ testfly spec upload --file openapi.yaml

# Test mock endpoints directly
$ testfly mock petstore GET /pets
HTTP 200  GET /mock/petstore/pets

Prefer the terminal?

The Testfly CLI

Everything you can do in the dashboard, you can do from the terminal. Create workspaces, upload specs, configure mock auth, and test endpoints without leaving your editor. Install as a .NET global tool and go.

  • Full workspace lifecycle: create, pause, resume, regenerate, delete
  • Upload specs and inspect parsed resources and routes
  • Fire mock requests with testfly mock and custom headers
  • Configure mock auth (bearer token or API key) per workspace
3
OpenAPI versions supported
<5s
Spec to live API
100%
FK relationship integrity
5
CRUD operations per resource

Stop waiting for the backend.

Upload your OpenAPI spec and start building in seconds. Free to start. No credit card required.