OpenAPI 3.0 Sample Spec (Backed by a Live API)
A complete OpenAPI 3.0 spec — paths, components, security schemes, examples — and a live API behind it. Use it to evaluate importers, generate clients, or learn the spec by reading a real-world example.
Get the spec
| Format | URL |
|---|---|
| JSON | /openapi.json |
| YAML | /openapi.yaml |
| Swagger UI | /docs |
What's inside
- ~30 paths covering CRUD on users, products, orders, posts
- Reusable components — schemas, parameters, responses, examples
- Security schemes — Bearer JWT, API Key, OAuth2 client-credentials
- Discriminated responses — success/error envelopes with proper status codes
- Realistic examples on every request and response
Generate a client in seconds
# Python
openapi-generator-cli generate -i https://demo.totalshiftleft.ai/openapi.json -g python -o ./py-client
# TypeScript
openapi-generator-cli generate -i https://demo.totalshiftleft.ai/openapi.json -g typescript-fetch -o ./ts-client
# Go
openapi-generator-cli generate -i https://demo.totalshiftleft.ai/openapi.json -g go -o ./go-client
Test your OpenAPI tooling
Building an OpenAPI importer, validator or codegen tool? Point it at this spec — it intentionally exercises tricky features: oneOf responses, nullable fields, parameter style variations, and multiple security schemes per operation.
Frequently asked questions
Is the OpenAPI spec hand-written or generated?
Generated from the Fastify route schemas at runtime, so it always matches the live API exactly.
Can I download the spec?
Yes — /openapi.json or /openapi.yaml. Both are versioned with a stable URL.
Does it cover authentication?
Yes — Bearer JWT, API Key (x-api-key) and OAuth2 client-credentials are all defined as security schemes.
Other free public APIs in this sandbox
Open the live sandbox — REST, GraphQL, SOAP and auth in one place. No signup, no API key.
Open the API Sandbox →Topics: OpenAPI 3.0 example · sample OpenAPI JSON · OpenAPI for testing · OpenAPI tutorial · OpenAPI generator · free OpenAPI spec