From 0098710f811187981cc05eb5a6194ff352302526 Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Fri, 13 Sep 2024 16:48:35 +0100 Subject: [PATCH 01/15] Persistent logs initial documentation --- .../observability/persistent-logs.mdx | 41 +++++++++++++++++++ src/content/partials/ai-gateway/logging.mdx | 10 +++++ 2 files changed, 51 insertions(+) create mode 100644 src/content/docs/ai-gateway/observability/persistent-logs.mdx create mode 100644 src/content/partials/ai-gateway/logging.mdx diff --git a/src/content/docs/ai-gateway/observability/persistent-logs.mdx b/src/content/docs/ai-gateway/observability/persistent-logs.mdx new file mode 100644 index 00000000000000..1dc024d07d6f17 --- /dev/null +++ b/src/content/docs/ai-gateway/observability/persistent-logs.mdx @@ -0,0 +1,41 @@ +--- +pcx_content_type: reference +title: Persistent logs +sidebar: + badge: + text: Beta +--- + +import { Render } from "~/components"; + +Logging is a fundamental building block for application development. Logging provides insights during the early stages of development and is often critical to understanding issues occurring in production. + +Your AI Gateway dashboard shows logs of individual requests, including the user prompt, model response, provider, timestamp, request status, token usage, cost, and duration. These logs persist, giving you the flexibility to store them for your preferred duration and do more with valuable request data. You can store up to 10 million logs per gateway. + +When you are nearing your plan limit, an alert will be displayed in the dashboard. If your limit is reached, new logs will stop being saved. To continue saving logs, you must delete older logs to free up space for new logs. + +To learn more about your plan limits, refer to the [Pricing](/ai-gateway/pricing/) page. + +## Default configuration + +Logs, which include metrics as well as request and response data are enabled by default for each gateway. If you are concerned about privacy or compliance and want to turn log collection off, you can go to settings and opt out of logs. + + + +This logging behavior will be uniformly applied to all requests in the gateway. If you need to modify the logging settings for specific requests, you can override this setting on a per-request basis. + +:::note[Note] + +If you turn off logging and are using Logpush, this will prevent the response and request body from being forwarded through Logpush. + +::: + +## Per-request logging + +To override the default logging behavior set in the settings tab, you can define headers on a per-request basis. + +## `cf-log-override` + +The `cf-log-override` header allows you to bypass the default log setting for the gateway. If the gateway is configured to save logs, the header will exclude the user prompt and model response data for that specific request. Conversely, if logging is disabled at the gateway level, this header will save the user prompt and model response data for that request. + +In this example, the gateway is configured to save logs, however we do not want this specific request to save the user prompt and model response. diff --git a/src/content/partials/ai-gateway/logging.mdx b/src/content/partials/ai-gateway/logging.mdx new file mode 100644 index 00000000000000..192179ae55d37b --- /dev/null +++ b/src/content/partials/ai-gateway/logging.mdx @@ -0,0 +1,10 @@ +--- +{} +--- + +To change the default log configuration in the dashboard: + +1. Log in to the [Cloudflare dashboard](https://dash.cloudflare.com/) and select your account. +2. Go to **AI** > **AI Gateway**. +3. Select **Settings**. +4. Change the **Logs** setting to your preference. From fcd0cc66dc13f48ee38d737e442f16ba4697d7ad Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Tue, 17 Sep 2024 12:19:54 +0100 Subject: [PATCH 02/15] Changed header --- src/content/docs/ai-gateway/observability/persistent-logs.mdx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/content/docs/ai-gateway/observability/persistent-logs.mdx b/src/content/docs/ai-gateway/observability/persistent-logs.mdx index 1dc024d07d6f17..fe1fd455b39acc 100644 --- a/src/content/docs/ai-gateway/observability/persistent-logs.mdx +++ b/src/content/docs/ai-gateway/observability/persistent-logs.mdx @@ -34,8 +34,8 @@ If you turn off logging and are using Logpush, this will prevent the response an To override the default logging behavior set in the settings tab, you can define headers on a per-request basis. -## `cf-log-override` +## `collect_logs` -The `cf-log-override` header allows you to bypass the default log setting for the gateway. If the gateway is configured to save logs, the header will exclude the user prompt and model response data for that specific request. Conversely, if logging is disabled at the gateway level, this header will save the user prompt and model response data for that request. +The `collect_logs` header allows you to bypass the default log setting for the gateway. If the gateway is configured to save logs, the header will exclude the user prompt and model response data for that specific request. Conversely, if logging is disabled at the gateway level, this header will save the user prompt and model response data for that request. In this example, the gateway is configured to save logs, however we do not want this specific request to save the user prompt and model response. From af0e8075e5ec803b8a5f1e83edd3efb2e7fca2b7 Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Fri, 20 Sep 2024 16:00:30 +0100 Subject: [PATCH 03/15] Renamed persistent logs to logging --- .../observability/{persistent-logs.mdx => logging.mdx} | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) rename src/content/docs/ai-gateway/observability/{persistent-logs.mdx => logging.mdx} (98%) diff --git a/src/content/docs/ai-gateway/observability/persistent-logs.mdx b/src/content/docs/ai-gateway/observability/logging.mdx similarity index 98% rename from src/content/docs/ai-gateway/observability/persistent-logs.mdx rename to src/content/docs/ai-gateway/observability/logging.mdx index fe1fd455b39acc..f393801eb29712 100644 --- a/src/content/docs/ai-gateway/observability/persistent-logs.mdx +++ b/src/content/docs/ai-gateway/observability/logging.mdx @@ -1,6 +1,6 @@ --- pcx_content_type: reference -title: Persistent logs +title: Logging sidebar: badge: text: Beta @@ -34,7 +34,7 @@ If you turn off logging and are using Logpush, this will prevent the response an To override the default logging behavior set in the settings tab, you can define headers on a per-request basis. -## `collect_logs` +## Collect logs (collect_logs) The `collect_logs` header allows you to bypass the default log setting for the gateway. If the gateway is configured to save logs, the header will exclude the user prompt and model response data for that specific request. Conversely, if logging is disabled at the gateway level, this header will save the user prompt and model response data for that request. From ce6722f1cae6969a6817647a05dd0304d25498eb Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Mon, 23 Sep 2024 13:40:46 +0100 Subject: [PATCH 04/15] Added collect log code example --- .../docs/ai-gateway/observability/logging.mdx | 21 +++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/src/content/docs/ai-gateway/observability/logging.mdx b/src/content/docs/ai-gateway/observability/logging.mdx index f393801eb29712..b8c09c86ca9488 100644 --- a/src/content/docs/ai-gateway/observability/logging.mdx +++ b/src/content/docs/ai-gateway/observability/logging.mdx @@ -34,8 +34,25 @@ If you turn off logging and are using Logpush, this will prevent the response an To override the default logging behavior set in the settings tab, you can define headers on a per-request basis. -## Collect logs (collect_logs) +## Collect logs (cf-aig-collect-log) -The `collect_logs` header allows you to bypass the default log setting for the gateway. If the gateway is configured to save logs, the header will exclude the user prompt and model response data for that specific request. Conversely, if logging is disabled at the gateway level, this header will save the user prompt and model response data for that request. +The `cf-aig-collect-log` header allows you to bypass the default log setting for the gateway. If the gateway is configured to save logs, the header will exclude the user prompt and model response data for that specific request. Conversely, if logging is disabled at the gateway level, this header will save the user prompt and model response data for that request. In this example, the gateway is configured to save logs, however we do not want this specific request to save the user prompt and model response. + +```bash +curl https://gateway.ai.cloudflare.com/v1/{account_id}/{gateway_id}/openai/chat/completions \ + --header 'Authorization: Bearer $TOKEN' \ + --header 'Content-Type: application/json' \ + --header 'cf-aig-collect-log: false \ + --data ' { + "model": "gpt-4o-mini", + "messages": [ + { + "role": "user", + "content": "What is the email address and phone number of user123?" + } + ] + } +' +``` From d12caab0270636cccaf1553e29ecd111f4ea3a7f Mon Sep 17 00:00:00 2001 From: Kathy <153706637+kathayl@users.noreply.github.com> Date: Mon, 23 Sep 2024 14:58:45 +0100 Subject: [PATCH 05/15] Update logging.mdx updates to wording bc how per request logging is set up the whole log does not show, not just the user prompt + model response --- src/content/docs/ai-gateway/observability/logging.mdx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/content/docs/ai-gateway/observability/logging.mdx b/src/content/docs/ai-gateway/observability/logging.mdx index b8c09c86ca9488..fe6e189734cfa6 100644 --- a/src/content/docs/ai-gateway/observability/logging.mdx +++ b/src/content/docs/ai-gateway/observability/logging.mdx @@ -18,7 +18,7 @@ To learn more about your plan limits, refer to the [Pricing](/ai-gateway/pricing ## Default configuration -Logs, which include metrics as well as request and response data are enabled by default for each gateway. If you are concerned about privacy or compliance and want to turn log collection off, you can go to settings and opt out of logs. +Logs, which include metrics as well as request and response data are enabled by default for each gateway. If you are concerned about privacy or compliance and want to turn log collection off, you can go to settings and opt out of logs or set logging behavior on a per-request basis. @@ -36,9 +36,9 @@ To override the default logging behavior set in the settings tab, you can define ## Collect logs (cf-aig-collect-log) -The `cf-aig-collect-log` header allows you to bypass the default log setting for the gateway. If the gateway is configured to save logs, the header will exclude the user prompt and model response data for that specific request. Conversely, if logging is disabled at the gateway level, this header will save the user prompt and model response data for that request. +The `cf-aig-collect-log` header allows you to bypass the default log setting for the gateway. If the gateway is configured to save logs, the header will exclude the log for that specific request. Conversely, if logging is disabled at the gateway level, this header will save the log for that request. -In this example, the gateway is configured to save logs, however we do not want this specific request to save the user prompt and model response. +In this example, the gateway is configured to save logs, however we do not want this specific request saved. ```bash curl https://gateway.ai.cloudflare.com/v1/{account_id}/{gateway_id}/openai/chat/completions \ From 3e74fb7b7ec71a094308f0c5fcc31434e431acf0 Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Mon, 23 Sep 2024 18:16:51 +0100 Subject: [PATCH 06/15] Renamed page to analytics --- src/content/docs/ai-gateway/observability/analytics.mdx | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/content/docs/ai-gateway/observability/analytics.mdx b/src/content/docs/ai-gateway/observability/analytics.mdx index d82ced8070c4ef..abb7853615f25c 100644 --- a/src/content/docs/ai-gateway/observability/analytics.mdx +++ b/src/content/docs/ai-gateway/observability/analytics.mdx @@ -1,5 +1,5 @@ --- -title: Analytics and logging +title: Analytics pcx_content_type: reference --- @@ -47,7 +47,3 @@ curl https://api.cloudflare.com/client/v4/graphql \ The cost metric is an estimation based on the number of tokens sent and received in requests. While this metric can help you monitor and predict cost trends, refer to your provider’s dashboard for the most accurate cost details. ::: - -## Logging - -Your AI Gateway dashboard also shows real-time logs of individual requests, such as the prompt, response, provider, timestamps, and whether the request was successful, cached, or if there was an error. These logs now persist and can store up to 10,000 logs per gateway for better observability and analysis. From b75c638192c98269249db036bdb1744b9cec0543 Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Tue, 24 Sep 2024 13:07:46 +0100 Subject: [PATCH 07/15] Ordering costs --- src/content/docs/ai-gateway/observability/costs.mdx | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/content/docs/ai-gateway/observability/costs.mdx b/src/content/docs/ai-gateway/observability/costs.mdx index 65399970f1b569..a6e43fd2bc3444 100644 --- a/src/content/docs/ai-gateway/observability/costs.mdx +++ b/src/content/docs/ai-gateway/observability/costs.mdx @@ -1,9 +1,10 @@ --- title: Costs pcx_content_type: reference +sidebar: + order: 2 --- - ## Supported Providers AI Gateway currently supports cost metrics from the following providers: @@ -28,7 +29,6 @@ The cost metric is an **estimation** based on the number of tokens sent and rece :::caution[Caution] - Providers may introduce new models or change their pricing. If you notice outdated cost data or are using a model not yet supported by our cost tracking, please [submit a request](https://forms.gle/8kRa73wRnvq7bxL48) ::: @@ -37,6 +37,3 @@ Providers may introduce new models or change their pricing. If you notice outdat AI Gateway allows users to set custom costs when operating under special pricing agreements or negotiated rates. Custom costs can be applied at the request level, and when applied, they will override the default or public model costs. For more information on configuration of custom costs, please visit the [Custom Costs](/ai-gateway/configuration/custom-costs/) configuration page. - - - From 5b8b21e56f1f0efacaae3c949188941c111b1d63 Mon Sep 17 00:00:00 2001 From: Kathy <153706637+kathayl@users.noreply.github.com> Date: Tue, 24 Sep 2024 18:48:58 +0100 Subject: [PATCH 08/15] Update logging.mdx --- src/content/docs/ai-gateway/observability/logging.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/content/docs/ai-gateway/observability/logging.mdx b/src/content/docs/ai-gateway/observability/logging.mdx index fe6e189734cfa6..e42dfbb56a3c1c 100644 --- a/src/content/docs/ai-gateway/observability/logging.mdx +++ b/src/content/docs/ai-gateway/observability/logging.mdx @@ -26,7 +26,7 @@ This logging behavior will be uniformly applied to all requests in the gateway. :::note[Note] -If you turn off logging and are using Logpush, this will prevent the response and request body from being forwarded through Logpush. +To export logs using Logpush, you must have logs turned on for the gateway or have overridden the gateway settings by using the `cf-aig-collect-log` request header. ::: From c63cba80373dbdb795e742a46b4290eb5857c33b Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Wed, 25 Sep 2024 13:56:57 +0100 Subject: [PATCH 09/15] Added logging folder --- .../observability/{logging.mdx => logging/index.mdx} | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) rename src/content/docs/ai-gateway/observability/{logging.mdx => logging/index.mdx} (91%) diff --git a/src/content/docs/ai-gateway/observability/logging.mdx b/src/content/docs/ai-gateway/observability/logging/index.mdx similarity index 91% rename from src/content/docs/ai-gateway/observability/logging.mdx rename to src/content/docs/ai-gateway/observability/logging/index.mdx index e42dfbb56a3c1c..27fb1e01b23ac6 100644 --- a/src/content/docs/ai-gateway/observability/logging.mdx +++ b/src/content/docs/ai-gateway/observability/logging/index.mdx @@ -18,7 +18,7 @@ To learn more about your plan limits, refer to the [Pricing](/ai-gateway/pricing ## Default configuration -Logs, which include metrics as well as request and response data are enabled by default for each gateway. If you are concerned about privacy or compliance and want to turn log collection off, you can go to settings and opt out of logs or set logging behavior on a per-request basis. +Logs, which include metrics as well as request and response data are enabled by default for each gateway. If you are concerned about privacy or compliance and want to turn log collection off, you can go to settings and opt out of logs or set logging behavior on a per-request basis. @@ -26,7 +26,7 @@ This logging behavior will be uniformly applied to all requests in the gateway. :::note[Note] -To export logs using Logpush, you must have logs turned on for the gateway or have overridden the gateway settings by using the `cf-aig-collect-log` request header. +To export logs using [Logpush](/ai-gateway/observability/logging/logpush), you must have logs turned on for the gateway or have overridden the gateway settings by using the `cf-aig-collect-log` request header. ::: From a2d888437c200421dab2af81ee3d7e9545459a01 Mon Sep 17 00:00:00 2001 From: Kathy <153706637+kathayl@users.noreply.github.com> Date: Thu, 26 Sep 2024 10:56:14 +0100 Subject: [PATCH 10/15] Update index.mdx --- .../docs/ai-gateway/observability/logging/index.mdx | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/content/docs/ai-gateway/observability/logging/index.mdx b/src/content/docs/ai-gateway/observability/logging/index.mdx index 27fb1e01b23ac6..a64897c98411e6 100644 --- a/src/content/docs/ai-gateway/observability/logging/index.mdx +++ b/src/content/docs/ai-gateway/observability/logging/index.mdx @@ -8,25 +8,23 @@ sidebar: import { Render } from "~/components"; -Logging is a fundamental building block for application development. Logging provides insights during the early stages of development and is often critical to understanding issues occurring in production. +Logging is a fundamental building block for application development. Logs provide insights during the early stages of development and are often critical to understanding issues occurring in production. -Your AI Gateway dashboard shows logs of individual requests, including the user prompt, model response, provider, timestamp, request status, token usage, cost, and duration. These logs persist, giving you the flexibility to store them for your preferred duration and do more with valuable request data. You can store up to 10 million logs per gateway. +Your AI Gateway dashboard shows logs of individual requests, including the user prompt, model response, provider, timestamp, request status, token usage, cost, and duration. These logs persist, giving you the flexibility to store them for your preferred duration and do more with valuable request data. -When you are nearing your plan limit, an alert will be displayed in the dashboard. If your limit is reached, new logs will stop being saved. To continue saving logs, you must delete older logs to free up space for new logs. +You can store up to 10 million logs per gateway. If your limit is reached, new logs will stop being saved. To continue saving logs, you must delete older logs to free up space for new logs. To learn more about your plan limits, refer to the [Pricing](/ai-gateway/pricing/) page. ## Default configuration -Logs, which include metrics as well as request and response data are enabled by default for each gateway. If you are concerned about privacy or compliance and want to turn log collection off, you can go to settings and opt out of logs or set logging behavior on a per-request basis. +Logs, which include metrics as well as request and response data, are enabled by default for each gateway. This logging behavior will be uniformly applied to all requests in the gateway. If you are concerned about privacy or compliance and want to turn log collection off, you can go to settings and opt out of logs. If you need to modify the log settings for specific requests, you can override this setting on a per-request basis. -This logging behavior will be uniformly applied to all requests in the gateway. If you need to modify the logging settings for specific requests, you can override this setting on a per-request basis. - :::note[Note] -To export logs using [Logpush](/ai-gateway/observability/logging/logpush), you must have logs turned on for the gateway or have overridden the gateway settings by using the `cf-aig-collect-log` request header. +To export logs using [Logpush](/ai-gateway/observability/logging/logpush), you must have logs turned on for the gateway. ::: From 627fca2de7dc714fa3ed3825299ef601048c5c56 Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Thu, 26 Sep 2024 11:11:05 +0100 Subject: [PATCH 11/15] Removed costs note --- src/content/docs/ai-gateway/observability/analytics.mdx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/content/docs/ai-gateway/observability/analytics.mdx b/src/content/docs/ai-gateway/observability/analytics.mdx index abb7853615f25c..886ad5b904ba78 100644 --- a/src/content/docs/ai-gateway/observability/analytics.mdx +++ b/src/content/docs/ai-gateway/observability/analytics.mdx @@ -42,8 +42,3 @@ curl https://api.cloudflare.com/client/v4/graphql \ ``` - -:::note[Note] - -The cost metric is an estimation based on the number of tokens sent and received in requests. While this metric can help you monitor and predict cost trends, refer to your provider’s dashboard for the most accurate cost details. -::: From 1bc4b49230509e951ed321030f0d5abbdaad3aef Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Thu, 26 Sep 2024 12:38:40 +0100 Subject: [PATCH 12/15] Update src/content/docs/ai-gateway/observability/logging/index.mdx Co-authored-by: Jun Lee --- src/content/docs/ai-gateway/observability/logging/index.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/content/docs/ai-gateway/observability/logging/index.mdx b/src/content/docs/ai-gateway/observability/logging/index.mdx index a64897c98411e6..567171bc4c83ef 100644 --- a/src/content/docs/ai-gateway/observability/logging/index.mdx +++ b/src/content/docs/ai-gateway/observability/logging/index.mdx @@ -14,7 +14,7 @@ Your AI Gateway dashboard shows logs of individual requests, including the user You can store up to 10 million logs per gateway. If your limit is reached, new logs will stop being saved. To continue saving logs, you must delete older logs to free up space for new logs. -To learn more about your plan limits, refer to the [Pricing](/ai-gateway/pricing/) page. +To learn more about your plan limits, refer to [Pricing](/ai-gateway/pricing/). ## Default configuration From 4ae98b3bff4ef751f8a7ea78aa7eb0798c83f0d7 Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Thu, 26 Sep 2024 12:38:52 +0100 Subject: [PATCH 13/15] Update src/content/docs/ai-gateway/observability/logging/index.mdx Co-authored-by: Jun Lee --- src/content/docs/ai-gateway/observability/logging/index.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/content/docs/ai-gateway/observability/logging/index.mdx b/src/content/docs/ai-gateway/observability/logging/index.mdx index 567171bc4c83ef..706478224e3e4d 100644 --- a/src/content/docs/ai-gateway/observability/logging/index.mdx +++ b/src/content/docs/ai-gateway/observability/logging/index.mdx @@ -22,7 +22,7 @@ Logs, which include metrics as well as request and response data, are enabled by -:::note[Note] +:::note To export logs using [Logpush](/ai-gateway/observability/logging/logpush), you must have logs turned on for the gateway. From 259c7cbe0bebfabb67ca400206c1f2bcf82c289c Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Thu, 26 Sep 2024 12:39:03 +0100 Subject: [PATCH 14/15] Update src/content/docs/ai-gateway/observability/logging/index.mdx Co-authored-by: Jun Lee --- src/content/docs/ai-gateway/observability/logging/index.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/content/docs/ai-gateway/observability/logging/index.mdx b/src/content/docs/ai-gateway/observability/logging/index.mdx index 706478224e3e4d..4ee86e164659b5 100644 --- a/src/content/docs/ai-gateway/observability/logging/index.mdx +++ b/src/content/docs/ai-gateway/observability/logging/index.mdx @@ -32,7 +32,7 @@ To export logs using [Logpush](/ai-gateway/observability/logging/logpush), you m To override the default logging behavior set in the settings tab, you can define headers on a per-request basis. -## Collect logs (cf-aig-collect-log) +## Collect logs (`cf-aig-collect-log`) The `cf-aig-collect-log` header allows you to bypass the default log setting for the gateway. If the gateway is configured to save logs, the header will exclude the log for that specific request. Conversely, if logging is disabled at the gateway level, this header will save the log for that request. From 73ebee3a3761b187e12a8d12b692ddecd558113d Mon Sep 17 00:00:00 2001 From: daisyfaithauma Date: Thu, 26 Sep 2024 12:39:18 +0100 Subject: [PATCH 15/15] Update src/content/docs/ai-gateway/observability/logging/index.mdx Co-authored-by: Jun Lee --- src/content/docs/ai-gateway/observability/logging/index.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/content/docs/ai-gateway/observability/logging/index.mdx b/src/content/docs/ai-gateway/observability/logging/index.mdx index 4ee86e164659b5..f19ecedf58d2c3 100644 --- a/src/content/docs/ai-gateway/observability/logging/index.mdx +++ b/src/content/docs/ai-gateway/observability/logging/index.mdx @@ -36,7 +36,7 @@ To override the default logging behavior set in the settings tab, you can define The `cf-aig-collect-log` header allows you to bypass the default log setting for the gateway. If the gateway is configured to save logs, the header will exclude the log for that specific request. Conversely, if logging is disabled at the gateway level, this header will save the log for that request. -In this example, the gateway is configured to save logs, however we do not want this specific request saved. +In the example below, we use `cf-aig-collect-log` to bypass the default setting to avoid saving the log. ```bash curl https://gateway.ai.cloudflare.com/v1/{account_id}/{gateway_id}/openai/chat/completions \