Skip to main content
PATCH
Edit a workflow draft edge
The reference panel describes the current v3 operation. The notes below describe its v2 compatibility API. Follow the v3 request schema for current calls: v3 can move identifiers from the body or query into the URL. Keep the v2 method, path, and payload together when using the compatibility API.

v2 compatibility notes

PATCH /api/v2/workflows/updateDraftEdge Changes one edge of the workflow’s editable draft. Handles cannot change here: to re-point an edge, delete it and create a new one, which runs the connection checks again.

Authentication

External App credential or platform API key. Requires permission workflows:write, and the caller must hold both workflows:read and workflows:write at the workflow’s home org unit. Any External App or platform API key with those grants may edit; who created the workflow lends no authority. The org unit a request acts from is not the workflow’s home.

Body

string
required
The workflow ID.
string
required
The edge’s edgeId.
string
New condition.
string
New label.
boolean
New error flag.
string
New description.
string
New gather-group label; "" clears it.
At least one field besides the IDs is required.

Responses

200 with:
string
The workflow ID.
string
The draft’s ID.
WorkflowDraftGraphEdge
The edge as getDraftGraph returns it.

Errors

Retries

Send an Idempotency-Key header to retry safely. Within 24 hours, the same key and body return the recorded status and body, with Idempotency-Replayed: true, while the caller still holds workflows:write and can read the workflow. Otherwise the repeat answers 409 idempotency_result_unavailable and does not write again. A new key is a new write. Without a key, a retried create meets the node-name rule (409) or the one-edge-per-pair rule (422), and a retried delete answers 404. If an outcome is unknown, read getDraftGraph before acting again.

Authorizations

Authorization
string
header
required

An External App: the JWT it obtains from POST /oauth/token with OAuth2 client_credentials. Pass as Authorization: Bearer <jwt>. An app's static companion key also authenticates as the app, but is deprecated and is not protected by Idempotency-Key.

Headers

Idempotency-Key
string

Path Parameters

workflowId
string
required
Minimum string length: 1
edgeId
string
required
Minimum string length: 1

Body

application/json
condition
string
label
string
onError
boolean
description
string
collectGroup
string

"" clears the gather group.

Response

The draft graph write.

data
object
required
meta
object
required