---
title: "Archive files"
method: POST
path: "/files:archive"
tags: ["files"]
---

# Archive files

`POST /files:archive`

## Request

- Base URL: `https://{tenant_name}.benchling.com/api/v2`
- URL: `https://{tenant_name}.benchling.com/api/v2/files:archive`
- Auth: HTTP bearer

Archive files

## Request body

- FilesArchive: The request body for archiving Files.
  - `fileIds` string[], required
  - `reason` 'Made in error' | 'Archived' | 'Other', required: The reason for archiving the provided Files. Accepted reasons may differ based on tenant configuration.

## Response `200`

OK

- FilesArchivalChange: IDs of all items that were archived or unarchived, grouped by resource type.
  - `fileIds` string[]

## Other responses

- `400`: Bad Request

---

[API](https://skmtc.dev/benchling/apis/benchling-api-2.md) - [All operations](https://skmtc.dev/benchling/apis/benchling-api-2/llms.txt) - [OpenAPI document](https://skmtc.dev/benchling/apis/benchling-api-2/revisions/01d2fa8523cd?raw)
