Build Runner MCP Server
Provides structured compilation, build, and test execution for Gradle-based Java projects, including error and test result parsing.
Executes Jest test suites and returns parsed test results (passed, failed, skipped) with failure details.
Executes Mocha test suites and returns parsed test results with failure details.
Supports building, testing, and type-checking Node.js projects, leveraging npm, pnpm, or yarn as package managers.
Allows building and testing Node.js/TypeScript projects using npm as the package manager.
Allows building and testing Node.js/TypeScript projects using pnpm as the package manager.
Performs type checking via tsc --noEmit on TypeScript projects.
Executes Vitest test suites and returns parsed test results with failure details.
Allows building and testing Node.js/TypeScript projects using Yarn as the package manager.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Build Runner MCP Server run tests for UserServiceTest and show failures"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Build Runner MCP Server
A Model Context Protocol (MCP) server that provides structured build, compile, and test operations with parsed output to reduce token usage and improve readability.
Features
Java version switching via SDKMAN (
sdk use java <version>)Compilation with structured error output
Build/Package with success/failure summary
Test execution with parsed test results (passed, failed, skipped)
Multi-build-system support: Maven, Gradle, npm/pnpm/yarn
Related MCP server: MCP Build Environment Service
Installation
# Clone the repository
git clone <repository-url>
cd build-runner-mcp
# Install dependencies
npm install
# Build the project
npm run buildConfiguration
Add to your Claude Code settings (~/.claude.json):
{
"mcpServers": {
"build-runner": {
"command": "node",
"args": ["/path/to/build-runner-mcp/build/index.js"]
}
}
}Available Tools
detect_project
Detect project type, build system, test framework, and configuration.
{
"projectPath": "/path/to/project"
}Returns: Project info including languages, build system, package manager, and test framework.
set_java_version
Switch Java version using SDKMAN before running commands.
Available versions: 17.0.16-amzn, 21.0.8-tem, 21.0.9-amzn, 25.0.1-tem
{
"version": "17.0.16-amzn"
}compile_project
Compile a Java project using Maven or Gradle.
{
"projectPath": "/path/to/project",
"javaVersion": "17.0.16-amzn",
"clean": false,
"module": "core"
}Returns: Structured compile errors and warnings with file, line, column, and message.
build_project
Build/package a Java project.
{
"projectPath": "/path/to/project",
"javaVersion": "21.0.8-tem",
"skipTests": true,
"clean": true
}Returns: Build artifacts with paths and sizes, duration, and any errors.
run_tests
Run tests for a Java project with structured results.
{
"projectPath": "/path/to/project",
"javaVersion": "17.0.16-amzn",
"testPattern": "UserServiceTest",
"module": "api",
"failFast": true
}Returns:
{
"success": false,
"summary": { "total": 50, "passed": 47, "failed": 2, "skipped": 1, "duration": "12.5s" },
"failures": [
{
"testClass": "UserServiceTest",
"testMethod": "testLogin",
"message": "Expected 200 but got 401",
"stackTrace": "...",
"file": "UserServiceTest.java",
"line": 42
}
]
}node_build
Build a Node.js/TypeScript project.
{
"projectPath": "/path/to/project",
"script": "build",
"packageManager": "pnpm"
}node_typecheck
Type check a TypeScript project using tsc --noEmit.
{
"projectPath": "/path/to/project"
}node_test
Run tests for a Node.js/TypeScript project (Jest, Vitest, or Mocha).
{
"projectPath": "/path/to/project",
"testPattern": "user.test.ts",
"failFast": true,
"coverage": true
}Token Savings
Before (raw Maven test output): ~500 lines
[INFO] Scanning for projects...
[INFO] --- maven-surefire-plugin:3.0.0:test ---
... (hundreds of lines)
[ERROR] Tests run: 50, Failures: 2, Errors: 0, Skipped: 1After (structured): ~20 lines
{
"success": false,
"summary": { "total": 50, "passed": 47, "failed": 2, "skipped": 1 },
"failures": [
{ "testClass": "UserServiceTest", "testMethod": "testLogin", "message": "Expected 200 but got 401" }
]
}SDKMAN Integration
The server automatically sources SDKMAN and switches Java versions when specified:
source "$HOME/.sdkman/bin/sdkman-init.sh" && sdk use java 17.0.16-amzn && mvn compileDevelopment
# Run in development mode
npm run dev
# Build
npm run build
# Clean build artifacts
npm run cleanLicense
MIT
Available Tools
9 toolsbuild_projectB
Build/package a Java project using Maven or Gradle. Returns build artifacts and duration.
Inputs: projectPath (required), clean, module, alsoMake, +2 more.
compile_projectB
Compile a Java project using Maven or Gradle. Returns structured error/warning information.
Inputs: projectPath (required), clean, module, alsoMake, +1 more.
detect_projectA
Detect project type, build system, test framework, and configuration. Supports Maven, Gradle, npm, pnpm, and yarn projects.
Inputs: projectPath (required).
install_projectA
Install a Java project to the local Maven repository using Maven (mvn install) or Gradle (publishToMavenLocal). Supports multi-module projects with -pl flag for inclusion/exclusion.
Inputs: projectPath (required), clean, module, alsoMake, +2 more.
node_buildB
Build a Node.js/TypeScript project using npm, pnpm, or yarn.
Inputs: projectPath (required), script, packageManager.
node_testB
Run tests for a Node.js/TypeScript project using Jest, Vitest, or Mocha. Returns structured test results.
Inputs: projectPath (required), coverage, failFast, testPattern, +2 more.
node_typecheckA
Type check a TypeScript project using tsc --noEmit.
Inputs: projectPath (required), packageManager.
run_testsA
Run tests for a Java project using Maven or Gradle. Returns structured test results with failures and stack traces.
Inputs: projectPath (required), clean, module, alsoMake, +3 more.
set_java_versionA
Switch Java version using SDKMAN before running commands. Available versions: 17.0.16-amzn, 21.0.8-tem, 21.0.9-amzn, 25.0.1-tem
Inputs: version (required), projectPath.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 9 tools
Most tools cleanly separate by ecosystem and build phase: Java build/install/compile/test versus Node build/test/typecheck. The only real ambiguity is compile_project vs build_project, since compilation is normally part of a build, but the descriptions clarify that compile focuses on diagnostics while build produces artifacts.
Naming is mixed: Java tools mostly follow verb_project (build_project, install_project, compile_project), while Node tools follow node_verb (node_test, node_build, node_typecheck). run_tests breaks the Java pattern by using a generic verb instead of something like test_project, and set_java_version follows yet another style.
Nine tools is well-scoped for a multi-language build runner. Each tool covers a meaningful build, test, install, detect, or environment-management action without feeling padded or redundant.
The surface covers the core Java and Node.js workflows: detection, building, compiling, testing, installing for Java, and type checking for TypeScript projects. Minor gaps like a Node install/publish command or a generic clean task are absent, but agents can still complete typical build-and-test workflows.
Related MCP Connectors
Build, test and cache insights for Xcode, Gradle and Bazel projects, for coding agents.
Structured knowledge base for AI agent solutions. Search, explore, and retrieve build logs.
Publish honest build receipts to cobuilt.dev: your agent drafts, you approve every field.
Discover software problems, analyze evidence, and create implementation-ready Build plans.
Related MCP Servers
- AlicenseBqualityDmaintenanceEnables AI assistants to manage development workflows by running build commands, executing tests, analyzing package.json files, installing dependencies, and performing code linting. Supports multiple package managers (npm, yarn, pnpm) and provides detailed error reporting for development operations.5MIT
- AlicenseAqualityDmaintenanceProvides secure access to containerized build environments for software projects, enabling AI assistants to execute builds, run tests, manage git operations, and inspect build artifacts without requiring local installation of dependencies.6MIT
- FlicenseBqualityDmaintenanceWraps Maven and Spring Boot operations for Claude Code, providing structured JSON output instead of raw build logs to save tokens and focus on code fixes.20-
- AlicenseNot gradedqualityCmaintenanceEnables an agent to run a build tool and receive clean structured compiler diagnostics with file, line, severity, and message, avoiding noisy log spam.MIT