Ticket Metrics

JSON Format

Name Type Comment
id integer Automatically assigned
ticket_id integer Id of the associated ticket
url string The API url of the ticket metric
group_stations integer Number of groups the ticket passed through
assignee_stations integer Number of assignees the ticket had
reopens integer Total number of times the ticket was reopened
replies integer Total number of times the ticket was replied to
assignee_updated_at date When the assignee last updated the ticket
requester_updated_at date When the requester last updated the ticket
status_updated_at date When the status was last updated
initially_assigned_at date When the ticket was initially assigned
assigned_at date When the ticket was last assigned
solved_at date When the ticket was solved
latest_comment_added_at date When the latest comment was added
first_resolution_time_in_minutes object Number of minutes to the first resolution time during calendar and business hours
reply_time_in_minutes object Number of minutes to the first reply during calendar and business hours
full_resolution_time_in_minutes object Number of minutes to the full resolution during calendar and business hours
agent_wait_time_in_minutes object Number of minutes the agent spent waiting during calendar and business hours
requester_wait_time_in_minutes object Number of minutes the requester spent waiting during calendar and business hours
created_at date When the record was created
updated_at date When the record was last updated
Example
{
  "id": 33,
  "ticket_id": 4343,
  "created_at": "2009-07-20T22:55:29Z",
  "updated_at": "2011-05-05T10:38:52Z",
  "group_stations": 7,
  "assignee_stations": 1,
  "reopens": 55,
  "replies": 322,
  "assignee_updated_at": "2011-05-06T10:38:52Z",
  "requester_updated_at": "2011-05-07T10:38:52Z",
  "status_updated_at": "2011-05-04T10:38:52Z",
  "initially_assigned_at": "2011-05-03T10:38:52Z",
  "assigned_at": "2011-05-05T10:38:52Z",
  "solved_at": "2011-05-09T10:38:52Z",
  "latest_comment_added_at": "2011-05-09T10:38:52Z",
  "reply_time_in_minutes": { "calendar": 2391, "business": 737 },
  "first_resolution_time_in_minutes": { "calendar": 2391, "business": 737 },
  "full_resolution_time_in_minutes": { "calendar": 2391, "business": 737 },
  "agent_wait_time_in_minutes": { "calendar": 2391, "business": 737 },
  "requester_wait_time_in_minutes": { "calendar": 2391, "business": 737 },
  "on_hold_time_in_minutes": { "calendar": 2290, "business": 637 }
}

List Ticket Metrics

GET /api/v2/ticket_metrics.json

Returns a list of tickets with their metrics.

Tickets are ordered chronologically by created date, from newest to oldest. The last ticket listed may not be the absolute oldest ticket in your account due to ticket archiving.

Archived tickets are not included in the response. See About archived tickets in the Support Help Center.

Allowed For
  • Agents
Using curl
curl https://{subdomain}.zendesk.com/api/v2/ticket_metrics.json \
  -v -u {email_address}:{password}
Example Response
Status: 200 OK

{
  "ticket_metrics": [
    {
      "id": 33,
      "ticket_id": 4343,
      "reopens": 55,
      "replies": 322,
      ...
    }
    {
      "id": 34,
      "ticket_id": 443,
      "reopens": 123,
      "replies": 232,
      ...
    },
  ]
}

Show Ticket Metrics

GET /api/v2/ticket_metrics/{ticket_metric_id}.json

GET /api/v2/tickets/{ticket_id}/metrics.json

Returns a specific metric, or the metrics of a specific ticket.

Allowed For
  • Agents
Using curl:
curl https://{subdomain}.zendesk.com/api/v2/ticket_metrics/{id}.json \
  -v -u {email_address}:{password}
Example Response
Status: 200 OK

{
  "ticket_metric": {
    "id": 34,
    "ticket_id": 443,
    "reopens": 123,
    "replies": 232,
    ...
  }
}