15 lines
257 B
TypeScript
15 lines
257 B
TypeScript
|
|
import api from './index'
|
||
|
|
|
||
|
|
export interface SystemStatus {
|
||
|
|
cpu_percent: number
|
||
|
|
memory_percent: number
|
||
|
|
disk_percent: number
|
||
|
|
timestamp: string
|
||
|
|
}
|
||
|
|
|
||
|
|
export const systemApi = {
|
||
|
|
getStatus() {
|
||
|
|
return api.get<SystemStatus>('/api/system/status')
|
||
|
|
},
|
||
|
|
}
|