An MCP server that provides real-time access to Chainlink's decentralized on-chain price feeds, optimized for seamless integration into AI agents and autonomous systems - Query Latest Price: Fetch the latest price for a specified price feed pair (e.g., FIL/ETH) on a given chain (e.g., ethereum), including price, decimals, round ID, and timestamp. - Query Price by Round ID: Retrieve price data for
Add this skill
npx mdskills install kukapay/chainlink-feeds-mcpProvides comprehensive access to 329 Chainlink price feeds across 9 chains with clear documentation
1# Chainlink Feeds MCP Server23An MCP server that provides real-time access to Chainlink's decentralized on-chain price feeds, optimized for seamless integration into AI agents and autonomous systems45<a href="https://glama.ai/mcp/servers/@kukapay/chainlink-feeds-mcp">6 <img width="380" height="200" src="https://glama.ai/mcp/servers/@kukapay/chainlink-feeds-mcp/badge" alt="chainlink-feeds-mcp MCP server" />7</a>89[](https://opensource.org/licenses/MIT)10[](https://nodejs.org/)111213## Features1415- **Query Latest Price**: Fetch the latest price for a specified price feed pair (e.g., `FIL/ETH`) on a given chain (e.g., `ethereum`), including price, decimals, round ID, and timestamp.16- **Query Price by Round ID**: Retrieve price data for a specific round ID (currently a placeholder due to on-chain historical data limitations).17- **List Supported Chains**: Get a comma-separated list of supported blockchain networks (e.g., `ethereum,base`).18- **List All Feeds**: Retrieve a Markdown-formatted list of all chains and their price feed names (e.g., `- ethereum: FIL/ETH,FDUSD/USD`).19- **List Feeds by Chain**: Obtain a comma-separated list of price feed names for a specific chain (e.g., `FIL/ETH,FDUSD/USD` for `ethereum`).20- **Configurable Feeds**: Define price feeds and RPC endpoints in a `feeds.json` file, supporting multiple chains and feed categories.2122## Supported Chains and Feeds2324The server supports **9 blockchain networks** with a total of **329 price feeds**, as defined in `feeds.json`:2526- **Ethereum**: 107 feeds (e.g., `FIL/ETH`, `BTC/USD`, `USDC/USD`)27- **BNB Chain (bsc)**: 80 feeds (e.g., `DOT/USD`, `CAKE/USD`, `BUSD/BNB`)28- **Base**: 52 feeds (e.g., `AXL/USD`, `USDC/USD`, `WIF/USD`)29- **Starknet**: 9 feeds (e.g., `ETH/USD`, `BTC/USD`, `WSTETH/ETH`)30- **Linea**: 15 feeds (e.g., `ETH/USD`, `FOXY/USD`, `MATIC/USD`)31- **Mantle**: 6 feeds (e.g., `MNT/USD`, `USDT/USD`, `BTC/USD`)32- **Scroll**: 22 feeds (e.g., `SCR/USD`, `STETH/USD`, `WBTC/BTC`)33- **zkSync**: 16 feeds (e.g., `ZK/USD`, `PEPE/USD`, `TRUMP/USD`)34- **Celo**: 22 feeds (e.g., `CELO/USD`, `CUSD/USD`, `NGN/USD`)3536Additional chains and feeds can be added by updating `feeds.json` with new network configurations and proxy addresses from Chainlink's Price Feeds documentation.3738## Prerequisites3940- **Node.js**: Version 18.x or higher.41- **npm**: For dependency installation.42- **Infura API Key**: Obtain a key from the [MetaMask Developer Dashboard](https://infura.io/) with access to supported networks (e.g., Ethereum, Base).43- **MCP Inspector** (optional): For testing the server locally.44- **Claude Desktop** (optional): For integration with Anthropic's Claude interface.4546## Installation47481. **Clone the Repository**:49 ```bash50 git clone https://github.com/kukapay/chainlink-feeds-mcp.git51 cd chainlink-feeds-mcp52 ```53542. **Install Dependencies**:55 ```bash56 npm install57 ```58 The project requires:59 - `@modelcontextprotocol/sdk`: For MCP server functionality.60 - `ethers`: Version 6.x for blockchain interactions.61 - `zod`: For input validation.62 - `dotenv`: For environment variable management.63643. **Configure MCP Client**:65 To use this server with an MCP client like Claude Desktop, add the following to your config file (or equivalent):66 ```json67 {68 "mcpServers": {69 "chainlink-feeds-mcp": {70 "command": "node",71 "args": ["path/to/chainlink-feeds-mcp/index.js"],72 "env": { "INFURA_API_KEY": "your_api_key_here" }73 }74 }75 }76 ```77## Usage7879The server exposes five tools via the MCP protocol, accessible through **Claude Desktop** (for natural language queries) or **MCP Inspector** (for JSON inputs). Below are the tools, with examples in both natural language (via Claude Desktop) and JSON formats.8081### Tool: `getLatestPrice`8283- **Description**: Fetches the latest price for a given pair on a specified chain, returns a JSON object like this:84 ```json85 {86 "chain": "ethereum",87 "pair": "FIL/ETH",88 "price": 0.01234,89 "decimals": 18,90 "roundId": "123456",91 "timestamp": "2025-04-17T12:00:00.000Z",92 "proxyAddress": "0x0606Be69451B1C9861Ac6b3626b99093b713E801",93 "feedCategory": "medium"94 }95 ```9697- **Parameters**:98 - `pair` (string): The price feed pair, e.g., `FIL/ETH`.99 - `chain` (string): The blockchain network, e.g., `ethereum`.100101- **Natural Language Example (Claude Desktop)**:102103 > **Input**: "What¡¯s the latest FIL/ETH price on Ethereum?"104105 > **Output**: "The latest FIL/ETH price on Ethereum is 0.01234, with 18 decimals, round ID 123456, updated at 2025-04-17 12:00:00 UTC."106107108### Tool: `queryPriceByRound`109110- **Description**: Queries the price for a given pair and round ID on a specified chain, returns a JSON object like this:111 ```json112 {113 "chain": "ethereum",114 "pair": "FDUSD/USD",115 "price": 1.0001,116 "decimals": 8,117 "roundId": "123",118 "timestamp": "2025-04-17T12:00:00.000Z",119 "proxyAddress": "0xfAA9147190c2C2cc5B8387B4f49016bDB3380572",120 "feedCategory": "medium"121 }122 ```123124125- **Parameters**:126 - `roundId` (string): The round ID for the price data.127 - `pair` (string): The price feed pair, e.g., `FDUSD/USD`.128 - `chain` (string): The blockchain network, e.g., `ethereum`.129130- **Natural Language Example (Claude Desktop)**:131132 > **Input**: "Can you get the FDUSD/USD price for round ID 123 on Ethereum?"133134 > **Output**: "For round ID 123, the FDUSD/USD price on Ethereum is 1.0001, with 8 decimals, updated at 2025-04-17 12:00:00 UTC. Note: This is a placeholder response due to historical data limitations."135136### Tool: `listSupportedChains`137138- **Description**: Returns a comma-separated list of all supported blockchain networks.139140- **Parameters**: None.141142- **Natural Language Example (Claude Desktop)**:143144 > **Input**: "Which blockchain networks does this server support?"145146 > **Output**: "The server supports the following networks: ethereum, bsc, base, starknet, linea, mantle, scroll, zksync, celo."147148149### Tool: `listSupportedFeeds`150151- **Description**: Returns a Markdown list of all supported chains and their price feed names.152153- **Parameters**: None.154155- **Natural Language Example (Claude Desktop)**:156157 > **Input**: "Can you list all the price feeds supported by the server?"158159 > **Output**: "Here are the supported price feeds by chain:160 - Ethereum: FIL/ETH, FDUSD/USD, UNI/ETH, ...161 - BNB Chain: DOT/USD, CAKE/USD, BUSD/BNB, ...162 - Base: AXL/USD, USDC/USD, WIF/USD, ...163 - Starknet: ETH/USD, BTC/USD, WSTETH/ETH, ...164 - Linea: ETH/USD, FOXY/USD, MATIC/USD, ...165 - Mantle: MNT/USD, USDT/USD, BTC/USD, ...166 - Scroll: SCR/USD, STETH/USD, WBTC/BTC, ...167 - zkSync: ZK/USD, PEPE/USD, TRUMP/USD, ...168 - Celo: CELO/USD, CUSD/USD, NGN/USD, ..."169170171### Tool: `listSupportedFeedsByChain`172173- **Description**: Returns a comma-separated list of price feed names for a specified blockchain network.174175- **Parameters**:176 - `chain` (string): The blockchain network, e.g., `base`.177178- **Natural Language Example (Claude Desktop)**:179 > **Input**: "What price feeds are available on the Base chain?"180181 > **Output**: "The Base chain supports the following price feeds: AXL/USD, USDC/USD, WIF/USD, CBETH/ETH, ..."182183184## License185186This project is licensed under the [MIT License](LICENSE).
Full transparency — inspect the skill content before installing.