Dibbla Docs Get started Guides Workflows Changelog
Open Console
Beyond apps

Workflow YAML reference

The slim format dibbla wf create -f consumes — three node types, the edge syntax, and the handful of rules that decide whether a graph runs.

The format dibbla wf create -f and wf update -f read. Write this, not the verbose React-Flow JSON the editor stores — the CLI converts between them.

Build your first workflow is the walkthrough; this is the field reference.

The whole shape

name: incident_triage          # required, unique in the org

nodes:
  - id: api_input              # entry point
    type: api
    inputs: [question]         # what a caller must send
    outputs: [question]        # what downstream nodes can read

  - id: reasoning_agent_function
    type: function
    function: reasoning_agent_function   # from the registry
    server: function-server              # which execution server provides it
    inputs:                              # literals, or left for an edge to fill
      system_message: "You are an incident triage assistant. Be brief."
      model: dibbla/claude-haiku-4-5
    outputs: [response]

  - id: api_response
    type: api_response
    linked_to: api_input       # ties the reply to its entry node
    inputs: [response]

edges:
  - api_input.question -> reasoning_agent_function.prompt_message
  - reasoning_agent_function.response -> api_response.response

Node types

typePurposeFields you needEnforced by wf validate
apientry point; defines what callers sendid, inputs, outputsnothing beyond type — outputs defaults to inputs
functionone call to a registry functionid, function, serverfunction, server
api_responsewhat the caller receivesid, linked_to, inputslinked_to

The two columns differ on purpose. The validator is lenient — an api node with no ports passes — but a graph built that way cannot do anything. Write the middle column; do not read a clean validate as confirmation you did.

An api node is required for every execution, including from the CLI. dibbla wf execute posts to the same endpoint the HTTP caller does, and it returns No API node found without one. The api_response node is what makes a caller receive something: omit it and a blocking execute waits out the 30-minute timeout and returns 408.

Edges

One per line, from.output -> to.input. The left side must be an output the producing node declares; the right side an input the consuming node accepts.

edges:
  - api_input.question -> summarise_incidents.region
  - summarise_incidents.summary -> api_response.response

Required and Optional inputs

Every input of a node has an input mode:

  • Required — the node waits for its value, but only for a value that can come. When the caller leaves out an optional API field that feeds it, a node the answer depends on runs without it instead of waiting forever. A node off the way to the answer — a side branch, an error handler — does not run without it, so “only when the call sends it” still works.
  • Optional — never waits; the node uses the value only if it has already arrived.

Without a choice, an input follows the function: dibbla fn get lists the Required ones under required_inputs, the rest are Optional.

Optional follows the source. A node fed by an optional API field needs no flag of its own: mark the field optional: on the api node, and the node it feeds runs with the value when the caller sends it and without it when the caller does not. An edge into a template variable is enough to declare it — no inputs: line.

  - id: api_input
    type: api
    inputs: [question, task]
    optional: [task]             # a call may leave out task

  - id: template
    type: function
    function: handlebars_template
    server: function-server
    inputs:
      script: "Q: {{question}} / task: {{task}}"
    # nothing about task here — it follows api_input.task

edges:
  - api_input.question -> template.question
  - api_input.task -> template.task

Two node keys change what the function says, for one node:

  - id: reasoning_agent
    type: function
    function: reasoning_agent_with_toolbox
    server: function-server
    optional: [system_message]   # never waits for it
    required: [thread_id]        # waits for it
  • Use the names from inputs: — files, not files[] — and <seat>.<port> for a capability provider’s port, such as memory.user.
  • wf get prints exactly the choices you wrote, sorted — including ones switched on the canvas. Every later write, such as dibbla wf tools add, keeps them.
  • A few inputs are fixed: tools, files and inputs the platform fills in itself are never waited for, so they cannot be required. A wired response on an api_response node, and an agent’s mcp_servers wired from another node, are always waited for.
Optional values from slower nodes can arrive too late

An Optional input does not hold the node, so if the node already ran, a value that arrives afterwards from a slower node is dropped — the agent ran without its context. Keep the input Required when the node needs it.

See which inputs wait, and why

dibbla wf validate lists under Inputs: every input whose waiting is worth knowing — with its mode and the reason — and what a call without each optional field does:

