Query Details
You can query trades either by pool address or by asset address:
- mode: pair - Query trades for a specific pool/pair address
- mode: asset - Query trades across top pools for a token asset
| Parameter | Required | Description |
|---|
blockchain | Yes | Blockchain identifier (e.g., “base”, “ethereum”, “bsc”) |
address | Yes | Token or pool address depending on mode |
mode | No | Query mode: pair (default) or asset |
limit | No | Number of results per page (default: 10, max: 1000) |
offset | No | Offset for pagination (default: 0) |
sortOrder | No | Sort order: asc or desc (default: desc) |
label | No | Filter by wallet label (e.g., PRO_TRADER, SMART_TRADER, FRESH_TRADER, DEV) |
swapTypes | No | Array of swap types to filter (e.g., REGULAR, DEPOSIT, WITHDRAWAL) |
swapSenderAddresses | No | Array of swap sender addresses to filter |
transactionSenderAddresses | No | Array of transaction sender addresses to filter |
minAmountUSD | No | Minimum trade amount in USD |
maxAmountUSD | No | Maximum trade amount in USD |
fromDate | No | Start date for trade filtering (ISO 8601 or Unix timestamp) |
toDate | No | End date for trade filtering (ISO 8601 or Unix timestamp) |
Response Overview
Each item in data[] represents a single trade:
- id: Unique swap identifier
- operation: Swap operation type (regular, deposit, withdrawal)
- type: Trade type (
buy, sell, deposit, or withdrawal)
- baseTokenAmount: Amount of base token traded (formatted)
- baseTokenAmountRaw: Amount of base token traded in smallest units
- baseTokenAmountUSD: USD value of base token traded
- quoteTokenAmount: Amount of quote token traded (formatted)
- quoteTokenAmountRaw: Amount of quote token traded in smallest units
- quoteTokenAmountUSD: USD value of quote token traded
- date: Trade timestamp in milliseconds
- swapSenderAddress: Address that executed the swap
- transactionSenderAddress: Transaction originator address
- blockchain: Blockchain name
- transactionHash: Transaction hash
- marketAddress: Pool/market address where trade occurred
- baseTokenPriceUSD: Base token price in USD at execution
- quoteTokenPriceUSD: Quote token price in USD at execution
- labels: Array of wallet labels (e.g.,
smart-money, pro-trader)
The base token is determined by the baseQuote logic, which identifies the most relevant token in the pair.
When using mode: asset, trades are aggregated from the top 5 pools by liquidity for that token.
Usage Examples
Query trades for a specific pool (pair mode):
curl -X GET "https://api.mobula.io/api/2/token/trades?blockchain=base&address=0x4200000000000000000000000000000000000006&mode=pair&limit=10"
Query trades for a token across all pools (asset mode):
curl -X GET "https://api.mobula.io/api/2/token/trades?blockchain=base&address=0x4200000000000000000000000000000000000006&mode=asset&limit=20"
Query trades with filters:
curl -X POST "https://api.mobula.io/api/2/token/trades" \
-H "Content-Type: application/json" \
-d '{
"blockchain": "base",
"address": "0x4200000000000000000000000000000000000006",
"mode": "asset",
"limit": 50,
"minAmountUSD": 1000,
"label": "SMART_TRADER",
"swapTypes": ["REGULAR"]
}'
Sample Response
{
"data": [
{
"id": "123456789",
"operation": "regular",
"type": "buy",
"baseTokenAmount": 100.5,
"baseTokenAmountRaw": "100500000000000000000",
"baseTokenAmountUSD": 1200.5,
"quoteTokenAmount": 1200.5,
"quoteTokenAmountRaw": "1200500000",
"quoteTokenAmountUSD": 1200.5,
"date": 1699545600000,
"swapSenderAddress": "0xabc123...",
"transactionSenderAddress": "0xdef456...",
"blockchain": "Base",
"transactionHash": "0x789abc...",
"marketAddress": "0x420000...",
"baseTokenPriceUSD": 11.95,
"quoteTokenPriceUSD": 1.0,
"labels": ["smart-money", "smart-trader"]
}
]
}
Special Labels
The label parameter accepts the following values:
- PRO_TRADER: Trades from known professional trading platforms
- SMART_TRADER: Trades from wallets identified as smart traders in the last 7 days
- FRESH_TRADER: Trades from newly funded wallets (within last 24 hours)
- DEV: Trades from token deployer addresses
- Custom labels created via the wallet labels API