Fire in da houseTop Tip:Paying $100+ per month for Perplexity, MidJourney, Runway, ChatGPT and other tools is crazy - get all your AI tools in one site starting at $15 per month with Galaxy AI Fire in da houseCheck it out free

jenkins-mcp

MCP.Pizza Chef: kjozsa

Jenkins MCP is a server that integrates Jenkins continuous integration and delivery operations into the MCP ecosystem. It enables real-time interaction with Jenkins pipelines, job management, and automation tasks through structured context and commands. This server simplifies Jenkins automation by exposing Jenkins functionality to LLMs and MCP clients, facilitating seamless CI/CD workflows and operational control.

Use This MCP server To

Trigger Jenkins build jobs from natural language commands Monitor Jenkins pipeline status and results in real time Retrieve build logs and artifacts for analysis Automate Jenkins job configuration and management Integrate Jenkins operations into AI-enhanced developer workflows Generate reports on Jenkins build history and metrics Coordinate multi-step CI/CD workflows with LLM orchestration

README

Jenkins MCP

smithery badge MCP server for managing Jenkins operations.

Jenkins MCP server

Installation

Installing via Smithery

To install Jenkins MCP for Claude Desktop automatically via Smithery:

npx -y @smithery/cli install @kjozsa/jenkins-mcp --client claude

Installing Manually

uvx install jenkins-mcp

Configuration

Add the MCP server using the following JSON configuration snippet:

{
  "mcpServers": {
    "jenkins-mcp": {
      "command": "uvx",
      "args": ["jenkins-mcp"],
      "env": {
        "JENKINS_URL": "https://your-jenkins-server/",
        "JENKINS_USERNAME": "your-username",
        "JENKINS_PASSWORD": "your-password",
        "JENKINS_USE_API_TOKEN": "false"
      }
    }
  }
}

CSRF Crumb Handling

Jenkins implements CSRF protection using "crumbs" - tokens that must be included with POST requests. This MCP server handles CSRF crumbs in two ways:

  1. Default Mode: Automatically fetches and includes CSRF crumbs with build requests

    • Uses session cookies to maintain the web session
    • Handles all the CSRF protection behind the scenes
  2. API Token Mode: Uses Jenkins API tokens which are exempt from CSRF protection

    • Set JENKINS_USE_API_TOKEN=true
    • Set JENKINS_PASSWORD to your API token instead of password
    • Works with Jenkins 2.96+ which doesn't require crumbs for API token auth

You can generate an API token in Jenkins at: User → Configure → API Token → Add new Token

Features

  • List Jenkins jobs
  • Trigger builds with optional parameters
  • Check build status
  • CSRF crumb handling for secure API access

Development

# Install dependencies
uv pip install -r requirements.txt

# Run in dev mode with Inspector
mcp dev jenkins_mcp/server.py

jenkins-mcp FAQ

How do I install Jenkins MCP server?
You can install Jenkins MCP via Smithery CLI using 'npx -y @smithery/cli install @kjozsa/jenkins-mcp --client claude' or manually with 'uvx install jenkins-mcp'.
How do I configure Jenkins MCP server?
Configure it by providing Jenkins URL, username, and password in the MCP server JSON configuration under environment variables.
Can Jenkins MCP server interact with multiple Jenkins instances?
Yes, by configuring multiple MCP server instances with different Jenkins URLs and credentials.
Is Jenkins MCP server compatible with different LLM clients?
Yes, it works with various MCP clients including Claude Desktop, GPT-4, and Gemini clients.
What Jenkins operations can I perform with Jenkins MCP?
You can trigger builds, monitor pipelines, fetch logs, manage jobs, and automate Jenkins workflows.
Does Jenkins MCP support secure credential management?
Credentials are managed via environment variables; secure storage depends on your deployment environment.
Can Jenkins MCP server be used in CI/CD automation pipelines?
Yes, it enables AI-driven orchestration and automation of Jenkins pipelines within MCP workflows.
How does Jenkins MCP improve developer productivity?
By enabling natural language control and real-time Jenkins interaction, it reduces manual Jenkins UI usage and scripting.