How can I display a list of users of a space on a confluence page?

I would like to display a list of users of a particular space on a page automatically based on the permissions of the users in that space so that the list updates automatically with the changing list of users on the permissions page?

So far I only see ways to manually add users of a space with some macros, but none of them doies this  automatically.

Klaus

 

2 answers

This widget could not be displayed.

Put page into Edit Mode

Click the <<+Insert>>

select "Other Macros"

choose the "User List" macro

configure the list for the selection of Permissions you need to display

smile

Thank you Rodney, but all I can configure is to enter Group names into the parameter "Group(s) and wether a user is online or offline.

Can you please explain how to configure the list, that it lists all members of this workspace? (So all users that are listed under "permission" of that workspace?).

Thank you.

Klaus

Hi, did you find an answer to the question?  I have the very same one :)

Thanks

Nicola

This would be helpful.

Have you read the Documentation?

When you have the macro editing pop up dialog box open, there is a link to "Documentation"

In that it says to get a list of all Users regardless of the Permissions Group enter "*" in the selection box

Otherwise type in the name of the Permissions Group(s) you want to see

That was where I started. Where is the selection box?

Screen Shot 2018-04-23 at 1.32.06 PM.pngScreen Shot 2018-04-23 at 1.32.19 PM.png

As I said in my original post, I am using the <<User List>> macro  here is the documentation link

https://confluence.atlassian.com/confcloud/user-list-macro-724765305.html

This works great for those members that we have set up in groups. However, we need to give permissions to those users who have permission to spaces. Much of the time this will work but there will be many times when it doesn't.

Thank you for the info but I think we're still looking for something that shows members of a space as opposed to a group.

Regards,

Kristin

What happens if you put "*" in the Groups field?  I think that will show you all users in all Permissions grouping but I am not sure what it would do for Users who have access as Individual Permissions (must be a nightmare to manage?) rather than by having Group Permissions

Our host created a macro that does show the Users for that specific Space but we also manage access by granting a permissions group to each user so it is possible to create something

We had more than the maximum so it wouldn't view. Which is fine, that's too unmanageable.

But it did help, so thank you. For what I need, I'll probably need to ask our dev team to develop something.

This widget could not be displayed.

I do not think this answers the original question. Listing all users having access to a specific space would be helpful, to reflect all users of that space on the space homepage or somewhere else. As only space admins can view the space permissions, this would be a great info for everybody contributing to that space. 

Ideally this should be shown with profile pics in a contemporary way, as it is standard in many collaboration tools. Any ideas for plugins or user macros? 

members.PNG

We realized a list of all space members by user macro, but it does not look really nice as it is a table listing all admins, then users of the space , then groups. Groups can be dissolved which should be standard in a proper way to display all people haveing access.  


## Macro has a body: Y or N (N)
## Body processing: Selected body processing option
## Output: Selected output option
## Macro to list all users and groups with the permission to administer the current space.
## @Param ShowUsers:title=List all users|type=boolean|desc=Show a list of all users who have access to the space|default=true
## @Param ShowGroups:title=List all groups|type=boolean|desc=Show a list of all groups who have access to the space|default=true
## @Param ListUsers:title=List all users inside a group|type=boolean|desc=Shows a list of all users inside the groups, instead of just the groups|default=false
<h1>Space Members</h1>
<p>The following users and groups have permission to access the <strong>$space.getName()</strong> Space.</p>
#if($paramShowUsers == true)
<h2>Users</h2>
<table class="confluenceTable">
<tr>
<th class="confluenceTh">Space Administrators</th>
</tr>
#foreach ($permission in $space.getPermissions())
#if ($permission.isUserPermission() && $permission.getType() == "SETSPACEPERMISSIONS")
<tr>
<td class="confluenceTd">#usernameLink($permission.getUserName())</td>
</tr>
#end
#end
</table>
<table class="confluenceTable">
<tr>
<th class="confluenceTh">Space Members</th>
</tr>
#foreach ($permission in $space.getPermissions())
#if ($permission.isUserPermission() && $permission.getType() == "VIEWSPACE")
<tr>
<td class="confluenceTd">#usernameLink($permission.getUserName())</td>
</tr>
#end
#end
</table>
#end
#if($paramShowGroups == true)
<h2>Groups</h2>
#if($paramListUsers == true)
#foreach ($permission in $space.getPermissions())
#if ($permission.isGroupPermission() && $permission.getType() == "SETSPACEPERMISSIONS")
#set ( $groupString = $permission.getGroup() )
#set ( $groupObject = $userAccessor.getGroup($groupString) )
#set ( $memberList = $userAccessor.getMemberNamesAsList($groupObject) )
<h3>$groupString</h3>
<table class="confluenceTable">
<tr>
<th class="confluenceTh">Space Administrators</th>
</tr>
#foreach ($member in $memberList)
<tr>
<td class="confluenceTd">#usernameLink($member)</td>
</tr>
#end
</table>
#end
#end
#foreach ($permission in $space.getPermissions())
#if ($permission.isGroupPermission() && $permission.getType() == "VIEWSPACE")
#set ( $groupString = $permission.getGroup() )
#set ( $groupObject = $userAccessor.getGroup($groupString) )
#set ( $memberList = $userAccessor.getMemberNamesAsList($groupObject) )
<h3>$groupString</h3>
<table class="confluenceTable">
<tr>
<th class="confluenceTh">Space Members</th>
</tr>
#foreach ($member in $memberList)
<tr>
<td class="confluenceTd">#usernameLink($member)</td>
</tr>
#end
</table>
#end
#end
#else
#foreach ($permission in $space.getPermissions())
#if ($permission.isGroupPermission() && $permission.getType() == "SETSPACEPERMISSIONS")
#set ( $groupString = $permission.getGroup() )
#set ( $groupObject = $userAccessor.getGroup($groupString) )
<li>$groupString</li>
#end
#end
#foreach ($permission in $space.getPermissions())
#if ($permission.isGroupPermission() && $permission.getType() == "VIEWSPACE")
#set ( $groupString = $permission.getGroup() )
#set ( $groupObject = $userAccessor.getGroup($groupString) )
<li>$groupString</li>
#end
#end
#end
#end

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Sep 17, 2018 in Confluence

Why start from scratch? Introducing four new templates for Confluence Cloud

Hi my Community friends!  For those who don't know me, I'm a product marketer on the Confluence Cloud team - nice to meet you! For those of you who do, you know that I've been all up in your Co...

569 views 7 6
Join discussion

Atlassian User Groups

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

Find a group

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

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you