Git commit prior to merge
This commit is contained in:
@@ -2250,6 +2250,7 @@ Filter by action (exact match) and/or a date range (inclusive).
|
||||
|
||||
* @summary List audit log entries (admin)
|
||||
*/
|
||||
export const listAuditLogsQueryForcedOnlyDefault = false;
|
||||
export const listAuditLogsQueryLimitDefault = 50;
|
||||
export const listAuditLogsQueryLimitMax = 200;
|
||||
|
||||
@@ -2261,6 +2262,12 @@ export const ListAuditLogsQueryParams = zod.object({
|
||||
.string()
|
||||
.optional()
|
||||
.describe('Exact action name to filter by (e.g. \"group.force_delete\").'),
|
||||
forcedOnly: zod.coerce
|
||||
.boolean()
|
||||
.default(listAuditLogsQueryForcedOnlyDefault)
|
||||
.describe(
|
||||
"When true, restrict results to forced deletions only — i.e. rows\nwith action `group.force_delete`, `user.force_delete`,\n`app.force_delete`, `service.force_delete`, or any\n`group.delete`\/`user.delete`\/`app.delete` row whose metadata\ncontains `force: true`. Overrides the `action` filter when set.\n",
|
||||
),
|
||||
from: zod
|
||||
.date()
|
||||
.optional()
|
||||
@@ -2311,17 +2318,26 @@ export const ListAuditLogsResponse = zod.object({
|
||||
|
||||
/**
|
||||
* Streams the filtered audit log as a CSV download.
|
||||
Honors the same `action`, `from`, and `to` filters as the list endpoint.
|
||||
Honors the same `action`, `forcedOnly`, `from`, and `to` filters as the
|
||||
list endpoint.
|
||||
Columns: action, actor_username, target_type, target_id, created_at, metadata.
|
||||
Capped at 50,000 rows per export to bound response size.
|
||||
|
||||
* @summary Export filtered audit log as CSV (admin)
|
||||
*/
|
||||
export const exportAuditLogsCsvQueryForcedOnlyDefault = false;
|
||||
|
||||
export const ExportAuditLogsCsvQueryParams = zod.object({
|
||||
action: zod.coerce
|
||||
.string()
|
||||
.optional()
|
||||
.describe('Exact action name to filter by (e.g. \"group.force_delete\").'),
|
||||
forcedOnly: zod.coerce
|
||||
.boolean()
|
||||
.default(exportAuditLogsCsvQueryForcedOnlyDefault)
|
||||
.describe(
|
||||
"When true, restrict the export to forced deletions only.\nSee the list endpoint for the exact set of matching rows.\nOverrides the `action` filter when set.\n",
|
||||
),
|
||||
from: zod
|
||||
.date()
|
||||
.optional()
|
||||
|
||||
Reference in New Issue
Block a user