Skip to main content
Glama

Jenkins Server MCP

by hekmon8

Jenkins Server MCP

A Model Context Protocol (MCP) server that provides tools for interacting with Jenkins CI/CD servers. This server enables AI assistants to check build statuses, trigger builds, and retrieve build logs through a standardized interface.

Installation

  1. Clone this repository:
git clone https://github.com/yourusername/jenkins-server-mcp.git cd jenkins-server-mcp
  1. Install dependencies:
npm install
  1. Build the project:
npm run build

Configuration

The server requires the following environment variables:

  • JENKINS_URL: The URL of your Jenkins server (defaults to 'http://sohoci.rd.tp-link.net/jenkins')
  • JENKINS_USER: Jenkins username for authentication
  • JENKINS_TOKEN: Jenkins API token for authentication

Configure these in your MCP settings file:

For Claude Desktop

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" } } } }

Tools and Usage

1. Get Build Status

Get the status of a Jenkins build:

// Example usage const result = await mcpClient.useTool("jenkins-server", "get_build_status", { jobPath: "view/xxx_debug", buildNumber: "lastBuild" // Optional, defaults to lastBuild });

Input Schema:

{ "jobPath": "string", // Path to Jenkins job "buildNumber": "string" // Optional, build number or "lastBuild" }

2. Trigger Build

Trigger a new Jenkins build with parameters:

// Example usage const result = await mcpClient.useTool("jenkins-server", "trigger_build", { jobPath: "view/xxx_debug", parameters: { BRANCH: "main", BUILD_TYPE: "debug" } });

Input Schema:

{ "jobPath": "string", // Path to Jenkins job "parameters": { // Build parameters as key-value pairs } }

3. Get Build Log

Retrieve the console output of a Jenkins build:

// Example usage const result = await mcpClient.useTool("jenkins-server", "get_build_log", { jobPath: "view/xxx_debug", buildNumber: "lastBuild" });

Input Schema:

{ "jobPath": "string", // Path to Jenkins job "buildNumber": "string" // Build number or "lastBuild" }

Development

For development with auto-rebuild:

npm run watch

Debugging

Since MCP servers communicate over stdio, you can use the MCP Inspector for debugging:

npm run inspector

This will provide a URL to access debugging tools in your browser.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Install Server
A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

A Model Context Protocol server that enables AI assistants to interact with Jenkins CI/CD servers, providing tools to check build statuses, trigger builds, and retrieve build logs.

  1. Installation
    1. Configuration
      1. For Claude Desktop
    2. Tools and Usage
      1. Get Build Status
      2. Trigger Build
      3. Get Build Log
    3. Development
      1. Debugging
    4. License

      Related MCP Servers

      • -
        security
        F
        license
        -
        quality
        A Model Context Protocol server that enables AI assistants to build and test Xcode projects directly through a standardized interface, with capabilities for running tests, monitoring progress, and accessing logs in real-time.
        Last updated -
        29
        TypeScript
      • -
        security
        -
        license
        -
        quality
        A Model Context Protocol server implementation that enables AI assistants to interact with Linear project management systems, allowing them to create, retrieve, and modify data related to issues, projects, teams, and users.
        Last updated -
        20
        2
        TypeScript
      • -
        security
        F
        license
        -
        quality
        A comprehensive Model Context Protocol server implementation that enables AI assistants to interact with file systems, databases, GitHub repositories, web resources, and system tools while maintaining security and control.
        Last updated -
        16
        TypeScript
      • -
        security
        F
        license
        -
        quality
        An 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.
        Last updated -
        Python

      View all related MCP servers

      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