Toggling network interfaces for ASUS routers via HTTP endpoint

I was looking for a way to segment some IoT devices from my main network and disable their network connections on demand programmatically. The Guest Network feature on the router does a good job of segmenting the network, so I wanted a way to turn the guest network’s interface off and on based upon conditions.

Example scenario: You have cloud-based IoT cameras and want to cease all traffic when you’re home.

This puts toggling any interface on the router behind an HTTP endpoint. Since an interface is created when a guest network is enabled, we can now enable and disable that network whenever we want.

https://github.com/twstokes/guest_toggle