Trigger an Alarm Clock rule based on a time variable

I’m attempting to recreate a webcore Alarm Clock piston, but am seeing that I can’t trigger the rule based on a variable.

The way mine works (interested in other solutions), is that the alarm time for each room is set into a variable which is automatically set each day based on weekday or weekend (weekend is later time and kids’ alarms aren’t set to turn on weekend days) and can be modified each day via SMS from IFTTT which sets the variable. If the day is a holiday (or observed holiday), then the alarm doesn’t fire. There is also a virtual switch that can be turned off for each room as well.

Any other thoughts on how to trigger the alarm clock rule based on a certain time which can be modified?

Thanks!

Perhaps better classified as a feature request to trigger a rule based on a time variable?

Yeah, I think the dynamic time trigger would require a feature request.

If there’s a predefined set of potential times that the alarms might trigger, you could accomplish it today. For example, if it could potentially trigger at one of 7:00 am, 7:15 am, 8:00 am, 9:00 am depending on certain conditions, you could accomplish that within a rule.

One approach would be to set all of the potential time triggers as triggers, then in the flow you would add conditions determining which of the time triggers you wanted to be ‘true’ (eg. based on variables or device switches or what not) and use time comparisons to determine which of the triggers triggered the rule.

It would be a bit verbose, but I wanted to least share since it’s a a potential approach that could work today. :slight_smile:

Ok, certainly appreciate the feedback on potential options which can be used right now – need to get them moved over.

This does wind up being very clunky since we can’t trigger based on a time value. I’ve still got to build them out for each :15 minute interval, but here’s a screenshot that should work.

I’ll wind up with four rules total:

  1. one that triggers the alarm (1x/room)
  2. one that runs the alarm rules (1x/room)
  3. one that sets the alarms back to default values each day and turns on/off the alarm’s switch (accounts for weekday/weekend)
  4. and one that will allow an incoming webhook from IFTTT to set each room’s value for the day (can also use the dashboard)

Changing the default value will require using the dashboard.