CLI daemon
Run Glueprint as a headless background service on any 64-bit Linux, macOS, or Windows machine.
- Topic
- CLI Daemon
- Available on
- Available onCLI Daemon
- Reviewed
- October 8, 2026
On this page
The CLI daemon is Glueprint as a long-running background service. Same engine as the desktop — assistants, sessions, routines, the cloud relay — without a graphical interface. Drive it from the portal, the mobile app, or another desktop machine.
A CLI daemon host detects and serves port forwarding the same way as a desktop host.
Use it when:
- You want assistants and routines running 24/7 on a server you don’t keep logged in.
- A laptop closing its lid shouldn’t stop work.
- You’re running an autonomous fleet of agents on dedicated infrastructure.
At a glance
- Binary name:
glueprint. - Platforms: 64-bit Linux, macOS, Windows.
- Storage: writes to the OS-standard Glueprint data directory (
~/.glueprinton Unix;%APPDATA%\Glueprinton Windows). - Signals:
SIGINT/SIGTERM/SIGHUPall trigger graceful shutdown.
Install
On a machine that runs the desktop app, the CLI is bundled with it. Open Settings > General > Command line tool and click Install: Glueprint writes a glueprint command into the bin directory under its data directory (~/.glueprint/bin on Unix), pointed at the same storage root the app uses, and registers that directory on your PATH for future shells. The same row offers Reinstall after an app update and Uninstall. Existing terminals may need reopening after the PATH change.
On a server or headless machine without the desktop app, install the CLI with one command:
curl -fsSL https://install.glueprint.ai | sh
This downloads the latest glueprint binary for your platform into ~/.glueprint/bin and adds that directory to your PATH via your shell profile. For air-gapped or manual setups, download the platform archive from the releases CDN (https://releases.glueprint.ai/cli/) and put the binaries somewhere on your PATH instead.
Quickstart
# Activate the daemon with a key from the portal
glueprint activate --key gp_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
# Start the daemon. Add --http-port to expose local health endpoints.
glueprint run --http-port 7878
# In another shell:
glueprint status
glueprint session list
Stop the daemon with Ctrl+C (or systemctl stop if you’ve installed it as a service).
Command reference
The daemon has these top-level subcommands. Each supports --help for the full flag list.
glueprint run
Start the daemon.
--port <PORT>— MCP server port. Default0(OS-assigned).--http-port <PORT>— Optional. Opens a small local HTTP server on127.0.0.1:<PORT>that exposes the monitoring endpoints below. Use this when you want a health-check probe, a Prometheus-style scraper, or a custom script to read the daemon’s state. Omit the flag and no HTTP server starts.--log-level <LEVEL>—trace/debug/info(default) /warn/error.--environment <ENV>—production(default) /staging/local.
A global --verbose flag promotes the log level to debug.
glueprint activate
On Pro, Team, or Enterprise, open Settings > Hosts, click Create Host, and generate a CLI daemon host key. Its format is gp_ plus 64 hexadecimal characters, as with the desktop’s alternative key path, but a key is bound to its host type. Free’s guided included-host setup is desktop-only. The desktop’s account-first browser flow does not replace CLI activation.
--key <KEY>— pass the key directly. Omit to be prompted interactively.--environment <ENV>— target cloud environment.
The key is stored in a permission-restricted credentials file under the daemon’s data directory (~/.glueprint/credentials.toml, mode 600), and the GLUEPRINT_API_KEY environment variable overrides it.
glueprint status
Print daemon and system health.
--format <FORMAT>—text(default) orjson.
Output includes whether the daemon is running, whether an API key is configured, totals per session status, detected agents with versions, and scheduled routine summary.
glueprint agent detect
Detect installed coding agents (Claude Code, Codex, Gemini) and Glueprint companion binaries (MCP, analytics) on PATH, with each agent’s login status. Signed-out agents get a glueprint agent login suggestion.
--format <FORMAT>—text(default) orjson.
glueprint agent login <AGENT>
Run the agent’s own sign-in in this terminal (for example codex login --device-auth), then report whether it is now signed in. Exits 0 only when it is.
--account <ID>— sign in one of the agent’s managed accounts instead of the machine’s own login (Claude Code and Codex).--format <FORMAT>—text(default) orjson.
You can also sign agents in from the desktop app or the web portal without a shell on the host: see Sign agents in on another host.
glueprint session list
List sessions on the host.
--status <STATUS>— filter to one ofrunning,stopped,completed,failed,ready,waiting,paused,interrupted.--format <FORMAT>—textorjson.
glueprint session stop <ID>
Stop a session by id (full UUID or a short prefix).
--format <FORMAT>—textorjson.
Errors if the session is already in a terminal state. --offline repairs the saved status of a session after the runtime itself has stopped; it never terminates a process. See Cross-host work and recovery.
Orchestration and session control
These families talk to the runtime already running on this machine (the daemon or the desktop app) and support the global --json envelope. Full reference: Orchestration from the CLI.
glueprint session start|send|steer|interrupt|status|stop— start and drive sessions from a terminal, optionally on another host with--on <HOST_ID>.glueprint session eventsreads a page of a local session’s events and does not accept--on.glueprint run create|list|show|close|reset— private orchestration runs.glueprint runwith no subcommand still starts the daemon.glueprint task create|update|list|show|dep add|dep rm— private tasks and their dependencies (not the product boards; those areglueprint board task ...).glueprint worker start|show|read|stop|retry— worker sessions dispatched for one ready task.glueprint gate create|resolve|list— decision gates that block a task until answered.glueprint checkandglueprint inbox check|ack— read and acknowledge a coordinator inbox.glueprint host list— the host inventory used by--on.glueprint guide orchestration— print the bundled orchestration guide.
glueprint config get [KEY] / glueprint config set <KEY> <VALUE>
Read or update settings. Keys are dot-separated (for example, appearance.theme, notifications.enabled, cloud.environment). get with no key dumps the full config. set only updates existing keys; it does not create new ones. Types are inferred (booleans, integers, floats with a decimal, otherwise strings).
glueprint service
Install the daemon as an OS service. Default behavior is to install at the user level on the current platform’s service manager (launchd on macOS, systemd on Linux, Task Scheduler on Windows). A user-level systemd service runs only while that user has a login session unless lingering is enabled: on a Linux server, run loginctl enable-linger $USER once so the daemon keeps running after you log out and starts at boot. (--no-user installs a system unit that runs as root with HOME=/home/glueprint; edit its User= and HOME= to the account that ran glueprint activate before relying on it.) On macOS, a user-level service runs while that user is logged in to the Mac.
service install— install as a service. Options:--no-userto install at the system level (requires root),--bin <PATH>to override the binary location,--print-onlyto print the service definition and the install command without actually modifying the service registry. On macOS and Linux a user-level install records your shell’sPATH(plus common user bin directories) in the service definition, so agents installed through npm, nvm or~/.local/binare found; run it again after you change Node versions. A system-level (--no-user) install keeps the service manager’s defaultPATH.service uninstall— remove the service. Supports--no-user.service status— report installed / active state. Supports--no-user,--check-both,--format.
HTTP monitoring endpoints
The daemon doesn’t expose a public API. The --http-port flag opens a tiny read-only HTTP server on 127.0.0.1 only so local monitoring tools can ask the daemon what it’s doing without parsing logs or invoking the CLI on every check.
Typical uses:
- A systemd watchdog or supervisor process that needs a 200 OK to confirm the daemon is alive.
- A Prometheus / Datadog / similar agent that scrapes session counts and cloud-connection state.
- A custom script or dashboard that reads
/sessionsto surface what’s running.
When --http-port is set, three JSON endpoints bind to 127.0.0.1:<PORT>:
GET /health— status ("ok"), version, uptime in seconds.GET /sessions— the active session list (id, name, status, project id, created-at).GET /state— cloud connection state, plan, uptime, scheduler active flag, and counts of running / ready / waiting sessions.
Since the server binds to loopback, you reach it from the same machine only — through localhost, an SSH tunnel, or whatever local proxy you’ve set up.
Shutdown behavior
On SIGINT, SIGTERM, or SIGHUP the daemon performs a graceful shutdown:
- Stops the scheduler so no new routines fire.
- Stops file and git watchers.
- Cancels in-progress task runs.
- Drains language servers.
- Sends
SIGTERMto running agent subprocesses, waits 5 seconds, thenSIGKILL. - Transitions sessions to
Stopped. - Disconnects from the cloud relay.
A second SIGINT short-circuits to immediate exit.