AutoMation01 wrote:Greetings all ---
Can the three values in this plugin be used to pass indigo variables?
I am looking to pass Netatmo - (wind / gust / temp) values that are already stored as indigo variables to apilio logic blocks? I have a IFTTT web hook setup that invokes my ifttt to apilio recipe and can pass static values to it, would now like to pass the indigo vars instead of the static values?
Is there a format to do this in the three values field in this plugin? Or is there an easier / better way to do this as a script?
Any advise / assistance is appreciated.
OK ... so this seems to work as a script:
****
#!/usr/bin/env python3.7
import requests
myVar_gust = (indigo.variables[1727362904].getValue(float))
myVar_wind = (indigo.variables[23371740].getValue(float))
myVar_temp = (indigo.variables[131355202].getValue(float))
key_val = "my key here"
the_url = "https://maker.ifttt.com/trigger/netatmo/with/key/" + key_val + "?&value1=" + str(myVar_gust) + "&value2=" + str(myVar_wind) + "&value3=" + str(myVar_temp)
indigo.server.log(str(requests.get(the_url)), type=" ====> : ")
****
I would be interested to know if there is an easier way to simply pass the indigo variables through the plugin three values with some type of special formatting or something?
Thanks ....