Cambrian List DEXes API

By Cambrian Network base

GET /api/v1/evm/dexes

List DEXes

Overview

Returns the list of decentralized exchanges (DEXes) tracked on a given EVM-compatible chain. Each entry includes the DEX's on-chain router/factory address, display name, and the AMM algorithm it implements.

Business Value

  • DEX Discovery: Easily discover all DEXes operating across different EVM chains in one request
  • Integration Planning: Get comprehensive DEX information needed for multi-chain DeFi integrations
  • Algorithm Analysis: Understand the distribution of different AMM algorithms (Uniswap V3, Algebra, etc.) across chains
  • Chain Coverage: See which DEXes operate on specific chains like Base (chainId: 8453)
  • Contract Verification: Access verified DEX contract addresses for secure integrations

Endpoint Details

URL:

https://api.cambrian.org/evm/dexes

Method: GET
Authentication: Required via X-API-Key header

Query Parameters

Parameter Type Required Default Description
chain_id integer No 8453 EVM chain ID. Allowed values: 1, 8453, 42161, 4663, 56.

Response Field Descriptions

Response Field Type Description
chainId UInt16 EVM chain ID the DEX is deployed on
address FixedString(42) On-chain contract address associated with the DEX
name String Display name of the DEX
algorithm LowCardinality(FixedString(10)) AMM algorithm identifier used by the DEX (e.g., aerodrome, univ3, algcl)

Examples

1. List DEXes on Base

Retrieves the list of DEXes available on Base (chain ID 8453, the default).

curl -X GET "https://api.cambrian.org/evm/dexes" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json"

Response:

[
  {
    "columns": [
      {
        "name": "chainId",
        "type": "UInt16"
      },
      {
        "name": "address",
        "type": "FixedString(42)"
      },
      {
        "name": "name",
        "type": "String"
      },
      {
        "name": "algorithm",
        "type": "LowCardinality(FixedString(10))"
      }
    ],
    "data": [
      [
        8453,
        "0x420dd381b31aef6683db6b902084cb0ffece40da",
        "Aerodrome",
        "aerodrome"
      ],
      [
        8453,
        "0x5e7bb104d84c7cb9b682aac2f3d509f5f406809a",
        "Aerodrome ICL",
        "univ3"
      ],
      [
        8453,
        "0x01be57173db036d481509cc7aaf7353812ff6dd3",
        "Algebra Clone",
        "algcl"
      ],
      [
        8453,
        "0x06621a0f74b4f3cdc2a3a0bbb3a969f27963eb13",
        "Algebra Clone",
        "algcl"
      ],
      [
        8453,
        "0x0ed6a7c1991e0e0b3e56ec2575b077e4dbfec4ae",
        "Algebra Clone",
        "algcl"
      ],
      [
        8453,
        "0x2f0d41f94d5d1550b79a83d2fe85c82d68c5a3ca",
        "Algebra Clone",
        "algcl"
      ],
      [
        8453,
        "0x3459670786e3ea7aeb1e09518d89eb277a23c68c",
        "Algebra Clone",
        "algcl"
      ],
      [
        8453,
        "0x36077d39cdc65e1e3fb65810430e5b2c4d5fa29e",
        "Algebra Clone",
        "algcl"
      ],
      [
        8453,
        "0x37fa58f9ba47a2af1b4ac8fd3e31f5c033f13aac",
        "Algebra Clone",
        "algcl"
      ],
      [
        8453,
        "0x4963818c35d5793d771bf8091c750b5a71ed101b",
        "Algebra Clone",
        "algcl"
      ]
    ],
    "rows": 33
  }
]

Result collections are limited to 10 items per response. The rows field (33) is the total number of DEXes available for Base; data holds only the first page shown above, including Aerodrome and several Algebra Clone deployments.

x402 Payment Option

This endpoint supports pay-per-use access via the x402 payment protocol (v2): pay $0.05 USDC per request using blockchain micropayments. No API key required.

Quick Start (TypeScript)

npm install @x402/fetch @x402/evm viem
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { wrapFetchWithPayment } from "@x402/fetch";
import { privateKeyToAccount } from "viem/accounts";

const signer = privateKeyToAccount(process.env.EVM_PRIVATE_KEY as `0x${string}`);
const client = new x402Client();
client.register("eip155:*", new ExactEvmScheme(signer));

const fetchWithPayment = wrapFetchWithPayment(fetch, client);
const response = await fetchWithPayment(
  "https://x402.cambrian.org/evm/dexes"
);
const data = await response.json();

Quick Start (Python)

pip install "x402[httpx]"
import asyncio, os
from eth_account import Account
from x402 import x402Client
from x402.http.clients import x402HttpxClient
from x402.mechanisms.evm import EthAccountSigner
from x402.mechanisms.evm.exact.register import register_exact_evm_client

async def main():
    client = x402Client()
    account = Account.from_key(os.getenv("EVM_PRIVATE_KEY"))
    register_exact_evm_client(client, EthAccountSigner(account))

    async with x402HttpxClient(client) as http:
        response = await http.get("https://x402.cambrian.org/evm/dexes")
        print(response.json())

asyncio.run(main())

Payment Flow

  1. Send a normal request to the endpoint (no API key needed)
  2. Server returns 402 Payment Required with payment details
  3. The x402 SDK automatically signs a payment authorization with your wallet
  4. The SDK resubmits the request with the signed payment
  5. Server verifies payment and returns the API response

The x402 SDK handles steps 2 through 5 automatically.

Network: Base (chain ID 8453) | Currency: USDC | Price: $0.05 per request