aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared
diff options
context:
space:
mode:
Diffstat (limited to 'shared')
-rw-r--r--shared/extra-utils/logs/logs.ts15
-rw-r--r--shared/models/server/log-level.type.ts2
2 files changed, 15 insertions, 2 deletions
diff --git a/shared/extra-utils/logs/logs.ts b/shared/extra-utils/logs/logs.ts
index cbb1afb93..c494c1f1e 100644
--- a/shared/extra-utils/logs/logs.ts
+++ b/shared/extra-utils/logs/logs.ts
@@ -13,6 +13,19 @@ function getLogs (url: string, accessToken: string, startDate: Date, endDate?: D
13 }) 13 })
14} 14}
15 15
16function getAuditLogs (url: string, accessToken: string, startDate: Date, endDate?: Date) {
17 const path = '/api/v1/server/audit-logs'
18
19 return makeGetRequest({
20 url,
21 path,
22 token: accessToken,
23 query: { startDate, endDate },
24 statusCodeExpected: 200
25 })
26}
27
16export { 28export {
17 getLogs 29 getLogs,
30 getAuditLogs
18} 31}
diff --git a/shared/models/server/log-level.type.ts b/shared/models/server/log-level.type.ts
index ce91559e3..4afb92d11 100644
--- a/shared/models/server/log-level.type.ts
+++ b/shared/models/server/log-level.type.ts
@@ -1 +1 @@
export type LogLevel = 'debug' | 'info' | 'warn' | 'error' export type LogLevel = 'debug' | 'info' | 'warn' | 'error' | 'audit'