Skip to main content

ops query

Query project state for interactive AI assistants. Returns structured JSON snapshots of project status, error logs, pipeline health, or system health. Designed to be piped into an AI context window.

AI Triage Helper

Use ops query status --json to feed the current system state to Claude or Gemini when asking for triage help. The structured output is purpose-built for LLM context windows.

Synopsis

Return a structured snapshot of project state
Terminal
$ops query <QUERY_TYPE>

Arguments

ArgumentAllowed ValuesDescription
QUERY_TYPEstatus, errors, pipelines, healthThe kind of snapshot to return

Flags

FlagTypeDescriptionDefault
--project-pTEXTProject to queryall
--hours-hINTEGERHours to look back for errors24
--jsonflagOutput as JSONtrue

Examples

Full system status snapshot across every project
Terminal
$ops query status
Errors from the last two days, structured for AI consumption
Terminal
$ops query errors --hours 48
Pipeline state scoped to a single project
Terminal
$ops query pipelines --project wdp-import
Health-check rollup for downstream services
Terminal
$ops query health
Copy a system snapshot to the clipboard to paste into an AI chat
Terminal
$ops query status --json | pbcopy

When to Use

🤖

AI Context

Feed ops query status --json into Claude or Gemini and ask "what should I look at first?"

🔍

Targeted Snapshot

Use --project to narrow the snapshot when investigating a single repo.

📋

Clipboard Hand-Off

Pipe to pbcopy (macOS) or clip.exe (WSL) to drop straight into a chat window.

JSON by Default

ops query defaults to JSON output because its primary consumers are scripts and AI assistants. Pair it with ops status for human-readable triage.