Exporting a workflow
Importing a workflow
Workflow JSON format
The exported JSON mirrors the internal workflow schema exactly. All fields are required unless marked optional.Workflow root fields
| Field | Type | Required | Notes |
|---|---|---|---|
name | string | ✅ | Displayed on the workflow card |
description | string | ✅ | One-line summary |
trigger | string | ✅ | "manual" (user starts it) or "auto" (starts with session) |
isEnabled | boolean | ✅ | true to make the workflow selectable |
skillId | string | null | ✅ | ID of a skill to activate automatically when this workflow runs, or null |
tags | string[] | ✅ | User-defined labels for filtering. Use [] for none. |
steps | Step[] | ✅ | Ordered array of steps — executed top to bottom by stepOrder |
Step fields
| Field | Type | Required | Notes |
|---|---|---|---|
stepOrder | number | ✅ | Zero-based execution order. Must be sequential: 0, 1, 2, … |
name | string | ✅ | Short label shown in the workflow progress bar |
description | string | ✅ | Longer explanation of what this step does |
stepType | string | ✅ | See valid values below |
conditionExpr | string | ✅ | Natural-language condition for condition steps. Leave "" for other types. |
promptTemplate | string | ✅ | The prompt sent to the LLM. Use template variables (see below). Leave "" for human_review. |
outputFormat | string | ✅ | See valid values below |
onSuccess | string | ✅ | What to do when the step succeeds |
onFailure | string | ✅ | What to do when the step fails |
stepType valid values:
"prompt"— sendpromptTemplateto the LLM and collect output"transform"— reshape or reformat the previous step’s output"condition"— evaluateconditionExpr; routes based on result"human_review"— pause execution and wait for the user to approve before continuing
outputFormat valid values: "text" · "markdown" · "json" · "code" · "table"
onSuccess valid values: "continue" · "pause"
onFailure valid values: "retry:1" · "retry:2" · "retry:3" · "skip" · "abort"
Template variables
| Variable | Resolves to |
|---|---|
{{input}} | The original user message that started the workflow |
{{prev_output}} | The full output of the immediately preceding step |
{{document}} | The content of any document attached to the session |
Version history
MIRA saves a new version each time you save a workflow. To access version history:- Open the workflow editor.
- Click ⋮ → Version History.
- Browse versions by timestamp.
- Click Restore to roll back — this creates a new version entry rather than overwriting the history.
Distributing workflows to your team
- Export the workflow JSON.
- Commit the file to your team’s shared repository.
- Each team member imports the file into their MIRA installation.
Edit this page — Open a pull
request