okx-plugin
AGENTS.md1 starsChanged 9 months agoApache-2.0View on GitHub
This is a skill collection providing 13 skills covering the complete OKX V5 REST API: trading account, order management, market data, public data, funding, trading bots, copy trading, block trading, spread trading, analytics, financial products, sub-accounts, and system status. Each skill in skills/ contains a SKILL.md with:
- Reads credentials
- Installs packages
Where files are headingNew AGENTS.md files have more rules about keeping secrets out of the code, and fewer about code style.
Of the AGENTS.md files we read, the 35,266 first seen in the last six months, against the older ones: the kind of rule that gained most share, and the kind that lost most. About files like this in general, not this one, and an estimate, since a kind is a pattern in the words.
In this repository2 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- .github/copilot-instructions.mdCopilot instructions
The file
We split this AGENTS.md into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 55
All CLI option names match the OKX V5 API parameter names exactly (e.g.
≈ “Common” is an estimate: at least 1 in 5 of the 45,344 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
OKX V5 API Skills — Agent Instructions
This is a skill collection providing 13 skills covering the complete OKX V5 REST API: trading account, order management, market data, public data, funding, trading bots, copy trading, block trading, spread trading, analytics, financial products, sub-accounts, and system status.
Available Skills
| Skill | Purpose | When to Use |
| okx-account | Trading account management | User asks about balance, positions, leverage, margin, risk, bills, account config; user says "how much USDT do I have", "show my positions", "set leverage to 10x", "what's my margin ratio" |
| okx-trade | Order placement & management | User wants to place/cancel/amend orders, batch orders, algo orders (TP/SL, trigger, trailing stop, TWAP), view fills; user says "buy 0.1 BTC", "cancel my open orders", "set a stop loss at 55000", "place a TWAP order" |
| okx-market | Market data | User asks for prices, tickers, order book, candles/K-line, trades, index data, exchange rate; user says "what's the BTC price", "show me ETH 1h candles", "how deep is the order book", "what's the 24h volume" |
| okx-public | Public reference data | User needs instrument info, funding rates, open interest, mark price, position tiers, system time; user says "what instruments are available", "what's the funding rate for BTC-USDT-SWAP", "show open interest", "is the exchange open" |
| okx-asset | Funding account | User wants to check funding balance, transfer funds, deposit/withdraw, flash swap; user says "check my funding balance", "transfer 1000 USDT to trading", "get my deposit address", "withdraw ETH" |
| okx-trading-bot | Automated strategies | User wants grid trading (spot/contract), signal trading, or recurring buy (DCA); user says "create a grid bot for BTC", "what grid parameters does AI recommend", "set up a DCA strategy", "check my running bots" |
| okx-copy-trading | Copy trading | User wants to follow/lead traders, view copy settings, profit sharing, public stats; user says "show top traders", "follow this trader", "check my copy trading positions", "what's the profit sharing ratio" |
| okx-rubik | Trading analytics | User wants big data: OI history, long/short ratios, taker volume, margin ratios; user says "what's the long/short ratio for BTC", "show taker buy/sell volume", "how has open interest changed", "is the market overleveraged" |
| okx-rfq | Block trading (RFQ) | User wants to create/execute block trades, manage RFQs and quotes; user says "create an RFQ", "get quotes for a block trade", "who are my counterparties" |
| okx-spread | Spread trading | User wants to trade spreads, view spread instruments and order book; user says "place a spread order", "what spread instruments are available", "show spread order book" |
| okx-finance | Financial products | User wants staking (ETH/SOL/DeFi), savings/earn, flexible loans; user says "stake my ETH", "what staking offers are available", "how much interest can I earn", "take out a loan" |
| okx-subaccount | Sub-account management | User needs to manage sub-accounts, API keys, permissions, transfers; user says "create a sub-account", "list my sub-accounts", "transfer funds to sub-account", "manage sub-account API keys" |
| okx-system | System status | User wants to check system status, maintenance schedule, announcements; user says "is OKX down", "any maintenance planned", "check system status" |
Architecture
- cli/ — Node.js CLI binary (
okx), built withcommander; source incli/src/, config incli/package.json - skills/ — 13 skill definitions (each is a
SKILL.mdwith YAML frontmatter + CLI command reference) - cli/src/commands/ — One module per API domain (account, trade, market, public, asset, etc.)
- cli/src/utils/ — Shared utilities (auth/signing, HTTP client, config)
Skill Discovery
Each skill in skills/ contains a SKILL.md with:
- YAML frontmatter (name, description, metadata)
- Full CLI command reference with parameters and types
- Usage examples (bash)
- Cross-skill workflow documentation
- Error handling notes
Setup
npm install -g okx-trader-cliThen create a .env file in the project root:
OKX_API_KEY=your-api-key
OKX_SECRET_KEY=your-secret-key
OKX_PASSPHRASE=your-passphraseCLI Parameter Convention
All CLI option names match the OKX V5 API parameter names exactly (e.g. --instId, --tdMode, --ordType). Refer to each skill's SKILL.md for the full parameter list.
Common Workflows
Check Balance → Place Order → Monitor:
okx-account (balance) → okx-trade (place order) → okx-trade (get-order) → okx-account (positions)
Market Research → Trade:
okx-market (ticker/candles) → okx-public (funding-rate) → okx-rubik (long-short ratio) → okx-trade (order)
Grid Bot Setup:
okx-market (candles for range) → okx-trading-bot (grid ai-param) → okx-trading-bot (grid order-algo) → okx-trading-bot (grid orders-pending)
Fund Management:
okx-asset (balances) → okx-asset (transfer between accounts) → okx-account (verify balance)
Portfolio Review:
okx-account (balance + positions) → okx-market (current prices) → okx-account (bills for P&L history)
Algo Strategy:
okx-market (analyze trend) → okx-trade (algo-order with TP/SL) → okx-trade (orders-algo-pending to monitor)
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

