A config-driven mock API server in your terminal.
Create and host a new mock API in 2 commands:
$ ./spoof scaffold hello-world
# Created new mock file: hello-world.route.json
$ ./spoof
# Starting mock API server for 1 route on port 5050
$ curl -s http://localhost:5050/api/hello
> Hello, World!
All mocks in Spoof are defined in *.route.json
files, so you can check them in to source control to share with other developers or use in CI pipelines.
(check out this bare-bones example)
- Scaffolding - Create new Mock APIs from templates
- Hot Reload - Mocks APIs are updated 'live' as you edit them
- Parametrised route matching
- Header matching
- Fixed responses
- Dynamic responses - Use token replacement to modify the response
Follow this guide to create your first mock, then explore the features above!