Manage

CLI

Last updated August 2026

Create and deploy projects from the command line. The CLI works from an infra.json, the declarative definition of your infrastructure, so it pairs naturally with your editor and your coding agent.

Installation

The installer picks the build for your machine, puts the spawned binary in ~/.local/bin, and adds completions for bash, zsh, or fish. macOS, Linux, and Windows under Git Bash or WSL are all supported.

$curl -fsSL https://spawned.sh/install.sh | bash

Set INSTALL_DIR to install somewhere else, such as INSTALL_DIR=/usr/local/bin. If the script reports that spawned is not on your PATH, add the install directory to your shell profile and open a new shell.

Run the same command again to upgrade. It always fetches the current release and replaces the binary in place.

Signing In

spawned --version   # confirm the install
spawned login       # start the sign-in flow

Tokens live in ~/.config/spawned/ on macOS and Linux, and in %LOCALAPPDATA%\spawned\ on Windows. spawned logout clears them.

In CI, or anywhere without a browser, set SPAWNED_API_KEY to an API key rather than signing in. The CLI uses the key in place of the stored tokens.

A Typical Workflow

spawned init my-project       # create a project
 
# Point your coding agent at the CLI to build the infra.json
 
spawned get my-project        # view the project and its outputs

apply deploys the infra.json from the current directory unless you point it elsewhere. Most commands accept a project as name, org/name, or id.

Your coding agent can drive every one of these commands. Give it the agent skill and it knows the schema, the flags, and how to read a failed build.

Draft Mode

By default spawned apply deploys immediately. Turn on Draft mode in a project’s sidebar and spawned apply stages the schema as the project’s draft instead: nothing deploys, the pending changes show up on the canvas, and you apply or discard them there. Canvas edits always go through the same draft, so an agent’s proposal and your own edits land in one place.

The agent sees Staged for review (revision N) plus a per-component summary. In draft mode spawned export <ref> returns the draft (add --deployed for the live schema), and spawned diff <ref> shows what it changes; applying or discarding happens on the canvas.

Each project has one draft. In draft mode every spawned apply replaces it with the agent’s latest file; with draft mode off, spawned apply deploys and clears any draft.

Commands

CommandDescription
initCreate a new project and write a starter infra.json
validateValidate an infra.json without applying it
applyApply an infra.json to a project to provision it
listList your projects
getGet a project and its deployment outputs
diffShow what the staged draft changes against the deployed schema
logsStream runtime logs from a component
buildsList a project’s builds and view build logs
uploadUpload a file to a Bucket component
exportExport a project’s generated files
schemaPrint the infrastructure schema as JSON
cloudsManage the clouds an organization can deploy to
orgManage organizations
apikeysManage API keys
reposList GitHub repos available through the GitHub App
configManage CLI defaults
login, logoutSign in and out of Spawned

Many commands have subcommands and options. Run spawned <command> --help for details.

Flags

FlagDescription
-h, —helpHelp for a command
-v, —versionShow the CLI version