okx-defi

โดย okx

OKX-รวมศูนย์ DeFi (ไม่ระบุ DApp เฉพาะ) — การค้นหาผลิตภัณฑ์ การดำเนินการฝาก/ถอน/รับสิทธิ์ และการดูสถานะ **หากผู้ใช้ระบุโปรโตคอล/DApp ของบุคคลที่สาม (Aave, Lido, PancakeSwap, Uniswap, Curve, Compound, Morpho, Pendle, Kamino, Raydium, Hyperliquid, Polymarket, …) ให้เปลี่ยนเส้นทางไปที่ okx-dapp-discovery — ไม่ใช่ที่นี่ แม้แต่ 'แสดงสถานะ Aave ของฉัน'** ทริกเกอร์การลงทุน: 'ลงทุนใน DeFi', 'รับผลตอบแทน', 'หา APY ที่ดีที่สุด', 'ฝาก/วางเดิมพันเพื่อรับผลตอบแทน', 'ค้นหาผลิตภัณฑ์ DeFi',...

npx skills add https://github.com/okx/onchainos-skills --skill okx-defi

OKX DeFi (experimental merge of okx-defi-invest + okx-defi-portfolio)

Multi-chain, OKX-aggregated DeFi in two capabilities behind one skill. Both wrap the same onchainos defi CLI command group.

Pre-flight Checks

Read ../okx-agentic-wallet/_shared/preflight.md. If that file does not exist, read _shared/preflight.md instead.

Intent Routing

User IntentReference
Discover / search DeFi products, find best APYinvest.md
Product detail (APY, TVL, accepted tokens)invest.md
Deposit / stake / provide liquidityinvest.md
Withdraw / redeem a position (full or partial)invest.md
Claim rewards (platform / investment / V3 fee / bonus / unlocked principal)invest.md
APY history, TVL history, V3 depth / price chartsinvest.md
View DeFi positions / holdings overview (持仓)portfolio.md
Per-protocol position detail (持仓详情)portfolio.md
Exact parameters / return schemas — invest & charts commandsinvest-cli-reference.md
Exact parameters / return schemas — positions commandsportfolio-cli-reference.md
Errors / failed deposits / expired calldatainvest-troubleshooting.md
Errors / empty positions / address-format issuesportfolio-troubleshooting.md

Typical flow spans both: view positions (Portfolio) → redeem or claim (Invest). Read both reference files when the request chains them.

Skill Routing

  • For DApp-named investing/lending/staking/positions ("on Aave", "my Hyperliquid balance") → use okx-dapp-discovery
  • For token price/chart or token search by name/contract → use okx-dex-market
  • For DEX spot swap execution → use okx-agentic-wallet
  • For wallet token balances → use okx-agentic-wallet
  • For broadcasting signed transactions → use okx-agentic-wallet
  • For Agentic Wallet login, balance, contract-call → use okx-agentic-wallet

Chain Support

CLI resolves chain names automatically (e.g. ethereum1, bsc56, solana501). Full alias table: references/portfolio.md §Chain Support.

Step 0: Address Resolution (shared by both capabilities)

When the user does NOT provide a wallet address, resolve it automatically from the Agentic Wallet before running any defi command:

1. onchainos wallet status          → check if logged in, get active account
2. onchainos wallet addresses       → get addresses grouped by chain category:
                                       - XLayer addresses
                                       - EVM addresses (Ethereum, BSC, Polygon, etc.)
                                       - Solana addresses
3. Match address to target chain:
   - EVM chains → use EVM address
   - Solana     → use Solana address
   - XLayer     → use XLayer address

Rules:

  • If the user provides an explicit address, use it directly — skip this step
  • If wallet is not logged in, ask the user to log in first (→ okx-agentic-wallet) or provide an address manually
  • If the user says "check all accounts" or "all wallets", use wallet balance --all to get all account IDs, then wallet switch <id> + wallet addresses for each account
  • Always confirm the resolved address with the user before proceeding if the account has multiple addresses of the same type

Address-Chain Compatibility (shared — CRITICAL)

The --address and chain parameters must be compatible. EVM addresses (0x…) can only query EVM chains; Solana addresses (base58) can only query solana. Never mix them — the API will return error 84019 (Address format error).

  • 0x… address → only pass EVM chains: ethereum,bsc,polygon,arbitrum,base,xlayer,avalanche,optimism,fantom,linea,scroll,zksync
  • base58 address → only pass solana
  • Sui address → only pass sui; Tron address (T…) → only pass tron; TON address → only pass ton
  • If the user wants positions across both EVM and Solana, make two separate calls with the respective addresses

Global Notes

  • The wallet address parameter for ALL defi commands is --address
  • defi positions uses --chains (plural, comma-separated); defi position-detail uses --chain (singular)
  • For CLI parameter details, see references/invest-cli-reference.md (invest & charts) and references/portfolio-cli-reference.md (positions)

Skills เพิ่มเติมจาก okx

