Skip to content

Commit bbb7cd6

Browse files
docs: clarify OTEL_EXPORTER_OTLP_HEADERS automatic support
- Document that SDK automatically reads OTEL_EXPORTER_OTLP_HEADERS - Add OTEL_EXPORTER_OTLP_TRACES_HEADERS to environment variables list - Clarify no additional code configuration is required - Improve Honeycomb example description Co-authored-by: Ona <no-reply@ona.com>
1 parent 37b8194 commit bbb7cd6

File tree

2 files changed

+7
-1
lines changed

2 files changed

+7
-1
lines changed

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -610,12 +610,14 @@ export OTEL_EXPORTER_OTLP_ENDPOINT=localhost:4318
610610
export OTEL_EXPORTER_OTLP_INSECURE=true
611611
leeway build :my-package
612612
613-
# Production (Honeycomb)
613+
# Production (Honeycomb with API key)
614614
export OTEL_EXPORTER_OTLP_ENDPOINT=api.honeycomb.io:443
615615
export OTEL_EXPORTER_OTLP_HEADERS="x-honeycomb-team=YOUR_API_KEY"
616616
leeway build :my-package
617617
```
618618

619+
The OpenTelemetry SDK automatically reads standard `OTEL_EXPORTER_OTLP_*` environment variables.
620+
619621
**For detailed configuration, examples, and span attributes, see [docs/observability.md](docs/observability.md).**
620622

621623
# Provenance (SLSA) - EXPERIMENTAL

docs/observability.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,13 @@ Leeway supports W3C Trace Context propagation, allowing builds to be part of lar
4646

4747
- `OTEL_EXPORTER_OTLP_ENDPOINT`: OTLP endpoint URL (e.g., `localhost:4318` or `api.honeycomb.io:443`)
4848
- `OTEL_EXPORTER_OTLP_INSECURE`: Disable TLS for OTLP endpoint (`true` or `false`, default: `false`)
49+
- `OTEL_EXPORTER_OTLP_HEADERS`: HTTP headers for OTLP requests (e.g., `x-honeycomb-team=YOUR_API_KEY`)
50+
- `OTEL_EXPORTER_OTLP_TRACES_HEADERS`: Trace-specific headers (takes precedence over `OTEL_EXPORTER_OTLP_HEADERS`)
4951
- `TRACEPARENT`: W3C Trace Context traceparent header (format: `00-{trace-id}-{span-id}-{flags}`)
5052
- `TRACESTATE`: W3C Trace Context tracestate header (optional)
5153

54+
**Note:** The OpenTelemetry SDK automatically reads `OTEL_EXPORTER_OTLP_HEADERS` and `OTEL_EXPORTER_OTLP_TRACES_HEADERS` from the environment. No additional configuration is required.
55+
5256
### CLI Flags
5357

5458
- `--otel-endpoint`: OTLP endpoint URL (overrides `OTEL_EXPORTER_OTLP_ENDPOINT`)

0 commit comments

Comments
 (0)