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

# Private Files & Presigned URLs

> Store files privately and download them via time-limited presigned URLs.

# Private Files

By default, files stored in Rendi are served from a public storage domain — the `storage_url` in poll and get responses is directly downloadable by anyone who has the link. For workloads with stricter access requirements, Rendi supports **private storage**: files placed there have no public URL and can only be downloaded via a short-lived presigned URL that you request on demand.

<Note>
  Private storage is not available on trial plans.
</Note>

## Marking a File as Private

Pass `is_private: true` on any endpoint that produces a stored file:

* [`POST /v1/run-ffmpeg-command`](/api-reference/endpoint/run-ffmpeg-command) — command's output files land in private storage
* [`POST /v1/run-chained-ffmpeg-commands`](/api-reference/endpoint/run-chained-ffmpeg-commands) — same for chained outputs
* [`POST /v1/files/store-file`](/api-reference/endpoint/store-file) — the file you're storing lands in private storage
* [`POST /v1/files/init-upload`](/api-reference/endpoint/init-upload) — direct upload lands in private storage

The file's row reflects this via `is_private: true` in every response that returns it.

## Downloading a Private File

The `storage_url` field on a private file is `null` — the file has no public location. To download it, ask the poll endpoint for a **presigned URL**: a signed, time-limited URL that grants read access for a duration you choose.

Pass `presigned_ttl_seconds` as a query parameter:

* [`GET /v1/files/{file_id}?presigned_ttl_seconds=3600`](/api-reference/endpoint/get-file)
* [`GET /v1/commands/{command_id}?presigned_ttl_seconds=3600`](/api-reference/endpoint/poll-command)

The response's `storage_url` is replaced with a presigned URL valid for the requested number of seconds. Maximum TTL is 7 days.

<Note>
  If the file is public (or hasn't finished processing yet), the parameter is ignored and the response's `storage_url` is unchanged.
</Note>

## Reusing Private Files as Command Inputs

To use a private file as an input to another `run-ffmpeg-command`, request a presigned URL for it first, then pass that URL in `input_files` as you would any other. Set a `presigned_ttl_seconds` value comfortably larger than your expected queue-wait + processing time so the URL is still valid when the backend downloads it.
