browser_intercept_request
Intercept network requests by URL pattern to add delays, force failures, or return mock responses.
Instructions
Intercept matching network requests to inject delays, force failures, or return mock responses. Uses CDP Fetch domain for precise request-level control.
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": {
"pattern": "<pattern>",
"action": "<action>"
},
"name": "browser_intercept_request"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| action | Yes | "delay" = add latency, "fail" = reject the request, "mock" = inject custom mock response | |
| delayMs | No | Delay in ms (required for action="delay") | |
| pattern | Yes | URL glob pattern to match (e.g., "*api*", "*graphql*") | |
| mockResponse | No | Mock response configuration (required for action="mock") |