codesession
oleh brian-mwirigi
Web & Frontend DevelopmentRingkasan
Track agent session costs, file changes, and git commits with codesession-cli.
Deskripsi
Apa yang Dilakukan Skill Ini
codesession-cli tracks AI agent session costs, token usage, file changes, and git commits from a single CLI. Session data is stored locally with a web dashboard for cost breakdowns, budget alerts, and per-model analytics. Compatible with Claude Code, Codex, Cursor, Windsurf, Cline, and any agent using OpenAI or Anthropic-compatible APIs.
It works across Claude Code, Codex, Cursor, Windsurf, and Cline without requiring separate dashboards or vendor-specific integrations for each tool.
Kapan Menggunakannya
- Checking how much a Claude Code session cost before closing it
- Setting a daily spend alert to avoid unexpected API bills
- Attributing token costs to specific agents in a multi-agent pipeline
- Comparing costs across Claude, GPT-4o, and Gemini for the same task type
- Exporting session history to CSV for client billing or project tracking
Contoh Alur Kerja
User asks: Track costs for a bug-fix session using Claude
- 1
Runs
cs start "Fix authentication bug" --json --close-staleto open a tracked session - 2
After each API call, runs
cs log-ai -p anthropic -m claude-sonnet-4 --prompt-tokens 8000 --completion-tokens 2000 --jsonto record usage - 3
Runs
cs status --jsonto check current spend before expensive operations - 4
Runs
cs end -n "Fixed auth bug, added tests" --jsonto close the session and capture git changes
Session summary with total AI cost, token counts, files changed, commits made, and access to the web dashboard for full analytics
Instalasi
clawhub install brian-mwirigi/codesessionJalankan perintah CLI-nya, atau tempel prompt ke Claude Code, Cursor, Codex, atau coding agent apa pun yang Anda pakai.