Skip to main content

MCP server for managing Jenkins operations

Project description

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

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

iflow_mcp_kjozsa_jenkins_mcp-0.1.1.tar.gz (11.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

iflow_mcp_kjozsa_jenkins_mcp-0.1.1-py3-none-any.whl (9.8 kB view details)

Uploaded Python 3

File details

Details for the file iflow_mcp_kjozsa_jenkins_mcp-0.1.1.tar.gz.

File metadata

  • Download URL: iflow_mcp_kjozsa_jenkins_mcp-0.1.1.tar.gz
  • Upload date:
  • Size: 11.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.2 {"installer":{"name":"uv","version":"0.10.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for iflow_mcp_kjozsa_jenkins_mcp-0.1.1.tar.gz
Algorithm Hash digest
SHA256 108bf446277e38f85faac61270c25eca32dc644915c039fddc5eb2d4815d4138
MD5 677aa73e31a124dfa11a95b2b0983feb
BLAKE2b-256 49268b145ed341e619a750903445a8c3c00947f017153413a329ff428aa53246

See more details on using hashes here.

File details

Details for the file iflow_mcp_kjozsa_jenkins_mcp-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: iflow_mcp_kjozsa_jenkins_mcp-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 9.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.2 {"installer":{"name":"uv","version":"0.10.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Debian GNU/Linux","version":"13","id":"trixie","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for iflow_mcp_kjozsa_jenkins_mcp-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0ed0631128f35e69cb3bdc48837fbc629006845ef55fb90770f10781b79a1dae
MD5 e2c7c8b399729281c345c877d8a5edb8
BLAKE2b-256 cbbb4a7e9baa6d838ae0520c2fdb2c90374662e32adb3c911acf317d9470a333

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page