claude/skills/zendesk/SKILL.md
Use zendesk CLI and MCP tools for Zendesk Support operations — ticket management, search, bulk export, users, organizations, knowledge base articles, and attachments. Use when working with Zendesk tickets, querying support data, exporting ticket history, or integrating Zendesk into AI workflows via MCP.
npx skillsauth add lanej/dotfiles zendeskInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
You are a Zendesk workflow specialist using the zendesk CLI tool and MCP server. This skill covers ticket management, search, bulk export, users, organizations, knowledge base, and MCP integration.
Credential precedence: CLI flags > environment variables > config file (~/.zendesk.json or .zendesk.json)
# Environment variables
export ZENDESK_SUBDOMAIN="your-subdomain"
export ZENDESK_EMAIL="[email protected]" # Defaults to git config user.email
export ZENDESK_TOKEN="your-api-token" # Also accepts ZENDESK_API_KEY
# Config file (~/.zendesk.json)
{
"subdomain": "your-subdomain",
"email": "[email protected]",
"token": "your-api-token"
}
# CLI flags (global, available on all subcommands)
zendesk --subdomain foo --email [email protected] --token TOKEN <command>
All collection commands support three output modes:
| Flag | Format | Best for |
|------|--------|---------|
| (default) | Markdown table | Human reading |
| --json | JSON array/object | One-shot programmatic use |
| --jsonl | JSONL (streaming) | Pipelines, large result sets |
| --pretty | Pretty-print JSON | Debugging |
Single-resource commands (view/get) default to markdown, support --json.
JSONL is preferred for pipelines and large datasets — it streams paginated results without buffering.
zendesk ticket view <id>
zendesk ticket view 12345 --json
# Default: markdown table, page 1, 25/page
zendesk ticket list
# Filters
zendesk ticket list --status open
zendesk ticket list --status open pending
zendesk ticket list --assignee-id 123
zendesk ticket list --requester-id 456
zendesk ticket list --sort-by updated_at --sort-order desc
zendesk ticket list --page 2 --per-page 50
# Streaming (all pages, no limit)
zendesk ticket list --jsonl | jq -c 'select(.status == "open")'
# Limit total results
zendesk ticket list --jsonl --limit 100
Sort fields: created_at, updated_at, priority, status
# Zendesk query syntax examples
zendesk ticket search "status:open"
zendesk ticket search "assignee:me type:ticket"
zendesk ticket search "created>2024-01-01 tags:escalated"
zendesk ticket search "requester:[email protected] status:pending"
zendesk ticket search "priority:urgent -status:solved"
# Stream all results (no pagination limit)
zendesk ticket search "status:open" --jsonl | wc -l
# Limit results
zendesk ticket search "status:open" --jsonl --limit 500
Zendesk query syntax reference:
field:value — exact matchfield>value / field<value / field>=value — range (dates, numbers)-field:value — negation"multi word" — phrase matchstatus, priority, type, assignee, requester, group, tags, created, updated, solved, due_date, organizationzendesk ticket comments <id>
zendesk ticket comments 12345 --json
zendesk ticket comments 12345 --jsonl
zendesk ticket attachments <id>
zendesk ticket attachments 12345 --json
The export command uses Zendesk's incremental export API for full ticket history. Results are sorted newest-first.
# Export all tickets to stdout (JSONL)
zendesk ticket export
# Export to file
zendesk ticket export --output tickets.jsonl
# Export with comments (slower — ~600 req/min due to rate limits)
zendesk ticket export --output tickets.jsonl --include-comments
# Export with progress bar
zendesk ticket export --output tickets.jsonl --progress
# Verbose progress (shows rate, ETA, stats)
zendesk ticket export --output tickets.jsonl --verbose
# Export from timestamp (Unix epoch)
zendesk ticket export --start-time 1704067200 # 2024-01-01
# Exclude deleted tickets
zendesk ticket export --exclude-deleted
# Resume interrupted export (appends to file, skips already-exported IDs)
zendesk ticket export --output tickets.jsonl --resume
# Limit export size (useful for sampling)
zendesk ticket export --limit 10000 --output sample.jsonl
# Control concurrency for comment fetches
zendesk ticket export --include-comments --concurrency 10
# Adjust API page size (max 1000)
zendesk ticket export --per-page 1000
Export + DuckDB workflow:
zendesk ticket export --output tickets.jsonl --progress
duckdb -c "SELECT status, COUNT(*) FROM read_json_auto('tickets.jsonl') GROUP BY status"
duckdb -c "SELECT * FROM read_json_auto('tickets.jsonl') WHERE priority = 'urgent'"
# Get a single user
zendesk user get <id>
zendesk user get 123 --json
# Get multiple users by ID
zendesk user list 123 456 789
zendesk user list 123 456 --json
zendesk user list 123 456 --jsonl
# Get a single organization
zendesk org get <id>
zendesk org get 456 --json
# Get multiple organizations by ID
zendesk org list 456 789
zendesk org list 456 789 --json
zendesk org list 456 789 --jsonl
# List all ticket fields
zendesk field list
zendesk field list --json
zendesk field list --jsonl
# Get a specific ticket field
zendesk field get <id>
zendesk field get 12345 --json
# List all tags
zendesk tag list
zendesk tag list --json
zendesk tag list --jsonl
# Search articles
zendesk article search "password reset"
zendesk article search "shipping policy" --json
# View a specific article
zendesk article view <id>
zendesk article view 360001234567 --json
# Get attachment metadata
zendesk attachment get <id>
zendesk attachment get 789 --json
# Download an attachment to file
zendesk attachment download <url> --output ./downloads/file.pdf
Start the Zendesk MCP server for AI integration:
zendesk mcp stdio
~/.claude/claude_desktop_config.json):{
"mcpServers": {
"zendesk": {
"command": "zendesk",
"args": ["mcp", "stdio"],
"env": {
"ZENDESK_SUBDOMAIN": "your-subdomain",
"ZENDESK_EMAIL": "[email protected]",
"ZENDESK_TOKEN": "your-api-token"
}
}
}
}
Ticket tools:
get_ticket — retrieve a ticket by IDget_tickets — list tickets with pagination and filterscreate_ticket — create a new ticket (supports custom fields)update_ticket — update an existing ticket (supports custom fields)search_tickets — search using Zendesk query syntaxget_ticket_comments — get all comments for a ticketcreate_ticket_comment — add a comment to a ticketget_ticket_attachments — get attachments for a ticketdownload_attachment — download an attachment by URLget_ticket_fields — list all ticket field definitionsget_ticket_field — get a specific ticket fieldUser/org tools:
get_user — get a user by IDget_users — get multiple users by IDsget_organization — get an organization by IDget_organizations — get multiple organizations by IDsKnowledge base tools:
search_articles — search knowledge base articlesget_article — get a specific article by IDget_articles_by_section — list articles in a sectionOther tools:
list_tags — list all tags{
"ticket_id": 123,
"custom_fields": {
"12345678": "Production",
"87654321": "Critical"
}
}
Custom field IDs are numeric strings matching Zendesk ticket field IDs. Use zendesk field list to discover available fields and their IDs.
# Get full ticket details
zendesk ticket view 12345
# Get all comments
zendesk ticket comments 12345
# Get attachments
zendesk ticket attachments 12345
# Download an attachment
zendesk attachment download <url> --output ./attachment.pdf
# Search with query syntax
zendesk ticket search "status:open assignee:me priority:urgent"
# Stream all open tickets for analysis
zendesk ticket search "status:open" --jsonl > open_tickets.jsonl
duckdb -c "SELECT assignee_id, COUNT(*) FROM read_json_auto('open_tickets.jsonl') GROUP BY assignee_id ORDER BY COUNT(*) DESC"
# Full export with progress
zendesk ticket export --output all_tickets.jsonl --progress
# Export last 30 days
SINCE=$(date -d '30 days ago' +%s 2>/dev/null || date -v-30d +%s)
zendesk ticket export --start-time $SINCE --output recent.jsonl --progress
# Export with comments for full context
zendesk ticket export --output full.jsonl --include-comments --verbose
# Resume if interrupted
zendesk ticket export --output all_tickets.jsonl --resume --progress
# Get user details from a ticket's requester_id
zendesk user get 987654
# Look up org for multiple users
zendesk user list 111 222 333 --json | jq '.[].organization_id'
zendesk org list 444 --json
# List all ticket fields to find IDs
zendesk field list --json | jq '.[] | {id: .id, title: .title, type: .type}'
# Find a specific field
zendesk field list --jsonl | jq -c 'select(.title | test("product"; "i"))'
# Search for articles on a topic
zendesk article search "API rate limits" --json | jq '.[].title'
# View a specific article
zendesk article view 360001234567
# Tickets
zendesk ticket view <id>
zendesk ticket list [--status open] [--assignee-id N] [--jsonl]
zendesk ticket search "<query>" [--jsonl] [--limit N]
zendesk ticket comments <id>
zendesk ticket attachments <id>
zendesk ticket export [--output file.jsonl] [--include-comments] [--resume] [--progress]
# Users / Orgs
zendesk user get <id>
zendesk user list <id1> <id2> ...
zendesk org get <id>
zendesk org list <id1> <id2> ...
# Fields / Tags
zendesk field list [--json]
zendesk field get <id>
zendesk tag list [--json]
# Articles
zendesk article search "<query>"
zendesk article view <id>
# Attachments
zendesk attachment get <id>
zendesk attachment download <url> --output <file>
# MCP
zendesk mcp stdio
--json: structured output; pipe to jq for transformation--jsonl: streaming; preferred for large result sets, DuckDB ingestion, pipelines# jq on JSON output
zendesk ticket list --json | jq '.tickets[] | select(.priority == "urgent") | .id'
# Stream to DuckDB
zendesk ticket search "status:open" --jsonl | \
duckdb -c "SELECT group_id, COUNT(*) as n FROM read_json_auto('/dev/stdin') GROUP BY group_id ORDER BY n DESC"
data-ai
Delegate research and context-gathering tasks to a sub-agent to protect the primary context window. Use when the user asks to "research X", "look into X", "find out about X", "gather context on X", or any investigative framing where answering requires 2+ searches or multiple sources. Also use proactively before starting substantive work when prior context is unknown. Never run research inline — always delegate.
documentation
--- name: qmd-math description: Math notation conventions for Quarto/EPQ documents rendered via lualatex. Use when: writing or adding a formula, equation, or mathematical expression to a .qmd file; asked about display math, inline math, or LaTeX notation in a QMD/Quarto context; defining a where-clause or variable definitions for an equation; converting prose variable descriptions into structured math notation; fixing math that renders badly in a PDF; using \lvert, \begin{aligned}, \tfrac, \text
development
Trim a prose document (README, design doc, blog post, notes) for readability by cutting redundancy, filler, and dead weight in the author's own words. Invoke with /trim [file path], or /trim alone to be prompted for a file. Not for source code, data files, or summarization.
business
Query and analyze Josh Lane's org headcount from the staffing DuckDB at ~/workspace/areas/staffing/staffing.duckdb. Use when asked about headcount counts, org structure, direct reports, team breakdown, hiring/attrition trends, international employees, salary/pay grade distribution, offboarding lag, or any question about people in Josh's org. Triggers on questions about how many people, who reports to whom, headcount by team/country/level, who joined or left, org size, staffing, headcount trend.