Files
MSE-PI-E2EEDA-Plein-de-eeee…/db/get-db.http
Klagarge 53fbc87af6 feat(db): add co2-status endpoint in REST API
This endpoint get the co2 status and return for each room if the co2 is too high or in the acceptable level

Assisted-by: Junie:gemini-3-flash
Signed-off-by: Klagarge <remi@heredero.ch>
2026-06-04 14:46:36 +02:00

31 lines
929 B
HTTP

@host = https://api.db.e.kb28.ch
@room-id = B3
@username = PIE2EEDA
@password =
### GET last value of temp, co2, humidity, windows states
GET {{host}}/api/v1/rooms/{{room-id}}/current
Authorization: Basic {{username}} {{password}}
### GET history of a room
@window = 1 day
GET {{host}}/api/v1/rooms/{{room-id}}/history?window={{window}}
Authorization: Basic {{username}} {{password}}
### GET CO2 status of all rooms
GET {{host}}/api/v1/rooms/co2-status
Authorization: Basic {{username}} {{password}}
### GET all rooms
GET {{host}}/api/v1/rooms
Authorization: Basic {{username}} {{password}}
### GET battery status of all devices
GET {{host}}/api/v1/battery
### Export sensor data as CSV for a node over a time range
@node = C2:64:0F:68:35:3E
@from = 2026-05-27T14:00:00+02:00
@to = 2026-05-27T18:00:00+02:00
GET {{host}}/api/v1/export/csv?node={{node}}&from={{from}}&to={{to}}
Authorization: Basic {{username}} {{password}}