Range is the industry’s most comprehensive blockchain risk and intelligence platform, delivering real-time security, sanctions compliance, cross-chain monitoring, and forensic capabilities purpose-built for institutional digital asset operations.
Range MCP Server
A Model Context Protocol (MCP) server that provides blockchain intelligence capabilities through Range's APIs. This server enables AI assistants to access Range's Data API and Risk API for blockchain analytics, risk assessment, and compliance operations.
🔐 Security & API Key Setup
IMPORTANT: This server requires your own Range API key. No API keys are included in this codebase for security reasons.
Getting Your Range API Key
-
Create a Range Account:
- Visit https://app.range.org
- Sign up for an account or log in if you already have one
-
Generate API Key:
- Navigate to Settings → API Keys
- Click "Generate New API Key"
- Copy your API key securely
-
Configure Environment:
- Copy
.env.exampleto.env - Replace
your_range_api_key_herewith your actual API key - NEVER commit your
.envfile to version control
- Copy
Environment Configuration
# Copy the example file
cp .env.example .env
# Edit the .env file with your API key
# RANGE_API_KEY=your_actual_api_key_here
Required environment variables:
RANGE_API_KEY: Your Range API key (required)RANGE_BASE_URL: API base URL (optional, defaults to production)PORT: Server port (optional, Railway sets automatically)LOG_LEVEL: Logging level (optional, defaults to 'info')
🚀 Quick Start
Local Development
-
Install Dependencies:
npm install -
Configure Environment:
cp .env.example .env # Edit .env with your Range API key -
Run Development Server:
npm run dev
Railway Deployment
-
Fork this Repository
-
Connect to Railway:
- Visit railway.app
- Connect your GitHub account
- Deploy from your forked repository
-
Set Environment Variables in Railway:
- Go to your Railway project dashboard
- Navigate to Variables tab
- Add
RANGE_API_KEYwith your API key - Optionally set other environment variables
📋 Available Scripts
npm run build- Build the TypeScript projectnpm start- Start the production servernpm run dev- Start development server with hot reloadnpm test- Run testsnpm run test:watch- Run tests in watch modenpm run test:coverage- Run tests with coverage reportnpm run lint- Run ESLintnpm run lint:fix- Fix ESLint issues automatically
🔧 Development
Project Structure
src/
├── index.ts # Main entry point
├── config/ # Configuration management
├── api/ # Range API client
├── mcp/ # MCP server implementation
├── tools/ # MCP tool handlers
└── utils/ # Utility functions
Testing
The project uses Jest for unit testing and fast-check for property-based testing:
# Run all tests
npm test
# Run tests with coverage
npm run test:coverage
# Run tests in watch mode
npm run test:watch
🛡️ Security Best Practices
- Never commit API keys: Always use environment variables
- Use your own API key: Each deployment should use a unique API key
- Rotate keys regularly: Generate new API keys periodically
- Monitor usage: Check your Range dashboard for API usage
- Secure deployment: Use Railway's environment variable management
📚 API Documentation
This server exposes Range's blockchain intelligence capabilities through MCP tools:
- Address Intelligence: Balance tracking, transaction history, risk scoring
- Transaction Analysis: Risk assessment, simulation, cross-chain monitoring
- Network Intelligence: Whale tracking, protocol analytics, volume data
- Compliance Tools: IVMS101 entities, sanctions screening, risk management
For detailed API documentation, see the Range platform documentation at app.range.org.
🤝 Contributing
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests for new functionality
- Ensure all tests pass
- Submit a pull request
📄 License
This project is licensed under the MIT License - see the LICENSE file for details.
⚠️ Disclaimer
This software is provided as-is. Users are responsible for:
- Obtaining and securing their own Range API keys
- Complying with Range's terms of service
- Ensuring proper security practices in their deployments
- Managing their API usage and billing
🆘 Support
- Range API Issues: Contact Range support at app.range.org
- MCP Server Issues: Open an issue in this repository
- Documentation: Check the Range platform documentation