English
Make a step act
You give a step a button that changes the player's machine: install a program, add a skill, turn an automation on. The step names an action the game knows; the game shows the plan, runs it after the player agrees, and proves the result with a check.
Before you begin 10 minutes
- A quest pack that passes
alta lint: the quickstart makes one,my-pack. - A step proven by a check: see Prove a step with a check.
Name an executor
run.donames an executor of the closed list, andrun.argsgives its arguments. An executor is a fixed command the game knows: your file never holds a command line, only the executor's name and values it accepts.Give the step a
checktoo: it is done when the check passes, never when the run ends.my-pack/actions.jsonjson{ "id": "ffmpeg", "kind": "action", "title": { "en": "Install ffmpeg", "fr": "Installe ffmpeg" }, "hint": { "en": "Your agent uses it to cut and convert videos.", "fr": "Ton agent s'en sert pour couper et convertir des vidéos." }, "run": { "do": "pkg.install", "args": { "pkg": "ffmpeg" } }, "check": { "type": "bin", "name": "ffmpeg" } }Let the plan card speak
When the player presses the step's button (See what it does), the game shows a plan card: what will run, what it changes, and how to undo it. Nothing runs before they say yes.
Each executor declares its undo. Some are undone by the game (an automation turned off again, a setting put back); others show the command that undoes them; a few cannot be undone, and the card says so.
my-pack/actions.jsonjson{ "id": "weather", "kind": "action", "title": { "en": "Add the weather skill", "fr": "Ajoute la compétence météo" }, "run": { "do": "skill.install", "args": { "ref": "@openclaw/weather" } }, "check": { "type": "skill", "name": "weather" } }Know what the owner allows
An executor runs only if the owner of the machine started the game with its capability. Without it, the step does not run on that machine, whatever the pack says: the step tells the player which option the game needs.
Capability Started with For example install--allow-installprograms, skills, automations setup--allow-setupsettings, sign-ins, channels ask--allow-aska message to an agent Some executors also need the player's own Mac (a window, a sound) and do not run in a hosted world; the executors page says which.
my-pack/actions.jsonjson{ "id": "brief", "kind": "action", "title": { "en": "Turn on the morning brief", "fr": "Active le brief du matin" }, "run": { "do": "automation.enable", "args": { "key": "morning-brief" } }, "check": { "type": "automation", "key": "morning-brief", "enabled": true } }Or show a command to copy
When there is no executor for what you need, a
commandstep shows a command the player copies into their terminal. The game does not run it. Add acheckif the machine can show the result; otherwise the player says it is done.my-pack/actions.jsonjson{ "id": "doctor", "kind": "command", "title": { "en": "Ask OpenClaw how it feels", "fr": "Demande à OpenClaw comment il va" }, "hint": { "en": "Copy the command into a terminal: it only reads.", "fr": "Copie la commande dans un terminal : elle ne fait que lire." }, "cmd": "openclaw doctor", "optional": true }Check the pack
Save the complete example as
my-pack/actions.jsonand check the folder. An executor that is not in the list, or an argument it does not take, is refused:step.run-executor,step.run-args.my-pack/actions.jsonjson{ "schema": "alta.quests/0.3", "branch": "core", "quests": [ { "id": "toolbox", "uid": "core.toolbox", "act": 2, "giver": "operator", "title": { "en": "Give your agent tools", "fr": "Donne des outils à ton agent" }, "summary": { "en": "A program, a skill and an automation, each installed after you agree.", "fr": "Un programme, une compétence et une automatisation, chacun installé après ton accord." }, "reward": { "xp": 50 }, "steps": [ { "id": "ffmpeg", "kind": "action", "title": { "en": "Install ffmpeg", "fr": "Installe ffmpeg" }, "hint": { "en": "Your agent uses it to cut and convert videos.", "fr": "Ton agent s'en sert pour couper et convertir des vidéos." }, "run": { "do": "pkg.install", "args": { "pkg": "ffmpeg" } }, "check": { "type": "bin", "name": "ffmpeg" } }, { "id": "weather", "kind": "action", "title": { "en": "Add the weather skill", "fr": "Ajoute la compétence météo" }, "run": { "do": "skill.install", "args": { "ref": "@openclaw/weather" } }, "check": { "type": "skill", "name": "weather" } }, { "id": "brief", "kind": "action", "title": { "en": "Turn on the morning brief", "fr": "Active le brief du matin" }, "run": { "do": "automation.enable", "args": { "key": "morning-brief" } }, "check": { "type": "automation", "key": "morning-brief", "enabled": true } }, { "id": "doctor", "kind": "command", "title": { "en": "Ask OpenClaw how it feels", "fr": "Demande à OpenClaw comment il va" }, "hint": { "en": "Copy the command into a terminal: it only reads.", "fr": "Copie la commande dans un terminal : elle ne fait que lire." }, "cmd": "openclaw doctor", "optional": true } ] } ] }examples/quest-pack/actions.fragment.json
Terminalshalta lint my-packOutputtextok my-pack/actions.json (quests) ok my-pack/quests.json (quests) 2 checked, 0 errors, 0 warnings
Try it
alta dev my-packOpen the address it prints, press L for the quests, then open Give your agent tools. Each action shows See what it does, and says the game was started without the right to run it: alta dev never changes your machine.
Demo: nothing is written on your machine.
Pitfalls
| Do | Avoid |
|---|---|
| One executor per step, and a check that proves its result | A step that is done when the run ends |
Values from the executor's list (pkg, pane, path…) | A command line, or a value the executor does not take |
A hint that says why the player wants this | A button with no reason on screen |
A command step only when no executor fits | Asking the player to type what the game can do |
Known limits: some executors of the list are declared but not in this version of the game yet; their card says so, and the step stays open. To ask the player for a value (a name, a token) before the run, or to keep a step with the player and still help, see Make a step that does it.
Go further
- Executors: what each one runs, its arguments, its undo.
- Consent: nothing acts before the player says yes.
- The game does it, the player agrees: inputs, secrets and proof.