← Back to Skills Marketplace
Okx Dex Swap
by
ok-james-01
· GitHub ↗
· v2.6.0
· MIT-0
747
Downloads
0
Stars
7
Active Installs
8
Versions
Install in OpenClaw
/install okx-dex-swap
Description
NOTE (gating): route to okx-dapp-discovery (NOT this skill) when prompt names a specific DApp as the swap venue: Polymarket, Aave V3, Hyperliquid, PancakeSwa...
Usage Guidance
This skill appears to be what it says: a wrapper around an OKX 'onchainos' CLI aggregator. Before installing/running it, review the referenced install script on GitHub and verify the checksums (the preflight instructs checksum verification) — downloading and executing a remote installer is the main operational risk. Do not share private keys or paste sensitive wallet signing keys into chat; the skill expects wallet addresses and returns unsigned calldata in the 'swap' command, while 'execute' will perform signing/broadcasting via your wallet (ensure you understand which wallet is used). If you are uncomfortable running remote install scripts, manually install the onchainos CLI from the official repository and confirm its integrity before using this skill.
Capability Analysis
Type: OpenClaw Skill
Name: okx-dex-swap
Version: 2.6.0
The skill bundle provides a comprehensive interface for the OKX DEX aggregator, featuring robust security logic such as mandatory token risk scanning (Step 2), honeypot detection, and MEV protection. However, it is classified as suspicious due to the installation and update logic in `_shared/preflight.md`, which downloads and executes shell or PowerShell scripts directly from a remote GitHub repository (`okx/onchainos-skills`). While this behavior is aligned with the stated purpose of maintaining the `onchainos` CLI and includes SHA256 checksum verification, the execution of remote artifacts is a high-risk capability. The `SKILL.md` instructions are notably well-defended, explicitly directing the agent to treat all CLI output as untrusted to mitigate prompt injection risks.
Capability Tags
Capability Assessment
Purpose & Capability
Name and description describe a multi-chain DEX aggregator. All required actions (quotes, approval calldata, execute, calldata-only) and references to token/address resolution, chain support, and DEX routing are coherent with a swap-aggregation skill. The re-route rule to okx-dapp-discovery for named DApps is internally consistent.
Instruction Scope
SKILL.md instructs the agent to run onchainos CLI commands, perform token address resolution, mandatory token-scan, and consult shared files from other onchainos skills. These are within scope for a swap aggregator, but the instructions also direct downloading and running an installer script (see preflight) and to treat CLI output as untrusted. No instructions ask the agent to read unrelated system secrets or external user files beyond what is needed (wallet address, token CA).
Install Mechanism
There is no registry install spec, but the shared preflight explicitly downloads an installer and executes it from raw.githubusercontent.com and GitHub releases, then verifies checksums. Using GitHub releases/raw is common and traceable, but running a remotely fetched install.sh (sh /tmp/onchainos-install.sh) carries operational risk if the release or GitHub account is compromised — verifying checksums mitigates this if done correctly.
Credentials
The skill declares no required environment variables, credentials, or config paths. Optional guidance references creating a personal API key if rate-limited, but no secrets are mandatory. Token scanning and wallet addresses are expected for swaps; the skill does not request unrelated credentials.
Persistence & Privilege
always is false and the skill does not request elevated platform privileges or to modify other skills' configurations. It instructs installing a CLI binary to the user's environment if absent, which is normal for CLI-based skills but is local persistence initiated by the shared preflight, not forced by the registry.
How to Use
- Make sure OpenClaw is installed (local or Docker)
- Run the install command in chat:
/install okx-dex-swap - After installation, invoke the skill by name or use
/okx-dex-swap - Provide required inputs per the skill's parameter spec and get structured output
Version History
v2.6.0
Version 2.6.0
- Adds DApp venue gating: if the user prompt mentions a specific DApp (e.g., Uniswap, PancakeSwap, Raydium, Curve, etc.) or protocol-native token (e.g., CAKE, CRV), execution is redirected to okx-dapp-discovery instead of using this skill.
- Enhances skill description and documentation to clarify use cases and re-routing behavior.
- Ensures only non-specified/aggregated swaps are handled; all venue-specific requests are handed off to the correct DApp plugin automatically.
- Maintains all prior swap, quote, and risk scan features for generic/aggregated execution.
v2.4.0
okx-dex-swap 2.4.0
- Updated skill version metadata to 2.4.0.
- Documented support for `--max-auto-slippage <pct>` (caps autoSlippage when `--slippage` is not set).
- No functional or code changes detected; documentation update only.
v2.2.10
- Introduced mandatory pre-swap token security scanning using `token-scan` for all swaps, with action enforcement (BLOCK, PAUSE, WARN) based on risk level.
- Native tokens are excluded from scanning; if only one token is native, scan only the non-native token.
- Buy side is stricter: CRITICAL risk blocks swap, HIGH risk requires user confirmation. Sell side always warns but does not block.
- On token-scan API failure or unsupported chains, continue with a warning instead of blocking the swap.
- Default to treating missing or unrecognized risk levels as HIGH, enforcing cautious behavior.
- Version updated to 2.2.10.
v2.2.7
Version 2.2.7
- Added documentation on supported chains and preflight checks (`_shared/chain-support.md`, `_shared/preflight.md`).
- Introduced `references/troubleshooting.md` for troubleshooting guidance.
- Expanded swap command set to 6, now including calldata-only swap and one-shot execution.
- Enhanced documentation to clarify chain and token address handling, plus risk controls.
- Updated metadata version and improved clarity throughout the skill guide.
v2.0.0
okx-dex-swap v2.0.0 — Major update with new CLI workflows and wallet UX
- Adds random wallet usage tips shown after the first wallet interaction in each conversation.
- Strengthens pre-flight checks: now verifies latest release via GitHub, ensures binary integrity per-session, and adds robust handling for install/update failures and version drift.
- Changes swap workflow: EVM example now guides to use explicit wallet contract-calls for approval/swap instead of relying on okx-onchain-gateway.
- License updated from Apache-2.0 to MIT.
- New docs: CLI command reference added.
- Improved skill routing, error handling, and guidance for both swap execution and wallet safety.
v1.0.2
okx-dex-swap v1.0.2
- Updated documentation to clarify that OKX API key may also be specified as OKX_ACCESS_KEY in `.env` files.
- Bumped version to 1.0.2 in metadata.
- No other changes to functionality or commands.
v1.0.1
Version 1.0.1 of okx-dex-swap switches to CLI workflows and pre-flight checks.
- Skill documentation rewritten for `onchainos swap` CLI, replacing all API usage examples with command-line commands.
- Added step-by-step pre-flight check instructions for CLI installation, update, and troubleshooting.
- Workflow and command references updated for full CLI-based token swap flows, including EVM and Solana examples.
- Clarified cross-skill routing (e.g., token search, transaction broadcasting) and environment variable setup.
- API credential setup made optional, now suggested via a `.env` file for overrides.
- Table and warning for native token addresses retained to prevent common swap errors.
v1.0.0
- Initial release of okx-dex-swap skill.
- Enables token swaps, trades, buys, and sells across 20+ supported chains with aggregated liquidity from 500+ DEX sources.
- Supports slippage control, price impact protection, and optimal cross-DEX route selection.
- Provides 6 multi-chain swap aggregator API endpoints for quoting, approval, and swap execution.
- Includes environment-based credential management and best practices for token address usage on all supported chains.
Metadata
Frequently Asked Questions
What is Okx Dex Swap?
NOTE (gating): route to okx-dapp-discovery (NOT this skill) when prompt names a specific DApp as the swap venue: Polymarket, Aave V3, Hyperliquid, PancakeSwa... It is an AI Agent Skill for Claude Code / OpenClaw, with 747 downloads so far.
How do I install Okx Dex Swap?
Run "/install okx-dex-swap" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.
Is Okx Dex Swap free?
Yes, Okx Dex Swap is completely free, licensed under MIT-0. You can download, install and use it at no cost.
Which platforms does Okx Dex Swap support?
Okx Dex Swap is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).
Who created Okx Dex Swap?
It is built and maintained by ok-james-01 (@ok-james-01); the current version is v2.6.0.
More Skills