Trigger Ansel Screenshot

Dear Community,

Is there a way to take a Ansel Screenshot without opening Ansel UI?
The Ansel Function Library only provides functions for camera movement, the UI itself, etc.
In other words: Can I trigger the function which is called when pressing the “take screenshot”-button in my code?

Thank you!
Lorenz