I managed to connect my Foobot air quality sensor to Homeassistant using rest, but now im blocked trying to decode the JSON to show the actual data (temperature, humidity and so on). I tried to take a look at the templates but I cant seem to get it to work…
The processing of incoming data is described in the “Processing incoming data” section.
You will only be able to get one value per sensor. According your data it’s a nested list which requires a little bit more, e.g, for the temperature {{ value_json.datapoints[0][2] }}
that did the trick, thanks! However, now im faced with a new issue…the Foobot API limits the number of queries to 200 per day, which by default is reached in a couple hours in homeassistant, can i edit this frequency somehow?
In the configuration variables of the RESTful component, you can specify the poll interval in seconds (scan_interval). So for Foobot, which is limited to 200 queries per day, you should specifiy something higher than (24x60x60)/200 = 432 seconds, for instance:
scan_interval: 450
I’ve updated it a bit in order to get multiple values with single REST call. This requires additional platform named jsonrest. Here is the config I’ve used for that:
I made a component for foobot, it’s working so far but I have some cleaning up to do before making a PR for integration into HA mainline. Mostly related to the python package for the API and documentation, not the component itself.
In the meantime, if anyone here want to test it, it would be appreciated to get some feedback before publishing it.
I am a newb to Hass and installed it on Ubuntu. I am trying to get Foobot working and added the device and token to my config but it doesn’t appear to be doing anything and I am not seeing anything in my logs either. I have a few devices working but not the foobot. Looking at the API, it is also not seeing any call from Hass. I verified that I have 0.66 and the foobot.py is present in the python folder. I am running python 3.6. Not sure what I am missing… The username is the email address correct?