Skip to main content
Files in a signed folder can only be fetched with a link that carries an expiry time (exp) and an HMAC-SHA256 signature (sig). signed_url() builds that link locally — no network call, no API key in the result.

Signature

Unlike url(), this needs the asset, not just its URL: the signature is computed over the asset’s id.

What is signed

The signature covers the asset id and the expiry time — HMAC-SHA256 over "{id}:{exp}" — and nothing else. One signed link can therefore be resized by a frontend (&width=…) without being signed again. Once the link expires, or if anyone edits exp or sig, the API answers 401.
A signed URL is a bearer token. Anyone holding it can fetch the file until it expires, with no API key. Keep expiry times short.

Access control is set on folders

Access control is set on top-level folders and inherited by everything beneath them. Create the signed folder first, then upload under it:
See Private media and Signed URLs.

Errors

Calling it without a signing secret raises DreepError — the SDK has nothing to sign with. Set signing_secret on the client, or the DREEP_SIGNING_SECRET environment variable; it is on the API Keys page of your dashboard.