---
name: zendesk-ticket-backlog
description: "Twice each weekday: unsolved Zendesk tickets by priority and age, the ones already past their SLA target, and whether the queue grew. Use when the user asks for this, or when it runs on a schedule."
---

# Zendesk ticket backlog

Twice each weekday: unsolved Zendesk tickets by priority and age, the ones already past their SLA target, and whether the queue grew.

Zendesk views tell you how many tickets are waiting. They are less helpful about which of those already broke an SLA promise: that is a red badge you only find by opening the view and scanning down the list.

Twice a day, at 8:00 and 14:00, the agent counts unsolved tickets through the Search API, splits them by priority and age, and reads the SLA metrics of the urgent and high tickets so every breach is listed by number. The tile is the unsolved count, so a falling line means the team is getting ahead.

## Two ways to get the data

Use the API or MCP route when you have an MCP server, a CLI or an API token for the app. Otherwise, if you can drive a browser the user is signed in to (Claude in Chrome, a Playwright or Chrome DevTools MCP server), use the browser route. Say which one you used.

## Route A: API or MCP server

### What you need

- A Zendesk agent or admin login with an API token (`ZENDESK_SUBDOMAIN`, `ZENDESK_EMAIL`, `ZENDESK_API_TOKEN`), or a Zendesk connector with read access to tickets.
- SLA policies set up in Zendesk (Suite Growth or above, or Support Professional or above); without them the breach list stays empty.

If something is missing, say what and stop; do not invent numbers.

### Steps

1. **Count unsolved by priority** (Zendesk): Call `GET /api/v2/search/count?query=type:ticket status<solved` for the total, then add `priority:urgent`, `priority:high`, `priority:normal` and `priority:low` for each band; the difference from the total is tickets with no priority. `status<solved` covers new, open, pending and on-hold.
2. **Split out tickets waiting on someone else** (Zendesk): Repeat the counts with `status:pending` and `status:hold`, so work the team owes is separate from tickets waiting on the customer or a third party.
3. **Age the queue** (Zendesk): Count `type:ticket status<solved created<YYYY-MM-DD` with the dates 3 and 7 days ago, per priority. For the oldest tickets themselves, use `GET /api/v2/search?query=...&sort_by=created_at&sort_order=asc`.
4. **Find SLA breaches** (Zendesk): Load each unsolved urgent and high ticket with `GET /api/v2/tickets/{ticket_id}?include=slas`. A breach is an entry in `slas.policy_metrics` (such as `first_reply_time` or `next_reply_time`) whose `breach_at` has passed and that has not been achieved yet.
5. **Compare and post**: Compare the unsolved total with the previous run, then post it with the priority and age table and the breached tickets: number, subject, metric and how long ago it breached.

## Route B: the browser

### What you need

- Signed in to Zendesk as an agent with Explore Viewer access or above; adding the SLA column to a shared view needs an admin.

If something is missing, say what and stop; do not invent numbers.

### Steps

Start at https://www.zendesk.com/login/. The user is signed in already; never type passwords or codes, and ask if a sign-in page appears.

