Deploy MS Teams Observability with OTLP
Deploy the MS Teams Observability collector and export Teams telemetry to an OTLP-compatible backend such as Grafana Cloud, Datadog, or any OTLP logs endpoint.
Estimated time: 30–40 minutes
What you will deploy:
- Microsoft Entra app registration for Graph API access
- Collector binary on a Linux or Windows host
- OTLP output to your chosen backend
- Live Teams telemetry in your OTLP platform
Before You Start
Section titled “Before You Start”- Microsoft 365 tenant with Teams calling activity
- Entra ID permission to create an app registration
- Admin consent for Graph application permissions
- Collector host with outbound HTTPS access to
graph.microsoft.comand your OTLP endpoint - An OTLP-compatible backend with a reachable logs endpoint and credentials
- License file for live mode (see License)
Step 1 — Create Microsoft Entra App
Section titled “Step 1 — Create Microsoft Entra App”Follow the canonical guide: Azure Permissions.
At the end, you must have:
tenant_idclient_idclient_secretorclient_certificate_path
Step 2 — Install the Collector
Section titled “Step 2 — Install the Collector”Follow Collector Installation to download the binary and build your config.yaml.
Your minimum config:
microsoft_authentication: graph: tenant_id: "<tenant-id>" client_id: "<client-id>" client_secret: "<secret>"
license: filepath: /etc/ms-teams-observability-agent/license.json
collection_config: interval_collection_minutes: 10 features: calls_collection: enabled: trueDo not configure the output section yet — that comes after you choose your OTLP backend.
Step 3 — Configure OTLP Output
Section titled “Step 3 — Configure OTLP Output”Add the OTLP output to your config.yaml. Choose your backend:
output: otel: - name: "grafana" enabled: true endpoint: "https://otlp-gateway-prod-eu-west-2.grafana.net/otlp/v1/logs" service_name: "ms-teams-agent" deployment_environment: "prod" headers: Authorization: "Basic <credentials>"See OTLP to Grafana for detailed setup.
output: otel: - name: "datadog" enabled: true endpoint: "https://otlp.datadoghq.com/v1/logs" service_name: "ms-teams-agent" deployment_environment: "prod" headers: DD-API-KEY: "<api-key>"See OTLP to Datadog for detailed setup.
output: otel: - name: "dynatrace" enabled: true endpoint: "https://{your-tenant}.live.dynatrace.com/api/v2/otlp/v1/logs" service_name: "ms-teams-agent" deployment_environment: "prod" headers: Authorization: "Api-token <token>"output: otel: - name: "my-backend" enabled: true endpoint: "https://your-otlp-endpoint/v1/logs" service_name: "ms-teams-agent" deployment_environment: "prod" headers: Authorization: "Bearer <token>"See OTLP Collector Connection for all parameters.
Step 4 — Validate
Section titled “Step 4 — Validate”-
Validate file structure and business rules:
Terminal window ms-teams-agent validate --config ./config.yaml -
Test Graph auth and OTLP connectivity:
Terminal window ms-teams-agent test-connection --config ./config.yaml -
Run one dry cycle:
Terminal window ms-teams-agent run --config ./config.yaml --dry-run
✅ Success criteria:
validatereturns no errortest-connectionconfirms Graph authentication and OTLP endpoint connectivitydry-runcompletes one cycle without errors
❌ If this fails:
Step 5 — Verify Data
Section titled “Step 5 — Verify Data”- Run a collector cycle:
ms-teams-agent run --config ./config.yaml --ignore-state - In your OTLP platform, confirm logs are visible:
- Grafana: filter logs by
service_name = "ms-teams-agent" - Datadog: check Log Explorer for Teams event families
- Dynatrace (OTLP): confirm logs arrive with expected source fields
- Grafana: filter logs by
Next Steps
Section titled “Next Steps”- Configure service mode for production persistence
- Customize OTLP headers and metadata in the Configuration Reference