pyzabbix
Zabbix API Python interface
What it is and what it does
PyZabbix is a Python wrapper around the Zabbix API that lets you query and manage Zabbix monitoring infrastructure programmatically. It handles HTTP communication, JSON-RPC formatting, and session management so you can focus on automation tasks. The package wraps the Zabbix API's method calls into Python objects—for example, `zapi.host.get()` translates to a Zabbix API call to retrieve hosts.
The library supports both username/password and API token authentication (Zabbix 5.4+), and exposes the underlying requests Session object so you can customize HTTP behavior—enabling SSL verification control, HTTP auth, timeouts, and custom headers. It's designed for administrators and developers building monitoring automation, reporting, or integration workflows with Zabbix.
Use it for:
- Automate host and item discovery, creation, or updates across multiple Zabbix instances.
- Build monitoring dashboards or reports by querying historical data and events from Zabbix.
- Integrate Zabbix alerts with external systems (ticketing, messaging, incident management).
- Bulk-manage user accounts, host groups, or monitoring templates via script.
- Monitor Zabbix itself—query API version, server status, or configuration for compliance checks.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
PyZabbix provides a Python interface to the Zabbix API, enabling programmatic access to query and manage Zabbix monitoring infrastructure through HTTP requests.
Yes, with conditions. PyZabbix is a stable, low-friction library with no known vulnerabilities and solid community adoption. However, the last release was over 970 days ago and the project is marked as aging. If you need to integrate Python with Zabbix 4.0–6.4, it is a reliable choice; verify compatibility with your Zabbix version first, and monitor the repository for updates if you deploy to newer Zabbix releases.
Install
pyzabbix on PyPI
pip
pip install pyzabbixuv
uv add pyzabbixpoetry
poetry add pyzabbixInstalling pyzabbix
Before you install
Low install friction; depends only on requests and packaging. Maintenance status is aging—last release was 2023-12-18, over 970 days ago, though the repository remains active with recent commits and moderate community engagement (983 stars).
License in practice
Licensed under LGPL 2.1 (copyleft). You may use and modify the package freely, but derivative works must also be distributed under LGPL 2.1; proprietary applications linking to this library should review copyleft obligations.
Quickstart
pip install pyzabbix
from pyzabbix import ZabbixAPI
zapi = ZabbixAPI("http://zabbixserver.example.com")
zapi.login("zabbix user", "zabbix pass")
print("Connected to Zabbix API Version %s" % zapi.api_version())
for h in zapi.host.get(output="extend"):
print(h['hostid'])
Requires a running Zabbix server instance and valid credentials; tested against Zabbix 4.0 LTS, 5.0 LTS, 6.0 LTS, and 6.4.
Verify before relying
- Whether the package is actively maintained or in maintenance-only mode given the 970-day gap since last release.
- Compatibility with Zabbix versions beyond 6.4.
- Performance characteristics when querying large datasets or high-frequency API calls.
Package facts
| License | LGPL (copyleft) |
| Python support | supports the current Python release (>=3.6) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 2 — requests, packaging |
| Maintenance | aging — 970 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 620,623/month — #5,725 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: pyzabbix-1.3.1-py3-none-any.whl
Keywords: zabbix, monitoring, api
Tags
More Monitoring packages
Wraps any iterable to display a real-time…
copyleft · top 100 on PyPI
opentelemetry-semantic-conventionsProvides generated Python code for…
permissive · top 100 on PyPI
opentelemetry-sdkProvides the reference implementation of the…
permissive · top 100 on PyPI
opentelemetry-apiProvides the abstract API and interfaces for…
permissive · top 100 on PyPI
opentelemetry-exporter-otlp-proto-httpExports OpenTelemetry observability data to an…
permissive · top 1,000 on PyPI
opentelemetry-instrumentationProvides automatic instrumentation commands and…
permissive · top 1,000 on PyPI
py-zabbixProvides Python bindings to query and interact…
copyleft · top 15,000 on PyPI
zabbix-apiProvides a Python client library for…
copyleft · top 15,000 on PyPI
zabbix-utilsProvides Python bindings for Zabbix API,…
permissive · top 15,000 on PyPI
google-analytics-adminPython client library for the Google Analytics…
permissive · top 1,000 on PyPI
lazr.restfulclientA programmable HTTP client library for…
copyleft · top 15,000 on PyPI
google-cloud-monitoring-dashboardsPython client library for Google Cloud…
permissive · top 15,000 on PyPI
google-cloud-monitoringPython client library for Google Cloud…
permissive · top 1,000 on PyPI
kanboardA Python client library that wraps the Kanboard…
permissive · top 15,000 on PyPI
mux-pythonOfficial Python wrapper for the Mux API,…
permissive · top 5,000 on PyPI
zulipPython client library for sending and receiving…
permissive · top 15,000 on PyPI