How to set up notifications for conversation events?
Note that we'll use Zendesk as an example here, but this will work for any event in your help desk, as long as they support webhooks. For Intercom, the event that we're looking into would be conversation.rating.added. While Zendesk allows sending these webhook events straight to Slack, other help desks might need a middleman like Zapier to first capture the webhook and then send an appropriate notification to your Slack.
To get yourself more acquainted with webhooks, be sure to check out Zendesk's general guide on them and also how to send them to Slack. The e-mail notification flow is largely similar, but instead of the HTTP Target that we'll explain in the next section, you'd need to create an Email Target instead.
A lot of these steps are covered in Zendesk's Slack guide, but to recap:
Go ahead and set up a new Incoming webhook in Slack
As a Zendesk admin, navigate to Settings β Extensions β Add target
Choose HTTP Target
Add the Incoming webhook's URL that you generated in step 1 as the target URL
Set the target's method to
POST
and the Content type toJSON
You may test the target and pass in an example message, for example
{ "text": "Hello Klaus!" }
If you received the message on Slack, then go ahead and Submit your new HTTP target π
If for some reason you did not receive the message, Zendesk offers some additional debugging information on the API β Target Failures page
We're now ready to configure different triggers that can use this target to send messages to our Slack.
In Zendesk, let's head over to Settings β Business Rules β Triggers
Click Add Trigger and give it a name with a cat emoji (highly important)
We'll leave the conditions up to you, but for our original question,
βSatisfaction
Is
Bad
worked out well. Note that you can mix-and-match the conditions as well.Click Add action and from the two dropdowns, first select
Notify target
and then select the name of the target we previously created.In the Message field, we will enter a JSON payload, that will look like this
{
"text": "You received some feedback on a ticket. <https://kibbles.klausapp.com/conversations?externalTicketId={{ticket.id}}|Review it on Klaus>"
}
Please see our "Link to Klaus from your help desk" article for details on how we construct the link and the externalTicketId
query parameter.
Whenever your trigger's conditions are fulfilled, you will receive a Slack notification.Β
(Optional) Lastly, you can spruce up that Slack message with some advanced formatting and even add custom buttons. Slack has a great Message Formatting tool that lets you preview the JSON payload as a real Slack message.