Supereg / homebridge-http-switch

Powerful http switch for Homebridge: https://github.com/homebridge/homebridge
ISC License
222 stars 37 forks source link

Support custom HTTP method on `statusUrl` #111

Open jesse-c opened 2 years ago

jesse-c commented 2 years ago

Is your feature request related to a problem? Please describe. Unable to get accurate status for services that don't use GET to return the status. The service I'm interacting with (a Toshiba TV), requires POST.

Describe the solution you'd like Use the method value, if present, for statusUrl like onUrl and offUrl.

Additional context I saw in the code that there's a comment around this expectation and it not being available due to backwards compatibility. Is this still a blocker?

My workaround would be building my own simple service that would effectively be a proxy to do a POST request for statusUrl. 😬

Thank you for making this Homebridge plugin in the first place!