> This page is for Developer Documentation.

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

# Get a file

GET https://{tenant_name}.benchling.com/api/v2-beta/files/{file_id}

Get a file. This endpoint returns an S3 URL, from which you can download the file contents.

Note: URL is valid for 1 hour after being returned from this endpoint. It should not be stored
persistently for later use.


Reference: https://docs.benchling.com/docs/api/v2-beta/benchling-api-beta/files/get-file

## Authentication

- `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer <token>`, where token is your auth token.

## Request

### Path parameters

- `file_id` (string, required) — The ID of the file

## Response

### 200

OK

- `errorMessage` (string, optional, nullable)
- `uploadStatus` (enum, optional)
  - Allowed values: `IN_PROGRESS`, `SUCCEEDED`, `FAILED_VALIDATION`, `NOT_UPLOADED`
- `archiveRecord` (ArchiveRecord, optional, nullable) — ArchiveRecord Resource if the file is archived. This is null if the file is not archived.
- `createdAt` (datetime, optional) — Date and time the file was created
- `creator` (FileCreator, optional) — UserSummary of the user who created the file
- `customFields` (map from string to CustomField, optional) — Custom field values of the file
- `displayId` (string, optional) — User-friendly ID of the file
- `filename` (string, optional)
- `folderId` (string, optional) — ID of the folder that contains the file
- `id` (string, optional)
- `modifiedAt` (datetime, optional) — Date and time the file was last modified
- `name` (string, optional)

## Errors

### 403 Forbidden Error

Forbidden

- `error` (ForbiddenErrorError, optional)

### 404 Not Found Error

Not Found

- `error` (NotFoundErrorError, optional)

## Types

### ArchiveRecord

- `reason` (string, optional)

### FileCreator

UserSummary of the user who created the file

- `handle` (string, optional)
- `id` (string, optional)
- `name` (string, optional)

### CustomField

- `value` (string, optional)

### ForbiddenErrorError

- `invalidId` (string, optional)
- `message` (string, optional)
- `type` (string, optional)
- `userMessage` (string, optional)

### NotFoundErrorError

- `message` (string, optional)
- `type` (enum, optional)
  - Allowed values: `invalid_request_error`
- `userMessage` (string, optional)
- `invalidId` (string, optional)

## Examples

**Response**

```json
{
  "errorMessage": "string",
  "uploadStatus": "SUCCEEDED",
  "archiveRecord": {
    "reason": "Made in error"
  },
  "createdAt": {},
  "creator": {
    "handle": "string",
    "id": "string",
    "name": "string"
  },
  "customFields": {},
  "displayId": "string",
  "filename": "IC50Chart.png",
  "folderId": "lib_bf0636",
  "id": "file_Of5GuBSq",
  "modifiedAt": {},
  "name": "IC50 Chart"
}
```

**SDK Code**

```python
import requests

url = "https://{tenant_name}.benchling.com/api/v2-beta/files/file_Of5GuBSq"

headers = {"Authorization": "Bearer <token>"}

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

print(response.json())
```

```javascript
const url = 'https://{tenant_name}.benchling.com/api/v2-beta/files/file_Of5GuBSq';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

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