Skip to content

Commit

Permalink
observability/apm: reduce python specific doc for OTEL_EXPORTER_OTLP_…
Browse files Browse the repository at this point in the history
…HEADERS (#4280)

* observability/apm: reduce python specific doc for OTEL_EXPORTER_OTLP_HEADERS

Special treatment of headers is not needed anymore since latest release so reduce the text to a note.

* Looks like callouts do not work in tables

* Update docs/en/observability/apm/otel-direct.asciidoc

Co-authored-by: Colleen McGinnis <[email protected]>

---------

Co-authored-by: Colleen McGinnis <[email protected]>
  • Loading branch information
xrmx and colleenmcginnis authored Sep 24, 2024
1 parent eccfa6d commit 53aaf31
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions docs/en/observability/apm/otel-direct.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -126,13 +126,7 @@ For information on how to format an API key, see

Please note the required space between `Bearer` and `an_apm_secret_token`, and `ApiKey` and `an_api_key`.

The Python OpenTelemetry agent requires the content of the header to be URL-encoded. For the `Bearer` token that would mean substituting the space between `Bearer` and the token with `%20`, e.g. `"Authorization=Bearer%20an_apm_secret_token"`, for encoding an API key you can use the following snippet:

[source,python]
----
from urllib.parse import quote
quote("ApiKey an_api_key")
----
NOTE: If you are using a version of the Python OpenTelemetry agent _before_ 1.27.0, the content of the header _must_ be URL-encoded. You can use the Python standard library's `urllib.parse.quote` function to encode the content of the header.

| `OTEL_METRICS_EXPORTER` | Metrics exporter to use. See https://opentelemetry.io/docs/specs/otel/configuration/sdk-environment-variables/#exporter-selection[exporter selection] for more information.

Expand Down

0 comments on commit 53aaf31

Please sign in to comment.