improved
API - Product name added to responses
May 4th, 2023
✨ Improvements
We changed the name of all our Airthings for Business devices a while ago, but we didn't replace the value of deviceType
in responses from the API, to avoid breaking any existing integrations.
To keep supporting integrations that depends on the value of deviceType
, we've added productName
to any responses where deviceType
is present, where the value will contain the current official name of the device.
Example response from get device endpoint:
GET /devices/{serialNumber}
{
"id": "2930000000",
"deviceType": "WAVE_PLUS",
"productName": "Space Plus",
"sensors": [
"radonShortTermAvg",
"temp",
"humidity",
"pressure",
"co2",
"voc",
"light",
"virusRisk"
],
"segment": {
"id": "00000000-0000-0000-0000-0000000000",
"name": "Device Name",
"started": "2019-12-11T14:31:33",
"active": true
},
"location": {
"id": "00000000-0000-0000-0000-0000000000",
"name": "Location Name"
}
}