Skip to main content
Update a workflow’s name, code, events, room scope, or enabled state. At least one field must be provided.

Endpoint

PATCH /v1/accounts/:accountId/workflows/:id

Authentication

Bearer token required.

Path Parameters

id
string
required
The workflow’s unique ID.

Request Body

All fields are optional, but at least one must be provided.
name
string
New workflow name.
code
string
New source code.
events
string[]
New list of trigger events.
roomId
string | null
New room scope. Set to null to trigger for all rooms.
enabled
boolean
Enable or disable the workflow.

Response

workflow
WorkflowRegistration
The updated workflow object. See WorkflowRegistration.

Example

curl -X PATCH https://api.collab-kit.com/v1/accounts/${ACCOUNT_ID}/workflows/wf_abc123 \
  -H "Authorization: Bearer ${TOKEN}" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Updated welcome message",
    "enabled": false
  }'
Response
{
  "type": "response",
  "success": true,
  "description": "Workflow updated",
  "data": {
    "workflow": {
      "id": "wf_abc123",
      "organization_id": "a1b2c3d4-...",
      "name": "Updated welcome message",
      "code": "export default async function(event, { store, room }) { ... }",
      "events": ["participant.joined"],
      "room_id": null,
      "enabled": false,
      "created_at": "2026-05-29T10:00:00.000Z",
      "updated_at": "2026-05-29T11:00:00.000Z"
    }
  },
  "error": null
}