@cdr-kit/CLI

cdr command

One binary, three surfaces. cdr ships every cdr-kit operation as a CLI command (25 commands), cdr mcp starts the stdio MCP server, cdr skill install drops the Claude Code plugin. Auto-creates the agent's wallet on first run.

Install

terminal
$ npm install -g @cdr-kit/cli
$ cdr --help

First run

terminal
$ cdr wallet
# first run prints a banner with the auto-generated address + faucet URL → stderr
# subsequent runs return the wallet state as JSON / pretty-printed object

The wallet is generated by viem's generatePrivateKey(), stored at ~/.config/cdr-kit/wallet.json (resolved cross-platform via env-paths), and written with chmod 600. Override anytime with CDR_PRIVATE_KEY=0x....

Commands

CommandDescription
cdr mcpStart the stdio MCP server. Same surface @cdr-kit/mcp exposes.
cdr wallet [--json]Show address, network, balance, wallet path (doctor command).
cdr wallet new [--force]Force-generate a new wallet (refuses to overwrite without --force).
cdr wallet export --yesPrint the private key (DANGEROUS — requires --yes to confirm).
cdr fundPrint address + open the Aeneid faucet in your browser (captcha-gated).
cdr configPrint resolved network / RPC / API URL / wallet path.
cdr feesAllocate / write / read fees + operational threshold (view-only).
cdr discover [--from-block N]Scan factory VaultCreated events.
cdr vault info <uuid>Vault info + plan + your entitlement, in one call.
cdr vault list --creator <addr>Every vault a creator has minted.
cdr vault create --read <addr> --read-config <hex> [--license-terms-id N]Create + configure + allocate — one tx.
cdr subscribe <uuid> [--periods N] [--max-price wei]Subscribe to + read a subscription-gated vault.
cdr access <uuid> [--aux-data hex]Read a vault you're already entitled to.
cdr access-license <uuid> --license-token-id NRead a license-gated vault by presenting a Story license token.
cdr subscriptionsEvery vault the agent is currently subscribed to.
cdr toolsEnumerate all 34 MCP tools (introspection).
cdr skill installInstall the cdr-kit Claude Code plugin into ~/.claude/skills/cdr-kit/.
cdr create time-window --start <ts> --end <ts> [--block-based]Create a TimeWindowCondition vault — read allowed only during [startTs, endTs].
cdr create dead-man --duration <s> --heirs <list> [--public-after]Create a DeadManSwitchCondition vault — auto-unlocks to heirs after the heartbeat lapses.
cdr create escrow --price <wei> --timeout <s> [--arbiter <addr>]Create a ConditionalEscrowCondition vault — buyer pays, confirms, then reads.
cdr create multi-sig --signers <list> --threshold <n>Create an N-of-M MultiSigCondition vault (off-chain sigs OR on-chain approve).
cdr poke <uuid>Reset the dead-man-switch heartbeat for a vault you created.
cdr multi-sig approve <uuid>On-chain Safe-style approval — agent must be a configured signer.
cdr multi-sig sign <uuid> --caller <addr> --deadline <ts>Produce an off-chain EIP-712 sig for collecting threshold-many off-band.
cdr multi-sig access <uuid> --deadline <ts> --sigs <list>Read a multi-sig vault by submitting collected off-chain sigs.
cdr multi-sig rotate <uuid> --signers <list> --threshold <n>Creator-only signer rotation; bumps epoch (invalidates BOTH paths).
cdr escrow pay <uuid> --price <wei>Buyer step 1 — escrow the listing price (excess refunded same tx).
cdr escrow confirm <uuid>Buyer step 2 — confirm delivery, releases funds + grants read.
cdr escrow claim-timeout <uuid> --buyer <addr>Seller — claim funds + grant buyer read after timeoutSecs of silence.
cdr escrow arbiter-refund <uuid> --buyer <addr>Arbiter — refund a buyer who paid but disputes delivery.
cdr ip register --spg <addr> [--metadata <uri>]Register a freshly-minted SPG NFT as a Story IP asset.
cdr ip attach-terms --ip <addr> --terms-id <id>Attach existing PIL license terms to an IP.
cdr ip mint-license --licensor <addr> --terms-id <id> [--amount N]Mint Story license tokens against an IP's licenseTermsId.
cdr ip register-derivative --child <addr> --parents <list> --terms-ids <list>Register a derivative IP — child inherits parents' PIL terms.
cdr ip wrap-ip --amount <wei>Wrap native IP into WIP (required before paying royalties).
cdr ip approve-wip --spender <addr> --amount <wei>Approve a spender (typically RoyaltyModule) to pull WIP.

Global flags

terminal
--network aeneid|mainnet   # default aeneid; mainnet throws (not yet deployed)
--json                     # machine-readable JSON output for any command

Use as MCP server

cdr mcp is the same stdio server @cdr-kit/mcp ships. Either binary works for MCP host configs — most prefer npx @cdr-kit/mcp for zero install footprint.

terminal
$ claude mcp add cdr-kit npx @cdr-kit/mcp