Mill-International-AS / Generation_3_REST_API

Local REST API documentation
37 stars 6 forks source link

API call for reboot should return ok, then reboot #14

Open olavt opened 1 year ago

olavt commented 1 year ago

I notice that some of the API calls like /reboot immediately starts the reboot before returning a response.

I think it would make more sense to return an OK before doing the actual reboot. Otherwise it's impossible to know if the heater was reachable or not when doing the /reboot API call.

olavt commented 1 year ago

The current behavior is quite unfortunate as every request I send to reboot the heater MCU will be flagged as a failed request.