> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dexutils.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Tokens API: Real-Time Prices, Metadata, and Batch Lookup

> Use GET /networks/{network}/tokens/{address} for token price, FDV, and 24h stats. POST /tokens/batch fetches up to 100 tokens across networks in one call.

The Tokens API lets you retrieve real-time price data, supply metrics, and 24-hour trading analytics for any token tracked by DexUtils. You can look up a single token by its contract address or send a batch request for up to 100 tokens across multiple networks in a single round-trip — useful for dashboards, portfolio trackers, and price alert systems.

## Get Token Details

```http theme={null}
GET /networks/{network}/tokens/{address}
```

Returns the full metadata and live analytics for a single token on a specific network.

### Path Parameters

<ParamField path="network" type="string" required>
  The network the token lives on (e.g. `ethereum`, `solana`, `bsc`). Retrieve valid network IDs from `GET /networks`.
</ParamField>

<ParamField path="address" type="string" required>
  The token's contract address. For EVM networks this is a checksummed hex address; for Solana it is a Base58 mint address.
</ParamField>

### Code Examples

<CodeGroup>
  ```bash cURL theme={null}
  # Replace the token below with your actual API key from the DexUtils dashboard
  curl "https://api.dexutils.io/v1/networks/ethereum/tokens/0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2" \
    -H "Authorization: Bearer dxu_sk_live_4f8a2bcd9e1f3a7056c8d2e94b0f1c63"
  ```

  ```python Python theme={null}
  import requests

  # Replace with your actual API key from the DexUtils dashboard
  network = "ethereum"
  address = "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"
  url = f"https://api.dexutils.io/v1/networks/{network}/tokens/{address}"
  headers = {"Authorization": "Bearer dxu_sk_live_4f8a2bcd9e1f3a7056c8d2e94b0f1c63"}

  response = requests.get(url, headers=headers)
  token = response.json()

  print(f"{token['symbol']} price: ${token['price_usd']}")
  print(f"24h volume: ${token['24h']['volume_usd']}")
  ```

  ```javascript JavaScript theme={null}
  // Replace with your actual API key from the DexUtils dashboard
  const network = "ethereum";
  const address = "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2";

  const response = await fetch(
    `https://api.dexutils.io/v1/networks/${network}/tokens/${address}`,
    {
      headers: {
        Authorization: "Bearer dxu_sk_live_4f8a2bcd9e1f3a7056c8d2e94b0f1c63",
      },
    }
  );

  const token = await response.json();

  console.log(`${token.symbol} price: $${token.price_usd}`);
  console.log(`24h volume: $${token["24h"].volume_usd}`);
  ```
</CodeGroup>

### Response Fields

<ResponseField name="id" type="string" required>
  The token's contract address, matching the `address` path parameter.
</ResponseField>

<ResponseField name="name" type="string" required>
  Full token name as registered on-chain (e.g. `Wrapped Ether`).
</ResponseField>

<ResponseField name="symbol" type="string" required>
  Token ticker symbol (e.g. `WETH`, `USDC`).
</ResponseField>

<ResponseField name="network" type="string" required>
  Network ID where this token is deployed (e.g. `ethereum`).
</ResponseField>

<ResponseField name="decimals" type="integer" required>
  Number of decimal places used by the token contract. Use this to convert raw on-chain amounts to human-readable values.
</ResponseField>

<ResponseField name="total_supply" type="string" required>
  Total token supply as a decimal string, adjusted for `decimals`.
</ResponseField>

<ResponseField name="price_usd" type="string" required>
  Current token price in USD, derived from the deepest liquidity pool. Returned as a string to preserve precision for low-cap tokens.
</ResponseField>

<ResponseField name="fdv" type="string" required>
  Fully diluted valuation in USD (`price_usd × total_supply`), returned as a decimal string.
</ResponseField>

<ResponseField name="liquidity_usd" type="string" required>
  Total USD liquidity aggregated across all indexed pools for this token.
</ResponseField>

<ResponseField name="pools" type="integer" required>
  Number of liquidity pools that include this token across all indexed DEXes on this network.
</ResponseField>

<ResponseField name="24h" type="object" required>
  Rolling 24-hour trading statistics.

  <Expandable title="24h object">
    <ResponseField name="volume_usd" type="string" required>
      Total USD trading volume across all pools in the past 24 hours.
    </ResponseField>

    <ResponseField name="buys" type="integer" required>
      Number of buy-side swap transactions in the past 24 hours.
    </ResponseField>

    <ResponseField name="sells" type="integer" required>
      Number of sell-side swap transactions in the past 24 hours.
    </ResponseField>

    <ResponseField name="price_change_pct" type="number" required>
      Percentage price change over the past 24 hours. Positive values indicate price appreciation; negative values indicate a decline.
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="has_image" type="boolean" required>
  `true` if DexUtils has a logo image on file for this token.
</ResponseField>

<ResponseField name="verified" type="boolean" required>
  `true` if the token has been manually verified by the DexUtils team. Verified tokens have confirmed metadata and are less likely to be honeypots or impostors.
</ResponseField>

### Example Response

```json Example Response theme={null}
{
  "id": "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2",
  "name": "Wrapped Ether",
  "symbol": "WETH",
  "network": "ethereum",
  "decimals": 18,
  "total_supply": "3142567.891",
  "price_usd": "3421.55",
  "fdv": "10748512348.05",
  "liquidity_usd": "892341204.12",
  "pools": 4823,
  "24h": {
    "volume_usd": "1248324891.44",
    "buys": 84231,
    "sells": 76443,
    "price_change_pct": 2.14
  },
  "has_image": true,
  "verified": true
}
```

***

## Batch Token Lookup

```http theme={null}
POST /tokens/batch
```

Fetches price and analytics data for up to 100 tokens across any combination of supported networks in a single request. This endpoint is ideal for portfolios, watchlists, and any use case where you need to minimise latency and API call count.

<Note>
  The batch endpoint accepts a maximum of 100 tokens per request. If you need data for more tokens, split your list into chunks of 100 and send multiple requests.
</Note>

### Request Body

<ParamField body="tokens" type="array" required>
  An array of token identifier objects. Each object must include both `network` and `address`.

  <Expandable title="Token identifier object">
    <ParamField body="network" type="string" required>
      The network ID the token lives on (e.g. `ethereum`, `solana`).
    </ParamField>

    <ParamField body="address" type="string" required>
      The token's contract address on the specified network.
    </ParamField>
  </Expandable>
</ParamField>

### Code Examples

<CodeGroup>
  ```bash cURL theme={null}
  # Replace the token below with your actual API key from the DexUtils dashboard
  curl -X POST "https://api.dexutils.io/v1/tokens/batch" \
    -H "Authorization: Bearer dxu_sk_live_4f8a2bcd9e1f3a7056c8d2e94b0f1c63" \
    -H "Content-Type: application/json" \
    -d '{
      "tokens": [
        {
          "network": "ethereum",
          "address": "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2"
        },
        {
          "network": "solana",
          "address": "So11111111111111111111111111111111111111112"
        }
      ]
    }'
  ```

  ```python Python theme={null}
  import requests

  # Replace with your actual API key from the DexUtils dashboard
  url = "https://api.dexutils.io/v1/tokens/batch"
  headers = {
      "Authorization": "Bearer dxu_sk_live_4f8a2bcd9e1f3a7056c8d2e94b0f1c63",
      "Content-Type": "application/json",
  }
  payload = {
      "tokens": [
          {
              "network": "ethereum",
              "address": "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2",
          },
          {
              "network": "solana",
              "address": "So11111111111111111111111111111111111111112",
          },
      ]
  }

  response = requests.post(url, json=payload, headers=headers)
  tokens = response.json()

  for token in tokens:
      print(f"{token['symbol']} ({token['network']}): ${token['price_usd']}")
  ```

  ```javascript JavaScript theme={null}
  // Replace with your actual API key from the DexUtils dashboard
  const response = await fetch("https://api.dexutils.io/v1/tokens/batch", {
    method: "POST",
    headers: {
      Authorization: "Bearer dxu_sk_live_4f8a2bcd9e1f3a7056c8d2e94b0f1c63",
      "Content-Type": "application/json",
    },
    body: JSON.stringify({
      tokens: [
        {
          network: "ethereum",
          address: "0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2",
        },
        {
          network: "solana",
          address: "So11111111111111111111111111111111111111112",
        },
      ],
    }),
  });

  const tokens = await response.json();

  tokens.forEach((token) => {
    console.log(`${token.symbol} (${token.network}): $${token.price_usd}`);
  });
  ```
</CodeGroup>

### Response

The batch endpoint returns a flat JSON array. Each element follows the same schema as the single-token response above — including the nested `24h` object. Elements appear in the same order as the input `tokens` array.

<Tip>
  If a token address is not found on the specified network, that position in the response array will be `null`. Always check for `null` entries before accessing response fields.
</Tip>
