Http get

Hi, trying to set up a rule with a http GET to call webcore piston with following URL http://Hubitat_IP/apps/api/8/execute/:12eefec6c80a4d3b419376b9195af609:?access_token=b99e86-c2d9-414e-bdd6-461ffcf422d9&actionType=setComfort

Using the the same URL in Edge, Chrome works as charm but not from RM 5.1, I have tried to put actionType, access_token and piston into variables and changed the url to

http://Hubitat_IP/apps/api/8/execute/%piston%?access_token=%access_token%&actionType=%actionType% and this does not work eighter.

Can any1 please give me some advice here.

If you set a string variable to http://Hubitat_IP/apps/api/8/execute/%piston%?access_token=%access_token%&actionType=%actionType% does it look exactly the same as http://hubitat_ip/apps/api/8/execute/:12eefec6c80a4d3b419376b9195af609:?access_token=b99e86-c2d9-414e-bdd6-461ffcf422d9&actionType=setComfort, i.e. no extra spaces or missing characters.

Thanks, yes it looks the same to me

Send GET to: http://Hubitat_IP/apps/api/8/execute/%piston%?access_token=%access_token%&actionType=%actionType%(http://Hubitat_IP/apps/api/8/execute/:12eefec6c80a4d3b419376b9195af609:?access_token=b99e86-c2d9-414e-bdd6-461ffcf422d9&actionType=setComfort)

If you turn on logging for the rule do you see any errors?

I have enabled events, triggers and actions but no errors only action : with the same url executed.

Everytime a do a reguest from Edge, Chrome I can see the execution on the piston under Location Events, But running the action from RM they never turns up under Location Events.

Can you post the rule that you’re using?

Try using port 8080, i.e. Http://hub_ip:8080./…


Thank you so much @thebearmay , I don't understand why but the port did the trick..Why port 8080 if you have the time to explain to in short.

tried the url with port 80 and 8080 with Edge and Chrome both works, but only 8080 from RM, weird.

When you are running from the browser you are using a different connection point for the send and receive, i.e. browser port 80 and hub port 80, when you send from the hub to itself you need to provide a secondary receive for the send.


Ahh, thank you so much also tried to running the http get without variables and that to works as charm. It was the only tiny thing as the "port" I would never figured out that one.


i have found similar in that if you send to a http address but the site is https, the request gets relayed to the https address but double-requests the request, ie
gets relayed to but as which confuses the receiving script.
guess it depends on how the server reactes and redirects http requests to https

I have not tried with https though, have you tried to put 123 into variable ? so the request looks like

yes, like this:

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.