OKX CEX Smart Money CLI
Smart Money leaderboard, trader analytics, position tracking, and aggregated consensus signals.
Preflight
Before running any command, follow ../_shared/preflight.md.
Use metadata.version from this file's frontmatter as the reference for Step 2.
Prerequisites
Install
okxCLI:npm install -g @okx_ai/okx-trade-cliConfigure credentials:
okx config init # select site -> follow browser OAuth flowVerify:
okx smartmoney traders-by-filter --limit 5
Security: NEVER accept credentials in chat. Guide users to
okx config initfor setup.
Credential & Profile Check
Run both commands before any authenticated command â the apiKey field from okx auth status --json is the auth-binary's internal state and is always false regardless of whether ~/.okx/config.toml has an API-key profile. okx config show --json is the only authoritative source for API-key presence. The auth method is detected during preflight Step 2 and remembered for the session.
okx config show --json # reveals API-key profiles (TOML config)
okx auth status --json # reveals OAuth session state (auth-binary state)
Apply in this order â first match wins:
config show --jsonhas any profile with a non-emptyapi_keyfield â API Key mode. Proceed.- No API-key profile AND
auth status --jsonreturns"status":"logged_in"â OAuth mode. Proceed. - No API-key profile AND
"status":"pending"â login is in progress, wait for it to complete. - No API-key profile AND
"status":"not_logged_in"â stop, loadokx-cex-authskill and follow login steps, wait for completion.
Smart Money does not support demo mode (leaderboard data is live-only). Always use live mode silently â don't mention it unless there's an error.
- API Key users: use
--profile <live-profile>(the profile withoutdemo=true). - OAuth users: no flag needed (live is the default).
On authentication errors (401 / "Session expired" / "Run okx auth login first"): stop immediately, load okx-cex-auth skill and follow re-authentication steps, then retry.
Skill Routing
| User intent | Route to skill |
|---|---|
| Market prices, tickers, candles | okx-cex-market |
| Spot / swap / futures / options orders | okx-cex-trade |
| Account balance, positions, transfers | okx-cex-portfolio |
| Grid / DCA / Smart Portfolio / Recurring Buy trading bots | okx-cex-bot |
| Simple Earn, Flash Earn, On-chain Earn, Dual Investment (Ã¥ÂÂå¸Âèµ¢), or AutoEarn (èªå¨èµÂå¸Â) | okx-cex-earn |
| Smart Money leaderboard, signals, trader analytics | This skill |
Command Index (10 commands, all read-only)
Trader family (6)
| Command | Type | Auth | Description |
|---|---|---|---|
smartmoney traders-by-filter |
READ | Required | Leaderboard ranking by pool conditions (period / minPnl / minWinRate / maxDrawdown / minAum). Paginated by authorId. Names use min* / max* prefix â disjoint from signal-side *Tier namespace. |
smartmoney performance-by-trader --authorIds <id1,id2> |
READ | Required | PnL / win-rate profile for one or more authorIds. `--sortBy <pnl |
smartmoney search-trader --keyword <name> |
READ | Required | Search Top Traders by nickname keyword (â¤10 results, ranked by follower count). |
smartmoney trader-positions --authorId <id> |
READ | Required | Current open positions for one trader. Filter by --instId <BTC-USDT-SWAP> (or bare base ccy). |
smartmoney trader-positions-history --authorId <id> |
READ | Required | Closed-position history with realized PnL. Paginated by posId. |
smartmoney trader-orders-history --authorId <id> |
READ | Required | Order / fill records. Paginated by ordId. |
Signal / coin family (4)
| Command | Type | Auth | Description |
|---|---|---|---|
smartmoney signal-overview-by-filter |
READ | Required | Multi-asset signal, tier-filtered pool. Pick coins via --topInstruments (top-N hottest) OR --instCcyList BTC,ETH,SOL (specific) â exactly one. Use this to discover the hottest coins among smart money. |
smartmoney signal-overview-by-trader --authorIds <id1,id2> |
READ | Required | Multi-asset signal aggregated over a hand-picked set of traders (authorIds-direct-lookup). Pick coins via --topInstruments OR --instCcyList. --sortBy (default pnl) and --period (default 7) drive capability metrics. Capability tier filters (pnlTier / winRateTier / etc.) not exposed. |
smartmoney signal-trend-by-filter --instCcy <ccy> [--asOfTime <yyyyMMddHH>] |
READ | Required | Single-coin smart-money signal time-series anchored at asOfTime (defaults to current UTC hour), tier-filtered pool. `--granularity 1h |
smartmoney signal-trend-by-trader --authorIds <id1,id2> --instCcy <ccy> [--asOfTime <yyyyMMddHH>] |
READ | Required | Single-coin smart-money signal time-series aggregated over a hand-picked set of traders (authorIds-direct-lookup). `--granularity 1h |
Time anchor:
signal-trend-by-{filter,trader}take an optional--asOfTime <yyyyMMddHH>(10-digit UTC hour, e.g.2026050100). Returns the latest--limitbuckets ending at that anchor. Omit--asOfTimeto use the current UTC hour.signal-overview-by-{filter,trader}does not expose any time input â handler always uses the current hour.
Multi-coin selection:
signal-overview-by-filterandsignal-overview-by-traderaccept--topInstruments(top-N hottest) or--instCcyList BTC,ETH,SOL(explicit base ccy list). The two flags are mutually exclusive. Passing neither defaults to--topInstruments=20.
â Linear-only scope: All four
signal-*commands aggregate USDT-margined and USDS-margined contracts only. Coin-margined contracts (BTC-USD-SWAP,BTC-USD-DELIVERY,ETH-USD-SWAP, â¦) are excluded by upstream â a trader's coin-margined positions are silently dropped fromlongNotional/shortNotional/tradersWithPosition. If a trader holds large coin-margined exposure but no linear position on that coin, they will not appear in the signal at all. To see a trader's full position book including coin-margined, runsmartmoney trader-positions --authorId <id>.
Need a trader's full picture? The old
smartmoney tradercomposite command is removed. Runperformance-by-trader,trader-positions, andtrader-orders-historyin parallel.
For full command syntax and parameters, read {baseDir}/references/trader-commands.md and {baseDir}/references/signal-commands.md.
Operation Flow
Step 0 â Credential & Profile Check
Before any authenticated command: see Credential & Profile Check. Always use live mode silently.
Step 1 â Identify intent
Trader discovery / ranking:
- "æÂ¨èÂÂ交æÂÂÃ¥ÂÂ" / "top traders" / "çÂÂ人æ¦Â" âÂÂ
smartmoney traders-by-filterwith sorting/filtering. See{baseDir}/references/trader-commands.md. - "çÂÂçÂÂæÂÂ个交æÂÂÃ¥ÂÂ" / "trader detail" â run
performance-by-trader,trader-positions,trader-orders-historyin parallel (the old compositesmartmoney traderis removed). - "æÂÂç´¢ alice / å°ÂæÂÂ" / "find trader by nickname" âÂÂ
smartmoney search-trader --keyword <name>(returns â¤10 matches withauthorIdto feed into other tools). - "verify these authorIds" / å·²çÂÂ¥ authorId âÂÂ
smartmoney performance-by-trader --authorIds <id1,id2>(direct lookup;--sortBy/--periodhonored, defaultspnl/90). - "ä»ÂçÂÂå½ÂÃ¥ÂÂæÂÂä»Â" / "current positions only" âÂÂ
smartmoney trader-positions --authorId <id>. - "ä»ÂçÂÂæÂÂ交记å½Â" / "trade history" âÂÂ
smartmoney trader-orders-history --authorId <id>(paginated). - "Ã¥ÂÂå²平ä»Â" / "closed positions" / "realized PnL track record" âÂÂ
smartmoney trader-positions-history --authorId <id>(paginated).
Signal analysis:
- "BTC èªæÂÂé±信å·" / "smart money signal for BTC" âÂÂ
smartmoney signal-overview-by-filter --instCcyList BTC. See{baseDir}/references/signal-commands.md. - "BTC ETH SOL è¿Âå 个å¸ÂçÂÂä¿¡å·" / "signals for these specific coins" âÂÂ
smartmoney signal-overview-by-filter --instCcyList BTC,ETH,SOL. - "è¿Âå 个交æÂÂÃ¥ÂÂçÂÂåªäºÂå¸Âï¼Â" / "consensus among these specific traders" âÂÂ
smartmoney signal-overview-by-trader --authorIds <id1,id2>(defaults to top-20 hottest among the group, or pass--instCcyList). - "èªæÂÂé±åÂ
³æ³¨åªäºÂå¸Âï¼Â" / "what are smart money trading right now?" âÂÂ
smartmoney signal-overview-by-filter(defaults to--topInstruments=20). See{baseDir}/references/signal-commands.md. - "ä¿¡å·è¶Âå¿" / "signal trend over time" âÂÂ
smartmoney signal-trend-by-filter --instCcy <ccy> [--asOfTime <yyyyMMddHH>] [--limit 24](orsignal-trend-by-trader --authorIds <ids> --instCcy <ccy>for an authorIds-scoped trend).
Step 2 â Execute and present
All commands are READ-only â no confirmation needed. Always pass --json and render results as Markdown tables.
For multi-step workflows (recommend traders then drill down, signal analysis with context), read {baseDir}/references/workflows.md.
Global Notes
- Security: Never ask users to paste API keys or secrets into chat.
- Output: Always pass
--jsonto list/query commands and render results as a Markdown table â never paste raw terminal output. - Network errors: If commands fail with a connection error, prompt user to check VPN:
curl -I https://www.okx.com - Language: Always respond in the user's language.
- Time inputs:
signal-trend-by-{filter,trader}take an optional--asOfTime <yyyyMMddHH>anchor (10-digit UTC hour); omit to use the current UTC hour.--limitcontrols how many buckets are returned ending at that anchor.signal-overview-by-{filter,trader}takes no time input â handler always uses the current hour.
For number/time formatting and response structure conventions, read {baseDir}/references/templates.md.
Installs: 6.4K | GitHub stars: 204 | First seen: Apr 23, 2026


