WaveXis Network Testing
Skill2 starsChanged 4 months agoMITView on GitHub
Network testing with wavexis. HAR capture, request interception, response mocking, network throttling, WebSocket inspection, request modification.
- Installs packages
In this repository45 other files it gives its agents.
- AGENTS.mdAGENTS.md
- allure-reportsSkill
- android-nativeSkill
- appian-lowcodeSkill
- appium-mobileSkill
- behave-bddSkill
- BiDiWave Cross-BrowserSkill
- BiDiWave Network InterceptionSkill
- CDPWave DebuggingSkill
- CDPWave TestingSkill
- db2-oracleSkill
- ebook-writerSkill
- flask-apiSkill
- flet-desktopSkill
- google-crawling-indexingSkill
- google-ranking-appearanceSkill
- google-seo-fundamentalsSkill
- google-seo-monitoringSkill
- jinja2-templatesSkill
- jmeter-load-testingSkill
- k6-load-testingSkill
- karate-api-testingSkill
- octane-almSkill
- paramiko-sshSkill
- postman-api-automationSkill
- prestashop-moduleSkill
- prompt-engineering-best-practicesSkill
- pytest-advancedSkill
- robot-frameworkSkill
- salesforce-devSkill
- sonarqube-quality-gatesSkill
- sql-serverSkill
- Skill NameSkill
- testcontainersSkill
- wave-ecosystem-guideSkill
- WaveXis AccessibilitySkill
- WaveXis CI/CD IntegrationSkill
- wavexis-cli-automationSkill
- wavexis-mcp-agent-integrationSkill
- WaveXis Performance AuditSkill
- WaveXis Session RecordingSkill
- WaveXis Web ScrapingSkill
- webdriverioSkill
- wordpress-themesSkill
- xctest-iosSkill
The file
Files
WaveXis Network Testing
Description
Network testing with wavexis — capture HAR files, intercept and mock requests/responses, modify in-flight traffic, simulate network conditions, inspect WebSocket frames, and replay captured HAR files.
When to Invoke
- Capturing HAR files for network analysis
- Intercepting or mocking API requests
- Modifying request headers or response bodies in-flight
- Simulating slow or unreliable network conditions
- Inspecting WebSocket traffic
- Replaying captured HAR files for testing
Prerequisites
pip install wavexis[cdp]- Chrome or Edge installed
- Basic familiarity with wavexis CLI (see
wavexis-cli-automationskill)
HAR Capture
har command
Capture all network traffic during page load as a HAR (HTTP Archive) file:
wavexis har https://example.com --output traffic.harHAR with interaction
wavexis har https://example.com \
--click "#load-more" \
--wait-for ".results" \
--output traffic.harHAR with filter
# Only capture API requests
wavexis har https://example.com \
--url-filter "*/api/*" \
--output api-traffic.harHAR options
| Option | Type | Default | Description |
--output | str | stdout | Output HAR file path |
--url-filter | str | None | Only capture matching URLs (regex) |
--method-filter | str | None | Only capture matching methods (GET, POST, etc.) |
--resource-type | str | None | Filter by type: xhr, fetch, script, stylesheet, image, document |
--include-bodies | flag | off | Include request/response bodies in HAR |
--click | str | None | Click selector after navigation |
--input | str | None | Type into selector after navigation |
--wait-for | str | None | Wait for selector before stopping capture |
--timeout | int | 30000 | Capture timeout in ms |
HAR output format
The output is a standard HAR 1.2 file:
{
"log": {
"version": "1.2",
"creator": {
"name": "wavexis",
"version": "1.0.0"
},
"entries": [
{
"request": {
"method": "GET",
"url": "https://example.com/api/data",
"headers": [...],
"queryString": [...],
"bodySize": 0
},
"response": {
"status": 200,
"statusText": "OK",
"headers": [...],
"content": {
"size": 1024,
"mimeType": "application/json"
},
"bodySize": 1024
},
"timings": {
"blocked": 0,
"dns": 5,
"connect": 20,
"send": 1,
"wait": 45,
"receive": 10
},
"time": 81
}
]
}
}Request Interception
intercept command
Block or allow requests matching a pattern:
wavexis intercept https://example.com \
--block "*/ads/*" \
--block "*/tracker.js" \
--output result.jsonintercept with allow
wavexis intercept https://example.com \
--block "*/ads/*" \
--allow "*/api/*" \
--output result.jsonintercept options
| Option | Type | Default | Description |
--block | str | None | URL pattern to block (can repeat) |
--allow | str | None | URL pattern to allow (overrides block) |
--resource-type | str | None | Block by resource type |
--output | str | stdout | Output file path |
--wait-for | str | None | Wait for selector before stopping |
--timeout | int | 30000 | Timeout in ms |
intercept output
{
"blocked": [
"https://ads.example.com/banner.js",
"https://tracker.example.com/analytics.js"
],
"allowed": [
"https://api.example.com/data"
],
"total_blocked": 2,
"total_allowed": 1
}Response Mocking
mock command
Mock API responses with custom status, headers, and body:
wavexis mock https://example.com \
--url "*/api/users" \
--status 200 \
--body '{"users": []}' \
--content-type "application/json" \
--output result.jsonmock with file
wavexis mock https://example.com \
--url "*/api/products" \
--status 200 \
--body-file ./mocks/products.json \
--content-type "application/json" \
--output result.jsonmock with delay
wavexis mock https://example.com \
--url "*/api/slow" \
--status 200 \
--body '{"data": "delayed"}' \
--delay 3000 \
--output result.jsonmock multiple endpoints
wavexis mock https://example.com \
--mock '*/api/users:200:{"users": []}' \
--mock '*/api/products:200:{"products": []}' \
--mock '*/api/error:500:{"error": "Internal"}' \
--output result.jsonmock options
| Option | Type | Default | Description |
--url | str | None | URL pattern to mock |
--status | int | 200 | HTTP status code |
--body | str | None | Response body string |
--body-file | str | None | Response body from file |
--content-type | str | application/json | Content-Type header |
--header | str | None | Additional response header (can repeat) |
--delay | int | 0 | Response delay in ms |
--mock | str | None | Shorthand: url:status:body (can repeat) |
--output | str | stdout | Output file path |
--timeout | int | 30000 | Timeout in ms |
In-Flight Modification
modify command
Modify request headers or URLs before they reach the server:
wavexis modify https://example.com \
--set-header "Authorization: Bearer token123" \
--set-header "X-Custom: value" \
--output result.jsonmodify URL
wavexis modify https://example.com \
--rewrite-url "*/staging/*->*/production/*" \
--output result.jsonmodify-response command
Modify response headers or body before the browser receives them:
wavexis modify-response https://example.com \
--url "*/api/config" \
--set-header "X-Modified: true" \
--output result.jsonmodify options
| Option | Type | Default | Description |
--set-header | str | None | Set request header (can repeat) |
--remove-header | str | None | Remove request header (can repeat) |
--rewrite-url | str | None | Rewrite URL pattern: from->to |
--url | str | None | URL pattern to match for modifications |
--output | str | stdout | Output file path |
--timeout | int | 30000 | Timeout in ms |
Network Throttling
throttle command
Simulate slow or unreliable network conditions:
wavexis throttle https://example.com \
--profile slow-3g \
--output result.jsonthrottle with CWV
wavexis throttle https://example.com \
--profile slow-3g \
--cwv \
--output cwv-throttled.jsonthrottle profiles
| Profile | Download | Upload | Latency | Description |
no-throttling | — | — | — | No throttling |
fast-4g | 4 Mbps | 3 Mbps | 20 ms | Fast 4G |
slow-4g | 1.5 Mbps | 750 kbps | 40 ms | Slow 4G |
fast-3g | 780 kbps | 330 kbps | 150 ms | Fast 3G |
slow-3g | 400 kbps | 400 kbps | 400 ms | Slow 3G |
offline | 0 | 0 | — | Offline |
custom throttle
wavexis throttle https://example.com \
--download 500000 \
--upload 250000 \
--latency 300 \
--output result.jsonthrottle options
| Option | Type | Default | Description |
--profile | str | slow-3g | Throttle profile name |
--download | int | None | Custom download speed in bytes/s |
--upload | int | None | Custom upload speed in bytes/s |
--latency | int | None | Custom latency in ms |
--cwv | flag | off | Measure CWV under throttling |
--output | str | stdout | Output file path |
--timeout | int | 60000 | Timeout in ms (longer for slow profiles) |
Network Inspection
inspect command
Inspect all network requests during page load:
wavexis inspect https://example.com --output network.jsoninspect with filter
wavexis inspect https://example.com \
--url-filter "*/api/*" \
--method "POST" \
--output api-calls.jsoninspect output
{
"requests": [
{
"url": "https://api.example.com/data",
"method": "GET",
"resource_type": "fetch",
"status": 200,
"status_text": "OK",
"mime_type": "application/json",
"encoded_size": 512,
"decoded_size": 1024,
"time": 45,
"protocol": "h2",
"from_cache": false,
"from_service_worker": false
}
],
"total_requests": 1,
"total_size": 1024,
"total_time": 45
}inspect options
| Option | Type | Default | Description |
--url-filter | str | None | URL pattern filter (regex) |
--method | str | None | HTTP method filter |
--resource-type | str | None | Resource type filter |
--status | int | None | Status code filter |
--include-bodies | flag | off | Include request/response bodies |
--output | str | stdout | Output file path |
--wait-for | str | None | Wait for selector before stopping |
--timeout | int | 30000 | Timeout in ms |
HAR Replay
har-replay command
Replay a captured HAR file against a target URL:
wavexis har-replay ./traffic.har --target https://staging.example.comhar-replay with verification
wavexis har-replay ./traffic.har \
--target https://staging.example.com \
--verify \
--output replay-results.jsonhar-replay options
| Option | Type | Default | Description |
--target | str | required | Target URL to replay against |
--verify | flag | off | Compare responses with original HAR |
--delay | int | 0 | Delay between requests in ms |
--url-filter | str | None | Only replay matching URLs |
--output | str | stdout | Output file path |
--timeout | int | 60000 | Timeout in ms |
WebSocket Inspection
WebSocket frame capture
wavexis inspect https://example.com \
--websocket \
--output ws-traffic.jsonWebSocket output
{
"websockets": [
{
"url": "wss://example.com/ws",
"frames": [
{
"direction": "send",
"data": "{\"type\": \"subscribe\", \"channel\": \"updates\"}",
"timestamp": 1234567890
},
{
"direction": "receive",
"data": "{\"type\": \"update\", \"data\": {...}}",
"timestamp": 1234567891
}
]
}
]
}Multi-Action YAML
HAR capture with interaction
actions:
- navigate:
url: https://example.com
wait_until: networkidle
- har:
url_filter: "*/api/*"
include_bodies: true
output: api-traffic.har
- click:
selector: "#load-data"
- wait_for:
selector: ".results"
- har_stop:
output: full-traffic.harMock and test
actions:
- mock:
url: "*/api/users"
status: 200
body: '{"users": [{"id": 1, "name": "Test User"}]}'
content_type: application/json
- navigate:
url: https://example.com
wait_until: networkidle
- assert:
text: "contains Test User"
- screenshot:
full_page: trueThrottle and measure
actions:
- throttle:
profile: slow-3g
- navigate:
url: https://example.com
wait_until: load
- cwv:
mobile: true
output: cwv-throttled.json
- screenshot:
full_page: trueBest Practices
- Use
--include-bodiessparingly — bodies can make HAR files very large. - Filter by URL — use
--url-filterto focus on relevant traffic. - Mock external APIs in tests — don't depend on third-party services in CI.
- Throttle with CWV — always measure CWV under
slow-3gfor real-world performance. - Block trackers in tests — use
intercept --blockto remove noise from analytics. - Verify HAR replays — use
--verifyto detect API response changes. - Save HAR files as artifacts — useful for debugging network issues in CI.
- Use custom throttle for specific scenarios — simulate your users' actual network conditions.
- Inspect WebSocket frames — debug real-time communication issues.
- Mock with realistic delays — use
--delayto simulate real API latency.
Common Pitfalls
- HAR files too large — use
--url-filterand avoid--include-bodiesfor large sites. - Mock not matching — URL patterns are regex; escape special characters.
- Throttle profile too slow —
slow-3gcan cause timeouts; increase--timeout. - Intercept blocking too much — use
--allowto whitelist critical resources. - HAR replay URL mismatch — the target URL must serve the same paths as the original capture.
- WebSocket frames missing — use
--websocketflag explicitly; not captured by default. - Modify headers not applied — modifications only apply to requests made after navigation starts.
- Mock delay causing timeout — keep mock delays shorter than
--timeout.
References
references/har-format.md— HAR file format referencereferences/network-patterns.md— Common network testing patternsassets/templates/har-capture.yml— HAR capture templateassets/templates/mock-api.yml— API mocking templateassets/templates/throttle-test.yml— Network throttling template- HAR 1.2 Specification
- Chrome DevTools Network
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