Valid — 3 nodes, 3 edges
Inputs:
  template.task: Required – waits for api_input.task; runs without it when the call omits 'task'
  2 other wired inputs are Required and wait for their wire on every call
  api_input.task (optional): A call without 'task' runs template.task without it.

With -o json the full list is under input_gating; each entry has node, input, mode (required or optional), sources, omitted_by, message and waits:

waitsMeans
alwayswaits for its value on every call
unless_omittedwaits, and runs without it when the call leaves out the field in omitted_by
holdswaits, so a call without the field in omitted_by does not run the node
neverdoes not wait; uses the value if it has arrived
skipsno value can ever come, so the node runs without it

dibbla wf api-docs shows the effect of leaving out each optional field per endpoint (omissions with -o json). Through Dibbla in your assistant, platform_workflow_validate gives the same answer.

Fields on api and api_response

Every field of an api node is one the caller must send, and every field of an api_response node one the answer carries. optional: changes that per field; required: is already the default.

  - id: api_input
    type: api
    inputs: [question, locale]
    optional: [locale]           # a call may leave out locale

  - id: api_response
    type: api_response
    linked_to: api_input
    inputs: [response, sources]
    optional: [sources]          # the answer may come without sources
  • dibbla wf api-docs marks these fields (optional), and lists them under optional_inputs and optional_outputs with -o json.
  • A field the caller leaves out sends nothing down its edges. A node the answer depends on runs without it; a node off the way to the answer does not run, and wf validate warns about it (OPTIONAL_FIELD_FEEDS_REQUIRED_INPUT) — fine when that node should only run when the field is sent.
  • A wired response is always waited for, so the caller never gets an answer before the agent has given one. optional: [response] has no effect then, and wf validate says so with a warning.

wf validate rejects, one error each:

RuleCause
UNKNOWN_INPUTa name in optional: or required: is not an input (or, on api and api_response, a field) of the node
CONFLICTING_INPUT_OVERRIDEthe same name is in both lists
INPUT_NOT_REQUIRABLErequired: names tools, files or an input the platform fills in

UNSATISFIED_INPUT — an input with no edge and no value — is judged on the same effective list: an input you made optional is not demanded, and one you made required is.

The rules that actually bite

Only wire ports the registry declares

Adding a plausible output a function does not have — an error port, say — produces preflight: malformed source handle, and the run then hangs rather than failing. A hang and a typo look nothing alike, which is what makes this one expensive. dibbla fn get <server> <function> is the ground truth for what exists.

Your node ids do not survive a round-trip

Custom ids work: edges and tools: resolve against them when you create the workflow. What they do not do is come back. The platform stores its own internal ids, and wf get regenerates a slim id from each node’s label — which for a function node defaults to the function name. So the file you wrote and the file you read back differ, and a diff between them is noise rather than drift.

One node, one role — and validate will not catch this one

A node may be an agent’s tool or a data input to that agent — never both. Wiring both closes a cycle (the implicit tool edge plus your data edge) and the run is rejected with CYCLE_DETECTED before it starts. To put data in an agent’s context, template it into the system message and keep that node out of tools:.

The validator builds its cycle check from edges: alone and never adds the implicit edges from tools:, so a tool-induced cycle passes both validate and create cleanly and only fails when you trigger it. It is the one class of error the section below cannot protect you from.

Types must match the function’s reflected types. Send true, not "true"; 42, not "42". dibbla fn get prints them.

Validate before you create

$dibbla wf validate -f incident_triage.yaml
valid: true
node_count: 3   edge_count: 2
 
$dibbla wf create -f incident_triage.yaml
 
# snapshot HEAD before editing an existing one
$dibbla revisions create incident_triage
$dibbla wf update incident_triage -f incident_triage.yaml

validate changes nothing on the platform, so it is cheap to run on every edit — but it is a server call, not a local parse. It needs your token, and it resolves the live function registry, so a function whose execution server is currently offline validates differently from one that is connected.

Round-trip an existing workflow to learn the shape

dibbla wf get <name> -o yaml prints any workflow in this format — usually faster than reading a schema. Note it returns the converted form, so a node you named yourself comes back named after its function — see the round-trip warning above.

Updating safely

wf update sends the current ETag, so a concurrent edit returns 412 rather than silently overwriting someone. Pull, merge, retry — --force exists but discards whatever the other writer just shipped.

And remember the editor has no save button: every change made there writes the live HEAD immediately. Take a revision first.