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

Looking rest api for confluence to remove users from groups

Bala May 20, 2016

I am looking rest api for confluence to remove users from confluence-users group..I am finding any kind of api's related to that..Even in Atlassian docs I haven't seen for removing users from confluence-users group..Please help me out

1 answer

0 votes
Damien Braz May 20, 2016

Hi Bala,

If you're using a Confluence 5.4 and less:

Look here for some help withApi for confluence: https://developer.atlassian.com/confdev/confluence-rest-api/confluence-xml-rpc-and-soap-apis/remote-confluence-methods#RemoteConfluenceMethods-UserManagement

  • boolean removeUserFromGroup(String token, String username, String groupname) - remove a user from a group.

With the new Rest API, use:

Recommended REST resourceREST method
removeUserFromGroup(java.lang.String token, RemoteGroup group, RemoteUser ruser) /rest/api/2/group/userDELETE
Bala May 20, 2016

Hi Damien,

 Thanks for your help

FYI, I  need to use these rest api for python script to remove userfromgroup..Moreover I am using version Confluence v5.8.18. The first one you suggested is soap-apis,  the only alternative I found now is soap apis because  I am finding any rest api to use for my python script

removeUserFromGroup(java.lang.String token, RemoteGroup group, RemoteUser ruser) This rest api is good to use in python script??

Bala May 22, 2016

@Damien Braz

Could you please help..Is that correct to use?

Bala May 22, 2016

@Damien Braz

The REST api you are stated is jira REST Api, Is a jira REST api will work for a confluence installation? Because REST api docs for jira and confluence are different.

 

Jira REST API:

https://docs.atlassian.com/jira/REST/latest/

 

Conflunce REST Api:

https://docs.atlassian.com/confluence/REST/latest/

Damien Braz May 22, 2016

Hi Bala, 

 

At the moment, Confluence API is only deprecated. You can still use the methods. The problem is Confluence will not be updated. Confluence Rest is not currently totally complete for Confluence. 

So, in my opinion, you should keed SOAP methods for the moments, waiting for Confluence adding methods you need. 

You can use: https://developer.atlassian.com/docs/developer-tools/using-the-rest-api-browser It will helpt you to discover the Rest Confluence Api smile

 

Damien.

Suggest an answer

Log in or Sign up to answer
This widget could not be displayed.
This widget could not be displayed.
Community showcase
Published in Confluence

6 Awesome Ways to Apply Trello, JIRA and Confluence to your Project

I attended  Atlassian Summit 2019  and learned a lot from the presenters, attendees and knowledgeable Atlassian product managers. The presentations I attended focused on applying Agile, pla...

2,442 views 11 28
Read article

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