Skip to main content

Archive Dynamic Workflow

Archive a dynamic workflow definition. Archiving does not change the status or version, and archived workflows support read-only queries.

Prerequisites

Complete the endpoint and authentication configuration. See API Overview and Authentication.

Endpoint

POST /dynamic_workflows/{workflow_id}/archive

Semantics

Archiving does not add a published version or change status or version; the archived field indicates the archive state. Archived workflows support read-only queries but cannot be edited or used to start new runs. Historical runs and execution results are retained.

Path parameter

workflow_id string (Required)Workflow ID in the format wf_<ULID>

Request example

curl -X POST "$AGENTSTUDIO_URL/dynamic_workflows/wf_01M7RMD9PRNVEPY2QKW1MA36TE/archive" \
  -H "Authorization: Bearer $DASHSCOPE_API_KEY"

Response fields

id stringWorkflow IDtype stringFixed to dynamic_workflowname / description stringName and descriptionstatus / archived string / boolstatus remains published; archived is true after archivingversion intPublished version number before archivingscript / input_schema string / objectComplete script and input schemacreated_at / updated_at stringCreation and last modification time, ISO 8601request_id stringUnique request identifier

Response example

{
  "id": "wf_01M7RMD9PRNVEPY2QKW1MA36TE",
  "type": "dynamic_workflow",
  "name": "sum-workflow",
  "description": "Adds two integers",
  "status": "published",
  "archived": true,
  "version": 3,
  "script": "export const meta = { name: 'sum-workflow' }\n\nreturn { sum: Number(args.a) + Number(args.b) }",
  "input_schema": {},
  "created_at": "2026-11-19T01:00:00Z",
  "updated_at": "2026-11-21T10:30:00Z",
  "request_id": "req_example"
}