The Alchemy MCP Server enables AI agents to interact with Alchemy's blockchain APIs for querying and retrieving blockchain data across multiple networks. Key capabilities include:
- Fetching current and historical token prices by symbol (e.g., BTC, ETH) or contract address, with support for natural language timeframes (e.g., "last week")
- Retrieving token and NFT ownership information across multiple blockchain networks
- Accessing transaction history and asset transfers for specific wallet addresses, with pagination options
- Querying NFT contract data and filtering results based on metadata or spam confidence levels
- Supporting time-based queries through natural language processing
- Providing a visual debugging interface with the MCP Inspector for testing methods and viewing responses
Enables AI agents to query Alchemy's blockchain APIs for token prices, NFT ownership, transaction history, token balances across multiple blockchain networks, asset transfers, and other blockchain data without writing code.
Provides access to Bitcoin price data and history through Alchemy's APIs.
Allows querying the Ethereum blockchain for transaction history, token balances, NFT ownership, and token prices through Alchemy's APIs.
Alchemy MCP Server
A Model Context Protocol (MCP) server that enables AI agents to interact with Alchemy's blockchain APIs in a structured way. This allows agents to query blockchain data directly without writing any code.
General Usage
This MCP server creates a bridge between AI agents and Alchemy's blockchain APIs, allowing agents to:
- Query token prices and price history (including flexible time frame queries)
- Get NFT ownership information and contract data
- View transaction history across multiple networks
- Check token balances across multiple blockchain networks
- Retrieve detailed asset transfers with filtering
- Send transactions via Smart Contract Accounts (requires configured wallet agent server)
- Execute token swaps via DEX protocols (requires configured wallet agent server)
- And more!
Quick Setup
To quickly set up the MCP server, use the following configuration in your MCP config file (typically in Claude Desktop or Cursor settings):
This configuration allows you to use the server without manually cloning the repository.
Environment Variables
The MCP server requires the following environment variable:
ALCHEMY_API_KEY
- Your Alchemy API key (required for all blockchain data queries)
For transaction and swap functionality, you must also configure:
AGENT_WALLET_SERVER
- URL of a configured wallet agent server that handles Smart Contract Account operations
⚠️ Important: The sendTransaction
and swap
methods will not function without a properly configured wallet agent server. These methods require external wallet infrastructure to handle signing and broadcasting transactions.
Available Methods
You can prompt your AI agent to use the following methods:
Token Price Methods
- fetchTokenPriceBySymbol
- Gets current price data for tokens by symbol
- Example: "What's the current price of ETH and BTC?"
- fetchTokenPriceByAddress
- Gets current price data for tokens by contract address
- Example: "What's the price of the token at address 0x1234...5678 on Ethereum mainnet?"
- fetchTokenPriceHistoryBySymbol
- Gets historical price data for tokens with specific date ranges
- Example: "Show me BTC price history from Jan 1 to Feb 1, 2023, with daily intervals"
- fetchTokenPriceHistoryByTimeFrame
- Gets historical price data using flexible time frames or natural language
- Example: "Show me ETH price for the last week" or "Get BTC price for the past 30 days"
Multichain Token Methods
- fetchTokensOwnedByMultichainAddresses
- Gets token balances for addresses across multiple networks
- Example: "What tokens does 0xabc...123 hold on Ethereum and Base?"
Transaction History Methods
- fetchAddressTransactionHistory
- Gets transaction history for addresses across multiple networks
- Example: "Show recent transactions for wallet 0xdef...456 on Ethereum"
- fetchTransfers
- Gets detailed asset transfer data with advanced filtering options
- Example: "Show me all ERC-20 transfers to or from 0xghi...789"
NFT Methods
- fetchNftsOwnedByMultichainAddresses
- Gets all NFTs owned by addresses with spam filtering
- Example: "What NFTs does 0xjkl...012 own?"
- fetchNftContractDataByMultichainAddress
- Gets NFT contract data for addresses
- Example: "What NFT collections does 0xmno...345 have tokens from?"
Transaction Methods
- sendTransaction
- Sends transactions via Smart Contract Accounts
- ⚠️ Important: Requires a configured wallet agent server with
AGENT_WALLET_SERVER
environment variable - Example: "Send 0.1 ETH to 0xpqr...678"
Swap Methods
- swap
- Executes token swaps via DEX protocols (Uniswap)
- ⚠️ Important: Requires a configured wallet agent server with
AGENT_WALLET_SERVER
environment variable - Example: "Swap 100 USDC for ETH"
Local Development and Open Source Contributions
Installation
- Clone the repository
- Install dependencies
Development
Building for Production
Using the MCP Inspector for Debugging
The MCP Inspector helps you debug your MCP server by providing a visual interface to test your methods:
This will start the MCP Inspector which you can access in your browser. It allows you to:
- See all available methods
- Test methods with different parameters
- View the response data
- Debug issues with your MCP server
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
License
This MCP server is licensed under the MIT License. This means you are free to use, modify, and distribute the software, subject to the terms and conditions of the MIT License.
Example Prompts
Here are some example prompts you can use with your AI agent:
API Reference
For more information about Alchemy's APIs, refer to:
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.
Tools
Alchemy MCP Server
Related MCP Servers
- Python
- RustMIT License
- TypeScriptMIT License
- JavaScriptMIT License