> ## Documentation Index
> Fetch the complete documentation index at: https://browser-mcp.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Direct download links

# Direct download links — 0.3.14

Lets MCP clients fetch files with ordinary HTTPS GET links, superseding the earlier client import bridge direction. No database migration is needed. Published in 0.3.14; the original implementation checks below preceded that release.

## Client contract

* `browser_create_download {downloadId}` returns a ready-to-use HTTPS GET bearer URL for a completed Chrome download. Legacy `fileId` is accepted.
* `browser_export_page` and `browser_run_js` artifacts return URLs immediately in ordinary tool text, HTTPS resource links and `resources[]`; no resource-reading operation is required. Two or more files also come as one tar bundle with a ready-to-run command (see [several files](#several-files-one-bundle-one-command)).
* `browser_screenshot` with `deliver: "file"` or `"both"` returns the capture, of the page or of one element by `ref` or `selector`, the same way at full resolution: one file in `resources[]` with `sourceKind: "screenshot"` and its pixel `width` and `height`.
* `browser_create_download {resourceUri}` reissues one retained export/artifact link; `{resourceUris:[…]}` reissues several, with a new bundle, in one call.
* `url` and `capability.url` identify the same one-use link. Metadata includes `name`, `mimeType`, `size`, `sha256`, `sourceKind`, link `expiresAt` (epoch milliseconds), separate `retainedUntil`, and an explicit `reissue` selector. Download capability `headers` is empty.
* An ordinary shell uses `curl --fail --output file "$DOWNLOAD_URL"`, checks size/SHA-256 and processes the local file. No Browser MCP headers/cookies, custom client adapter or chat import tool is necessary. Output permissions/overwrite protection are the caller's responsibility. Do not follow redirects or automatically retry.
* The bearer URL is intentionally visible to the model, conversation history and shell logs. Any holder can redeem it before expiry/revocation. Do not publish URLs, tokens, cookies or private content in issues/releases. Broad MCP/runtime credentials and upload/secret-export grants are unchanged.

## Several files: one bundle, one command

When one `browser_run_js`, `browser_export_page` or `browser_create_download {resourceUris}` call returns two or more files, the result also carries `bundle`, one single-use HTTPS GET link to a POSIX tar archive of all of them, and its text has one ready-to-run shell command, for example (placeholders in capitals):

```sh theme={null}
curl --fail --silent --show-error --output browser-mcp-1f3c9a2e.tar 'https://HOST/api/native-data/ID/download/TOKEN' && echo 'SHA256  browser-mcp-1f3c9a2e.tar' | if command -v sha256sum >/dev/null; then sha256sum -c; else shasum -a 256 -c; fi && mkdir browser-mcp-1f3c9a2e && tar -xf browser-mcp-1f3c9a2e.tar -C browser-mcp-1f3c9a2e && rm browser-mcp-1f3c9a2e.tar
```

It fetches the archive once, checks its SHA-256 (`sha256sum` on Linux, `shasum` on macOS), unpacks every file into the new directory `browser-mcp-<id>` and removes the archive. A failed step stops the rest: nothing is unpacked from an archive whose hash does not match, and an existing directory is never written into. It needs a POSIX shell (sh, bash, zsh), curl and tar. The command holds only server-made strings (the archive and directory names, the URL and the hash), never a file name chosen by a page or script.

In the archive each file has its own name in Unicode NFC, made unique without regard to case (`data.json`, `data-2.json`), with mode 0600; each entry of `resources[]` gives its `bundleName`. The archive is streamed from the retained bytes of its files, so it takes no extra server memory. It has no `resource_link` block, so a client that fetches those does not use it up. `bundle` holds `name`, `directory`, `files`, `size`, `sha256`, `mimeType` (`application/x-tar`), `expiresAt`, `url`, `capability` and `reissue`. The per-file links stay usable on their own. If the bundle link cannot be issued, `bundle` carries `linkError` (`bundle_link_unavailable`, or `bundle_too_large` when the files exceed 256 MiB) and the per-file links still work.

`bundle.reissue` is `browser_create_download {resourceUris:[…]}` with every file's `resourceUri`: one call returns a new link per file and a new bundle and command, without repeating the script or export. It accepts 1–32 resources retained for the session. Ones that are gone are listed in `unavailable` and get no link; the call is refused before admission (`resource_unavailable`, `retrySafe: true`) only when none is available.

## Server guarantees and limits

Creation/reissue requires the authenticated originating browser/credential/session/runtime generation. The download URL contains a random 256-bit bearer token; only its hash is retained in gateway leases. GET requires neither an MCP token nor browser cookies. Scope authority is checked at creation, redemption and every second while active, with bounded fail-closed checks. Browser/session/token revocation aborts active access.

Links to retained export/artifact/screenshot-file bytes (per file and bundle) last at most **5 minutes**, links to Chrome downloads at most **60 seconds**; both are bounded by source and issuer expiry, including stream completion. Retained bytes hold no stream slot until their link is fetched, so their links can wait for an agent's next turn. Each admits one GET. Valid-but-unusable URLs return **410** with `link_expired`, `link_used`, `link_revoked` or `link_failed`. Invalid/unknown/purged URLs return **404**; unsupported method/Range returns **400** without consuming a valid link. Capacity before stream admission returns **429**. These errors contain recovery guidance, never automatic replay. HTTP responses are no-store attachments, with safe filename/MIME, content length when known, nosniff and no-referrer.

Byte/time/memory/concurrency limits remain: 256 MiB native file, 20 MiB export/artifact blob, bounded source retention and global/browser/session reservations, four concurrent streams per session and 32 globally. Retained export/artifact links reserve bytes at issuance but open streams on GET, supporting 32 artifacts in one result without opening 32 simultaneous streams. A link-issuance failure preserves the completed source selector with `linkError` rather than encouraging another browser action.

`browser_cancel_transfer {transferId}` revokes a link, not the source. Reissue from the same retained `resourceUri` (or several `resourceUris` at once) or `downloadId` using `browser_create_download` and a **new idempotency key**; it never repeats the website request/export/script. A repeated original key recovers the same URL, possibly expired or used, without issuing another transfer. Download URLs may appear in bounded ordinary receipts. Header-only upload/secret-export capabilities remain absent from durable receipt replay.

Runtime disconnect/pause/session end/source expiry can destroy retained bytes. Reconnect does not restore them. If bytes are unavailable, a new source action requires an explicit task decision. Browser-specific recovery stays in Browser MCP tool descriptions/results; clients need no browser-aware recovery layer. See [full workflow and recovery](runtime-recovery-and-transfers.md) and [native data limits](https://browser-mcp.mintlify.site/native-data.md).

An initial `browser_create_download` lookup that cannot select an available retained
resource returns `resource_unavailable`, `rejectedBeforeAdmission:true`, and
`retrySafe:true`: no download link or byte transfer was created by that call.
Missing, expired, revoked, out-of-scope and unready download IDs use the same
non-enumerating refusal; it does not establish existence or ownership. Select an
available ID with `browser_list_downloads` **in this session**, or use a retained
`resourceUri` from this session's export/artifact result. `retrySafe` concerns the
refused link request only, not permission to recreate bytes or replay a website
action, export or script. Failures after transfer admission, timeouts and lost
replies can still have `outcome:unknown` and `retrySafe:false`; inspect status and
never automatically replay them. This runtime classification requires the updated
CLI; a server update alone cannot reclassify an older CLI's generic transfer error.

## Manual verification (2026-10-20)

No automated suites were run. Existing assertions were updated where their old header/resource-link contract changed; they remain unrun. Typechecks, Community and Managed frontend/server builds, and the Node CLI build passed.

An isolated local PostgreSQL database, real Community server, verified local HTTPS reverse proxy, real NativeRuntime/Relay and disposable Chromium served synthetic content only. Generic MCP client and **ordinary curl with only local CA trust** verified:

* Browser-authenticated PDF download → direct GET → exact size/SHA-256 → expected local `pdftotext` content. Original fixture URL without browser authentication returned no document.
* HTML page export and Uint8Array binary artifact returned direct URLs immediately, with exact size/SHA-256 and expected local content/bytes.
* 32 artifacts in one result produced 32 links without stream exhaustion; an individual link downloaded correctly.
* Reissue after successful GET returned identical retained bytes; website request counter did not increment. Same idempotency-key replay returned the original URL, not a fresh transfer.
* Used and explicitly cancelled links returned 410 `link_used`/`link_revoked`; a real 60-second expiry returned 410 `link_expired`; fresh reissue after expiry delivered the retained artifact correctly.
* Cross-session reissue was refused; links required no special headers or browser cookies.
* An independent HTTPS gateway probe verified denied issuers, wrong URL token, method/Range/cookie/Origin rejection, stream-capacity admission, issuer revocation on GET, oversize-producer failure, zero-byte artifacts, attachment headers, safe malformed-name/MIME handling and the built Node CLI download helper. A probe rerun after the bounded lease-metadata purge correctly returned 404 rather than 410; a fresh link then verified actual 60-second expiry and retained-byte reissue again.

The coordinating chat task also verified the actual local Community UI and real model conversation: the model used three ordinary curl commands for the authenticated PDF (14,668 bytes), HTML export (218 bytes) and binary artifact (5 bytes). Independent checks matched each result's size/SHA-256, expected PDF text and binary bytes. The fixture's website-download counter increased exactly once. A missing-source `transfer_failed` result remained visible unchanged in both structured and JSON-text content, without capture masking. Reloaded UI preserved the successful conversation; no import tool, transfer-vault rows or published artifacts were created. No tokens, bearer URLs, cookies or document contents are included in this receipt.

This receipt does not claim deployed verification or every platform's Chrome behavior. The disposable headless Chromium fixture disabled its sandbox for synthetic-only host testing; normal sandboxed CLI startup was not verified here. The server/CLI/database schema version remains unchanged pending an authorized release.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.