Skip to main content

Analytics Dashboard

The Analytics dashboard provides comprehensive visibility into your AI usage patterns, costs, and performance metrics across all configured providers — including Claude, CLIProxy OAuth providers, and CLIProxy multi-provider sources.

Overview

Access analytics through the dashboard:
ccs config
# Navigate to Analytics tab
Analytics Dashboard - Dark

Data Sources

Available since v7.51.0 — unified multi-provider analytics
CCS aggregates usage data from three sources into a single unified view:

Claude Config

Local session data from ~/.claude/ — costs, tokens, session history for Claude account profiles

CCS Instances

Usage from all configured CCS profiles (GLM, API profiles, account profiles)

CLIProxy Multi-Provider

Aggregated usage from all CLIProxy OAuth providers (Gemini, Codex, AGY, GHCP, Kimi, etc.)

CLIProxy Background Sync

CLIProxy usage data syncs automatically every 5 minutes in the background:
  • Snapshot stored at ~/.ccs/cache/cliproxy-usage/latest.json
  • Dashboard reads from snapshot for instant load (no blocking API calls)
  • Manual refresh available via the refresh button or API endpoint

Key Metrics

Five summary cards display high-level metrics:

Total Tokens

Combined input/output tokens across all providers

Total Cost

Aggregate spending across Claude, Gemini, GPT, GLM, Qwen models

Cache Tokens

Tokens served from cache, reducing API costs

Input/Output Cost

Breakdown of costs by request direction

Dashboard Widgets

Area chart showing token/cost trends over time with:
  • Configurable date ranges: 24H, 7D, 30D, Month, All Time
  • Custom date picker for specific periods
  • Auto-refresh with “Updated X ago” indicator
  • Daily and hourly granularity — drill down to per-hour breakdowns

Cost by Model

Horizontal bar chart breaking down costs per model:
  • Claude Opus/Sonnet 4.6 Thinking
  • Gemini 3 Pro / Flash variants
  • GPT 5.2, GLM 4, Qwen3 Coder
  • Color-coded bars for quick comparison

Model Usage

Donut chart showing distribution of requests across models:
  • Percentage breakdown by model
  • Visual representation of dominant providers
  • Monthly aggregates for billing overview

Session Stats

  • Total Sessions: Count of coding sessions
  • Avg Cost/Session: Average spending per session
  • Recent Activity: List of recent sessions with timestamps

CLIProxy Stats

Real-time proxy performance metrics:
  • Success Rate: Percentage with total/failed counts
  • Total Tokens: Aggregate tokens through proxy
  • Models Used: Per-model breakdown with request counts
  • Anomaly Detection: Highlights unusual usage spikes or error rates

Hourly Breakdown

Available since v7.51.0
Granular per-hour usage view:
  • Token and cost breakdown by hour of day
  • Identify peak usage patterns
  • Useful for rate limit planning

Time Range Controls

RangeDescription
24HLast 24 hours
7DLast 7 days (default)
30DLast 30 days
MonthCurrent calendar month
All TimeComplete history
CustomDate picker for specific range

API Endpoints

Available since v7.51.0 — programmatic access to analytics data
The CCS dashboard server exposes analytics endpoints at http://localhost:3000:
EndpointMethodDescription
/api/usage/summaryGETHigh-level aggregate totals
/api/usage/dailyGETDay-by-day breakdown
/api/usage/hourlyGETHour-by-hour breakdown
/api/usage/modelsGETPer-model usage and costs
/api/usage/sessionsGETSession list with stats
/api/usage/insightsGETAnomaly detection results
/api/usage/refreshPOSTTrigger manual CLIProxy sync
Example:
# Get summary (requires ccs config running)
curl http://localhost:3000/api/usage/summary

# Force refresh CLIProxy data
curl -X POST http://localhost:3000/api/usage/refresh

# Get hourly breakdown
curl http://localhost:3000/api/usage/hourly

Storage

Analytics data is stored locally. No data is sent to external servers.
PathDescription
~/.ccs/usage/Local session usage data
~/.ccs/cache/cliproxy-usage/latest.jsonCLIProxy usage snapshot (refreshed every 5 min)