lucassimon / notify-via-slack

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Notify via slack

Install: pip install notify-via-slack

Usage

Create an app in slack api

Save the bot token

Copy the .env.example to .env cp .env.example .env

Replace the SLACK_BOT_TOKEN

Send a message

slack.notify import SlackNotify

handler = SlackNotify(app_name='My app name')
handler.notify(message='some message', emit_log=True, is_error=True)

About


Languages

Language:Python 72.5%Language:Makefile 27.5%