Agnostic Documentation
  • 👋Welcome to Agnostic
  • Overview
    • 💡Introducing Agnostic
    • ✨Our Features
  • API
    • Execution Layer
      • Blocks
    • Smart-contracts
      • EVM Events
      • EVM Calls
    • DeFi
      • Trades
      • Liquidity Events
      • Liquidity Snapshots
    • Token
      • Balances
      • Total Supplies
  • Tutorials
    • 🦄Uniswap V3
      • Definition
      • Explore
      • Apify
    • 🤑Portfolio tracker
  • Fundamentals
    • 📈Data visualization
      • 👨‍🔬Create your first chart
    • 👷Building API
    • 💻HTTP Interface
      • Authentication
    • 🔑Authentication details
      • PostgreSQL
      • HTTP
    • 📎Understanding Projects
    • 🛠️Collaborate with your team
      • 📝Setting permissions
      • 🧑Inviting Members
Powered by GitBook
On this page
  1. Tutorials
  2. Uniswap V3

Explore

PreviousDefinitionNextApify

Last updated 11 months ago

To explore the Agnostic data ocean, you can use a wide range of tools from psql to Grafana and, of course, the integrated data visualization tool from Agnostic.

Let's break down the query with a few comments:

SELECT
  date_trunc('hour', timestamp) as chart_x, -- we trunc timestamp to hour
  1 / (
    pow (1.0001, avg(input_6_value_int32)) -- we apply our formula to the sixth parameter of the signature: the tick
    / pow (10, 18 - 6) -- we consider each token decimals here
  ) as chart_y 
FROM
  evm_events_ethereum_mainnet -- the event data collection for the Ethereum mainnet
WHERE
  address = '0x88e6a0c2ddd26feeb64f039a2c41296fcb3f5640' -- the address of the ETH/USDC pool
  and signature = 'Swap(address,address,int256,int256,uint160,uint128,int24)' -- filter the right signature
  and chart_x >= '2023-08-01'
GROUP BY
  chart_x
ORDER BY
  chart_x ASC

🦄
Token price from Uniswap events