Quick answer
Dune indexes major blockchains into SQL tables. Its API executes a saved query (by id, with parameters), polls for completion and returns the result rows, or simply returns the latest cached results. Requests carry the X-Dune-API-Key header and consume credits.
Dune API at a glance
- Pricing
- Free credits; paid plans
- Availability
- Worldwide
- Paper trading
- Not applicable (data only)
- Integration type
- REST + API key
- In AlgoGP
- Design and backtest in AlgoGP, connect the exported code
- Header
X-Dune-API-Key- Flow
- Execute query → poll status → get results
- Python
dune-client
Build a Dune strategy with AlgoGP
AlgoGP does not connect to Dune natively yet. Dune uses plain HTTPS with an API key, so it is a good candidate for a native adapter; it is not built in yet.
- 1
Design and backtest in AlgoGP
Describe the strategy to the copilot and backtest it on years of normalized history. The result does not depend on any vendor.
- 2
Export the Python project
Every project exports
strategy.py,market_data.py,brokers.pyandlive.py. The strategy only sees bars, cash, positions and orders, never a vendor’s wire format. - 3
Plug in Dune
Implement the four adapter methods (
account,positions,submit_market_orderand a candle fetcher) with Dune’s SDK, or keep a built-in platform for paper trading and add Dune when you go live.
Built-in data sources for the same markets: Alpaca, Binance, Coinbase Exchange, Yahoo Finance.
Dune API: frequently asked questions
Is the Dune API free?
The free plan includes monthly credits; heavier use needs a paid plan.
Design and backtest your Dune strategy first
AlgoGP turns an idea into Python and tests it on years of history before you connect it to Dune. The exported code keeps the broker behind four small adapter methods.
- AI copilot writes and revises the rules
- Backtests with realistic costs
- Exported Python ready to wire to Dune
Free plan, no card required.
Dune alternatives
- Glassnode API GuideOn-chain analytics for Bitcoin, Ethereum and more: exchange flows, SOPR, MVRV, holder cohorts and thousands of metrics by API.
- CryptoQuant API GuideOn-chain and exchange-flow data for crypto traders: reserves, netflows, miner flows, funding and the indicators built on them.
- Coin Metrics API GuideCrypto market and on-chain network data: candles, order books, funding, options and thousands of network metrics.
- Messari API GuideCrypto research data: asset profiles, fundamentals, token unlocks, news and AI-summarized intel through the Messari API.
Independent guide. AlgoGP is not affiliated with Dune. Limits, prices and availability change; confirm them in the official documentation. Nothing here is investment advice.