Send information back to Zendesk

You can pull data from Zendesk, work on it, and send it back to the ticket.

  1. To complete the task, you need your Zendesk API Key. For details on how to generate it, see Zendesk documentation.
  2. In your Next Matter workflow create a new integration step.
  3. To update a ticket, use the following:
  • Method: PUT
  • Headers: Content-Type: application/json
  • Headers: Authorization: ZENDESK_API_KEY
  • URL: https://ZENDESK_DOMAIN.zendesk.com/api/v2/tickets/{{instance_name}}
  • Body might look like the following:
{  
"ticket": {  
   "custom_fields": [  
       { "id": %%ENTER_ZENDESK_FIELD_ID%%, "value": %%ENTER_VALUE%% }  
    ]  //You can find the field ID in Zendesk Admin Center > Objects and rules > Fields
  }  
}

Update a Zendesk ticket with a comment

  1. To update a specific ticket with a comment, use the following integration:
  • Method: PUT
  • Headers: Content-Type: application/json
  • Headers: Authorization: ZENDESK_API_KEY
  • URL: https://ZENDESK_DOMAIN.zendesk.com/api/v2/tickets/TICKET_ID
  • Body might look like the following:
{
	"ticket": {		
		"comment": {
			"html_body": "PUBLIC_COMMENT", //replace this placeholder. 
			"public": true
		}
	}
}
  1. Create a variable for the ticket ID with the value of $.ticket.id.
  2. Save your changes.

📘

You can get your Zendesk ticket ID from the Ticket ID button that's on the top of each ticket in Zendesk. Copy the number without #.