The Atlassian Community can help you and your team get more value out of Atlassian products and practices.
Looking at the documentation here. This should work:
{
"title": "My Title",
"source": {
"branch": {
"name": "my-feature-branch"
}
},
"reviewers": [
{
"uuid": "{504c3b62-8120-4f0c-a7bc-87800b9d6f70}"
}
]
}
But it does not, I get a 400.
If I remove the "reviewers" property from the json, the PR creates successfully.
I have confirmed the uuid that I am using is correct (via a call to {{baseUrl}}/workspaces/:ourworkspace/members) and has access to the repo.
So, I don't 'think' I'm doing anything wrong. Can you confirm the functionality works and the documentation is correct? And if so, any suggestions for what else to try?
This is my json:
{ "title": "my PR title",
"source": { "branch": { "name": "sourcebranch" } },
"destination": { "branch": { "name": "develop" } },
"reviewers": [ { "uuid": "{valid-uuid}" } ]
}
Hi Mark,
I can confirm that this works for me using an API call like the following:
curl -u <username>:<app-password> -X POST https://api.bitbucket.org/2.0/repositories/<workspace-id>/<repo-slug>/pullrequests -H "Content-Type: application/json" -d '{"title":"My Title","source":{"branch":{"name":"test3"}},"destination":{"branch":{"name":"master"}},"reviewers":[{"uuid":"{85h7ba24-d516-4fo6-980c-e5fa6829a41e}"}]}'
Could you try testing the API call with curl (in case you haven't already)?
If you get the same error, could you please copy-paste here the exact call and the full output, sanitizing any private/sensitive info like username, password, workspace-id etc?
Kind regards,
Theodora
Beginning on April 4th, we will be implementing push limits. This means that your push cannot be completed if it is over 3.5 GB. If you do attempt to complete a push that is over 3.5 GB, it will fail...
Connect with like-minded Atlassian users at free events near you!
Find an eventConnect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.
Host an eventYou're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.