mcp-jenkins-client
Provides tools for interacting with a Jenkins CI/CD server, enabling management and monitoring of jobs, builds, nodes, views, queues, plugins, and system operations.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
mcp-jenkins-client
An open-source MCP server that exposes Jenkins CI/CD operations as tools for AI assistants. Built on python-jenkins and FastMCP.
Installation
Install from source with uv, or build a Docker image. Both start from a clone.
From source (uv)
Requires Python 3.10+ and uv.
git clone <repo-url> mcp-jenkins-client
cd mcp-jenkins-client
uv sync # creates .venv and installs the server
uv run mcp-jenkins-client # starts the server on stdio (needs the variables below)To work on it, install the test dependencies and run the suite:
uv sync --extra dev
uv run pytestWithout uv: python -m venv .venv && .venv/bin/pip install -e ".[dev]".
Docker
Requires Docker. Python and uv are not needed.
git clone <repo-url> mcp-jenkins-client
cd mcp-jenkins-client
docker build -t mcp-jenkins-client .The image is not published anywhere, so build it yourself. After git pull, rebuild it to update.
Related MCP server: jenkins-mcp
Configuration
Set the following environment variables:
Variable | Required | Description |
| Yes | Jenkins server URL |
| Yes | Jenkins username |
| Yes | Jenkins API token |
| No | Per-request HTTP timeout in seconds (default |
| No | Disk cap for the log cache in MB (default |
| No | Retries for transient failures — 502/503/504 responses and refused connections (default |
Claude Desktop / Claude Code
Add to your MCP client configuration. For a uv install, use the path to your checkout:
{
"mcpServers": {
"jenkins": {
"command": "uv",
"args": ["--directory", "/path/to/mcp-jenkins-client", "run", "mcp-jenkins-client"],
"env": {
"JENKINS_URL": "https://jenkins.example.com",
"JENKINS_USERNAME": "your-username",
"JENKINS_API_TOKEN": "your-api-token"
}
}
}
}For the Docker image, the client starts a container for each session:
{
"mcpServers": {
"jenkins": {
"command": "docker",
"args": [
"run", "-i", "--rm",
"-e", "JENKINS_URL", "-e", "JENKINS_USERNAME", "-e", "JENKINS_API_TOKEN",
"mcp-jenkins-client"
],
"env": {
"JENKINS_URL": "https://jenkins.example.com",
"JENKINS_USERNAME": "your-username",
"JENKINS_API_TOKEN": "your-api-token"
}
}
}
}-iis required: the server talks to the client over stdin and stdout.-e NAMEwithout a value passes the variable fromenvinto the container, so the token stays out of the command line. Add"-e", "JENKINS_TIMEOUT"or"-e", "JENKINS_LOG_CACHE_MB"to pass an optional setting.Add
"-v", "mcp-jenkins-cache:/root/.cache/mcp-jenkins-client"toargsto keep the log cache across sessions; without it each container starts with an empty cache.Inside the container,
localhostis the container itself. For a Jenkins on your own machine, usehttp://host.docker.internal:8080(on Linux, also add"--add-host=host.docker.internal:host-gateway"toargs).
Available Tools (54)
Jobs (14 tools)
list_jobs— List jobs with server-side paginationget_job_info— Get full job detailsget_job_config— Get job XML configurationcreate_job— Create a job from XML configreconfig_job— Update job configurationcopy_job— Copy a jobrename_job— Rename a jobdelete_job— Delete a jobenable_job— Enable a disabled jobdisable_job— Disable a jobjob_exists— Check if a job existscreate_folder— Create a folderset_next_build_number— Set next build numbersearch_jobs— Search jobs by regex across all folder depths
Builds (16 tools)
Every build tool except delete_build accepts lastBuild, lastSuccessfulBuild, lastFailedBuild or lastCompletedBuild in place of a build number; responses to an alias include the resolved build_number. Right after build_job, lastBuild is still the previous build — use the build number from wait_for_queue_item.
list_builds— List builds for a job with pagination (optionally with each build's result and parameters)build_job— Trigger a build (auto-routes parameterized jobs tobuildWithParameters; on a multibranch project, starts a branch scan)get_build_info— Get full build detailsget_build_status— Get just result/building/duration — cheap, use for pollingwait_for_build— Block until a build finishes (bounded, default 300s)get_build_console_output— Read a byte range of the console logsearch_build_console— Regex-search the console log, with context lines; page withfrom_offsetget_build_stages— Get pipeline stage infoget_stage_log— Read one pipeline stage's logget_failed_stage_log— Jump straight to the tail of the first failed stageget_build_env_vars— Get build environment variablesget_build_test_report— Get test resultsstop_build— Stop a running build (escalates/stop→/term→/kill)delete_build— Delete a buildget_build_artifact— Download a build artifactget_running_builds— List running builds
Nodes (6 tools)
list_nodes— List agent nodes with paginationget_node_info— Get node detailsget_node_config— Get node XML configurationdelete_node— Delete a nodeenable_node— Enable a nodedisable_node— Disable a node
Views (6 tools)
list_views— List views with paginationget_view_config— Get view XML configurationcreate_view— Create a viewreconfig_view— Update view configurationdelete_view— Delete a viewview_exists— Check if a view exists
Queue (4 tools)
get_queue_info— List queued items with paginationget_queue_item— Get queued item detailswait_for_queue_item— Wait for a queued item to start, return its build numbercancel_queue_item— Cancel a queued build
Plugins (2 tools)
list_plugins— List installed plugins with paginationget_plugin_info— Get plugin details
System (6 tools)
get_server_info— Get Jenkins server infoget_whoami— Get current user infoget_version— Get Jenkins versionquiet_down— Prepare Jenkins for shutdownrun_groovy_script— Execute Groovy scriptcheck_jenkinsfile_syntax— Validate Jenkinsfile syntax
Typical workflow
build_job → queue_id
wait_for_queue_item → build_number
wait_for_build → result
get_failed_stage_log (or search_build_console for a specific pattern)Pagination
List tools support server-side pagination with offset and limit parameters:
Use list_jobs with offset=0, limit=10 to get the first 10 jobsConsole output supports byte-based pagination, capped at 100 KB per call:
Use get_build_console_output with offset=0, limit=5000 to read the first 5KBBuild logs routinely reach hundreds of megabytes. Don't scan them with offsets — search them:
Use search_build_console with pattern='ERROR|Traceback|FAILED' to find failuresEach match reports a byte_offset; pass it to get_build_console_output as
offset and the output starts exactly at the matched line. All offsets
(byte_offset, offset, next_offset, from_offset) are byte positions in the
text the tools return, not in Jenkins' raw log.
The search stops once it has max_matches matches (default 50) and their context,
so total_matches means "at least this many" unless scanned_all is true. Pass count_all=true to read the whole log for an exact count. For the
next batch, pass the result's next_offset as from_offset: paging that way
returns every match exactly once, with absolute line numbers (a running build's
unfinished last line may repeat).
Log cache
The first read of a build's log downloads it from Jenkins and keeps an exact copy
on disk, so later searches and reads of that build — also in later sessions — read
the local copy instead of downloading it again. A log is downloaded only as far as
a call needs (a search stops at its matches); a later call resumes from where the
last download stopped. A running build's copy is extended with only what was added.
Parallel calls in one session share one download per build. Word searches
(error|FAILED|traceback) use a fast substring path. Design:
docs/superpowers/specs/2026-11-29-log-reading-design.md.
Location:
$XDG_CACHE_HOME/mcp-jenkins-client/logs/, default~/.cache/mcp-jenkins-client/logs/.The cache stores build log text on disk. The directory is made private to your user (mode
0700), and the cache turns itself off if someone else owns it. On Windows there is no such check, so no privacy promise.JENKINS_LOG_CACHE_MBcaps its size (default1024); the least recently read copies go first, and copies unread for 7 days are deleted.0turns the cache off: every call then streams the log from Jenkins.A cache error (such as a full disk) turns the cache off for the rest of the session; a call caught by it mid-download fails once, asking for a retry.
License
MIT — see LICENSE.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Your org's AI agents, tasks, runs, search, and brain files as MCP tools and resources.
MCP server for your apps' tools and custom tools, plus hosted AI agents and approval-gated workflows
AgentReady Tools is a searchable catalog of more than 250 APIs, MCP servers and developer tools that AI agents can use, each with agent-readiness checks (docs, auth, OpenAPI, MCP support). Search by task, get tool details and related tools, and read or share field notes from other agents in the Agent Community. Remote MCP endpoint: https://agentready-tools.com/mcp
MCP server exposing Buildkite API data (pipelines, builds, jobs, tests) to AI tooling and editors.
Related MCP Servers
- 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.767 PyPI1MIT
- AlicenseBqualityDmaintenanceProvides AI assistants with full access to Jenkins CI/CD systems, enabling querying, managing, and controlling Jenkins jobs, builds, nodes, and queues through natural language.222,121 npm2MIT
- FlicenseNot gradedqualityDmaintenanceEnables AI agents and external systems to programmatically trigger and monitor Jenkins jobs, retrieve build status and logs via MCP standards.-
- AlicenseBqualityCmaintenanceA comprehensive MCP server with 53 tools for managing Jenkins CI/CD operations, including job, build, pipeline, node, credential, and plugin management, enabling AI assistants to control Jenkins servers through natural language.53MIT