BNB MCP Server

Natural language interface for BNB Chain data

Efficient blockchain data access through AI

BNB MCP Server

Model Context Protocol

Explore the Model Context Protocol and its capabilities for seamless blockchain data interaction through natural language.

Supported Operations

Comprehensive set of operations to interact with BNB Chain data through our intuitive interface.

OperationDescription
find_largest_txFind largest transaction in last 5 minutes
find_most_active_addressFind most active trading address
get_address_transfersQuery transaction history for specific address
get_token_balanceQuery BNB or token balance
get_transaction_detailsGet transaction details
get_block_detailsGet block information
get_gas_priceGet current Gas price
get_contract_eventsGet contract events
get_chain_statsGet on-chain statistics
broadcast_transactionBroadcast a signed raw transaction to BNB Chain
get_token_priceGet current price information for a token
export_transaction_historyExport transaction history in CSV format

Requirements

  • Node.js 18+
  • pnpm

Installation Steps

  1. Clone repository
  2. Install dependencies

Ready to Get Started?

Set up your BNB MCP Server in minutes with just a few simple steps

Quick start visualization

BNB MCP Server Usage Guide

What is MCP?

MCP (Model Control Protocol) is a sophisticated protocol designed to enhance and control Large Language Models (LLMs) interactions.

MCP Visualization
Real-time Model Control
Dynamic adjustment of model behavior and parameters
Enhanced Context Management
Efficient handling of context windows and memory
Tool Integration
Seamless integration with external tools and APIs
State Management
Persistent state tracking across conversations
Architecture Visualization

Architecture Overview

Our architecture is designed for performance, reliability, and scalability to handle complex blockchain data queries.

Event-Driven Architecture
Using Server-Sent Events (SSE) for real-time communication
Stateful Processing
Maintaining conversation and context state
Tool Orchestration
Managing and coordinating multiple tool interactions
Context Windows
Intelligent handling of context limitations

Usage Methods

1. Local Development Environment

Prerequisites:
  • Node.js (v16 or higher)
  • npm or yarn
  • Cursor IDE
  • Git
Setup steps:
# Clone the repository
git clone https://github.com/bnb-mcp/server
cd bnb-mcp-server

# Install dependencies
npm install

# Configure environment variables
cp .env.example .env
# Edit .env with your configuration

# Start development server
npm run dev
Development Environment

2. Production Environment

Production endpoint:

https://dev.bscmcp.org/sse

Best Practices

Follow these best practices to ensure optimal performance and reliability when using the BNB MCP Server.

Best Practices
Error Handling
  • Implement proper error recovery
  • Use exponential backoff for reconnections
  • Log errors comprehensively
Security
  • Store API keys in environment variables
  • Implement rate limiting
  • Use secure connections (HTTPS)
Performance
  • Monitor memory usage
  • Implement proper cleanup
  • Use connection pooling
Development Workflow
  • Use TypeScript for better type safety
  • Follow conventional commits
  • Write comprehensive tests