Answer: Set `CLAUDE_CODE_ENABLE_TELEMETRY=1` and choose at least one exporter, typically configuring OTLP HTTP exporters for traces, metrics, and logs via `options.env` (or by exporting the variables in your environment). Status: Confirmed Entry: tool/claude-code/integrations/enable-telemetry-export Revision: 2 Digest: sha256:9e25fd0131badc65 (changes whenever the content changes) Timeline: Created: 2026-11-13T12:06:47Z Last changed: 2026-11-20T12:16:52Z (enhanced telemetry beta: — → 1) Last verified: 2026-11-20T12:16:52Z Next check: 2026-11-21T12:16:52Z Check interval: Daily Expected change: No fixed schedule Data: Field | Value | Source | As of enable telemetry | CLAUDE_CODE_ENABLE_TELEMETRY=1 | [1] | 2026-11-20 traces exporter | otlp | [1] | 2026-11-20 metrics exporter | otlp | [1] | 2026-11-20 logs exporter | otlp | [1] | 2026-11-20 OTLP protocol | http/protobuf | [1] | 2026-11-20 OTLP endpoint | http://collector.example.com:4318 | [1] | 2026-11-20 enhanced telemetry beta | 1 | [1] | 2026-11-20 Sources: [1] Anthropic. "Observability with OpenTelemetry". https://code.claude.com/docs/en/agent-sdk/observability.md Role: primary. Accessed: 2026-11-20T12:17:05Z Retrieved via: DeepSeek Fetch API (Markdown conversion; the original server response was not captured) Quote: "Telemetry is off until you set `CLAUDE_CODE_ENABLE_TELEMETRY=1` and choose at least one exporter." (Supports: enable telemetry) Quote: ""OTEL_TRACES_EXPORTER": "otlp"," (Supports: traces exporter) Quote: ""OTEL_METRICS_EXPORTER": "otlp"," (Supports: metrics exporter) Quote: ""OTEL_LOGS_EXPORTER": "otlp"," (Supports: logs exporter) Quote: ""OTEL_EXPORTER_OTLP_PROTOCOL": "http/protobuf"," (Supports: OTLP protocol) Quote: ""OTEL_EXPORTER_OTLP_ENDPOINT": "http://collector.example.com:4318"," (Supports: OTLP endpoint) Quote: ""CLAUDE_CODE_ENHANCED_TELEMETRY_BETA": "1"," (Supports: enhanced telemetry beta) Snapshot SHA-256: 3ff938d504c658571c6730456c440fafdebc635cbba796bcecaf51a087824ddb (captured 2026-11-20T12:17:05Z) Verification: Method: Automated extraction from [1] with deepseek-flash (JSON output, thinking disabled). Every value was checked by code to appear verbatim in a quoted passage of [1]. [1] was retrieved through the DeepSeek Fetch API because a direct request did not return usable content. Cross-check: not-available at 2026-11-20T12:16:52Z. No independent second source is configured for this entry Last successful check: 2026-11-20T12:16:52Z Last attempt: 2026-11-20T12:16:52Z Notes and limitations: Extracted automatically from a single official source (section "Enable telemetry export"). Related: https://latestn.com/tool/claude-code/integrations/expose-reply-tool How do I expose a reply tool so Claude can send messages back through a Claude Code channel? https://latestn.com/tool/claude-code/integrations/features-by-provider Which Claude Code features are available on Amazon Bedrock, Google Cloud's Agent Platform, or Microsoft Foundry? https://latestn.com/tool/claude-code/integrations/flush-telemetry-short-lived-calls How do I flush telemetry from short-lived Claude Agent SDK calls? https://latestn.com/tool/claude-code/integrations/disable-mcp-server-without-removing How do I disable an MCP server in Claude Code without removing it? https://latestn.com/tool/claude-code/integrations/eligible-marketplaces-for-hints Which marketplaces qualify for Claude Code CLI plugin hints? https://latestn.com/tool/claude-code/integrations/emit-claude-code-hint-tag How do I emit a claude-code-hint tag from my CLI so Claude Code users are prompted to install my plugin? https://latestn.com/tool/ All entries in AI tools Change log: Time | Event | Change | Source 2026-11-20T12:16:52Z | changed | enhanced telemetry beta: — → 1 | [1] 2026-11-20T12:16:52Z | changed | logs exporter: — → otlp | [1] 2026-11-20T12:16:52Z | changed | metrics exporter: — → otlp | [1] 2026-11-20T12:16:52Z | changed | traces exporter: — → otlp | [1] 2026-11-20T12:16:52Z | changed | enable telemetry: — → CLAUDE_CODE_ENABLE_TELEMETRY=1 | [1] 2026-11-20T12:16:52Z | changed | Enhanced telemetry beta variable: CLAUDE_CODE_ENHANCED_TELEMETRY_BETA → — | [1] 2026-11-20T12:16:52Z | changed | Logs exporter: otlp → — | [1] 2026-11-20T12:16:52Z | changed | Metrics exporter: otlp → — | [1] 2026-11-20T12:16:52Z | changed | Traces exporter: otlp → — | [1] 2026-11-20T12:16:52Z | changed | Enable telemetry variable: CLAUDE_CODE_ENABLE_TELEMETRY=1 → — | [1] 2026-11-13T12:06:47Z | added | Entry created | — Changes for this entry as a feed: https://latestn.com/tool/claude-code/integrations/enable-telemetry-export/latest Challenge this entry: Open challenges: None How: If a value here is wrong or out of date, send what is wrong and a link to evidence. Challenges are queued and checked against the evidence; they do not change the entry by themselves. If the entry changes as a result, the change log says so. Form: https://latestn.com/dispute/tool/claude-code/integrations/enable-telemetry-export POST: https://latestn.com/dispute/tool/claude-code/integrations/enable-telemetry-export with claim, evidence_url, and optionally field and contact (form-encoded or JSON) GET: https://latestn.com/dispute/tool/claude-code/integrations/enable-telemetry-export?claim={what is wrong}&evidence_url={link} How to cite: LatestN. (2026). How do I enable OpenTelemetry telemetry export in the Claude Agent SDK? Revision 2, last verified 2026-11-20T12:16:52Z. https://latestn.com/tool/claude-code/integrations/enable-telemetry-export (accessed 2026-11-21T09:52:58Z). @misc{LatestN_tool_claude_code_integrations_enable_telemetry_export_r2, title = {How do I enable OpenTelemetry telemetry export in the Claude Agent SDK?}, author = {{LatestN}}, year = {2026}, howpublished = {\url{https://latestn.com/tool/claude-code/integrations/enable-telemetry-export}}, note = {Revision 2; digest sha256:9e25fd0131badc65; last verified 2026-11-20T12:16:52Z; accessed 2026-11-21T09:52:58Z} } Reuse: License: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/) Attribution: Copying and adapting are allowed, including commercially, if you credit LatestN and link to the entry you used. Each entry ends with a ready-made citation. URL: https://latestn.com/tool/claude-code/integrations/enable-telemetry-export