Skip to content

Add the specific user as a default reviewer for the project

PUT
/workspaces/{workspace}/projects/{project_key}/default-reviewers/{selected_user}

Adds the specified user to the project’s list of default reviewers. The method is idempotent. Accepts an optional body containing the uuid of the user to be added.

project_key
required
string

The project in question. This can either be the actual key assigned to the project or the UUID (surrounded by curly-braces ({})).

selected_user
required
string

This can either be the username or the UUID of the default reviewer, surrounded by curly-braces, for example: {account UUID}.

workspace
required
string

This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example: {workspace UUID}.

The specified user was added as a project default reviewer

Media type application/json
object
type
required
string
links
Account Links

Links related to an Account.

object
avatar
Link

A link to a resource related to this object.

object
href
string format: uri
name
string
key
additional properties
any
created_on
string format: date-time
display_name
string
uuid
string
links
object
avatar
Link

A link to a resource related to this object.

object
href
string format: uri
name
string
self
Link

A link to a resource related to this object.

object
href
string format: uri
name
string
html
Link

A link to a resource related to this object.

object
href
string format: uri
name
string
repositories
Link

A link to a resource related to this object.

object
href
string format: uri
name
string
account_id

The user’s Atlassian account ID.

string
account_status

The status of the account. Currently the only possible value is “active”, but more values may be added in the future.

string
has_2fa_enabled
boolean
nickname

Account name defined by the owner. Should be used instead of the “username” field. Note that “nickname” cannot be used in place of “username” in URLs and queries, as “nickname” is not guaranteed to be unique.

string
is_staff
boolean
Examples
Example response
{
"display_name": "Yaniv Sagy",
"links": {
"self": {
"href": "https://api.bitbucket.org/2.0/users/%7Bdd5db7f2-6389-458d-a62a-716773910b7a%7D"
},
"avatar": {
"href": "https://secure.gravatar.com/avatar/YS-2.png"
},
"html": {
"href": "https://api.bitbucket.org/%7Bdd5db7f2-6389-458d-a62a-716773910b7a%7D/"
}
},
"type": "user",
"uuid": "{dd5db7f2-6389-458d-a62a-716773910b7a}",
"account_id": "712020:4efe52fa-b4b4-475b-9eb0-c0a23b7eb194",
"nickname": "Yaniv Sagy"
}

If the specified user cannot be added as a default reviewer for the project

Media type application/json
Error

Base type for most resource objects. It defines the common type element that identifies an object’s type. It also identifies the element as Swagger’s discriminator.

object
type
required
string
error
object
message
required
string
detail
string
data

Optional structured data that is endpoint-specific.

object
key
additional properties
any
key
additional properties
any
Example generated
{
"type": "example",
"error": {
"message": "example",
"detail": "example",
"data": {}
}
}

If the authenticated user does not have admin access to the project

Media type application/json
Error

Base type for most resource objects. It defines the common type element that identifies an object’s type. It also identifies the element as Swagger’s discriminator.

object
type
required
string
error
object
message
required
string
detail
string
data

Optional structured data that is endpoint-specific.

object
key
additional properties
any
key
additional properties
any
Example generated
{
"type": "example",
"error": {
"message": "example",
"detail": "example",
"data": {}
}
}

If the specified user, project, or workspace does not exist

Media type application/json
Error

Base type for most resource objects. It defines the common type element that identifies an object’s type. It also identifies the element as Swagger’s discriminator.

object
type
required
string
error
object
message
required
string
detail
string
data

Optional structured data that is endpoint-specific.

object
key
additional properties
any
key
additional properties
any
Example generated
{
"type": "example",
"error": {
"message": "example",
"detail": "example",
"data": {}
}
}