Health notifications
SquaredUp Cloud supports sending notifications when the health of a workspace changes.
Sending notifications requires a channel to be configured in our platform for the target system. It may also require channel configuration in the target system. The supported targets are:
Teams Webhook
Sending alerts to a Microsoft Teams channel is simple to configure:
Go to the Teams channel and select the Connectors option.
From the list of connectors, choose the Incoming Webhook connector and add it to the channel.
Give the webhook connector a name and icon. It makes sense to use a SquaredUp Cloud name and icon to make it clear that the alerts are coming from SquaredUp Cloud.
Click Create and you should be given a webhook URL.
Copy the webhook URL and then click Done.
Now use the webhook URL to configure the channel in SquaredUp Cloud:
In SquaredUp Cloud browse to Settings and then click Notifications.
Click Add new channel and then select the channel from the dropdown.
Display Name:
Enter a name for your channel. This helps you to identify this channel in the list of your channels.
URL:
Paste the webhook URL to configure the channel in SquaredUp Cloud.
Test:
Use the Test button to send a test notification and check that it is working as expected.
Slack
There are two ways to configure notifications:
The API approach is more complex to configure, but more flexible. In particular, it allows notifications to be sent to multiple Slack channels, whereas a Slack webhook is tied to a specific Slack channel.
If you are likely to configure multiple SquaredUp Cloud notification channels to target different Slack channels, the API approach may be preferable. If you are only targeting a single Slack channel, the webhook approach should suffice.
Slack API
You will need to create a Slack app. Go to https://api.slack.com/apps and click on Create New App.
Choose From scratch, specify a name for the app and the Slack workspace that hosts the Slack channels you want to send notifications to.
Configure the app icon and description. You can use whatever name, description and icon you would like, but it makes sense for them to refer to SquaredUp Cloud so that users can clearly see where the notifications are originating from.
Select Add features and functionality and then choose the Permissions option.
Configure the chat:write permission to Send messages as @squaredup_alerts.
Configure the chat:write.public permission to Send messages to channels.
Click Install to Workspace.
You should now be given a token.
Now use the token to configure the channel in SquaredUp Cloud:
In SquaredUp Cloud browse to Settings and then click Notifications.
Click Add new channel and then select the channel from the dropdown.
Display Name:
Enter a name for your channel. This helps you to identify this channel in the list of your channels.
Token:
Paste the API token in here.
You can use the same token to configure multiple SquaredUp Cloud channels, each targeting a different Slack channel.
Slack channel:
Enter the destination/target Slack channel for messages to be delivered to.
You can specify public or private Slack channels, but for private channels the Slack app you created must be added to the Slack channel (type
/invite
in the Slack channel).Test:
Use the Test button to send a test notification and check that it is working as expected.
In Slack, when you click the View button in the notification you may get a warning triangle beside it. To fix this, add
https://api.squaredup.com/api/slack_interaction
as the Interaction URL.
Slack Webhook
You will need to create a Slack app. Go to https://api.slack.com/apps and click on Create New App.
Choose From scratch, specify a name for the app and the Slack workspace that hosts the Slack channels you want to send notifications to.
Configure the app icon and description. You can use whatever name, description and icon you would like, but it makes sense for them to refer to SquaredUp Cloud so that users can clearly see where the notifications are originating from.
Go to Incoming Webhooks and enable the Activate Incoming Webhooks option.
Click Add new Webhook to Workspace and choose the Slack channel you want to target.
Copy the URL.
Now use the webhook URL to configure the channel in SquaredUp Cloud:
In SquaredUp Cloud browse to Settings and then click Notifications.
Click Add new channel and then select the channel from the dropdown.
Display Name:
Enter a name for your channel. This helps you to identify this channel in the list of your channels.
URL:
Paste the webhook URL to configure the channel in SquaredUp Cloud.
Test:
Use the Test button to send a test notification and check that it is working as expected.
In Slack, when you click the View button in the notification you may get a warning triangle beside it. To fix this, add
https://api.squaredup.com/api/slack_interaction
as the Interaction URL.
ServiceNow
No configuration is required within ServiceNow. However, you may want to create a specific user within ServiceNow to use with the SquaredUp Cloud channel. The user will appear as the caller on ServiceNow incidents that are created by SquaredUp Cloud. The user will need permission to create and add comments to incidents. Permission to change the state of incidents (e.g. mark as resolved) is not required.
Configure the channel in SquaredUp Cloud:
In SquaredUp Cloud browse to Settings and then click Notifications.
Click Add new channel and then select the channel from the dropdown.
Display Name:
Enter a name for your channel. This helps you to identify this channel in the list of your channels.
Username:
Enter your ServiceNow username.
Password:
Enter your ServiceNow password.
URL:
Enter the URL of your ServiceNow instance.
Test:
Use the Test button to send a test notification and check that it is working as expected.
Custom
This option allows any webhook (HTTP POST endpoint) to be used to send notifications.
An example would be to use a third-party service like https://apify.com/ to send an email.
The JSON body of the webhook request is totally customizable, using inserts to specify elements of the notification – including the name of the monitored entity (e.g. SquaredUp Cloud Workspace name), the previous and new health states, and a link back to the SquaredUp Cloud app.
This is an example of the JSON body:
{
"text": "{{stateSymbol}} {{name}} changed from {{oldState}} to {{newState}}.",
"link": "{{link}}"
}
This is just an example, and will need to be edited to match the requirements of the particular webhook being used. For example, this JSON is in the structure required for sending emails through apify.com:
{
"subject": "{{stateSymbol}} {{name}} has changed from {{oldState}} to {{newState}}.",
"html": "Hi there t<p>{{stateSymbol}} The health of <b><a href='{{link}}'>{{name}}</a></b> has changed from <b>{{oldState}}</b> to <b>{{newState}}</b>.<p style='color:blue;font-size:0.9em''><em>Brought to you by SquaredUp Alerts™</em>",
"to": "sue.bloggs@squaredup.com"
}
The SquaredUp Cloud channel configuration requires the webhook URL and JSON:
In SquaredUp Cloud browse to Settings and then click Notifications.
Click Add new channel and then select the channel from the dropdown.
Display Name:
Enter a name for your channel. This helps you to identify this channel in the list of your channels.
URL:
Paste the webhook URL to configure the channel in SquaredUp Cloud.
Body:
Enter the JSON body for the channel.
Test:
Use the Test button to send a test notification and check that it is working as expected.
Comments
0 comments
Please sign in to leave a comment.