diff --git a/docs/source/configuration/logging.mdx b/docs/source/configuration/logging.mdx index 832cdccddb..a6f902970d 100644 --- a/docs/source/configuration/logging.mdx +++ b/docs/source/configuration/logging.mdx @@ -71,9 +71,13 @@ JSON-formatted logging provides compatibility with common searchable logging too > This is part of an experimental feature, it means any time until it's stabilized (without the prefix `experimental_`) we might change the configuration shape or adding/removing features. > If you want to give feedback or participate in that feature feel free to join [this discussion on GitHub](https://github.com/apollographql/router/discussions/1961). -By default some of our logs containing sensitive data (like request body, response body, headers) are not displayed even if we are in the right log level. -For example if you need to display raw responses from one of your subgraph it won't be displayed by default. To enable them you have to configure it thanks to the `contains_attributes` setting. -Here is an example on how you can configure it: +By default, the router _doesn't_ log certain values that might contain sensitive data, even if a sufficient log level is set: + + - Request bodies + - Response bodies + - Headers + +You can enable selective logging of these values via the `when_header` option: ```yaml title="router.yaml" telemetry: