chatGPT部分完成
This commit is contained in:
@@ -55,7 +55,7 @@ export class ChatGPT extends BaseModel {
|
||||
if (endDate) {
|
||||
const startDate = new Date(endDate - 90 * 24 * 60 * 60);
|
||||
const formattedDate = time => dayjs(time).format("YYYY-MM-DD")
|
||||
return axios.get(`${ChatGPT.base}/v1/dashboard/billing/usage?start_date=${formattedDate(startDate * 1000)}&end_date=${formattedDate(endDate * 1000)}`,
|
||||
return await axios.get(`${ChatGPT.base}/v1/dashboard/billing/usage?start_date=${formattedDate(startDate * 1000)}&end_date=${formattedDate(endDate * 1000)}`,
|
||||
{headers}).then(res => res.json()).then(res => {
|
||||
usages.total_usage = res.total_usage
|
||||
const names = usages.account_name.split(" ")
|
||||
|
||||
Reference in New Issue
Block a user