<p>You have <code>/rest/branch-utils/latest/projects/{project_key}/delete-after-merge</code></p>

CC BY-SA 4.0
2024-01-12T19:30:44.847Z
2024-01-12T19:30:44.847Z
Henri
<p>I know that 'Branch deletion on merge' can be set at both project and repo level via UI.</p>
<p>What I am looking for the the REST API endpoint for doing this. Similar endpoints for branching model, etc. exist but I could not find an endpoint for setting 'Branch deletion on merge' at project level.</p>
<p>Using Atlassian Bitbucket v7.17.1</p>
<p><a href="https://i.sstatic.net/vhsaS.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/vhsaS.png" alt="enter image description here" /></a></p>

<bitbucket><bitbucket-server>
Bitbucket REST API to set 'Branch deletion on merge'
Kaliyug Antagonist
# Bitbucket REST API to set 'Branch deletion on merge'

(Asked by: username_0 on 2021-12-06)

I know that 'Branch deletion on merge' can be set at both project and repo level via UI.

What I am looking for the the REST API endpoint for doing this. Similar endpoints for branching model, etc. exist but I could not find an endpoint for setting 'Branch deletion on merge' at project level.

Using Atlassian Bitbucket v7.17.1

[![enter image description here](https://i.sstatic.net/vhsaS.png)](https://i.sstatic.net/vhsaS.png)

**Tags:** bitbucket, bitbucket-server


---

## 1 answers

### Answer by username_1 on 2024-01-12. Score: 0

You have `/rest/branch-utils/latest/projects/{project_key}/delete-after-merge`


---

