{"name":"OTEL_EXPORTER_OTLP_ENDPOINT","slug":"otel-exporter-otlp-endpoint","family":"env","title":"Environment variables","noun":"environment variable","description":"Base URL for OTLP telemetry exports. When no signal-specific `OTEL_EXPORTER_OTLP_<SIGNAL>_ENDPOINT` is set, the HTTP exporters send to this URL with `\/v1\/metrics`, `\/v1\/logs` or `\/v1\/traces` appended, and the gRPC exporter uses it as given. Claude Code also reads it to pick the exporter's proxy and TLS agent options and in its gateway telemetry routing checks, and its gateway's managed settings set it to `listen.public_url` when `telemetry.forward_to` is configured.","description_source":"code","described_by":{"bundle":"2.1.286","author":"claude-opus-5-5"},"presence":{"first_seen":"2.1.138","removed_in":null,"in_current_build":true,"newest_mined":"2.1.308","builds":149,"mined_builds":149,"first_cited":null},"aliases":[],"entries":[],"entries_total":0,"docs":[{"source":"claude-code","path":"agent-sdk\/hosting","title":"Hosting the Agent SDK","documented":false},{"source":"claude-code","path":"agent-sdk\/observability","title":"Observability with OpenTelemetry","documented":false},{"source":"claude-code","path":"claude-apps-gateway","title":"Claude apps gateway for Amazon Bedrock, Claude Platform on AWS, Google Cloud, and Microsoft Foundry","documented":false},{"source":"claude-code","path":"claude-apps-gateway-config","title":"Claude apps gateway configuration","documented":false},{"source":"claude-code","path":"monitoring-usage","title":"Monitoring","documented":false},{"source":"claude-code","path":"server-managed-settings","title":"Configure server-managed settings","documented":false},{"source":"claude-code","path":"settings-reference","title":"All settings","documented":false}],"docs_total":7,"gates":[],"related":[{"name":"OTEL_EXPORTER_OTLP_HEADERS","slug":"otel-exporter-otlp-headers","description":"Telemetry exporters can now ignore OTEL_EXPORTER_OTLP_HEADERS and use only the headers given in configuration"},{"name":"OTEL_EXPORTER_OTLP_INSECURE","slug":"otel-exporter-otlp-insecure","description":"Used by the OTLP gRPC exporter when the endpoint starts with neither `http:\/\/` nor `https:\/\/`: `true` (case-insensitive, trimmed) uses insecure credentials, any other value uses TLS credentials. A non-empty signal-specific `OTEL_EXPORTER_OTLP_<SIGNAL>_INSECURE` takes precedence; `http:\/\/` endpoints are always insecure and `https:\/\/` endpoints always use TLS."},{"name":"OTEL_EXPORTER_OTLP_LOGS_ENDPOINT","slug":"otel-exporter-otlp-logs-endpoint","description":"URL for OTLP log exports, used as given without a `\/v1\/logs` suffix and taking precedence over `OTEL_EXPORTER_OTLP_ENDPOINT`. Claude Code also reads it to pick the log exporter's proxy and TLS agent options and when matching the endpoint against a collector named by gateway managed settings."},{"name":"OTEL_EXPORTER_OTLP_LOGS_HEADERS","slug":"otel-exporter-otlp-logs-headers","description":"Comma-separated `key=value` headers for OTLP log exports; the bundled exporters merge it over `OTEL_EXPORTER_OTLP_HEADERS`, its values winning on a clash. While it is set, Claude Code skips some of its built-in routes that attach its own `Authorization: Bearer` token to log exports."},{"name":"OTEL_EXPORTER_OTLP_LOGS_PROTOCOL","slug":"otel-exporter-otlp-logs-protocol","description":"Protocol for the OTLP log exporter when `OTEL_LOGS_EXPORTER` includes `otlp`: `grpc`, `http\/json` or `http\/protobuf`. Unset or empty falls back to `OTEL_EXPORTER_OTLP_PROTOCOL`; any other value throws `Unknown protocol set in OTEL_EXPORTER_OTLP_LOGS_PROTOCOL or OTEL_EXPORTER_OTLP_PROTOCOL env var`."},{"name":"OTEL_EXPORTER_OTLP_METRICS_ENDPOINT","slug":"otel-exporter-otlp-metrics-endpoint","description":"In remote sessions, usage metrics can now go to the session's own metrics address, signed with `CLAUDE_CODE_SESSION_ACCESS_TOKEN`"},{"name":"OTEL_EXPORTER_OTLP_METRICS_HEADERS","slug":"otel-exporter-otlp-metrics-headers","description":"Comma-separated `key=value` headers for OTLP metric exports; the bundled exporters merge it over `OTEL_EXPORTER_OTLP_HEADERS`, its values winning on a clash. While it is set, Claude Code skips some of its built-in routes that attach its own `Authorization: Bearer` token to metric exports, including the remote session ingress collector."},{"name":"OTEL_EXPORTER_OTLP_METRICS_PROTOCOL","slug":"otel-exporter-otlp-metrics-protocol","description":"When metrics are sent over OpenTelemetry by gRPC or HTTP protobuf, Claude Code now prepares an extra resource before creating the exporter"},{"name":"OTEL_EXPORTER_OTLP_METRICS_TEMPORALITY_PREFERENCE","slug":"otel-exporter-otlp-metrics-temporality-preference","description":"Set OTEL_METRICS_EXPORTER=prometheus and child sessions report through the runner, giving one scrape target per machine."},{"name":"OTEL_EXPORTER_OTLP_PROTOCOL","slug":"otel-exporter-otlp-protocol","description":"OTLP transport for Claude Code's telemetry exporters (metrics, logs and traces) when the signal-specific `OTEL_EXPORTER_OTLP_<SIGNAL>_PROTOCOL` variable is empty. Accepted values are `grpc`, `http\/json` and `http\/protobuf`; any other value, including leaving both unset, makes exporter setup throw `Unknown protocol set in ... env var`, and for traces one code path forces `http\/protobuf` regardless. The `claude gateway` server also sets it to `http\/protobuf` in the environment it pushes to clients through managed settings when `telemetry.forward_to` and `listen.public_url` are configured."}],"url":"https:\/\/changelogs.core-directive.com\/reference\/env\/otel-exporter-otlp-endpoint","family_url":"https:\/\/changelogs.core-directive.com\/reference\/env.json"}