Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Celebration

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,559,605
Community Members
 
Community Events
185
Community Groups

How can I extract all the commits in a pull request using bitbucket API and the pull request ID?

Edited

I am using this api call

https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/commits

My first question -

 1. The response does not have the commit hash as shown in the BitBucket UI of the pull request. How to fix this? The pull request Id is correctly passed to the api call.

2. How can I filter only the commit hash that are not merged from the response?

 

Thanks.

 

1 answer

1 accepted

0 votes
Answer accepted

I am able to filter out the commits by using the 'message' string in the json response.

However, for pull request with having more then 10 commits, I am not able to get all the commits. How can I request all the commits with one api call and is it possible?

Thanks 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
TAGS
AUG Leaders

Atlassian Community Events