API mocking lets you define HTTP endpoints that return whatever response you configure — a specific status code, custom headers, and a body you control. Instead of waiting for a backend to be ready or spinning up a local server, you point your frontend or integration code at a Swisstools mock URL and get consistent, predictable responses immediately.Documentation Index
Fetch the complete documentation index at: https://docs.swisstools.dev/llms.txt
Use this file to discover all available pages before exploring further.
What you can configure
Each mock endpoint is defined by five properties:| Property | Description |
|---|---|
| Method | HTTP method: GET, POST, PUT, PATCH, or DELETE |
| Path | The endpoint path, e.g. /users or /orders/123 |
| Status code | The HTTP status code to return, e.g. 200, 201, 404 |
| Response body | Any text or JSON body to include in the response |
| Response headers | Key-value pairs sent with every response, e.g. Content-Type: application/json |
How mock URLs work
Every project gets a unique base URL derived from your team and project identifiers:<team_ref> is your team’s 8-character reference ID and <project_slug> is your project’s slug. You can find the full base URL on your project page.
For example, a mock configured with path /users on the project my-api belonging to team abc12345 is reachable at:
Instant updates
Changes to a mock take effect immediately. Update the status code, swap the response body, or add a header — the very next request to that URL sees the new response. There is no cache to clear and no server to restart.Create a mock endpoint
Step-by-step guide to creating and configuring your first mock.
Using your mock URL
How to construct and call your mock endpoint URL.