Skip to main content
Glama

webview_network

Capture fetch and XMLHttpRequest traffic from WebViews in iOS simulators and export as JSON or redacted HAR log to debug network issues.

Instructions

Captures HTTP traffic made INSIDE a WebView (fetch + XMLHttpRequest) and exports it as JSON or a redacted HAR 1.2 log. This is the network-debugging path for WebView-based apps — RN shells that host their UI in a WKWebView, where the API calls run in the web layer so metro_network (CDP Network domain) captures nothing. It injects a fetch/XHR recorder into the page, captures for durationMs while you drive the app, then returns request/response metadata (url, method, status, headers, timing). Only requests made AFTER capture starts are recorded. format:'har' emits a valid HAR 1.2 log (HAR-lite — no response bodies) openable in Chrome DevTools → Import HAR; pass saveTo to write the .har file. Sensitive headers (authorization/cookie/…) and request bodies are REDACTED by default — set redact:false to keep them (don't commit unredacted HAR: it leaks tokens). Requires the app's WKWebView to be inspectable (isInspectable=true) — on by default in debug/staging builds, frequently disabled in production App Store builds.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
udidYesSimulator / device UDID
webviewIdNoTarget WebView id. Omit to auto-select the first visible WebView.
durationMsNoHow long to capture (ms) while you drive the app (default 5000)
formatNoOutput format: 'json' (default, structured entries) or 'har' (HAR 1.2 log).
saveToNoOptional file path to write the output (a .har file when format:'har').
redactNoMask sensitive headers (authorization/cookie/…) and request bodies. Default true.
includeResourcesNoAlso include the browser's retroactive Performance Resource Timing list — EVERY request the document made since navigation, including ones that fired before capture started (URL + timing + size, but no headers/body). Default true. Set false for fetch/XHR only (with full headers + bodies).
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Given no annotations, description fully discloses behavioral traits: injection mechanism, capture duration, recording only after start, redaction of sensitive data, HAR format validation, and inclusion of performance resource timing. Also warns about not committing unredacted HAR.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Long but every sentence adds value. Well-structured with clear main purpose first, then context, then parameter details. Could be slightly tighter, but no redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex tool with no annotations and no output schema, description covers behavior, parameters, output format, side effects, prerequisites, and security warnings. Thoroughly explains the tool's role in the debugging workflow.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, but description adds significant value beyond schema: explains default for redact, clarifies includeResources behavior, details format:'har' usage and saveTo, and provides context for each parameter.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Clearly states it captures HTTP traffic from WebView and exports as JSON or HAR. Distinguishes from sibling metro_network, which uses CDP and doesn't work for WebView-based apps.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly explains when to use (WebView-based apps like RN shells) and when not (metro_network instead). Also mentions requirements: WKWebView inspectable and debug/staging builds.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/hoainho/podium-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server