Get users and groups from icingaweb2

Hello,
I’m working on some automation for the Icinga2 and have a question.
I’m using LDAP authentication to the icingaweb2 interface, it works pretty well, but I want to get the information about users and groups from the icingaweb interface and their permissions if it’s possible because due to member/group permissions I want to permit access to automation or deny


I’m talking about this configuration page in icingaweb2.
Thank you for any information.