Smart App Help, Security Exception, Endpoint is Blacklisted


(Brannon Bowden) #1

Ok, so working on a smartApp to update another home automation system I use when certain events happen, this is my first smartapp, so its been a bit trial and error, I finally get it to where it appears to work, but I get the following error.

22f16b72-7499-4d06-92dd-5252dd2a941a 11:55:37 AM: error java.lang.SecurityException: Endpoint http://mydomain.com/Serial/1/[e2b30045-a971-4ce1-bc8c-a65eb5a51ce2]=off is blacklisted. @ line 50

Just realized, there was an issue a couple days ago,with nest and something similar, but that it was fixed in the backend…Any ideas?


Endpoint null is blacklisted
(Brannon Bowden) #2

Well after browsing more examples, found a slightly modified way to do this that works.


(Andrew Mager) #3

What ended up being the solution?


(Brannon Bowden) #4

Unfortunately I appear to have lost the changes I had made for this along the line somewhere, without realizing it. I know I ended up moving the code to the device type itself, and using the VLC Media Player Device Type as an example for the logic. I was unable to get it to work as a smart app. It has been a while, and I should revisit doing this as a smartApp and see if I get the same issues.


(Brannon Bowden) #5

Actually realized I was able to get it to work in a Smart App… I am not sure what I was doing wrong the first time, but this method works. I control the API on the other end, so authentication wasn’t much of a worry for me, as I am ignoring all data that I am not explicitly looking for.

private testThis(String path) {

def pollParams = [
    uri: "http://mydomain.com",
    path: "${path}"
    ]

httpGet(pollParams)
}

def switchesHandler(evt) {
if (evt.value == "on") {
	testThis("/set/Serial/1/${evt.deviceId}=on")
} 
else if (evt.value == "off") {
	testThis("/set/Serial/1/${evt.deviceId}=off")
}
}