DuneLink
A modern bridge connecting Dune Analytics data to intelligent agents through Model Control Protocol (MCP).
Overview
DuneLink enables seamless integration of blockchain data analytics into your AI applications. By leveraging Dune Analytics' powerful query capabilities with the Model Control Protocol, this service allows LLMs and other AI systems to access on-chain data through simple, natural language interactions.
Core Capabilities
Data Retrieval Tools
Tool | Description | Use Case |
---|---|---|
get_latest_result | Retrieves pre-computed query results | Quick access to existing data |
run_query | Executes a query on-demand | Real-time data analysis |
Data Format
All data is returned in CSV format, providing:
- Universal compatibility
- Easy parsing by most data analysis tools
- Human-readable output
Getting Started
System Requirements
- Python 3.10 or higher
- Valid Dune Analytics API key (Get yours here)
Quick Setup
- Clone & Navigate
- Environment Setup
- Configure API Access
Usage
Running the Service
DuneLink offers two ways to run:
As MCP Service
This starts the MCP service on default port 8000.
As Web Server
This provides access to the web interface and REST API endpoints.
Integrating with Applications
MCP Client Integration
REST API
Endpoint | Method | Description |
---|---|---|
/dune/health | GET | Service health check |
/dune/query/{query_id}/latest | GET | Retrieve latest results |
/dune/query/{query_id}/execute | POST | Run a query |
Example REST Call:
Architecture
Advanced Configuration
Environment Variables
Variable | Purpose | Default |
---|---|---|
DUNE_API_KEY | Authentication for Dune API | None (Required) |
PORT | Server port | 8000 |
Performance Tuning
For high-volume query execution:
Troubleshooting
Common issues and solutions:
Problem | Solution |
---|---|
API Key errors | Ensure .env file exists with valid key |
Timeout errors | Increase timeout for complex queries |
CSV parsing issues | Check query returns proper tabular data |
Contributing
Contributions are welcome! Please follow these steps:
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature
- Commit your changes:
git commit -am 'Add some amazing feature'
- Push to the branch:
git push origin feature/amazing-feature
- Open a Pull Request
License
This project is released under the MIT License. See LICENSE
file for details.
Acknowledgments
- Built with FastMCP
- Query functionality powered by Dune Analytics
This server cannot be installed
remote-capable server
The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.
モデル制御プロトコルを介して Dune Analytics ブロックチェーン データを AI アプリケーションに接続するブリッジ。これにより、LLM は自然言語による対話を通じてオンチェーン データにアクセスできるようになります。
Related MCP Servers
- -securityAlicense-qualityA mcp server that bridges Dune Analytics data to AI agents.Last updated -23PythonMIT License
- AsecurityFlicenseAqualityImplements the Model Context Protocol to allow AI models to access and interact with blockchain data, including reading contract states, retrieving events, and accessing transaction information across various networks.Last updated -1062160TypeScript
Nodit MCP Serverofficial
AsecurityAlicenseAqualityConnects AI agents and developers to structured blockchain data across multiple networks through Nodit's Web3 infrastructure, enabling easy querying, analysis and interaction with blockchain ecosystems without specialized development expertise.Last updated -962713TypeScriptApache 2.0- -securityAlicense-qualityA Model Context Protocol server that connects AI agents to Dune Analytics data, providing access to DEX metrics, EigenLayer statistics, and Solana token balances through structured tools.Last updated -2TypeScriptMIT License