xxx pressed. Count: 1 // Unsuccessful status code
Getting subj after much trouble with node installation. Does it support https? Example of button config:
"name": "Camera", "address": "84:D6:D0:53:7D:28", "timeout": "60000", "protocol": "udp", "url": "https://domain:8123/api/services/script", "method": "POST", "headers": {"x-ha-access": "pw"}, "json": true, "body": {"entity_id": "script.onvifer"}
Just an assumption: 8123 looks like Hass, if you have a self singed certificate you could get problems. You should see them in the logs though
It's been a while J In the meantime I found out that I can still do shell scripts with curl, proceeded that way, faced some sort of commotion with NPM and deleted it for good J
I am having a similar (perhaps the same) problem. I'm using Let's Encrypt certs; are those also going to cause problems so I can't use this?
If the Let's Encrypt certificate is valid and you are using the correct hostname there should be a problem @vadimbz You could close the issue if it's solved
Well, I'm switching to a "real" certificate now so we'll see if that helps once I get everything set up.
did anybody figure out how to get this working? i just installed a lets encrypt ssl cert and i'm getting errors saying not authenticated.. was working fine before SSL
Edit- got it working with the LE cert, i'd mistyped x-ha-access
Also! For the original question-- to run a script, the config.json entry should look like this:
"name": "Camera",
"address": "84:D6:D0:53:7D:28",
"timeout": "60000",
"protocol": "udp",
"url": "https://domain:8123/api/services/script/onvifer",
"method": "POST",
"headers": {"x-ha-access": "pw"},
No need to send anything in the body unless you are passing info to your script. I now have several buttons configured this way, using and let's encrypt SSL certificate.