General
- Closed tickets cannot be updated. By default there is an automation which closes solved ticket after 4 days. After ticket is closed survey answers cannot be updated to ticket anymore.
- Survey languages (one vs. multiple triggers). With one trigger Zendesk language needs to match with survey language parameter in the link.
Mapping to Satisfaction object
- Satisfaction score field accepted values are "good" or "bad". Your question element in the survey must have these values when you map it to Satisfaction score field.
- Adding only Satisfaction comment to Zendesk is not possible. Comment is not updated to Zendesk without a score but a score can be updated without a comment.
- You can update Satisfaction to ticket only if ticket status is Solved.
Accepted format/values
- Date field: dd-/.MM-/.yyyy, yyyy-/.MM-/.dd and with HH:mm, e.g. 23.05.2016 or 2016/05/23 12:00
- Checkbox field: Yes/No, Y/N, True/False, T/F, On/Off, 1/0
- Dropdown or multi-select field: option names need to match fully between survey and Zendesk field (capital letters etc.)
How to use same values in multiple dropdown or multi-select fields
If you have same option values in two or more Zendesk dropdown or multi-select fields and you use these fields with integration then you must change field tag values so that every option have unique tag.
You can find field tag value when you
- login to Zendesk
- go to Admin (gear icon)
- select "Ticket fields" under title Manage
- click your field name
- click "Show tags" next to "Field values" title
Here is one example where we have three options Professionalism, Problem solving and Tiger prowess. Each of these have a own tag professionalism, problem_solving and tiger_prowess:
If you have option "Professionalism" in two dropdown or multi-select fields then you must edit that field tags so that first one have "professionalism" and another one have for example "professionalism2". Otherwise integration can't update fields because it doesn't know which field it should use.
How to add custom field to integration link
Open Admin (gear icon) in Zendesk
Click "Ticket Fields" under MANAGE
Click your ticket field name
Under your ticket field name you can see "Custom field ID" and number after it is your field ID
Copy the number and add it to placeholder {{ticket.ticket_field_ADDNUMBERHERE}}
For example: {{ticket.ticket_field_45527909}}
Copy whole placeholder and open your dynamic content (Manage > Dynamic Content) item where you have the integration link
Edit link and add there new key-value pair, for example
&meta=[{'key':'ZendeskTicketId','value':'{{ticket.id}}'},{'key':'RequesterEmail','value':'{{ticket.requester.email}}'},{'key':'ZendeskAgent','value':'{{ticket.assignee.name}}'},{'key':'ZendeskFirstName','value':'{{ticket.requester.first_name}}'},{'key':'ExampleField','value':'{{ticket.ticket_field_45527909}}'}]&source=external&name=Zendesk%20Ticket%20%23{{ticket.id}}
Save your changes and test integration. You should see new meta field and value in Surveypal (Manage > Meta fields) after you first time clicked invitation link from the email which Zendesk sent to you when ticket is solved.
You can also use custom User and Organization fields. You will find instructions from Zendesk placeholder reference.
How to create a Zendesk ticket after survey response via email
You might want to create a ticket after you get new response to your survey. You can do this with Surveypal automations.
Go to your survey and open Manage -view and click on "Automations", and make an automation as in the picture below. Insert your Zendesk support email address to the "To:" -field. You can add background information to message subject or body by adding background information field name inside double curly brackets {{fieldname}}. You'll find background information field name from Manage view when you click "Meta fields".
It's possible that ticket goes to suspended tickets list. If it happens then click ticket in your suspended tickets list, click "Resolve automatically" and then open user "Surveypal" (user name comes from your automation "From" field), click menu next to primary email address (noreply@surveypal.com) and select "Verify now". Go to Zendesk admin view and select "Customers" under "Settings" title. Add noreply@surveypal.com to field "Allowlist" and click "Save tab".
How to create a Zendesk ticket after survey response via API
You might want to create a ticket after you get new response to your survey. You can do this with Surveypal automations and Zendesk API.
Go to your survey, open Manage view, click "Automations", and make an automation as in the picture below.
Url: [your Zendesk domain]/api/v2/tickets.json
Method: HTTP POST
Content-Type: application/json
Headers: Authorization: Basic [Zendesk_email_address/token:api_token] base64 encoded string. More information.
example: Authorization: Basic firstname.lastname@email.com/token:apitokenhere12345 encode the "firstname.lastname@email.com/token:apitokenhere12345" into base64, result should be like this:
Authorization:Basic Zmlyc3RuYW1lLmxhc3RuYW1lQGVtYWlsLmNvbS90b2tlbjphcGl0b2tlbmhlcmUxMjM0NQ
Body content:
{"ticket": {"subject": "New survey response {{userextid}}", "comment": { "body": "This is ticket comment.\nNext line" }, "custom_fields": [{"id": 360003054139, "value": "{{p0e0}}"}, {"id": 360003058300, "value": "{{p1e0}}"}]}}
You'll find list of Zendesk ticket fields from here.
You can add response background information to API request by adding background information field name inside double curly brackets {{fieldname}}. You'll find background information field name from Manage view when you click "Meta fields".
You can add survey question values with element identifiers, for example {{p0e0}}. You'll find more information how to get element identifier from here.
How to create Zendesk unsubscribe survey
You can allow customer to unsubscribe your Zendesk feedback survey emails.
Create a new user field in Zendesk:
- Go to Admin (gear icon) and select "User fields" under Manage title
- Select Text field and give name "Unsubscribe" and click "Create field"
Create a new survey which have two pages.
Add single choice question to first page:
- Question "Do you want to unsubscribe?"
- Options are "yes" and "no".
Add text element to second page which contains thank you message:
Go to Design view, select custom CSS (icon </>) and add below CSS to text field:
button.prev, button.submit, .progress { display:none; }
Go to Build view and click Launch.
Add mapping to survey:
- Go to Distribute view, select Integrations and click Configure next to Zendesk logo
- Change "response has been completed" option to "response has been updated"
- Add mapping which will write question "Do you want to unsubscribe?" value to Zendesk User object field "Unsubscribe":
- Copy integration link from end of mapping view and save mappings.
Go to Zendesk and paste copied link to end of your trigger/automation email body field and put it inside <a> tag, for example:
<a href="https://my.surveypal.com/app/form/ext?sid=1562343237&sh=fPbO3jY2irD1Fpkj9Y-e5lqVG3g2DM0kikp6VNiHOT4Ig1LzBl0Avim-uKXz1HKC&externalId={{ticket.id}}&meta=[{'key':'ZendeskTicketId','value':'{{ticket.id}}'},{'key':'RequesterEmail','value':'{{ticket.requester.email}}'},{'key':'ZendeskAgent','value':'{{ticket.assignee.name}}'},{'key':'ZendeskFirstName','value':'{{ticket.requester.first_name}}'}]&source=external&name=Zendesk%20Ticket%20%23{{ticket.id}}">Unsubscribe</a>
Add data parameter to your link which will push answer to your survey question:
<a href="https://my.surveypal.com/app/form/ext?sid=1562343237&sh=fPbO3jY2irD1Fpkj9Y-e5lqVG3g2DM0kikp6VNiHOT4Ig1LzBl0Avim-uKXz1HKC&externalId={{ticket.id}}&meta=[{'key':'ZendeskTicketId','value':'{{ticket.id}}'},{'key':'RequesterEmail','value':'{{ticket.requester.email}}'},{'key':'ZendeskAgent','value':'{{ticket.assignee.name}}'},{'key':'ZendeskFirstName','value':'{{ticket.requester.first_name}}'}]&source=external&name=Zendesk%20Ticket%20%23{{ticket.id}}&data={p0e0:0}">Unsubscribe</a>
Add p parameter to your link which will change page right after survey opens:
<a href="https://my.surveypal.com/app/form/ext?sid=1562343237&sh=fPbO3jY2irD1Fpkj9Y-e5lqVG3g2DM0kikp6VNiHOT4Ig1LzBl0Avim-uKXz1HKC&externalId={{ticket.id}}&meta=[{'key':'ZendeskTicketId','value':'{{ticket.id}}'},{'key':'RequesterEmail','value':'{{ticket.requester.email}}'},{'key':'ZendeskAgent','value':'{{ticket.assignee.name}}'},{'key':'ZendeskFirstName','value':'{{ticket.requester.first_name}}'}]&source=external&name=Zendesk%20Ticket%20%23{{ticket.id}}&data={p0e0:0}&p=1">Unsubscribe</a>
This link will push answer to survey question "Do you want to unsubscribe?" and recipient see only your survey second page.
Add condition to your feedback survey trigger/automation which will check every time that requester "Unsubscribe" field doesn't contain value "yes":
Save your trigger/automation and test it.