✨ Improvements

The open-api spec (latest-samples and samples endpoints) has been updated removing a map which was incorrectly documented as containing doubles only. It now describes each sensor of the device with type (number/string)

Note: Sensors not existing on a device are not returned in the response. The example below illustrates all possible sensors (the result will vary depending on the sensors available in the device type):

{
  "data": {
    "battery": 0,
    "co2": 0,
    "humidity": 0,
    "light": 0,
    "mold": 0,
    "pm1": 0,
    "pm10": 0,
    "pm25": 0,
    "pressure": 0,
    "radonShortTermAvg": 0,
    "rssi": 0,
    "sla": 0,
    "temp": 0,
    "time": 0,
    "virusRisk": 0,
    "voc": 0,
    "relayDeviceType": "string"
  }
}
{
  "data": {
    "co2": [
      0
    ],
    "humidity": [
      0
    ],
    "light": [
      0
    ],
    "mold": [
      0
    ],
    "pm1": [
      0
    ],
    "pm10": [
      0
    ],
    "pm25": [
      0
    ],
    "pressure": [
      0
    ],
    "radonShortTermAvg": [
      0
    ],
    "sla": [
      0
    ],
    "temp": [
      0
    ],
    "time": [
      0
    ],
    "virusRisk": [
      0
    ],
    "voc": [
      0
    ]
  },
  "start": "2021-04-06T09:28:31.801Z",
  "end": "2021-04-06T09:28:31.801Z",
  "measurementSystem": "US",
  "cursor": "string"
}

✨ Improvements

We have received some feedback about unpaired/retired devices being returned by our endpoints.

Having old devices in the response makes it harder to know if a device in the response is active in an account or not.

To address this we added a new default to hide segments and devices due to unpaired or decommissioned devices from the following endpoints:

/devices
/segments
/locations/{locationId}

Getting old segments of unpaired devices and unpaired devices can still be done by providing the query parameter: showInactive=true

Consider the following response from the /devices endpoint, the device 2930002398 has been decommissioned,
hence its segment is active=false, it is only returned by the endpoint, when the query parameter showInactive=true is present.

{
  "devices": [
    {
      "id": "2930000351",
      "deviceType": "WAVE_PLUS",
      "sensors": [
        "radonShortTermAvg",
        "temp",
        "humidity",
        "pressure",
        "co2",
        "voc",
        "light",
        "virusRisk"
      ],
      "segment": {
        "id": "6b761d0e-c1a4-4607-b52b-2ae6e4320e29",
        "name": "Hardware Area",
        "started": "2018-11-19T16:51:51",
        "active": true
      },
      "location": {
        "id": "0a4fa775-1bed-455b-b1b1-b91d40df667b",
        "name": "Airthings HQ - Oslo"
      }
    },
    {
      "id": "2930002398",
      "deviceType": "WAVE_PLUS",
      "sensors": [
        "radonShortTermAvg",
        "temp",
        "humidity",
        "pressure",
        "co2",
        "voc",
        "light",
        "virusRisk"
      ],
      "segment": {
        "id": "d36a7733-bac9-47af-b8af-094da015e41f",
        "name": "NOx - Meeting Room",
        "started": "2018-12-06T14:46:06",
        "active": false
      },
      "location": {
        "id": "0a4fa775-1bed-455b-b1b1-b91d40df667b",
        "name": "Airthings HQ - Oslo"
      }
    }
  ]
}

✨ Improvements

Battery status (percentage), rssi (signal strength) and relay device type have been added the following
endpoints:

/devices/{serialNumber}/latest-samples
/locations/{locationId}/latest-samples

rssi is only visible for devices which are connected to a hub. relayDeviceType will be "hub" when
the device is connected to a hub and "app" when an app is used to sync data from the device.

Example response:

{
  "data": {
    "co2": 491.0,
    "humidity": 16.0,
    "light": 45,
    "pressure": 1027.8,
    "radonShortTermAvg": 39.0,
    "temp": 22.2,
    "time": 1616143854,
    "virusRisk": 7.0,
    "voc": 54.0,
    "rssi": -45,
    "battery": 83,
    "relayDeviceType": "hub"
  }
}

✨ Improvement

All three types of sample events have received a new ratings property in the data object. This property contains ratings for all sensors in a given sample, wherein the rating for a given sensor value is calculated based on our recommended thresholds. For example, if the temperature is below 18 degrees, it is given a POOR rating.

The ratings are GOOD, FAIR and POOR.

An example response:

{
  "ratings": {
    "radonShortTermAvg": "GOOD",
    "temp": "POOR",
    "pressure": "GOOD",
    "humidity": "FAIR",
    "voc": "GOOD"
  }
}

🚀 Feature Release

  • Virus risk feed is now released. Virus risk events are sent using a new type airthings-webhook-cloudevent-virus-risk-feed

  • Hub metadata feed is now released. Hub events are sent using a new type hub-meta-data-feed and can be selected
    with the other devices/locations in the Dashboard.

About once every hour, the Hub sends metadata to the Airthings cloud informing us about its current status. A few example fields are connectionType (ethernet or cellular), lastSeenDevices(devices seen by the hub within the last 15 minutes), and devices, which shows all devices paired to the hub.

An example event:

{
  "id": "cb0bb746-cdb3-42b5-8a96-db88380e5513",
  "type": "airthings-webhook-cloudevent-hub-meta-data-feed",
  "source": "https://dashboard.airthings.com/integrations/webhooks/f278e95b-26e2-4942-8374-175611b98c36",
  "dataContentType": "application/json",
  "labels": {},
  "data": {
    "serialNumber": "2820000001",
    "recorded": "2020-11-13T13:46:08",
    "lastSeenDevices": [
      "2930000001"
    ],
    "devices": {
      "2930000001": {
        "lastSeen": 1598065353,
        "rssi": -57,
        "type": "wavePlus"
      }
    },
    "connectionType": "ethernet"
  },
  "time": "2020-11-13T13:46:10.280000",
  "specVersion": "0.2"
}

✨ Improvement

  • Two new properties have been added to the data object: rssi (signal strength of the device) and batteryPercentage.

🚀 Feature Release

Two endpoints have been added for fetching full history of samples for virus risk values:

  • /devices/{serialNumber}/virus-risk-samples
  • /segments/{segmentId}/virus-risk-samples

This is considered a beta feature, and it might change in the future.

✨ Improvements

  • Virus risk sensor values has been added to /latest-samples for devices and locations.

✨ Improvements

Properties active and started have been added to the segment object to the /devices and /locations endpoints. The active field is used to distinguish between devices that are currently paired to an account and devices that have been unpaired and removed from the account, but still have historical measurements.

The segment object now has the following structure:

{
  "id": "91f7fc45-8006-4279-9b0a-fa8b812020fa",
  "name": "My device name",
  "started": "2020-08-07T06:53:04",
  "active": true
}

🚀 Feature Release

Two endpoints have been added for fetching full history of samples for mold values:

  • /devices/{serialNumber}/mold-samples
  • /segments/{segmentId}/mold-samples

This is considered a beta feature, and it might change in the future.

🚀 Feature Release

The webhooks will now receive an event when a new mold risk indicator value is calculated. The event type will be airthings-webhook-cloudevent-virtual-sample-feed for these samples.