zshot/cliDownload

Additional Assets

A render returns its primary output as the response body. It can also produce additional artifacts. Request each with its matching with_* field: with_har, with_warc, with_archive_cdx, with_pprof_cpu, with_pprof_memory, with_trace, with_navigator_video, with_network_log, and with_axtree. Most are booleans; with_axtree instead takes true/json for the JSON accessibility tree or text for the indented snapshot. with_archive_cdx produces a CDXJ index of the WARC and requires one: output_type=warc or with_warc=true.

Each asset the server produces is written to a temporary location and advertised with a Link header on the render response, one per asset:

Link: </assets?file=<id>.har>; rel="related"; type="application/json"

The URL is relative, so it resolves against whatever host or reverse proxy fronts the server. Fetch the asset with a GET to that URL. Its lifetime is set by --server-additional-asset-expiration; after it expires the URL returns 404. A lifetime of 0 turns additional assets off: the server writes none and sends no Link headers.

When the server requires signed URLs, each asset link is signed and its expires is the asset’s lifetime, capped by --server-signed-url-max-age.