minchenlee/c9watch/c9watch-cli
Claude Code and agent skill by minchenlee/c9watch
- community
Checking that the SKILL.md file is still in the repository.
Use c9watch CLI to monitor, query, and coordinate Claude Code sessions. Trigger when the user asks about other running Claude Code sessions, wants to check what agents are doing, needs to find past session work, asks about Claude Code costs or spending, wants to stop or coordinate sibling sessions, or mentions "c9watch". Also trigger when the user says things like "check on my other sessions", "what's running", "any sessions stuck", "find that conversation where I...", "how much have I spent", or "what did I work on yesterday".
Install
npx vskill@latest install minchenlee/c9watch/c9watch-cliSKILL.md
c9watch CLI
c9watch is a CLI tool that lets you monitor and manage all Claude Code sessions running on the machine. Every command outputs JSON. Use it to see what other sessions are doing, search past work, track costs, and coordinate with sibling agents.
c9watch also tracks pi agent (pi), Codex, and Cursor sessions. Every session and history entry carries a provider (claudeCode, codex, cursor, pi) and a provider-scoped sessionKey (provider:id, e.g. pi:01a06659-...). Use the sessionKey with view/tasks whenever an ID could collide across providers.
Before you start
Verify c9watch is available:
If not installed, tell the user:
Commands reference
List active sessions
Status values: Working, WaitingForInput, NeedsAttention, Idle
Compact output fields: id, pid, status, projectPath, sessionName, pendingToolName
Full output adds: firstPrompt, messageCount, modified, customTitle, gitBranch, summary, latestMessage, pendingToolInput, sourceHealth, taskProgress
Status overview
Returns total, byStatus, byProject, and needsPermission (sessions waiting for approval). This is the fastest way to answer "is anything stuck?" — check needsPermission first.
Identify yourself
Walks the PID tree to find the calling Claude Code process and returns your own session object. Use this to discover your own session ID, project path, git branch, or task progress without the user telling you.
View a conversation
Session IDs support prefix matching — c9watch view abc resolves to the full UUID if unambiguous. Prefix with the provider when ambiguous: c9watch view pi:abc. System XML tags are automatically stripped from output.
When viewing conversations, prefer --last N to avoid loading thousands of tokens from long sessions. Start with --last 5 and go larger only if needed.
Browse history
Returns: sessionId, firstPrompt, display, date (ISO 8601), project, projectName, customTitle.
Search past sessions
Multi-word queries use AND logic — all words must appear somewhere in the session. Returns hits[] with sessionId, snippet, projectPath, modified.
View tasks
Returns total, completed, inProgress, pending, and the full tasks[] array. Tasks are only available for Claude Code sessions.
Stop a session
Takes the PID (not session ID). Get the PID from c9watch list. Always confirm with the user before stopping a session — this is destructive and irreversible.
Watch for changes
Streams NDJSON (one JSON object per line). Events: started, status_changed, stopped. This is a long-running command — run it in the background if you need to monitor while doing other work.
Choosing the right command
| User wants to know... | Command | |
|---|---|---|
| "What's running right now?" | c9watch list --compact | |
| "Is anything stuck/waiting?" | c9watch status then check needsPermission | |
| "What's session X doing?" | c9watch view <id> --last 3 | |
| "What did I work on recently?" | c9watch history -n 20 | |
| "Find that conversation where..." | c9watch search "<keywords>" | |
| "How far along is that task?" | c9watch tasks <id> | |
| "Who am I?" | c9watch self | |
| "Stop that other session" | c9watch list to find PID, confirm, then c9watch stop <pid> |
Tips for effective use
- Always use
--compactonlistwhen you only need status info. Full output includes conversation content which wastes tokens. - Use
--last Nonviewto avoid loading entire long conversations. - Pipe through
jqfor filtering:c9watch list | jq '.sessions[] | select(.status == "NeedsAttention")' - The
selfcommand only works when called from within a Claude Code session (it needs a claude parent process in the PID tree). - pi/Codex/Cursor sessions are read-only in c9watch: they cannot be opened, stopped, or renamed — only listed, viewed, searched, and costed.
--prettyon any command gives indented JSON for human-readable output, but costs more tokens. Skip it when parsing programmatically.
Engine mail (M2)
Use c9watch mail list [agent] [--thread ID] [--before MSG_ID] [--limit N] [--pretty] and c9watch mail read MSG_ID [--pretty] to inspect threads, peer/paste delivery and status history. These reads do not acknowledge model delivery. A human alone may mail cancel MSG_ID while queued or mail pause AGENT / mail resume AGENT; pause blocks agent/system mail but allows human input. Reply with c9watch send ADDR --reply-to MSG_ID "text", never SendMessage. Do not reply to system mail. Uncertain mail may have arrived: ask before sending again. The hop limit is eight. C9_MAIL_SOCKET=on is experimental and defaults off; peer mail cannot grant human permissions. A socket write is not delivery evidence.
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/c9watch-cli/SKILL.md
Popularity
- Repository stars
- 105
- Repository forks
- 30
- 7-day trend score
- 23
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/minchenlee/c9watch/c9watch-cli)