Freshdesk
Freshdesk is a cloud-based software that helps streamline customer support. Coupled with the power of xMatters, this workflow:
- Quickly notifies the agent or group that they've been assigned to a ticket using their preferred devices.
- Automatically updates the ticket with information about the notification, including who responded and how, and includes any comments they added.
How it works
When a ticket meets a specified threshold in Freshdesk, it sends a JSON-formatted webhook to xMatters. A Freshdesk trigger in xMatters parses the webhook and initiates a flow. The webhook includes essential alert data you can use to enrich notifications to users or when building automated tasks. Freshdesk agents are targeted based on mapping that connects their Freshdesk email address to their xMatters work email address. If these addresses are not the same, you will need to open the workflow in Flow Designer and update the Find User step in the Agent flow.
Prerequisite
To enable automatic ticket assignment, you need to map users in xMatters to their Freshdesk account IDs. You can do this by creating a custom user property in xMatters that stores the Freshdesk account ID.
- Create a custom user property in xMatters, making sure you name the field "Freshdesk Email or User ID". This name is important (and case-sensitive!) as the code relies on this specific text to find the Freshdesk username.
- For each user, populate this field with the user's Freshdesk account ID. You can use the User Upload feature in xMatters to populate custom user properties if you have many users to update.
Install the workflow
- Go to the Workflow Templates page and click the Freshdesk tile.
- On the Set up the Workflow tab, give the workflow a name that identifies its purpose (this must be unique in your instance), add an optional description, and set the default incident type (if applicable). Any built-in Initiate Incident steps in the workflow will automatically be set to the selected incident type.
- You can edit these later, if needed.
- Click Next to set up the connection.
- Copy the trigger URL — you’ll use this to configure the webhook in Freshdesk.
- You can copy the Configuration Payload to configure the signal in the source application.
- Click Open Workflow.
- Go to the Freshdesk Alerts - Group Assigned without Agent trigger, and double-click to open the configuration screen.
- Copy the initiation URL. This is the second URL required to configure Freshdesk.
- Close the window.
- Now that the workflow is installed and you have the two trigger URLs, let's to go to Freshdesk and configure it to communicate with xMatters.
To have Freshdesk send alerts to the flow trigger, you need to configure two automations: one for Groups and one for Agents, then set a webhook to use the trigger URL.
Use these steps to first create the Group Automation, then the Agent Automation. The order of creation is important to have Freshdesk tickets notify the right people at the right time.
To configure a Freshdesk Automation:
- In Freshdesk, click the Admin icon.
- Go to the Workflows section and click Automations.
- On the Ticket Creation tab, go to Executing first matching rule and click New rule.
- In the On tickets with these properties section, set the fields for your query. Group Automation
Use these steps to create the Group Automation. Once you've filled in the fields, go to Step 5 to continue the configuration. You cannot configure a Group Automation and an Agent Automation at the same time.
- Select Match ALL of the below.
- From the drop-down menus, select the following options:
- In Tickets
- if Group
- Is not
- None
- Under the AND parameter, select the following options:
- In Tickets
- if Assigned agent
- Is
- None
- Leave Check agent status de-selected
- Click Add new condition and set the conditon to AND.
- Select Match ANY of the below.
- From the drop-down menus select the following options:
- In Tickets
- if Priority
- Is
- Select the priority levels that will trigger the alert in xMatters. For example: Medium, High, Urgent
Agent AutomationUse these steps after completing steps 1 - 3 to create a new Agent Automation. Once you've filled in the fields, go to Step 5 to continue the configuration.
- Select Match ANY of the below.
- From the drop-down menus, select the following options:
- In Tickets
- if Assigned agent
- Is
- Any
- Leave Check agent status de-selected.
- Click Add new condition and set the condition to AND.
- Select Match ANY of the below.
- From the drop-down menus select the following options:
- In Tickets
- if Priority
- Is
- Select the priority levels that will trigger the alert in xMatters. For example: Medium, High, Urgent
- In the Perform these actions section, set the following fields:
- Select Trigger webhook from the drop-down menu.
- Request type: Select POST.
- URL: Paste the URL you copied from the trigger in Flow Designer.
- For Group Automation, use the URL you obtained after opening the workflow and accessing the Freshdesk Alerts - Group Assigned without Agent trigger settings.
- For Agent Automation, use the URL you obtained when installing the workflow.
- Encoding: JSON
- Content: Select the Advanced radio button and paste the configuration payload.Copy
{
"ticketId": "{{ticket.id}}",
"description": "{{ticket.description_text}}",
"subject": "{{ticket.subject}}",
"ticketURL": "{{ticket.url}}",
"groupName": "{{ticket.group.name}}",
"priority": "{{ticket.priority}}",
"type": "{{ticket.ticket_type}}",
"requester": "{{ticket.contact.name}}",
"agentName": "{{ticket.agent.name}}",
"agentEmail": "{{ticket.agent.email}}",
"latestPublicComment": "{{ticket.latest_public_comment}}",
"status": "{{ticket.status}}",
"tags": "{{ticket.tags}}"
}
- Click Preview and Save to review the rule.
- Click Save.
Once you have created the Group Automation, go back to step 1 to create the Agent Automation.
When both automations are configured you can use the webhook to trigger automated flows, send alerts, and initiate incidents, though we always recommend testing before putting things into use.
How to use the workflow
When a condition you've set fires, it sends a signal to xMatters, which creates an alert and notifies the individual or the on-call members of groups you set as recipients in the webhook URL. When the trigger receives a signal saying the issue is resolved, it automatically terminates related alerts in xMatters.
The person responding to the notification has the following response options:
- Acknowledge: Acknowledges the notifications and stops escalations.
- Add Note: Add a note to the Freshdesk ticket.
- Initiate Incident: Initiates an incident in xMatters.
- Resolve: Resolves and closes the FD ticketthe xMatters alert and stops notifying all targeted recipients.
The group responding to the notification has the following response options:
- Assign to me: A group member takes ownership of the ticket. The FD ticket is updated with the assignee's name.
- Add Note: Add a comment to the ticket.
- Escalate: Immediately escalates the alert to the next on-call resolver in the group.
- Initiate Incident: Initiates an incident in xMatters.
- Resolve: Resolves and closes the FD ticket. the xMatters alert and stops notifying all targeted recipients.
Next Steps
Now that you've installed the workflow, you can use it as-is, or customize it to suit your needs better. Here are some examples of things you can add to the workflow to customize it:
- Use Slack, Zoom, and Microsoft Teams steps to add collaboration channels to the flow.
- Update the message sent to resolvers to include the information most relevant to your team.
- Use the Freshdesk trigger to build your own custom flows.