@augustdigital/cli

中文文档
4.13.51发布于 2026/10/28MITTypeScriptCommonJS近 30 天下载 3597

CLI powering the August Digital ecosystem.

原始使用文档
文档目录13 节
  1. Install
  2. Quickstart
  3. Config layout
  4. Auth
  5. Global flags
  6. Commands
  7. Vault names
  8. Recipes
  9. Claude Code skill
  10. JSON envelope
  11. Programmatic use
  12. Exit codes
  13. Watch mode

@augustdigital/cli

The august command — a read-only CLI over the August Digital SDK. Inspect vault APY, TVL, positions, redemptions, and user points across EVM, Solana, and Stellar without writing TypeScript.

Read-only by design. There are no signing or write commands.

Install

npm install -g @augustdigital/cli

Or run without installing:

npx -y @augustdigital/cli --help

Quickstart

august init                              # one-time setup
august whoami                            # confirm config + API key status
august vault apy 0xVault --chain 8453    # current APY (human output)
august vault apy eth-coreusdc            # same call, by name
august vault apy 0xVault --chain 8453 --json | jq .data.currentApy

Config layout

august init writes:

~/.augustdigital/
├── config.json    # default chain, RPCs, profile, telemetry
├── keystore.json  # AES-256-GCM; holds your August API key (optional)
├── .session       # mode 0600; decrypted API key + expiry
└── profiles/      # named overlays for chain + RPC sets

Override the root with AUGUST_CONFIG_DIR=….

Auth

If you stored an API key during init, run august login once per shell to unlock the keystore. Subsequent commands read from .session until it expires (default 1h, set config.auth.sessionTtlSec). august logout clears it.

In CI, either set AUGUST_PASSPHRASE (so login runs non-interactively) or skip the keystore entirely and use AUGUST_API_KEY. Env vars always win over the session.

Global flags

FlagPurpose
--jsonStable JSON envelope on stdout.
--csvCSV output (tabular commands only).
--chain <id>Chain id for this call.
--rpc <url>RPC URL override (pair with --chain).
--profile <name>Named profile to activate.
--no-colorDisable ANSI colors.
--verboseDiagnostics on stderr.
--config-dir <path>Override ~/.augustdigital for this call.

Commands

GroupCommand
Setupinit, login, logout, whoami
Configconfig get|set|list|path
Profilesprofile create|switch|list|delete
Diagnosticschain list, rpc test [--chain <id>]
Vaultvault list|get|apy|tvl|positions|loans|allocations|redemptions|history|summary
Useruser points|positions|pnl --vault <addr-or-name>
Skillskill install|path

Run august <command> --help for per-command flags and examples.

Vault names

Every command that takes <vault> (and user pnl --vault …) accepts either a raw address or a vault name:

august vault list                           # discover known names per chain
august vault tvl coreusdc                   # bare symbol, chain inferred
august vault tvl eth-coreusdc               # explicit chain prefix
august vault tvl 0xE9B7…32 --chain 1        # raw address (unchanged)

Chain prefixes accepted: eth/mainnet, base, arb/arbitrum, op/optimism, avax/avalanche, bsc/bnb, polygon/matic, hyperevm/hyper, monad, mezo, plasma, ink, flare.

If a bare name matches multiple chains, the CLI returns VAULT_NAME_AMBIGUOUS; either prefix the name or pass --chain. Names come from the upshift metadata endpoint and are cached in-process for 10 minutes — addresses always work without a network call.

Recipes

# Inspect a vault
august vault summary 0xVault --chain 8453
august vault apy 0xVault --chain 8453 --json | jq .data.currentApy

# Wallet's positions across all August vaults
august user positions 0xWallet --json \
  | jq '.data.positions[] | {vault, chainId, shares}'

# Lifetime PnL for a wallet in one vault
august user pnl 0xWallet --vault 0xVault --chain 1

# Diagnose a flaky RPC
august rpc test --json

# Per-call RPC override (no config change)
AUGUST_RPC_8453=https://my-rpc.example/v1 august vault tvl 0xVault --chain 8453

# Environment-specific config
august profile create staging --chain 8453
august profile switch staging
august config set rpcs.8453 https://staging-rpc.example/v1

Claude Code skill

Ships with a Claude Code skill that teaches Claude how to call the CLI and the companion MCP server:

august skill install
# → ~/.claude/skills/august.md

Override the destination with --dest <dir> (or CLAUDE_SKILLS_DIR). Pass --force to overwrite a divergent file.

JSON envelope

Every --json response uses the same envelope as @augustdigital/mcp:

{
  "schemaVersion": 1,
  "command": "vault.apy",
  "ok": true,
  "data": { "address": "0x…", "chainId": 8453, "currentApy": 0.1234 },
  "meta": { "chainId": 8453, "durationMs": 312, "generatedAt": "2026-05-17T…" }
}

On failure: ok: false, error: { code, message, remediation? }. Match on error.code — message text is not part of the contract.

Programmatic use

import { buildProgram } from '@augustdigital/cli';

const program = buildProgram();
await program.parseAsync(['node', 'august', 'whoami', '--json']);

buildProgram() returns the same commander tree the binary uses, so embedders (tests, MCP servers, internal tooling) can drive the CLI without spawning a child process.

Exit codes

CodeMeaning
0Success — and for ops commands, no anomalies.
1Execution error (bad input, network failure, unresolved vault). The --json envelope carries error.code + remediation.
2ops health / ops redemptions completed but found anomalies (data.anomalies > 0). Cron on a non-zero exit to alert.

Watch mode

points leaderboard, vault pending-redemptions, ops health, and ops redemptions accept --watch <seconds>. Human output re-renders in place; --json emits one envelope per tick (NDJSON) for piping.

版本与发布记录

@augustdigital/cli 共发布 110 个版本,首次发布于 2025/10/07;过去 12 个月发布了 79 个版本。

版本发布日期距今
4.13.51latest2026/10/2810 天前
4.13.502026/10/2711 天前
4.13.492026/10/2415 天前
4.13.482026/10/1523 天前
4.13.472026/10/1524 天前
4.13.462026/10/1425 天前

关于 @augustdigital/cli 的常见问题

@augustdigital/cli 是什么?

CLI powering the August Digital ecosystem.

如何安装 @augustdigital/cli?

在项目目录运行 npm install @augustdigital/cli,或使用 pnpm add / yarn add / bun add。它还提供命令行工具 august,可以用 npx august 直接运行。

@augustdigital/cli 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@augustdigital/cli 支持 ESM 还是 CommonJS?

以 CommonJS 形式发布,可以直接 require();在 ES Module 项目中也可以用 import 引入(Node.js 会把 module.exports 作为默认导出)。

@augustdigital/cli 需要什么版本的 Node.js?

package.json 的 engines 字段要求 Node.js >=22.23.4 <23.0.0 || >=24.22.1 <25.0.0 || >=26.12.1。版本不符时 npm 默认只给出警告,开启 engine-strict 后会拒绝安装。

@augustdigital/cli 可以商用吗?

@augustdigital/cli 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@augustdigital/cli 的下载量有多少?

根据 npm 官方下载统计,@augustdigital/cli 在 2026/10/07 – 2026/11/05 这 30 天内被下载 3,597 次,日均约 120 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@augustdigital/cli 还在维护吗?

最新版本 4.13.51 发布于 2026/10/28(10 天前);至今共发布 110 个版本,其中过去 12 个月发布了 79 个;首次发布于 2025/10/07。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。