Enables packaging and deploying the MCP server as a Docker container for simplified deployment and portability.
Handles environment variables for configuring sensitive information like API credentials.
Enables version control and cloning of the repository for installation.
Provides the runtime environment for the MCP server, requiring Node.js 18+ for operation.
Manages dependencies and provides scripts for building, testing, and running the server.
Implements the server using TypeScript for type safety and maintainability.
Band MCP Server
A fully functional Model Context Protocol (MCP) server that integrates with the Band API. This server enables seamless interaction with Band social platform data through AI assistants and other MCP-compatible tools.
✅ Project Status: Production Ready
Version: 1.0.3
Docker Image: kanghouchao/band-mcp-server:latest
This MCP server is fully implemented and provides complete access to Band API functionality including user profiles, band management, posts, comments, albums, and photos with full read/write capabilities.
Key Features
✅ Access Token Authentication: Secure authentication using Band API access tokens
✅ Complete Band API Coverage: Full implementation of all major Band API endpoints
✅ Read/Write Operations: Comprehensive CRUD operations for posts, comments, and band data
✅ MCP Integration: Native MCP tools and resources for seamless AI integration
✅ Docker Deployment: Production-ready containerized deployment
✅ TypeScript Implementation: Type-safe implementation with full error handling
✅ Automated CI/CD: Continuous integration and automated Docker builds
Features
- Access Token Authentication: Securely authenticate using Band API access tokens.
- MCP Resources: Fetch and expose Band posts as MCP resources.
- MCP Tools: Enable read/write operations on Band data via MCP tools.
- TypeScript Implementation: Leverage TypeScript for type safety and maintainability.
- Dockerized Deployment: Simplify deployment with a Docker container.
Quick Start
Prerequisites
- Band API access token (obtainable from Band Developer Portal)
- VS Code with MCP support or any MCP-compatible client
- Docker (for containerized deployment)
VS Code Integration
Add the following configuration to your VS Code settings.json
:
Local Development
Docker Deployment
Available MCP Tools
User & Band Management
get_user_information
- Get user profile information for a Band groupget_bands
- Get list of all Band groups the authenticated user belongs topermissions
- Check user permissions for a specific Band (posting, commenting, deletion rights)
Posts & Content
get_posts
- Get posts from a specific Band with pagination supportget_post
- Get detailed information about a specific postwrite_post
- Create a new post in a Band groupremove_post
- Delete a post from a Band (requires appropriate permissions)
Comments & Interactions
get_comments
- Get comments for a specific post with sorting optionswrite_comment
- Add a comment to a postremove_comment
- Delete a comment from a post (requires appropriate permissions)
Media & Albums
get_albums
- Get photo albums in a Band groupget_photos
- Get photos from a specific album
Usage Examples
Error Handling & API Limits
The server implements comprehensive error handling and respects Band API rate limits:
- Authentication errors: Clear error messages for invalid or expired tokens
- Permission errors: Detailed feedback when operations require higher permissions
- Rate limiting: Automatic handling of API rate limits with appropriate delays
- Validation: Input validation for all parameters using Zod schemas
- Logging: Comprehensive logging for debugging and monitoring
Development & Testing
Project Structure
Available Scripts
npm run dev
- Development mode with hot reloadnpm run build
- Build TypeScript to JavaScriptnpm run test
- Run test suitenpm run lint
- Run ESLintmake help
- Show all available Makefile commands
Troubleshooting
Common Issues
"Authentication failed"
- Verify your Band API access token is valid and not expired
- Ensure the token has the necessary permissions for the operations you're trying to perform
- Check that the token is correctly set in the environment variable
BAND_ACCESS_TOKEN
"Permission denied" errors
- Some operations require specific roles within a Band (leader, co-leader, etc.)
- Use the
permissions
tool to check your access rights for a specific Band - Contact the Band administrator to request appropriate permissions
Docker container issues
- Ensure Docker is running and you have sufficient permissions
- Check that the environment variable is properly passed to the container
- Verify the Docker image is up to date:
docker pull kanghouchao/band-mcp-server:latest
MCP client connection issues
- Verify your MCP client supports the required protocol version
- Check that the server command and arguments are correctly configured
- Review VS Code or client logs for detailed error messages
Debug Mode
To enable detailed logging, set the environment variable:
Contributing
We welcome contributions! Please follow these guidelines:
- Fork the repository and create a feature branch
- Write tests for new functionality
- Follow TypeScript best practices and maintain type safety
- Update documentation for any API changes
- Run tests and linting before submitting:
- Submit a pull request with a clear description of changes
Development Workflow
Roadmap
Planned Improvements
- Response data optimization for better AI processing performance
- Combined API tool for complex operations
- Enhanced error recovery and retry mechanisms
- Additional Band API endpoint coverage
- Performance monitoring and metrics
- Multi-language support for error messages
Performance Optimization
Current focus is on optimizing API response data to improve AI processing speed by:
- Filtering unnecessary data fields
- Implementing selective field queries
- Reducing payload sizes for better performance
Security Considerations
- Token Security: Never commit access tokens to version control
- Environment Variables: Always use environment variables for sensitive data
- Permissions: Follow principle of least privilege when requesting API permissions
- Rate Limiting: Respect Band API rate limits to avoid service disruption
- Input Validation: All inputs are validated using Zod schemas
License
MIT License - see LICENSE file for details.
Maintainer: kanghouchao
Docker Hub: kanghouchao/band-mcp-server
Issues: Please report bugs and feature requests via GitHub Issues
This server cannot be installed
remote-capable server
The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.
A Model Context Protocol server that integrates with the Band API, allowing users to fetch posts from Band groups and perform read/write operations on Band data.
Related MCP Servers
- -securityFlicense-qualityA Model Context Protocol server that enables SQL query execution, database management, and business intelligence capabilities through MySQL connections.Last updated -JavaScript
- -securityFlicense-qualityA Model Context Protocol server providing tools for querying Bitcoin blockchain data via Blockchain Data and Query APIs, supporting various BTC information retrieval functions.Last updated -Python
- -security-license-qualityA Model Context Protocol server that provides tools for connecting to and interacting with various database systems (SQLite, PostgreSQL, MySQL/MariaDB, SQL Server) through a unified interface.Last updated -Python
- -security-license-qualityA Model Context Protocol server that bridges Microsoft Teams and MCP-compatible clients, enabling chat integration, message handling, and advanced search capabilities without REST API endpoints.Last updated -Python