mock_endpoint
Return a fabricated HTTP response for requests matching a URL pattern in a Mac or iOS Simulator app, so you can test app behavior without reaching the real server.
Instructions
Answer requests to one endpoint in a simulator app with a made-up response, without reaching the server.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"app": "<app>",
"simulator": "<simulator>",
"pattern": "<pattern>"
},
"name": "mock_endpoint"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| app | Yes | The app: a bundle ID like com.me.MyApp, an app name, or * for every app in a simulator. | |
| body | No | The response body, usually JSON. | |
| delay | No | Seconds to wait before answering. | |
| status | No | HTTP status. Default 200. | |
| pattern | Yes | Requests whose URL contains this, like api.me.com/v1/user. Use * for any text. | |
| simulator | Yes | For iOS Simulator apps: booted, any, a device name or a UDID. Leave out for a Mac app. | |
| content_type | No | Default application/json. |