Developers

Agents, from your terminal

Asteroids agents are persistent — they keep state, memory, and history for life. The ast CLI launches one in two commands; the API is a 202 send plus one standing event stream.

1. Install and log in

bash
npm i -g @asteroidbelt/ast
ast auth login          # opens the browser once; CI: set AST_API_TOKEN

Login mints an API token scoped to you (revocable anytime under Settings → API tokens). Headless machines use ast auth login --no-browser.

2. Launch an agent

bash
cd my-project
ast launch              # scaffolds ./agent.toml, creates the agent, prints its address

agent.toml is optional — ast agent create with no file and no flags gives you the one-click default (hermes). Edit the file and re-apply with ast deploy.

3. Talk to it

bash
ast agent message my-agent "Summarize today's signups"   # streams the turn until idle
ast agent chat my-agent                                   # interactive REPL

Or over HTTP — one origin, one namespace (https://asteroidbelt.ai/api/v1):

bash
# send (202 + turnId; output never rides this response)
curl -X POST https://asteroidbelt.ai/api/v1/agents/my-agent/messages \
  -H "Authorization: Bearer ast_..." -H "Content-Type: application/json" \
  -d '{"parts":[{"type":"text","index":0,"text":"Summarize today's signups"}]}'

# listen (standing SSE — every turn, every channel, agent-initiated posts)
curl -N https://asteroidbelt.ai/api/v1/agents/my-agent/stream \
  -H "Authorization: Bearer ast_..."

One Q&A = POST the message, read the stream until turn.status_idle.

Go deeper