Heurist Logo
Back to Skill Marketplace
okx

okx-dex-token

VerifiedCryptoaccess level:low

This skill should be used when the user asks to 'find a token', 'search for a token', 'look up PEPE', 'what\'s trending', 'top tokens', 'trending tokens on Solana', 'token rankings', 'who holds this token', 'holder distribution', 'token market cap', 'token liquidity', 'research a token', 'tell me about this token', 'token info', or mentions searching for tokens by name or address, discovering trending tokens, viewing token rankings, checking holder distribution, or analyzing token market cap and liquidity. Covers token search, metadata, market cap, liquidity, volume, trending token rankings, and holder analysis across XLayer, Solana, Ethereum, Base, BSC, Arbitrum, Polygon, and 20+ other chains. Do NOT use when the user says only a single generic word like 'tokens' or 'crypto' without specifying a token name, action, or question. For simple current price checks, price charts, candlestick data, or trade history, use okx-dex-market instead. For meme token safety analysis, developer reputation, rug pull checks, b

Install

npx @heurist-network/skills add okx-dex-token

Installs

2

Stars

136

Timeline

Updated Mar 9, 2026

Created Mar 9, 2026

Verification

Reviewed and verified

SHA256: 03f14349785256e1...

Approved Mar 9, 2026 by admin

Access Level

low

External APIs

OKX DEX API

Files (1)

SKILL.md

Summary

license
Apache-2.0
metadata
author: okxversion: 1.0.1homepage: https://web3.okx.com

SKILL.md

OKX DEX Token Info CLI

5 commands for token search, metadata, detailed pricing, rankings, and holder distribution.

Pre-flight Checks

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. Confirm installed: Run which onchainos. If not found, install it:

    curl -sSL https://raw.githubusercontent.com/okx/onchainos-skills/main/install.sh | sh
    

    If the install script fails, ask the user to install manually following the instructions at: https://github.com/okx/onchainos-skills

  2. Check for updates: Read ~/.onchainos/last_check and compare it with the current timestamp:

    cached_ts=$(cat ~/.onchainos/last_check 2>/dev/null || true)
    now=$(date +%s)
    
    • If cached_ts is non-empty and (now - cached_ts) < 43200 (12 hours), skip the update and proceed.
    • Otherwise (file missing or older than 12 hours), run the installer to check for updates:
      curl -sSL https://raw.githubusercontent.com/okx/onchainos-skills/main/install.sh | sh
      
      If a newer version is installed, tell the user and suggest updating their onchainos skills from https://github.com/okx/onchainos-skills to get the latest features.
  3. If any onchainos command fails with an unexpected error during this session, try reinstalling before giving up:

    curl -sSL https://raw.githubusercontent.com/okx/onchainos-skills/main/install.sh | sh
    
  4. Create a .env file in the project root to override the default API credentials (optional — skip this for quick start):

    OKX_API_KEY=
    OKX_SECRET_KEY=
    OKX_PASSPHRASE=
    

Skill Routing

  • For real-time prices / K-lines / trade history → use okx-dex-market
  • For swap execution → use okx-dex-swap
  • For transaction broadcasting → use okx-onchain-gateway
  • For wallet balances / portfolio → use okx-wallet-portfolio
  • For meme token safety (dev reputation, rug pull, bundlers, similar tokens by same dev) → use okx-dex-market
  • For smart money / whale / KOL signals → use okx-dex-market

Quickstart

# Search token
onchainos token search xETH --chains "ethereum,solana"

# Get detailed price info
onchainos token price-info 0xe7b000003a45145decf8a28fc755ad5ec5ea025a --chain xlayer

# What's trending on Solana by volume?
onchainos token trending --chains solana --sort-by 5 --time-frame 4

# Check holder distribution
onchainos token holders 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee --chain xlayer

Chain Name Support

The CLI accepts human-readable chain names (e.g., ethereum, solana, xlayer) and resolves them automatically.

