Skip to content

aos code

Run one small program that calls many aos commands (opt-in Code Mode)

1 command. Run aos code --help for the same list from the binary, or see every group.

Discover operations and run JavaScript programs that call them in parallel; one process, only the final result returned

Under WSL / SSH: runs inside WSL (where aos was started). How the host works

Terminal window
aos code operations | describe <op> | capabilities --json | docs | check <prog.js> | run <prog.js|-> | eval '<expr>' | skill
flag values meaning
<op> One of these is required
<prog.js> One of these is required
<prog.js|-> One of these is required
<expr> Required positional argument
--json One of these is required
Terminal window
aos code operations
aos code describe capture-screenshot
aos code eval 'await ops["window-list"]({ args: ["--json"] })'
aos code run prog.js