
Okx Dex Bridge
Automate cross-chain token bridging across OKX-supported networks using the onchainos CLI from your coding agent.
Overview
okx-dex-bridge is an agent skill most often used in Build (also Operate, Validate) that walks solo builders through OKX DEX cross-chain bridging via the onchainos CLI with shared chain resolution and session pre-flight c
Install
npx skills add https://github.com/okx/onchainos-skills --skill okx-dex-bridgeWhat is this skill?
- Resolves human-readable chain names and aliases before bridge commands via shared onchainos chain support
- Runs a documented pre-flight each session: fetch latest GitHub release tag before the first onchainos command
- Wallet accounts expose addressList across 18+ EVM and Solana-family chains at creation time as the source of truth
- Points to `onchainos wallet chains` for the current recognized chain list and chainIndex values
- Keeps routine CLI output internal—only surfaces brief status on install, update, or failure
- Pre-flight checklist: resolve latest stable release via GitHub API before the first onchainos command each session
- Wallet addressList currently spans 18+ chains across EVM and Solana families at account creation
- Use `onchainos wallet chains` for the up-to-date recognized chain list and chainIndex values
Adoption & trust: 2.2k installs on skills.sh; 284 GitHub stars; 2/3 security scanners passed (skills.sh audits).
What problem does it solve?
You need to move tokens across chains reliably but keep guessing chain indexes, CLI versions, and which addresses your wallet actually controls on each network.
Who is it for?
Solo builders shipping Web3 features or ops playbooks who already use onchainos and want agent-driven, repeatable cross-chain bridges.
Skip if: Teams avoiding on-chain custody, builders who only need a one-off manual bridge in a browser wallet, or anyone without reviewing this skill’s Security Audits panel before handling keys.
When should I use this skill?
Before executing OKX DEX cross-chain bridge commands with onchainos in an agent session, especially on first command after opening the workspace.
What do I get? / Deliverables
Your agent runs version-checked onchainos bridge commands against the correct chain aliases and wallet addresses, with clear status only when setup or execution fails.
- Cross-chain bridge transaction executed or prepared via onchainos with resolved chain names
- Brief user-facing status on install, update, or bridge failure only
- Confirmed use of current wallet addressList chains as truth for both ends of the bridge
Recommended Skills
Journey fit
Spans multiple journey phases - primary shelf plus alternate fits below.
Bridging is primarily an on-chain integration task wired into products, scripts, or agent workflows during implementation. The skill centers on calling OKX DEX bridge flows through onchainos rather than UI-only ops or pure research.
Where it fits
Prototype a testnet bridge path before committing to mainnet routing in your MVP.
Embed documented onchainos bridge steps into a backend script your agent maintains.
Verify wallet addressList coverage on source and destination chains before signing bridge transactions.
Execute a controlled treasury rebalance across Polygon and Arbitrum with the same pre-flight version check each session.
Run pre-flight and chain resolution checks before any automated bridge in a release pipeline that touches production keys.
How it compares
Use as a procedural agent skill over the onchainos CLI—not as a standalone hosted bridge UI or generic swap MCP server.
Common Questions / FAQ
Who is okx-dex-bridge for?
It is for solo and indie developers who automate OKX onchain workflows and need cross-chain bridging from Claude Code, Cursor, Codex, or similar agents.
When should I use okx-dex-bridge?
Use it during Build when wiring bridge steps into an app or script, during Validate when prototyping multi-chain flows on testnets, and during Operate when moving treasury or liquidity across supported chains.
Is okx-dex-bridge safe to install?
Treat wallet and bridge automation as high risk: review the Security Audits panel on this Prism page and your key-handling policy; do not rely on invented audit pass counts from summaries.
SKILL.md
READMESKILL.md - Okx Dex Bridge
# Shared Chain Name Support > This file is shared across all onchainos skills. The CLI accepts human-readable chain names and resolves them automatically. When a wallet account is created via `onchainos wallet add`, the response's `addressList` enumerates every chain on which an address was generated for that account — the backend determines the full set at creation time, currently spanning 18+ chains across the EVM and Solana families (Ethereum, BNB Chain, Polygon, Arbitrum, Base, Optimism, X Layer, Avalanche, Linea, Scroll, zkSync, Sonic, Blast, Fantom, Monad, Conflux, Tempo, Solana, etc.). Treat that response as the source of truth — do not hard-code a chain count or list here. For the up-to-date list of chains the CLI recognizes (with both name aliases and chainIndex), run `onchainos wallet chains`. # Shared Pre-flight Checks > This file is shared across all onchainos skills. Follow these steps before the first `onchainos` command each session. Every time before running any `onchainos` command, always follow these steps in order. Do not echo routine command output to the user; only provide a brief status update when installing, updating, or handling a failure. 1. **Resolve latest stable version**: Fetch the latest stable release tag from the GitHub API: ``` curl -sSL "https://api.github.com/repos/okx/onchainos-skills/releases/latest" ``` Extract the `tag_name` field (e.g., `v1.0.5`) into `LATEST_TAG`. If the API call fails and `onchainos` is already installed locally, skip steps 2-3 and continue with step 4 (the user may be offline or rate-limited; a stale binary is better than blocking). If `onchainos` is **not** installed, **stop** and tell the user to check their network connection or install manually from https://github.com/okx/onchainos-skills. 2. **Install or update**: If `onchainos` is not found, or if the cache at `~/.onchainos/last_check` (`$env:USERPROFILE\.onchainos\last_check` on Windows) is older than 12 hours: - Download the installer and its checksum file from the latest release tag: - **macOS/Linux**: `curl -sSL "https://raw.githubusercontent.com/okx/onchainos-skills/${LATEST_TAG}/install.sh" -o /tmp/onchainos-install.sh` `curl -sSL "https://github.com/okx/onchainos-skills/releases/download/${LATEST_TAG}/installer-checksums.txt" -o /tmp/installer-checksums.txt` - **Windows**: `Invoke-WebRequest -Uri "https://raw.githubusercontent.com/okx/onchainos-skills/${LATEST_TAG}/install.ps1" -OutFile "$env:TEMP\onchainos-install.ps1"` `Invoke-WebRequest -Uri "https://github.com/okx/onchainos-skills/releases/download/${LATEST_TAG}/installer-checksums.txt" -OutFile "$env:TEMP\installer-checksums.txt"` - Verify the installer's SHA256 against `installer-checksums.txt`. On mismatch, **stop** and warn — the installer may have been tampered with. - Execute: `sh /tmp/onchainos-install.sh` (or `& "$env:TEMP\onchainos-install.ps1"` on Windows). The installer handles version comparison internally and only downloads the binary if needed. - On other failures, point to https://github.com/okx/onchainos-skills. 3. **Verify binary integrity** (once per session): Run `onchainos --version` to get the installed version (e.g., `1.0.5` or `2.0.0-beta.0`). Construct the installed tag as `v<version>`. Download `checksums.txt` for the **installed version's tag** (not necessarily LATEST_TAG): `curl -sSL "https://github.com/okx/onchainos-skills/releases/download/v<version>/checksums.txt" -o /tmp/onchainos-checksums.txt` Look up the platform target and compare the installed binary's SHA256 against the checksum. On mismatch, reinstall (step 2) and re-verify. If still mismatched, **stop** and warn. - Platform targets — macOS: `arm64`->`aarch64-apple-darwin`, `x86_64`->`x86_64-apple-darwin`; Linux: `x86_64`->`x86_64-unknown-linux-gnu`, `aarch64`->`aarch64-unknown-linux-gnu`, `i686`->`i686-unknown-linux-gnu`, `armv7l`->`armv7-unknown-linux-