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

# Get Top Pools by Token

Retrieves top DEX pools containing a specific token, ranked by volume*liquidity by default. Returns pricing, volumes, transaction counts, and liquidity; sortable by various metrics with pagination. Ideal for: finding best liquidity for a token, comparing trading venues, token pool discovery.

![Get Top Pools by Token logo](https://ai-icon.b3.fun/logo/coingecko)
Catalog action Blockchain Data

Retrieves top DEX pools containing a specific token, ranked by volume*liquidity by default. Returns pricing, volumes, transaction counts, and liquidity; sortable by various metrics with pagination. Ideal for: finding best liquidity for a token, comparing trading venues, token pool discovery.


## At a Glance

| Field | Value |
| --- | --- |
| Action ID | `coingecko-get-top-pools-token` |
| Category | Blockchain Data |
| Connector | Not required |
| Requires gas | No |
| Funds movement | None declared |
| Tags | `coingecko`, `onchain`, `pool`, `token`, `dex`, `read` |

## Payload Schema

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `network` | `string` | Yes | Network ID \(e.g., 'eth', 'bsc', 'polygon_pos'\). |
| `tokenAddress` | `string` | Yes | Token contract address. |
| `include` | `string` | No | Attributes to include: base_token, quote_token, dex \(comma-separated\). |
| `includeInactiveSource` | `boolean` | No | Include inactive pool tokens using most recent swap. |
| `page` | `number` | No | Page number for pagination \(default: 1\). |
| `sort` | `string` | No | Sort order: h24_volume_usd_liquidity_desc, h24_tx_count_desc, h24_volume_usd_desc. |

## Result Schema

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `pools` | `array` | Yes | List of top pools containing this token |

## Examples

**Workflow node**

```json
{
  "type": "coingecko-get-top-pools-token",
  "payload": {
    "network": "example-network",
    "tokenAddress": "0x0000000000000000000000000000000000000000"
  },
  "children": []
}
```
  **Test with API**

```bash
curl -X POST "https://api.b3os.org/v1/actions/coingecko-get-top-pools-token/test" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "inputs": {
    "network": "example-network",
    "tokenAddress": "0x0000000000000000000000000000000000000000"
  }
}'
```

**Use expressions for dynamic values**

Payload fields can use workflow expressions such as `{{$trigger.body.amount}}`, `{{$nodes.fetch.result.price}}`, and `{{$props.asset}}` when the value should come from a trigger, prior node, or reusable workflow prop.