Skip to main content
PATCH
Update workflow draft

Authorizations

x-api-key
string
header
required

Path Parameters

workflowId
string
required

Body

application/json
plan
WorkflowPlan · object

Replace the whole draft plan. Mutually exclusive with ops.

importSources
object[]

Resolve exact import source inputs from cached AI Finder previews before validation or saving. The referenced BLOCK must match the resolved blockId. Resolved source fields override copied values in node.inputs; other inputs are preserved. Preview references are not persisted.

Required array length: 1 - 60 elements
ops
object[]

Ordered edit operations applied to the current draft plan. Mutually exclusive with plan.

Minimum array length: 1
name
string
Required string length: 1 - 120
trigger
WorkflowTrigger · object

Trigger configuration. Defaults to MANUAL when omitted during creation. SCHEDULE requires definition and startsAt. Recurrence byWeekday uses 0=Sunday, 1=Monday, through 6=Saturday; a Monday-only weekly schedule uses [1]. Always include Z or an explicit UTC offset in startsAt, with the requested wall-clock time in the selected IANA timezone; never send an offset-free timestamp. INTENT requires signal; WEBHOOK may declare inputs.

maxCreditsPerRun
integer | null
folderId
integer | null

Assign the workflow to a workflow folder (see GET /v1/workflows/folders), or null to remove it from any folder. Assignment is organizational only — a folderId-only update does not change the plan or advance the revision.

revision
string

Optimistic concurrency token (the revision from GET /v1/workflow/{workflowId}). 409 on mismatch.

Response

Draft updated

status
enum<string>
required
Available options:
success
message
string
required
data
object
required