I had the same problem! Wasn’t me but the kids refusing to talk to Alexa.
I took a different approach that didn’t cost me a smart plug. I used an app called Host Pinger. Since I have a Pi 3 that is always on, whenever the XB1 is on/off, the Host Pinger app would report that in ST via a Virtual Switch. I then use that switch to do the same as you did above.