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

# Get a file from a run

> Download a file a run returns, once, from its single-use link.

This page shows how to download a file a run collects, such as a statement. The run's result holds it as a `$file` object:

```json theme={null}
{
  "statement": {
    "$file": {
      "id": "file_9c8b7a6f5e4d3c2b1a0f9e8d7c6b5a4f",
      "name": "statement-2026-09.pdf",
      "media_type": "application/pdf",
      "size": 182044,
      "sha256": "5f2d...",
      "download_url": "https://.../v1/file-downloads/...",
      "expires_at": "2026-10-08T17:30:00.000Z"
    }
  }
}
```

## Download the file

Fetch `download_url` once, with no `Authorization` header:

```bash theme={null}
curl -o statement.pdf "$DOWNLOAD_URL"
```

Save the body before anything else. Pomerado erases the file as soon as one download sends its last byte, whether or not your client saved it. Compare the bytes with `sha256` to confirm they are complete.

A download that breaks off before its last byte may start again until `expires_at`. An undownloaded file is erased after 30 minutes.


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