This repository demonstrates how to use the APISIX MCP Bridge plugin to integrate Model Context Protocol (MCP) servers with APISIX. The setup includes building a custom APISIX Docker image with Docker client capabilities and creating a Bitbucket MCP server that communicates via stdio.
The MCP Bridge plugin allows APISIX to act as a proxy for MCP servers, enabling seamless integration between MCP clients (like VS Code) and MCP servers through HTTP/SSE endpoints.
- Custom APISIX Image: Enhanced with Docker client for running containerized MCP servers
- Bitbucket MCP Server: Containerized MCP server for Atlassian Bitbucket integration
- MCP Bridge Plugin: APISIX plugin that bridges HTTP/SSE to stdio MCP communication
- Docker and Docker Compose
- VS Code with MCP extension (for client testing)
- Atlassian Bitbucket credentials (username and app password)
Edit .env
with your Bitbucket credentials:
ATLASSIAN_SITE_NAME="https://api.bitbucket.org"
ATLASSIAN_BITBUCKET_USERNAME="your_username"
ATLASSIAN_BITBUCKET_APP_PASSWORD="your_app_password"
The custom APISIX image includes Docker client for running containerized MCP servers:
docker-compose build apisix
docker-compose build mcp-bitbucket
docker-compose build
docker-compose up -d
This will start:
- APISIX on port 80 with MCP Bridge plugin
- Whoami service for testing
Check that APISIX is running:
curl http://localhost/whoami
Test MCP Bridge endpoint:
curl http://localhost/mcp-bitbucket/
Configure VS Code MCP client to connect to the APISIX MCP Bridge endpoint:
- Install the MCP extension in VS Code
- Add the following configuration to your VS Code settings or MCP client config:
{
"servers": {
"mcp-bitbucket": {
"type": "sse",
"url": "http://localhost/mcp-bitbucket"
}
}
}
Stop and remove all services:
docker-compose down
Remove built images:
docker rmi arulrajnet/apisix:dev arulrajnet/mcp-bitbucket:v1.39.7
This project is licensed under the MIT License - see the LICENSE file for details.