{"version":"2.1.334","anchor":"otlp-telemetry-can-follow-the-hosts-credential","canonical_anchor":"otlp-telemetry-can-follow-the-hosts-credential","heading":"OpenTelemetry exports can reuse the host's login and retry refused batches","tier":"notice","area":"Telemetry","scope":"org","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.334\/e\/otlp-telemetry-can-follow-the-hosts-credential","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.334","markdown":"### OpenTelemetry exports can reuse the host's login and retry refused batches\n\nOpenTelemetry exports can reuse the host's credential, and batches refused for a bad credential are re-sent once\n\n**Unclear.** It is not clear whether `CLAUDE_CODE_HOST_AUTH_ENV_VAR` is meant to be set by users or by an app that launches Claude Code.\n\n**What**\n\nClaude Code can send monitoring data to your own collector using OTLP, the OpenTelemetry format. Two things are different:\n\n- The exporter can reuse the host's login header. `CLAUDE_CODE_HOST_AUTH_ENV_VAR` names the variable to take it from, either `ANTHROPIC_AUTH_TOKEN` or `ANTHROPIC_CUSTOM_HEADERS`. This happens only when the collector address and headers match the host's configuration.\n\n- When the collector refuses a batch with a 401 or 403 error (a login refusal), Claude Code keeps the batch and sends it once more under the current credential. A log line reports how many batches were re-sent.\n\n**Why**\n\nMonitoring data refused because a credential expired is no longer quietly lost.\n\n- Area: Telemetry\n- Tier: You'll notice\n- Useful: 3\/5\n- Signal: 2\/5\n- Scope: org\n- Heads-up: no"}