Blog Post

Microsoft Developer Community Blog
5 MIN READ

Building a GitHub Copilot Agent Usage Dashboard

jometzg's avatar
jometzg
Icon for Microsoft rankMicrosoft
Jun 01, 2026

with OpenTelemetry, Container Apps, Azure Monitor and Grafana

Introduction

Working with organisations that are attempting to create GitHub Copilot custom agents, take-up of these agents by their community becomes important to know. Some questions quickly emerge are "how well are we actually using it?", "which agents are getting used and which have not had that much traction?".

Native metrics provide high-level insights into adoption, but they lack the depth needed to answer more granular questions—such as which agent workflows are most used, or how behaviour evolves over time.

In this post, I’ll walk through how to build an enterprise-grade GitHub Copilot usage dashboard that captures detailed telemetry from VS Code using OpenTelemetry, processes it in Azure Monitor, and visualises insights in Grafana—all using a reproducible, infrastructure-as-code approach. The dashboard can be made available to anyone that needs it.

Architecture

VS Code can be configured to emit metrics using Open Telemetry as a standard. This is a configuration item in VS Code and you essentially point it to an Open Telemetry Collector. The collector is an endpoint that can consume the telemetry.

In this implementation, it is a container image that is hosted in Azure and I have chosen Azure Container Apps (ACA) for this purpose as it is an easy to use managed environment - but it could also run in Azure Kubernetes Service (AKS) with a little more effort.

There is a prebuilt image opentelemetry collector for this and this has been adapted to inject configuration to send the telemetry to Azure Application Insights.

For defining and hosting the dashboard, I have chosen another Azure managed service Azure Managed Grafana

Sample Dashboard

The sample dashboard is one that contains a collection of visualisations derived from the collected data in Application Insights. Azure Managed Grafana allows you to visually author these dashboards or they can be implemented as a JSON file and adapted from there.

Note that the telemetry generated by VS Code gives the location of the users - city, region and country, but does not include any personally-identifying information (PII) and so cannot be used to track individuals. As I understand it, this is by design.

Managed Grafana has its own permission structure, which may then be used to give users access to the dashboard. 

Implementation Details

There is a GitHub repo Copilot Usage Dashboard that contains details of how to implement this together with instructions for either "click-ops" 🙂creation or via Terraform. So I suggest you follow the link to my repo to look at the details. In summary, there needs to be in Azure:

  • Azure Container App (ACA) that hosts the collector - this needs to have public ingress
  • Azure Container Registry (ACR) that hosts the docker image that is customised via the Dockerfile
  • Key Vault that hosts the Application Insights connection string that ACA references
  • Application Insights - this needs to be created with a flag to allow it to work with Grafana data
  • Log Analytics Workspace that works with Application Insights
  • Azure Managed Grafana to host the Grafana dashboard

The main thing to bear in mind is that VS Code needs to be configured to emit OpenTelemetry

{
  "github.copilot.nextEditSuggestions.enabled": true,
  "github.copilot.chat.otel.enabled": true,
  "github.copilot.chat.otel.exporterType": "otlp-http",
  "github.copilot.chat.otel.otlpEndpoint": "https://<fqdn>"
}

where the FQDN is the URL of the public ingress to the Azure Container App.

There is a Dockerfile in this repo that just injects the correct configuration file into the OpenTelemetry collector image. It is this configuration file that tells the collector to emit to Application Insights. It is of the form below:

receivers:
  otlp:
    protocols:
      grpc:
        endpoint: 0.0.0.0:4317
      http:
        endpoint: 0.0.0.0:4318

processors:
  batch:
  attributes:
    actions:
      - key: environment
        value: "prod"
        action: upsert

exporters:
  azuremonitor:
    connection_string: "${APPLICATIONINSIGHTS_CONNECTION_STRING}"
  debug:
    verbosity: detailed

service:
  pipelines:
    traces:
      receivers: [otlp]
      processors: [batch, attributes]
      exporters: [azuremonitor, debug]

    metrics:
      receivers: [otlp]
      processors: [batch, attributes]
      exporters: [azuremonitor]

As can be seen above, there is a placeholder for the Application Insights connection string - in the ACA configuration this is an environment variable that then points to a secret which is in key vault.

If all is well, VS Code will emit telemetry to the container image running in ACA and this will use its configuration to send to Application Insights. The Grafana dashboard then using this data.

Troubleshooting

The GitHub repo goes into the detail of troubleshooting, but the overall steps to troubleshoot are:

  1. If there is no data in Grafana, check that Grafana has access to Application Insights
  2. check whether there is telemetry being pushed into Application Insights by looking at the logs and looking for the contents of the table Dependencies. If there is telemetry there, then it is Grafana permissions. If not, look to ACA
  3. Look at ACA logs to see if it is healthy and look to see if there is any logs being received
  4. Use a curl request to send a fake log to ACA (a sample is in the repo) to see if the ACA is accepting logs
  5. Check the connection to Application Insights is correct and is being pulled from key vault or replace the environment variable value with the connection string directly
  6. If all good so far, then it may be that the configuration in VS Code is not correct or in the correct place.

Hopefully the more detailed steps will resolve any issues quickly.

Further thoughts and enhancements

This implementation attempts to build a dashboard showing GitHub Copilot agent usage using a standard set of security controls, but more may be needed. Here is a list of possible enhancements:

  1. A more refined dashboard. This should be easy as there are samples for all sorts of visualisations and few of these may allow more focus on agent and model usage.
  2. the ACA-hosted OpenTelemetry collector has a public-facing ingress. This may need to be locked-down at the network level by address restriction or by a non-public ingress. Care would need to be taken to make sure that this is then visible/reachable to the intended VS Code user audience
  3. The ACA collector endpoint is not authenticated in of itself. This could be achieved at the container level by putting an authenticating proxy in the Dockerfile or at the ACA ingress level. Some investigation would be needed to see how the VS Code configuration could work with this and this may dictate largely what form this authentication can take.
  4. How the VS Code configuration changes can be automated for a user base has not been investigated as part of this work. It is assumed that an organisation may be able to roll-out these changes using their application deployment automation.

Summary

This approach provides a means by which an organisation can track the usage of GitHub Copilot agents (and their models), that is not provided by GitHub Enterprise dashboards. This will provide insights into the take up of custom agents and their underlying models - allowing an organisation to test whether their investments on custom agents are being used effectively. Additionally, the dashboards themselves can easily be rolled-out to a wider community than GitHub Enterprise one.  

Updated May 28, 2026
Version 1.0