What is MCP Bundler Service?
MCP Bundler Service is a microservice that bundles code from public GitHub repositories and prepares it for deployment. It can return the bundled code directly or upload it to Google Cloud Storage (GCP) for further use.
How to use MCP Bundler Service?
Install dependencies with pnpm install, start the server with pnpm run dev, and access the interactive API documentation at /docs on localhost:8080. Use the /bundler or /v2/bundler endpoints with a GitHub repository URL; optionally specify a commit hash, output format (v1), or an MCP ID (v2). For GCP uploads, set the GCP_SERVICE_ACCOUNT_KEY environment variable; set DISABLE_GCP_INTEGRATION=true to return the bundle directly.
Key features of MCP Bundler Service
- Bundle code directly from any public GitHub repository
- Support for ESM (
mjs) and CommonJS (cjs) output formats
- Pin commits for reproducible builds with optional commit hash
- Optional upload of bundled code to Google Cloud Storage
- Interactive Swagger documentation at
/docs
- Comprehensive error handling with HTTP status codes (400, 500, 504)
Use cases of MCP Bundler Service
- Quickly fetch and bundle code from a GitHub repo for local testing or deployment
- Automate building and storing MCP server bundles in GCS for cloud-native pipelines
- Generate reproducible build artifacts by pinning specific commit hashes
- Integrate with CI/CD systems using the REST API and optional GCP upload
评论