ChainNamechainIndex
XLayerxlayer196
Solanasolana501
Ethereumethereum1
Basebase8453
BSCbsc56
Arbitrumarbitrum42161

Command Index

#CommandDescription
1onchainos token search <query>Search for tokens by name, symbol, or address
2onchainos token info <address>Get token basic info (name, symbol, decimals, logo)
3onchainos token price-info <address>Get detailed price info (price, market cap, liquidity, volume, 24h change)
4onchainos token trendingGet trending / top tokens
5onchainos token holders <address>Get token holder distribution (top 20)

Boundary: token vs market skill

NeedUse this skill (okx-dex-token)Use okx-dex-market instead
Search token by name/symbolonchainos token search-
Token metadata (decimals, logo)onchainos token info-
Price + market cap + liquidity + multi-timeframe changeonchainos token price-info-
Token ranking (trending)onchainos token trending-
Holder distributiononchainos token holders-
Raw real-time price (single value)-onchainos market price
K-line / candlestick chart-onchainos market kline
Trade history (buy/sell log)-onchainos market trades
Index price (multi-source aggregate)-onchainos market index
Meme token dev reputation / rug pull-onchainos market memepump-token-dev-info
Bundle/sniper detection-onchainos market memepump-token-bundle-info
Similar tokens by same creator-onchainos market memepump-similar-tokens

Rule of thumb: okx-dex-token = token discovery & enriched analytics (search, trending, holders, market cap). okx-dex-market = raw price feeds, charts, smart money signals & meme pump scanning (including dev reputation, rug pull checks, bundler analysis).

Cross-Skill Workflows

This skill is the typical entry point — users often start by searching/discovering tokens, then proceed to swap.

Workflow A: Search → Research → Buy

User: "Find BONK token, analyze it, then buy some"

1. okx-dex-token    onchainos token search BONK --chains solana              → get tokenContractAddress, chain, price
       ↓ tokenContractAddress
2. okx-dex-token    onchainos token price-info <address> --chain solana      → market cap, liquidity, volume24H, priceChange24H
3. okx-dex-token    onchainos token holders <address> --chain solana         → top 20 holders distribution
4. okx-dex-market   onchainos market kline <address> --chain solana --bar 1H → hourly price chart
       ↓ user decides to buy
5. okx-dex-swap     onchainos swap quote --from ... --to <address> --amount ... --chain solana
6. okx-dex-swap     onchainos swap swap --from ... --to <address> --amount ... --chain solana --wallet <addr>

Data handoff:

  • tokenContractAddress from step 1 → reused in all subsequent steps
  • chain from step 1 → reused in all subsequent steps
  • decimal from step 1 or onchainos token info → needed for minimal unit conversion in swap

Workflow B: Discover Trending → Investigate → Trade

User: "What's trending on Solana?"

1. okx-dex-token    onchainos token trending --chains solana --sort-by 5 --time-frame 4  → top tokens by 24h volume
       ↓ user picks a token
2. okx-dex-token    onchainos token price-info <address> --chain solana                   → detailed analytics
3. okx-dex-token    onchainos token holders <address> --chain solana                      → check if whale-dominated
4. okx-dex-market   onchainos market kline <address> --chain solana                       → K-line for visual trend
       ↓ user decides to trade
5. okx-dex-swap     onchainos swap swap --from ... --to ... --amount ... --chain solana --wallet <addr>

Workflow C: Token Verification Before Swap

Before swapping an unknown token, always verify:

1. okx-dex-token    onchainos token search <name>                            → find token
2. Check communityRecognized:
   - true → proceed with normal caution
   - false → warn user about risk
3. okx-dex-token    onchainos token price-info <address> → check liquidity:
   - liquidity < $10K → warn about high slippage risk
   - liquidity < $1K → strongly discourage trade
4. okx-dex-swap     onchainos swap quote ... → check isHoneyPot and taxRate
5. If all checks pass → proceed to swap

Operation Flow

Step 1: Identify Intent

  • Search for a token → onchainos token search
  • Get token metadata → onchainos token info
  • Get price + market cap + liquidity → onchainos token price-info
  • View rankings → onchainos token trending
  • View holder distribution → onchainos token holders

