Using Python to Implement the Status Bar

image
I want to know if it’s possible to write something similar to the restart Grasshopper button in the status bar using Python :point_up_2:

How about this one?

I don’t need the existing plug-in battery. My intention was to know how to implement this function using Python, with API interfaces or function methods