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

Bad Request when merging pull request with Bitbucket API 2.0 Edited

I've tried several different formats for the JSON body of the request but no matter what I try I get a 400 bad request response.

I'm basing my request off the official documentation here:

I've also posted a ticket on Stack Overflow with some code examples:

I've had no issues with creating branches and pull requests, the API docs are quite clear. However for some reason the merge is just not working.

Would greatly appreciate some help as I'm completely stuck.



So I have discovered that the API will return a bad request if the pull request can't be merged due to conflicts. Is this intended behavior? Is there a correct way to check for conflicts with the API before attempting to merge the PR?

0 answers

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Bitbucket

Bitbucket Server 7.0 is here!

Hello Community, I’m Anton Genkin, a product manager on the Bitbucket Server and Data Center team and am excited to share that Bitbucket Server 7.0 is now available! It's a platform release, one th...

1,005 views 6 5
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