Z-Wave - Change doorlock's user code.

Discussions about Z-Way software and Z-Wave technology in general
Post Reply
neitrosha
Posts: 2
Joined: 10 May 2018 23:09

Z-Wave - Change doorlock's user code.

Post by neitrosha »

Hello.
I have a server with OpenVPN and my raspberry pi (v 2.something) is an OpenVPN client. This works perfectly.
I have a doorlock where I can set passwords.

My goal is to set passwords from any place any time using simple AJAX calls with jQuery. Here's the problem.

We have ZAutomation API and JS/Run API.
With ZAutomation I can log in using ZAutomation/api/v1/login and then I can open and close my doorlock using /ZAutomation/api/v1/devices/[deviceId]/command/open
But I can't seem to figure out how to change a password using ZAutomation.

I can change the password using this command /JS/Run/zway.devices[5].UserCode.Set(12,'7777',1), but for this purpose I have to be logged in through the browser for that command to work. I tried many different ways with basic authorization, allowing anonymous access and even creating anonymous user and granting him all of the rights but to no avail.

Could somebody tell me what else I can do? Because with both of these solutions there's something prevents me from finishing my project.

Thanks.
Post Reply