Random delay function request in Apilio

Bruno \ 15x16

Apr 26

I came from Stringify which allowed me to do this scenario:

I wonder if you could implement a random delay by using an apilio numeric variable.
What I am trying to achieve is to trigger an applet in ifttt at a random delay to switch on a lamp, then another trigger at another random delay to call another ifttt applet to switch off that lamp in such a way the house will feel occupied when I am away.

I gonna try to sketch my needs to make it easier to understand:

ifttt:
when sunset trigger a logicblock in Apilio

apilio:

if home is empty:

  • call ifttt applet to switch on lamp after a 30 seconds delay. [at this point I would like the delay to be a random value or perhaps to let me use a variable defined in apilio]

     - call ifttt applet to switch off lamp after a 3600 seconds delay. [at this point I would like the delay to be a random value or perhaps to let me use a variable defined in apilio]
    

Is there a way to make the delay as a variable which could be a random numeric value?

||Philipp|

Apr 28

Hi there!

That’s a great idea for a product improvement - I’d like to have it myself :slight_smile:

But currently I see no way how to achieve this with the features available. Making the use of variables possible for delays might be the easiest way to build it quickly, but then you’d still a service to change a numeric variable to a random number.

Cheers

Philipp

||Bruno|

May 2

It would be fab if we could call:

https://www.random.org/integers/?num=1&min=30&max=60&col=1&base=10&format=plain&rnd=new

This then would populate the apilio variable somehow.

or perhaps I could call that from IFTTT then call Apilio to set the variable. I need to figure out the best way to do it.

||Philipp|

May 6

Thanks for mentioning that idea!

2 Likes

I’d also like this feature - and even maybe a random time option (random time between x and y) for events to be run. That would make apilio even more powerful as a hub for home automation, especially for lighting where you want to e.g. be able to make a house look occupied when you are away on holiday.

2 Likes

I personally like the idea to allow a numeric variable be used as the delay.
And then on the configuration of the numeric variable have the option to configure a random value with a range.
But many users would probably prefer to configure the value right there in the logicblock configuration :smile:

:+1: as well for the random event. Wouldn’t it be most useful if one could define a random offset related to sunset / sunrise (e.g. at sunset with some randomness, start a logicblock)

1 Like

This was released recently, see below :smiley: You can now set a random delay to your actions in Apilio. With this release, you’ll be able to specify a delay that falls between min/max minutes you can specify, for example: a random delay that lasts 3 minutes minimum and 15 minutes maximum.

@AndrewM let us know if you give it a go :wink:

1 Like