v13

latestOpenAPI 3.1.0Apache 2.0raw.githubusercontent.com2026-08-015232292.9 KB
Workflows

Import Workflow

Create a new workflow in a workspace from an export payload produced by GET /api/v1/workflows/{id}/export. Block, edge, loop and parallel identifiers are regenerated, so the same payload can be imported repeatedly and alongside its source workflow. The workflow name is de-duplicated against the target folder. Requires write permission on the target workspace.

post/api/v1/workflows/import

Request body

workspaceIdstring required

The workspace to import the workflow into. Requires write permission.

folderIdstring

Optional folder to place the imported workflow in. Defaults to the workspace root.

namestring

Optional override for the imported workflow's name. Defaults to the name carried in the payload, then to "Imported Workflow".

descriptionstring

Optional override for the imported workflow's description. Defaults to the description carried in the payload.

Example request

{
  "workspaceId": "a91c4b2e-6d3f-4e8a-b5c7-0d9e2f1a8c64",
  "folderId": "8a4c2e6b-0d1f-4b3a-9c5e-7f2d8b4a6c91",
  "name": "Customer Support Agent (copy)",
  "description": "Imported from the staging workspace",
  "workflow": {
    "version": "1.0",
    "exportedAt": "2026-06-20T14:15:22Z",
    "workflow": {
      "id": "3b1f7c92-8d4e-4a6b-9c0d-5e2f8a714b36",
      "name": "Customer Support Agent",
      "description": "Routes incoming support tickets",
      "workspaceId": "a91c4b2e-6d3f-4e8a-b5c7-0d9e2f1a8c64"
    },
    "state": {
      "blocks": {},
      "edges": [],
      "loops": {},
      "parallels": {},
      "metadata": {
        "name": "Customer Support Agent",
        "description": "Routes incoming support tickets",
        "exportedAt": "2026-06-20T14:15:22Z"
      },
      "variables": {}
    }
  }
}

Response

The workflow was imported.

Example response

{
  "data": {
    "id": "7d2e9f14-3a6b-4c8d-b1e5-9f0a2c7d4e83",
    "name": "Customer Support Agent (1)",
    "description": "Routes incoming support tickets",
    "workspaceId": "a91c4b2e-6d3f-4e8a-b5c7-0d9e2f1a8c64",
    "createdAt": "2026-06-20T14:15:22Z",
    "updatedAt": "2026-06-20T14:15:22Z"
  },
  "limits": {
    "workflowExecutionRateLimit": {
      "sync": {
        "requestsPerMinute": 60,
        "maxBurst": 10,
        "remaining": 59,
        "resetAt": "2025-06-20T14:16:00Z"
      },
      "async": {
        "requestsPerMinute": 60,
        "maxBurst": 10,
        "remaining": 59,
        "resetAt": "2025-06-20T14:16:00Z"
      }
    },
    "usage": {
      "currentPeriodCost": 1.25,
      "limit": 50,
      "plan": "pro"
    }
  }
}