Step 2: Collect Parameters

  • Missing chain → recommend XLayer (--chain xlayer, low gas, fast confirmation) as the default, then ask which chain the user prefers
  • Only have token name, no address → use onchainos token search first
  • For search, --chains defaults to "1,501" (Ethereum + Solana)
  • For trending, --sort-by defaults to 5 (volume), --time-frame defaults to 4 (24h)

Step 3: Call and Display

  • Search results: show name, symbol, chain, price, 24h change
  • Indicate communityRecognized status for trust signaling
  • Price info: show market cap, liquidity, and volume together

Step 4: Suggest Next Steps

After displaying results, suggest 2-3 relevant follow-up actions based on the command just executed:

Just calledSuggest
token search1. View detailed analytics (market cap, liquidity) → onchainos token price-info (this skill) 2. View price chart → okx-dex-market 3. Buy/swap this token → okx-dex-swap
token info1. View price and market data → onchainos token price-info (this skill) 2. Check holder distribution → onchainos token holders (this skill)
token price-info1. View K-line chart → okx-dex-market 2. Check holder distribution → onchainos token holders (this skill) 3. Buy/swap this token → okx-dex-swap
token trending1. View details for a specific token → onchainos token price-info (this skill) 2. View price chart → okx-dex-market 3. Buy a trending token → okx-dex-swap
token holders1. View price trend → okx-dex-market 2. Buy/swap this token → okx-dex-swap

Present conversationally, e.g.: "Would you like to see the price chart or check the holder distribution?" — never expose skill names or endpoint paths to the user.

CLI Command Reference

1. onchainos token search

Search for tokens by name, symbol, or contract address.

onchainos token search <query> [--chains <chains>]
ParamRequiredDefaultDescription
<query>Yes-Keyword: token name, symbol, or contract address (positional)
--chainsNo"1,501"Chain names or IDs, comma-separated (e.g., "ethereum,solana" or "196,501")

Return fields:

FieldTypeDescription
tokenContractAddressStringToken contract address
tokenSymbolStringToken symbol (e.g., "ETH")
tokenNameStringToken full name
tokenLogoUrlStringToken logo image URL
chainIndexStringChain identifier
decimalStringToken decimals (e.g., "18")
priceStringCurrent price in USD
changeString24-hour price change percentage
marketCapStringMarket capitalization in USD
liquidityStringLiquidity in USD
holdersStringNumber of token holders
explorerUrlStringBlock explorer URL for the token
tagList.communityRecognizedBooleantrue = listed on Top 10 CEX or community verified

2. onchainos token info

Get token basic info (name, symbol, decimals, logo).

onchainos token info <address> [--chain <chain>]
ParamRequiredDefaultDescription
<address>Yes-Token contract address (positional)
--chainNoethereumChain name

Return fields:

FieldTypeDescription
tokenNameStringToken full name
tokenSymbolStringToken symbol (e.g., "ETH")
tokenLogoUrlStringToken logo image URL
decimalStringToken decimals (e.g., "18")
tokenContractAddressStringToken contract address
tagList.communityRecognizedBooleantrue = listed on Top 10 CEX or community verified

3. onchainos token price-info

Get detailed price info including market cap, liquidity, volume, and multi-timeframe price changes.

onchainos token price-info <address> [--chain <chain>]
ParamRequiredDefaultDescription
<address>Yes-Token contract address (positional)
--chainNoethereumChain name

Return fields:

