It sounds like the integration might be using a restful command to control the switches and the API can only receive one command at a time. I had the same issue when setting up controls for my Yamaha amplifier. However in that case a 1 second delay between successive commands was no issue.
Would this type of command work with a gate motor switch as well?
I have an electronic gate virtual switch directly under the live feed of my front gate for opening and closing while viewing who’s at the gate. However, I have had a scenario, where someone in the household presses the button (Probably unintentionally) during the night, which is a problem as there is a manual lock on the gate which gets locked after everyone is home. The issue is that when the button is pressed and the gate is locked, it causes major problems in the morning unlocking the lock, because the gate has shifted open slightly, and the lock cant be accessed, or should I say, can get accessed but almost impossible.
Also would this snippet go into “Automations” or some other part of HA, as I have only just recently set it up, and thus far, I only have the gate on it, and the cameras (So, very new to all of this).
The Virtual switch is just called “ewelink_virtual_switch” (Haven’t dipped my toes into the proverbial water too deep yet to put the ESPHome firmware on it yet)