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

Next challenges

Recent achievements

  • Global
  • Personal

Recognition

  • Give kudos
  • Received
  • Given

Leaderboard

  • Global

Trophy case

Kudos (beta program)

Kudos logo

You've been invited into the Kudos (beta program) private group. Chat with others in the program, or give feedback to Atlassian.

View group

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 set default reviewers using API 2.0

Not sure if this is possible, but it seems it was once possible to set default reviewers using the API. Could not find it on the documentation. I'm trying to automate repository creation and setting the default reviewers is an important step. Has anyone tried and succeeded?

My request as of now (attempted to add a participants field, that of course didnt work):

curl -X POST \ https://api.bitbucket.org/2.0/repositories/myhandle/mynewrepo \ -H 'Authorization: Basic yattayattayatta' \ -H 'Content-Type: application/json' \ -d '{ "scm": "git", "is_private": true, "participants": [ { "is_staff": true, "account_id": "my_own_account", "role": [REVIEWER], "approved": true } ], "project": { "key": "MYPROJECT" }}'

 

1 answer

1 accepted

1 vote
Answer accepted

Hello @Daniel Rosario Carletti,

Welcome to the Community.

Here are the endpoints to add and delete a user to/from default reviewers for a given repository. This endpoint lists all default reviewers.

Hope this helps. Let me know if you have any questions.

Cheers,
Daniil

Suggest an answer

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

Calling any interview participants for Bitbucket Data Center

Hi everyone,  We are looking to learn more about development teams’ workflows and pain points, especially around DevOps, integrations, administration, scale, security, and the related challeng...

442 views 4 4
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