vibeside_mock_route
Intercept and mock browser HTTP/GraphQL requests to simulate custom status codes, response bodies, delays, or network faults without changing backend code.
Instructions
Intercept and mock network HTTP/GraphQL requests in the browser with custom status, body, latency, or network faults.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | Custom rule ID (optional, auto-generated if omitted) | |
| body | No | Response body as JSON object, array, or string | |
| error | No | Simulate network error/failure instead of responding | |
| times | No | Number of times to mock before auto-removing rule (omit for infinite/persistent) | |
| method | No | HTTP method to match (case-insensitive, default ALL) | ALL |
| status | No | HTTP response status code (100-599, default: 200) | |
| delayMs | No | Artificial delay in milliseconds before responding (max 60000ms) | |
| headers | No | Custom response headers as key-value pairs | |
| urlPattern | Yes | URL to match: exact URL, wildcard/glob (e.g. "*/api/users*"), or regex (e.g. "^/api/v[12]/.*") | |
| contentType | No | Response Content-Type header (default: application/json) | application/json |
| operationName | No | GraphQL operation name to match in POST body (operationName field or query keyword) |