---
title: "Archive an automation flow"
method: POST
path: "/api/v1/automations/{id}/archive"
tags: ["automation"]
---

# Archive an automation flow

`POST /api/v1/automations/{id}/archive`

## Request

- Base URL: `https://api.bundle.social`
- URL: `https://api.bundle.social/api/v1/automations/{id}/archive`
- Auth: API key in header `x-api-key`

Retire a flow without deleting it. Archived flows never trigger and are hidden from the default list.

## Path parameters

- `id` string, required

## Response `200`

200

- object
  - `id` string, required
  - `teamId` string, required
  - `organizationId` string, nullable
  - `name` string, required
  - `status` 'DRAFT' | 'ACTIVE' | 'PAUSED' | 'ARCHIVED', required
  - `platformScope` 'INSTAGRAM' | 'FACEBOOK' | 'BOTH' | 'TIKTOK', required
  - `createdByUserId` string, nullable
  - `createdAt` string, date-time, nullable, required
  - `updatedAt` string, date-time, nullable, required
  - `deletedAt` string, date-time, nullable
  - `draftVersion` object
    - `id` string, required
    - `flowId` string, required
    - `version` number, required
    - `status` 'DRAFT' | 'PUBLISHED' | 'RETIRED', required
    - `definition` object, required
      - `trigger` object, required
        - `keywords` string[]
        - `matchMode` 'ANY' | 'ALL'
        - `caseSensitive` boolean
        - `senderExternalIds` string[]
        - `payloads` string[]
        - `actionDelaySeconds` integer
        - `id` string
        - `type` 'COMMENT_CREATED' | 'DM_RECEIVED' | 'QUICK_REPLY_CLICKED' | 'BUTTON_CLICKED' | 'MANUAL_TEST', required
        - `platform` 'INSTAGRAM' | 'FACEBOOK' | 'TIKTOK', required
        - `socialAccountId` string, required
        - `postId` string, nullable
      - `steps` union[], required
        - union
          - object
            - `id` string
            - `type` 'CONDITION', required
            - `conditions` object[], required
              - …
          - object
            - `id` string
            - `type` 'SEND_MESSAGE', required
            - `message` object, required
              - …
          - object
            - `id` string
            - `type` 'SEND_PRIVATE_REPLY', required
            - `message` object, required
              - …
          - object
            - `id` string
            - `type` 'SEND_PUBLIC_COMMENT_REPLY', required
            - `text` string, required
          - object
            - `id` string
            - `type` 'LIKE_COMMENT', required
          - object
            - `id` string
            - `type` 'ARCHIVE_CONVERSATION', required
          - object
            - `id` string
            - `type` 'OPEN_CONVERSATION', required
    - `publishedAt` string, date-time, nullable
    - `publishedByUserId` string, nullable
    - `createdAt` string, date-time, nullable, required
  - `publishedVersion` object
    - `id` string, required
    - `flowId` string, required
    - `version` number, required
    - `status` 'DRAFT' | 'PUBLISHED' | 'RETIRED', required
    - `definition` object, required
      - `trigger` object, required
        - `keywords` string[]
        - `matchMode` 'ANY' | 'ALL'
        - `caseSensitive` boolean
        - `senderExternalIds` string[]
        - `payloads` string[]
        - `actionDelaySeconds` integer
        - `id` string
        - `type` 'COMMENT_CREATED' | 'DM_RECEIVED' | 'QUICK_REPLY_CLICKED' | 'BUTTON_CLICKED' | 'MANUAL_TEST', required
        - `platform` 'INSTAGRAM' | 'FACEBOOK' | 'TIKTOK', required
        - `socialAccountId` string, required
        - `postId` string, nullable
      - `steps` union[], required
        - union
          - object
            - `id` string
            - `type` 'CONDITION', required
            - `conditions` object[], required
              - …
          - object
            - `id` string
            - `type` 'SEND_MESSAGE', required
            - `message` object, required
              - …
          - object
            - `id` string
            - `type` 'SEND_PRIVATE_REPLY', required
            - `message` object, required
              - …
          - object
            - `id` string
            - `type` 'SEND_PUBLIC_COMMENT_REPLY', required
            - `text` string, required
          - object
            - `id` string
            - `type` 'LIKE_COMMENT', required
          - object
            - `id` string
            - `type` 'ARCHIVE_CONVERSATION', required
          - object
            - `id` string
            - `type` 'OPEN_CONVERSATION', required
    - `publishedAt` string, date-time, nullable
    - `publishedByUserId` string, nullable
    - `createdAt` string, date-time, nullable, required

## Other responses

- `400`: 400
- `401`: 401
- `403`: 403
- `404`: 404
- `429`: 429
- `500`: 500
- `502`: 502
- `503`: 503
- `504`: 504

## Changes

- **2026-11-03** `fb6e4fbd8d2f`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/bundle/apis/bundle-social-api/changes/api/v1/automations/:id/archive/post.md)

---

[API](https://skmtc.dev/bundle/apis/bundle-social-api.md) - [All operations](https://skmtc.dev/bundle/apis/bundle-social-api/llms.txt) - [OpenAPI document](https://skmtc.dev/bundle/apis/bundle-social-api/revisions/18efa1cb93a4?raw)
