This tutorial explains how to set up a Facebook Help Desk for Raise Complaint Journey (for Abc Broadband, as an example) using Zendesk Custom Integration. 

Following is the simple explanation of the journey:

  1. Customer visits ABC Broadband.
  2. Clicks Get Started and Raise Complaint Menu.
  3. Automated Help Desk presents the customer with Issue Categories through Quick Reply option.
  4. Customer selects the Issue Category.
  5. Help Desk gathers the required details such as Account Name and Account ID.
  6. Help Desk creates a Ticket on Zendesk and informs the customer

 There are a set of preliminary steps that you need to complete before you begin this tutorial. Check them by clicking the below button:

Flow Set Up

Create the following variables under Session Data by clicking the Settings icon on the top right corner.
A session data variable allows temporary storage of data during each execution of a flow. We will need these variables to be available through out the customer journey.

Step 2 - Set the Session Key

A Session Key uniquely identifies each run of a flow.

Set the Session Key to facebook.psid under Settings available on the top right corner. This is a one-time configuration for this flow. This is required to resume the flow after receiving message on the Receive Node by maintaining the Session Key.

Step 3 - Welcome Message

Add a send node and choose Facebook Channel. A sample configuration is shown below: 

To present the issue categories, we have used Quick Replies. Configure the Type, Title and Payload as shown above. It is only a sample.

Note: A maximum of only 11 quick reply buttons can be configured.

Note: $( will be dyanamically replaced with the name of the customer during flow execution.

Step 4 - Receive the Issue Category

Add a Receive Node to receive the Issue category. A sample configuration is shown below:

Note: When the customer chooses a quick reply, the response is received as Incoming Message. Hence this option is chosen in the Receive Node for Event Name

Store the customer response under the Session Data tab of the Receive Node On-Leave event to be used later in the variable issue

Note: The message that the Receive Node receives is stored under the variable sysResponseMessage

Step 5 - Get further details

Add a Send Node to get further details from the customer. A sample is shown below:

A Delay Node after this node is optional

Step 6 - Get Account ID

Add a Send Node to get Account ID from the customer. A sample is shown below:

Step 7 - Receive Account ID

Add a Receive Node to receive Account ID. Store the customer response in account_id variable to be used later. 

Step 8 - Get Account Name 

Add a Send Node to get Account Name from the customer. A sample is shown below:

Step 9 - Receive Account Name

Add a Receive Node to receive Account Name. Store the customer response in account_name variable to be used later.

Step 10 - Create a Ticket on Zendesk - Custom Node Configuration

Add the Custom Integration Node called TicketStatus (created as part of Preliminary Set Up).

  1. Set the Method Name to "Create Ticket. 
  2. Content-Type is auto-populated as the value was already provided in the Custom Node configuration while creating the Integration under Header Section. 
  3. Provide the Ticket Comment details as follows: 
  4. "Details of Issue: Account Name - $(account_name), Account ID - $(account_id), Issue -  $(issue)". All of the variables are configured in the Receive Node - On Leave event and hold the customer responses. They will be replaced dynamically during flow execution.
  5. Under the Response Tab, assign the ticket_id generated by the API to a variable called id_ticket_cust to communicate the information to customer.

Step 11 - Send Confirmation to Customer

Add a Send Node to send the confirmation to the customer and end the flow. A Sample is shown below:

Step 12 - Handle Errors/Timeouts/Invalid Choices

It is a good practice to handle all the Errors/Timeouts/Invalid Choices. You can end the flow on all of the above. Here is an example on how to handle it. Add a Send Node to inform the customer that something went wrong and connect all the Error/Timeouts/Invalid Choices edges to this node. End the flow on this Send Node. End the flow on Error edge of this flow. A sample is shown below:

Overall Flow

Rule to activate the flow

Publish the flow before creating a Rule

  1. Create a Rule to invoke the flow.
  2. Set the Event to Postback
  3. Set the Condition to facebook-postback.payload EQUALS complaint. complaint is the payload set for the Persistent Menu corresponding to Raise Complaint. The preview of the Rule (image below) shows the payload all in Captials, however, payload is case sensitive. Ensure to give the right value. 
  4. Invoke the flow when the above Event and Conditions are met. 

Note: While setting the Rule to Active State, ensure that the Start Time is in UK timezone as the servers are in UK timezone.

For more details on how to set up a Rule, refer here. A sample is shown below:

Sample Journey

A sample Journey is shown below:

Did this answer your question?