Skip to main content

this sdk upload with 2025-05-09, uptime_kuma_api_v2, support uptime kuma 2.0.0-beta.2, 支持 Uptime kuma 2.0.0-beta.2 版本的sdk

Project description

功能特点:

  • 基于 https://github.com/lucasheld/uptime-kuma-api 改进,以便支持2.0 API
  • 支持 Uptime Kuma 2.0.0-beta.2 版本
  • 注意使用try/finally关闭链接,否则会导致timeout问题,原因未知,可能是uptime的问题

超时问题解决:

from uptime_kuma_api_v2 import UptimeKumaApi
if __name__ == '__main__':
    try:
        api = UptimeKumaApi('http://localhost:3001')
        api.login('admin', 'admin')
        monitor_list = api.get_monitors() # get all monitors
        print(monitor_list)
    except Exception as e:
        # print("Connection was unsuccessfull")
        raise e
    finally:
        # !!任务结束后自动断开链接,防止阻塞程序(不断开会引起下一次操作timeout)
        api.disconnect()

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

uptime_kuma_api_v2_0_1-2.0.0b2.tar.gz (2.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

uptime_kuma_api_v2_0_1-2.0.0b2-py3-none-any.whl (2.6 kB view details)

Uploaded Python 3

File details

Details for the file uptime_kuma_api_v2_0_1-2.0.0b2.tar.gz.

File metadata

File hashes

Hashes for uptime_kuma_api_v2_0_1-2.0.0b2.tar.gz
Algorithm Hash digest
SHA256 9fc83f474c156a30f642f0c4996c821dbad14453f77c46ea6a8e005fa3277beb
MD5 f395cac84ee527dff966582f542e1230
BLAKE2b-256 5af3a2fa5b46a4bdd1b14d9850360a23fd40990ddfcdd0f866202ed7dd3d6923

See more details on using hashes here.

File details

Details for the file uptime_kuma_api_v2_0_1-2.0.0b2-py3-none-any.whl.

File metadata

File hashes

Hashes for uptime_kuma_api_v2_0_1-2.0.0b2-py3-none-any.whl
Algorithm Hash digest
SHA256 2bb785744543905f31e33806d2427222ac2450136a95e88a864397ce8569f7cf
MD5 312c3dfb724e5f5d732fba67cb990788
BLAKE2b-256 21e32f741449b71fbfdf0870d76018e88fcc9a62d5f3a97a8fa6fcc79418b7c5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page