what is wrong? username and password

Moderator: leecollings

Post Reply
tiga
Posts: 159
Joined: Friday 27 May 2016 20:15
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: nederland
Contact:

what is wrong? username and password

Post by tiga »

what am i doing wrong?
i have a lua script running on my raspberry with this line in it:

commandArray['OpenURL']='192.168.0.123:8080/json.htm?type=command&param=updateuservariable&vname=deltaT&vtype=1&vvalue='..tostring(delta)

that works perfect, in my settings: i dont need to use a username and password when connected to my local network.
but i want to change this so i have to implement my username and password in this line.

so this is what i did:

commandArray['OpenURL']='http://USERNAME:[email protected] ... ing(delta)

i succesfully use this command with the username and password in "tasker" on my Phone but in lua it does not work.

or can it be done more easely?

this allso does not work :(

commandArray['OpenURL']='USERNAME:[email protected]:8080/json.htm?type=command&param=updateuservariable&vname=deltaT&vtype=1&vvalue='..tostring(delta)
zicht
Posts: 272
Joined: Sunday 11 May 2014 11:09
Target OS: Windows
Domoticz version: 2023.1+
Location: NL
Contact:

Re: what is wrong? username and password

Post by zicht »

The format is wrong...
it should be like :

Code: Select all

https://IP:Port/json.htm?username=yourname==&password=yourpassword&type=command&param=updateuservariable&vname=IETS&vtype=2&vvalue=AnDERS
Be aware you have to encode your username and password in base64
https://www.domoticz.com/wiki/Domoticz_ ... horization


Hope this helps
Rpi & Win x64. Using : cam's,RFXCom, LaCrosse, RFY, HuE, google, standard Lua, Tasker, Waze traveltime, NLAlert&grip2+,curtains, vacuum, audioreceiver, smart-heating&cooling + many more (= automate all repetitive simple tasks)
tiga
Posts: 159
Joined: Friday 27 May 2016 20:15
Target OS: Raspberry Pi / ODroid
Domoticz version:
Location: nederland
Contact:

Re: what is wrong? username and password

Post by tiga »

Ok thank you very much.i give IT a try!!
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest