The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Bitbucket Cloud: Verify Merge Checks via API 2

peter_warmenhoven
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!
August 10, 2020

Apparently, using API 1.0 it was possible to check if a Pull Request satisfied merge checks by making  GET request to the merge endpoint. The same thing doesn't work in 2.0:

https://api.bitbucket.org/2.0/repositories/<workspace>/<repo>/pullrequests/<pull_request_id>/merge

Unfortunately this does not work any longer and when making a GET request to this endpoint I get a strange error:

 

`This endpoint does not support token-based authentication`

Though, I am just using Basic Authentication

1 answer

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

0 votes
Michael Gutierrez
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!
October 16, 2020

I found the "canMerge" value in 1.0 very useful because we have multiple repos we sometimes need to merge code to at once. It would save me a lot of code if something was similar in 2.0, but there isn't. I had to resort to checking the PR events for approvals to see if required approves had approved, and checking for merge conflicts manually instead. Messy mess.

TAGS
AUG Leaders

Atlassian Community Events