Skip to main content
PATCH
/
workflows
/
{workflow_id}
[Beta] Update a workflow (creates a new version)
curl --request PATCH \
  --url https://api.open.cx/workflows/{workflow_id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "description": "<string>",
  "trigger_type": "manual-trigger",
  "trigger_configuration": "<unknown>",
  "trigger_constraints": "<unknown>",
  "workflow_blocks": [
    "<unknown>"
  ],
  "workflow_editor_state": "<unknown>"
}
'
{
  "id": 123,
  "workflow_id": "<string>",
  "name": "<string>",
  "description": "<string>",
  "is_active": true,
  "trigger_type": "<string>",
  "version_number": 123,
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z",
  "workflow_blocks": [
    "<unknown>"
  ],
  "trigger_configuration": "<unknown>",
  "trigger_constraints": "<unknown>",
  "webhook_url": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

workflow_id
string
required

Body

application/json
name
string

New workflow name

Minimum string length: 1
description
string | null

New workflow description

trigger_type
enum<string>

New trigger type

Available options:
manual-trigger,
ai-trigger,
cron-trigger,
form-trigger,
webhook,
contact-created,
phone-call-started,
phone-call-finished,
ticket-created,
ticket-reassigned,
ticket-resolved,
ticket-handoff,
pre-ticket-handoff,
ticket-tag-added,
ticket-inactive,
sequence-completed,
csat-score-submit,
prohibited-topic-detected,
sla-first-reply-breached,
sla-next-reply-breached,
sla-resolution-breached,
voice-call-transferred,
pre-voice-call-transfer,
pre-phone-call-finished,
manual-ticket-trigger
trigger_configuration
any | null

New trigger configuration

trigger_constraints
any | null

New trigger constraints

workflow_blocks
any[]

New workflow step/block definitions (replaces existing blocks)

workflow_editor_state
any | null

React Flow editor state (nodes, edges, viewport) for the dashboard visual editor

Response

Default Response

id
number
required

Version serial ID

workflow_id
string
required

Workflow UUID (groups all versions of the same workflow)

name
string
required

Workflow name

description
string | null
required

Workflow description

is_active
boolean | null
required

Whether this version is currently active

trigger_type
string
required

Trigger type: "manual-trigger", "ai-trigger", "cron-trigger", "webhook", "form-trigger", or event-based triggers

version_number
number
required

Version number (increments with each edit)

created_at
string<date-time>
required
updated_at
string<date-time>
required
workflow_blocks
any[] | null
required

Workflow step/block definitions

trigger_configuration
any | null
required

Trigger-specific configuration

trigger_constraints
any | null
required

Trigger constraint rules (JSON Logic)

webhook_url
string | null
required

Trigger URL for webhook-type workflows. Call this URL (POST) to trigger the workflow. Null for non-webhook workflows.