[dss-developer] REST-API - Set user defined states

Christian Stüllein | SSE christian.stuellein at sse-engineering.de
Fri Mar 13 17:27:57 CET 2020


Hi. I found the problem.

The String "system−addon−user−defined−states" (copied from the
dss-json.pdf) contains "false" '−' characters. With the standard minus
'-' everything works as expected.


I wish everyone a nice weekend and stay healthy!

Mit freundlichen Grüßen
______________________________________________________________
Christian Stüllein

SSE - Stüllein Software Engineering
Friedrich-Hartung-Str. 16
64560 Riedstadt

Mobil: +49 (0)170 / 294 61 67
Tel:   +49 (0)6158 / 828 7707
Fax:   +49 (0)6158 / 828 7708

E-Mail: christian.stuellein at sse-engineering.de
Web: www.sse-engineering.de

Am 3/10/2020 um 7:38 PM schrieb Christian Stüllein | SSE:
> Hi,
>
>
> I have a question according the user defined states. As stated in the
> JSON API document it should be possible to set a user defined state (if
> that state is not linked to physical outputs or defined by other
> states). If I understand this correctly, I can only set the state
> "active" or "inactive" using this two strings as value. Is this correct?
>
>
> I tried this with the state "Kind_zuhause" within the testserver
> (https://testrack2.aizo.com:50443) but I get an error, that the given
> state is not found.
>
>
> My requests is:
> https://testrack2.aizo.com:58080/json/state/set?addon=system−addon−user−defined−states&name=1494253299&value=inactive&token=55d6d57898cc9fa127f3eeddd751c78f4fc3294f5c549d758488093ec7c02aa6
>
> The Respose is: {"ok":false,"message":"State not found name:1494253299
> model/apartment.cpp:912 httpPath:/json/state/set"}
>
>
> I wonder what's wrong. If I debug the User-Defined-States App in the
> webbrowser it seems to work. This app is sending:
>
> https://testrack2.aizo.com:50443/json/state/set?addon=system-addon-user-defined-states&name=1494253299&value=inactive&a=0.40391334838893855&
>
>
> I also tried to add the a=0.40391334838893855 part (what ever this is)
> but without success.
>
>
> I hope one of you has an idea were my error is.
>
>
> best regards, Christian
>
>
>
> _______________________________________________
> dss-developer mailing list
> dss-developer at forum.digitalstrom.org
> http://forum.digitalstrom.org/cgi-bin/mailman/listinfo/dss-developer
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://forum.digitalstrom.org/pipermail/dss-developer/attachments/20200313/ab3df3eb/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: OpenPGP digital signature
URL: <http://forum.digitalstrom.org/pipermail/dss-developer/attachments/20200313/ab3df3eb/attachment.pgp>


More information about the dss-developer mailing list