CLI
layer is Layer’s command-line interface. It reaches the same models, workspaces, and Creative Unit balance as the app, from a terminal, a Makefile, or a CI job.
uv tool install layerpipx install layerpip install layerThen sign in and generate:
layer loginlayer generate image -p "a cyberpunk market stall, isometric"The first run picks the recommended model for the modality, prints what it will cost, waits for the result, and writes the file into your working directory.
InstallInstallers, supported Python versions, and upgrading.
AuthenticationBrowser sign-in, device codes, and API keys for CI.
ConfigurationProfiles, layer.toml, and the environment variables that override them.
Generating assetsImage, video, mesh, and audio — every flag, and how runs are priced.
ModelsList what your workspace can run, and inspect what a model accepts.
ScriptingJSON output, the stdout/stderr split, and the published exit codes.
Command surface
Section titled “Command surface”| Command | What it does |
|---|---|
layer login / logout / whoami |
Sign in, sign out, and show who you are signed in as |
layer use <workspace> |
Choose the workspace subsequent commands act on |
layer generate image|video|mesh|audio |
Run a generation |
layer generate status <id> |
Read back a run submitted with --no-wait |
layer base-models list / show |
The catalogue your workspace can run, and one model’s inputs |
Global options apply to every command: --profile, --workspace/-w, --project, --api-url, --json, --quiet/-q, and --version.
Other ways to drive Layer
Section titled “Other ways to drive Layer”The CLI is for you and your scripts. If the caller is an AI agent rather than a shell, the MCP server gives it tools instead, and the Agent Skills teach it the procedures. For your own services, there is the REST API.