Skip to content

Commit 38b029c

Browse files
details on how to manually delet logs (#19166)
1 parent 5b2d418 commit 38b029c

File tree

1 file changed

+9
-3
lines changed
  • src/content/docs/ai-gateway/observability/logging

1 file changed

+9
-3
lines changed

src/content/docs/ai-gateway/observability/logging/index.mdx

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ You can store up to 10 million logs per gateway. If your limit is reached, new l
1616

1717
To learn more about your plan limits, refer to [Limits](/ai-gateway/reference/limits/).
1818

19-
We recommend using an authenticated gateway when storing logs to prevent unauthorized access and protecs against invalid requests that can inflate log storage usage and make it harder to find the data you need. Learn more about setting up an [authenticated gateway](/ai-gateway/configuration/authentication/).
19+
We recommend using an authenticated gateway when storing logs to prevent unauthorized access and protects against invalid requests that can inflate log storage usage and make it harder to find the data you need. Learn more about setting up an [authenticated gateway](/ai-gateway/configuration/authentication/).
2020

2121
## Default configuration
2222

@@ -28,7 +28,7 @@ Logs, which include metrics as well as request and response data, are enabled by
2828

2929
To override the default logging behavior set in the settings tab, you can define headers on a per-request basis.
3030

31-
## Collect logs (`cf-aig-collect-log`)
31+
### Collect logs (`cf-aig-collect-log`)
3232

3333
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.
3434

@@ -51,8 +51,14 @@ curl https://gateway.ai.cloudflare.com/v1/{account_id}/{gateway_id}/openai/chat/
5151
'
5252
```
5353
54-
## Auto Log Cleanup
54+
## How to delete logs
55+
56+
### Auto Log Cleanup
5557
5658
Enable Auto Log Cleanup to automatically delete the oldest logs once the default storage limit of 10 million logs is reached, ensuring that new logs are always saved without needing manual deletion. Logs are deleted in chunks of 0.1% of the storage limit, which equates to 10,000 logs at a time.
5759
5860
This setting is useful for maintaining continuous logging while staying within the default storage constraints.
61+
62+
### Manual deletion
63+
64+
To manually delete logs, navigate to the Logs tab in the dashboard. Use the available filters such as status, cache, provider, cost, or any other options in the dropdown to refine the logs you wish to delete. Once filtered, select Delete logs to complete the action.

0 commit comments

Comments
 (0)