It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Confluence page restrictions scriptrunner


I created a confluence space for a empolyee blog. Every employee shall be able to write a blog post, but only the author and a moderator group should be able to edit these posts.

This doesn't seem possible without scriptrunner.
So I think a custom event listener for the "BlogPostCreateEvent" would be the right way to trigger a script, that will set the restrictions to these values:
- view everyone
- edit author user
- edit moderator group

Do you think this is the right way?
Is there an example for setting page restrictions through scriptrunner?
There is a built-in script to set page restrictions, but I can't see the source code of it.


Thank you

1 answer


I believe that if you want to use a listener to do this you'll need to take a look at the ContentPermissionManager and PagePermissionManager classes in order to set the permissions. I don't believe there's an example, but if you have trouble getting something to work feel free to post your code up here and I'll give you some pointers. :)

Jenna Davis

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted in Confluence

Lessons and Learnings: Six Months of Working Remote [Discussion]

Hey there, folks! For most of us, the past six months- yes, you read that right- have been a journey. More people than ever before have pivoted to working remotely, and navigating being on-scre...

4,118 views 4 6
Join discussion

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you