Author Topic: http command using LUA  (Read 304 times)

Offline Lucas68

  • Newbie
  • *
  • Posts: 2
  • Karma: +0/-0
http command using LUA
« on: May 31, 2018, 12:59:28 pm »

Sorry for the noob question. I just got a Vera Edge from my fren and I'm trying to figure out how to send http command using LUA, but i just cant figure out how.

I was trying to create a "Virtual switch" that will send a http command of let say:

and put the command in LUA code of the device, but I cant find something like that.

Then I try to create lua scene, but it requires a trigger which i dont have any sensor yet at the moment, is it possible for me to create a variable of lets say xxx=1. and the scene will check if xxx=1 and run the http command if it is?

I've spent whole day trying to look for more info, but most of the explanation is quite confusing for me as I dont code, I just want to send a simple command. Thanks so much!

Offline parkerc

  • Beta Testers
  • Sr. Hero Member
  • *****
  • Posts: 2474
  • Karma: +35/-48
  • Life Moves Pretty Fast....
Re: http command using LUA
« Reply #1 on: June 04, 2018, 10:43:12 am »
It sounds like creating an app/plug-in would be quite a task if you do not have any programming experience.

If it help, if you want to call something via a url, using lua, then this is an example of code that i have that calls a second Vera to turn on a light.

The url you use could be anything with it?s own http/API - set the scene to manual and it will run on your command.

Code: [Select]
« Last Edit: June 04, 2018, 11:51:42 am by parkerc »