cd /news/ai-tools/usage-metrics-api-adds-usage-from-to… · home › topics › ai-tools › article
[ARTICLE · art-156483] src=github.blog ↗ pub= topic=ai-tools verified=true sentiment=↑ positive

Usage metrics API adds usage from tools like OpenCode

GitHub's Copilot usage metrics API now reports model usage from tools outside the IDE, including OpenCode, Claude Code, Codex, Zed, Copilot CLI, the GitHub app, cloud agent, code review, VS Code and JetBrains, through a new `totals_by_client` array in the enterprise, organization, enterprise-user and organization-user 1-day and 28-day reports. Each entry carries `request_count`, `session_count`, `token_usage` and a `totals_by_model` breakdown with a `model_selection_mode` of `user_selected`, `auto` or `product_selected`, closing a gap left by tools that send no editor telemetry and were missing from `totals_by_ide`. GitHub said the change is additive, existing fields are unchanged, and `totals_by_client` is an empty array when there is no usage to report; access requires the `View Copilot Metrics` permission and the Copilot usage metrics policy enabled.

by read2 min views2 publishedOct 23, 2026
Usage metrics API adds usage from tools like OpenCode
Image: GitHub Changelog

The Copilot usage metrics API now reports model usage from more of the tools your developers use with Copilot, including tools like OpenCode that weren’t previously captured in your reports. A new totals_by_client array is available in the enterprise, organization, enterprise-user, and organization-user 1-day and 28-day reports.

What’s new

Each totals_by_client entry represents one client and includes:

  • client : The tool that sent the requests, such as opencode ,claude_code ,codex ,zed ,copilot_cli ,github_app ,cloud_agent ,code_review ,vscode , orjetbrains . Unrecognized clients are grouped underother .
  • request_count : The number of successful model requests from the client.
  • session_count : The number of distinct sessions from the client.
  • token_usage : Prompt tokens, output tokens, and average tokens per request.
  • totals_by_model : The same request and token metrics broken down by model, with amodel_selection_mode that shows whether the model was requested directly (user_selected ), chosen by auto (auto ), or chosen by the product (product_selected ). Selection modes that aren’t reported individually yet appear asother , and values that can’t be normalized appear asunknown .

Why this matters

More developers now use Copilot as the model provider behind tools outside the IDE. Because those tools often don’t send editor telemetry, their usage was missing from totals_by_ide and hard to account for. Counting requests on the server closes that gap, so you can see which tools drive Copilot usage, compare request and token volume across them, and base tool support and governance decisions on real usage.

This is different from agent app activity, which counts jobs started by agent apps such as Claude and Codex on GitHub. totals_by_client measures model traffic, meaning requests and tokens, from any tool that uses Copilot.

Important notes

  • Scope: Enterprise, organization, enterprise-user, and organization-user reports, in both 1-day and 28-day versions. In the aggregated 28-day reports,totals_by_client appears in eachday_totals entry.
  • Access: Available to enterprise owners and billing managers, organization owners, and anyone with a custom organization or enterprise role that grants theView Copilot Metrics permission. The Copilot usage metrics policy must be enabled.
  • Copilot code review and Copilot cloud agent: Requests from these clients reportproduct_selected because the product chooses the model. Copilot code review models are reported asunknown .
  • Request counts:request_count counts model calls, not prompts. One prompt can trigger several model calls, so don’t compare this field directly with prompt or interaction counts.
  • Client identification: Clients are identified by the integration ID they send with each request. Treatclient as a best-effort grouping, not a verified identity.
  • Backward compatibility: This change is additive. Existing fields are unchanged, andtotals_by_client is an empty array when there is no usage to report.

Visit the Copilot usage metrics API documentation to get started.

── more in #ai-tools 4 stories · sorted by recency
── more on @github 3 stories trending now
sponsored brought to you by zahid.host 4,200+ EU-deployed projects
reading about agents? ship yours in a single git push.

Run your AI side-project on zahid.host

EU-based hosting, git-push deploys, automatic HTTPS, no cold starts. Free tier with a custom domain — perfect for shipping the agent you just read about.

$git push zahid main
→ Live at https://your-agent.zahid.host ✓
Get free account → Pricing
from €0/mo · no card required
LIVE [news/usage-metrics-api-ad…] indexed:0 read:2min 2026-10-23 · —