Page 1 of 1

need JSON commands

Posted: 02 Feb 2016 16:35
by vvuu
Hi,
I couldn't find how to set and get some things via JSON API ZAutomation

1) a certain level of the dimmer:
http://192.168.1.10/ZAutomation/api/v1/ ... way_1-0-2/.......... ????

2) get a battery level of the sensor
http://192.168.1.10/ZAutomation/api/v1/ ... _2-0-31-1/
doesn't show battery status ;(

3) get only temperature level - not whole answer:
http://192.168.1.10/ZAutomation/api/v1/ ... _2-0-31-3/
......."metrics":{"probeTitle":"Temperature","scaleTitle":null,"level":8,2"icon":"temperature","title":"Temp"}.......

Re: need JSON commands

Posted: 08 Feb 2016 14:35
by vvuu
I found 1);
../ZAutomation/api/v1/devices/ZWayVDev_zway_2-0-30/command/exact?level=50

Still couldn't find a solution for questions 2), 3),

another question:
4) ../ZAutomation/api/v1/notifications --> could I get only events of one device or I have to parse it by external tools?

Re: need JSON commands

Posted: 09 Feb 2016 00:14
by bogr
Have you tried reading and making any sense of the superb documentation (slightly sarcastic) at
http://docs.zwayhomeautomation.apiary.io?

It says

Code: Select all

Retrieve a Notification
http://r3bfish.ddns.net:8083/ZAutomation/api/v1/notifications/id
I tried by listing all notifications and then grabbing an id like

Code: Select all

http://localhost:8083/ZAutomation/api/v1/notifications/1454367882
but it didn't work for me at least. Maybe you have better success ;). Unfortunately it doesn't seem possible to list notifications per device?

Checking the battery section for device:

Code: Select all

deviceType  Metrics                                      Commands          Examples
battery    probeTitle,scaleTitle, level, icon, title      -                 -
Doesn't say much to me, but maybe you can decrypt this. Probably you can't get the battery level without doing some additional parsing?

Re: need JSON commands

Posted: 09 Feb 2016 11:19
by pz1
bogr wrote:Have you tried reading and making any sense of the superb documentation (slightly sarcastic) at
This documentation is not up to date, and some of the described functions are not (yet?) implemented. On top of that the Apiary people decided to beautify the layout, which imho did not add to its usability :( I do prefer plain compact syntax specifications.

Re: need JSON commands

Posted: 26 Feb 2016 14:37
by vvuu

Re: need JSON commands

Posted: 26 Feb 2016 19:12
by bogr
Noooo, that's cheating - he wanted to use the ZAutomation API ;)

Re: need JSON commands

Posted: 26 Feb 2016 19:18
by remoticz
bogr wrote:Noooo, that's cheating
Not only cheating, but not fit for the future either. They have written somewhere that the JS interface is going to disappear.

Re: need JSON commands

Posted: 26 Feb 2016 19:52
by bogr
Really? That doesn't sound to good if the ZAutomation is the only alternative then?

Re: need JSON commands

Posted: 15 May 2016 06:10
by Mike Yeager
Anyone find a way to read the ZAutomation data using a timestamp to get only the changes since the last read?

Re: need JSON commands

Posted: 24 May 2016 15:49
by billyboy