> For the complete documentation index, see [llms.txt](https://docs.fylr.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.fylr.io/for-developers/api/endpoints/eas/download.md).

# /download

The download endpoint is used to deliver binary file data. It delivers data for original files as well as renditions. These URL to the files should be taken from the responses of `/api/db` or `/api/search`.

### `GET /eas/download/{fileId}/{hash}/{version}`

{% openapi src="/files/kfiDjhyZfEICNBmt5f49" path="/eas/download/{fileId}/{hash}/{version}" method="get" %}
[fylr-openapi.yml](https://4100607288-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAdRFzQASDY2Elfdm3wXW%2Fuploads%2Fgit-blob-c66962d021f9281075604517b7590deaf0d3f984%2Ffylr-openapi.yml?alt=media)
{% endopenapi %}

### `HEAD /eas/download/{fileId}/{hash}/{version}`

{% openapi src="/files/kfiDjhyZfEICNBmt5f49" path="/eas/download/{fileId}/{hash}/{version}" method="head" %}
[fylr-openapi.yml](https://4100607288-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAdRFzQASDY2Elfdm3wXW%2Fuploads%2Fgit-blob-c66962d021f9281075604517b7590deaf0d3f984%2Ffylr-openapi.yml?alt=media)
{% endopenapi %}

### `GET /eas/download/{fileId}/{hash}/{version}/{zippath}`

{% openapi src="/files/kfiDjhyZfEICNBmt5f49" path="/eas/download/{fileId}/{hash}/{version}/{zippath}" method="get" %}
[fylr-openapi.yml](https://4100607288-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAdRFzQASDY2Elfdm3wXW%2Fuploads%2Fgit-blob-c66962d021f9281075604517b7590deaf0d3f984%2Ffylr-openapi.yml?alt=media)
{% endopenapi %}

### `HEAD /eas/download/{fileId}/{hash}/{version}/{zippath}`

{% openapi src="/files/kfiDjhyZfEICNBmt5f49" path="/eas/download/{fileId}/{hash}/{version}/{zippath}" method="head" %}
[fylr-openapi.yml](https://4100607288-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FAdRFzQASDY2Elfdm3wXW%2Fuploads%2Fgit-blob-c66962d021f9281075604517b7590deaf0d3f984%2Ffylr-openapi.yml?alt=media)
{% endopenapi %}

### Paths inside a ZIP

The `{zippath}` form reads one entry out of a ZIP stored as an original or a version — a page of a `pages.zip`, a file of an archive — without downloading the whole ZIP, range requests included. The ZIP is read on demand: no special version and no particular extension is required, and holding `asset_show` on the record is enough. It works for files in any connected storage location, S3 included; a file that is not stored in a location — one left at its remote URL via `leave_on_remote` — fails with `ZipPathNotSupported`, the endpoint's one restriction.

A directory listing of a ZIP (from **6.35.0**) reports each entry's `mod_time` from the extended UTC timestamp where the archive carries one, instead of the legacy MS-DOS field, and directory entries carry a `mod_time` as well; `size` stays omitted for directories.