FieldTypeDescription
priceStringCurrent price in USD
timeStringTimestamp (Unix milliseconds)
marketCapStringMarket capitalization in USD
liquidityStringTotal liquidity in USD
circSupplyStringCirculating supply
holdersStringNumber of token holders
tradeNumString24-hour trade count
priceChange5MStringPrice change percentage — last 5 minutes
priceChange1HStringPrice change percentage — last 1 hour
priceChange4HStringPrice change percentage — last 4 hours
priceChange24HStringPrice change percentage — last 24 hours
volume5MStringTrading volume (USD) — last 5 minutes
volume1HStringTrading volume (USD) — last 1 hour
volume4HStringTrading volume (USD) — last 4 hours
volume24HStringTrading volume (USD) — last 24 hours
txs5MStringTransaction count — last 5 minutes
txs1HStringTransaction count — last 1 hour
txs4HStringTransaction count — last 4 hours
txs24HStringTransaction count — last 24 hours
maxPriceString24-hour highest price
minPriceString24-hour lowest price

4. onchainos token trending

Get trending / top tokens by various criteria.

onchainos token trending [--chains <chains>] [--sort-by <sort>] [--time-frame <frame>]
ParamRequiredDefaultDescription
--chainsNo"1,501"Chain names or IDs, comma-separated
--sort-byNo"5"Sort: 2=price change, 5=volume, 6=market cap
--time-frameNo"4"Window: 1=5min, 2=1h, 3=4h, 4=24h

Return fields:

FieldTypeDescription
tokenSymbolStringToken symbol
tokenContractAddressStringToken contract address
tokenLogoUrlStringToken logo image URL
chainIndexStringChain identifier
priceStringCurrent price in USD
changeStringPrice change percentage (for selected time frame)
volumeStringTrading volume in USD (for selected time frame)
marketCapStringMarket capitalization in USD
liquidityStringTotal liquidity in USD
holdersStringNumber of token holders
uniqueTradersStringNumber of unique traders (for selected time frame)
txsBuyStringBuy transaction count (for selected time frame)
txsSellStringSell transaction count (for selected time frame)
txsStringTotal transaction count (for selected time frame)
firstTradeTimeStringFirst trade timestamp (Unix milliseconds)

5. onchainos token holders

Get token holder distribution (top 20).

onchainos token holders <address> [--chain <chain>]
ParamRequiredDefaultDescription
<address>Yes-Token contract address (positional)
--chainNoethereumChain name

Return fields (top 20 holders):

FieldTypeDescription
data[].holdAmountStringToken amount held
data[].holderWalletAddressStringHolder wallet address

Input / Output Examples

User says: "Search for xETH token on XLayer"

onchainos token search xETH --chains xlayer
# → Display:
#   xETH (0xe7b0...) - XLayer
#   Price: $X,XXX.XX | 24h: +X% | Market Cap: $XXM | Liquidity: $XXM
#   Community Recognized: Yes

User says: "What's trending on Solana by volume?"

onchainos token trending --chains solana --sort-by 5 --time-frame 4
# → Display top tokens sorted by 24h volume:
#   #1 SOL  - Vol: $1.2B | Change: +3.5% | MC: $80B
#   #2 BONK - Vol: $450M | Change: +12.8% | MC: $1.5B
#   ...

User says: "Who are the top holders of this token?"

onchainos token holders 0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee --chain xlayer
# → Display top 20 holders with amounts and addresses

Edge Cases

  • Token not found: suggest verifying the contract address (symbols can collide)
  • Same symbol on multiple chains: show all matches with chain names
  • Unverified token: communityRecognized = false — warn user about risk
  • Too many results: name/symbol search caps at 100 — suggest using exact contract address
  • Network error: retry once
  • Region restriction (error code 50125 or 80001): do NOT show the raw error code to the user. Instead, display a friendly message: ⚠️ Service is not available in your region. Please switch to a supported region and try again.

Amount Display Rules

  • Use appropriate precision: 2 decimals for high-value, significant digits for low-value
  • Market cap / liquidity in shorthand ($1.2B, $45M)
  • 24h change with sign and color hint (+X% / -X%)

Global Notes

  • Use contract address as primary identity — symbols can collide across tokens
  • communityRecognized = true means listed on Top 10 CEX or community verified
  • The CLI resolves chain names automatically (e.g., ethereum1, solana501)
  • EVM addresses must be all lowercase
  • The CLI handles authentication internally via environment variables — see Prerequisites step 4 for default values