The workflow_definition object passed to Create from Definition and Update Agent defines the full conversation graph. It is the same structure the dashboard’s visual workflow builder reads and writes β€” building an agent in the UI produces a workflow_definition under the hood, and anything you can configure visually can equally be expressed here as JSON.

Nodes

Each node represents a step in the conversation.

Node types


Node data fields

Common fields (all node types)

agentNode β€” data extraction

Extraction variable schema:
type is one of string, number, or boolean.

agentNode β€” tools

trigger node

webhook node

qa node


Edges

Each edge connects two nodes and defines when the transition fires.

Validation rules

  • All source and target IDs in edges must reference existing node IDs
  • All nodes except trigger, webhook, and qa must have a non-empty prompt
  • Node IDs must be unique within the workflow
  • Each workflow must have exactly one startCall or trigger node as the entry point

Minimal example