Apps & Software

GitHub Updates Copilot Usage Metrics API to Include Additional Developer Tools

· GlobeWire Daily Editorial Desk · Source: github.blog

2 min read

Key takeawaysAccording to an official GitHub changelog announcement, the Copilot usage metrics API has been updated to report model usage from a wider variety of developer tools, such as OpenCode, which were previously omitted from reports. GitHub stated that this expansion is designed to address visibility gaps caused by developers using Copilot as a model provider…
GitHub Updates Copilot Usage Metrics API to Include Additional Developer Tools

Image: The GitHub Blog · Photo source · Resized and letterboxed to 16:9; no AI generation

According to an official GitHub changelog announcement, the Copilot usage metrics API has been updated to report model usage from a wider variety of developer tools, such as OpenCode, which were previously omitted from reports. GitHub stated that this expansion is designed to address visibility gaps caused by developers using Copilot as a model provider outside traditional IDEs.

Understanding the New Data Structure

GitHub reports that a new `totals_by_client` array is now accessible within enterprise, organization, enterprise-user, and organization-user reports for both 1-day and 28-day intervals.

  • Client Identification: Each entry designates the specific tool that sent requests, such as `opencode`, `claude_code`, `codex`, `zed`, `copilot_cli`, `github_app`, `cloud_agent`, `code_review`, `vscode`, or `jetbrains`. Unrecognized clients are categorized under `other`.
  • Request and Session Counts: Tracks the number of successful model requests and distinct sessions per client. Note that `request_count` counts model calls rather than individual prompts, meaning a single prompt may trigger multiple calls.
  • Token Usage: Provides details on prompt tokens, output tokens, and average tokens per request.
  • Model Breakdowns: The `totals_by_model` field details request and token metrics per model, featuring a `model_selection_mode` to indicate whether a model was requested directly (`user_selected`), chosen by auto (`auto`), or selected by the product (`product_selected`).

Scope, Access, and Important Distinctions

GitHub notes that this update applies to enterprise and organization-level reports in 1-day and 28-day formats. In aggregated 28-day reports, the new array appears within each `day_totals` entry.

  • Access Requirements: Available to enterprise owners, billing managers, organization owners, and custom roles granted the "View Copilot Metrics" permission, provided the Copilot usage metrics policy is enabled.
  • Metric Distinction: GitHub clarifies that `totals_by_client` measures model traffic and token usage from any tool utilizing Copilot, which differs from agent app activity that measures jobs started by agent apps like Claude and Codex on GitHub.
  • Client Reliability: Integration IDs sent with requests identify clients, meaning organizations should treat the client field as a best-effort grouping rather than a verified identity.
  • Compatibility: The change is fully additive; existing fields remain unchanged, and the array defaults to empty when no usage data exists.

To verify these updates and begin implementation, users can consult the official Copilot usage metrics API documentation on the GitHub Blog.

Share this article
Read the original source: Usage metrics API adds usage from tools like OpenCode - The GitHub Blog

AI-assisted reporting; source claims are attributed and have not been independently verified.

About the author

GlobeWire Daily Editorial Desk — AI-assisted news based on attributed published sources.

More to read