Skip to main content

Simple alert helpers for Slack and Telegram using requests.

Project description

toolsalert

Simple alert helpers for Slack and Telegram, implemented using requests.

Install

pip install toolsalert

Usage

from toolsalert import AlertSlack, AlertTelegram

# Slack
slack_alert = AlertSlack(slack_token, slack_channel, bot_name, bot_icon)
slack_alert.send("Hello from Slack")

# Telegram
tg = AlertTelegram(api_token="123456:ABCDEF...", chat_id="123456789")
tg.send("Hello from Telegram")
tg.send_no_preview("<b>HTML</b> message without link preview")
tg.send_photo("https://example.com/some_image.jpg")

Notes

  • Do not hardcode real tokens/webhook URLs in code committed to git.
  • Use environment variables or a secret manager for credentials.

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

toolsalert-0.1.1.tar.gz (4.8 kB view details)

Uploaded Source

Built Distribution

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

toolsalert-0.1.1-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file toolsalert-0.1.1.tar.gz.

File metadata

  • Download URL: toolsalert-0.1.1.tar.gz
  • Upload date:
  • Size: 4.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for toolsalert-0.1.1.tar.gz
Algorithm Hash digest
SHA256 ff5ea04ade88632c0c8146b86a6e1de24ec229a4eea8b24f303c215419b782c2
MD5 141e1b9bd5a895328ba60c005d61ca81
BLAKE2b-256 f0e06b1e347186d3a19ec9e57f49d36d3f180870ec3f8872124dd53898d4a908

See more details on using hashes here.

File details

Details for the file toolsalert-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: toolsalert-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 5.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for toolsalert-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 a91d7bd631fdcca6af39c92de93167d8583ef7d6feceba54eb296c102ca3b826
MD5 1296643e3f49d8157549ba3a6fb7bd79
BLAKE2b-256 bb675df6838547ca6c85374d7d8418b91154b1449b3dbeb46555149e1eb149b6

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