Alerting setup
Below you’ll find a short tutorial on how to setup the Robots.txt alerts to Slack or MS Teams.
Jump to:
Microsoft Teams Channel
Go to Workflows in Teams, click on “New flow”.

Select the workflow “Post to a channel when a webhook request is received”. Then click “Next”.
You need to choose a Teams team and a channel to sent your alert to. In my example I made a “Jan Personal” team and the channel “Alerter”.

Then you should get a confirmation with a workflow URL (an endpoint which my tool can then call). Copy this URL and keep it somewhere on the side (eg. a notepad).

Now go to my Robots.txt tool interface and paste the webhook URL in the correct field. DO NOT FORGET TO SAVE!

After you clicked “Save alert”, click on “Test alert” at the bottom.
This will send a test alert to your Teams channel with a dummy message. If that arrives correctly then your config works. Hooray!
Slack channel
Go to https://api.slack.com/apps/ (make sure you have admin of equivalent right in the workspace so you can make Apps).
Disclaimer: You don’t need a paid Slack workspace but you may require certain edit rights (not always though). I used to need owner/admin rights in a corporate Slack at my previous job. But in my (personal) free Slack workspace, I didn’t need anything special. So do check if you experience restrictions.
Click on “Create New App”.

Choose “From scratch”:

Choose an app name (you can choose, I recommend something descriptive) and select your Slack workspace. Click on “Create App”.

You should get a new screen with lots of configuration options. In the left menu, go to “OAuth & Permissions”.

Inside “OAuth & Permissions”, scroll to the “Scopes” section. Click “Add an OAuth Scope” under Bot Token Scopes.

Add “chat:write”.

Scroll to the top, to “OAuth Tokens” and click on “Install to [workspace]“.

Complete the next step. You should now see the screen below.
Copy the OAuth token. TIP: Paste it in a notepad, you’ll need it a few steps later.

Now you need to do one more thing inside your Slack.
You need to add (/invite) your new Slack bot into your channel. Best way to do that is to simply send a message in your channel and tagging your bot. Example:
“Random message to tag @robots.txt-alert Bot in this channel”.

Then you get a popup. Click “Add them”. The setup inside Slack should be done now.

Now go back to my Robots.txt tool interface and paste the token in the “key” field. Click on “Save alert”!

AĆ fter you clicked “Save alert”, click on “Test alert” at the bottom.
This will send a test alert to your Slack channel with a dummy message. If that arrives correctly then your config works. Hooray!