Commands and shortcuts#
PacketCode has a small process-level command surface and a larger interactive slash-command surface.
CLI commands#
packetcode start the interactive interface
packetcode run run one non-interactive turn and print the response
packetcode doctor inspect configuration and runtime readiness
packetcode skills list, install or remove skills
packetcode acp run the optional ACP stdio server
packetcode sugar login authorize with a Sugar service
Use packetcode --help and packetcode <command> --help for the flags supported
by the installed version.
Run one turn without the interface#
packetcode run takes the prompt as positional arguments and prints the final
response. It uses the same providers, sessions, tools and permission policy as
the interactive interface.
packetcode run --permission-mode read-only "summarise this repository"
packetcode run --provider ollama --model qwen2.5-coder:14b "review the current diff"
packetcode run --resume <session-id> --json "continue with the next step"
| Flag | Effect |
|---|---|
--provider NAME |
Override the configured provider. |
--model MODEL |
Override the configured model. |
--permission-mode MODE |
ask, accept-edits, auto, read-only or bypass. |
--resume ID |
Continue a saved session. |
--json |
Print one machine-readable result object instead of plain text. |
run does not read the prompt from standard input, and has no --trust or
--computer option. Because nobody is present to answer a prompt, an action
that needs approval is refused and the command exits 3 — even if the model
then produces a normal-looking answer without it. Choose a permission mode that
allows the work, or run the task interactively.
| Exit code | Meaning |
|---|---|
0 |
The turn completed. |
1 |
The run failed. |
2 |
The command line was wrong, such as a missing prompt or an unknown permission mode. |
3 |
An action required approval, which is unavailable here. |
130 |
Cancelled with Ctrl+C or SIGTERM. |
Plain output on standard output is the final response only; diagnostics and
configuration warnings go to standard error. With --json, standard output
carries one object with schema_version, ok, session_id, provider,
model, output, elapsed_ms, usage, and error when the run failed. The
current schema_version is 1.
Interactive commands#
Type /help for the live registry. Common actions include changing the model or
provider, viewing tools, managing sessions and jobs, compacting context,
inspecting MCP servers, and selecting a permission posture. Skills and command
files may add more entries, so the live help is authoritative for the current
installation.
Keyboard use#
- Submit from the composer with the key shown in its footer.
- Use the interface's cancel key to stop a streaming turn before retrying.
- Open pickers and approval panels with the displayed shortcuts; terminal and platform bindings can affect key delivery.
- When a shortcut conflicts with the terminal emulator, use the equivalent slash command.
Verify#
Run packetcode --help and confirm it lists run, doctor, skills, acp
and sugar, then open the interface and compare /help with the features you
configured. A command that does not appear belongs to a newer build than the
one installed; check packetcode --version first.
For run, packetcode run --permission-mode read-only --json "list the files you can see" should exit 0 and print one JSON object with "ok": true.