Cambrian V3 - Pool Info API

By Cambrian Network pancake

GET /api/v1/evm/pancake/v3/pool

PancakeSwap V3 Pool Info

This endpoint returns comprehensive pool information for PancakeSwap V3 liquidity pools, including current TVL (Total Value Locked), swap volume, fees APR (Annual Percentage Rate), price tick utilization, number of swaps and unique users across multiple time ranges (5 minutes, 1 hour, 1 day, 1 week, 1 month and 1 year).

Business Value

  • Pool Performance Monitoring: Track key metrics like TVL, volume, and fees to assess pool health and profitability
  • Liquidity Analysis: Monitor price tick utilization to understand how efficiently liquidity is being used
  • User Activity Insights: Analyze swap counts and unique user metrics across different time periods for activity trends
  • APR Calculations: Access fees APR data for yield farming and liquidity provision decision making
  • Historical Context: Compare performance across multiple time ranges from 5 minutes to 1 year for trend analysis

Endpoint Details

URL:

https://opabinia.cambrian.network/api/v1/evm/pancake/v3/pool

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

Query Parameters

Parameter Type Required Default Description
pool_address string true - Pool address with 0x prefix (pattern: ^0x[a-fA-F0-9]{40}$)

Response Field Descriptions

Response Field Type Description
createdAt DateTime Pool creation timestamp in UTC
token0Address string Contract address of the first token in the pair
token0Symbol string Symbol of the first token
token0Decimals number Number of decimals for token0
token1Address string Contract address of the second token in the pair
token1Symbol string Symbol of the second token
token1Decimals number Number of decimals for token1
feeTier number Fee tier of the pool (in hundredths of basis points)
tickSpacing number Tick spacing for the pool
currentLiquidity string Current total liquidity in the pool
currentSqrtPriceX96 string Current sqrt price multiplied by 2^96
currentTick number Current tick of the pool
currentPoolPrice number Current price of token1 in terms of token0
poolTvlUSD number Total Value Locked in USD
swapVolumeUSD object Map of swap volume in USD across different time periods
feeApr object Map of fee APR percentages across different time periods
tickUtilization object Map of tick utilization percentages across different time periods
swapCount object Map of swap counts across different time periods
uniqueUserCount object Map of unique user counts across different time periods

Examples

1. Get Pool Information for WETH/cbBTC Pool

This example retrieves comprehensive pool data for a PancakeSwap V3 WETH/cbBTC pool, showing metrics across multiple timeframes.

curl -X GET "https://opabinia.cambrian.network/api/v1/evm/pancake/v3/pool?pool_address=0xC211e1f853A898Bd1302385CCdE55f33a8C4B3f3" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json"

Response:

{
  "columns": [
    {
      "name": "createdAt",
      "type": "DateTime('UTC')"
    },
    {
      "name": "token0Address",
      "type": "LowCardinality(FixedString(42))"
    },
    {
      "name": "token0Symbol",
      "type": "String"
    },
    {
      "name": "token0Decimals",
      "type": "UInt8"
    },
    {
      "name": "token1Address",
      "type": "LowCardinality(FixedString(42))"
    },
    {
      "name": "token1Symbol",
      "type": "String"
    },
    {
      "name": "token1Decimals",
      "type": "UInt8"
    },
    {
      "name": "feeTier",
      "type": "UInt32"
    },
    {
      "name": "tickSpacing",
      "type": "Int32"
    },
    {
      "name": "currentLiquidity",
      "type": "UInt128"
    },
    {
      "name": "currentSqrtPriceX96",
      "type": "UInt256"
    },
    {
      "name": "currentTick",
      "type": "Int32"
    },
    {
      "name": "currentPoolPrice",
      "type": "Float64"
    },
    {
      "name": "poolTvlUSD",
      "type": "Float64"
    },
    {
      "name": "swapVolumeUSD",
      "type": "Map(String,Float64)"
    },
    {
      "name": "feeApr",
      "type": "Map(String,Float64)"
    },
    {
      "name": "tickUtilization",
      "type": "Map(String,Float64)"
    },
    {
      "name": "swapCount",
      "type": "Map(String,UInt64)"
    },
    {
      "name": "uniqueUserCount",
      "type": "Map(String,UInt64)"
    }
  ],
  "data": [
    [
      "2024-09-13T06:45:47+00:00",
      "0x4200000000000000000000000000000000000006",
      "WETH",
      18,
      "0xcbb7c0000ab88b473b1f5afd9ef808440eed33bf",
      "cbBTC",
      8,
      100,
      1,
      107212895607954956,
      "145626920347568717213247",
      -264150,
      3.3785018666119674E-12,
      10203249.179796051,
      {
        "'1 day'": 53295029.62580393,
        "'1 hour'": 1353107.9274884984,
        "'1 month'": 1784013607.2371073,
        "'1 week'": 423699314.55249476,
        "'1 year'": 15967482203.790384,
        "'5 minute'": 0.0
      },
      {
        "'1 day'": 19.06518744238614,
        "'1 hour'": 11.617108664042423,
        "'1 month'": 20.98171171712304,
        "'1 week'": 21.59347867379058,
        "'1 year'": 15.649409244467313,
        "'5 minute'": 0.0
      },
      {
        "'1 day'": 45.983333333333334,
        "'1 hour'": 27.200000000000003,
        "'1 month'": 48.590555555555554,
        "'1 week'": 53.9702380952381,
        "'1 year'": 100.0,
        "'5 minute'": 0.0
      },
      {
        "'1 day'": 21365,
        "'1 hour'": 593,
        "'1 month'": 612298,
        "'1 week'": 142752,
        "'1 year'": 10504673,
        "'5 minute'": 0
      },
      {
        "'1 day'": 21365,
        "'1 hour'": 207,
        "'1 month'": 32285,
        "'1 week'": 9371,
        "'1 year'": 388236,
        "'5 minute'": 0
      }
    ]
  ],
  "rows": 1
}

The response shows detailed metrics for the WETH/cbBTC pool created on September 13, 2024. The pool has a TVL of ~$10.2M and shows strong activity with over 21K swaps in the past day. The fee APR ranges from 11.6% (1 hour) to 21.6% (1 week), indicating good returns for liquidity providers.

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://deep42.cambrian.network/api/v1/evm/pancake/v3/pool"
);
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://deep42.cambrian.network/api/v1/evm/pancake/v3/pool")
        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–5 automatically.

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


Related Endpoints

  • /api/v1/evm/pancake/v3/pools - Returns a list of all liquidity pools, including token pairs, fee tiers, and creation timestamps
  • /api/v1/evm/aero/v3/pool - Returns current pool TVL(Total Value Locked), Swap Volume, Fees APR (Annual Percentage Rate), Price Tick Utilization, Number of Swaps and Unique users for recent time range (5 minutes, 1 hour, 1 day, 1 week, 1 month and 1 year)
  • /api/v1/evm/alien/v3/pool - Returns current pool TVL (Total Value Locked), Swap Volume, Fees APR (Annual Percentage Rate), Price Tick Utilization, Number of Swaps and Unique users for recent time range (5 minutes, 1 hour, 1 day, 1 week, 1 month and 1 year)