================== /// MCP /// /// SON /// ================== [server:online] [protocol:ready]
sonarqube-mcp-server
by sapientpants
Model Context Protocol (MCP) server that exposes SonarQube / SonarCloud data—metrics, issues, hotspots, quality-gate status, etc.—to AI assistants via stdio or HTTP transports.
74
13
Open SourceInstallation
1. Clone the repository
git clone https://github.com/sapientpants/sonarqube-mcp-server.git
cd sonarqube-mcp-server
2. Install dependencies
npm install # or pnpm install / yarn install
3. Build TypeScript sources
npm run build # emits JS to ./dist
4. Configure environment
export SONARQUBE_URL=https://your-sonarqube.example.com
export SONARQUBE_TOKEN=<personal_access_token_with_browse_admin>
# Optional
export SERVER_PORT=8080 # default 8080
export LOG_LEVEL=info
5. Start the server
npm start # runs "node dist/index.js"
# or, for dev hot-reload
npm run dev # uses ts-node / nodemon
6. Verify
-------
-e SONARQUBE_URL=https://your-sonarqube \
-e SONARQUBE_TOKEN=<token> \
curl http://localhost:8080/health # → { status:"ok" }
Docker
docker build -t sonarqube-mcp-server .
docker run -d -p 8080:8080 \
sonarqube-mcp-server
Documentation
License: MIT License
Updated 7/30/2025