--- id: api4jenkins version: "2.1.0" license: Apache 2.0 license_treatment: permissive maintenance: active --- # api4jenkins — Jenkins Python Client License: permissive · Maintenance: active · Downloads: 522.4K/mo ## What it is and what it does api4jenkins is a Python client library that wraps the Jenkins REST API, letting you programmatically interact with Jenkins from Python code. It offers both sync and async APIs, so you can choose blocking or non-blocking calls depending on your use case. The library models Jenkins concepts (jobs, builds, agents) as Python classes, making it straightforward to query attributes, create jobs from XML, trigger builds, and stream build output. The package is built on httpx for HTTP transport and supports Python 3.8 through 3.12. It's actively maintained, carries no known vulnerabilities, and is classified as production-stable. The single external dependency keeps installation friction low. Use it for: - Automate Jenkins job creation and configuration from Python scripts or CI/CD pipelines. - Poll Jenkins builds programmatically and stream or parse build logs in real time. - Write integration tests that spin up Jenkins jobs and verify their output without manual intervention. - Build dashboards or monitoring tools that query Jenkins job status and build history asynchronously. - Migrate jobs or build data between Jenkins instances by reading and re-creating them via the API. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. A Python client library for the Jenkins REST API that provides both synchronous and asynchronous interfaces to query, create, and manage Jenkins jobs and builds. Yes. The package is actively maintained, has no known vulnerabilities, carries a permissive license, and offers low installation friction. It provides a clean, Pythonic interface to Jenkins automation—both sync and async—making it suitable for CI/CD integration, testing, and operational scripting. Install it if you need to automate or integrate with Jenkins from Python. ## Install pip install api4jenkins uv add api4jenkins poetry add api4jenkins ## Installing api4jenkins Before you install: Low friction: pure Python wheel with a single runtime dependency (httpx). Actively maintained with recent commits and production-stable status. License in practice: Apache 2.0 permissive license allows commercial and private use with minimal restrictions. Quickstart: pip install api4jenkins from api4jenkins import Jenkins client = Jenkins('http://127.0.0.1:8080/', auth=('admin', 'admin')) print(client.version) build = client.build_job('path/to/job') for line in build.get_build().progressive_output(): print(line) Requires a running Jenkins instance accessible at the provided URL with valid credentials. Verify before relying: - Whether httpx is bundled or must be installed separately (likely separate, given it's listed as a runtime dependency). - Performance characteristics when managing large numbers of jobs or builds concurrently. ## Package facts - License: Apache 2.0 (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 522.4K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags jenkins python client, jenkins api wrapper, jenkins automation, jenkins job management, async jenkins client, jenkins ci/cd integration, jenkins rest api python, jenkins-automation, async-support, ci-cd [View on SkillFed](https://skillfed.io/packages/api4jenkins) · [View on PyPI](https://pypi.org/project/api4jenkins/)