Creating a piston to control device from Virtual device from another hub


#1

Just wondering if someone has got a virtual switch to control an actual switch from a different location. I have 2 homes and 2 hubs of course. Let’s just say I wanted a virtual switch from one hub to turn on lights or an appliance from the other hub - How would I go about this?

I’ve already have 2 instances on WeBCore, and a Virtual Switch created one of my hubs. Just wondering what the next step would be.

Any help would be appreciated.
Thanks,
Tom.


#2

webCoRE can trigger any piston (even on other hubs) by making a GET request directly to that piston.

Basically, create the “turn on lights” piston in the house with the lights, but do NOT use any triggers in the code. You want to see this at the top:


Then you copy the URL found here:
temp

and send that long URL to your OTHER house to use in a new piston there.
(be careful to not share that URL)

The house away from the bulbs can then make a GET request to that long web URL to trigger that piston and those lights…

There is a great example here: https://community.webcore.co/t/6685


#3

Awesome! let me try that.