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

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

How to capture PR creation event in BitBucket?

Hi Team,

I have a requirement to run a script when there is a PR(PullRequest) created over bitbucket server. The script further require to capture the PR reviewer details once the PR is raised.

Same time, Do not want to trigger a build in bamboo up on PR creation.

I have different thoughts,

1) Through BB API's, Poll the PR creation page until PR creation event occurs - Not a good idea to continuously poll server page using API's

 2) checking for any GIT CLI commands to list the latest PR event, so those GIT commands could be incorporated in script and figure out the PR creation. -- Not found any useful GIT commands.

3) If any logs that captures the PR event (could be audit or any server specific logs which keeps track of the events), that log could be given as input to script to identify for the PR creation event in logs may be  based on time stamps or PR creation related keywords

 

I feel and positive about option 3 for now. if its feasible to identify PR events in any of the logs or in unique files which records this data, please let me know which will be of a great help/

 

Also Great if there is any other best approaches to capture the PR creation event and PR reviewers through scripting. ( just need to know where can it be identified, can think about how later on. .. )

 

Thanks,

Jay

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Bitbucket

New improvements to user management in Bitbucket Cloud 👥

Hey Community! We’re willing to wager that quite a few of you not only use Bitbucket, but administer it too. Our team is excited to share that we’ll be releasing improvements throughout this month of...

3,848 views 10 16
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you