You don’t read carefully what I wrote!
OP doesn’t want to turn on/off, off/on these lights.
From what I understand, he just wants to turn them off at a random minute between 23:00-23:45 and he doesn’t want them to turn on again. Therefore, the “Presence Simulation” function here is not useful because it will turn the lights on again.
What the OP wants to achieve will be done exactly by “sequematic.com”, control of turning off the light at a random time using the time interval 23:00 - 23:45. Optionally, it is possible to define the day of the week. Exactly what OP wants!
You can create a separate scene to turn them on again.
The sequence itself on the “sequematic.com” website can be done in two ways. By using a webhook for an ewelink scene that turns off the lights or by pairing an ewelink account and directly selecting the device.
And whether such a small period of time is ok or not is a decision for the OP and his needs. If he needs such a period of time, he clearly has such a need.
Go and check how “Presence Simulation” works… The state of your first device does not matter for this function to work. If it is set, it will try to execute regardless of everything else. Works relative to device does not take into account scenes and other devices and their status.
And the lights must be on until 23:00 and then turned off at a random time between 23:00-23:45.
Go and test your solution based on these two devices and see what happens.
It does not matter whether the lights are turned on or off by the first sequence. “Presence Simulation” will turn them on or off many times depending on the state. This does not in any way solve the situation the OP is talking about. Otherwise he would already be using “Presence Simulation”!
If the OP wants to have control on a daily basis, it matters, despite your assessment. However, you want to forcefully introduce an operating pattern that the OP does not want, i.e. turn it off and on using “Presence Simulation”!
The “If” function in ewelink scenes currently does not have the ability to execute at a random time within a defined time interval.
There is a “Time of Day” option and you can set the date, time and number of executions, but there is no random time option.
And what will “sequematic.com” give him in the form of this function but expanded with a random time.
On the ewelink side, you can basically do nothing if you pair your account. And if for some reason this is not the preferred option, we create a scene in ewelink and set the webhook as the trigger, and our device and its status to off as the action.
Simple and fast!