1. **Open the Support dashboard in Explore**: Enter your subdomain on the sign-in page (you land on `https://<subdomain>.zendesk.com/agent/`), then open **Explore** from the product tray and go to **Dashboards** > **Zendesk Support**. The **Unsolved Tickets** tab gives unsolved tickets by priority and by status; filter by group or brand if the team's view does.
2. **Read the backlog by age**: On the same tab, read the unsolved counts by age bracket for older than 3 and 7 days. For exact numbers, switch to Support, open **Views** > **All unsolved tickets**, sort by **Requested** oldest first and count down to the 3-day and 7-day marks.
3. **Find the SLA breaches**: In **All unsolved tickets**, add the **SLA** column (admins do this under the view's **Formatting options**) and sort by it ascending: breached tickets show a red badge with the time since the breach. Read the urgent and high ones with their ticket number, subject and the metric named in the badge.
4. **Compare and post**: Set the unsolved total against the number from the previous run, then post it with the priority and age table and the breached tickets, most urgent first.

Note: Explore dashboards refresh about once an hour, so the view counts in Support can run a little ahead of the dashboard. Views list 30 tickets per page and show the total at the top. The SLA column exists only when SLA policies are set up (Suite Growth or above, or Support Professional or above).

## The report

- **Unsolved tickets** now, and the change since the last run.
- **By priority**, with how many are pending or on-hold.
- **Age**: unsolved tickets older than 3 and 7 days.
- **Past SLA**: breached tickets with the metric and how long ago, most urgent first.

## Post it to Briefkin

When `BRIEFKIN_TOKEN` is set, or `~/.config/briefkin/env` exists (the installer from https://briefkin.dev/docs writes it), also send the result to the user's Briefkin board as one card. Keep the `item_key` the same on every run so the card updates in place, use a new `event_id` per run, and put today's real numbers in place of the example ones. If the request fails, say so once and carry on.

```bash
[ -n "${BRIEFKIN_TOKEN:-}" ] || . ~/.config/briefkin/env
curl -sS -X POST "${BRIEFKIN_URL:-https://briefkin.dev}/v1/events" \
  -H "authorization: Bearer $BRIEFKIN_TOKEN" \
  -H "content-type: application/json" \
  -d @- <<'JSON'
{
  "v": 1,
  "event_id": "zendesk-ticket-backlog/<date of this run, e.g. 2026-10-16>",
  "item_key": "zendesk-ticket-backlog",
  "project": "Acme",
  "source": "Zendesk ticket backlog skill",
  "kind": "metric",
  "title": "63 unsolved tickets, 4 past SLA",
  "metric": {
    "label": "Unsolved tickets",
    "value": 63,
    "better": "lower",
    "period_start": "<start of the period, ISO 8601>",
    "period_end": "<end of the period, ISO 8601>"
  },
  "glance": {
    "type": "Grid",
    "props": {
      "columns": 3
    },
    "children": [
      {
        "type": "Stat",
        "props": {
          "label": "Urgent or high",
          "value": 11
        }
      },
      {
        "type": "Stat",
        "props": {
          "label": "Older than 7 days",
          "value": 9,
          "tone": "warn"
        }
      },
      {
        "type": "Stat",
        "props": {
          "label": "Past SLA",
          "value": 4,
          "tone": "bad"
        }
      }
    ]
  },
  "widget": [
    {
      "type": "Table",
      "props": {
        "columns": [
          "Priority",
          "Unsolved",
          "Pending or on-hold",
          "Over 3 days",
          "Over 7 days"
        ],
        "align": [
          "left",
          "right",
          "right",
          "right",
          "right"
        ],
        "rows": [
          [
            "Urgent",
            3,
            0,
            1,
            0
          ],
          [
            "High",
            8,
            2,
            3,
            1
          ],
          [
            "Normal",
            39,
            11,
            14,
            6
          ],
          [
            "Low",
            9,
            3,
            4,
            2
          ],
          [
            "No priority",
            4,
            1,
            1,
            0
          ]
        ]
      }
    },
    {
      "type": "Table",
      "props": {
        "columns": [
          "Ticket",
          "Priority",
          "Breached",
          "Since"
        ],
        "align": [
          "left",
          "left",
          "left",
          "right"
        ],
        "rows": [
          [
            "#21874 Checkout fails with card declined",
            "Urgent",
            "First reply",
            "2 h ago"
          ],
          [
            "#21851 Cannot export invoices to CSV",
            "High",
            "Next reply",
            "5 h ago"
          ],
          [
            "#21790 SAML login error after IdP change",
            "High",
            "First reply",
            "1 day ago"
          ],
          [
            "#21702 Data import stuck at 90%",
            "High",
            "Next reply",
            "3 days ago"
          ]
        ]
      }
    },
    {
      "type": "Callout",
      "props": {
        "text": "#21874 is urgent and still has no first reply.",
        "tone": "bad"
      }
    }
  ],
  "size": "md"
}
JSON
```

Widgets come from the Briefkin catalog (https://briefkin.dev/v1/catalog). Without a token, just give the user the report.

Set `period_start` and `period_end` to the window the number covers: the tile names it from them ("Last 7 days", "Today", "This month"). For a count right now (open items, a balance), send `"period_label": ""` so no period shows; for another name, send it as `period_label` (at most 24 characters).

## Run it on a schedule

Suggested: Weekdays at 8:00 and 14:00 (`0 8,14 * * 1-5`). From cron, with the agent signed in on that machine:

```bash
0 8,14 * * 1-5 claude -p "Run the zendesk-ticket-backlog skill"
# Codex: codex exec, Gemini CLI: gemini -p, Copilot CLI: copilot -p, OpenCode: opencode run
```

Or use the agent's own scheduler (Claude Code routines, Codex automations, Claude or ChatGPT scheduled tasks): https://briefkin.dev/skills/zendesk-ticket-backlog#schedule

Source: https://briefkin.dev/skills/zendesk-ticket-backlog
