---
title: "Download file content"
method: GET
path: "/files/{file_id}/content"
tags: ["Files"]
---

# Download file content

`GET /files/{file_id}/content`

Downloads the raw bytes of a file. Only files created server-side are downloadable; uploaded files return 400.

## Path parameters

- `file_id` string, required

## Query parameters

- `workspace_id` string, uuid — Workspace to scope the request to. Defaults to the caller’s default workspace.
- `provider` 'openai' | 'anthropic' — Store or read this file on the named provider using your own API key for it. Omit to use OpenRouter storage.

## Response `200`

The raw file content.

## Other responses

- `400` — Bad Request - Invalid request parameters or malformed input
- `401` — Unauthorized - Authentication required or invalid credentials
- `403` — Forbidden - Authentication successful but insufficient permissions
- `404` — Not Found - Resource does not exist
- `429` — Too Many Requests - Rate limit exceeded
- `500` — Internal Server Error - Unexpected server error
- `502` — Bad Gateway - Provider/upstream API failure
- `503` — Service Unavailable - Service temporarily unavailable

## Changes

> 204 revisions in range; 44 could not be searched.

- **2026-07-29** `6968addaaf97` — 4 info
  - added the new optional `query` request parameter `provider`
  - added the non-success response with the status `403`
  - added the non-success response with the status `502`
  - added the non-success response with the status `503`

[Change history](https://skmtc.dev/openrouterteam/apis/openrouter-api/changes/files/:file_id/content/get.md)

---

[API](https://skmtc.dev/openrouterteam/apis/openrouter-api.md) · [All operations](https://skmtc.dev/openrouterteam/apis/openrouter-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/openrouterteam/openrouter-api/revisions/c7f48ab0bdf3/schema)
