How to remove my application's appindicator programmatically?

I know how to add an appindicator menu from my application, but I can't seem to find how to remove it but still keep my program running in the background. Is there a way to do this?


Solution 1:

Found out that you can hide an indicator by calling

indicator.set_status(appindicator.STATUS_PASSIVE)

Which was all I needed.