返回 Skill 市集

Market Data

cmc-api-dex

Provides a reference and integration guide for CoinMarketCap's DEX APIs, delivering on-chain token data from Uniswap, PancakeSwap, Raydium and other DEXs. Supports authenticated requests (X-CMC_PRO_API_KEY) against https://pro-api.coinmarketcap.

45 天前更新1 分鐘內設定完

總覽

Provides a reference and integration guide for CoinMarketCap's DEX APIs, delivering on-chain token data from Uniswap, PancakeSwap, Raydium and other DEXs.

Provides a reference and integration guide for CoinMarketCap's DEX APIs, delivering on-chain token data from Uniswap, PancakeSwap, Raydium and other DEXs. Supports authenticated requests (X-CMC_PRO_API_KEY) against https://pro-api.coinmarketcap.com and explains GET vs POST usage patterns and JSON body requirements. Documents core endpoints such as /v1/dex/token, /v1/dex/token/price, /v1/dex/token/price/batch, /v1/dex/token/pools and /v1/dex/token-liquidity/query. Use cases include fetching token price by contract address, batch price retrieval, discovering liquidity pools, analyzing liquidity over time, detecting rug pulls/security signals, listing trending or newly launched DEX tokens, and retrieving recent trades. Core advantages: authoritative on-chain DEX coverage, multi-chain/multi-DEX support, ready-made endpoints for analytics and trading integrations, and clear authentication and request format guidance for reliable implementation.

Skill.md

這個 Skill 如何運作

Provides a reference and integration guide for CoinMarketCap's DEX APIs, delivering on-chain token data from Uniswap, PancakeSwap, Raydium and other DEXs. Supports authenticated requests (X-CMC_PRO_API_KEY) against https://pro-api.coinmarketcap.

SKILL.mdALPHIO / 已驗證

CoinMarketCap DEX API

This skill covers CoinMarketCap's DEX (Decentralized Exchange) APIs for on-chain token data. Unlike CEX endpoints, these APIs fetch data directly from blockchain DEXs like Uniswap, PancakeSwap, and Raydium.

Authentication

All requests require an API key in the header:

curl -X GET "https://pro-api.coinmarketcap.com/v1/dex/platform/list" \
  -H "X-CMC_PRO_API_KEY: your-api-key"

Get your API key at: https://pro.coinmarketcap.com/login

Base URL

https://pro-api.coinmarketcap.com

POST vs GET Endpoints

Many DEX endpoints use POST for complex queries with body parameters. Always check the method:

  1. GET endpoints pass parameters as query strings
  2. POST endpoints pass parameters in JSON body with Content-Type: application/json

Common Use Cases

See use-cases.md for goal-based guidance on which endpoint to use:

  1. Get DEX token price by contract address
  2. Find a token's contract address by name
  3. Get prices for multiple tokens at once
  4. Check token security before trading
  5. Find liquidity pools for a token
  6. Find trending DEX tokens
  7. Find today's biggest DEX gainers
  8. Find newly launched tokens
  9. Detect potential rug pulls (liquidity removal)
  10. Get recent trades for a token
  11. Get supported networks and DEXs
  12. Get meme coins

API Overview

EndpointMethodDescriptionReference
/v1/dex/tokenGETToken details by platform/addresstokens.md
/v1/dex/token/priceGETLatest DEX price for a tokentokens.md
/v1/dex/token/price/batchPOSTBatch token pricestokens.md
/v1/dex/token/poolsGETLiquidity pools for a tokentokens.md
/v1/dex/token-liquidity/queryGETToken liquidity over timetokens.md
/v1/dex/tokens/batch-queryPOSTBatch token metadatatokens.md
/v1/dex/tokens/transactionsGETRecent DEX transactionstokens.md
/v1/dex/tokens/trending/listPOSTTrending DEX tokenstokens.md
/v4/dex/pairs/quotes/latestGETLatest DEX pair quotespairs.md
/v4/dex/spot-pairs/latestGETDEX spot pairs listingpairs.md
/v1/dex/platform/listGETList supported DEX platformsplatforms.md
/v1/dex/platform/detailGETPlatform detailsplatforms.md
/v1/dex/searchGETSearch DEX tokens/pairsplatforms.md
/v1/dex/gainer-loser/listPOSTTop DEX gainers/losersdiscovery.md
/v1/dex/liquidity-change/listGETTokens with liquidity changesdiscovery.md
/v1/dex/meme/listPOSTMeme tokens on DEXdiscovery.md
/v1/dex/new/listPOSTNewly discovered DEX tokensdiscovery.md
/v1/dex/security/detailGETToken security/risk signalssecurity.md

Common Workflows

Get DEX Token Information

  1. Search for token: /v1/dex/search?keyword=PEPE
  2. Get token details: /v1/dex/token?network_slug=ethereum&contract_address=0x...
  3. Check security risks: /v1/dex/security/detail?network_slug=ethereum&contract_address=0x...

Analyze Token Liquidity

  1. Get token pools: /v1/dex/token/pools?network_slug=ethereum&contract_address=0x...
  2. Get liquidity history: /v1/dex/token-liquidity/query?network_slug=ethereum&contract_address=0x...

Find Trending Tokens

  1. Get trending tokens: POST /v1/dex/tokens/trending/list with filters
  2. Get gainers/losers: POST /v1/dex/gainer-loser/list
  3. Find new tokens: POST /v1/dex/new/list

Monitor DEX Activity

  1. Get recent transactions: /v1/dex/tokens/transactions?network_slug=ethereum&contract_address=0x...
  2. Get pair quotes: /v4/dex/pairs/quotes/latest?network_slug=ethereum&contract_address=0x...

Key Parameters

Most DEX endpoints require:

  1. network_slug or platform_crypto_id: Identifies the blockchain (ethereum, solana, bsc)
  2. contract_address: The token's on-chain contract address

Use /v1/dex/platform/list to get valid network slugs and platform IDs.

Error Handling

CodeMeaning
400Bad request (invalid parameters)
401Unauthorized (invalid or missing API key)
403Forbidden (endpoint not in your plan)
429Rate limit exceeded
500Server error

Example error response:

{
  "status": {
    "error_code": 400,
    "error_message": "Invalid value for 'contract_address'"
  }
}

Rate Limits

Rate limits depend on your API plan. Check response headers:

  1. X-CMC_PRO_API_KEY_CREDITS_REMAINING: Credits left
  2. X-CMC_PRO_API_KEY_CREDITS_RESET: Reset timestamp

Response Format

All responses follow this structure:

{
  "status": {
    "timestamp": "2024-01-15T12:00:00.000Z",
    "error_code": 0,
    "error_message": null
  },
  "data": { ... }
}

最適合用於

何時使用

Provides a reference and integration guide for CoinMarketCap's DEX APIs, delivering on-chain token data from Uniswap, PancakeSwap, Raydium and other DEXs. Supports authenticated requests (X-CMC_PRO_API_KEY) against https://pro-api.coinmarketcap.

01 · 會前準備

準備決策簡報

在投資委員會開會前,把零散證據整理成結構化的論據。

02 · 團隊協作

統一交接標準

讓分析師、投資組合經理與 Agent 產出一致的研究結果。

03 · 即時更新

更新投資邏輯

出現新催化劑、KPI 發布或財報結果後,更新情境假設。

社群回饋

越用越好用。

隨著 Skill 被使用與評審,回饋將顯示在這裡。

提交回饋

探索更多

相關 Skills

查看全部
免費開始