Skip to main content
Glama
Pawangunjkar

Jenkins MCP Server

by Pawangunjkar

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
JENKINS_URLYesJenkins server URL (e.g., http://localhost:8080)
JENKINS_TIMEOUTNoRequest timeout in seconds30
JENKINS_USERNAMEYesJenkins usernameadmin
JENKINS_API_TOKENYesJenkins API token
JENKINS_SSL_VERIFYNoSet to false for self-signed certificatestrue
JENKINS_MCP_CACHE_DIRNoCredential cache directory~/.jenkins-mcp-cache

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": false
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
jenkins_connectA

Connect to a Jenkins server and create a named session.

If a session with the same name exists, it will be disconnected first. Credentials are automatically cached for future reconnection.

Args: url: Jenkins server URL (e.g., 'http://localhost:8080') username: Jenkins username (default: admin) api_token: Jenkins API token (generate at User → Configure → API Token) ssl_verify: Verify SSL certificates (default: True, set False for self-signed certs) timeout: Request timeout in seconds (default: 30) session_name: Name for this session, e.g. 'prod', 'staging' (default: 'default')

jenkins_disconnectB

Disconnect a specific Jenkins session.

Args: session_name: Name of the session to disconnect (default: 'default')

jenkins_statusB

Show connection status and Jenkins system overview.

Displays active sessions, Jenkins version, executor info, and job counts.

Args: session_name: Session to check (default: 'default')

jenkins_save_credentialsB

Save Jenkins credentials for a session name (persisted to disk for future use).

Saved credentials are used for auto-connect and future sessions.

Args: session_name: Name to save these credentials under url: Jenkins server URL username: Jenkins username api_token: Jenkins API token

jenkins_list_jobsA

List all Jenkins jobs, optionally within a specific folder.

Shows job name, type, color/status, and URL for each job.

Args: folder: Folder path to list jobs from (empty = root level) session_name: Jenkins session to use (default: 'default')

jenkins_get_jobB

Get detailed information about a specific Jenkins job.

Shows configuration, health, last builds, parameters, and more.

Args: job_name: Full job name (use 'folder/job-name' for jobs in folders) session_name: Jenkins session to use

jenkins_create_jobB

Create a new Jenkins job from an XML configuration.

Args: job_name: Name for the new job config_xml: Job configuration in XML format (config.xml content) folder: Folder to create the job in (empty = root level) session_name: Jenkins session to use

jenkins_delete_jobA

Delete a Jenkins job permanently.

⚠️ This action cannot be undone. All build history will be lost.

Args: job_name: Full job name (use 'folder/job-name' for jobs in folders) session_name: Jenkins session to use

jenkins_copy_jobB

Copy/clone an existing Jenkins job to a new name.

The new job will have identical configuration to the source.

Args: source_job: Name of the job to copy new_name: Name for the new job session_name: Jenkins session to use

jenkins_rename_jobC

Rename a Jenkins job.

Args: job_name: Current job name new_name: New name for the job session_name: Jenkins session to use

jenkins_enable_jobC

Enable a disabled Jenkins job so it can be built again.

Args: job_name: Full job name session_name: Jenkins session to use

jenkins_disable_jobC

Disable a Jenkins job (prevents new builds from being triggered).

Args: job_name: Full job name session_name: Jenkins session to use

jenkins_get_job_configB

Get a job's XML configuration (config.xml).

Useful for understanding job setup, modifying, or duplicating configurations.

Args: job_name: Full job name session_name: Jenkins session to use

jenkins_update_job_configB

Update a job's XML configuration (config.xml).

⚠️ This replaces the entire job configuration.

Args: job_name: Full job name config_xml: New XML configuration content session_name: Jenkins session to use

jenkins_buildB

Trigger a build for a Jenkins job.

For parameterized builds, pass parameters as JSON string.

Args: job_name: Full job name parameters: Build parameters as JSON string, e.g. '{"BRANCH": "main", "DEPLOY": "true"}' (empty for non-parameterized jobs) session_name: Jenkins session to use

jenkins_get_build_infoB

Get detailed information about a specific build.

Shows result, duration, timestamp, changes, and artifacts.

Args: job_name: Full job name build_number: Build number to inspect session_name: Jenkins session to use

jenkins_get_build_logC

Get console output (build log) for a specific build.

Returns the full console text output of the build.

Args: job_name: Full job name build_number: Build number (0 = last build) start_line: Start offset in bytes for progressive output (default: 0 = from beginning) session_name: Jenkins session to use

jenkins_stop_buildC

Abort/stop a running build.

Args: job_name: Full job name build_number: Build number to stop (0 = last build) session_name: Jenkins session to use

jenkins_delete_buildB

Delete a specific build from the build history.

⚠️ This cannot be undone.

Args: job_name: Full job name build_number: Build number to delete session_name: Jenkins session to use

jenkins_get_last_buildC

Get information about the last build of a job.

Args: job_name: Full job name session_name: Jenkins session to use

jenkins_get_last_successful_buildC

Get information about the last successful build of a job.

Args: job_name: Full job name session_name: Jenkins session to use

jenkins_get_last_failed_buildC

Get information about the last failed build of a job.

Args: job_name: Full job name session_name: Jenkins session to use

jenkins_get_queueC

List all items currently in the Jenkins build queue.

Shows queued jobs waiting to be built, their position, and why they're waiting.

Args: session_name: Jenkins session to use

jenkins_get_queue_itemA

Get details of a specific item in the build queue.

Args: queue_id: Queue item ID (from jenkins_get_queue) session_name: Jenkins session to use

jenkins_cancel_queue_itemC

Cancel/remove an item from the build queue.

Args: queue_id: Queue item ID to cancel session_name: Jenkins session to use

jenkins_list_nodesB

List all Jenkins nodes/agents with their status.

Shows node name, status (online/offline), executors, and labels.

Args: session_name: Jenkins session to use

jenkins_get_node_infoC

Get detailed information about a specific Jenkins node/agent.

Args: node_name: Node name (use '(built-in)' or '(master)' for the master node) session_name: Jenkins session to use

jenkins_enable_nodeC

Bring a Jenkins node/agent back online.

Args: node_name: Node name to enable session_name: Jenkins session to use

jenkins_disable_nodeB

Take a Jenkins node/agent offline with a reason message.

Args: node_name: Node name to disable reason: Reason for taking offline (displayed in Jenkins UI) session_name: Jenkins session to use

jenkins_get_node_logC

Get the log output from a Jenkins node/agent.

Args: node_name: Node name session_name: Jenkins session to use

jenkins_get_executor_statusC

Show executor status across all nodes.

Displays which executors are busy and what they're running.

Args: session_name: Jenkins session to use

jenkins_list_viewsC

List all Jenkins views.

Args: session_name: Jenkins session to use

jenkins_get_viewC

Get details about a view and list its jobs.

Args: view_name: View name session_name: Jenkins session to use

jenkins_create_viewA

Create a new Jenkins view.

Args: view_name: Name for the new view view_type: View type — 'list' (default) or 'my' (My View) session_name: Jenkins session to use

jenkins_delete_viewA

Delete a Jenkins view.

⚠️ This only removes the view — jobs in the view are NOT deleted.

Args: view_name: View name to delete session_name: Jenkins session to use

jenkins_add_job_to_viewC

Add a job to an existing view.

Args: view_name: View name job_name: Job name to add to the view session_name: Jenkins session to use

jenkins_list_credentialsB

List all credentials stored in Jenkins.

Args: domain: Credential domain ('_' = global domain, default) store: Credential store ('system' = system store, default) session_name: Jenkins session to use

jenkins_get_credentialB

Get details of a specific Jenkins credential (secrets are masked).

Args: credential_id: Credential ID domain: Credential domain ('_' = global) store: Credential store ('system' = system store) session_name: Jenkins session to use

jenkins_create_credentialA

Create a new credential in Jenkins.

Args: credential_id: Unique ID for the credential credential_type: Type — 'userpass' (username/password), 'secret' (secret text), 'ssh' (SSH key) username: Username (for 'userpass' type) password: Password (for 'userpass' type) or private key (for 'ssh' type) secret: Secret text (for 'secret' type) description: Description of the credential domain: Credential domain ('_' = global) store: Credential store ('system' = system store) session_name: Jenkins session to use

jenkins_delete_credentialC

Delete a credential from Jenkins.

Args: credential_id: Credential ID to delete domain: Credential domain ('_' = global) store: Credential store ('system' = system store) session_name: Jenkins session to use

jenkins_list_pluginsA

List all installed Jenkins plugins with version and status.

Args: session_name: Jenkins session to use

jenkins_get_plugin_infoC

Get detailed information about a specific installed plugin.

Args: plugin_name: Plugin short name (e.g., 'git', 'pipeline-model-definition') session_name: Jenkins session to use

jenkins_install_pluginB

Install a Jenkins plugin.

The plugin will be downloaded and installed. Jenkins may need a restart to activate it.

Args: plugin_name: Plugin short name (e.g., 'git', 'blueocean') version: Specific version to install (empty = latest) session_name: Jenkins session to use

jenkins_list_available_pluginsC

Search available plugins for installation from the Jenkins Update Center.

Args: query: Search query to filter plugins (empty = list all available) session_name: Jenkins session to use

jenkins_list_folder_jobsB

List all jobs inside a Jenkins folder (recursive).

Args: folder_path: Folder path (e.g., 'my-folder' or 'parent/child-folder') session_name: Jenkins session to use

jenkins_create_folderC

Create a new folder in Jenkins.

Args: folder_name: Name for the new folder parent_folder: Parent folder path (empty = root level) description: Folder description session_name: Jenkins session to use

jenkins_get_pipeline_stagesB

Get pipeline stage details and status for a pipeline build.

Shows each stage's name, status, and duration. Requires the Pipeline: REST API plugin.

Args: job_name: Pipeline job name build_number: Build number (0 = last build) session_name: Jenkins session to use

jenkins_replay_pipelineA

Replay a pipeline build, optionally with a modified Groovy script.

This re-runs a pipeline build, allowing you to edit the pipeline script without modifying the Jenkinsfile.

Args: job_name: Pipeline job name build_number: Build number to replay script: Modified pipeline script (empty = use original script) session_name: Jenkins session to use

jenkins_system_infoC

Get comprehensive Jenkins system information.

Shows version, JVM info, system properties, and environment overview.

Args: session_name: Jenkins session to use

jenkins_restartA

Restart the Jenkins server.

Args: safe: If True (default), waits for running builds to finish before restarting. If False, restarts immediately (may abort running builds). session_name: Jenkins session to use

jenkins_quiet_downA

Put Jenkins into quiet-down mode (no new builds will be started).

Running builds will continue but no new builds will be queued. Useful before maintenance or restart.

Args: session_name: Jenkins session to use

jenkins_cancel_quiet_downA

Cancel quiet-down mode and resume normal operations.

Queued builds will begin processing again.

Args: session_name: Jenkins session to use

jenkins_run_groovy_scriptA

Execute a Groovy script on the Jenkins Script Console.

⚠️ This is a powerful admin tool. Scripts run with full Jenkins access.

Common scripts:

  • List all jobs: 'Jenkins.instance.items.each { println it.name }'

  • Get Jenkins version: 'println Jenkins.instance.version'

  • List users: 'Jenkins.instance.securityRealm.getAllUsers().each { println it.id }'

Args: script: Groovy script to execute session_name: Jenkins session to use

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

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/Pawangunjkar/jenkins-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server