Send heartbeat to uptime kuma.
Project description
uk-send
Send a heartbeat to uptime kuma in a separate thread without blocking the main program.
Examples:
Base usage
import uk_send as uk
url = "https://uk.example.xom/api/push/YhYAt5t6qiRJ60b16g8326vAGYQw7Ty0"
uk.send("test message", url=url)
Env usage
UK_URL="https://uk.example.xom/api/push/YhYAt5t6qiRJ60b16g8326vAGYQw7Ty0"
UK_PROXY="http://127.0.0.1:1080"
import uk_send as uk
uk.send("test message")
Defaults:
import uk_send as uk
url = "https://uk.example.xom/api/push/YhYAt5t6qiRJ60b16g8326vAGYQw7Ty0"
uk.send(
msg="test message", # default ""
url=url, # required
ping=1, # default 1
status="up", # default "up"
proxy="http://127.0.0.1:1080", # default None
)
Options:
- uk-send - Base module, uses standart urllib module. No additional dependences.
- uk-send[requests] - Uses requests module.
- uk-send[httpx] - Uses httpx module.
- uk-send[requests-socks] - Uses request module. Supports socks5 proxy.
- uk-send[httpx-socks] - Uses httpx module. Supports sosks5 proxy.
Priority
Send modules:
The uk-send module uses modules in the next priority if they are available:
No-proxy or http-proxy:
- httpx
- requests
- urllib
Socks-proxy:
- httpx[socks]
- requests[socks]
- ERROR
Parameters
URL:
- function argument
- env
Proxy:
- function argument
- env
Message:
- function argument
- url parameter
- default ("")
Status:
- function argument
- url parameter
- default ("up")
Ping:
- function argument
- url parameter
- default (1)
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
uk_send-0.1.9.tar.gz
(8.4 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file uk_send-0.1.9.tar.gz.
File metadata
- Download URL: uk_send-0.1.9.tar.gz
- Upload date:
- Size: 8.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.22 {"installer":{"name":"uv","version":"0.9.22","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6bff2d4fe06d7e0ef6dffb76b12b08ac9cb3c1bb5bc64861bc607e167f166536
|
|
| MD5 |
c369090dcfe014fbbe95b4d0bc33f3fd
|
|
| BLAKE2b-256 |
c12e1974e6f21c6754a9c45a1dd5293bc7792dd47f8625287fa8f56c02c4123b
|
File details
Details for the file uk_send-0.1.9-py3-none-any.whl.
File metadata
- Download URL: uk_send-0.1.9-py3-none-any.whl
- Upload date:
- Size: 9.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.9.22 {"installer":{"name":"uv","version":"0.9.22","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9c71ad5d9cb5dfa9af5cb33eb46869973c6b9f40a363a433ac819d387c743267
|
|
| MD5 |
7fd680d4309234737e1bdf992b609016
|
|
| BLAKE2b-256 |
d84cb22d2862bf6468e38293b6094edd0d3be18b0ecf25b25380f8350d1a2f3a
|