The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to capture PR creation event in BitBucket?

Jayadev Pentapati
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
August 29, 2020

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

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

TAGS
AUG Leaders

Atlassian Community Events