agentis-dev/NFT-Scanner-MCP
If you are the rightful owner of NFT-Scanner-MCP and would like to certify it and/or have it hosted online, please leave a comment on the right or send an email to henry@mcphub.com.
NFT Scanner MCP Server provides real-time blockchain data for NFTs across multiple networks, designed for AI assistants to access live NFT market data, ownership information, and transaction history.
getNFTCollectionDetails
Complete collection stats and metadata
getNFTMetadata
Specific token details and ownership
getNFTTransfers
Transaction history and transfers
getNFTSales
Marketplace sales and pricing data
getWalletNFTs
All NFTs owned by a wallet
NFT Scanner MCP Server
A comprehensive Model Context Protocol (MCP) server that provides real-time blockchain data for NFTs across multiple networks. Built for AI assistants to access live NFT market data, ownership information, and transaction history.
š Features
Real-Time NFT Data
- Collection Analytics: Floor prices, volume, market cap, owner counts
- Live Metadata: Token details, attributes, ownership tracking
- Transaction History: Transfers, sales, marketplace activity
- Multi-chain Support: Ethereum, Polygon, Arbitrum, Optimism
Market Intelligence
- Floor Price Tracking: Real-time prices across OpenSea, LooksRare, Blur
- Sales History: Detailed transaction data with pricing and timestamps
- Collection Search: Find NFT projects by name or description
- Wallet Analysis: Complete NFT portfolio for any address
Data Sources
- Alchemy NFT API - Primary blockchain data
- OpenSea API - Marketplace statistics and events
- NFTScan API - Additional data validation
š Available Tools
Tool | Description | Use Case |
---|---|---|
getNFTCollectionDetails | Complete collection stats and metadata | Market research, portfolio analysis |
getNFTMetadata | Specific token details and ownership | Token verification, trait analysis |
getNFTTransfers | Transaction history and transfers | Ownership tracking, market activity |
getNFTSales | Marketplace sales and pricing data | Price discovery, market trends |
getWalletNFTs | All NFTs owned by a wallet | Portfolio management, holder analysis |
getNFTFloorPrice | Current floor prices across markets | Price monitoring, arbitrage |
searchNFTCollections | Find collections by name/description | Discovery, research |
š ļø Installation & Setup
Prerequisites
- Node.js 18+
- npm or yarn
- API keys (see configuration below)
Quick Start
- Clone and Install
git clone <repository-url>
cd nft-scanner-mcp
npm install
- Configure API Keys
cp env.example .env
# Edit .env with your API keys
- Run the Server
npm start
- Test with Demo
npm test
š API Configuration
Required: Alchemy API Key
# Get free API key at: https://dashboard.alchemy.com/
ALCHEMY_API_KEY=your_alchemy_api_key_here
Optional: Enhanced Data Sources
# OpenSea API (recommended for market data)
OPENSEA_API_KEY=your_opensea_api_key_here
# NFTScan API (additional validation)
NFTSCAN_API_KEY=your_nftscan_api_key_here
Getting API Keys
-
Alchemy (Required)
- Sign up for free account
- Create new app
- Copy API key from dashboard
-
OpenSea (Recommended)
- Apply for API access
- Enhanced marketplace data
-
NFTScan (Optional)
- Additional data source for validation
š” Usage Examples
Get Collection Details
{
"name": "getNFTCollectionDetails",
"arguments": {
"contractAddress": "0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D",
"chain": "ethereum"
}
}
Response:
{
"collectionDetails": {
"name": "Bored Ape Yacht Club",
"totalSupply": "10000",
"marketStats": {
"floorPrice": 15.75,
"totalVolume": 682544.23,
"numOwners": 5420,
"sevenDayVolume": 1205.67
}
}
}
Get NFT Metadata
{
"name": "getNFTMetadata",
"arguments": {
"contractAddress": "0xBC4CA0EdA7647A8aB7C2061c2E118A18a936f13D",
"tokenId": "1000"
}
}
Check Wallet NFTs
{
"name": "getWalletNFTs",
"arguments": {
"walletAddress": "0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045",
"limit": 50
}
}
Search Collections
{
"name": "searchNFTCollections",
"arguments": {
"query": "Azuki",
"limit": 10
}
}
š Supported Networks
Network | Chain ID | Status |
---|---|---|
Ethereum | ethereum | ā Full Support |
Polygon | polygon | ā Full Support |
Arbitrum | arbitrum | ā Full Support |
Optimism | optimism | ā Full Support |
š Data Structure
Collection Details Response
{
timestamp: string;
contractAddress: string;
chain: string;
collectionDetails: {
name: string;
description: string;
totalSupply: number;
symbol: string;
contractType: string;
verified: boolean;
marketStats: {
floorPrice: number;
totalVolume: number;
totalSales: number;
averagePrice: number;
numOwners: number;
oneDayVolume: number;
sevenDayVolume: number;
};
social: {
website: string;
discord: string;
twitter: string;
};
};
}
NFT Metadata Response
{
timestamp: string;
contractAddress: string;
tokenId: string;
metadata: {
name: string;
description: string;
image: string;
attributes: Array<{
trait_type: string;
value: string;
}>;
owner: string;
tokenType: string;
};
}
ā” Performance & Rate Limits
- Built-in Rate Limiting: 1 request per second
- Automatic Retries: Up to 3 retries with exponential backoff
- Request Caching: Smart caching to reduce API calls
- Error Handling: Graceful degradation when APIs are unavailable
šÆ Real-World Applications
For AI Assistants
- Market Analysis: "What's the current floor price of BAYC?"
- Portfolio Tracking: "Show me all NFTs in wallet 0x..."
- Collection Research: "Find information about Azuki collection"
- Transaction Monitoring: "Get recent sales for CryptoPunks"
For Developers
- NFT Portfolio Apps: Real-time wallet tracking
- Market Dashboards: Live collection statistics
- Trading Bots: Floor price monitoring
- Analytics Platforms: Historical transaction data
š§ Development
Project Structure
nft-scanner-mcp/
āāā nft-scanner-mcp-server.js # Main MCP server
āāā demo-nft-scanner-mcp.js # Demo/testing script
āāā package.json # Dependencies
āāā env.example # Environment template
āāā README.md # This file
Running Tests
# Run demo with sample data
npm test
# Start server in development mode
npm run dev
Adding New Features
The server is designed to be extensible. To add new NFT data sources:
- Add new tool definition in
setupToolHandlers()
- Implement the corresponding method
- Update rate limiting and error handling
- Add example usage to demo script
š”ļø Error Handling
The server includes comprehensive error handling:
- API Failures: Automatic fallback to alternative data sources
- Rate Limiting: Exponential backoff with retry logic
- Invalid Addresses: Validation and clear error messages
- Network Issues: Graceful degradation and timeout handling
š Monitoring
All requests include:
- Timestamps: ISO 8601 format
- Data Sources: Clear attribution of data origin
- Request IDs: For debugging and tracking
- Performance Metrics: Response times and success rates
š¤ Contributing
- Fork the repository
- Create feature branch (
git checkout -b feature/amazing-feature
) - Commit changes (
git commit -m 'Add amazing feature'
) - Push to branch (
git push origin feature/amazing-feature
) - Open Pull Request
š License
This project is licensed under the MIT License - see the file for details.
š Related Projects
- Real-time Crypto MCP - Cryptocurrency data
- Model Context Protocol - Official MCP documentation
- Alchemy NFT API - Primary data source
š Support
- Issues: GitHub Issues
- Documentation: MCP Docs
- Community: Discord | Twitter
Built with ā¤ļø for the Web3 community