Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 21:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.

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

I have a list of inactive users in Confluence. Is there any API to delete it ?

Barkha Singh March 6, 2023

I have a list of inactive users in Confluence. Is there any API to delete it ?
I tried below api 

curl -u {username}:{password} -X POST https://{confluence_url}/rest/api/user?username={inactive_username}&method=DELETE

curl -u {username}:{password} -X DELETE https://{confluence_url}/rest/api/user?username={inactive_username}

1 answer

1 accepted

0 votes
Answer accepted
Faisal March 6, 2023

Hi Barkha,

 

Can you please tell what user Directory are you using currently for your Confluence application is it Confluence Internal directory  or Jira Directory integrated with Confluence or Any AD .

 

Because you can't delete users present in the last two as you are not owner for the user ID and if it is the first one then we can look what is the issue with the curl command 

 

Please check and confirm

Barkha Singh March 6, 2023

I am using https://confluence-dev.cox.com url . And i am getting 405 error.  "Method Not Allowed"

Faisal March 6, 2023

Can you please tell what user Directory are you using currently for your Confluence application is it Confluence Internal directory  or Jira Directory integrated with Confluence or Any AD .

Barkha Singh March 6, 2023

Confluence Internal Directory

Faisal March 6, 2023

Currently delete API is not available as per the Link for Confluence server . Can you please specify what is your source of origin for the mentioned API ?

Barkha Singh March 6, 2023

Is there any other way to delete inactive users?

Faisal March 6, 2023

Currently you can use add-on for completing the task . One of the Add-on which i can recommended is Script Runner for Confluence .

Which has script to complete the action . You can use trial version to complete your action .

You can Find many more add-on if you search . Let me check and recommend you a few .

Regards

Like Barkha Singh likes this
Pradeep Varma
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
June 14, 2023

Can you share me a script to get inactive users in Confluence for datacenter

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events