Standalone remote CLI for deployed PocketBase instances.
PocketBase CLI provides a consistent command surface for remote administration, automation, and agent-driven workflows. It wraps the PocketBase HTTP API with stable command semantics, explicit confirmation guards, and machine-readable output designed for scripts and tools.
- Remote-first administration for deployed PocketBase instances
- Stable
--jsonoutput for automation and integrations - Machine-readable
schema --jsoncommand contract - Browser-assisted login with
auth login-browser - Encrypted local persistence for stored auth, config, and command history
- Explicit
--yesguardrails for destructive or side-effectful operations
One-line install or update from GitHub:
curl -fsSL https://raw.githubusercontent.com/Ericsunsk/Pocketbase-CLI/main/scripts/install-global.sh | bashThe installer clones or updates the repo under ~/.local/share/pocketbase-cli, builds it, installs the global pocketbase-cli command, and prints a PATH hint when needed.
npm install
npm run build
node dist/bin.js config set base_url https://pb.example.com
printf 'Secret123\n' | node dist/bin.js auth login --password-stdin admin@example.com
node dist/bin.js --json infoAlternative authentication flow:
node dist/bin.js auth login-browser
# headless hosts:
node dist/bin.js auth login-browser --no-openBase URL resolution priority is: command-line arguments > persisted config set ... values > POCKETBASE_CLI_BASE_URL > stored auth session target.
Only the remote base URL is read from the environment. Login identity and password must come from command arguments, --password-stdin, or the local browser form.
By default the CLI stores config, history, and auth state under ~/.cache/pocketbase-cli. The persisted session file is encrypted at rest and uses an adjacent .key file.
README.en.md: full English guideREADME.zh-CN.md: 完整中文指南FEATURES.md: feature and behavior referenceDEVELOPMENT.md: contributor and build guideTESTING.md: test strategy and validation guideCHANGELOG.md: release notesdocs/releases/v0.1.5.md: latest release summary