You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
Next: Root
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
The Atlassian Community can help you and your team get more value out of Atlassian products and practices.
Is there bamboo REST apis available to delete plan/project ?
Hi @EndeJoli,
Please, find below the requested:
#
# Marks project for deletion. Project will be deleted by a batch job.
#
# replace {username} to authenticate and perform deletion
# replace http://localhost:8085 with URL to access Bamboo
# replace {projectKey}, e.g PROJ
curl -k -u {username} \
-X DELETE http://localhost:8085/rest/api/latest/project/{projectKey}
#
# However, to delete the project you MUST delete the plans first,
# otherwise Bamboo will throw an error:
{"message":"Project can''t be deleted, as it still contains plans.","status-code":400}
#
# Marks plan for deletion. Plan will be deleted by batch job.
#
# replace {username}
# replace {planKey}, e.g PROJ-PLAN
# replace http://localhost:8085 with URL to access Bamboo
curl -k -u {username} \
-H 'X-Atlassian-Token: no-check' \
-H 'Accept: application/json' \
-H 'Content-Type: application/x-www-form-urlencoded' \
-d 'buildKey={planKey}' \
-X POST 'http://localhost:8085/ajax/deleteChain.action'
Kind regards,
Rafael
When you say:
Marks plan for deletion. Plan will be deleted by batch job.
What do you mean? I am in need to delete some projects as well which contain plans, but when I run the curl command with the ajax/deleteChain.action, it doesn't do anything, do you have more info on how to delete the plans programmatically?
What i mean is, this batch job, is that something I need to configure to run? or how does it work?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.