alert-me
Multi-Platform Python tool to send notifications to your devices. alert-me allows you to send notifications to your devices using different services.
📝 Table of Contents
📕 About
alert-me is a multi-platform Python tool to send notifications to your devices. It supports different plugins to send notifications via different services.
Available plugins:
- Telegram
- Url
Creating additional plugins is easy. Just create a new class that inherits from Plugin and implements the notify method.
⚙️ Installation
Python repository
The easiest way to get alert-me is through the pypi.org repository. Install it by running the following command:
pip install python-alert
Building from source
To install alert-me from source, clone this repository and run pip install . as follows:
git clone https://github.com/NeverMendel/alert-me.git
cd alert-me
pip install .
📖 Usage
Command line
alert-me can be used from the command line by invoking the alert-me command. It accepts a number of arguments to configure the alert.
alert-me -p telegram <TOKEN> <CHAT_ID> "Hello!"
alert-me -c telegram "Hello!"
alert-me -c email to_email@example.com "subject" "body"
Python
alert-me can be used as a Python module by importing AlertMe.
from alert_me.alert_me import AlertMe
from alert_me.plugins.telegram import TelegramPlugin
from alert_me.config import get_config
alert_me = AlertMe([TelegramPlugin("<TOKEN>", "<CHAT_ID>")])
alert_me.notify("Hello!")
alert_me = AlertMe([get_config("email")])
alert_me.notify("to_email@example.com", "subject", "body")
Config
alert-me can be used to fetch the configuration from a file. The file must be in the INI format and be located in the user home directory (~/.alert-me.ini).
Here is an example of a configuration file:
[telegram]
plugin = telegram
token = <TOKEN>
chat_id = <CHAT_ID>
[email]
plugin = email
smtp_server = <SMTP_SERVER>
smtp_port = <SMTP_PORT>
sender_email = <SENDER_EMAIL>
sender_password = <SENDER_PASSWORD>
Command line arguments
usage: alert-me [-h] (-c CONFIG_UNPROCESSED | -p PLUGIN) [-v] [-vv] [-V] ...
Multi-Platform Python tool to send notifications to your devices
positional arguments:
args Plugin and/or notify arguments
options:
-h, --help show this help message and exit
-c CONFIG_UNPROCESSED, --config CONFIG_UNPROCESSED
Configuration name
syntax: --config=[config_name1],[config_name2],...
example: --config=telegram,email
-p PLUGIN, --plugin PLUGIN
Plugin name
-v, --verbose enable verbose logging
-vv, --extra-verbose enable extra verbose logging
-V, --version show program's version number and exit
License
Metadata
Release files for python-alert 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| python_alert-0.1.0.tar.gz | 8.5 kB | Without provenance | Details for python_alert-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| python_alert-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for python_alert-0.1.0-py3-none-any.whl |
Total release size: 17.7 kB
Release files / python_alert-0.1.0.tar.gz
| Download URL | python_alert-0.1.0.tar.gz |
|---|---|
| Size | 8.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1ac773b07ccfc086c048ed1a179f418547b4ed1c838133503d4972bef5b0472e
|
|
BLAKE2b-256 checksum How to use checksums |
860041d268382c7627e3462903342c41bbc0366b610251aeac782244a0f6e05c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.0.0 CPython/3.10.12
|
Release files / python_alert-0.1.0-py3-none-any.whl
| Download URL | python_alert-0.1.0-py3-none-any.whl |
|---|---|
| Size | 9.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ab5d12cd256457cccd50c89ce62a65ec276c8f158d256eab74557ca28b8b9f6d
|
|
BLAKE2b-256 checksum How to use checksums |
3e614dd7b4bee986bbd5883a99549feb254e755fa96d38c66e5f01e50b56ff0d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.0.0 CPython/3.10.12
|
Security for python-alert 0.1.0
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.