zshot/cliDownload

--network-log

CLI
--network-log
ValuePATH

Writes a JSON log of the page’s network requests alongside the render: when each started and completed, with its status, content type and size. On the server, the log is returned as a Link response header.

Example Output

{
  "url": "https://zshot-cli.com/example_assets/hello_zshot/",
  "log": [
    {
      "type": "start",
      "timestamp_ms": 0,
      "url": "https://zshot-cli.com/example_assets/hello_zshot/",
      "outcome": "allowed"
    },
    {
      "type": "complete",
      "timestamp_ms": 222,
      "url": "https://zshot-cli.com/example_assets/hello_zshot/",
      "duration_ms": 222,
      "http_status": 200,
      "content_type": "text/html",
      "bytes_received": 504
    },
    {
      "type": "start",
      "timestamp_ms": 223,
      "url": "https://zshot-cli.com/example_assets/hello_zshot/style.css",
      "outcome": "allowed"
    },
    {
      "type": "complete",
      "timestamp_ms": 428,
      "url": "https://zshot-cli.com/example_assets/hello_zshot/style.css",
      "duration_ms": 204,
      "http_status": 200,
      "content_type": "text/css",
      "bytes_received": 1385
    }
  ]
}

Example

Run locally
zshot -f page.png \
  --network-log page.network.json \
  https://zshot-cli.com/example_assets/hello_zshot/