Node catalog
Every workflow primitive is a typed node. Schema for each type is self-documenting via the executor's Descriptor() — the canvas inspector, MCP workflow_node_types, and these docs all read the same source.
When a new node type lands in internal/agents/workflow/nodes/, add a page under docs/workflow/nodes/ mirroring the schema + output map from the descriptor. The workflow-node-module skill is the authoring guide for the executor side.
Index
Logic & routing
| Type | What it does |
|---|---|
classify | LLM picks one of output_cases for free-text input. Verdict drives outgoing edges by case:. |
branch | Single Go-template expression → verdict. Routes to the edge whose case: matches. |
switch | Multi-rule list. First rule whose when is true wins. |
transform | Pure data shaping — gotemplate / jsonpath / jq. No I/O. |
end | Explicit terminator with a final result expression. |
Execution
| Type | What it does |
|---|---|
agent | Spawn an agent turn through the existing pool. Templated prompt, optional skills + tools whitelist. |
session_init | First-turn context injection for agent nodes — mirrors the channel session-context pattern. |
shell | Run a local command. Captures stdout / stderr / exit_code. Same gate policy as agents. |
go_script | Run a Go program under the yaegi interpreter. Stdin = run context JSON, stdout = result JSON. |
Integrations
| Type | What it does |
|---|---|
connector | Call one operation on a registered connector row. Same code path as MCP wick_execute. |
channel | Call a channel action (Slack send_message, open_modal, add_reaction, …) without going through an agent. |
http | Outbound HTTP call. Templated URL / headers / query / body. Retry + parse_response: raw|json|bytes. |
db_query | Parameterized SQL against a configured DSN. Returns rows + row_count + columns. |
State
| Type | What it does |
|---|---|
datatable_get | Load one row by primary key. Branches on found/not_found. |
datatable_exists | Check whether any row matches. Branches on true/false. |
datatable_query | Multi-row search with where / order_by / limit. |
datatable_count | Count without loading. |
datatable_insert | Insert; fail on PK conflict. |
datatable_upsert | Insert or update; returns `action: insert |
datatable_delete | Delete rows matching where. |
Render context
Every node's templated fields render against the run's render context. Top-level keys:
| Key | What |
|---|---|
.Event | Trigger payload — .Event.Payload, .Event.User, .Event.Channel, etc. Per-trigger shape; see Triggers. |
.Node.<id> | Output of an upstream node. Object keys are merged so .Node.classify.verdict, .Node.classify.confidence work directly. |
.Env | Per-workflow env variables (including secrets). Set via ⋮ → Settings in the canvas editor. Secrets are stored encrypted and decrypted at run time — use {{.Env.KEY}} for both plain and secret vars. Secret values are masked in output and stored run state. See Canvas editor ▶ Workflow settings. |
.Run | Run-scoped metadata: .Run.id, .Run.workflow_id, .Run.started_at, .Run.final_result. |
.Workflow | Workflow metadata: .Workflow.id, .Workflow.name, .Workflow.version. |
Template engine = Go's text/template with wick-specific helpers (jsonEscape, upper, lower, default, …). Test a template against a synthetic context with workflow_template_test — on missing-key errors it lists available keys at the offending path plus a did-you-mean hint.
Output shape convention
Every node sets at minimum result (string for routing) and may add typed fields. When result is an object the fields are merged into .Node.<id>.* for direct template access. Branching nodes (classify, branch, switch) emit verdict — the engine filters outgoing edges by edge.case == verdict.
See also
- Triggers — what populates
.Event. - MCP authoring —
workflow_node_types+workflow_node_detailops the LLM uses to discover this same catalog. - Canvas editor — visual palette of these types.