---
title: "Archive multiple assets to a storage."
method: POST
path: "/v2/assets/bulk/archive/"
---

# Archive multiple assets to a storage.

`POST /v2/assets/bulk/archive/`

## Request

- Base URL: `https://app.iconik.io/API/files`
- URL: `https://app.iconik.io/API/files/v2/assets/bulk/archive/`
- Auth: none declared. Required headers: `Auth-Token`, `App-ID`
- TypeScript: <https://skmtc.dev/iconik/apis/iconik-files/docs/v2/assets/bulk/archive/post.ts> (a function with typed inputs; its response is checked against the schema)

Required roles:
 - can_archive_formats

## Query parameters

- `allow_host_transfer` boolean

## Headers

- `Auth-Token` string, required
- `App-ID` string, required

## Request body

- BulkArchiveAssetRequestSchema
  - `destination_storage_id` string, uuid, nullable: ID of the storage to archive the assets to.
  - `objects` ArchiveAssetRequest[]: List of assets to archive. Each asset should contain the asset ID.
    - `all_versions` boolean
    - `delete_only_from_source` boolean
    - `delete_only_from_source_context` SourceContext
      - `external_id` string, nullable: external storage path / id
      - `root_collection_path` string, nullable: root collection path
      - `root_collection_storage_id` string, uuid, nullable: root collection storage ID
      - `storage_id` string, uuid, nullable
    - `delete_original` boolean
    - `destination_directory_path` string, nullable
    - `formats` string[]: List of format names to transfer. If not specified, ORIGINAL will be transferred.
    - `id` string, uuid, required: ID of the object to transfer.
    - `preferred_original_storage_id` string, uuid, nullable
    - `version_ids` string[]: List of version IDs to transfer.
  - `parent_job_id` string, uuid, nullable: Parent job ID

## Response `202`

Archive jobs created

## Other responses

- `400`: Bad request
- `401`: Token is invalid
- `403`: Permission on storage denied
- `404`: Asset or storage not found
- `default`: Error response

---

[API](https://skmtc.dev/iconik/apis/iconik-files.md) - [All operations](https://skmtc.dev/iconik/apis/iconik-files/llms.txt) - [OpenAPI document](https://skmtc.dev/iconik/apis/iconik-files/revisions/ed57d13791a2?raw)
