| 1 | # Agent actions |
| 2 | |
| 3 | Delegate a message to a coding-agent CLI. Hover a message, click the robot button, pick an action. |
| 4 | |
| 5 | ## Setup |
| 6 | |
| 7 | | Step | What | |
| 8 | |---|---| |
| 9 | | 1 | Install the agent CLI and log in once, inside WSL for the WSL presets | |
| 10 | | 2 | WSL: set `networkingMode=mirrored` in `%UserProfile%\.wslconfig`, so the agent reaches the app's MCP endpoint on `127.0.0.1` | |
| 11 | | 3 | Settings > Agents: pick or add an agent, press Test | |
| 12 | | 4 | Settings > Agents: add actions. Their order is the order in the toolbar menu | |
| 13 | |
| 14 | ## Flow |
| 15 | |
| 16 | | Where | What | |
| 17 | |---|---| |
| 18 | | Hover toolbar | Robot button before "..." lists the actions, "Manage actions..." opens Settings > Agents | |
| 19 | | Start dialog | Only for actions with "Ask for extra instructions", or for chats agents cannot see yet. Ctrl+Enter starts, Esc cancels, "Show prompt" shows the rendered prompt | |
| 20 | | Chip under the message | Step, time, Stop. Click expands the last 6 steps. Failed: Log, Retry | |
| 21 | | Rail > Agents | Own page like Saved, Ctrl+6. Shown when at least one action exists. Badge = running runs. Running and Done lists, row click jumps to the message | |
| 22 | | Toast | On finish or failure: Open chat, Open session (Retry when failed) | |
| 23 | | Open session | Starts the agent's resume command in a terminal. Runs stay after a restart (last 50) | |
| 24 | |
| 25 | ## Placeholders |
| 26 | |
| 27 | | Placeholder | Where | Value | |
| 28 | |---|---|---| |
| 29 | | `{message}` | prompt, extra args | Text of the message | |
| 30 | | `{sender}` | prompt, extra args | Sender of the message | |
| 31 | | `{chat}` | prompt, extra args | Chat or channel title | |
| 32 | | `{thread}` | prompt, extra args | Up to 20 earlier messages, oldest first | |
| 33 | | `{extra}` | prompt, extra args | Text from the start dialog | |
| 34 | | `{conversation_id}` | prompt, extra args | Teams conversation id | |
| 35 | | `{message_id}` | prompt, extra args | Teams message id | |
| 36 | | `{session_id}` | all | New session id of the run | |
| 37 | | `{agent}` | all | Agent id | |
| 38 | | `{prompt}` | command | Rendered prompt as one argument. Without it the prompt goes to stdin | |
| 39 | | `{cwd}` | command, open session | Working dir of the action | |
| 40 | |
| 41 | ## Presets |
| 42 | |
| 43 | | Preset | Runs in | Output | Open session | |
| 44 | |---|---|---|---| |
| 45 | | Claude Code (WSL) | WSL default distro | Claude stream-json | `wt.exe wsl.exe --cd {cwd} -e claude --resume {session_id}` | |
| 46 | | Claude Code (Windows) | Windows | Claude stream-json | `wt.exe -d {cwd} claude --resume {session_id}` | |
| 47 | | Copilot CLI (WSL) | WSL default distro | Copilot JSON | `wt.exe wsl.exe --cd {cwd} -e copilot --resume {session_id}` | |
| 48 | | Custom | Windows | Plain text | empty | |
| 49 | |
| 50 | ## Limits |
| 51 | |
| 52 | | Topic | State | |
| 53 | |---|---| |
| 54 | | Replies | Agents never send on their own. They write through the MCP tool `write_message`, and the user reviews each message unless review is off (Settings > MCP) | |