okx-defi-invest

Discovers DeFi yield products and generates deposit, withdrawal, and reward-claim calldata across multiple chains.

Updated Apr 5, 2026
One-click install
npx skills add https://github.com/Nith567/xlayer-skills-arena --skill okx-defi-invest-nith567
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: okx-defi-invest
Source: https://github.com/Nith567/xlayer-skills-arena/tree/main/okx-defi-invest
Command: npx skills add https://github.com/Nith567/xlayer-skills-arena --skill okx-defi-invest-nith567

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Finding and executing DeFi investments across chains requires manually comparing APYs, converting token amounts to minimal units, and building multi-step transaction calldata for protocols like Aave, Lido, and Uniswap V3. ## Core Features & Use Cases - Product Discovery: Search and rank DeFi products by APY and TVL across Ethereum, BSC, Solana, and other chains, filtered by token, platform, or product group (SINGLE_EARN, DEX_POOL, LENDING). - One-Step Execution: Generate ordered calldata for deposits, withdrawals, and reward claims via defi invest, defi withdraw, and defi collect, with mandatory balance checks and fresh position-detail lookups. - Use Case: Ask to "earn yield on 100 USDC on Ethereum" and the skill resolves your wallet address, finds the top Aave product, verifies your balance, converts the amount to minimal units, and returns signable calldata. ## Quick Start Ask the agent to find the best USDC yield on Ethereum and deposit 100 USDC into the top Aave product.

Frequently Asked Questions about okx-defi-invest

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I deposit USDC into Aave using onchainos?▼

Search products with defi search --token USDC --chain ethereum, get details with defi detail, verify your wallet balance, then run defi invest with the investmentId, address, token, and amount in minimal units. Sign and broadcast the returned calldata steps in order.

How do I find the best DeFi APY for a token?▼

Run defi search with the token symbol and optional chain or platform filters, or defi list to see all products sorted by APY descending. Results include investmentId, rate as a decimal, and TVL for comparison.

Which chains and protocols does OKX DeFi invest support?▼

It supports EVM chains like Ethereum, BSC, Polygon, Arbitrum, Base, and XLayer, plus Solana, with protocols including Aave, Lido, Compound, PancakeSwap, Uniswap, NAVI, Kamino, and BENQI. Use defi support-chains and defi support-platforms for the live list.

Why must I call position-detail before every withdraw or claim?▼

Position data such as investmentId, coinAmount, and rewards changes after each on-chain operation, so stale data causes wrong parameters or failed transactions. The skill mandates a fresh defi position-detail call immediately before every defi withdraw or defi collect.

What amount format does defi invest require?▼

Amounts must be integers in minimal units, computed as userAmount times 10 to the power of the token's decimals. For example, 100 USDC with 6 decimals becomes 100000000. Get the token precision from defi detail or token search.

Can I use this skill for token swaps or price checks?▼

No. DEX spot swaps route to okx-dex-swap, token prices and market data route to okx-dex-market, and viewing balances or positions routes to okx-wallet-portfolio or okx-defi-portfolio. This skill only handles DeFi investment execution.