Hello all,
I would like to write a binding for Kohler OnCue Plus, which is a cloud-based monitoring system for standby backup generators. I have been able to reverse-engineer the protocol to communicate with their servers. So I studied the Eclipse documentation and installed the IDE however my java skills are novice level at best and I unfortunately cannot devote the necessary time to understanding the many layers of abstraction needed to get it working, let alone “doing it right.” If I had a good template I could copy from I think I could get it going. I think this would be a good binding to have because it would allow owners to determine when they are on utility power or generator power without any additional hardware (Zwave current sensors etc.) and offer more direct access to generator status than the Kohler app which IMO is clunky to use.
The protocol is straightforward:
Step 1: Get session key if none is available.
https://api.kohler.com/krm/v1/users/connect?username=YOUR_USERNAME&password=YOUR_PASSWORD&dateformat=m-d%20g:i%20A
This returns some json elements, one of which is a session key. Use the session key to get current status of the generator.
Step 2: Get generator status using session key
https://api.kohler.com/krm/v1/devices/listdevices?sessionkey=SESSIONKEY_FROM_STEP_ONE¶meters=[4,11,60,69,102,91,114,115,549]&events=active&showperipheraldetails=true
This returns more json with all the data. Step 2 can be repeated at a predetermined intervals. The Kohler app allows you to specify as often as every 5 seconds so near-real-time updates are ok. If the session key is invalid, step 1 is executed to get a new one.
If any skilled binding writers can offer some guidance I would be extremely grateful.
Thanks,
Russell
PatPend