okx avatar

Okx Cex Bot

This lets Claude create and manage OKX's native server-side trading bots without you needing to run anything locally. It handles both grid bots (spot and contract, including coin-margined) and DCA Martingale strategies across spot and futures markets. The skill enforces a two-step auth check before every command to distinguish between API key and OAuth modes, then applies the right flags for live versus demo trading. Notable that it never auto-transfers funds when balance is insufficient, instead it reports the shortfall and asks you to decide. Commands cover the full lifecycle: create with AI-suggested parameters, amend price ranges or take-profit levels on running bots, stop execution, and monitor P&L and individual fills.

skills.sh installs
10.2K
GitHub stars
200
last updated
Aug 21, 2026

Install

$ npx -y skills add okx/agent-skills --skill okx-cex-bot --agent claude-code

Installs into .claude/skills of the current project.

Files

OKX CEX Bot Trading

Grid, DCA (Spot & Contract Martingale), Smart Portfolio and Recurring Buy (定投) management on OKX. All bots are native OKX server-side — they run on OKX and do not require a local process.

Preflight

Before running any command, follow ../_shared/preflight.md. Use metadata.version from this file's frontmatter as the reference for Step 2.

Prerequisites

npm install -g @okx_ai/okx-trade-cli
okx config init   # select site -> follow browser OAuth flow

Security: NEVER accept credentials in chat. Guide users to okx config init for setup.

Credential & Profile Check

Run before every authenticated command. The auth method is detected during preflight Step 2 and remembered for the session.

Step A — Verify credentials

Run both commands — 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.

Sponsors

Details

Repository
github.com/okx/agent-skills
Categories
Backend & APIs, DevOps & CI/CD, AI & Agent Building, Finance & Trading

More from okx/agent-skills

All 11
1nomadamas avatarparking-lot-searchnomadamas/k-skillUse when the user asks for nearby parking lots or 근처 주차장/공영주차장. Always ask the user's current location first, then use official Data.go.kr public parking data t10.2Kskills.sh installs
2nomadamas avatarlibrary-book-searchnomadamas/k-skillUse when the user asks to search Korean library books, book details, library holdings, or whether a Korean public library owns a book via k-skill-proxy Data4Lib10.1Kskills.sh installs
3teng-lin avatarnotebooklmteng-lin/notebooklm-pyComplete API for Google NotebookLM - full programmatic access including features not in the web UI. Create notebooks, add sources, generate all artifact types, 10.1Kskills.sh installs
4anthropics avatarcode-reviewanthropics/knowledge-work-pluginsReview code changes for security, performance, and correctness. Trigger with a PR URL or diff, "review this before I merge", "is this code safe?", or when check10.1Kskills.sh installs
5nomadamas avatarlh-notice-searchnomadamas/k-skillSearch official LH 청약 (Korea Land & Housing Corporation lease/subscription) 공고 lists through k-skill-proxy. Use when a user asks about 청년/행복/영구/국민/매입/전세임대, 분양주택10.1Kskills.sh installs
6langchain-ai avatarmanaged-deep-agentslangchain-ai/langchain-skillsINVOKE THIS SKILL when building, testing, or deploying Managed Deep Agents in LangSmith with the mda CLI. Covers the code-first, file-based project layout; defi10Kskills.sh installs