Arg0/Docs

Workflows

Node-based automation in .workflow.md files — a directed graph of nodes connected by edges, like Zapier or n8n.

Editing

In Arg0 Desktop you can edit the same file two ways — both read and write identical .workflow.md syntax:

  • Text - Write the markdown directly
  • Canvas - Drag nodes, connect edges, and inspect runs. Node positions are saved into each node's position field

How it works

A .workflow.md file contains a ## @automation block. Each node receives JSON items, processes them, and passes results along its connections to the next nodes.

markdown
## @automation daily_summary

enabled: true
timeout: "5m"
context:
  channel: "#updates"

workflow:
  trigger: trigger
  nodes:
    - id: trigger
      type: trigger.cron
      parameters:
        schedule: "0 9 * * *"

    - id: fetch
      type: http.request
      parameters:
        method: GET
        url: "https://api.example.com/metrics"

    - id: format
      type: transform.template
      parameters:
        template: "Daily users: {{ $json.total_users }}"

  connections:
    - trigger -> fetch
    - fetch -> format

Node fields

FieldRequiredDescription
idyesUnique node id within the automation
typeyesNode type (see below)
parametersnoNode-specific inputs
credentialsnoReference to an @auth or @integration
endpointnoFor http.request, an ## @endpoint block name
positionnoCanvas coordinates { x, y }
on_errornoNode id to jump to on failure

Node types

  • Triggers — trigger.manual, trigger.webhook, trigger.cron
  • Actions — http.request, action.slack.postMessage, action.notion.createPage, etc.
  • Data — filter, switch, transform.set, transform.map, transform.template, transform.format.*
  • AI — ai.prompt, agent.instance
  • Control flow — delay.wait, delay.until, loop.forEach, loop.splitInBatches, merge.append, merge.combine
  • Custom code — code.javascript
  • Human in the loop — checkpoint.manual pauses the run for approval

Connections

source -> target with an optional [label] for branches:

markdown
connections:
  - trigger -> fetch
  - filter -> process [true]
  - filter -> skip [false]
  - switch -> high_priority [high]
  - switch -> default_path [default]

Expressions

Use {{ ... }} inside parameters:

markdown
{{ $json.title }}               # current item's field
{{ fetch.output.total_users }}  # another node's output
{{ fetch.count }}               # number of items a node produced
{{ $context.channel }}          # automation context
{{ $env.API_KEY }}              # environment variable
{{ $error.message }}            # inside on_error handlers

Credentials

Workflow files never contain secrets. Define how to authenticate with @auth, and tokens are resolved at runtime.

markdown
## @auth SlackOAuth

type: oauth2
service: slack
scope: chat:write,channels:read

Reference it from a node — or use @integration to manage multiple accounts:

markdown
- id: post
  type: http.request
  endpoint: SlackSendMessage
  credentials: SlackOAuth

Auth types: oauth2, api_key, basic_auth. Tokens can also come from env or the OS keychain.

Endpoints

An ## @endpoint block defines a reusable HTTP call for http.request nodes:

markdown
## @endpoint SlackSendMessage

POST https://slack.com/api/chat.postMessage
Auth: SlackOAuth

Body:
- channel: string
- text: string

Error handling

Set on_error on the automation or a single node to route failures to a handler node:

markdown
- id: fetch
  type: http.request
  on_error: notify_failure