A command-line interface for managing Zendesk instances, written in Go. It covers 47+ commands across tickets, users, organizations, and groups with full CRUD operations. Supports multi-instance configuration so you can switch between production, staging, and dev Zendesk accounts without juggling credentials. Output comes in table, JSON, or CSV formats, and a built-in cache with a 10-minute TTL cuts redundant API calls.

Zendesk’s web UI is fine for one-off tasks, but it falls apart when you need to do anything repeatable or at scale. zd-cli lets you script bulk ticket closures, export user lists to CSV, pipe search results through jq, and chain operations together in shell scripts. It supports both API token auth for personal use and full OAuth 2.0 for team deployments. Shell completion works across bash, zsh, fish, and PowerShell.

# Switch instances, search, and act on results
zd instance switch production
zd ticket search "status:open priority:urgent" -o json | jq -r '.[].id' > urgent.txt
while read id; do zd ticket assign $id 987654321; done < urgent.txt

# Export org users to CSV
zd org users 11111111 --per-page 1000 -o csv > acme_users.csv

This project came out of real frustration with Zendesk migrations. Moving between Zendesk instances is one of those problems that sounds simple until you’re in the middle of it. Acquisitions, replatforms, account consolidations. Every one of them means reconciling thousands of users, organizations, group memberships, and ticket histories across two or more systems that have no native concept of each other. The web admin panel is useless for this. There’s no way to diff two instances, no bulk export that actually captures the relationships between entities, and no way to script the recreation of matching structures on the target side. You end up clicking through pages of users one at a time or trying to wrangle Zendesk’s limited CSV import format. zd-cli’s multi-instance support was built specifically for this problem. You can point it at a source and destination, dump both sides to JSON or CSV, diff them with standard Unix tools, and then script the creation or update of whatever is missing. The structured output means you can build real migration pipelines instead of error-prone manual processes.

The same capabilities that make migrations tractable also make complex day-to-day operations manageable. Reassigning hundreds of tickets during a team reorg. Auditing group memberships across organizations after a restructure. Cleaning up suspended or inactive users that have accumulated over years. Exporting ticket data for compliance reviews. These are all tasks that take hours of tedious clicking in the web UI but reduce to shell one-liners or short scripts with zd-cli. The project is open-sourced because every organization running Zendesk at scale hits these same walls. The third-party tools that exist for this space are expensive, often SaaS-only, and still don’t give you the composability of a proper CLI. zd-cli is free, runs locally, and fits into whatever workflow you already have.