Commands

Every xo command on one page, the settings it reads, and where to go for the lower-level API commands.

xo --help lists every command, and --help after any of them shows its flags. The options go before or after the command.

Log in

CommandDoes
xo loginsigns you in to XO in your browser, links the quirq hub's client when the xo server keeps a hub, and connects gh to GitHub
xo login --keyasks for an XO API key instead of opening the browser
xo login xo / xo login githubonly the XO key / only GitHub
xo statuseach service, its address, and whether you are logged in; never a key
xo logoutdeletes your XO key and the hub's address; asks before logging gh out
xo meyour profile: name, image, email, public and private metadata

Spaces

CommandDoes
xo create space NAME KINDcreates a space on XO Cloud and records it as NAME (kinds)
xo create space [NAME]makes a folder a space on the quirq hub (the one you are in, named after it, or ./NAME, made if it is not there): one branch per git repository in it, pushed to the hub after you say yes, or to GitHub with --github; a folder that is already a git repository keeps its own branches; nothing on XO Cloud (how)
xo spaces (or xo list spaces)your spaces, with their projects and refs
xo spaces --space-id IDXO Cloud's view of a space you own, with its connection URLs
xo connect P S --ref REFputs project P in space S at a branch, tag or commit (default main); adds P to your projects first if it is not there yet (how)
xo connect S / xo connect S --id IDa new space entry / one for an XO Cloud space you already have
xo install space:Sclones or fetches each project into ./S/REPO at its ref
xo update space:Spushes each branch with new commits under ./S (to the quirq hub once xo login found one), then records the refs
xo sync space:Srebases each branch on its upstream (or the hub's branch) and pushes it, merges the space's changes with yours, records them

Projects

CommandDoes
xo create project URL / xo create project NAMEadds a project: a clone at ./REPO, or an empty repository at ./NAME
xo projects (or xo list projects)your projects
xo projects add NAMEadds a name to your projects list
xo connect P --repo URLgives a plain project its GitHub repo
xo install, update, sync project:Pclone or fast-forward, push, or rebase and push one project
xo listyour projects and your spaces together

Sharing

CommandDoes
xo share space:S USER / xo share project:P USERinvites USER to a copy (GitHub projects only)
xo list sharedthe invites waiting on you
xo accept IDshows the invite, asks, then adds it (--as NAME, --space S, --ref REF, --yes)
xo reject IDtakes the invite off

Other tools

CommandDoes
xo gh ARGSruns GitHub's gh with these arguments (xo gh pr list)
xo sh ARGSruns the quirq hub's client, spacehub, with these arguments, on the hub xo login found (xo sh project list; the hub)

The arguments go to the tool as they are, and its input, output and exit code are its own. Neither tool gets your XO key; spacehub gets no GitHub token either. Put the word first: xo gh pr list, not xo --json gh pr list (xo's own options do not apply to it). sh is a word inside xo only: the hub's client is installed as spacehub, never as sh, the system shell.

Settings

SettingVariableFlagDefault
XO API keyXO_API_KEY--api-key - (asks without showing it)the key xo login saved
AddressXO_URL--url URLthe one xo login saved, then https://xo.quirq.dev

A saved key is only ever sent to the address it was saved with, so a one-off --url needs --api-key - or XO_API_KEY. Avoid --api-key KEY itself: the key would land in your shell history and the process list.

Responses print as JSON on stdout. Any problem exits 1 with one line on stderr, starting xo:, that says why.

Lower level and self-hosting

xo ops, xo call and xo api reach XO Cloud's API operation by operation (through the xo server, only the creates and xo spaces --space-id pass); the xo README covers them. To run your own xo server, see deploy-vercel.md in the xo repo.