When an end user submits a ticket by email, in most cases the email becomes a new ticket or adds a comment to an existing ticket. In certain cases though, the email becomes a suspended ticket. It remains suspended until somebody reviews the email and decides whether to accept or reject it. If nobody reviews it, the email is deleted after 14 days. You can use this API to list, recover, or delete suspended tickets. For more information, see Understanding and managing suspended tickets and spam and Guidelines for reviewing suspended tickets in Zendesk help.
JSON Format
Suspended Tickets are represented as JSON objects with the following properties:
Name
Type
Read-only
Mandatory
Description
attachments
array
true
false
The attachments, if any associated to this suspended ticket. See Attachments
author
object
true
false
The author id (if available), name and email
brand_id
integer
true
false
The id of the brand this ticket is associated with. Only applicable for Enterprise accounts
cause
string
true
false
Why the ticket was suspended
cause_id
integer
true
false
The ID of the cause
content
string
true
false
The content that was flagged
created_at
string
true
false
The ticket ID this suspended email is associated with, if available
error_messages
array
true
false
The error messages if any associated to this suspended ticket
id
integer
true
false
Automatically assigned
message_id
string
true
false
The ID of the email, if available
recipient
string
true
false
The original recipient e-mail address of the ticket
subject
string
true
false
The value of the subject field for this ticket
ticket_id
integer
true
false
The ticket ID this suspended email is associated with, if available
{"attachments":[],"author":{"email":"[email protected]","id":1111,"name":"Mr. Roboto"},"brand_id":123,"cause":"Detected as spam","cause_id":0,"content":"Out Of Office Reply","created_at":"2009-07-20T22:55:29Z","error_messages":null,"id":435,"message_id":"[email protected]","recipient":"[email protected]","subject":"Help, my printer is on fire!","ticket_id":67321,"updated_at":"2011-05-05T10:38:52Z","url":"https://example.zendesk.com/api/v2/tickets/35436.json","via":{"channel":"email","source":{"from":{"address":"[email protected]","name":"TotallyLegit"},"rel":null,"to":{"address":"[email protected]","name":"Example Account"}}}}
List Suspended Tickets
GET /api/v2/suspended_tickets
Allowed For:
Unrestricted agents
Sorting
You can sort the tickets with the sort_by and sort_order query string parameters.
Parameters
Name
Type
In
Required
Description
sort_by
string
Query
false
The field to sort the ticket by, being one of author_email, cause, created_at, or subject.
sort_order
string
Query
false
The order in which to sort the suspended tickets. This can take value asc or desc.
PUT /api/v2/suspended_tickets/{suspended_ticket_id}/recover
Note: During recovery, the API sets the requester to the authenticated agent who called the API, not the original requester. This prevents the ticket from being re-suspended after recovery. To preserve the original requester, use the Recover Multiple Suspended Tickets endpoint with the single ticket.