feat: refresh max token

This commit is contained in:
archer
2023-07-14 10:05:29 +08:00
parent f3715731c4
commit 358c4716f9
7 changed files with 83 additions and 27 deletions

View File

@@ -45,8 +45,8 @@ export const triggerModelCollection = (appId: string) =>
POST<number>(`/app/share/collection?appId=${appId}`);
// ====================== data
export const getTokenUsage = (data: { appId: string }) =>
POST<{ tokenLen: number; date: Date }[]>(`/app/data/tokenUsage`, {
export const getAppTotalUsage = (data: { appId: string }) =>
POST<{ total: number; date: Date }[]>(`/app/data/totalUsage`, {
...data,
start: addDays(new Date(), -7),
end: new Date()