> This page is for version v1 (default).
> For other versions, use one of these documentation indexes:
> - v1 (default): https://developers.truemed.com/v-1/llms.txt

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://developers.truemed.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://developers.truemed.com/_mcp/server.

# Get File

GET https://dev-api.truemed.com/api/v1/files/{file_id}

Returns file metadata and, for clean-scanned files, a short-lived presigned download URL scoped to the owning sales channel. Files that are still scanning or quarantined are not downloadable.

Reference: https://developers.truemed.com/api-reference/files/retrieve-file

## Authentication

- `x-truemed-api-key` header (required) — Sales channel API key for merchant server-to-server authentication

## Servers

- `https://dev-api.truemed.com` (Development server, default)
- `https://api.truemed.com` (Production server)

## Request

### Path parameters

- `file_id` (string, required) — The public file identifier.

## Response

### 200

Successful response

- `content_type` (string, required) — The file's MIME type, e.g. application/pdf.
- `download_url` (string, required) — Short-lived presigned download URL (5 minutes). Always present in a 200 response; non-clean files return 409 rather than a 200 with this field absent.
- `file_id` (string, required) — The public file identifier.
- `filename` (string, required) — The stored filename.
- `scan_status` (enum, required) — Malware-scan status. Downloads are only available once the file is clean.
  - Allowed values: `pending_scan`, `clean`, `quarantined`
- `size_bytes` (integer, required) — The file size in bytes.

## Errors

### 400 Bad Request Error

Bad Request

- `error` (enum, required)
  - Allowed values: `TotalAmountInvalid`, `ValidationError`
- `message` (string, required)

### 404 Not Found Error

Not Found

- `error` (enum, required)
  - Allowed values: `NotFound`
- `message` (string, required)

### 405 Method Not Allowed Error

Method Not Allowed

- `error` (enum, required)
  - Allowed values: `MethodNotAllowed`
- `message` (string, required)

### 500 Internal Server Error

Internal Server Error

- `error` (enum, required)
  - Allowed values: `ServerError`
- `message` (string, required)

### 501 Not Implemented Error

Not Implemented

- `error` (enum, required)
  - Allowed values: `NotImplemented`
- `message` (string, required)

## Examples

**Response**

```json
{
  "content_type": "application/pdf",
  "download_url": "https://dev-dispute-evidence.s3.amazonaws.com/dev/dispute_evidence/9c1f2e3a-4b5c-6d7e-8f90-1a2b3c4d5e6f/2026-07-23/01920a7e-9c3f-7b21-8e4a-2f6b1d0c5a9e_receipt.pdf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIOSFODNN7EXAMPLE%2F20260723%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20260723T193000Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=9f86d081884c7d659a2feaa0c55ad015a3bf4f1b",
  "file_id": "01920a7e-9c3f-7b21-8e4a-2f6b1d0c5a9e",
  "filename": "receipt.pdf",
  "scan_status": "clean",
  "size_bytes": 248193
}
```

**SDK Code**

```python
import requests

url = "https://dev-api.truemed.com/api/v1/files/01920a7e-9c3f-7b21-8e4a-2f6b1d0c5a9e"

headers = {"x-truemed-api-key": "<apiKey>"}

response = requests.get(url, headers=headers)

print(response.json())
```

```javascript
const url = 'https://dev-api.truemed.com/api/v1/files/01920a7e-9c3f-7b21-8e4a-2f6b1d0c5a9e';
const options = {method: 'GET', headers: {'x-truemed-api-key': '<apiKey>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```