mirror of
https://github.com/Myzel394/kleckrelay-website.git
synced 2025-06-19 07:55:25 +02:00
feat: Add get cron report
This commit is contained in:
parent
6f870f7302
commit
3b130d054f
13
src/apis/get-latest-cron-report.ts
Normal file
13
src/apis/get-latest-cron-report.ts
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
import {CronReport} from "~/server-types"
|
||||||
|
import {client} from "~/constants/axios-client"
|
||||||
|
|
||||||
|
export default async function getLatestCronReport(): Promise<CronReport> {
|
||||||
|
const {data} = await client.get(
|
||||||
|
`${import.meta.env.VITE_SERVER_BASE_URL}/v1/cron-report/latest/`,
|
||||||
|
{
|
||||||
|
withCredentials: true,
|
||||||
|
},
|
||||||
|
)
|
||||||
|
|
||||||
|
return data
|
||||||
|
}
|
@ -56,3 +56,5 @@ export * from "./delete-alias"
|
|||||||
export {default as deleteAlias} from "./delete-alias"
|
export {default as deleteAlias} from "./delete-alias"
|
||||||
export * from "./delete-reserved-alias"
|
export * from "./delete-reserved-alias"
|
||||||
export {default as deleteReservedAlias} from "./delete-reserved-alias"
|
export {default as deleteReservedAlias} from "./delete-reserved-alias"
|
||||||
|
export * from "./get-latest-cron-report"
|
||||||
|
export {default as getLatestCronReport} from "./get-latest-cron-report"
|
||||||
|
@ -213,3 +213,11 @@ export interface AdminSettings {
|
|||||||
allowStatistics: boolean | null
|
allowStatistics: boolean | null
|
||||||
allowAliasDeletion: boolean | null
|
allowAliasDeletion: boolean | null
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export interface CronReport {
|
||||||
|
id: string
|
||||||
|
createdAt: Date
|
||||||
|
reportData: {
|
||||||
|
encryptedReport: string
|
||||||
|
}
|
||||||
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user