I am trying to raise pr from (example data) master branch of
https://{bitbucket_base_url.com}/users/sravya/repos/sample_repo/browse
to
master branch of https://{bitbucket_base_url.com}/projects/my_project_key/repos/sample_repo/browse.
Endpoint i am using :
https://{bitbucket_base_url.com}/rest/api/1.0/projects/my_project_key/repos/sample_repo/pull-requests
Payload :
payload = {
"title": "Hi",
"description": "Hello",
"state": "OPEN",
"open": True,
"closed": False,
"fromRef": {
"id": "refs/heads/master",
'repository': {
'slug': "sample_repo",
'name': None,
'project':{
'key':'sravya'
}
}
},
"toRef": {
"id": "refs/heads/master",
'repository': {
'slug': "sample_repo",
'name': None,
'project':{
'key':'my_project_key'
}
}
},
"locked": False,
# "reviewers": [
# {
# "user": {
# "name": "sravya"
# }
# },
# ]
}
i am getting 404 - {"errors":[{"context":null,"message":"Repository sravya/sample_repo does not exist.","exceptionName":null}. can someone help??