Is there a DB query or a CLI to get all the space contributors

Sramanth Pandeti
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.
September 14, 2020

Hello,

We are merging our confluence instances and we are also figuring out a way to merge/add users to the target instance before migrating the spaces. We have only decided to add active users to the target instance such as users who have contributed to a space, users in space permissions and users in groups. I tried to use the space contributors macro but it only displays the email address. I want to find a DB query or a CLI to fetch the space contributors of certain spaces.? 

I tried the contributors macro, but it only provided the email address. I want to get the user's username and email address information.

Thanks for your help!

1 answer

1 accepted

0 votes
Answer accepted
Avinash Bhagawati {Appfire}
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 15, 2020

Hi @Sramanth Pandeti ,

Thanks for posting your requirement here.

We are from bobswift support team and we have raised support request in our portal. Please signup to our bobswift portal from below  link and let us know so that we can add you to the support ticket.

https://bobswift.atlassian.net/servicedesk/customer/portal/1/user/signup?destination=portal%2F1%2FSUPPORT-4672

With the help of Confluence CLI (https://marketplace.atlassian.com/apps/284/confluence-command-line-interface-cli?hosting=server&tab=overview) you will be able to get the list of users who have created the pages, modified pages ,added the comment and watched the pages in space.

Please find below actions for your reference. In our below examples, EXPERIMENT refers to space key of the space

  • To get the list of page authors, please find below action.
--action getPageList --space EXPERIMENT --columns "Title,Author" --outputFormat 999 --file authors.csv

  • To get the list of page modifiers, please find below action for your reference.
--action runFromPageList --space EXPERIMENT --common "--action getPageHistoryList --id @pageId@ --columns "1,2,5,7" --file modifiers.csv --append" --continue

  • To get list of users who commented on pages in space, please find below action for your reference.
--action runFromPageList --space "EXPERIMENT" --common "--action getCommentList --id @pageId@ --columns "2,4" --file commentUsers.csv --append" --continue

  • To get all the list of watchers for space, you can use below action.
--action runFromPageList --space EXPERIMENT --common "--action getWatchList --id @pageId@ --columns "5,7,8" --file watchers.csv --append" --continue

Also to get the all the users in confluence, you can below getUserList command to get the username along with their email address.

-action getUserList --name @all --columns "1,3,4" --file userslist.csv

Please let us know if you have any additional questions, we are happy to help you !

Thanks,
Avinash

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events