Airquality binding failing with "missing data sub-object" error

I think I found a problem with the Airquality binding not storing the correct value in the API key field.

Every hour, when the binding refresh the AQI it will stop with the following error in the openhab log:

[WARN ] [airquality.handler.AirQualityHandler] - Error in aqicn.org (Air Quality) response: missing data sub-object

Looking at the Paper UI item properties I can see that the value stored in the API token key is wrong (too short) and the item will still fail and go offline when trying to edit and enter the correct key. I counted the number of characters and found that it match the one for the API key of the weatherunderground binding.

As a quick and temporary fix, deleting and re-creating the item in Paper UI will return the item to online status for a while, so does reloading the model if you created it with a THING file.

Time to file an issue on Github…

I found it was already reported there. I added my findings to the discussion.