# OKX API

> OKX's V5 API covers spot, margin, perpetual, futures and options trading, account and market data over REST and WebSocket, with demo trading on the same host and an open-source Agent Trade Kit whose okx-trade-mcp package is a local MCP server.

- Canonical: https://www.anchorterminal.com/tools/okx
- Pricing: https://www.anchorterminal.com/tools/okx#pricing
- Reviews: https://www.anchorterminal.com/tools/okx#reviews
- Markdown: https://www.anchorterminal.com/tools/okx.md (~8,850 tokens)
- Slim: https://www.anchorterminal.com/tools/okx.min.md (~2,280 tokens, same facts, less prose, for token-sensitive contexts)
- JSON: https://www.anchorterminal.com/tools/okx.json (this page as data, same URL with Accept: application/json)
- Site index for agents: https://www.anchorterminal.com/llms.txt (the key docs and every listing in one file, at most 16 MB, about 4 million tokens: https://www.anchorterminal.com/llms-full.txt)
- API: https://www.anchorterminal.com/api/v1/index.json
- MCP: https://www.anchorterminal.com/mcp (the whole catalogue as tools, no key)
- DNS: dig +short TXT okx.grade.anchorterminal.com (the grade as a DNS TXT record, for a sandbox with no HTTP where names still resolve; also top., best.<category>. and <a>.vs.<b>. under the zone, and the same under grade.letme.dev)
- Licence: CC BY 4.0, credit Anchor Terminal and link this page (https://www.anchorterminal.com/terms/#data)
- Updated: 2026-11-04

## Overview

**Grade B · 64.3/100 · rank #413 of 1349 · #4 in Crypto exchanges · not agent-ready · confidence medium**


## Assessment

OKX publishes per-endpoint rate limits, Read, Trade and Withdraw key permissions with IP binding, demo trading on the production host, and an MIT MCP server with 170 tools, a read-only flag and a permission check at startup. The fee table and privacy policy were not read, no OpenAPI file was found, and the news tools return third-party text.

## Facts

| Field | Value |
| --- | --- |
| Vendor | OKX (https://www.okx.com/docs-v5/en/) |
| Kind | HTTP API |
| Category | Crypto exchanges (https://www.anchorterminal.com/categories/crypto-exchanges) |
| Transport | stdio |
| Auth | API key · API key, secret and passphrase made at okx.com/account/my-api, with HMAC-SHA256 signatures over a timestamp and the request. Permissions are Read, Trade and Withdraw, singly or combined; each key binds up to 20 IP addresses or ranges, and a Trade or Withdraw key with no IP binding expires after 14 days without use. Demo trading uses the same host with the header `x-simulated-trading` set to 1 and keys that do not expire. US and Australian users call us.okx.com and EEA users eea.okx.com. The MCP server reads the key from ~/.okx/config.toml, checks its permissions at startup and hides order tools when the key cannot trade (https://www.okx.com/docs-v5/en/, https://www.okx.com/docs-v5/agent_en/, checked 2026-11-03). |
| Pricing | Pay per use (Pay per use) · The API costs nothing to call. Trades carry maker and taker fees by regular and VIP level; the fee page at okx.com/fees loads its table by script and the fee FAQ says the rates that apply are the ones shown while logged in, so the lowest tier's rates are unread. Public market data and demo trading need no funded account. |
| x402 | No · No x402, MPP or L402 in the V5 docs, the API agreement or the Agent Trade Kit (checked 2026-11-03). |
| Licence | Proprietary hosted service under OKX's Terms of Service (29 October 2026) and API Agreement (28 July 2026). The Agent Trade Kit (MCP server, CLI and skills) is MIT |
| Tools exposed | 170 |
| Packages | npm: `@okx_ai/okx-trade-mcp`; npm: `@okx_ai/okx-trade-cli`; pypi: `python-okx` |
| Source | https://github.com/okx/agent-trade-kit |
| Docs | https://www.okx.com/docs-v5/en/ |
| llms.txt | https://www.okx.com/llms.txt |
| Last release | 2026-10-28 |
| GitHub stars | 499 (as of 2026-11-03) |
| npm downloads / week | 1,839 |
| Surface listed | The V5 REST API at openapi.okx.com/api/v5 and its WebSocket channels at ws.okx.com, read from okx.com/docs-v5, the help centre, okx.com/status and a shallow clone of okx/agent-trade-kit on 3 November 2026. No account was made, no key was used and no MCP session was opened |
| MCP server | Official, local. okx-trade-mcp (stdio) in okx/agent-trade-kit, npm @okx_ai/okx-trade-mcp v1.5.0 of 28 October 2026, 170 tools in 11 modules per the README (market 19, spot 13, swap 17, futures 18, option 10, account 14, event 9, earn 24, bot 18, news 7, smartmoney 10), default modules spot, swap and account, --read-only, --modules and a demo profile. Keys stay in ~/.okx/config.toml. Not in the official MCP registry. Skills for OpenClaw in okx/agent-skills |
| Key permissions | Read, Trade and Withdraw, in any combination; up to 20 IP addresses or ranges per key; Trade or Withdraw keys without an IP binding expire after 14 days without use. No withdrawal address allow-list was found in the API docs read |
| Rate limits | Per endpoint and per User ID for private REST (sub-accounts count separately); Place order 60 per 2 seconds per instrument, lead-trader instruments 4 per 2 seconds; Get balance 10 per 2 seconds; 3 amendments in flight per order; 1,000 order requests per 2 seconds per sub-account, higher by fill ratio from VIP5; WebSocket 3 connections a second per IP, 480 subscribe, unsubscribe and login requests an hour per connection, 30 connections per channel per sub-account. Error 50011 on a limit |
| Sandbox | Demo trading on the production REST host and wspap.okx.com WebSocket hosts with the header `x-simulated-trading` set to 1 and demo keys that do not expire; withdraw, deposit and purchase or redemption are unsupported there |
| Countries | Restricted per the Risk and Compliance Disclosure of 8 July 2026 are Afghanistan, Canada, Cuba, Hong Kong, Iran, India, Japan, Malaysia, Nepal, North Korea, Syria, Crimea, Donetsk and Luhansk, Uzbekistan and certain US jurisdictions including all US territories; services are limited in Australia, the Bahamas, Brazil, Eritrea, Russia, South Korea and the United Kingdom. Regional entities serve the EEA (eea.okx.com), the US and Australia (us.okx.com) |
| Fees | Not read. okx.com/fees loads its table by script and the fee FAQ (updated 9 September 2026) says the applicable rates are the ones shown while logged in |
| FIX and WebSocket | No FIX API in the V5 docs read. WebSocket public, private and business channels at ws.okx.com (demo at wspap.okx.com), with a 30-second idle disconnect and port 8443 retiring on 31 October and 16 November 2026 |
| Terms on automated trading | The Terms of Service (29 October 2026) say API use may be subject to order rate limits and repeated violations may suspend the account. The API Agreement (28 July 2026) covers the Agent Trade Kit, bars wash trading, layering, spoofing, quote stuffing and momentum ignition by an agent, bars circumventing rate limits, requires minimum key scope, makes the user responsible for keys and AI-submitted orders, and says use cases a third-party AI provider's terms restrict, including fully automated trading without human oversight, must not run through the API |
| SDKs | python-okx on PyPI (the only SDK named in the docs), the okx-trade-cli, and a market-maker sample at okxapi/okx-sample-market-maker |
| Status | okx.com/status with issue descriptions, maintenance notices and per-asset deposit and withdrawal status, no component history; nothing listed for August to November 2026 |
| Legal entity | Aux Cayes FinTech Co. Ltd. (Seychelles) for most users, with OKX Europe Limited, OKX Inc., OKX Australia, OKX Dubai, OKX Brazil, OKX Singapore and OKX El Salvador for their regions, per the terms |
| Capabilities | exchange.spot-trading, exchange.market-data, exchange.derivatives, exchange.balances, exchange.transfers, exchange.staking, market.crypto |
| Tags | hosted, official, closed-source, api-key, mcp, cli, llms-txt, sandbox, typescript, python, usage-priced, no-card, mit |
| JSON | https://www.anchorterminal.com/api/v1/tools/okx.json |

## Score breakdown (methodology v0.7, October 2026 research run)

Assessed 2026-11-03 from public evidence against the published checklist (https://www.anchorterminal.com/benchmark/#checklist). Confidence: medium. Performance and Task success pending (no score, not in the total); the total is Σ(score × weight) ÷ 80 over the 7 assessed categories. "This run" is each category's share of the 100 points.

| Category | Weight | This run | Score (0–100) | Points |
| --- | --- | --- | --- | --- |
| Reliability | 16% | 20 | 65 | 13.0 |
| Performance | 10% | pending | pending | n/a |
| Schema & documentation | 13% | 16.2 | 73 | 11.9 |
| Agent ergonomics | 13% | 16.2 | 77 | 12.5 |
| Security & auth | 14% | 17.5 | 68 | 11.9 |
| Payments & pricing | 10% | 12.5 | 20 | 2.5 |
| Task success | 10% | pending | pending | n/a |
| Maintenance & community | 7% | 8.8 | 81 | 7.1 |
| Transparency & trust (editorial 38, provenance 85) | 7% | 8.8 | 62 | 5.4 |
| Negative events | up to −15 | up to −15 | none recorded | 0 |
| **Total** | | | | **64.3 → B** |

### Why each score

- Reliability 65 (checked 2026-11-03): Read with the hosted lines on the V5 REST API. okx.com/status is OKX's own page with issue descriptions, maintenance notices and deposit and withdrawal status, but no component history or feed (10 of 20). It lists no incident between 5 August and 3 November 2026; its newest entry is from March 2024, and whether every incident reaches the page cannot be told, so read as clean with a doubt (20 of 30). Rate limits per endpoint, per User ID and per sub-account with numbers, and WebSocket limits (15). Error 50011 on a limit, a clOrdId on orders and a cap of 3 amendments in flight, but no Retry-After or backoff guidance found (10 of 15). No SLA (0). Generally available (10). 10 + 20 + 15 + 10 + 0 + 10 = 65.
- Performance: Pending. Latency is measured per call by our probes, which haven't run yet, so this run doesn't score it. Its weight is shared across the assessed categories until the first probe window closes.
- Schema & documentation 73 (checked 2026-11-03): No OpenAPI file was found in the V5 docs; the kit's tool definitions are typed TypeScript with annotations, and the organisation has an undescribed ai-builder-openapi-md repository we did not read (12 of 25). okx.com/llms.txt exists and links the API and Agent Trade Kit pages, though the V5 docs have no Markdown twins (5 of 10). Each endpoint states its rate limit, rule, parameters and notes (15 of 20). Enums for ordType, tdMode and instType with required flags (12 of 15). Request and response examples per endpoint and an error code list with messages (14 of 15). A dated changelog with an upcoming-changes section that labels breaking changes and dates sunsets (15). 12 + 5 + 15 + 12 + 14 + 15 = 73.
- Agent ergonomics 77 (checked 2026-11-03): limit parameters on books, candles and history, and in the kit --modules and --read-only narrow 170 tools to the three default modules; no field selection (17 of 25). after, before and limit cursors on history endpoints (18 of 20). Numeric codes with messages, such as 51020 for an invalid quantity, and the kit returns a structured error block with code, message and endpoint (17 of 20). clOrdId on orders, batch endpoints and a cap of 3 amendments in flight; the kit sets readOnlyHint on query tools but destructiveHint false on order tools and has no idempotency key (13 of 20). python-okx, the CLI and a demo profile, with passphrase and HMAC signing on every private call (12 of 15). 17 + 18 + 17 + 13 + 12 = 77.
- Security & auth 68 (checked 2026-11-03): Key, secret and passphrase with Read, Trade and Withdraw permissions, up to 20 bound IPs, revocation in the account, and unbound Trade or Withdraw keys that expire after 14 idle days; no OAuth (28 of 30). Read-only keys, sub-account keys, demo trading, the kit's --read-only flag and its startup check that hides order tools when the key cannot trade, and an API Agreement requiring minimum scope; no confirmation step in the kit (18 of 20). The news and smartmoney modules return third-party text and the docs read give no guidance on treating it as untrusted (5 of 15). An account audit log tool in the kit and usage records for unbound keys in the Security Center, no per-call log (9 of 15). No security.txt; SECURITY.md with security@okx.com and GitHub private advisories; certifications and a bounty not read (8 of 20). 28 + 18 + 5 + 9 + 8 = 68.
- Payments & pricing 20 (checked 2026-11-03): No machine payment protocol (0). The fee table loads by script and the fee FAQ defers to the logged-in view, so no rate was read (0 of 20, unchecked). Public market data and demo trading need no funded account or card (20). A person signs up, verifies and mints a key (0). 0 + 0 + 20 + 0 = 20.
- Task success: Pending. Task success needs the category task suites run through each tool, which haven't run yet, so this run doesn't score it. Its weight is shared across the assessed categories until then. A data provider's data-quality score is published on its listing now and becomes half of this category when it's scored.
- Maintenance & community 81 (checked 2026-11-03): Read as a closed service with an open-source kit. Changelog entry of 27 October 2026 and kit v1.5.0 on 28 October (30). Changelog entries on 3, 6, 11, 18, 20 and 26 August, 15, 29 and 30 September and 27 October, and kit releases on 20 and 21 August, 1, 7, 14 and 23 September, 19 and 28 October (20). A public changelog, a Telegram community for the kit and GitHub issues whose replies were not read (10 of 15). python-okx is named as the official SDK and the kit is current; the MCP server is not in the official registry (12 of 15). The kit runs CI on push and pull request across Node 18, 20 and 26 with unit tests and coverage (9 of 10). 30 + 20 + 10 + 12 + 9 = 81.
- Transparency & trust 62 (checked 2026-11-03): The editorial half. A closed service with terms that name the contracting entities by region and an API Agreement for agents; the kit is MIT (17 of 30). The privacy policy was not read (5 of 30). The changelog dates sunsets and labels breaking changes, such as port 8443 on 31 October and 16 November 2026 (16 of 20). No subprocessor or data-location statement read; the MCP server is local and its npm package runs a postinstall script whose purpose we did not trace (0 of 20). 17 + 5 + 16 + 0 = 38.

Fix list, everything this grade says the listing lacks, the biggest gain first (19 items). What it covers is at https://www.anchorterminal.com/fixes/okx.md (JSON https://www.anchorterminal.com/fixes/okx.json). The whole list for a coding agent comes from `POST https://www.anchorterminal.com/api/v1/fix-list` with `{"listing": "okx", "plan": "read"}`, free while the beta runs

### What we couldn't check

- Kind http-api, not mcp. The kit is a local route built on the V5 API; the REST and WebSocket docs carry the limits, demo trading and terms.
- unchecked: the fee schedule (script-loaded), the privacy policy, the governing-law clause of the terms (past the part read), the ai-builder-openapi-md repository, python-okx's release date, GitHub issue replies and the kit's postinstall script.
- unchecked: the live tool list as served. The count of 170 is the README's; a grep of the tool sources found between 157 and 223 name fields depending on the pattern.
- Judgement call on the incident record. The status page shows no incident since March 2024 and no component history, so 20 of 30 rather than 30 for a clean Statuspage record or 5 for no history.
- firstReleased is 10 June 2022, the oldest changelog entry we could read; the page is longer than our reader covered and the V5 API predates it.
- The changelog's 18 August and 15 September 2026 entries give different RPI minimum notional thresholds without saying which applies. Recorded, not deducted.
- The API Agreement bars running use cases a third-party AI provider's terms restrict, naming fully automated trading without human oversight as an example, through the API. Recorded as a fact for agents, not deducted.
- Humans. okx.com/about names nobody; the founder and president come from Wikipedia and a conference biography, and the 2026 funding reports are Wikipedia's citations of Reuters and Bloomberg, not read first-hand.

### Sources

- robots.txt: <https://www.okx.com/robots.txt> (seen 2026-11-03)
- V5 API docs (overview, keys, demo, rate limits, WebSocket, Place order): <https://www.okx.com/docs-v5/en/> (seen 2026-11-03)
- Agent page (Agent Trade Kit): <https://www.okx.com/docs-v5/agent_en/> (seen 2026-11-03)
- API changelog: <https://www.okx.com/docs-v5/log_en/> (seen 2026-11-03)
- agent-trade-kit repository, shallow clone (README, CHANGELOG, server source, CI, SECURITY.md): <https://github.com/okx/agent-trade-kit> (seen 2026-11-03)
- npm @okx_ai/okx-trade-mcp latest: <https://registry.npmjs.org/@okx_ai%2fokx-trade-mcp/latest> (seen 2026-11-03)
- npm weekly downloads: <https://api.npmjs.org/downloads/point/last-week/@okx_ai/okx-trade-mcp> (seen 2026-11-03)
- GitHub organisation repositories: <https://api.github.com/orgs/okx/repos?per_page=100&sort=updated> (seen 2026-11-03)
- API Agreement (28 July 2026): <https://www.okx.com/help/okx-api-agreement> (seen 2026-11-03)
- Terms of Service (29 October 2026): <https://www.okx.com/help/terms-of-service> (seen 2026-11-03)
- Risk and Compliance Disclosure (restricted locations): <https://www.okx.com/help/risk-compliance-disclosure> (seen 2026-11-03)
- trading fee rules FAQ: <https://www.okx.com/help/trading-fee-rules-faq> (seen 2026-11-03)
- fee page (table loads by script): <https://www.okx.com/fees> (seen 2026-11-03)
- status page: <https://www.okx.com/en-us/status> (seen 2026-11-03)
- llms.txt: <https://www.okx.com/llms.txt> (seen 2026-11-03)
- about page: <https://www.okx.com/about> (seen 2026-11-03)
- security.txt (404): <https://www.okx.com/.well-known/security.txt> (seen 2026-11-03)
- official MCP registry search: <https://registry.modelcontextprotocol.io/v0/servers?search=okx> (seen 2026-11-03)
- RDAP for okx.com: <https://rdap.verisign.com/com/v1/domain/okx.com> (seen 2026-11-03)

## Score history

Every move of a score since the listing was graded, newest first, with its cause. A score can't move without an entry here. JSON: https://www.anchorterminal.com/api/v1/tools/okx/history.json

- 2026-11-03: graded 64.3 B (methodology 0.7)

## Who's behind it (provenance 85/100, checked 2026-11-03)

| Check | Finding | Points |
| --- | --- | --- |
| Legal entity named | Aux Cayes FinTech Co. Ltd. | 20/20 |
| Domain age | okx.com, registered 2001-07-03 (25 years) | 15/15 |
| Endpoint on the vendor's domain | okx.com | 15/15 |
| Terms of service | read, states 6 of the 7 things a reader expects, and has 1 clause that costs points | 7.1/10 |
| Privacy policy | published, but our reader couldn't read it | 7/10 |
| Status page | www.okx.com/status | 10/10 |
| Changelog | published | 10/10 |
| security.txt | not found | 0/10 |
| People named | 1 named with their role, none with a public profile | 7/10 |
| Support route | help pages, a community | 5/5 |

The Terms of Service (last updated 29 October 2026) name Aux Cayes FinTech Co. Ltd. for all users not served by a regional OKX entity; the page metadata of the API Agreement also lists it as publisher. The governing-law clause sat past the part of the page we read. The privacy policy URL is OKX's help-centre page and was not read.

RDAP gives okx.com a registration date of 3 July 2001, long before OKX took the name in 2022.

https://www.okx.com/.well-known/security.txt answers 404; the Agent Trade Kit's SECURITY.md names security@okx.com.

www.okx.com/robots.txt allows the docs, help and status pages read and /llms.txt, and disallows account, KYC and other private paths.

okx.com/status is OKX's own page with issue descriptions and maintenance notices in UTC+8, no component history and no feed found.

### Terms and privacy, as read

A reading by a fixed set of rules, each answered with the vendor's own sentence. Not legal advice.

**Terms of service** (https://www.okx.com/help/terms-of-service), read 2026-11-03, dated 2026-10-29, states 6 of the 7 things a reader expects.

- To know. Says the terms or the service can change without notice (costs points). "11.1 Service Change and Interruption: we may change the Services and/or may also interrupt, suspend or terminate the Services at any time with or without prior notice."
- To know. Says access can be ended without notice or for any reason. "Further, in the event that users decline to provide the requested information, or otherwise do not comply in a timely manner, we may, without notice, suspend or terminate your access to your Account, or to all or part of the Services immediately."
- To know. Requires arbitration or waives class actions. "20.4 Waiver of Jury Trial: YOU AND OKX AGREE TO WAIVE ANY RIGHT TO SUE IN COURT AND HAVE A TRIAL IN FRONT OF A JUDGE OR JURY."
- Gives the date it was last updated. Last updated 2026-10-29.
- Says how changes to the terms are announced. Gives 30 days of notice before a change.
- Not found in the text. Refers to a service level or uptime commitment.
- Also in the text (2026-11-03). Instructions sent through the API or any electronic channel are acted on as the customer's own without any duty to verify their source. "OKX is entitled and authorised to act upon and give effect to such Electronic Communication as if it were a valid and duly authorised instruction from you, without any obligation to verify the authenticity or source of such communication."
- Also in the text (2026-11-03). Commercial use of the platform or services needs OKX's explicit authorisation. "9.4 You may not use the OKX Platform or the Services for any commercial purpose unless otherwise explicitly authorized by OKX."
- Also in the text (2026-11-03). API use falls under a separate OKX API Agreement that these terms incorporate by reference. "For the API Services, please refer to the OKX API Agreement."

**Privacy policy** (https://www.okx.com/help/privacy-policy), read 2026-11-03. Our reader couldn't read it (the page answered HTTP 404 to our reader).


## Humans behind the project (researched 2026-11-03 from public pages, not part of the grade)

### Key people

- Star Xu, Founder and CEO, OKX
- Note: okx.com/about names nobody and the terms name only the contracting entities, so the founder comes from Wikipedia's OKX and Star Xu articles. Hong Fang is described as OKX's president in a Consensus Hong Kong 2025 speaker biography found by search, which is not a first-hand OKX page, so she is not listed. Investors were looked for on okx.com and in two searches. Wikipedia's OKX article says Intercontinental Exchange invested in March 2026 at a $25 billion valuation, citing Reuters, and that an October 2026 round at the same valuation included Ripple Labs, Circle Internet Group, SC Ventures and QRT, citing Bloomberg; neither report was read first-hand, so they are not listed as investors and the valuation is left out. The status is private per Wikipedia.
- OKX: X https://x.com/okx GitHub https://github.com/okx

### Getting support

- Help: https://www.okx.com/help
- Help: https://www.okx.com/docs-v5/en/
- Community (Agent Trade Kit issues): https://github.com/okx/agent-trade-kit/issues
- Community (OKX AgentKit Telegram): https://t.me/OKX_AgentKit
- General contact: security@okx.com
- Sources: https://www.okx.com/about, https://www.okx.com/help/terms-of-service, https://www.okx.com/docs-v5/agent_en/, https://github.com/okx/agent-trade-kit/blob/main/SECURITY.md, https://en.wikipedia.org/wiki/OKX, https://en.wikipedia.org/wiki/Star_Xu

## Live (updated 2026-11-04 15:53 UTC)

- Vendor status page: unknown, no machine-readable status found
- security.txt: none
- Always current: https://www.anchorterminal.com/api/v1/live/okx.json

## Probe metrics

Not measured yet. Our benchmark probes haven't run, so there's no availability, latency or error rate from a run and Performance is pending. Live uptime, where we poll the endpoint, is under Live and doesn't change the score.

## Strengths

- Official local MCP server, MIT, with modules, --read-only, a demo profile, readOnlyHint annotations and a startup check that hides order tools when the key cannot trade
- Keys limited to Read, Trade or Withdraw, bound to up to 20 IPs, with unbound Trade and Withdraw keys expiring after 14 idle days
- Rate limits published per endpoint and per User ID, with sub-account and WebSocket limits in numbers
- Demo trading on the production hosts with one header, keys that do not expire, and a demo profile in the kit
- An API Agreement written for agents, naming prohibited tactics, minimum key scope and rate-limit circumvention

## Weaknesses

- The fee table loads by script and the fee FAQ defers to the logged-in view, so maker and taker rates were not read
- No OpenAPI file was found in the docs; the machine-readable contract is the kit's tool definitions
- The status page lists incidents without component history, and its newest entry is from March 2024
- The news and smart money tools return third-party text with no documented guidance on treating it as untrusted
- Trade tools in the kit carry destructiveHint false, and the npm package runs a postinstall script



## Before you call it (notes for agents)

1. Start okx-trade-mcp with --profile demo first, then --read-only on a live key; load only the modules the task needs
2. Use a sub-account key with Read and Trade only, bound to the agent's IP; an unbound Trade key expires after 14 idle days
3. Stay under 60 place-order requests per 2 seconds per instrument and at most 3 amendments in flight per order; 50011 means the limit was hit
4. Send a clOrdId on every order and use the structured error block (code, message, endpoint) to diagnose with read-only tools before retrying
5. Call us.okx.com or eea.okx.com for US, Australian and EEA accounts; openapi.okx.com does not serve those regions

## Connect

Install:

```bash
npm install -g @okx_ai/okx-trade-mcp @okx_ai/okx-trade-cli
```

First request:

```bash
curl https://www.okx.com/api/v5/market/ticker?instId=BTC-USDT
```

MCP client configuration:

```json
{
  "mcpServers": {
    "okx-demo": {
      "args": [
        "-y",
        "@okx_ai/okx-trade-mcp",
        "--profile",
        "demo"
      ],
      "command": "npx"
    }
  }
}
```

Through letme: https://letme.dev/okx. letme answers with the pick and how to call it direct. How it works: https://www.anchorterminal.com/letme/index.md

## Similar tools

Ranked by shared capabilities, then score. Same-category tools with no shared capability key are listed last.

| Tool | Grade | Score | Rank | Shared capabilities | x402 | Markdown |
| --- | --- | --- | --- | --- | --- | --- |
| Gemini Exchange API | BB | 74.6 | 70 | exchange.market-data, exchange.spot-trading, exchange.derivatives, exchange.balances, exchange.transfers, exchange.staking, market.crypto | no | https://www.anchorterminal.com/tools/gemini-exchange.md |
| Kraken API | BB | 71 | 159 | exchange.spot-trading, exchange.market-data, exchange.derivatives, exchange.balances, exchange.transfers, exchange.staking, market.crypto | no | https://www.anchorterminal.com/tools/kraken.md |
| Binance API | B | 63.2 | 448 | exchange.spot-trading, exchange.market-data, exchange.derivatives, exchange.balances, exchange.transfers, exchange.staking, market.crypto | no | https://www.anchorterminal.com/tools/binance.md |
| Bitfinex API | C | 58.4 | 687 | exchange.market-data, exchange.spot-trading, exchange.derivatives, exchange.balances, exchange.transfers, exchange.staking, market.crypto | no | https://www.anchorterminal.com/tools/bitfinex.md |
| Bybit | C | 57.3 | 745 | exchange.market-data, exchange.spot-trading, exchange.derivatives, exchange.balances, exchange.transfers, exchange.staking, market.crypto | no | https://www.anchorterminal.com/tools/bybit.md |
| Gate | C | 56.4 | 786 | exchange.market-data, exchange.spot-trading, exchange.derivatives, exchange.balances, exchange.transfers, exchange.staking, market.crypto | no | https://www.anchorterminal.com/tools/gate-io.md |

## Panel reviews (0)

Reviewed by the Anchor panel (https://www.anchorterminal.com/reviewers/index.md): .

Desk reviews, written from public documentation, pricing, terms, source and status history on 1 October 2026. No calls made. For a desk review, the outcome says whether the reviewer's questions could be answered from public material: success, partial or failure. How reviews work: https://www.anchorterminal.com/reviews/how-it-works.md

## Notable

- OKX's official MCP server is okx-trade-mcp in okx/agent-trade-kit (TypeScript, MIT, 499 stars, v1.5.0 on 28 October 2026, first public release 12 May 2026), a local stdio process with 170 tools in 11 modules per its README, loading spot, swap and account by default, with --modules, --read-only and a demo profile. It is published on npm as @okx_ai/okx-trade-mcp (1,839 downloads in the week to 2 November 2026) and is not in the official MCP registry, where OKX entries are third-party (source: <https://github.com/okx/agent-trade-kit, https://registry.modelcontextprotocol.io/v0/servers?search=okx>)
- OKX's docs carry an Agent page for the kit and an API Agreement of 28 July 2026 that defines the Agent Trade Kit, bars configuring an agent for wash trading, layering, spoofing, quote stuffing or momentum ignition, bars circumventing rate limits, requires the minimum key scope, and says use cases a third-party AI provider's terms restrict, such as fully automated trading without human oversight, must not run through the API (source: <https://www.okx.com/docs-v5/agent_en/, https://www.okx.com/help/okx-api-agreement>)
- Rate limits are set per endpoint and per User ID for private REST, with Place order at 60 requests per 2 seconds, Get balance at 10 per 2 seconds, at most 3 amendments in flight per order, 1,000 order requests per 2 seconds per sub-account, and WebSocket limits of 3 connections a second per IP and 480 subscribe, unsubscribe and login requests an hour per connection; exceeding a limit returns error 50011 (source: <https://www.okx.com/docs-v5/en/>)
- Demo trading runs on the production REST and WebSocket hosts with the header `x-simulated-trading` set to 1, without withdraw, deposit and purchase or redemption functions (source: <https://www.okx.com/docs-v5/en/>)
- The changelog's newest entry is 27 October 2026 (a bbo-rpi-tbt channel); on 30 September 2026 Crypto-USD spot pairs migrated to Crypto-USDC with no mapping between instrument IDs, and WebSocket port 8443 stops for public internet connections on 31 October 2026 and for colocation on 16 November, labelled a breaking change (source: <https://www.okx.com/docs-v5/log_en/>)
- The Terms of Service (last updated 29 October 2026) name OKX Europe Limited, OKX Inc., OKX Australia, OKX Dubai, OKX Brazil, OKX Singapore and Aux Cayes FinTech Co. Ltd. as contracting entities by residency, say API use may be subject to order rate limits with repeated violations leading to suspension, and bar commercial use without authorisation (source: <https://www.okx.com/help/terms-of-service>)
- Restricted Locations per the Risk and Compliance Disclosure of 8 July 2026 are Afghanistan, Canada, Cuba, Hong Kong, Iran, India, Japan, Malaysia, Nepal, North Korea, Syria, Crimea, Donetsk and Luhansk, Uzbekistan and certain US jurisdictions including all US territories, with services limited in Australia, the Bahamas, Brazil, Eritrea, Russia, South Korea and the United Kingdom (source: <https://www.okx.com/help/risk-compliance-disclosure>)
- okx.com/status lists issue descriptions, maintenance and deposit and withdrawal status in UTC+8; its newest listed incident is a trading service issue of 27 March 2024 lasting about 2 hours 31 minutes, and nothing is listed for August to November 2026 (source: <https://www.okx.com/en-us/status>)
- No security.txt on okx.com (404); the kit's SECURITY.md names security@okx.com and GitHub private advisories (source: <https://github.com/okx/agent-trade-kit/blob/main/SECURITY.md>)

- #4 of 21 in Best crypto exchange APIs and MCP servers for AI agents: https://www.anchorterminal.com/best/crypto-exchanges/index.md
- All 210 exchanges comparisons: https://www.anchorterminal.com/compare/crypto-exchanges/index.md

## Compare

- [Bitfinex API vs OKX API](https://www.anchorterminal.com/compare/bitfinex-vs-okx.md): C 58.4 vs B 64.3
- [Bitget vs OKX API](https://www.anchorterminal.com/compare/bitget-vs-okx.md): D 53.9 vs B 64.3
- [Bithumb Open API vs OKX API](https://www.anchorterminal.com/compare/bithumb-vs-okx.md): D 50.6 vs B 64.3
- [Bitstamp API vs OKX API](https://www.anchorterminal.com/compare/bitstamp-vs-okx.md): D 50.4 vs B 64.3
- [Bybit vs OKX API](https://www.anchorterminal.com/compare/bybit-vs-okx.md): C 57.3 vs B 64.3
- [Crypto.com Exchange API vs OKX API](https://www.anchorterminal.com/compare/crypto-com-exchange-vs-okx.md): D 46.8 vs B 64.3
- [Gate vs OKX API](https://www.anchorterminal.com/compare/gate-io-vs-okx.md): C 56.4 vs B 64.3
- [Gemini Exchange API vs OKX API](https://www.anchorterminal.com/compare/gemini-exchange-vs-okx.md): BB 74.6 vs B 64.3
- [HTX trading API vs OKX API](https://www.anchorterminal.com/compare/htx-vs-okx.md): E 43.3 vs B 64.3
- [KuCoin vs OKX API](https://www.anchorterminal.com/compare/kucoin-vs-okx.md): D 53.9 vs B 64.3
- [MEXC API vs OKX API](https://www.anchorterminal.com/compare/mexc-vs-okx.md): C 56.3 vs B 64.3
- [Binance API vs OKX API](https://www.anchorterminal.com/compare/binance-vs-okx.md): B 63.2 vs B 64.3
- [Coinbase Advanced Trade API vs OKX API](https://www.anchorterminal.com/compare/coinbase-advanced-trade-vs-okx.md): C 61.7 vs B 64.3
- [Coinbase MCP server (Coinbase for Agents) vs OKX API](https://www.anchorterminal.com/compare/coinbase-mcp-vs-okx.md): C 60 vs B 64.3
- [Kraken API vs OKX API](https://www.anchorterminal.com/compare/kraken-vs-okx.md): BB 71 vs B 64.3
- [OKX API vs Uniswap Trading API](https://www.anchorterminal.com/compare/okx-vs-uniswap.md): B 64.3 vs B 63.3
- [OKX API vs Upbit Open API](https://www.anchorterminal.com/compare/okx-vs-upbit.md): B 64.3 vs C 54.7
- [Deribit vs OKX API](https://www.anchorterminal.com/compare/deribit-vs-okx.md): C 59 vs B 64.3
- [dYdX vs OKX API](https://www.anchorterminal.com/compare/dydx-vs-okx.md): B 69.5 vs B 64.3
- [Hyperliquid vs OKX API](https://www.anchorterminal.com/compare/hyperliquid-vs-okx.md): D 50 vs B 64.3

## Verify this listing

For the vendor. The badge or a plain link to this page verifies the listing, from a page on okx.com or one of its subdomains, or the README at the root of github.com/okx/agent-trade-kit. It shows the listing is the vendor's and that the vendor knows it's here, and it never changes a grade, rank or review. The vendor sends the page's address to `POST https://www.anchorterminal.com/api/v1/verify` as `{"slug": "okx", "url": "…"}`, or calls the `verify_listing` tool at https://www.anchorterminal.com/mcp. We fetch the page once, then again every week; two failed checks in a row and the verification lapses, and a later pass restores it. What we check: https://www.anchorterminal.com/builders/index.md#verify

HTML badge:

```html
<a href="https://www.anchorterminal.com/tools/okx"><img src="https://www.anchorterminal.com/badges/okx.svg" alt="OKX API on Anchor Terminal" height="20"></a>
```

Markdown badge, for a README:

```markdown
[![OKX API on Anchor Terminal](https://www.anchorterminal.com/badges/okx.svg)](https://www.anchorterminal.com/tools/okx)
```

Plain link:

```html
<a href="https://www.anchorterminal.com/tools/okx">OKX API on Anchor Terminal</a>
```

## Share this listing

For the vendor. Sharing assets for social media, two PNGs of 1200 × 630 that say OKX API is listed on Anchor Terminal, with the vendor's logo and this page's address and no grade or score.

- Dark: https://www.anchorterminal.com/assets/share/okx-dark.png
- Light: https://www.anchorterminal.com/assets/share/okx-light.png

---

Query this catalogue directly over MCP: https://www.anchorterminal.com/mcp (Streamable HTTP, no key). How: https://www.anchorterminal.com/agents/#mcp
