solanatestp1p2p3p4

Returns 200000 DEX trades by token on Solana, where block time since 2024-11-18 and trade amount in USD is at least 50: currency symbol, currency mint address, currency name and trade price.

By Jackson Cameron · saved 18 November 2024 · run 1 time · Bitquery API v2

What it returns

Filters

The query

query MyQuery($time_30min_ago: DateTime, $time_22p5min_ago: DateTime, $time_15min_ago: DateTime, $time_7p5min_ago: DateTime) {
  Solana(network: solana) {
    DEXTradeByTokens(
      where: {Block: {Time: {since: $time_30min_ago}}, any: [{Trade: {Side: {Currency: {MintAddress: {is: "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"}}}}}, {Trade: {Currency: {MintAddress: {not: "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"}}, Side: {Currency: {MintAddress: {is: "So11111111111111111111111111111111111111112"}}}}}, {Trade: {Currency: {MintAddress: {notIn: ["So11111111111111111111111111111111111111112", "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"]}}, Side: {Currency: {MintAddress: {notIn: ["So11111111111111111111111111111111111111112", "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v"]}}}}}], Trade: {AmountInUSD: {ge: "50"}}}
      limit: {count: 200000}
    ) {
      Trade {
        Currency {
          Symbol
          MintAddress
          Name
        }
        p1: Price(minimum: Block_Time)
        p2: Price(minimum: Block_Time, if: {Block: {Time: {after: $time_22p5min_ago}}})
        p3: Price(minimum: Block_Time, if: {Block: {Time: {after: $time_15min_ago}}})
        p4: Price(minimum: Block_Time, if: {Block: {Time: {after: $time_7p5min_ago}}})
        end: Price(maximum: Block_Time)
      }
    }
  }
}

Variables

{"time_30min_ago": "2024-11-18T16:30:00Z", "time_22p5min_ago": "2024-11-17T16:07:30Z", "time_15min_ago": "2024-11-18T17:00:00Z", "time_7p5min_ago": "2024-11-17T16:22:30Z"}

Similar queries