# `bird whatsapp agents files download`

## Usage

```bash
bird whatsapp agents files download <number-id> <file-id> [flags]
```

## Description

Download a file the agent on a WhatsApp number holds. The file id is the `id` on
an entry from `bird whatsapp agents files list`.

The bytes are written to --output when set, otherwise to stdout:

bird whatsapp agents files download wan\_123 waf\_456 --output returns.pdf

--url prints the short-lived download URL (valid for 15 minutes) instead of
downloading, for handing to another tool. That URL is pre-authorized and needs
no Authorization header; the follow-up request must not send one. --url and
--output cannot be combined.

## Examples

```bash
bird whatsapp agents files download <number-id> <file-id> --output returns.pdf
```

## Options

| Name           | Description                                               |
| -------------- | --------------------------------------------------------- |
| `--output, -o` | Write the bytes to this file instead of stdout            |
| `--url`        | Print the short-lived download URL instead of downloading |

## Related

| Name                                                                                    | Description                    |
| --------------------------------------------------------------------------------------- | ------------------------------ |
| [`bird whatsapp agents files delete`](/docs/cli/reference/whatsapp-agents-files-delete) | Remove one of an agent's files |
| [`bird whatsapp agents files get`](/docs/cli/reference/whatsapp-agents-files-get)       | Get one of an agent's files    |
| [`bird whatsapp agents files list`](/docs/cli/reference/whatsapp-agents-files-list)     | List an agent's files          |
| [`bird whatsapp agents files upload`](/docs/cli/reference/whatsapp-agents-files-upload) | Upload a file to an agent      |

## Related resources

- [Should I use a Bird SDK or call the API directly?](/explained/platform/should-i-use-an-sdk-or-call-the-api-directly) (answer)
- [Build your first integration](/learn/paths/integration) (course)
- [Send your first email](/docs/get-started/send-your-first-email) (docs)

[Get an implementation brief](/learn/workspace?topic=api-basics)
