- In the workflow, a File step attaches the file to the case with Export file enabled.
- The workflow writes the file’s URL into a case attribute (a Case update step referencing the File step’s
urloutput). - Your backend reads the attribute from the cases API and fetches the URL with your API token.
The file URL
An exported case file is addressed by a stable URL:401, and even a valid token
from a different organization gets a 404, so passing it around in tickets, emails, or logs doesn’t expose the
file.
Download a file
Send aGET request with your API token:
string
required
Path parameter. The file’s ID — the last segment of the URL the workflow wrote into the case attribute. You
never construct this yourself; always use the full URL the workflow produced.
string
required
Request header.
Bearer <YOUR_API_TOKEN> — an API-scoped token from the
Tokens page, the same token the cases API uses.302 redirect: Location holds a short-lived storage link (valid for about a minute) that
serves the bytes, and the body carries the same link as JSON for clients that prefer an explicit second request:
fetch,
python-requests, and Go all drop the Authorization header on the cross-host hop, which is exactly right.
The final response serves the file with its original filename in Content-Disposition.
Exporting a file
Only exported files can be downloaded externally. Export is a per-file decision the workflow makes: the External access setting on the File step. A file attached as Internal only stays internal — its URL still works inside the workflow (for example as an LLM file input), but external requests get a404.
Once a run exports a file it stays exported; retries of the step don’t change that.
There is no listing endpoint — your systems learn about a file when the workflow hands its URL over, normally
through a case attribute you read from the cases API or receive in a
webhook payload.
Pre-signed links
If your systems can’t call an authenticated API at all — the file needs to reach a human clicking a link in a ticket or email — the File step offers a third mode: Export + pre-signed link. Besides exporting the file, the step’s output then includes a second URL,presigned_url, that serves the file directly with no API token.
Trade-offs versus the stable URL:
- It expires after 7 days. Don’t store it — anyone clicking later gets an error. The stable URL on the same output never expires.
- It grants access by itself. Anyone holding the link can download the file until it expires, so treat it like the file’s contents, not like an identifier.
- It can’t be revoked — the only control is the 7-day expiry.
Errors
Errors return a JSON body with an
error message.
