Parsing space permissions using ScriptRunner

Vamsi Kandala
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
January 12, 2023

Hi,

I am using ScriptRunner Listeners to send me email notification whenever any space admin removes any permissions to any of the users in their space.

I used 'event.permissions' to capture what was removed and for which user.  It is returning back something like this:

[[SETPAGEPERMISSIONS,0,null,XYZ123,null]]

Where 'SETPAGEPERMISSIONS' is the permission type and 'XYZ123' is the user whose permissions were removed.

Is there a way to parse this into two separate variables to capture the permission type and user affected?  It looks like an array and I tried different combinations.

Thanks,
Vamsi

1 answer

0 votes
Ram Kumar Aravindakshan _Adaptavist_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 27, 2023

Hi @Vamsi Kandala

Just to check, have you managed to solve this question?

If not, could you please share the code you currently use? I am requesting this so I can review it and try to provide a better solution.

Thank you and Kind regards,
Ram

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
TAGS
AUG Leaders

Atlassian Community Events