Jenkins Server MCP
Jenkins 服务器 MCP
模型上下文协议 (MCP) 服务器提供与 Jenkins CI/CD 服务器交互的工具。该服务器使 AI 助手能够通过标准化接口检查构建状态、触发构建以及检索构建日志。
安装
克隆此存储库:
git clone https://github.com/yourusername/jenkins-server-mcp.git
cd jenkins-server-mcp安装依赖项:
npm install构建项目:
npm run buildRelated MCP server: Jenkins MCP Server
配置
服务器需要以下环境变量:
JENKINS_URL:你的 Jenkins 服务器的 URL(默认为“ http://sohoci.rd.tp-link.net/jenkins ”)JENKINS_USER:用于身份验证的 Jenkins 用户名JENKINS_TOKEN:用于身份验证的 Jenkins API 令牌
在您的 MCP 设置文件中配置这些:
对于克劳德桌面
MacOS: ~/Library/Application Support/Claude/claude_desktop_config.json Windows: %APPDATA%/Claude/claude_desktop_config.json
{
"mcpServers": {
"jenkins-server": {
"command": "node",
"args": ["/path/to/jenkins-server-mcp/build/index.js"],
"env": {
"JENKINS_URL": "https://your-jenkins-server.com",
"JENKINS_USER": "your-username",
"JENKINS_TOKEN": "your-api-token"
}
}
}
}工具和用法
1. 获取构建状态
获取 Jenkins 构建的状态:
// Example usage
const result = await mcpClient.useTool("jenkins-server", "get_build_status", {
jobPath: "view/xxx_debug",
buildNumber: "lastBuild" // Optional, defaults to lastBuild
});输入模式:
{
"jobPath": "string", // Path to Jenkins job
"buildNumber": "string" // Optional, build number or "lastBuild"
}2. 触发构建
使用参数触发新的 Jenkins 构建:
// Example usage
const result = await mcpClient.useTool("jenkins-server", "trigger_build", {
jobPath: "view/xxx_debug",
parameters: {
BRANCH: "main",
BUILD_TYPE: "debug"
}
});输入模式:
{
"jobPath": "string", // Path to Jenkins job
"parameters": {
// Build parameters as key-value pairs
}
}3. 获取构建日志
检索 Jenkins 构建的控制台输出:
// Example usage
const result = await mcpClient.useTool("jenkins-server", "get_build_log", {
jobPath: "view/xxx_debug",
buildNumber: "lastBuild"
});输入模式:
{
"jobPath": "string", // Path to Jenkins job
"buildNumber": "string" // Build number or "lastBuild"
}发展
对于使用自动重建的开发:
npm run watch调试
由于 MCP 服务器通过 stdio 进行通信,因此您可以使用 MCP Inspector 进行调试:
npm run inspector这将提供一个 URL 来访问浏览器中的调试工具。
执照
该项目根据 MIT 许可证获得许可 - 有关详细信息,请参阅LICENSE文件。
Available Tools
3 toolsget_build_logB
Get the console output of a Jenkins build
| Name | Required | Description | Default |
|---|---|---|---|
| buildNumber | Yes | Build number (use "lastBuild" for most recent) | |
| jobPath | Yes | Path to the Jenkins job |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the action ('Get') but doesn't add context beyond that—e.g., it doesn't mention authentication needs, rate limits, error handling, or what 'console output' entails (e.g., log format, size limits). For a tool with no annotations, this is a significant gap in transparency.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence: 'Get the console output of a Jenkins build.' It's front-loaded with the core purpose, has zero waste, and is appropriately sized for a simple tool. Every word earns its place, making it highly concise and well-structured.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's complexity (simple read operation with 2 parameters) and the absence of annotations and output schema, the description is minimally adequate. It states what the tool does but lacks details on behavior, usage context, or output format. It meets the basic requirement but has clear gaps, especially in behavioral transparency and guidelines.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 100%, with both parameters ('buildNumber' and 'jobPath') well-documented in the schema (e.g., 'use "lastBuild" for most recent'). The description doesn't add any parameter-specific details beyond what the schema provides. According to the rules, with high schema coverage (>80%), the baseline is 3, as the schema does the heavy lifting.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: 'Get the console output of a Jenkins build.' It specifies the verb ('Get') and resource ('console output of a Jenkins build'), making it understandable. However, it doesn't explicitly differentiate from sibling tools like 'get_build_status' (which might return status metadata rather than console output), so it misses full sibling distinction.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives. It doesn't mention sibling tools like 'get_build_status' or 'trigger_build,' nor does it specify prerequisites, contexts, or exclusions for usage. This lack of comparative or contextual advice limits its helpfulness for an AI agent.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_build_statusC
Get the status of a Jenkins build
| Name | Required | Description | Default |
|---|---|---|---|
| buildNumber | No | Build number (use "lastBuild" for most recent) | |
| jobPath | Yes | Path to the Jenkins job (e.g., "view/xxx_debug") |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden of behavioral disclosure. It states the tool retrieves status but doesn't add any context beyond that—no information about authentication needs, rate limits, error handling, or what the status response entails (e.g., success/failure, duration). This leaves significant gaps in understanding how the tool behaves in practice.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence that directly states the tool's purpose without any fluff or redundancy. It's appropriately sized and front-loaded, making it easy to parse quickly. Every word earns its place by conveying essential information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity of a build status tool with no annotations and no output schema, the description is incomplete. It doesn't explain what the status output includes (e.g., success indicators, timestamps) or any behavioral nuances like error cases. For a tool that likely returns structured status data, this lack of context leaves the agent under-informed.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has 100% description coverage, with clear explanations for both parameters (e.g., 'buildNumber' can use 'lastBuild' for most recent, 'jobPath' specifies the path). The description adds no additional meaning beyond what the schema provides, so it meets the baseline score of 3 for high schema coverage without compensating value.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('Get') and resource ('status of a Jenkins build'), making the tool's purpose immediately understandable. It distinguishes itself from sibling tools like 'get_build_log' (which retrieves logs) and 'trigger_build' (which initiates builds). However, it doesn't explicitly mention the verb+resource combination in a way that highlights sibling differentiation beyond the obvious.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives. It doesn't mention scenarios where this tool is preferred over 'get_build_log' for status checks or 'trigger_build' for initiating actions. There's no context about prerequisites, such as needing a valid job path or build number, leaving usage entirely implicit.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
trigger_buildC
Trigger a new Jenkins build
| Name | Required | Description | Default |
|---|---|---|---|
| jobPath | Yes | Path to the Jenkins job | |
| parameters | Yes | Build parameters (optional) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the full burden of behavioral disclosure. 'Trigger a new Jenkins build' implies a mutation/write operation, but it doesn't disclose critical traits: whether it requires specific permissions, if it's idempotent, what happens on failure, rate limits, or the response format. For a mutation tool with zero annotation coverage, this is a significant gap in transparency.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is a single, efficient sentence with zero waste. It's front-loaded with the core action and resource, making it easy to scan. Every word earns its place, and there's no redundancy or unnecessary elaboration.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the complexity of a mutation tool with no annotations and no output schema, the description is incomplete. It lacks information on behavioral traits (e.g., permissions, side effects), usage context, and what to expect after triggering. The schema covers inputs well, but for a tool that initiates builds, more guidance is needed to be fully helpful.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description adds no parameter semantics beyond what the input schema provides. Schema description coverage is 100%, with clear descriptions for 'jobPath' and 'parameters', so the baseline is 3. The description doesn't explain parameter usage, such as how 'jobPath' is formatted or what 'parameters' might include, but the schema adequately covers this.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action ('Trigger') and resource ('a new Jenkins build'), making the purpose immediately understandable. It doesn't differentiate from sibling tools like 'get_build_log' or 'get_build_status', which are read operations, but the verb 'Trigger' inherently distinguishes it as a write/mutation action. The purpose is specific but lacks explicit sibling differentiation.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., needing job access), when not to use it (e.g., for read-only operations), or refer to sibling tools like 'get_build_log' for checking results. Usage is implied by the action but lacks explicit context or exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
3 tool updates
v1.0.0- First observed
get_build_log - First observed
get_build_status - First observed
trigger_build
TDQS
Each tool has a clearly distinct purpose: get_build_log retrieves console output, get_build_status checks build status, and trigger_build initiates new builds. There is no overlap or ambiguity between these functions.
All tools follow a consistent verb_noun pattern (get_build_log, get_build_status, trigger_build) with clear, descriptive names. The naming convention is uniform and predictable throughout the set.
With only 3 tools, the server feels thin for a Jenkins integration, which typically involves more operations like managing jobs, viewing queue status, or canceling builds. While the tools cover basic build interactions, the scope is limited.
The toolset is severely incomplete for Jenkins functionality. It lacks core operations such as listing jobs, viewing build history, managing job configurations, or handling Jenkins system information. Agents will face significant gaps in performing typical Jenkins tasks.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
The Buildkite MCP server exposes Buildkite product data (pipelines, builds, jobs, and test data) to AI tools, editors, and agents through the Model Context Protocol. It provides capabilities including pipeline creation and management, build monitoring with specialized tools like 'wait_for_build', efficient log querying using Apache Parquet conversion and caching, and OAuth-based authentication for both read-write and read-only access to Buildkite's REST API.
The Mercado Pago MCP Server implements the Model Context Protocol to provide AI agents and LLMs with access to Mercado Pago's APIs and tools within compatible development environments. It acts as an intermediary that translates Mercado Pago resources into executable functions (tools) that AI applications can invoke to perform actions and automate flows. The server simplifies integration, enables using documentation to implement or improve code, and optimizes operations through natural language interactions without manual implementations.
A Model Context Protocol server for Wix AI tools
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceAn integration tool that allows interaction with Jenkins CI/CD servers through a Model Context Protocol interface, enabling users to view server info, manage jobs, inspect builds, and trigger builds with parameters.1-
- AlicenseNot gradedqualityNot gradedmaintenanceA Model Context Protocol (MCP) server that enables AI tools like chatbots to interact with and control Jenkins, allowing users to trigger jobs, check build statuses, and perform other Jenkins operations through natural language.-
- AlicenseBqualityDmaintenanceA server that enables interaction with Jenkins CI/CD pipelines from any compatible MCP client (like Claude Desktop), allowing users to manage jobs, builds, coverage reports, and other Jenkins functionality through natural language.119MIT
- AlicenseNot gradedqualityCmaintenanceProvides Jenkins CI/CD integration for AI assistants through the Model Context Protocol, enabling job management, build control, and system administration via natural language commands.1MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/hekmon8/Jenkins-server-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server