Automations reference (JSON)

Every trigger, condition and action an automation can use, with copy-pasteable JSON, the limits, and what each error message means.


This is the full grammar for a Collection's automations document — what you see when you open ⋯ → Edit automations (JSON), and what your AI writes when you ask it for a rule. For the plain-English tour, start with Automations.

Everything below is a closed list. If a rule uses a word that isn't here, it won't save, and you'll be told exactly where.

The document

{
  "version": 1,
  "rules": [
    {
      "id": "close-out",
      "name": "Close out a finished task",
      "enabled": true,
      "when": { "changed": "done_1", "to": true },
      "if": { "all": [{ "key": "stage_3", "op": "neq", "value": "done" }] },
      "then": [
        { "op": "set", "key": "stage_3", "value": "done" },
        { "op": "set_now", "key": "completed_4" }
      ]
    }
  ]
}
KeyRequiredNotes
versionyesAlways 1.
rulesyesUp to 16.
idyesA short slug you choose — letters, digits, -, _, up to 36 characters. Must be unique in the document.
namenoWhat you see in the undo toast. Up to 64 characters. Worth writing.
enablednoDefaults to true. Set false to park a rule without deleting it.
whenyesExactly one trigger.
ifnoAn extra gate.
thenyes1–8 actions.

The key in a condition or action is a binding key — the short name of a property on this Collection, like done_1 or stage_3. You can see them on the Collection's Properties tab.

Triggers (when)

Exactly one per rule.

changed

{ "changed": "done_1", "to": true }
FieldNotes
changedThe property to watch.
toOptional. Only fire when the new value is this.
fromOptional. Only fire when the old value was this.

With neither to nor from, any change to that property fires the rule.

Dragging a card between board columns changes the property the board groups by, so this trigger covers board drags with nothing extra:

{ "changed": "stage_3", "to": "done" }

created

{ "created": true }

Fires once, when an entry is created, after its defaults are filled in. Takes no to or from.

Conditions (if)

Optional. Same grammar as conditional card styling, so there's one condition language to learn:

{ "if": { "all": [ { "key": "stage_3", "op": "neq", "value": "done" } ] } }
  • all — every condition must hold.
  • any — at least one must hold. Leave any out and it isn't checked.

You can use both; then all of all must hold and at least one of any.

OperatorMeansNeeds a value
eqisyes
neqis notyes
gt gtegreater than / or equalyes
lt lteless than / or equalyes
containstext contains (ignores capitals)yes
emptyhas no valueno
presenthas a valueno

A value is one plain thing: text (up to 64 characters), a number, or true/false. Never a formula.

Actions (then)

Between 1 and 8. They run in the order you write them.

VerbNeeds valueWhat it does
setyesWrites the value.
set_nownoStamps a date or datetime property with the current moment.
clearnoEmpties the property.
togglenoFlips a checkbox — anything not already ticked becomes ticked.
incrementnoAdds to a number. Optional by (default 1, negative counts down). An unset number counts as zero.
add_tagyesAdds one tag, leaving the property's other tags alone.
remove_tagyesRemoves one tag, leaving the others alone.
[
  { "op": "set",        "key": "stage_3", "value": "done" },
  { "op": "set_now",    "key": "completed_4" },
  { "op": "clear",      "key": "blocked_by_7" },
  { "op": "toggle",     "key": "done_1" },
  { "op": "increment",  "key": "attempts_9", "by": 1 },
  { "op": "add_tag",    "key": "tags_5", "value": "shipped" },
  { "op": "remove_tag", "key": "tags_5", "value": "blocked" }
]

Tag values are labels

Write the tag's name, not its id:

{ "op": "set", "key": "stage_3", "value": "done" }

A label that doesn't exist yet is created for you, with a colour picked automatically. Capitalisation doesn't matter when matching an existing one.

Limits

LimitValue
Rules per Collection16
Actions per rule8
Conditions per all / any list8
Text value length64 characters
Rule name length64 characters
How far a cascade runs3 steps
Whole document size16 KB

What happens when it can't save

Nothing is written — not part of it, none of it — and you get a list of exactly what's wrong, each pointing at the spot:

rules[0].then[0].op: "notify" is not an action
  (expected set | set_now | clear | toggle | increment | add_tag | remove_tag)

Common ones:

MessageMeans
names no triggerThe when has neither changed nor created.
is required for "set"That verb needs a value.
not allowed for "set_now"That verb takes no value.
duplicate rule idTwo rules share an id.
…completes a cycle back to a rule that triggers on itRule A sets off rule B which sets off rule A. Break the loop, or gate one with an if.
is not a property referenceThe key isn't a valid binding key. Check the Properties tab.

Rules of thumb

  • A rule fires at most once per edit. It can't set itself off, even indirectly.
  • A rule that would change nothing does nothing — no toast, no write. Setting Stage to done when it's already done is silently skipped.
  • Rules run on your own edits, on any of your devices. Your AI's edits in a chat don't set them off.

See also