Skip to content

internet-court/internet-court-skill / vendored/okx/okx-defi

okx-defi

Verified

OKX-aggregated DeFi (no specific DApp named) — product discovery, deposit/withdraw/claim execution, AND positions viewing. **If the user names ANY third-party protocol/DApp (Aave, Lido, PancakeSwap, Uniswap, Curve, Compound, Morpho, Pendle, Kamino, Raydium, Hyperliquid, Polymarket, …), route to okx-dapp-discovery — NOT here, even for 'show my Aave positions'.** INVEST triggers: 'invest in DeFi', 'earn yield', 'find best APY', 'deposit/stake for yield', 'search DeFi products', 'redeem/withdraw position', 'claim DeFi rewards', 'borrow against asset', 'repay loan', 'add/remove CLMM liquidity', 'APY/TVL history', 'depth chart', yield farming, lending, staking, liquidity pools. PORTFOLIO triggers: 'check my DeFi positions', 'view DeFi holdings/portfolio', 'my staking/lending positions', 'DeFi balance', 'DeFi 持仓', '我的DeFi资产'. Do NOT use for: DEX swaps (okx-agentic-wallet), token prices (okx-dex-market), wallet token balances (okx-agentic-wallet).

references/portfolio-cli-reference.md

View on GitHub
# OKX DeFi — Portfolio CLI Command Reference

Parameter tables and return schemas for the position-viewing commands.

> `defi support-chains` / `defi support-platforms` and full flow examples live in `invest-cli-reference.md`.

## 1. onchainos defi positions

Get user DeFi holdings overview across protocols and chains.

```bash
onchainos defi positions --address <address> --chains <chains>
```

| Param | Required | Default | Description |
|---|---|---|---|
| `--address` | Yes | — | User wallet address |
| `--chains` | Yes | — | Comma-separated chain names (e.g. `"ethereum,bsc,solana"`) |

**Return fields** (per platform entry):

| Field | Type | Description |
|---|---|---|
| `analysisPlatformId` | String | Platform ID — used in `position-detail` and `claim --platform-id` |
| `platformName` | String | Protocol name (e.g. `"Aave V3"`) |
| `chainIndex` | String | Chain identifier |
| `totalValue` | String | Total position value in USD |
| `investedValue` | String | Originally invested value in USD |
| `profitValue` | String | Unrealized profit/loss in USD |
| `platformLogo` | String | Protocol logo URL |
| `investTypeList[]` | Array | Investment types active on this platform |
| `rewardDefiTokenInfo[]` | Array | Pending claimable rewards info |

---

## 2. onchainos defi position-detail

Get detailed DeFi holdings for a specific protocol.

```bash
onchainos defi position-detail \
  --address <address> \
  --chain <chain> \
  --platform-id <id>
```

| Param | Required | Default | Description |
|---|---|---|---|
| `--address` | Yes | — | User wallet address |
| `--chain` | Yes | — | Chain name |
| `--platform-id` | Yes | — | Protocol platform ID (`analysisPlatformId` from `positions` output) |

**Return fields** (per position entry):

| Field | Type | Description |
|---|---|---|
| `investmentId` | String | Product ID — used in `redeem`, `claim` |
| `investmentName` | String | Product name |
| `investType` | String | Position type (see investType reference below) |
| `coinAmount` | String | Current redeemable balance in token units |
| `coinUsdValue` | String | Current position value in USD |
| `tokenAddress` | String | Receipt/LP token address |
| `tokenSymbol` | String | Receipt/LP token symbol |
| `apy` | String | Current APY |
| `earnedTokenList[]` | Array | Pending reward tokens and amounts |
| `tokenId` | String | V3 Pool NFT tokenId (if applicable — use in `redeem --token-id`) |
| `tickLower` | String | V3 Pool lower tick (if applicable) |
| `tickUpper` | String | V3 Pool upper tick (if applicable) |
| `healthRate` | String | Lending health rate (LENDING type only) |

**investType values**:

| Value | Description |
|---|---|
| `1` | Save (savings / yield) |
| `2` | Pool (liquidity pool) |
| `3` | Farm (yield farming) |
| `4` | Vaults |
| `5` | Stake |
| `6` | Borrow |
| `7` | Staking |
| `8` | Locked |
| `9` | Deposit |
| `10` | Vesting |

---
reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis.Stars: 472kUpdated Claude CodeCodexVerifiedInstall
diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.Stars: 322kUpdated Claude CodeCodexVerifiedInstall
dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependenciesStars: 322kUpdated Claude CodeCodexVerifiedInstall
executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is availableStars: 322kUpdated Claude CodeCodexVerifiedInstall