# Archive Workflow

Source: https://agenta.ai/docs/reference/api/archive-workflow

`POST /workflows/{workflow_id}/archive`

Base URL: `https://us.cloud.agenta.ai/api` (US cloud), `https://eu.cloud.agenta.ai/api` (EU cloud) or `$AGENTA_HOST/api` (self-hosted). Authentication: `Authorization: ApiKey YOUR_API_KEY`.

Archive a workflow artifact (soft delete).

Sets `deleted_at` on the workflow and its variants. Archived
workflows are hidden from queries unless `include_archived=true`.
Revision IDs remain resolvable so historical traces stay intact.

See: [Versioning](https://agenta.ai/docs/reference/api-guide/versioning.md).

## Parameters

- `workflow_id` (in path, string (uuid), required)

## Response schemas

### 200: Successful Response

- `count` (integer): `1` when a workflow is returned, `0` when none matched. Default: `0`.
- `workflow` (object, nullable): The workflow artifact.
  - `folder_id` (string (uuid), nullable)
  - `flags` (object, nullable)
    - `is_application` (boolean) Default: `false`.
    - `is_evaluator` (boolean) Default: `false`.
    - `is_snippet` (boolean) Default: `false`.
  - `tags` (object, nullable)
  - `meta` (object, nullable)
  - `name` (string, nullable)
  - `description` (string, nullable)
  - `created_at` (string (date-time), nullable)
  - `updated_at` (string (date-time), nullable)
  - `deleted_at` (string (date-time), nullable)
  - `created_by_id` (string (uuid), nullable)
  - `updated_by_id` (string (uuid), nullable)
  - `deleted_by_id` (string (uuid), nullable)
  - `slug` (string, nullable)
  - `id` (string (uuid), nullable)
  - `access` (object, nullable)
    - `visibility` (string, one of: "private", "project", required)
    - `owner_user_id` (string (uuid), nullable)

### 422: Validation Error

- `detail` (array of object)
  - `loc` (array of string | integer, required)
  - `msg` (string, required)
  - `type` (string, required)
  - `input` (any)
  - `ctx` (Context)
