Issue description below (edited and shortened for clarity).
This automation and script work perfectly, here is an example of one of the automations (that calls the generic script):
Here is the script it calls (which is generic as it is called from many different automations, including ifttt (allowing me to remove alot of redundant logic)):
Which works perfectly for every single one of the many automations that use it, which I have for many motion sensors and various different timers and different smart outlets!) - so now I also need to now call the script from ifttt directly for those same sensors for an increase in reliability for motion detection as mentioned above. However I am getting error messages from within the execution of the script when it is called from ifttt, due to the contents of the body of the ifttt applett parameters which cannot be understood or read by HA)… Here is the ifttt applet which needs some kind of syntax change (for the same situation shown in the two pictures above):
Note the code in the body of the applett. The applett is correctly called by the motion sensor and fires off the home assistant script (not automation) as expected, but there is a problem within the ifttt body in that the data values (parameters) cannot be interpreted within the script, starting with the template for the condition (representing an input_select drop-down on the UI for the automation being enabled or disabled, with two values, ‘Enabled’ and ‘Disabled’, where it checks to make sure ‘Enabled’ is the selected option). The other two templated values are the timer itself and a value representing the duration of the timer (as you may have guessed). Here is a log of the related errors encountered within the script when called from the above ifttt applet:
I have tried putting curly braces around the template variables (the three parameters mentioned above) in the ifttt applet body that are on the left side of each colon (in the ifttt app on my Android phone), but in the ifttt app the stuff between the curly braces suddenly gets highlighted as some weird block of text I cannot edit and won’t let me save the applett because it says the “ingredient” is not recognized. Do those three parameters need to be defined somewhere in the ifttt applet as variables (ingredients) - or would that be going down the wrong rabbit hole? Unless it is just a problem where the editing of the applet must be done on a desktop in a browser as is the case when building custom applets -
I am sure I am very close finally to getting the correct logic to be fired off for a motion notification from within ifttt to HA, but don’t know what to try next as far as fixing the syntax… thoughts?