leapcat-portfolio

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

LeapCat Portfolio Skill

LeapCat 投资组合技能

View portfolio overview and stock positions using the leapcat. These are read-only commands for checking the user's current holdings and performance.
通过leapcat查看投资组合概览和股票持仓。这些是只读命令,用于查询用户当前的持仓和收益表现。

Prerequisites

前置条件

  • Node.js 18+ is required (commands use
    npx leapcat@latest
    which auto-downloads the CLI)
  • User must be authenticated — run
    npx leapcat@latest auth login --email <email>
    first
  • 需要安装 Node.js 18+ 版本(命令使用
    npx leapcat@latest
    会自动下载CLI)
  • 用户必须完成身份验证 — 请先运行
    npx leapcat@latest auth login --email <email>

Commands

命令

portfolio overview

投资组合概览

Get a high-level summary of the user's portfolio including total value, profit/loss, and asset allocation.
bash
npx leapcat@latest portfolio overview --json
获取用户投资组合的高层摘要,包括总价值、盈亏情况和资产配置。
bash
npx leapcat@latest portfolio overview --json

portfolio positions

投资组合持仓

List all current stock positions with details such as symbol, quantity, average cost, current price, and unrealized P&L.
bash
npx leapcat@latest portfolio positions --json
列出所有当前股票持仓的详细信息,包括代码、持仓数量、平均成本、当前价格和浮盈浮亏。
bash
npx leapcat@latest portfolio positions --json

Workflow

工作流程

  1. Check portfolio overview — Run
    portfolio overview --json
    to get a summary of total portfolio value and performance.
  2. View positions — Run
    portfolio positions --json
    to see individual stock holdings and their current status.
  3. Cross-reference with market data — Use
    market quote --symbol <symbol> --exchange <exchange> --json
    to get real-time prices for specific positions.
  1. 查看投资组合概览 — 运行
    portfolio overview --json
    获取投资组合总价值和表现的摘要。
  2. 查看持仓 — 运行
    portfolio positions --json
    查看单只股票持仓及其当前状态。
  3. 与市场数据交叉比对 — 使用
    market quote --symbol <symbol> --exchange <exchange> --json
    获取特定持仓的实时价格。

Error Handling

错误处理

ErrorCauseResolution
NOT_AUTHENTICATED
Session expiredRe-authenticate with
auth login
TOKEN_EXPIRED
Auth token has expiredRun
auth refresh --json
错误原因解决方案
NOT_AUTHENTICATED
会话过期运行
auth login
重新验证身份
TOKEN_EXPIRED
身份验证令牌已过期运行
auth refresh --json