okx-agent-identity
okx
ERC-8004 บนเชน Agent identity บน XLayer: ลงทะเบียน / สร้าง / อัปเดต / เปิดใช้งาน / ปิดใช้งาน / ค้นหา agent; ดูคะแนน; รายการบริการ agent; ตั้งค่ารูป avatar. บทบาท: user (User / User Agent / Buyer / Client / 用户 / 买家 / 买方), asp
developmentapi
okx-ai-guide
okx
OKX.AI (ระบบเศรษฐกิจของ Agent) คำแนะนำเบื้องต้นและการเริ่มต้นใช้งาน ใช้เมื่อผู้ใช้ถามว่า OKX.AI คืออะไร ทำอะไรได้บ้าง วิธีใช้หรือเริ่มต้นใช้งาน ต้องการบทช่วยสอน / คำแนะนำด่วน / ความช่วยเหลือเกี่ยวกับ OKX.AI หรือพิมพ์ชื่อผลิตภัณฑ์ในรูปแบบการสะกด / การเว้นวรรค / ตัวพิมพ์ / ตัวพิมพ์ผิดใดๆ (OKXAI, okx ai, okx-ai, okx.ai ตัวพิมพ์เล็ก, ภาษาจีนที่พิมพ์ผิด เช่น 啥是okxai) — เช่น what is OKX.AI / OKX.AI 是什么 / 怎么用 OKX.AI / OKX.AI 快速开始 และการถอดความในภาษาใดๆ ตรวจจับแพลตฟอร์มรันไทม์ แนะนำ...
researchapidocument
okx-agentic-wallet
okx
แหล่งข้อมูลที่เชื่อถือได้สำหรับ OKX Agentic Wallet และฟีเจอร์ Gas Station Gas Station คือฟีเจอร์แก๊สด้วย stablecoin ของ OKX บน Solana ผ่าน Relayer ของบุคคลที่สาม รองรับเฉพาะ Solana ไม่มี EIP-7702 ต้องเรียกใช้สำหรับคำถามเกี่ยวกับ Gas Station (คืออะไร / ทำงานอย่างไร / โทเค็นที่รองรับ / ค่าธรรมเนียม / เปิดหรือปิด Gas Station / เปลี่ยนโทเค็นแก๊สเริ่มต้น / ความเข้ากันได้กับ Jito Bundler) และการดำเนินการใดๆ ในกระเป๋าเงิน: เข้าสู่ระบบ, ยืนยัน OTP, เพิ่ม/สลับ/สถานะ/ออกจากระบบบัญชี, ยอดคงเหลือ, สินทรัพย์, การถือครอง, ที่อยู่, ฝาก/รับ/เติมเงิน,...
apiweb-scrapingdevelopment
okx-agent-chat
okx
Routing stub — any a2a-agent-chat envelope / agent-task system message is handled by `okx-agent-task`. For missing or uninitialized OKX A2A communication runtime/plugin, read `skills/okx-agent-chat/ensure-okx-a2a-communication-ready.md`.
developmentapicommunication
okx-agent-task
okx
ต้องเปิดใช้งานบนซองจดหมายขาเข้า: (1) {agentId, message:{source:"system", event, jobId, ...}} — เหตุการณ์ระบบ; (2) {msgType:"a2a-agent-chat", jobId, sender:{role}, ...} — แชทงานระหว่างเอเจนต์ (ฟิลด์ที่ระดับบนสุด; sender.role = คู่สัญญา ไม่ใช่คุณ); (3) ข้อความ "Read okx-agent-task/SKILL.md" ในซองจดหมาย นอกจากนี้ยังต้องเปิดใช้งานสำหรับคำสำคัญ: 发布任务 / 创建任务 / 帮我发任务 / publish task / create task / 接任务 / 接单 / 协商 / 验收 / 拒绝 / 仲裁 / dispute / stake / unstake / 修改卖家 / 修改预算 / change provider / change budget...
developmentapicommunication
okx-agent-payments-protocol
okx
ใช้เมื่อเอเจนต์พบ HTTP 402 / payment-required หรือผู้ใช้กล่าวถึง x402, x402Version, X-PAYMENT, PAYMENT-REQUIRED, PAYMENT-SIGNATURE, WWW-Authenticate: Payment, permit2, upto, metered billing, ช่องทางการชำระเงิน / voucher / session, channelId / channel_id, การเปิด / ปิด / เติมเงิน / ชำระบัญชี / คืนเงินช่องทาง, paymentId หรือลิงก์ a2a_, การสร้าง / ตรวจสอบลิงก์ชำระเงิน, A2MCP / ปลายทาง A2MCP, หรือการส่งคำขอ / เรียกปลายทางของเอเจนต์พร้อมปลายทางที่เป็นรูปธรรม...
okx-security
okx
We need to translate the given text from English to Thai. The text describes a skill for security scanning. We must preserve the name "okx-security" but it's not in the text, so we don't include it. We translate the entire text inside <text> tags. No extra commentary, no labels. Just the translation. The text: "Use this skill for security scanning: check transaction safety, is this transaction safe, pre-execution check, security scan, token risk scanning, honeypot detection, DApp/URL phishing detection, message signature safety, malicious transaction detection, approval safety checks, token approval management. Triggers: 'is this token safe', 'check token security', 'honeypot check', 'scan this tx', 'scan this swap tx', 'tx risk check', 'is this URL a scam', 'check if this dapp is safe', 'phishing..." Translate to Thai. Keep technical terms like "honeypot", "DApp", "URL", "tx" (transaction), "swap", "phishing" as
okx-task-watch
okx
We need to translate the given text from English to Thai, preserving the name "okx-task-watch" and other technical terms like "okx-a2a user watch", "okx-a2a user outdated-list", etc. The text includes a mix of Thai and English phrases already. The instruction says to translate only the text inside <text>, and not to include the name unless it appears in the source text. The name "okx-task-watch" is not in the source text, so we don't include it. The source text has some Thai phrases already: "监听任务进展 / 帮我盯着任务 / 任务有动静告诉我 / 历史消息 / 未读消息 / 未决策 / 待决策 / 继续监听" - these are Chinese, not Thai. The target language is Thai, so we need to translate the entire text into Thai, including those Chinese phrases. Also the English parts. We must preserve product names, protocol names, URLs, numbers, technical terms. So "okx-a2a user watch", "okx-a
developmentapiproductivity