It should be possible to set interval value as variable. Blockly in ioBroker has a dedicated block for that purpose.  (same for timers please)