Cambrian Token Holders by Program ID API

By Cambrian Network solana

GET /api/v1/solana/tokens/holders

Token Holders

Returns a list of accounts currently holding a specific Solana token (identified by its program ID/mint address), sorted by their current balance (descending). This endpoint leverages pre-aggregated data for performance.

Business Value

  • Portfolio Analysis: Track token distribution across holders to understand concentration and diversification patterns
  • Community Insights: Identify large holders and community distribution for token governance and ecosystem health
  • Risk Assessment: Monitor holder concentration to assess potential liquidity and market manipulation risks
  • Market Research: Analyze token adoption patterns and holder behavior for investment and partnership decisions
  • Compliance Monitoring: Track token distribution for regulatory reporting and AML compliance requirements

Endpoint Details

URL:

https://opabinia.cambrian.network/api/v1/solana/tokens/holders

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

Query Parameters

Parameter Type Required Default Description
program_id string true - The program ID (mint address) of the token.
limit integer false 100 Limit the number of results.
offset integer false 0 Offset the results, allows you to skip a number of rows before starting to return rows.

Response Field Descriptions

Response Field Type Description
account String Account address holding the token
balanceRaw UInt64 Raw token balance (without decimal adjustment)
balanceUi Float64 UI-friendly token balance (adjusted for decimals)
balanceUSD Float64 USD value of the token holdings

Examples

1. Get Token Holders for ORCA Token

This example demonstrates retrieving the current holders of the ORCA token, showing the top holders by balance.

curl -X GET "https://opabinia.cambrian.network/api/v1/solana/tokens/holders?program_id=orcaEKTdK7LKz57vaAYr9QeNsVEPfiu6QeMU1kektZE" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json"

Response:

[
  {
    "columns": [
      {
        "name": "account",
        "type": "FixedString(44)"
      },
      {
        "name": "balanceRaw",
        "type": "UInt64"
      },
      {
        "name": "balanceUi",
        "type": "Float64"
      },
      {
        "name": "balanceUSD",
        "type": "Float64"
      }
    ],
    "data": [
      [
        "5ooCx5vKiV2ZxAEKNNHAJjAJ7BARfLUZPGvgiApZjgFD",
        14842422968139,
        14842422.968139,
        15078463.11561864
      ],
      [
        "Ce5j11WAsSzM3nkzrw4Kw6v6ic3nbyqpv5eywjYKeKc5",
        6951626814473,
        6951626.814473,
        7062179.0485680625
      ],
      [
        "3YzoJK4pS8Urmd6PZtj16BMBVtc8eepk3MLs6LYtrArV",
        5665238176383,
        5665238.176383,
        5755332.877061672
      ],
      [
        "3qPbC7P9baPCXxz2Duqk2Qmbj21ap8pRRbRY8sfobKje",
        3803969870002,
        3803969.870002,
        3864464.6834870223
      ],
      [
        "BwzWKw33iBQin9E8HwFgevCeMByioZCvoZFk7uN433ft",
        3410398860862,
        3410398.860862,
        3464634.6855525016
      ]
    ],
    "rows": 100
    // ... additional rows omitted for brevity
  }
]

This response shows the top ORCA token holders with their account addresses, raw balances, UI-friendly balances, and USD values. The data is returned in columnar format for efficient processing.

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/solana/tokens/holders"
);
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/solana/tokens/holders")
        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/solana/tokens/holders-over-time - Returns a list of accounts holding a specific token over time with snapshots at specified block intervals
  • /api/v1/solana/tokens/holder-distribution-over-time - Returns the distribution of token holders over time grouped by USD value tiers
  • /api/v1/solana/tokens - Returns a paginated list of known tokens for the Solana chain
  • /api/v1/solana/ohlcv/token - Retrieve Open, High, Low, Close, and Volume data for any SPL token