Skip to main content

uptime-kuma-api-ng

PyPI Docs CodeQL Security scan OpenSSF Scorecard

Maintained fork of lucasheld/uptime-kuma-api, which appears abandoned (13 open PRs, 23 open issues, none merged/closed since 2023 as of this fork). Published as uptime-kuma-api-ng on PyPI since the original name is taken; the importable module is still uptime_kuma_api, so only your pip install line changes. Fixes add_monitor()/edit_monitor() against Uptime Kuma 2.x (missing conditions field) plus a delete_monitor() type bug. See MODERNIZATION_PLAN.md for deferred, larger-scope work (full 2.x audit, tests, CI, upstream PR/issue triage).

Maintenance model: this fork is maintained primarily by an AI coding agent (Claude), under human supervision, not by a human reading every line. Changes are scoped, reviewed, and merged with that in mind. There is no warranty and no guarantee of correctness, security, or continued maintenance — use at your own risk, pin a version, and review the diff before upgrading. Issues and PRs are welcome and will be triaged and reviewed (by the human maintainer and/or AI) before merging, same as any other project — being AI-assisted doesn't mean auto-merged.

uptime-kuma-api

A wrapper for the Uptime Kuma Socket.IO API

uptime-kuma-api is a Python wrapper for the Uptime Kuma Socket.IO API.

This package was developed to configure Uptime Kuma with Ansible. The Ansible collection can be found at https://github.com/lucasheld/ansible-uptime-kuma.

Python version 3.7+ is required.

Supported Uptime Kuma versions:

Uptime Kuma uptime-kuma-api
1.21.3 - 1.23.2 1.0.0 - 1.2.1
1.17.0 - 1.21.2 0.1.0 - 0.13.0

Security

This client never logs credentials (no print/logging calls anywhere in the library) and sends your username/password/token only to the Uptime Kuma server URL you provide, over the connection you configure. TLS verification is on by default.

Ongoing scanning, all free and running on every push/PR:

  • CodeQL static analysis (GitHub's own SAST).
  • Bandit for Python-specific security anti-patterns.
  • pip-audit checking dependencies against the OSV vulnerability database, plus Dependabot opening PRs when a dependency has a fix available.
  • OpenSSF Scorecard for overall repo security posture (branch protection, pinned dependencies, SAST coverage, etc.) — this one reports a 0-10 score, not a pass/fail; click the badge for the live breakdown.

Found a real security issue? Please open a GitHub issue — there's no dedicated security contact for this fork.

Installation

This fork is published on the Python Package Index (PyPI) as uptime-kuma-api-ng (the original uptime-kuma-api name is taken by the unmaintained upstream project). The importable module is still uptime_kuma_api — only your pip install line changes.

You can install it using pip:

pip install uptime-kuma-api-ng

Documentation

The API Reference is available at rozsasarpi.github.io/uptime-kuma-api.

Example

Once you have installed the python package, you can use it to communicate with an Uptime Kuma instance.

To do so, import UptimeKumaApi from the library and specify the Uptime Kuma server url (e.g. 'http://127.0.0.1:3001'), username and password to initialize the connection.

>>> from uptime_kuma_api import UptimeKumaApi, MonitorType
>>> api = UptimeKumaApi('INSERT_URL')
>>> api.login('INSERT_USERNAME', 'INSERT_PASSWORD')

Now you can call one of the existing methods of the instance. For example create a new monitor:

>>> result = api.add_monitor(type=MonitorType.HTTP, name="Google", url="https://google.com")
>>> print(result)
{'msg': 'Added Successfully.', 'monitorID': 1}

At the end, the connection to the API must be disconnected so that the program does not block.

>>> api.disconnect()

With a context manager, the disconnect method is called automatically:

from uptime_kuma_api import UptimeKumaApi, MonitorType

with UptimeKumaApi('INSERT_URL') as api:
    api.login('INSERT_USERNAME', 'INSERT_PASSWORD')
    api.add_monitor(
        type=MonitorType.HTTP,
        name="Google",
        url="https://google.com"
    )

Release files for uptime-kuma-api-ng 1.4.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for uptime-kuma-api-ng 1.4.4
File Size Uploaded
uptime_kuma_api_ng-1.4.4.tar.gz 57.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for uptime-kuma-api-ng 1.4.4
File Interpreter ABI Platform
uptime_kuma_api_ng-1.4.4-py3-none-any.whl Python 3 none any Details

Total release size: 107.5 kB

Release files / uptime_kuma_api_ng-1.4.4.tar.gz

Download URL uptime_kuma_api_ng-1.4.4.tar.gz
Size 57.7 kB
Tags Source
SHA-256 checksum
How to use checksums
611055f8f76066a3ba6c44f2036e905274c52b538e1ab676dc49db6e79b901a0
BLAKE2b-256 checksum
How to use checksums
ebdf6e4ed58aac80908fd95cebc82441cc2c3eb20a3bea0b329ba9be7cd6bdb3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 1, 2026.

Transparency log

Release files / uptime_kuma_api_ng-1.4.4-py3-none-any.whl

Download URL uptime_kuma_api_ng-1.4.4-py3-none-any.whl
Size 49.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6fd6ee5bcff28872fb90fdd628e4c536b2f006c7c600e90cbe0b98c9791cc3a2
BLAKE2b-256 checksum
How to use checksums
be6cfb517460d0bc1e4861635a8b5d7fbc1f252d586fc010a87b70e5509b8f73
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 1, 2026.

Transparency log

Release history Release notifications | RSS feed

1.9.0

2 release files

1.8.0

2 release files

1.7.1

2 release files

1.5.0

2 release files

This release

1.4.4 This release

2 release files

1.4.3

2 release files

1.4.2

2 release files

1.4.1

2 release files

1.3.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page