johnnyt Posted May 11, 2022 Posted May 11, 2022 Starting new thread on this as the old one is closed for some reason and I don't know how to re-open or get it reopened. Looks like Airthings now offers API's for consumer products https://help.airthings.com/en/articles/4510990-integrations-airthings-api Now I have to see if/how I get this to work with ISY.
MrBill Posted May 11, 2022 Posted May 11, 2022 1 hour ago, johnnyt said: Starting new thread on this as the old one is closed for some reason and I don't know how to re-open or get it reopened. Old threads are now closed on purpose. While that one is not too bad, the point is most of the information in threads over 1.5 years old is out of date. It's best to start new discussions, referencing old when appropriate. 1 hour ago, johnnyt said: Now I have to see if/how I get this to work with ISY. Are you a programmer/developer wanting to be pointed to the developers group and developer documentation, --or-- are you hinting that you hope someone will soon create a node server?
johnnyt Posted May 12, 2022 Author Posted May 12, 2022 3 hours ago, MrBill said: Are you a programmer/developer wanting to be pointed to the developers group and developer documentation, --or-- are you hinting that you hope someone will soon create a node server? I had a look after work at what's needed and understood about 20%, so it's a stretch but I'll see if I can conquer it when I have more time. They show you how to do it with Postman / Insomnia so that's where I'll look first. In another related post JimboAutomates said he would look into a Node server. If that happens before I figure things out (assuming I can) I'll for sure look into it.
Jimbo.Automates Posted May 13, 2022 Posted May 13, 2022 Yes, I'll work on a node server if possible in a couple weeks after vacation.Sent from my Pixel 6 Pro using Tapatalk
johnnyt Posted June 29, 2022 Author Posted June 29, 2022 On 5/12/2022 at 11:51 PM, JimboAutomates said: Yes, I'll work on a node server if possible in a couple weeks after vacation. Sent from my Pixel 6 Pro using Tapatalk Hi @JimboAutomates. Just wondering if this is still something you're planning to do?
Jimbo.Automates Posted June 29, 2022 Posted June 29, 2022 Yes, I started working in it, but UD Mobile Push Notifications support in Notification node server took priority. Hope get back to it this weekend. 1
Jimbo.Automates Posted July 4, 2022 Posted July 4, 2022 @macjeff and @johnnyt, The initial version is released to production see https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/blob/main/README.md https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/blob/main/CONFIG.md Only minimal testing has been done and already found one issue https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/issues Not sure I'll have time to work on it the rest of the weekend so thought I would release it for you guys to give it a try. Let me know your thoughts on this thread.
macjeff Posted July 4, 2022 Posted July 4, 2022 my Polisy just went totally down. Posted a topic but also sent Jimbo a PM. I need to make a decision. Start from scratch (with backups) or wait and have it down. I cant SSH, HTTP, HTTPS, no admin console. But I can ping it LOL
Jimbo.Automates Posted July 4, 2022 Posted July 4, 2022 Lot's more issues https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/issues Most importantly is #4 because I forgot to add token refreshing, so when the token times out the node server stops updating.
Jimbo.Automates Posted July 5, 2022 Posted July 5, 2022 Airthings node server 0.0.2 released, all known issues should be resolved.
Jimbo.Automates Posted July 5, 2022 Posted July 5, 2022 Airthings node server 0.0.4 released, discover was broken in previous release.
Jimbo.Automates Posted July 5, 2022 Posted July 5, 2022 Airthings node server 0.0.5 released. Fixed https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/issues/5 1
Jimbo.Automates Posted July 6, 2022 Posted July 6, 2022 Airthings node server 0.0.6 released. Fixed https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/issues/6
macjeff Posted July 6, 2022 Posted July 6, 2022 Got my Polisy back up and running thanks to Michel. So there is a feature ONLY in the non plus versions (and the new firmware) that has a MOLD field in the app. It alerts you if MOLD conditions are favorable. Can you add that? Again its NOT in the Wave Plus which is upsetting. Also I am going to get a View Plus eventually. Does it support it? Jeff
Jimbo.Automates Posted July 6, 2022 Posted July 6, 2022 Put yours in debug mode, do a query on a sensor and PM me the Log Package so I can confirm what the mold looks like. Their docs say it's a number, but I have no idea what that number means. I've asked their support, but that will probably take a while to resolve. Also, there is a reason it's not included on the others: https://help.airthings.com/en/articles/4418460-mold-do-the-wave-wave-plus-or-view-plus-have-mold-risk-indicators As mentioned in the doc, it should support any sensor they release, but only for the current values being stored.
Jimbo.Automates Posted July 7, 2022 Posted July 7, 2022 I've added some issues, please add if you find others: https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/issues I'm not going to make an official release until these are resolved, especially #7 since that could affect existing program references.
macjeff Posted July 17, 2022 Posted July 17, 2022 I had written a program to tell me when any of my units show RADON over a certain percent. Tonight it warned me. I checked the real logs at airthings and it was not even close to bad levels. I checked the ISY and all of my units had nothing in the connected (the Node server said connected but not the individual nodes for the devices). I looked at logs and showed lots of errors. Restarted and now stuff is fine but got my logs before I did. Sorry but I was only in ERROR mode. Switched to debug for future. Airthings-C_7-16-2022_110235_PM.zip
Jimbo.Automates Posted July 17, 2022 Posted July 17, 2022 Thanks, I'll take a look when I'm home at the end of the week.Sent from my Pixel 6 Pro using Tapatalk
johnnyt Posted July 17, 2022 Author Posted July 17, 2022 Hi, I had asked before (but think post may have gotten lost in forum crash) if an API call needed to be made 'per device' or if it returned data from all devices linked to my account. I have 7 wave plus devices and am getting repeated messages about API rate limit being exceeded (so I think I know the answer). Is there a way to get more info per call, or, if I need to ask Airthings for a higher rate limit, what number do I need to ask them for? I had short poll / long pol set to 120/240 but bumped them up to 240/480 for now. Here's a short excerpt from log, repeated every short poll until waiting period is over. 2022-07-17 11:30:09,349 Thread-2046 udi_interface INFO Controller:shortPoll: enter 2022-07-17 11:30:09,350 Thread-2046 udi_interface INFO Controller:_query_all: enter 2022-07-17 11:30:09,351 Thread-2046 udi_interface DEBUG Controller:authorize: enter 2022-07-17 11:30:09,351 Thread-2046 udi_interface DEBUG Controller:authorize: Token Expires: 2022-07-17 13:18:09.802246 currently: 2022-07-17 11:30:09.351733 2022-07-17 11:30:09,352 Thread-2046 udi_interface DEBUG Controller:authorize: exit 2022-07-17 11:30:09,353 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,353 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,354 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,354 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,355 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,356 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,356 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,357 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,357 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,358 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,359 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,359 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,360 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,360 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,361 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,362 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,362 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,363 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,364 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,364 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,365 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,365 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,366 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,367 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,367 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,368 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,369 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,369 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,370 Thread-2046 udi_interface INFO Controller:_query_all: exit 2022-07-17 11:30:09,370 Thread-2046 udi_interface INFO Controller:shortPoll: exit
johnnyt Posted July 17, 2022 Author Posted July 17, 2022 Oops. it was a separately post, and not part of this one. Also had question about the time value
Jimbo.Automates Posted July 21, 2022 Posted July 21, 2022 On 7/17/2022 at 8:46 AM, johnnyt said: Hi, I had asked before (but think post may have gotten lost in forum crash) if an API call needed to be made 'per device' or if it returned data from all devices linked to my account. I have 7 wave plus devices and am getting repeated messages about API rate limit being exceeded (so I think I know the answer). Is there a way to get more info per call, or, if I need to ask Airthings for a higher rate limit, what number do I need to ask them for? I had short poll / long pol set to 120/240 but bumped them up to 240/480 for now. Here's a short excerpt from log, repeated every short poll until waiting period is over. 2022-07-17 11:30:09,349 Thread-2046 udi_interface INFO Controller:shortPoll: enter 2022-07-17 11:30:09,350 Thread-2046 udi_interface INFO Controller:_query_all: enter 2022-07-17 11:30:09,351 Thread-2046 udi_interface DEBUG Controller:authorize: enter 2022-07-17 11:30:09,351 Thread-2046 udi_interface DEBUG Controller:authorize: Token Expires: 2022-07-17 13:18:09.802246 currently: 2022-07-17 11:30:09.351733 2022-07-17 11:30:09,352 Thread-2046 udi_interface DEBUG Controller:authorize: exit 2022-07-17 11:30:09,353 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,353 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,354 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,354 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,355 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,356 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,356 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,357 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,357 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,358 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,359 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,359 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,360 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,360 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,361 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,362 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,362 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,363 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,364 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,364 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,365 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,365 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,366 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,367 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,367 Thread-2046 udi_interface INFO Sensor:shortPoll: enter 2022-07-17 11:30:09,368 Thread-2046 udi_interface INFO Sensor:query: enter 2022-07-17 11:30:09,369 Thread-2046 udi_interface WARNING Controller:api_get: API Rate limit exceeded, waiting until 2022-07-17 11:31:10.032853 query the Airthings service. 2022-07-17 11:30:09,369 Thread-2046 udi_interface INFO Sensor:shortPoll: exit 2022-07-17 11:30:09,370 Thread-2046 udi_interface INFO Controller:_query_all: exit 2022-07-17 11:30:09,370 Thread-2046 udi_interface INFO Controller:shortPoll: exit Issue added: https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/issues/13
Jimbo.Automates Posted July 21, 2022 Posted July 21, 2022 On 7/16/2022 at 8:11 PM, macjeff said: I had written a program to tell me when any of my units show RADON over a certain percent. Tonight it warned me. I checked the real logs at airthings and it was not even close to bad levels. I checked the ISY and all of my units had nothing in the connected (the Node server said connected but not the individual nodes for the devices). I looked at logs and showed lots of errors. Restarted and now stuff is fine but got my logs before I did. Sorry but I was only in ERROR mode. Switched to debug for future. Airthings-C_7-16-2022_110235_PM.zip 7.83 MB · 1 download Looks like the rate limit issue as well: 2022-07-16 00:03:04,512 Thread-16889 udi_interface ERROR pgSession:response: Unknown response 429: https://ext-api.airthings.com/v1//devices/2930024519/latest-samples {"error":"TOO_MANY_REQUESTS","error_description":"Rate limit on API exceeded","error_code":1070} Added info to issue: https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/issues/13 1
Jimbo.Automates Posted July 23, 2022 Posted July 23, 2022 Issue updated: https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/issues/13 Also updated config doc: https://github.com/UniversalDevicesInc-PG3/udi-poly-Airthings-Consumer/blob/main/CONFIG.md
johnnyt Posted July 24, 2022 Author Posted July 24, 2022 Correct me if I'm wrong but when you say "sensor" in the issue explanation on github, I think you mean "device", right? I have 7 devices and each one has 6 sensors. Timing for short poll should be 30 X 7, not 30 X 42 (7x6). Is it sending data for all sensors in all devices or just the changed data since last short poll? It looks like it's only changes because I rarely see 42 messages being sent to ISY but I want to confirm in case the reason I'm not getting 42 updates every time is because there's a problem somewhere. For reference I set my short poll to 240 (4 mins). I think devices update the mothership every 5 mins, each on it's own schedule. I haven't seen any rate limit issues since I moved to 4 mins.
Jimbo.Automates Posted July 24, 2022 Posted July 24, 2022 Correct me if I'm wrong but when you say "sensor" in the issue explanation on github, I think you mean "device", right? I have 7 devices and each one has 6 sensors. Timing for short poll should be 30 X 7, not 30 X 42 (7x6). Is it sending data for all sensors in all devices or just the changed data since last short poll? It looks like it's only changes because I rarely see 42 messages being sent to ISY but I want to confirm in case the reason I'm not getting 42 updates every time is because there's a problem somewhere. For reference I set my short poll to 240 (4 mins). I think devices update the mothership every 5 mins, each on it's own schedule. I haven't seen any rate limit issues since I moved to 4 mins. Yes, it's each device, not the sensors in the device. On each poll it gets current data for all sensors in the device, but if the value is the same as previous then PG3 doesn't pass it on to the ISY.Sent from my Pixel 6 Pro using Tapatalk
Recommended Posts