LargestPurchasesAndSalesOnPump

Returns 2 DEX trades by token on Solana, where currency mint address is not 111111…1111, DEX protocol name is pump and block time after 2024-01-24, sorted by buy volume, highest first: trade price, currency mint address and sum of trade side amount in USD.

By Jacob · saved 24 January 2025 · Bitquery API v2

What it returns

Filters

The query

query LargestPurchasesAndSalesOnPump($startTime: DateTime) {
  Solana(dataset: realtime) {
    DEXTradeByTokens(
      where: {Block: {Time: {after: $startTime}}, Trade: {Dex: {ProtocolName: {is: "pump"}}, Currency: {MintAddress: {notIn: "11111111111111111111111111111111"}}}}
      limit: {count: 2}
      orderBy: {descendingByField: "buy_volume"}
    ) {
      # trades: count(distinct: Block_Time, if: {Block: {Time: {after: $startTime}}})
      Trade {
        start: Price(minimum: Block_Time)
        end: Price(maximum: Block_Time)
        Currency {
          MintAddress
        }
      }
      buy_volume: sum(
        of: Trade_Side_AmountInUSD
        if: {Trade: {Side: {Type: {is: buy}}}}
      )
      sell_volume: sum(
        of: Trade_Side_AmountInUSD
        if: {Trade: {Side: {Type: {is: sell}}}}
      )
    }
  }
}

Variables

{
  "startTime": "2024-01-24T08:00:00Z",
  "endTime": "2024-01-24T09:00:00Z"
}

Similar queries