Informational state types


I have a home automation system (Home Assistant) that can read the operational state of Octoprint. This will allow me to control a power switch with will turn off the printer after printing or an error, etc....

My question is, does anyone know what all the condition states octoprint reports. So far I have "Printing" and "Operational" and "Unknown". thx.


Here's the documentation.

And this is the code, jump down to line 660 through 691.


Excellent, that was exactly what I was looking for.

Would , you happen to know what state will be reported in case of a thermal runway?? Im assuming "Error" but I hate to assume. thx!


Never mind, I forced a thermal run away, the octoprint status is "Offline".


Are you getting thermal runaways normally?


No, just thought it would be a great idea to have Home Assistant monitor the printer and turn it off after a print or error. I've figured out how to turn the printer off after printing, but not so much after the printer goes offline. When the printer goes "Offline", Home Assistant shows "Unknown ". Home Assistant also shows "Unknown" sometimes during normal printing, so I can't trigger on that...

It would be great if Octoprint had a built in mqtt client that could send out messages.


Not sure if you could tweak the MGTT Publish one to fulfill your needs.


Looks promising, THX!