There are lots of different event types you could add, but for the purposes of our tutorial let's add two event subscriptions - app_mention which sends events when someone mentions your bot, and message.channels which sends events when a new message is posted in a public channel.For our bot, we're interested in the Bot Events, so click on the Add Bot User Event button. Then you'll add some individual event subscriptions.This URL needs to be verified first, as outlined in the Events API docs. You'll need to configure the Request URL that the data payloads will be pushed to.Switch the Enable Events toggle to on and you'll be presented with a new screen of options.From your app's settings, click the Event Subscriptions feature in the navigation menu.Giving your bot access to the Events API is pretty simple: When these events happen, a data payload will be sent to your bot, and it can use that data to form a useful response. It gives a bot a way to react to posted messages, changes to channels, and other activities that happen in Slack. The Events API is a bot's equivalent of eyes and ears. Great, you've just created a bouncing baby bot! Don't leave the app settings yet though, there's just one more bit of configuration left to do. Once you've completed these fields, click the Add Bot User button and then Save Changes.
When disabled, you'll have to programmatically set its online presence. This modification is an incrementing number appended to the username - so might become Always Show My Bot as Online - we recommend you enable this feature, so that your bot always appears to be ready to receive input (which it probably will be). This username may be modified slightly from the default when it is installed to a workspace where that username is already reserved.
This article describes an outdated approach to Slack apps.