> ## Documentation Index
> Fetch the complete documentation index at: https://docs.browspark.krishm.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# devtools_network

> Inspect network activity collected in the session (preserved across reloads).

Inspect network activity collected in the session (preserved across reloads). Actions: search (filters below; searchIn picks url/headers/body/postData), get (one request: headers, timing, initiator stack, redirects, security), body (response body, JSON pretty-printed; fetched on demand if not captured), frames (WebSocket frames or SSE messages), har (export HAR artifact), throttle, cache, block/unblock, mock/unmock/rules, replay, clear.

## Parameters

<ParamField body="tabId" type="integer">
  Target tab id from browser\_tabs, which lists tabs across all windows. Defaults to the agent's most recently opened usable tab, or the only usable tab. Otherwise select a listed tabId.
</ParamField>

<ParamField body="action" type="enum" required default="search">
  One of: `search`, `get`, `body`, `frames`, `har`, `throttle`, `cache`, `block`, `unblock`, `mock`, `unmock`, `rules`, `replay`, `clear`.
</ParamField>

<ParamField body="query" type="string">
  Text or regex
</ParamField>

<ParamField body="regex" type="boolean">
   
</ParamField>

<ParamField body="searchIn" type="enum[]">
  Default url Items: `url`, `headers`, `body`, `postData`.
</ParamField>

<ParamField body="method" type="string">
   
</ParamField>

<ParamField body="status" type="string">
  e.g. "404", "4xx,5xx", "500-599"
</ParamField>

<ParamField body="domain" type="string">
   
</ParamField>

<ParamField body="type" type="string[]">
  Resource types: Document, XHR, Fetch, Script, Stylesheet, Image, Font, WebSocket, Other…
</ParamField>

<ParamField body="minDurationMs" type="number">
   
</ParamField>

<ParamField body="failed" type="boolean">
   
</ParamField>

<ParamField body="since" type="string">
   
</ParamField>

<ParamField body="until" type="string">
   
</ParamField>

<ParamField body="requestId" type="string">
   
</ParamField>

<ParamField body="maxChars" type="integer">
  Body chars to return, default 20000
</ParamField>

<ParamField body="bodyOffset" type="integer">
   
</ParamField>

<ParamField body="preset" type="enum">
  One of: `none`, `offline`, `slow3g`, `fast3g`, `4g`.
</ParamField>

<ParamField body="latencyMs" type="number">
   
</ParamField>

<ParamField body="downloadKbps" type="number">
   
</ParamField>

<ParamField body="uploadKbps" type="number">
   
</ParamField>

<ParamField body="disabled" type="boolean">
  For cache: true disables the cache
</ParamField>

<ParamField body="patterns" type="string[]">
  URL globs for block/unblock, e.g. "*analytics*"
</ParamField>

<ParamField body="pattern" type="string">
  URL glob for mock/unmock
</ParamField>

<ParamField body="response" type="object">
   
</ParamField>

<ParamField body="overrides" type="object">
  For replay
</ParamField>

<ParamField body="offset" type="integer">
  Pagination offset, default 0 Range: 0 to ….
</ParamField>

<ParamField body="limit" type="integer">
  Page size, default 50 Range: 1 to 500.
</ParamField>

## Example

```json Slow API calls theme={null}
{
  "tabId": 1234,
  "domain": "api.example.com",
  "minDurationMs": 500
}
```

```json Response body theme={null}
{
  "tabId": 1234,
  "action": "body",
  "requestId": "1234.56"
}
```

```json Mock an endpoint theme={null}
{
  "tabId": 1234,
  "action": "mock",
  "pattern": "*/api/user",
  "response": {
    "status": 200,
    "headers": {
      "content-type": "application/json"
    },
    "body": "{\"name\":\"Test User\"}"
  }
}
```

```json Throttle to slow 3G theme={null}
{
  "tabId": 1234,
  "action": "throttle",
  "preset": "slow3g"
}
```

```json Export HAR theme={null}
{
  "tabId": 1234,
  "action": "har"
}
```
