jq, shell scripts, cron jobs, and AI coding agents like Claude Code, Cursor, and Codex.
Piping with jq
Since all output is valid JSON, usejq to extract, filter, and transform results:
Shell Scripts
Resolve a city name and search permits
Batch lookup contractors by ID
Cron Jobs
Monitor permit activity on a weekly schedule:AI Agent Integration
The CLI is built with an agent-first design. AI coding agents (Claude Code, Cursor, Codex, or custom agents) can:- Read
--helpto understand available commands and flags - Run commands and parse the JSON output
- Branch on exit codes to handle errors programmatically
- Chain commands to build multi-step research workflows
How an AI agent uses the CLI
The CLI help text is written to be clear and specific so that an LLM can construct the correct command on the first attempt. No human-oriented decorations (colors, spinners, progress bars) interfere with parsing.
Why CLI over MCP for agents?
The CLI avoids common MCP pain points:- No context bloat — the agent only reads what it requests
- No credential juggling — one API key in the environment
- No host lock-in — works with any agent that can run shell commands
- No protocol overhead — plain JSON in, plain JSON out
Error Handling in Scripts
Related Articles
- CLI commands overview — Full list of commands and flags
- CLI output and pagination — Understanding JSON responses
- CLI error codes — Exit codes reference
- Automate API calls — Automating with the REST API directly
