productivity
Jenkins CLI for Headless Automation
Use the Jenkins CLI for headless automation with headless JSON commands, schema discovery, credentials, and permission controls.
7 functions 6 read 1 write API token auth
Jenkins CLI for Headless Automation
Use KosmoKrator as a non-interactive integration runtime for local automations and wrappers.
Use headless automation when another tool needs a stable local command surface. The Jenkins CLI uses the same integration registry as the TUI, Lua runtime, and MCP gateway, but returns predictable command output for automation.
Command Shape
# Jenkins CLI for Headless Automation
kosmokrator integrations:configure jenkins --set api_token="$JENKINS_API_TOKEN" --enable --read allow --write ask --json
kosmo integrations:call jenkins.jenkins_list_jobs '{}' --json Discovery Before Execution
Agents and scripts can inspect Jenkins docs and schemas before choosing a function.
kosmo integrations:docs jenkins --json
kosmo integrations:docs jenkins.jenkins_list_jobs --json
kosmo integrations:schema jenkins.jenkins_list_jobs --json
kosmo integrations:search "Jenkins" --json
kosmo integrations:list --json Useful Jenkins CLI Functions
| Function | Type | Parameters | Description |
|---|---|---|---|
jenkins.jenkins_list_jobs | Read | none | List all Jenkins jobs. Returns job names, URLs, colors (build status), and basic metadata. |
jenkins.jenkins_get_job | Read | job_name | Get detailed information about a specific Jenkins job, including description, last build, health reports, and parameters. |
jenkins.jenkins_create_job | Write | name, mode, description, config | Create a new Jenkins job. Requires a job name and configuration. |
jenkins.jenkins_list_builds | Read | job_name, status, per_page | List builds for a specific Jenkins job, including build numbers, results, durations, and timestamps. |
jenkins.jenkins_get_build | Read | job_name, build_number | Get detailed information about a specific Jenkins build, including result, duration, console output, artifacts, and change sets. |
jenkins.jenkins_list_nodes | Read | none | List all Jenkins nodes (agents), including name, offline status, and executor count. |
jenkins.jenkins_get_current_user | Read | none | Get the authenticated Jenkins user's profile information, including user ID, full name, and email. |
Automation Notes
- Use
--jsonfor machine-readable output. - Keep credentials out of argv by using environment variables or stored KosmoKrator configuration.
- Configure read/write policy before unattended runs; use
--forceonly for trusted automation. - Use the MCP gateway instead when the agent needs dynamic tool discovery inside a conversation.