Agglayer MCP Server
by colygon
The Agglayer MCP Server facilitates interaction with the Agglayer cross-chain settlement layer. It provides tools for querying information and performing cross-chain operations.
Last updated: N/A
Agglayer MCP Server
This is a Model Context Protocol (MCP) server for interacting with the Agglayer cross-chain settlement layer. Agglayer is a cross-chain settlement layer that connects the liquidity and users of any blockchain for fast, low-cost interoperability and growth.
Features
This MCP server provides tools for:
- Getting information about supported blockchain networks
- Checking token balances across chains
- Performing cross-chain transfers
- Getting liquidity information
Installation
# Clone the repository
git clone <repository-url>
cd agglayer-mcp-server
# Install dependencies
npm install
# Build the project
npm run build
Configuration
The server can be configured using environment variables:
AGGLAYER_API_KEY
: Your Agglayer API key (defaults to 'demo_key' for development)
Usage
Starting the Server
npm start
MCP Integration
To use this server with Claude or other MCP-compatible systems, add it to your MCP settings configuration file:
{
"mcpServers": {
"agglayer": {
"command": "node",
"args": ["/path/to/agglayer-mcp-server/build/index.js"],
"env": {
"AGGLAYER_API_KEY": "your-api-key"
},
"disabled": false,
"autoApprove": []
}
}
}
Available Tools
get_chain_info
Get information about supported blockchain networks.
{
"chain": "ethereum" // Optional, returns all chains if not specified
}
get_token_balance
Get token balance for an address on a specific chain.
{
"chain": "ethereum",
"address": "0x...",
"token": "USDC" // Optional, returns all token balances if not specified
}
cross_chain_transfer
Perform a cross-chain token transfer.
{
"sourceChain": "ethereum",
"destinationChain": "polygon",
"token": "USDC",
"amount": "100.0",
"fromAddress": "0x...",
"toAddress": "0x..."
}
get_liquidity_info
Get liquidity information across chains.
{
"chain": "ethereum", // Optional, returns all chains if not specified
"token": "USDC" // Optional, returns all tokens if not specified
}
Available Resources
agglayer://chains
: List of all supported blockchain networksagglayer://tokens
: List of all supported tokensagglayer://chains/{chainId}
: Information about a specific blockchain networkagglayer://tokens/{tokenSymbol}
: Information about a specific token
Development
# Run in development mode with auto-reloading
npm run dev
License
ISC