Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root


1 badge earned


Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!


Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.


Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!


Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

How to add user properties in Confluence?

Hi there

I am new with Confluence ScriptRunner, and I'm a bit lost. I have to create a screen, when a user connects to Confluence, where he has to accept the Conditions of use. 

I want to save the agreement as a user property, so I can later check who agreed and who didn't.

I couldn't find anything in Confluence about adding new properties/settings to the user.

Is there a way ? Did anybody do that ?

Thank you for your attention !


1 answer

So if some people are still interessted, the best solution is to use Bandana, that work with a context (could be global, a space key or a specific context for the properties you manage), a key (for me a string with the context name + user key + property version) and the value you want to store.

See Persistence in Confluence ( and What is Bandana? One form of Confluence persistence (


Simple code: 

import com.atlassian.bandana.BandanaManager
import com.atlassian.bandana.BandanaContext
import com.atlassian.confluence.setup.bandana.ConfluenceBandanaContext

String myContext = "<your context name>"
String myKey = "<your key>"
def myValue ="This could be text or a structure, an object ..."

ConfluenceBandanaContext ctx = new ConfluenceBandanaContext(myContext)
def bandanaManager = ComponentLocator.getomponent(BandanaManager)

// Store the value
bandanaManager.setValue(ctx, myKey, myValue);

//Retrieve the value
def myNewValue = bandanaManager.getValue(ctx, myKey) 
Ok, now I'm fighting because I created a class to structure my data.
When I store data in bandana (setValue), it works (data are in the DB), but I can't retrieve them anymore (with getValue).
I have a warning when I store the data:
Non-serializable type groovy.util.myClass is not compatible with remote Bandana cache

but the data are anyway in the DB !

I don't get it ...

Suggest an answer

Log in or Sign up to answer

Atlassian Community Events