Skip to main content
Glama

Robot Actions — Remote Device Control

iOS Safari capture network

ios_safari_capture_network
Read-onlyIdempotent

Capture network requests made by a Safari page on an iOS device over a time window. Collects Network.requestWillBeSent, Network.responseReceived, Network.loadingFinished, and Network.loadingFailed events and returns merged records. Returns { records, bodiesOmitted? } in summary format, or a HAR 1.2 document when format="har". Each record: { requestId, method, url, requestHeaders?, status?, statusText?, mimeType?, resourceType?, responseHeaders?, encodedDataLength?, state, errorText?, startTimestamp?, endTimestamp?, body?, bodyTruncated?, bodyError? }. Set includeBodies=true to fetch response bodies for completed text-like responses (json|text|xml|javascript|html|css|svg|x-www-form-urlencoded); per-body cap: 10 000 chars (bodyTruncated=true when hit); total cap: 200 000 chars (excess records counted in bodiesOmitted). Body fetch failures set bodyError on that record. Set throttle to emulate bandwidth for the capture window only (best-effort; cleared afterwards): slow-3g (51 200 B/s) or fast-3g (209 715 B/s). NOTE: throttle="offline" is NOT supported on iOS — WebKit only has bandwidth throttling; use android_devtools_capture_network for offline. When throttle was active, a top-level throttle field appears in the output. Returns at most limit records (default 100, most-recent first) so heavy pages stay within the token budget — filter with urlSubstring / onlyErrors; total/returned appear when records were dropped. Default window: 5 000 ms. Maximum: 30 000 ms. Omit pageId to auto-pick the active page. Pass url to navigate inside the capture session and record the full page-load waterfall (pass the current URL to reload). NOTE: some iOS versions report no request timings to a remote inspector. The result then says timestamped=false, startTimestamp/endTimestamp are omitted and no duration can be derived — what each request was and how it answered is still accurate, so do not read speed from a capture that reports it.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
urlNoNavigate the page to this URL inside the capture session to record the full page-load waterfall (pass the current URL to reload)
udidYesiOS device UDID
limitNoMax records to return, most-recent first (default 100). Heavy pages make hundreds of requests; the default keeps the response within the MCP token budget. total/returned are included when records were dropped.
formatNoOutput format: "summary" (default) returns { records, bodiesOmitted? }; "har" returns a HAR 1.2 document
pageIdNoCDP target id from ios_safari_list_pages. Omit it to use the page ios_safari_navigate last landed on (or, failing that, the first loaded page) — only pass it to target a DIFFERENT tab
throttleNoEmulate bandwidth for the capture window only (best-effort; cleared afterwards). slow-3g: 51 200 B/s. fast-3g: 209 715 B/s. offline is NOT supported on iOS — use android_devtools_capture_network instead.
triggerJsNoJavaScript run INSIDE the capture window (after the collector attaches) to trigger requests race-free — e.g. "fetch('/api/x')" or a click. For a full-page navigation prefer the `url` param. Both avoid the attach-race of triggering from a separate call.
durationMsNoCollection window in milliseconds (default: 5000, max: 30000)
onlyErrorsNoOnly failed / 5xx records
urlSubstringNoOnly records whose URL contains this substring — target the requests you care about
includeBodiesNoFetch response body for completed text-like responses (default: true). Request bodies (postData) are always captured. Set false to skip response bodies for a lighter payload. Per-body cap: 10 000 chars. Total cap: 200 000 chars.
platformVersionNoIgnored (kept for compatibility)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / pageId / description
      Previous value: -"CDP target id from ios_safari_list_pages — auto-picked when omitted"New value: +"CDP target id from ios_safari_list_pages. Omit it to use the page ios_safari_navigate last landed on (or, failing that, the first loaded page) — only pass it to target a DIFFERENT tab"
  2. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already declare readOnly/idempotent/non-destructive, yet the description adds substantial behavioral context beyond them: per-body and total body caps with bodyTruncated/bodiesOmitted flags, throttle being best-effort and cleared afterwards with a top-level throttle field, and the important timestamped=false caveat where timings are omitted.

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?

Front-loaded with purpose, output shape and record fields, then parameter behavior and NOTE caveats. It is dense and slightly redundant with the schema on throttle and includeBodies, but nearly every sentence carries actionable information and the NOTE markers aid scanning.

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?

With no output schema, the description fully carries the burden of explaining return values (summary vs HAR, per-record field list, caps and omission flags) plus the platform limitation that timings may be absent. An agent has everything needed to call it and interpret results.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3; the description goes further by explaining the rationale for limit (token budget, total/returned on drops), the includeBodies caps and bodyError behavior, and the throttle field appearing in output when active — details not present in the schema.

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?

States a specific verb+resource+scope: capturing network requests from a Safari page on an iOS device over a time window, and enumerates the CDP events merged. It is clearly distinguishable from ios_pcap_start, ios_traffic_flows and ios_safari_trace, and even names the Android counterpart for the offline case.

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

Usage Guidelines4/5

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

Provides concrete routing guidance: omit pageId to auto-pick the active page, prefer url for full-page navigation vs triggerJs for race-free triggers, and use android_devtools_capture_network when offline throttling is needed. It lacks an explicit when-not against other capture siblings (ios_traffic_flows, ios_pcap_start), but the context given is strong.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources