Hello
I am trying to use the Bitbucket API to automatically merge some commits forward from old -> new branch. I have set up a webhook that triggers whenever a new commit is pushed to old. I would then like to take that commit and attempt to merge it forward.
I am using this route:
https://api.bitbucket.org/2.0/repositories/{workspace}/{repo}/refs/branches
which takes a "target" commit hash. The target is simply a starting point though. If there are other unmerged commits before my target, the branch will contain all of them. I want the branch to only contain the commit I am specifying. Basically, I'd like to cherry-pick a commit hash into a new branch.
Is this possible at all through the REST API? Is there a possible workaround?
Thank you in advance!