Developers
Flags & machine I/O
Global CLI flags, JSON envelopes, site targeting, and environment overrides for Frontpage.
Global flags
| Flag | Effect |
|---|---|
--json | Stable JSON envelope on stdout for supported commands |
--quiet | Suppress progress spinners / chatter |
--site <slug> | Subdomain override (most site-scoped commands) |
--yes | Confirm destructive ops (unpublish, revert) when non-TTY |
--help / -h | Per-command help (alias of frontpage help <cmd>) |
--message "…" | Commit message for push |
--limit <n> / --page <n> | History pagination where supported |
JSON envelope
{
"ok": true,
"command": "status",
"data": { }
}
{
"ok": false,
"command": "push",
"error": {
"message": "…",
"code": "conflict",
"httpStatus": 409,
"exitCode": 3
}
}
Failures with --json still use the process exit code; the envelope is on stdout. Some content
commands already return JSON bodies even without the flag — you can still wrap with global --json
where supported.
Site resolution order
--site <slug>if provided.frontpage/state.jsonslugin the current working directory- Error if neither is available for a site-scoped command
Environment overrides
| Variable | Purpose |
|---|---|
FRONTPAGE_API_KEY | Bearer key for the process (wins over keychain/file) |
FRONTPAGE_API_BASE | API origin (default https://app.frontpage.host) |
TTY vs CI
- Interactive prompts require a TTY unless you pass the value /
--yes. - In CI, set
FRONTPAGE_API_KEYand prefer--json.
Slug rules
- Use the subdomain slug only:
acme, notacme.frontpage.host - Custom domains are display metadata, not CLI targets