Skip to main content
Albus runs agent sessions over an HTTP API. A session is a named conversation with an agent: you choose the identifier, and running the same identifier again continues that conversation. One HTTP call runs a turn and returns the assistant’s reply. You are probably reading this to set Albus up for the user of this machine, or to write code against it. Both are below, in order. Do not skip verification.

Alpha limits

Read these before designing anything.
  • 20 session runs per organization, ever, in the alpha. 429 means the cap is spent. Never retry a run in a loop.
  • Access is by invitation. A 403 naming not_provisioned means the account is not enabled: stop and tell the user to email carlo@albus.sh with the Google address they sign in with.
  • No memory across sessions. The agent sees the turns of its own session and nothing else.
  • No code execution, no durable execution (a crashed run does not resume), and no traces, metrics, or alerting — the per-session audit log is the observability that exists.
Full detail: alpha limitations.

Setup

1. Install the CLI

On Windows: irm https://raw.githubusercontent.com/albusgroup/albus-cli/master/install.ps1 | iex. The installer uses uv tool install, then pip install --user, then conda. If albus is not on PATH afterwards, it is in the scripts directory the installer printed (usually ~/.local/bin).

2. Check what state you are in

credential is api_key when ALBUS_API_KEY is set, session when the user is signed in, none otherwise. A working session also reports email and organizations; a credential that does not work reports error. The command exits 0 either way — read the JSON, not the exit code. If authenticated is already true, skip to step 4.

3. Authenticate

You cannot complete a browser sign-in yourself. Print the URL and let the user open it.
The command prints the authorization URL on its own line, then blocks until the user finishes, for up to 180 seconds. Show the URL verbatim and ask them to open it. Do not open a browser on their behalf, and do not paste their credentials anywhere. The sign-in redirects to 127.0.0.1:8484-8487 on the machine running the CLI. If that is not the machine the user’s browser is on, tell them to forward those ports (ssh -L 8484:localhost:8484 …), or to sign in on their own machine and set ALBUS_API_KEY here instead. An organization API key works instead and needs no browser:

4. Verify

JSON with the user’s email and organizations means setup is complete. An error naming the Albus beta means the account is not provisioned — stop, and tell the user to email carlo@albus.sh.

5. Run one session

Do this once, to prove the setup end to end. It spends one of the organization’s 20 alpha runs, so run it once and do not loop.
The assistant’s reply is the last element of messages.

6. Install an SDK, if the user is writing code

Both authenticate with an organization API key, which is a different credential from the browser session. Minting one requires the browser session from step 3:
The token field is shown once. Have the user store it, then:
Never write the key into a source file, a committed config, or a shell profile you did not create for this purpose.

The whole API surface

Base URL https://albus.sh/api. Authenticate with Authorization: Bearer <key>. /whoami and /tokens accept only a user bearer token, not an API key.

Running a session

  • wait=true (the default in the CLI and SDKs) blocks until the assistant replies and returns the session with its messages. wait=false returns as soon as the run is accepted; poll GET /sessions/{id}.
  • wait_timeout bounds the wait server-side. Exceeding it is 504, and the run is still going.
  • Omitting agent.model.provider uses the model credential Albus supplies, which is what a first run should do. To bring your own, store it as a secret and reference it — see model providers.
  • mcp_servers requires a Streamable HTTP MCP endpoint. allowed_tools names tools as the server names them; the agent sees them prefixed, as github__search_issues. Omit it to allow every tool the server exposes. See MCP servers.

Failures and what to do about them

Rules that matter when you write Albus code

  • The session id is the caller’s. The same id resumes the conversation; a new id starts one. Do not generate a fresh id per turn.
  • Pass an idempotency key on anything unattended, derived from the work item rather than the clock. The same key re-attaches to that invocation instead of running again — which makes it right for a lost response or a 504, and wrong for rerunning a failed invocation. That needs a new key.
  • One invocation per session at a time. Concurrency lives across session ids, not inside one.
  • Credentials are never inlined. Store them with albus secrets create and reference them as albus.sh/secrets/<name>. Required for model.provider.credential, correct for MCP headers. Values are resolved server-side and never appear in responses or the audit log.
  • --agent-file replaces the other agent flags and cannot be combined with them.

Examples

Run and resume a session

Run unattended, retry safely

The key is derived from the work item, not the clock, so a retry re-attaches instead of running twice. The wait is bounded, and a timeout means “still running”.
Python

Give the agent GitHub tools

Python

Debug a run

The audit log is what happened inside the run; agents revision is the exact configuration that ran it.

Fan out across sessions

Python
Each run spends one of the organization’s 20 alpha runs. Fan out deliberately.

Where the rest of the documentation is

Any page is markdown at the same URL with .md appended.