# HTTP action tutorials

In this document, you will find tutorials for the AsTeRICS Grid HTTP action.

# Turn on/off shelly plug

The shelly plug has a built-in wifi access point or can connect itself to a wifi access point. Furthermore, it runs a webserver and provides a REST API that can be used to turn the plug (electricity) on or off.

Shelly plug Shelly Plus Plug UK

  1. Get a shelly plus plug (see UK model (opens new window) or Shelly Plug S (opens new window)).
  2. Plug it in and enable the shelly wifi access point according to the shelly plug manual.
  3. Connect to the wifi access point of the shelly plug.
  4. Now the shally plug should be reachable through an ip address, e.g http://192.168.33.1.
  5. Turn on Editing mode
  6. Edit cell and got to Actions tab
  7. Select HTTP action
  8. Enter http://192.168.33.1/relay/0?turn=toggle command into the field HTTP URL (see Fig 1).
  9. Enter GET into the field HTTP method.
  10. Enter text/plain into the field HTTP Content-Type.
  11. Click on OK to save the action.
  12. Turn off Editing mode

image

Fig 1: HTTP action to toggle Shelly plug.

TIP

You can also use dedicated on/off commands (see Shelly 2 HTTP manual (opens new window)):

http://192.168.33.1/relay/0?turn=on
http://192.168.33.1/relay/0?turn=on