twitchdev / twitch-cli

The official Twitch CLI to make developing on Twitch easier.
Apache License 2.0
604 stars 71 forks source link

Simulate Keepalive Message Interruption [Feature Request] #291

Closed Robertsmania closed 9 months ago

Robertsmania commented 11 months ago

Tell us about your feature request

For testing client logic to handle KeepAlive Messages it would be helpful to have an option with the CLI to suspend or interrupt the outgoing messages.

I'm not certain of the causes or conditions that could cause a real server in production to stop sending the messages, but from the documentation it sounds like the connection itself is still considered open (or at least has not received an explicit close).

Ideally, the option with the CLI would stop sending the Keepalive Messages to an existing client but not prohibit establishing new connections which would receive the messages as normal. Perhaps specifying the SessionID to suspend?

Disclaimer

Xemdo commented 9 months ago

This will be implemented as such:

twitch event websocket keepalive --session=[Session ID] --enabled=[true/false]