CLI Overview
morse-cli is the command-line client for the Morse decentralized CMS. It signs with a locally encrypted key, stores content on Walrus, and encrypts private entries with Seal: the same protocol surface as the SDK, driven from your terminal. Runs on Node or Bun and targets testnet or Walrus Mainnet.
@arcadiasystems/morse-cli from npm. It targets testnet unless you choose mainnet with --network, MORSE_NETWORK or a profile. Mainnet spends real SUI and WAL, so test on testnet first.Installing
The published binary is a Node-targeted bundle. You need Node (≥ 18) or Bun (≥ 1.2) to run it.
npm i -g @arcadiasystems/morse-cli morse --help
Also available via bun add -g or pnpm add -g.
Or run without installing:
npx @arcadiasystems/morse-cli --help
Getting started
Select an active publication and collection once. All subsequent commands will use them automatically, so you never have to paste a 64-character object ID. publication create and collection create auto-select the new object.
See CLI Cookbooks for step-by-step guides.
Active context
The active publication and collection live in the current profile. Override per command with -P, --publication <slug|id> and -C, --collection <name>. Slugs resolve against publications owned by the active account.
morse use <slug|id> [collection]: set the active publication and collection (optional)morse use --clear: clear the active contextmorse status: show the active profile, account, publication, and collection
Security model
Private keys are stored in an encrypted keystore (scrypt + AES-256-GCM) and unlocked by a password.
- Keys are never accepted as command-line flags. They come only from an interactive hidden prompt, the
MORSE_PRIVATE_KEYenv var, or the encrypted keystore. - Keystore files are written
chmod 600; group- or world-readable key files are refused on read. - Keys are never printed or logged, including under
--debug. The sole exception isaccount export, which deliberately reveals a key: interactive-only, requires confirmation, unavailable in--json. - For CI, set
MORSE_PRIVATE_KEY(raw key, never persisted) andMORSE_KEYSTORE_PASSWORDto skip prompts.
Configuration
Settings resolve with the precedence flags > MORSE_* env > config file > defaults. The config file lives under $XDG_CONFIG_HOME/morse (default ~/.config/morse); encrypted keystores live in keystores/ beside it.
| Variable | Overrides | Notes |
|---|---|---|
MORSE_PROFILE | -p, --profile | Profile to use. |
MORSE_NETWORK | --network | testnet, mainnet or localnet. |
MORSE_RPC_URL | --rpc | Sui RPC URL override. |
MORSE_ADDRESS | (no flag) | Active account address. |
MORSE_PUBLICATION | -P, --publication | Active publication ID. |
MORSE_COLLECTION | -C, --collection | Active collection name. |
MORSE_PRIVATE_KEY | (no flag) | Raw Bech32 secret key. Highest-priority key source; never persisted. |
MORSE_KEYSTORE_PASSWORD | (no flag) | Keystore password for non-interactive unlock. |
Output & scripting
- Human-readable output goes to stdout; progress, warnings, and prompts go to stderr. Redirecting stdout yields only the result.
- In
--jsonmode,bigintvalues (e.g.gasUsedMist) are encoded as decimal strings and byte arrays (sealId, quilt patch IDs) as0x-hex. - Color is emitted only to a TTY and honors
NO_COLOR/FORCE_COLOR.
See CLI Command Reference → Global options for a full list of global flags (--json, --quiet, --yes, and more).
Exit codes
| Code | Meaning |
|---|---|
0 | Success |
1 | Generic error (contract abort, uncategorized) |
2 | Usage error (bad flags/args, invalid ID/slug/address, declined confirmation) |
3 | Not found |
4 | Auth or permission failure (keystore unlock, unauthorized, no-access) |
5 | Network or transport failure |