| name | api-testing |
| description | Test API integrations by mocking responses, intercepting requests, and monitoring network traffic. Use when the user wants to mock backend APIs, simulate errors, test offline behavior, intercept requests, or add authentication headers. |
| allowed-tools | Bash(browser-devtools-cli:*), Bash(node-devtools-cli:*) |
API Testing Skill
Test API integrations by mocking responses, intercepting requests, and monitoring network traffic.
When to Use
This skill activates when:
- User wants to test API integrations
- User needs to mock backend responses
- User wants to simulate error scenarios
- User asks about request interception
- User needs to test offline behavior
Capabilities
Response Mocking
browser-devtools-cli stub mock-http-response \
--pattern "**/api/users" \
--response '{"action":"fulfill","status":200,"body":[{"id":1,"name":"Test"}]}'
Request Interception
browser-devtools-cli stub intercept-http-request \
--pattern "**/api/**" \
--modifications '{"headers":{"Authorization":"Bearer token"}}'
Network Monitoring
browser-devtools-cli --json o11y get-http-requests
browser-devtools-cli --json o11y get-http-requests --resource-type fetch
browser-devtools-cli --json o11y get-http-requests --status '{"min":400}'
Stub Management