Skip to main content

Query Details

Required Parameters

  • wallet - Wallet address to query trades for (supports EVM and Solana addresses)

Optional Parameters

ParameterTypeDefaultDescription
walletsstring-Comma-separated list of additional wallet addresses
tokenAddressstring-Filter trades involving this token contract address
blockchainsstring-Comma-separated list of blockchain IDs (e.g., "ethereum,base,solana:solana")
limitnumber50Number of trades per page (min: 1, max: 100)
offsetnumber0Offset for pagination
orderstring”desc”Sort order by date: "asc" or "desc"
fromnumber-Start timestamp in milliseconds
tonumber-End timestamp in milliseconds
The endpoint also supports POST requests with the same parameters in the JSON body. Useful for complex queries or when passing multiple wallet addresses.

Pagination

Pagination is offset-based, consistent with other V2 wallet endpoints (/wallet/activity, /wallet/positions).
  • Use offset and limit to control which slice of results you receive
  • page in the response is computed as Math.floor(offset / limit) + 1
The response includes a pagination object:
{
  "pagination": {
    "page": 1,
    "offset": 0,
    "limit": 50,
    "pageEntries": 42
  }
}
pageEntries indicates the actual number of trades returned (may be less than limit on the last page).

Response Overview

Each item in data[] represents a consolidated swap trade:
FieldTypeDescription
idstringUnique trade identifier
typestringTrade direction: "buy" or "sell" (relative to base token)
operationstringSwap type: "regular", "mev", etc.
baseTokenAmountnumberAmount of base token traded (formatted with decimals)
baseTokenAmountRawstringRaw amount of base token in smallest units
baseTokenAmountUSDnumberUSD value of the trade
quoteTokenAmountnumberAmount of quote token traded (formatted)
quoteTokenAmountRawstringRaw amount of quote token in smallest units
quoteTokenAmountUSDnumberUSD value of the quote side
baseTokenPriceUSDnumberBase token price at trade time
quoteTokenPriceUSDnumberQuote token price at trade time
datenumberTrade timestamp in milliseconds
blockchainstringBlockchain name (e.g., "Ethereum", "Solana")
transactionHashstringTransaction hash
marketAddressstringPool/market contract address
transactionSenderAddressstringWallet that sent the transaction
swapSenderAddressstringAddress that initiated the swap (may differ for AA wallets)
swapRecipientstring|nullSwap beneficiary address (important for Account Abstraction)
baseTokenobject|null{ address, name, symbol, logo, decimals }
quoteTokenobject|null{ address, name, symbol, logo, decimals }
labelsstring[]Wallet labels (e.g., "sniper", "insider", "smart-money")
platformobject|null{ id, name, logo } - Trading platform/aggregator
totalFeesUSDnumber|nullTotal fees paid in USD
gasFeesUSDnumber|nullGas fees in USD
platformFeesUSDnumber|nullPlatform/aggregator fees in USD
mevFeesUSDnumber|nullMEV/priority fees in USD
preBalanceBaseTokenstring|nullPre-swap raw balance of base token
preBalanceQuoteTokenstring|nullPre-swap raw balance of quote token
postBalanceBaseTokenstring|nullPost-swap raw balance of base token
postBalanceQuoteTokenstring|nullPost-swap raw balance of quote token

Usage Examples

Basic: single wallet

curl -X GET "https://api.mobula.io/api/2/wallet/trades?wallet=0xaF88370abD82EC6943cdB3D4ec7b764B92c35B43" \
  -H "Authorization: YOUR_API_KEY"

Solana wallet with limit

curl -X GET "https://api.mobula.io/api/2/wallet/trades?wallet=4tqMHgB8jjbTgefVfqtVFYzyfQz2LQ8T3E922ePmt6kZ&limit=10" \
  -H "Authorization: YOUR_API_KEY"

Filter by token and blockchains

curl -X GET "https://api.mobula.io/api/2/wallet/trades?wallet=0xaF88370abD82EC6943cdB3D4ec7b764B92c35B43&tokenAddress=0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2&blockchains=ethereum&limit=20" \
  -H "Authorization: YOUR_API_KEY"

Pagination with offset

curl -X GET "https://api.mobula.io/api/2/wallet/trades?wallet=0xaF88370abD82EC6943cdB3D4ec7b764B92c35B43&limit=10&offset=10&order=desc" \
  -H "Authorization: YOUR_API_KEY"

POST with multiple wallets

curl -X POST "https://api.mobula.io/api/2/wallet/trades" \
  -H "Authorization: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "wallet": "0xaF88370abD82EC6943cdB3D4ec7b764B92c35B43",
    "wallets": "0xaF88370abD82EC6943cdB3D4ec7b764B92c35B43,4tqMHgB8jjbTgefVfqtVFYzyfQz2LQ8T3E922ePmt6kZ",
    "limit": 20
  }'

Date range filter

curl -X GET "https://api.mobula.io/api/2/wallet/trades?wallet=0xaF88370abD82EC6943cdB3D4ec7b764B92c35B43&from=1704067200000&to=1735689600000&order=asc" \
  -H "Authorization: YOUR_API_KEY"

Sample Response

{
  "data": [
    {
      "id": "22039719729",
      "operation": "regular",
      "type": "sell",
      "baseTokenAmount": 10289426.248783976,
      "baseTokenAmountRaw": "10289426248783975872330870",
      "baseTokenAmountUSD": 1953.59,
      "quoteTokenAmount": 0.6675364467,
      "quoteTokenAmountRaw": "667536446729330304",
      "quoteTokenAmountUSD": 1953.59,
      "preBalanceBaseToken": null,
      "preBalanceQuoteToken": null,
      "postBalanceBaseToken": null,
      "postBalanceQuoteToken": null,
      "date": 1768290275000,
      "swapSenderAddress": "0xd2b37ade14708bf18904047b1e31f8166d39612b",
      "transactionSenderAddress": "0xd8da6bf26964af9d7eed9e03e53415d37aa96045",
      "swapRecipient": "0xd2b37ade14708bf18904047b1e31f8166d39612b",
      "blockchain": "Ethereum",
      "transactionHash": "0x07dcb584b301f2b8d445e504ff64f27ea8d8a9c9d58329145a0813c9d0f18dd0",
      "marketAddress": "0x79786aa97633871f4ea737b3099cf911598d65b7",
      "baseTokenPriceUSD": 0.00018986,
      "quoteTokenPriceUSD": 3124.15,
      "labels": [],
      "baseToken": {
        "address": "0x9f277edfc463ebaa3d2a6274b01177697e910391",
        "name": "Miniature Woolly Mammoth",
        "symbol": "WOOLLY",
        "logo": "https://metadata.mobula.io/assets/logos/evm_1_0x9f277edfc463ebaa3d2a6274b01177697e910391.webp",
        "decimals": 18
      },
      "quoteToken": {
        "address": "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
        "name": "Ethereum",
        "symbol": "ETH",
        "logo": "https://metadata.mobula.io/assets/logos/evm_1_0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2.webp",
        "decimals": 18
      },
      "platform": null,
      "totalFeesUSD": 0.058,
      "gasFeesUSD": 0.058,
      "platformFeesUSD": 0,
      "mevFeesUSD": 0
    }
  ],
  "pagination": {
    "page": 1,
    "offset": 0,
    "limit": 50,
    "pageEntries": 1
  }
}
The tokenAddress filter uses the raw contract address. Make sure to pass the correct address for the blockchain you’re querying (e.g., WETH on Ethereum, SOL on Solana).
Use order=asc with from to efficiently scan trade history forward from a specific point in time.