# Record a workflow

Do a task once in any application or several, and the chat agent turns the recording into a Workflow.

## Needs

| Requirement | Detail |
| --- | --- |
| Desktop App on macOS | The **+** menu does not offer it in a browser or elsewhere |
| **Workflow Recording** application | On by default. Off on **Applications** or with `openprogram programs disable workflow_recording`: no menu item. [Applications](https://fzkuji.github.io/OpenProgram/docs/capabilities/applications.html) |
| Accessibility and Screen & System Audio Recording | System Settings → Privacy & Security. If one is missing, the start dialog says which and opens its pane. |
| Narration (optional) | The engine from **Settings → Voice** and a microphone. Without an engine, no narration. |

## Record

1. Composer **+** menu → **Record a workflow**.
2. Set **Narrate with the microphone** and the microphone, then **Start recording**.
3. A bar stays above every window: recording dot, elapsed time, step count, microphone switch, **Discard** (trash) and red **Stop**. Do the task as usual. Say what changes next time ("the date is always last Monday").
4. **Stop**. The window returns with the recording in the composer: "Recorded demonstration · 12 steps · 48.3 s · 9 images".
5. Add a sentence, such as when it should run, and send.

| Case | Result |
| --- | --- |
| Without a chat | **Workflow Recording** on the new tab page, or **Open** on **Applications**. Starting opens a new chat; the recording waits in its composer. |
| After sending | The agent reads steps and screenshots, asks about anything that decides inputs, writes the package, runs `openprogram programs check` and summarizes steps, inputs and assumptions for correction. The card shows each step with its screenshot. |
| Ten minutes | Stops by itself as if clicked; the bar warns 30 seconds before |
| **Discard** | Stops and deletes |
| Removed from the composer | Stays on disk |

## What is recorded

| Recorded | Not recorded |
| --- | --- |
| Clicks, with application, window and control | Text in password fields (the step says only that one was typed) |
| Typed text; Return, Tab, Escape, shortcuts; scrolling; application and window switches | Anything in OpenProgram, password managers, Keychain Access, system credential prompts |
| Display screenshots at clicks, Return and window switches | OpenProgram's own windows |
| Narration, as text | Audio: the sound is discarded |

Stored in `~/.openprogram/recordings/<id>/`: `session.json`, `events.jsonl` (one line per step), `images/`. Sending gives the model the step list and up to 12 screenshots, like other message content. Delete a folder any time; its card then says the recording is gone.

## Recording as context

With purpose `context` instead of `workflow`, the agent uses it only as context for that message and writes no Workflow unless asked. The start dialog records for a Workflow; `context` comes from `POST /api/recordings` with `{"purpose": "context"}`.

## Tips

- One task per recording, from its usual starting point.
- Use the real inputs of one typical run; the agent turns changing values into parameters and asks when unsure.
- With enough in the conversation you need no recording: ask for the Workflow, and gaps are filled from earlier conversations and memory before asking.

[Write and check a Workflow](https://fzkuji.github.io/OpenProgram/docs/capabilities/workflows/authoring.html)
