drawer.json.
.buttons/drawers/<name>/.
Example
Top-level fields
| Field | Meaning |
|---|---|
schema_version | Drawer spec version. Current version is 1. |
name | Drawer name. |
description | Human-readable one-liner. |
inputs | Values supplied at drawer press time. |
steps | Ordered workflow steps. |
output_schema | Optional JSON Schema for values exposed when called as a sub-drawer. |
return | Map of output fields to ${...} expressions. |
triggers | Automatic invocation sources. Webhook triggers are live today. |
on_error | Optional drawer to call after failure. |
Step kinds
| Kind | Status | Purpose |
|---|---|---|
button | Live | Press a button. |
drawer | Live | Call another drawer as a sub-workflow. |
for_each | Live | Iterate nested steps over an array. |
switch | Live | Run the first matching branch. |
aggregate | Live | Pluck values out of an array, often after for_each. |
wait | Live | Pause for a duration or until an RFC3339 time. |
split, merge, transform, batch | Reserved | Schema-reserved for future runtimes. |
References
Step args and drawer fields can use${...} expressions. The expression body is CEL.
Inputs
Drawer inputs mirror button args and addsecret redaction:
Failure handling
Step-levelon_failure controls one step:
stop, continue, and retry.
Drawer-level on_error calls another drawer after a failed run. The handler receives drawer, run_id, failed_step, error, and redacted inputs.
Webhook triggers
Webhook triggers are stored intriggers.
${inputs.webhook.body}, plus headers, query, method, path, and received_at.
Schema
Print the embedded JSON Schema:docs/schemas/drawer.schema.json.