mirror of
https://github.com/ferdzo/iotDashboard.git
synced 2026-04-05 17:16:26 +00:00
Added Comfort Index widget, updated stylings on other widgets, GPT Service with problems.
This commit is contained in:
@@ -58,6 +58,23 @@ export const devicesApi = {
|
||||
apiClient.get<{ device_id: string; device_name: string; metrics: string[] }>(
|
||||
`/devices/${id}/metrics/`
|
||||
),
|
||||
|
||||
getComfortIndex: (id: string) =>
|
||||
apiClient.get<{
|
||||
device_id: string;
|
||||
device_name: string;
|
||||
overall_score: number;
|
||||
rating: string;
|
||||
components: {
|
||||
temperature: number;
|
||||
humidity: number;
|
||||
air_quality: number;
|
||||
acoustic: number;
|
||||
light: number;
|
||||
};
|
||||
suggestions: string[];
|
||||
raw_readings: Record<string, number>;
|
||||
}>(`/devices/${id}/comfort_index/`),
|
||||
};
|
||||
|
||||
// Telemetry API
|
||||
|
||||
Reference in New Issue
Block a user