Are you an LLM? Read llms.txt for a summary of the docs, or llms-full.txt for the full context.
Skip to content

CLI: @pampalo/cli

The pampalo command-line tool, a thin wrapper over the SDK. Use it to create an agent account, sync it, check balances, and move money from a terminal or a shell script.

Install

pnpm
pnpm add -g @pampalo/cli

Installing globally gives you the pampalo binary. Requires Node 20+.

Quickstart

# create a fresh agent account (prompts for a passphrase)
pampalo init agent1
 
# …fund the printed EVM address with some Base Sepolia ETH / test tokens…
 
# scan the chain, then check balances
pampalo sync    -a agent1
pampalo balance -a agent1
account 0x81889262e283DDE619a62A2503F2A25970494C33  (chain 84532)
 
PUBLIC
  ETH   0.01
  USDC  25.0
 
PRIVATE (spendable notes)
  (none, run `pampalo sync`)
 
SHIELDS
  (none)

Authentication

Commands that touch the keystore need your passphrase. In order of precedence:

  1. --passphrase <s> flag
  2. PAMPALO_PASSPHRASE environment variable
  3. an interactive hidden prompt

For unattended use, set PAMPALO_MNEMONIC to a recovery phrase; it runs the account directly, no keystore or passphrase needed.

RPC configuration

Every on-chain command needs an RPC URL, resolved in this order:

  1. --rpc <url> flag
  2. PAMPALO_RPC environment variable
  3. ALCHEMY_API_KEY, from which the CLI builds the Alchemy URL for known chains (Ethereum, Base, and their Sepolia testnets)

The CLI also auto-loads a .env / .env.local from the current directory, so dropping ALCHEMY_API_KEY=… in a .env.local is enough to make sync and balance work.

Commands

CommandWhat it does
pampalo init [name]Create a fresh agent account + encrypted keystore
pampalo import [name]Import an existing recovery phrase into a keystore
pampalo address [name]Print the account's derived identifiers
pampalo balancePublic + private balances and shield statuses
pampalo syncScan the chain, rebuild notes + the merkle leaf set
pampalo sendPublic EVM transfer (native or ERC-20)
pampalo shieldPublic → private note (to self)
pampalo transferPrivate note → private note
pampalo unshieldPrivate note → public payout

Global options

FlagDefaultMeaning
-a, --account <name>defaultWhich keystore to use
-c, --chain <id>84532Chain id (Base Sepolia)
--rpc <url>(none)RPC URL (else PAMPALO_RPC / ALCHEMY_API_KEY)
-p, --passphrase <s>(none)Keystore passphrase (else prompt / env)
--json(none)Machine-readable output (for agents)

Moving money

Amounts are in human units (e.g. 1.5); the CLI resolves decimals from the asset. --asset accepts native, a known symbol (usdc), or a token address.

# public EVM transfer
pampalo send --to 0x… --amount 0.01 --asset native
 
# shield to yourself
pampalo shield --amount 10 --asset usdc
 
# private transfer to a recipient's identifiers
pampalo transfer --amount 5 --asset usdc \
  --poseidon 0x… --envelope 0x04…
 
# unshield to a public address (defaults to your own)
pampalo unshield --amount 3 --asset usdc --recipient 0x…

Add --json to any command for structured output that's easy for an agent to parse.

Files

PathContents
~/.pampalo/accounts/<name>.jsonEncrypted keystore (scrypt + AES-256-GCM, mode 0600)
~/.pampalo/pampalo.dbSQLite note store + sync cursors

Everything private stays on your machine; the CLI talks only to your RPC and the public chain.