GET /v1/files/{file_id}/content
Returns a File content link. The returned URL is time-limited and can be used to download the file content directly.
Files can be downloaded only when status is ready.
Path parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
file_id | string | Yes | File ID with the file_ prefix |
Headers
| Header | Required | Description |
|---|---|---|
Authorization | Yes | Bearer $QODER_PAT |
Example request
Example response
HTTP 200 OKResponse fields
| Field | Type | Description |
|---|---|---|
url | string | Presigned download URL |
expires_at | string | UTC expiration time for the URL in RFC 3339 format |
Notes
- Request a new URL after
expires_at. - Clients should parse the JSON response, read the
urlfield, and send a GET request to that URL.
Errors
| HTTP | Type | Trigger |
|---|---|---|
| 401 | authentication_error | Missing or invalid authentication token |
| 403 | permission_error | File purpose does not allow downloads |
| 404 | not_found_error | File with the given ID does not exist |
| 409 | conflict_error | File exists but is not in ready status |
| 410 | not_found_error | File is in deleted status |
Related
Attach and download files
Upload files to give your agent context, and download files it produces.