-
Notifications
You must be signed in to change notification settings - Fork 0
Working with Slack
Notifly can be used with Slack too! Truly Flexible! Isn't it?🤩🎉
✅ Create app.
✅ Visit this page to work with the Slack API.
✅ Go to Create an App.
✅ Enter App Name and select workspace. Click Create App.
✅ Under Add features and functionality select Incoming Webhooks and Activate Incoming Webhooks.
✅ Scroll down, select Add New Webhook to Workspace and select a channel from the drop-down.
This channel name is used as an argument in the sample code. Click Allow.
✅ Select OAuth & Permissions from left-sidebar.
✅ Under Scopes > Bot Token Scopes click Add an OAuth Scope and add the following scopes,
chat:write chat:write.public files:write users:write.
✅ Scroll up, under OAuth Tokens for Your Team copy the Bot User OAuth Access Token to use in sample code.
✅ Click Reinstall to Workspace, select channel and click Allow.
- Create a
sample.pyfile. - Paste the following code.
from notifly import slack x= slack.Notifier('token', channel='channel-name') #create object of class Notiflier x.send_message('message') #send message x.send_file("image or file address") #send image/file - Run the code! Done and Dusted!🤩🎉 Go to the next page to explore the TensorFlow Integration!🤩✌