Knowledgebase · Last updated 17 November 2026
For LLM agents: use awx from your terminal
A prompt an LLM agent like Claude Code can read, so it can use awx computers from its terminal for you.
What this is
Coding agents such as Claude Code work in a terminal. Give one the prompt below and it can use awx for you: make a cloud computer, run code in it, move files, share a web page, use the desktop, and stop the computer when the job is done.
The prompt is written for the agent, not for you. It says how to install and sign in, which commands exist, the limits and costs, and what to ask you before doing anything that is hard to undo.
Before you start
- Make an API key. Sign in at box.awanbox.com, open Account, then API keys, and press Create key. It is shown once.
- Give it to the terminal, not to the chat. In the terminal where the agent runs, set it as an environment variable, or sign in once yourself:
export AWX_API_KEY=bx_...
# or
pipx install https://awanbox.com/sdk/awx-0.3.0-py3-none-any.whl
awx login --key bx_...
The agent can install the awx command itself if it is missing. It needs Python 3.10 or newer.
Give it to your agent
Pick one:
- Save it in your project. Claude Code reads
CLAUDE.mdin the folder you start it in; many other agents readAGENTS.md. Download awx-agent-prompt.md and save it under that name, or add it to the file you already have. - Point the agent at it. Start your request with: Read https://awanbox.com/knowledgebase/for-llm-agents/awx-agent-prompt.md and follow it.
- Paste it at the start of a chat.
Then ask for the job in plain words, for example: Make an awx computer called demo, build a small page that says hello, and send me a link to it.
To see what that looks like, read How to let Claude Code use awx from your terminal: a real run, every command the agent typed, and its screenshot.
The prompt
This is the same text as awx-agent-prompt.md.
# Using awx (awanbox.com) from your terminal
You can use **awx**: cloud computers for AI agents. Each computer is a Linux desktop of its own (Ubuntu 24.04, Xfce, Chrome, Python 3, Node.js, git) with a disk that stays. You control it from this terminal with the `awx` command. A person owns the account and pays for what runs; work for them, carefully.
## Set up
1. Check the command: `awx --version` (0.3.0 or newer). If it is missing, install it with `pipx install https://awanbox.com/sdk/awx-0.3.0-py3-none-any.whl` (Python 3.10 or newer). Without pipx, use a virtual environment: `pip install <same address>` inside one that is active, or `python3 -m venv ~/.awx && ~/.awx/bin/pip install <same address>`, then run `~/.awx/bin/awx`. A plain `pip install` outside a virtual environment is often refused ("externally-managed-environment").
2. Sign in with the person's API key (it starts with `bx_`). Use the `AWX_API_KEY` environment variable if it is set (it wins over a saved login), or a login the person already made (`awx login --key ...`). If `awx whoami` succeeds, a key is in effect; never print the variable to check it. If there is no key, stop and ask the person to make one at https://box.awanbox.com, Account, API keys, and to set `AWX_API_KEY` themselves.
3. Never print, log or commit the key, and never copy it into a computer, a file or a URL.
4. `awx whoami` shows the account: `tier_label` is the plan, `credit` the credit (in Malaysian ringgit), `max_running` how many computers may run at once (null means no limit). Admin accounts have no running limit and are not charged (`credit.exempt` is true).
5. Before making a computer, run `awx --json sandbox list` to see which exist and which are `running`. Use the one the person names; make a new one only when asked or when none fits.
## Commands
A computer can be called by its name or its id. Put `--json` before a command to get JSON; prefer it when you need to read the result.
```
awx --json sandbox list # your computers and their state
awx sandbox create --name NAME [--size small|large] # a new computer (Small unless you ask for Large)
awx sandbox start NAME | stop NAME # a stopped computer keeps its files
awx sandbox exec NAME [--timeout 85] -- COMMAND ARGS # run as user "agent" (has sudo) in /home/agent
awx sandbox upload NAME LOCAL_FILE /home/agent/FILE
awx sandbox download NAME /home/agent/FILE [LOCAL_FILE]
awx sandbox ls NAME [PATH] | awx sandbox cat NAME PATH
awx sandbox preview NAME --port PORT # a public https link to a web server in the computer
awx sandbox name NAME LABEL --port PORT # a permanent address LABEL.awanbox.com (costs credit)
awx sandbox shot NAME [FILE.png] # a screenshot of the desktop (1280 x 800)
awx sandbox click NAME X Y | type NAME "TEXT" | key NAME "ctrl+l" # mouse and keyboard on the desktop
awx sandbox view NAME [--control] # a link for the PERSON to watch or take over the desktop
awx sandbox delete NAME # removes the computer and its files for good
awx chat ask "TASK" --computer NAME # hand a task to awx's built-in agent and wait for its answer
```
`awx --help` and `awx sandbox --help` list every command and option.
## How to work
- `exec` exits with the command's own exit code. A command may run for 30 seconds, or up to 85 with `--timeout 85`. Start anything longer in the background and send all its output to a file (`bash -c 'nohup CMD > /tmp/job.log 2>&1 &'`); without the redirection `exec` waits for it until the timeout. Check it later with `exec NAME -- tail /tmp/job.log`.
- To share a web app, start its server inside the computer listening on `0.0.0.0` (not only `127.0.0.1`), in the background, then run `awx sandbox preview`. It gives a random address such as `https://<random>.awanbox.com/`; `awx sandbox name` gives a fixed `LABEL.awanbox.com`. Deleting the computer ends its links. A link made before the server is up shows "Nothing is listening on port N" until it is. On the Free plan a link lasts up to one hour (make a new one when it expires); the paid plan allows longer with `--ttl`. Check the link with `curl` before you give it to the person.
- Use the desktop (`shot`, `click`, `type`, `key`) only when a command cannot do the job, for example a page that needs a browser. `shot` captures the desktop as it is; to show a page, open it in Chrome inside the computer first (`awx sandbox exec NAME -- bash -c 'DISPLAY=:0 nohup chrome http://localhost:8000 >/dev/null 2>&1 &'`; `chrome` starts Google Chrome with the options a container needs, and its yellow "--no-sandbox" banner is expected), wait a few seconds, then take the screenshot. Take a screenshot before and after you act. If Chrome asks you to accept Google's terms when it starts, accept them yourself: Chrome on an awx computer is there for you to use. This covers only Chrome's own start-up terms, not accounts, sign-ups or purchases on websites.
- The computer is a container. There is no systemd (`systemctl`, `service`, snap), no Docker inside it, no VPN, no mounting, no GPU, and cron is not running. Keep long-running programs alive with supervisor: a file in `/etc/supervisor/conf.d/`, then `sudo supervisorctl update`.
- Files stay on the computer's disk between sessions. Download anything the person must keep.
## Costs and limits
- On the Free plan a running computer uses credit by the minute: Small RM0.03 an hour, Large RM0.10 an hour. Stop a computer when the work is done, unless the person wants it running.
- Making a computer costs nothing, and an account can have two. Credit (in Malaysian ringgit, RM) is used only while a computer runs. Reuse a computer when you can.
- Up to three computers can run at once (admins: no limit).
- Rate limits: 600 requests a minute per key, and 20 new computers, starts, chats or agent messages a minute. On the error code `rate_limited`, wait the number of seconds in `Retry-After`, then try again.
## Ask the person first
- Before deleting a computer or files (`delete` does not ask for confirmation and cannot be undone), making a permanent name (it costs credit), making more than one computer, or anything public or hard to undo.
- Never type passwords, codes or card numbers yourself. Give the person the link from `awx sandbox view NAME --control`, let them type it on the desktop, and wait until they say they are done.
## Errors
Errors are JSON: `{"error": {"code": "...", "message": "..."}}`. Common codes: `unauthorized` (the key is missing, wrong or revoked), `not_found`, `conflict` (for example a name that is taken), `quota_exceeded`, `forbidden` (not on this plan), `rate_limited`. Read the message and act on it; do not retry the same call blindly.
## Other ways in
- MCP: `https://mcp.awanbox.com/mcp` with the header `Authorization: Bearer <key>`.
- HTTP API: `https://api.awanbox.com/v2/...` with the same header; it is what the command uses.
- Docs: https://awanbox.com/docs/sdk/
What to expect
- The agent runs in your terminal; the work runs on the
awxcomputer. Programs it starts there keep running after the agent’s session ends, and the computer keeps its files. - It uses your credit while a computer runs, so it stops computers when it is done, unless you ask it to keep one running.
- You can watch at any time: open box.awanbox.com, or ask the agent for a link to the desktop.
- Prefer a tool list to a prompt? Connect the agent to MCP at
mcp.awanbox.comwith the same key; see the command line and API docs.
Common questions
How do I give the prompt to Claude Code?
Save it as CLAUDE.md in your project folder, or paste it at the start of a chat. You can also tell the agent to read it from https://awanbox.com/knowledgebase/for-llm-agents/awx-agent-prompt.md.
Should I paste my API key into the chat?
No. Set it as AWX_API_KEY in the terminal the agent uses, or run awx login yourself once. The prompt tells the agent never to print the key or copy it anywhere.
Does it work with agents other than Claude Code?
Yes. Any agent that can run commands in a terminal can follow it. Save it as AGENTS.md, or wherever your agent reads its instructions.
What does the agent ask me before doing?
It asks before deleting a computer or files, making a permanent name, making more than one computer, or anything public or hard to undo. It never types passwords; it gives you a link to the desktop so you type them yourself.