06
actions · execute
Abilities are data.
Every application exposes what it can do behind two commands. <app>.actions returns the list: id, label, menu, shortcut, whether it is enabled and, if not, why. <app>.execute {id, params} runs one.
- Menus, keybindings, the command line and agents all end in the same
execute.
- Parameters are typed, so a form can be drawn from them and a bad call is refused before it runs.
- MCP, for AI clients that speak it, is a small adapter written in Mix. It offers a few generic tools, never one per action, and never goes around the Bus.
monitor.actions (first three, from the app's registry)
[
{id: "help.macros", label: "Macros", menu: "Help",
class: "intent", enabled: true, shortcut: nil},
{id: "file.refresh", label: "Refresh now", menu: "File",
class: "intent", enabled: true, shortcut: "Ctrl+R"},
{id: "file.quit", label: "Quit", menu: "File",
class: "intent", enabled: true, shortcut: "Ctrl+Q"},
…
]