How to make an action from UIX under different user (for example "M-Files server")


I would like to create some little script that runs by user (for example from context menu of object) and makes some actions that user have no rights for. I can not make it straight because all actions from UIX are executing under this user's rights. But may be there is some way to do it for example via "M-Files Server" user (as it happens when event handler executing)?

I could for example create a simple Vault App and call its function from UIX but may be there is an easier way?

Thank you!