Adds the specified user to the repository's list of default
reviewers.
This method is idempotent. Adding a user a second time has no effect.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the username or the UUID of the default reviewer,
surrounded by curly-braces, for example: {account UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Create a new deploy key in a repository. Note: If authenticating a deploy key
with an OAuth consumer, any changes to the OAuth consumer will subsequently
invalidate the deploy key.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Adds a new SSH public key to the specified user account and returns the resulting key.
This can either be the UUID of the account, surrounded by curly-braces, for
example: {account UUID}
, OR an Atlassian Account ID.
Type: string
The new SSH key object. Note that the username property has been deprecated due to privacy changes.
Type: object
{
"type" : "Required string",
"created_on" : "date-time",
"last_used" : "date-time",
"comment" : "The comment parsed from the SSH key (if present)",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"label" : "The user-defined label for the SSH key",
"uuid" : "The SSH key's immutable ID.",
"key" : "The SSH public key value in OpenSSH format.",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
}
Approve the specified commit as the authenticated user.
This operation is only available to users that have explicit access to
the repository. In contrast, just the fact that a repository is
publicly accessible to users does not give them the ability to approve
commits.
The commit's SHA1.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Approve the specified pull request as the authenticated user.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Bulk upload of annotations.
Annotations are individual findings that have been identified as part of a report, for example, a line of code that represents a vulnerability. These annotations can be attached to a specific file and even a specific line in that file, however, that is optional. Annotations are not mandatory and a report can contain up to 1000 annotations.
Add the annotations you want to upload as objects in a JSON array and make sure each annotation has the external_id field set to a unique value. If you want to use an existing id from your own system, we recommend prefixing it with your system's name to avoid collisions, for example, mySystem-annotation001. The external id can later be used to identify the report as an alternative to the generated UUID. You can upload up to 100 annotations per POST request.
annotation_type: VULNERABILITY, CODE_SMELL, BUG
result: PASSED, FAILED, IGNORED, SKIPPED
severity: HIGH, MEDIUM, LOW, CRITICAL
Please refer to the Code Insights documentation for more information.
The commit for which to retrieve reports.
Type: string
The repository.
Type: string
Uuid or external-if of the report for which to get annotations for.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The annotations to create or update
Type: array
[ {
"type" : "Required string",
"summary" : "The message to display to users.",
"result" : "The state of the report. May be set to PENDING and later updated.",
"severity" : "The severity of the annotation.",
"updated_on" : "The timestamp when the report was updated.",
"path" : "The path of the file on which this annotation should be placed. This is the path of the file relative to the git repository. If no path is provided, then it will appear in the overview modal on all pull requests where the tip of the branch is the given commit, regardless of which files were modified.",
"created_on" : "The timestamp when the report was created.",
"line" : "The line number that the annotation should belong to. If no line number is provided, then it will default to 0 and in a pull request it will appear at the top of the file specified by the path field.",
"link" : "A URL linking to the annotation in an external tool.",
"external_id" : "ID of the annotation provided by the annotation creator. It can be used to identify the annotation as an alternative to it's generated uuid. It is not used by Bitbucket, but only by the annotation creator for updating or deleting this specific annotation. Needs to be unique.",
"annotation_type" : "The type of the report.",
"details" : "The details to show to users when clicking on the annotation.",
"uuid" : "The UUID that can be used to identify the annotation."
} ]
Makes a change to the specified issue.
The fields of the changes
object are strings, not objects. This
allows for immutable change log records, even after user accounts,
milestones, or other objects recorded in a change entry, get renamed or
deleted.
The assignee_account_id
field stores the account id. When POSTing a
new change and changing the assignee, the client should therefore use
the user's account_id in the changes.assignee_account_id.new
field.
This call requires authentication. Private repositories or private
issue trackers require the caller to authenticate with an account that
has appropriate authorization.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The new issue state change. The only required elements are changes.[].new
. All other elements can be omitted from the body.
Type: object
{
"issue" : {
"type" : "Required string",
"updated_on" : "date-time",
"edited_on" : "date-time",
"kind" : "string. Possible values: bug | enhancement | proposal | task",
"reporter" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"title" : "string",
"priority" : "string. Possible values: trivial | minor | major | critical | blocker",
"version" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"component" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"milestone" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"created_on" : "date-time",
"links" : {
"comments" : {
"name" : "string",
"href" : "uri"
},
"attachments" : {
"name" : "string",
"href" : "uri"
},
"watch" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"vote" : {
"name" : "string",
"href" : "uri"
}
},
"votes" : "integer",
"id" : "integer",
"assignee" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"state" : "string. Possible values: new | open | resolved | on hold | invalid | duplicate | wontfix | closed"
},
"created_on" : "date-time",
"name" : "string",
"changes" : {
"component" : {
"new" : "string",
"old" : "string"
},
"milestone" : {
"new" : "string",
"old" : "string"
},
"kind" : {
"new" : "string",
"old" : "string"
},
"assignee" : {
"new" : "string",
"old" : "string"
},
"state" : {
"new" : "string",
"old" : "string"
},
"title" : {
"new" : "string",
"old" : "string"
},
"priority" : {
"new" : "string",
"old" : "string"
},
"version" : {
"new" : "string",
"old" : "string"
},
"content" : {
"new" : "string",
"old" : "string"
}
},
"links" : {
"issue" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"message" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
}
}
This endpoint is used to poll for the progress of an issue export
job and return the zip file after the job is complete.
As long as the job is running, this will return a 200 response
with in the response body a description of the current status.
After the job has been scheduled, but before it starts executing, this
endpoint's response is:
{
"type": "issue_job_status",
"status": "ACCEPTED",
"phase": "Initializing",
"total": 0,
"count": 0,
"pct": 0
}
Then once it starts running, it becomes:
{
"type": "issue_job_status",
"status": "STARTED",
"phase": "Attachments",
"total": 15,
"count": 11,
"pct": 73
}
Once the job has successfully completed, it returns a stream of the zip file.
The name of the repo
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
The ID of the export task
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
When using GET, this endpoint reports the status of the current import task.
After the job has been scheduled, but before it starts executing, this endpoint's response is:
< HTTP/1.1 202 Accepted
{
"type": "issue_job_status",
"status": "PENDING",
"phase": "Attachments",
"total": 15,
"count": 0,
"percent": 0
}
Once it starts running, it is a 202 response with status STARTED and progress filled.
After it is finished, it becomes a 200 response with status SUCCESS or FAILURE.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Produces a raw git-style diff.
If the spec
argument to this API is a single commit, the diff is
produced against the first parent of the specified commit.
Two commits separated by ..
may be provided as the spec
, e.g.,3a8b42..9ff173
. When two commits are provided and the merge
query
parameter is true or absent, this API produces a 3-way diff, also
referred to as a merge diff. This is equivalent to merging the left
branch into the right branch and then computing the diff of the merge
commit against its first parent (the right branch). These diffs have
the same behavior as pull requests that show the 3-way diff, such as
the Bitbucket Cloud Pull
Request.
For a simple git-style diff, add merge=false
to the query.
The two commits are interpreted as follows:
git diff
.While similar to patches, diffs:
path=foo/bar.py
query param to filterThe raw diff is returned as-is, in whatever encoding the files in the
repository use. It is not decoded into unicode. As such, the
content-type is text/plain
.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
A commit SHA (e.g. 3a8b42
) or a commit range using double dot
notation (e.g. 3a8b42..9ff173
).
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Generate diffs that include binary files, true if omitted.
Type: boolean
Generate diffs with lines of context instead of the usual three.
Type: integer
Generate diffs that ignore whitespace.
Type: boolean
If true, the source commit is merged into the
destination commit, and then a diff from the
destination to the merge result is returned. If false,
a simple 'two dot' diff between the source and
destination is returned. True if omitted.
Type: boolean
Limit the diff to a particular file (this parameter
can be repeated for multiple paths).
Type: string
Whether to perform rename detection, true if omitted.
Type: boolean
Produces a response in JSON format with a record for every path
modified, including information on the type of the change and the
number of lines added and removed.
If the spec
argument to this API is a single commit, the diff is
produced against the first parent of the specified commit.
Two commits separated by ..
may be provided as the spec
, e.g.,3a8b42..9ff173
. When two commits are provided and the merge
query
parameter is true or absent, this API produces a 3-way diff, also
referred to as a merge diff. This is equivalent to merging the left
branch into the right branch and then computing the diff of the merge
commit against its first parent (the right branch). These diffs have
the same behavior as pull requests that show the 3-way diff, such as
the Bitbucket Cloud Pull
Request.
For a simple git-style diff, add merge=false
to the query.
The two commits are interpreted as follows:
git diff
.This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
A commit SHA (e.g. 3a8b42
) or a commit range using double dot
notation (e.g. 3a8b42..9ff173
).
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Generate diffs that ignore whitespace
Type: boolean
If true, the source commit is merged into the
destination commit, and then a diffstat from the
destination to the merge result is returned. If false,
a simple 'two dot' diffstat between the source and
destination is returned. True if omitted.
Type: boolean
Limit the diffstat to a particular file (this parameter
can be repeated for multiple paths).
Type: string
Whether to perform rename detection, true if omitted.
Type: boolean
Creates a new branch in the specified repository.
The payload of the POST should consist of a JSON document that
contains the name of the tag and the target hash.
This call requires authentication. Private repositories require the
caller to authenticate with an account that has appropriate
authorization.
The branch name should not include any prefixes (e.g.
refs/heads). This endpoint does support using short hash prefixes for
the commit hash, but it may return a 400 response if the provided
prefix is ambiguous. Using a full commit hash is the preferred
approach.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Creates a new branch restriction rule for a repository.
kind
describes what will be restricted. Allowed values include:push
, force
, delete
and restrict_merges
.
Different kinds of branch restrictions have different requirements:
push
and restrict_merges
require users
and groups
to beThe restriction applies to all branches that match. There are
two ways to match a branch. It is configured in branch_match_kind
:
glob
: Matches a branch against the pattern
. A '*'
inpattern
will expand to match zero or more characters, and every'foo*'
will match'foo'
and 'foobar'
, but not 'barfoo'
. '*'
will match allbranching_model
: Matches a branch against the repository'sbranch_type
controls the type of branchproduction
, development
,bugfix
, release
, feature
and hotfix
.The combination of kind
and match must be unique. This means that
two glob
restrictions in a repository cannot have the same kind
andpattern
. Additionally, two branching_model
restrictions in a
repository cannot have the same kind
and branch_type
.
users
and groups
are lists of users and groups that are except from
the restriction. They can only be configured in push
andrestrict_merges
restrictions. The push
restriction stops a user
pushing to matching branches unless that user is in users
or is a
member of a group in groups
. The restrict_merges
stops a user
merging pull requests to matching branches unless that user is inusers
or is a member of a group in groups
. Adding new users or
groups to an existing restriction should be done via PUT
.
Note that branch restrictions with overlapping matchers is allowed,
but the resulting behavior may be surprising.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The new rule
Type: object
{
"type" : "Required string",
"branch_match_kind" : "Indicates how the restriction is matched against a branch. The default is `glob`.",
"branch_type" : "Apply the restriction to branches of this type. Active when `branch_match_kind` is `branching_model`. The branch type will be calculated using the branching model configured for the repository.",
"kind" : "The type of restriction that is being applied.",
"pattern" : "Apply the restriction to branches that match this pattern. Active when `branch_match_kind` is `glob`. Will be empty when `branch_match_kind` is `branching_model`.",
"groups" : [ {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"full_slug" : "The concatenation of the workspace's slug and the group's slug,\nseparated with a colon (e.g. `acme:developers`)\n",
"workspace" : {
"type" : "Required string",
"is_private" : "Indicates whether the workspace is publicly accessible, or whether it is\nprivate to the members and consequently only visible to members.\nNote that private workspaces cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the workspace.",
"links" : {
"projects" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"snippets" : {
"name" : "string",
"href" : "uri"
},
"members" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"owners" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"uuid" : "The workspace's immutable id.",
"slug" : "The short label that identifies this workspace."
},
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"slug" : "The \"sluggified\" version of the group's name. This contains only ASCII\ncharacters and can therefore be slightly different than the name"
} ],
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "The branch restriction status' id.",
"value" : "integer",
"users" : [ {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
} ]
}
Creates a new build status against the specified commit.
If the specified key already exists, the existing status object will
be overwritten.
When creating a new commit status, you can use a URI template for the URL.
Templates are URLs that contain variable names that Bitbucket will
evaluate at runtime whenever the URL is displayed anywhere similar to
parameter substitution in
Bitbucket Connect.
For example, one could use https://foo.com/builds/{repository.full_name}
which Bitbucket will turn into https://foo.com/builds/foo/bar
at render time.
The context variables available are repository
and commit
.
The commit's SHA1.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The new commit status object.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "An identifier for the build itself, e.g. BB-DEPLOY-1",
"description" : "A description of the build (e.g. \"Unit tests in Bamboo\")",
"links" : {
"commit" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
}
},
"state" : "Provides some indication of the status of this commit",
"uuid" : "The commit status' id.",
"key" : "An identifier for the status that's unique to\n its type (current \"build\" is the only supported type) and the vendor,\n e.g. BB-DEPLOY",
"refname" : "\nThe name of the ref that pointed to this commit at the time the status\nobject was created. Note that this the ref may since have moved off of\nthe commit. This optional field can be useful for build systems whose\nbuild triggers and configuration are branch-dependent (e.g. a Pipeline\nbuild).\nIt is legitimate for this field to not be set, or even apply (e.g. a\nstatic linting job).",
"url" : "A URL linking back to the vendor or build system, for providing more information about whatever process produced this status. Accepts context variables `repository` and `commit` that Bitbucket will evaluate at runtime whenever at runtime. For example, one could use https://foo.com/builds/{repository.full_name} which Bitbucket will turn into https://foo.com/builds/foo/bar at render time."
}
Creates new comment on the specified commit.
To post a reply to an existing comment, include the parent.id
field:
The commit's SHA1.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The specified comment.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"parent" : "comment",
"deleted" : "boolean",
"inline" : {
"path" : "The path of the file this comment is anchored to.",
"from" : "The comment's anchor line in the old version of the file.",
"to" : "The comment's anchor line in the new version of the file. If the 'from' line is also provided, this value will be removed."
},
"created_on" : "date-time",
"links" : {
"code" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"commit" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : "commit",
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
}
}
Creates or updates an individual annotation for the specified report.
Annotations are individual findings that have been identified as part of a report, for example, a line of code that represents a vulnerability. These annotations can be attached to a specific file and even a specific line in that file, however, that is optional. Annotations are not mandatory and a report can contain up to 1000 annotations.
Just as reports, annotation needs to be uploaded with a unique ID that can later be used to identify the report as an alternative to the generated UUID. If you want to use an existing id from your own system, we recommend prefixing it with your system's name to avoid collisions, for example, mySystem-annotation001.
annotation_type: VULNERABILITY, CODE_SMELL, BUG
result: PASSED, FAILED, IGNORED, SKIPPED
severity: HIGH, MEDIUM, LOW, CRITICAL
Please refer to the Code Insights documentation for more information.
Either the uuid or external-id of the annotation.
Type: string
The commit the report belongs to.
Type: string
The repository.
Type: string
Either the uuid or external-id of the report.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The annotation to create or update
Type: object
{
"type" : "Required string",
"summary" : "The message to display to users.",
"result" : "The state of the report. May be set to PENDING and later updated.",
"severity" : "The severity of the annotation.",
"updated_on" : "The timestamp when the report was updated.",
"path" : "The path of the file on which this annotation should be placed. This is the path of the file relative to the git repository. If no path is provided, then it will appear in the overview modal on all pull requests where the tip of the branch is the given commit, regardless of which files were modified.",
"created_on" : "The timestamp when the report was created.",
"line" : "The line number that the annotation should belong to. If no line number is provided, then it will default to 0 and in a pull request it will appear at the top of the file specified by the path field.",
"link" : "A URL linking to the annotation in an external tool.",
"external_id" : "ID of the annotation provided by the annotation creator. It can be used to identify the annotation as an alternative to it's generated uuid. It is not used by Bitbucket, but only by the annotation creator for updating or deleting this specific annotation. Needs to be unique.",
"annotation_type" : "The type of the report.",
"details" : "The details to show to users when clicking on the annotation.",
"uuid" : "The UUID that can be used to identify the annotation."
}
Create a deployment environment level variable.
The environment.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The variable to create
Type: object
{
"type" : "Required string",
"uuid" : "The UUID identifying the variable.",
"value" : "The value of the variable. If the variable is secured, this will be empty.",
"secured" : "If true, this variable will be treated as secured. The value will never be exposed in the logs or the REST API.",
"key" : "The unique name of the variable."
}
Create an environment.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The environment to create.
Type: object
{
"type" : "Required string",
"name" : "The name of the environment.",
"uuid" : "The UUID identifying the environment."
}
Creates a new issue.
This call requires authentication. Private repositories or private
issue trackers require the caller to authenticate with an account that
has appropriate authorization.
The authenticated user is used for the issue's reporter
field.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The new issue. The only required element is title
. All other elements can be omitted from the body.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"edited_on" : "date-time",
"kind" : "string. Possible values: bug | enhancement | proposal | task",
"reporter" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"title" : "string",
"priority" : "string. Possible values: trivial | minor | major | critical | blocker",
"version" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"component" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"milestone" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"created_on" : "date-time",
"links" : {
"comments" : {
"name" : "string",
"href" : "uri"
},
"attachments" : {
"name" : "string",
"href" : "uri"
},
"watch" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"vote" : {
"name" : "string",
"href" : "uri"
}
},
"votes" : "integer",
"id" : "integer",
"assignee" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"state" : "string. Possible values: new | open | resolved | on hold | invalid | duplicate | wontfix | closed"
}
Creates a new issue comment.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The new issue comment object.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"parent" : "comment",
"deleted" : "boolean",
"inline" : {
"path" : "The path of the file this comment is anchored to.",
"from" : "The comment's anchor line in the old version of the file.",
"to" : "The comment's anchor line in the new version of the file. If the 'from' line is also provided, this value will be removed."
},
"created_on" : "date-time",
"links" : {
"code" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"issue" : {
"type" : "Required string",
"updated_on" : "date-time",
"edited_on" : "date-time",
"kind" : "string. Possible values: bug | enhancement | proposal | task",
"reporter" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"title" : "string",
"priority" : "string. Possible values: trivial | minor | major | critical | blocker",
"version" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"component" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"milestone" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"created_on" : "date-time",
"links" : {
"comments" : {
"name" : "string",
"href" : "uri"
},
"attachments" : {
"name" : "string",
"href" : "uri"
},
"watch" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"vote" : {
"name" : "string",
"href" : "uri"
}
},
"votes" : "integer",
"id" : "integer",
"assignee" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"state" : "string. Possible values: new | open | resolved | on hold | invalid | duplicate | wontfix | closed"
}
}
Creates or updates a report for the specified commit.
To upload a report, make sure to generate an ID that is unique across all reports for that commit. If you want to use an existing id from your own system, we recommend prefixing it with your system's name to avoid collisions, for example, mySystem-001.
Please refer to the Code Insights documentation for more information.
The commit the report belongs to.
Type: string
The repository.
Type: string
Either the uuid or external-id of the report.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The report to create or update
Type: object
{
"type" : "Required string",
"updated_on" : "The timestamp when the report was updated.",
"data" : [ {
"type" : "The type of data contained in the value field. If not provided, then the value will be detected as a boolean, number or string.",
"title" : "A string describing what this data field represents.",
"value" : { }
} ],
"logo_url" : "A URL to the report logo. If none is provided, the default insights logo will be used.",
"remote_link_enabled" : "If enabled, a remote link is created in Jira for the issue associated with the commit the report belongs to.",
"link" : "A URL linking to the results of the report in an external tool.",
"external_id" : "ID of the report provided by the report creator. It can be used to identify the report as an alternative to it's generated uuid. It is not used by Bitbucket, but only by the report creator for updating or deleting this specific report. Needs to be unique.",
"reporter" : "A string to describe the tool or company who created the report.",
"report_type" : "The type of the report.",
"title" : "The title of the report.",
"uuid" : "The UUID that can be used to identify the report.",
"result" : "The state of the report. May be set to PENDING and later updated.",
"created_on" : "The timestamp when the report was created.",
"details" : "A string to describe the purpose of the report."
}
Create a repository level known host.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The known host to create.
Type: object
{
"type" : "Required string",
"public_key" : {
"type" : "Required string",
"key_type" : "The type of the public key.",
"md5_fingerprint" : "The MD5 fingerprint of the public key.",
"sha256_fingerprint" : "The SHA-256 fingerprint of the public key.",
"key" : "The base64 encoded public key."
},
"hostname" : "The hostname of the known host.",
"uuid" : "The UUID identifying the known host."
}
Create a schedule for the given repository.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The schedule to create.
Type: object
{
"type" : "Required string",
"updated_on" : "The timestamp when the schedule was updated.",
"created_on" : "The timestamp when the schedule was created.",
"selector" : {
"type" : "The type of selector.",
"pattern" : "The name of the matching pipeline definition."
},
"uuid" : "The UUID identifying the schedule.",
"cron_pattern" : "The cron expression that the schedule applies.",
"enabled" : "Whether the schedule is enabled.",
"target" : {
"type" : "Required string"
}
}
Create a repository level variable.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The variable to create.
Type: object
{
"type" : "Required string",
"uuid" : "The UUID identifying the variable.",
"value" : "The value of the variable. If the variable is secured, this will be empty.",
"secured" : "If true, this variable will be treated as secured. The value will never be exposed in the logs or the REST API.",
"key" : "The unique name of the variable."
}
Creates a new project.
Note that the avatar has to be embedded as either a data-url
or a URL to an external image.
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Type: object
{
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
}
Creates a new pull request where the destination repository is
this repository and the author is the authenticated user.
The minimum required fields to create a pull request are title
andsource
, specified by a branch name.
If the pull request's destination
is not specified, it will default
to the repository.mainbranch
. To open a pull request to a
different branch, say from a feature branch to a staging branch,
specify a destination
(same format as the source
):
Reviewers can be specified by adding an array of user objects as thereviewers
property.
Other fields:
description
- a stringclose_source_branch
- boolean that specifies if the source branch should be closed upon mergingThis can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The new pull request.
The request URL you POST to becomes the destination repository URL. For this reason, you must specify an explicit source repository in the request object if you want to pull from a different repository (fork).
Since not all elements are required or even mutable, you only need to include the elements you want to initialize, such as the source branch and the title.
Type: object
{
"type" : "Required string",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"comment_count" : "The number of comments for a specific pull request.",
"updated_on" : "The ISO8601 timestamp the request was last updated.",
"reason" : "Explains why a pull request was declined. This field is only applicable to pull requests in rejected state.",
"author" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"destination" : {
"commit" : {
"hash" : "string"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"branch" : {
"default_merge_strategy" : "The default merge strategy, when this endpoint is the destination of the pull request.",
"name" : "string",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
}
},
"source" : {
"commit" : {
"hash" : "string"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"branch" : {
"default_merge_strategy" : "The default merge strategy, when this endpoint is the destination of the pull request.",
"name" : "string",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
}
},
"title" : "Title of the pull request.",
"reviewers" : [ {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
} ],
"task_count" : "The number of open tasks for a specific pull request.",
"closed_by" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"rendered" : {
"reason" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"description" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"title" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
}
},
"created_on" : "The ISO8601 timestamp the request was created.",
"links" : {
"comments" : {
"name" : "string",
"href" : "uri"
},
"activity" : {
"name" : "string",
"href" : "uri"
},
"approve" : {
"name" : "string",
"href" : "uri"
},
"merge" : {
"name" : "string",
"href" : "uri"
},
"decline" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"diff" : {
"name" : "string",
"href" : "uri"
},
"diffstat" : {
"name" : "string",
"href" : "uri"
}
},
"close_source_branch" : "A boolean flag indicating if merging the pull request closes the source branch.",
"id" : "The pull request's unique ID. Note that pull request IDs are only unique within their associated repository.",
"state" : "The pull request's current status.",
"merge_commit" : {
"hash" : "string"
},
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
}
Creates a new pull request comment.
Returns the newly created pull request comment.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The comment object.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"parent" : "comment",
"deleted" : "boolean",
"inline" : {
"path" : "The path of the file this comment is anchored to.",
"from" : "The comment's anchor line in the old version of the file.",
"to" : "The comment's anchor line in the new version of the file. If the 'from' line is also provided, this value will be removed."
},
"created_on" : "date-time",
"links" : {
"code" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"pullrequest" : {
"type" : "Required string",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"comment_count" : "The number of comments for a specific pull request.",
"updated_on" : "The ISO8601 timestamp the request was last updated.",
"reason" : "Explains why a pull request was declined. This field is only applicable to pull requests in rejected state.",
"author" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"destination" : {
"commit" : {
"hash" : "string"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"branch" : {
"default_merge_strategy" : "The default merge strategy, when this endpoint is the destination of the pull request.",
"name" : "string",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
}
},
"source" : {
"commit" : {
"hash" : "string"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"branch" : {
"default_merge_strategy" : "The default merge strategy, when this endpoint is the destination of the pull request.",
"name" : "string",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
}
},
"title" : "Title of the pull request.",
"reviewers" : [ {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
} ],
"task_count" : "The number of open tasks for a specific pull request.",
"closed_by" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"rendered" : {
"reason" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"description" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"title" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
}
},
"created_on" : "The ISO8601 timestamp the request was created.",
"links" : {
"comments" : {
"name" : "string",
"href" : "uri"
},
"activity" : {
"name" : "string",
"href" : "uri"
},
"approve" : {
"name" : "string",
"href" : "uri"
},
"merge" : {
"name" : "string",
"href" : "uri"
},
"decline" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"diff" : {
"name" : "string",
"href" : "uri"
},
"diffstat" : {
"name" : "string",
"href" : "uri"
}
},
"close_source_branch" : "A boolean flag indicating if merging the pull request closes the source branch.",
"id" : "The pull request's unique ID. Note that pull request IDs are only unique within their associated repository.",
"state" : "The pull request's current status.",
"merge_commit" : {
"hash" : "string"
},
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
}
}
Creates a new repository.
Note: In order to set the project for the newly created repository,
pass in either the project key or the project UUID as part of the
request body as shown in the examples below:
The project must be assigned for all repositories. If the project is not provided,
the repository is automatically assigned to the oldest project in the workspace.
Note: In the examples above, the workspace ID teamsinspace
,
and/or the repository name hablanding
can be replaced by UUIDs.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The repository that is to be created. Note that most object elements are optional. Elements "owner" and "full_name" are ignored as the URL implies them.
Type: object
{
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
}
Creates a new webhook on the specified repository.
Note that this call requires the webhook scope, as well as any scope
that applies to the events that the webhook subscribes to. In the
example above that means: webhook
, repository
and issue
.
Also note that the url
must properly resolve and cannot be an
internal, non-routed address.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Creates a new snippet under the authenticated user's account.
Snippets can contain multiple files. Both text and binary files are
supported.
Snippets are created with a multipart POST. Both multipart/form-data
and multipart/related
are supported. Both allow the creation of
snippets with both meta data (title, etc), as well as multiple text
and binary files.
The main difference is that multipart/related
can use rich encoding
for the meta data (currently JSON).
The new snippet object.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "boolean",
"creator" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"created_on" : "date-time",
"id" : "integer",
"title" : "string",
"scm" : "The DVCS used to store the snippet."
}
Creates a new comment.
The only required field in the body is content.raw
.
To create a threaded reply to an existing comment, include parent.id
.
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The contents of the new comment.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "boolean",
"creator" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"created_on" : "date-time",
"id" : "integer",
"title" : "string",
"scm" : "The DVCS used to store the snippet."
}
Creates a new tag in the specified repository.
The payload of the POST should consist of a JSON document that
contains the name of the tag and the target hash.
This endpoint does support using short hash prefixes for the commit
hash, but it may return a 400 response if the provided prefix is
ambiguous. Using a full commit hash is the preferred approach.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Type: object
{
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"date" : "The date that the tag was created, if available",
"tagger" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "The message associated with the tag, if available."
}
Identical to /snippets
, except that the new snippet will be
created under the workspace specified in the path parameter{workspace}
.
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The new snippet object.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "boolean",
"creator" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"created_on" : "date-time",
"id" : "integer",
"title" : "string",
"scm" : "The DVCS used to store the snippet."
}
Create a workspace level variable.
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The variable to create.
Type: object
{
"type" : "Required string",
"uuid" : "The UUID identifying the variable.",
"value" : "The value of the variable. If the variable is secured, this will be empty.",
"secured" : "If true, this variable will be treated as secured. The value will never be exposed in the logs or the REST API.",
"key" : "The unique name of the variable."
}
Creates a new webhook on the specified workspace.
Workspace webhooks are fired for events from all repositories contained
by that workspace.
Note that only owners can install webhooks on workspaces.
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Declines the pull request.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Delete an application property value stored against a repository.
The key of the Connect app.
Type: string
The name of the property.
Type: string
The repository.
Type: string
The repository container; either the workspace slug or the UUID in curly braces.
Type: string
Delete a branch in the specified repository.
The main branch is not allowed to be deleted and will return a 400
response.
The branch name should not include any prefixes (e.g.
refs/heads).
The name of the branch.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Deletes an existing branch restriction rule.
The restriction rule's id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Delete a repository cache.
The UUID of the cache to delete.
Type: string
The repository.
Type: string
The account.
Type: string
Delete an application property value stored against a commit.
The key of the Connect app.
Type: string
The commit.
Type: string
The name of the property.
Type: string
The repository.
Type: string
The repository container; either the workspace slug or the UUID in curly braces.
Type: string
Deletes a single Report matching the provided ID.
The commit the report belongs to.
Type: string
The repository.
Type: string
Either the uuid or external-id of the report.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Deletes a single Annotation matching the provided ID.
Either the uuid or external-id of the annotation.
Type: string
The commit the annotation belongs to.
Type: string
The repository.
Type: string
Either the uuid or external-id of the annotation.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
This deletes a deploy key from a repository.
The key ID matching the deploy key.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Delete a deployment environment level variable.
The environment.
Type: string
The repository.
Type: string
The UUID of the variable to delete.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Deletes the specified download artifact from the repository.
Name of the file.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Delete an environment
The environment UUID.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Deletes the specified issue. This requires write access to the
repository.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Delete an attachment for an issue
The issue id
Type: string
Path to the file.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Deletes the specified comment.
The id of the comment.
Type: integer
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The updated comment.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"parent" : "comment",
"deleted" : "boolean",
"inline" : {
"path" : "The path of the file this comment is anchored to.",
"from" : "The comment's anchor line in the old version of the file.",
"to" : "The comment's anchor line in the new version of the file. If the 'from' line is also provided, this value will be removed."
},
"created_on" : "date-time",
"links" : {
"code" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"issue" : {
"type" : "Required string",
"updated_on" : "date-time",
"edited_on" : "date-time",
"kind" : "string. Possible values: bug | enhancement | proposal | task",
"reporter" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"title" : "string",
"priority" : "string. Possible values: trivial | minor | major | critical | blocker",
"version" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"component" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"milestone" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"created_on" : "date-time",
"links" : {
"comments" : {
"name" : "string",
"href" : "uri"
},
"attachments" : {
"name" : "string",
"href" : "uri"
},
"watch" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"vote" : {
"name" : "string",
"href" : "uri"
}
},
"votes" : "integer",
"id" : "integer",
"assignee" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"state" : "string. Possible values: new | open | resolved | on hold | invalid | duplicate | wontfix | closed"
}
}
Delete a repository level known host.
The UUID of the known host to delete.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Delete a schedule.
The repository.
Type: string
The uuid of the schedule.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Delete the repository SSH key pair.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Delete a repository level variable.
The repository.
Type: string
The UUID of the variable to delete.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Deletes this project. This is an irreversible operation.
You cannot delete a project that still contains repositories.
To delete the project, delete
or transfer the repositories first.
The project in question. This is the actual key
assigned
to the project.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Delete an application property value stored against a pull request.
The key of the Connect app.
Type: string
The name of the property.
Type: string
The pull request ID.
Type: string
The repository.
Type: string
The repository container; either the workspace slug or the UUID in curly braces.
Type: string
Deletes a specific pull request comment.
The id of the comment.
Type: integer
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Deletes the repository. This is an irreversible operation.
This does not affect its forks.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
If a repository has been moved to a new location, use this parameter to
show users a friendly message in the Bitbucket UI that the repository
has moved to a new location. However, a GET to this endpoint will still
return a 404.
Type: string
Deletes the specified webhook subscription from the given
repository.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
Installed webhook's ID
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Deletes a snippet and returns an empty response.
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Deletes a snippet comment.
Comments can only be removed by their author.
The id of the comment.
Type: integer
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Deletes the snippet.
Note that this only works for versioned URLs that point to the latest
commit of the snippet. Pointing to an older commit results in a 405
status code.
To delete a snippet, regardless of whether or not concurrent changes
are being made to it, use DELETE /snippets/{encoded_id}
instead.
The snippet id.
Type: string
A commit revision (SHA1).
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Deletes a specific SSH public key from a user's account
The SSH key's UUID value.
Type: string
This can either be the UUID of the account, surrounded by curly-braces, for
example: {account UUID}
, OR an Atlassian Account ID.
Type: string
Delete a tag in the specified repository.
For Git, the tag name should not include any prefixes (e.g. refs/tags).
For Mercurial, this adds a commit to the main branch that removes the
specified tag.
The name of the tag.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Delete an application property value stored against a user.
The key of the Connect app.
Type: string
The name of the property.
Type: string
Either the UUID of the account surrounded by curly-braces, for example {account UUID}
, OR an Atlassian Account ID.
Type: string
Delete a workspace level variable.
The UUID of the variable to delete.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Deletes the specified webhook subscription from the given workspace.
Installed webhook's ID
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
A POST request to this endpoint initiates a new background celery task that archives the repo's issues.
When the job has been accepted, it will return a 202 (Accepted) along with a unique url to this job in the
'Location' response header. This url is the endpoint for where the user can obtain their zip files."
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The options to apply to the export. Available options include project_key
and project_name
which, if specified, are used as the project key and name in the exported Jira json format. Option send_email
specifies whether an email should be sent upon export result. Option include_attachments
specifies whether attachments are included in the export.
Type: object
{
"project_key" : "string",
"send_email" : "boolean",
"type" : "Required string",
"project_name" : "string",
"include_attachments" : "boolean"
}
Creates a new fork of the specified repository.
To create a fork, specify the workspace explicitly as part of the
request body
To fork a repository into the same workspace, also specify a new name
.
When you specify a value for name
, it will also affect the slug
.
The slug
is reflected in the repository URL of the new fork. It is
derived from name
by substituting non-ASCII characters, removes
whitespace, and changes characters to lower case. For example,My repo
would turn into my_repo
.
You need contributor access to create new forks within a workspace.
By default the fork inherits most of its properties from the parent.
However, since the optional POST body document follows the normalrepository
JSON schema and you can override the new fork's
properties.
Properties that can be overridden include:
is_private=False
would fail)is_private
true
)Properties that cannot be modified include:
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
A repository object. This can be left blank.
Type: object
{
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
}
Retrieve an application property value stored against a repository.
The key of the Connect app.
Type: string
The name of the property.
Type: string
The repository.
Type: string
The repository container; either the workspace slug or the UUID in curly braces.
Type: string
Returns a branch object within the specified repository.
This call requires authentication. Private repositories require the
caller to authenticate with an account that has appropriate
authorization.
For Git, the branch name should not include any prefixes (e.g.
refs/heads).
The name of the branch.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a specific branch restriction rule.
The restriction rule's id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Return the branching model as applied to the repository. This view is
read-only. The branching model settings can be changed using the
settings API.
The returned object:
development
property. development.branch
containsdevelopment
branch. development.branch
will not be presentproduction
property. production
will notproduction
is disabled.production.branch
contains the actual branch object that isproduction
branch. production.branch
willbranch_types
array which contains all enabled branchThis can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Return the branching model configuration for a repository. The returned
object:
development
property for the development branch.production
property for the production branch. Thebranch_types
contains all the branch types.This is the raw configuration for the branching model. A client
wishing to see the branching model with its actual current branches may
find the active model API more useful.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the specified build status for a commit.
The commit's SHA1.
Type: string
The build status' unique key
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Retrieve the URI of the content of the specified cache.
The UUID of the cache.
Type: string
The repository.
Type: string
The account.
Type: string
Returns the specified commit.
The commit's SHA1.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Retrieve an application property value stored against a commit.
The key of the Connect app.
Type: string
The commit.
Type: string
The name of the property.
Type: string
The repository.
Type: string
The repository container; either the workspace slug or the UUID in curly braces.
Type: string
Returns the specified commit comment.
The id of the comment.
Type: integer
The commit's SHA1.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a single Report matching the provided ID.
The commit the report belongs to.
Type: string
The repository.
Type: string
Either the uuid or external-id of the report.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Returns a single Annotation matching the provided ID.
Either the uuid or external-id of the annotation.
Type: string
The commit the report belongs to.
Type: string
The repository.
Type: string
Either the uuid or external-id of the report.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Returns the best common ancestor between two commits, specified in a revspec
of 2 commits (e.g. 3a8b42..9ff173).
If more than one best common ancestor exists, only one will be returned. It is
unspecified which will be returned.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
A commit range using double dot notation (e.g. 3a8b42..9ff173
).
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the specified issue tracker component object.
The component's id
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
This operation has no parameters
Returns details about a specific one of the authenticated user's
email addresses.
Details describe whether the address has been confirmed by the user and
whether it is the user's primary address or not.
Returns the specified reviewer.
This can be used to test whether a user is among the repository's
default reviewers list. A 404 indicates that that specified user is not
a default reviewer.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the username or the UUID of the default reviewer,
surrounded by curly-braces, for example: {account UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the deploy key belonging to a specific key.
The key ID matching the deploy key.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Retrieve a deployment
The deployment UUID.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Return a redirect to the contents of a download artifact.
This endpoint returns the actual file contents and not the artifact's
metadata.
Name of the file.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Retrieve an environment
The environment UUID.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
This endpoints is used to retrieve the contents of a single file,
or the contents of a directory at a specified revision.
When path
points to a file, this endpoint returns the raw contents.
The response's Content-Type is derived from the filename
extension (not from the contents). The file contents are not processed
and no character encoding/recoding is performed and as a result no
character encoding is included as part of the Content-Type.
The Content-Disposition
header will be "attachment" to prevent
browsers from running executable files.
If the file is managed by LFS, then a 301 redirect pointing to
Atlassian's media services platform is returned.
The response includes an ETag that is based on the contents of the file
and its attributes. This means that an empty __init__.py
always
returns the same ETag, regardless on the directory it lives in, or the
commit it is on.
When the request for a file path includes the query parameter?format=meta
, instead of returning the file's raw contents, Bitbucket
instead returns the JSON object describing the file's properties:
File objects contain an attributes
element that contains a list of
possible modifiers. Currently defined values are:
link
-- indicates that the entry is a symbolic link. The contentsexecutable
-- indicates that the file has the executable bit set.subrepository
-- indicates that the entry points to a submodule orbinary
-- indicates whether Bitbucket thinks the file is binary.This endpoint can provide an alternative to how a HEAD request can be
used to check for the existence of a file, or a file's size without
incurring the overhead of receiving its full contents.
When path
points to a directory instead of a file, the response is a
paginated list of directory and file objects in the same order as the
underlying SCM system would return them.
When listing the contents of the repo's root directory, the use of a
trailing slash at the end of the URL is required.
The response by default is not recursive, meaning that only the direct contents of
a path are returned. The response does not recurse down into
subdirectories. In order to "walk" the entire directory tree, the
client can either parse each response and follow the self
links of eachcommit_directory
object, or can specify a max_depth
to recurse to.
The max_depth parameter will do a breadth-first search to return the contents of the subdirectories
up to the depth specified. Breadth-first search was chosen as it leads to the least amount of
file system operations for git. If the max_depth
parameter is specified to be too
large, the call will time out and return a 555.
Each returned object is either a commit_file
, or a commit_directory
,
both of which contain a path
element. This path is the absolute path
from the root of the repository. Each object also contains a commit
object which embeds the commit the file is on. Note that this is merely
the commit that was used in the URL. It is not the commit that last
modified the file.
Directory objects have 2 representations. Their self
link returns the
paginated contents of the directory. The meta
link on the other hand
returns the actual directory
object itself
Like most API endpoints, this API supports the Bitbucket
querying/filtering syntax and so you could filter a directory listing
to only include entries that match certain criteria. For instance, to
list all binary files over 1kb use the expression:
size > 1024 and attributes = "binary"
which after urlencoding yields the query string:
?q=size%3E1024+and+attributes%3D%22binary%22
To change the ordering of the response, use the ?sort
parameter:
.../src/eefd5ef/?sort=-size
See filtering and sorting for more
details.
The commit's SHA1.
Type: string
Path to the file.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
If 'meta' is provided, returns the (json) meta data for the contents of the file. If 'rendered' is provided, returns the contents of a non-binary file in HTML-formatted rendered markup. Since Git does not generally track what text encoding scheme is used, this endpoint attempts to detect the most appropriate character encoding. While usually correct, determining the character encoding can be ambiguous which in exceptional cases can lead to misinterpretation of the characters. As such, the raw element in the response object should not be treated as equivalent to the file's actual contents.
Type: string
Potential values: meta, rendered
If provided, returns the contents of the repository and its subdirectories recursively until the specified max_depth of nested directories. When omitted, this defaults to 1.
Type: integer
Optional filter expression as per filtering and sorting.
Type: string
Optional sorting parameter as per filtering and sorting.
Type: string
Returns the specified issue.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the contents of the specified file attachment.
Note that this endpoint does not return a JSON response, but instead
returns a redirect pointing to the actual file that in turn will return
the raw contents.
The redirect URL contains a one-time token that has a limited lifetime.
As a result, the link should not be persisted, stored, or shared.
The issue id
Type: string
Path to the file.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the specified issue change object.
This resource is only available on repositories that have the issue
tracker enabled.
The issue change id
Type: string
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the specified issue comment object.
The id of the comment.
Type: integer
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the specified issue tracker version object.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
The version's id
Type: integer
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the specified issue tracker milestone object.
The milestone's id
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Produces a raw patch for a single commit (diffed against its first
parent), or a patch-series for a revspec of 2 commits (e.g.3a8b42..9ff173
where the first commit represents the source and the
second commit the destination).
In case of the latter (diffing a revspec), a patch series is returned
for the commits on the source branch (3a8b42
and its ancestors in
our example). For Mercurial, a single patch is returned that combines
the changes of all commits on the source branch.
While similar to diffs, patches:
path=foo/bar.py
query parameterThe raw patch is returned as-is, in whatever encoding the files in the
repository use. It is not decoded into unicode. As such, the
content-type is text/plain
.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
A commit SHA (e.g. 3a8b42
) or a commit range using double dot
notation (e.g. 3a8b42..9ff173
).
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Retrieve a specified pipeline
The pipeline UUID.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Retrieve the repository pipelines configuration.
The repository.
Type: string
The account.
Type: string
Retrieve a repository level known host.
The UUID of the known host to retrieve.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Retrieve a schedule by its UUID.
The repository.
Type: string
The uuid of the schedule.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Retrieve the repository SSH key pair excluding the SSH private key. The private key is a write only field and will never be exposed in the logs or the REST API.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Retrieve a given step of a pipeline.
The UUID of the pipeline.
Type: string
The repository.
Type: string
The UUID of the step.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Retrieve the log file for a given step of a pipeline.
This endpoint supports (and encourages!) the use of HTTP Range requests to deal with potentially very large log files.
The UUID of the pipeline.
Type: string
The repository.
Type: string
The UUID of the step.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Retrieve a repository level variable.
The repository.
Type: string
The UUID of the variable to retrieve.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Returns the requested project.
The project in question. This is the actual key
assigned
to the project.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the specified pull request.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a paginated list of the pull request's activity log.
This handler serves both a v20 and internal endpoint. The v20 endpoint
returns reviewer comments, updates, approvals and request changes. The internal
endpoint includes those plus tasks and attachments.
Comments created on a file or a line of code have an inline property.
Updates include a state property of OPEN, MERGED, or DECLINED.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Retrieve an application property value stored against a pull request.
The key of the Connect app.
Type: string
The name of the property.
Type: string
The pull request ID.
Type: string
The repository.
Type: string
The repository container; either the workspace slug or the UUID in curly braces.
Type: string
Returns a specific pull request comment.
The id of the comment.
Type: integer
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Redirects to the repository diffstat
with the revspec that corresponds to the pull request.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
When merging a pull request takes too long, the client receives a
task ID along with a 202 status code. The task ID can be used in a call
to this endpoint to check the status of a merge task.
If the merge task is not yet finished, a PENDING status will be returned.
If the merge was successful, a SUCCESS status will be returned.
If the merge task failed, an error will be returned.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
ID of the merge task
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Redirects to the repository patch
with the revspec that corresponds to pull request.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the object describing this repository.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the webhook with the specified id installed on the specified
repository.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
Installed webhook's ID
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
This endpoint redirects the client to the directory listing of the
root directory on the main branch.
This is equivalent to directly hitting
/2.0/repositories/{username}/{repo_slug}/src/{commit}/{path}
without having to know the name or SHA1 of the repo's main branch.
To create new commits, POST to this endpoint
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Instead of returning the file's contents, return the (json) meta data for it.
Type: string
Potential values: meta
Retrieves a single snippet.
Snippets support multiple content types:
The default content type of the response is application/json
.
Since JSON is always utf-8
, it cannot reliably contain file contents
for files that are not text. Therefore, JSON snippet documents only
contain the filename and links to the file contents.
This means that in order to retrieve all parts of a snippet, N+1
requests need to be made (where N is the number of files in the
snippet).
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the changes made on this snippet in this commit.
The snippet id.
Type: string
The commit's SHA1.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the diff of the specified commit against its first parent.
Note that this resource is different in functionality from the patch
resource.
The differences between a diff and a patch are:
path=foo/bar.py
query param to filter theNote that the character encoding of the contents of the diff is
unspecified as Git does not track this, making it hard for
Bitbucket to reliably determine this.
The snippet id.
Type: string
A revspec expression. This can simply be a commit SHA1, a ref name, or a compare expression like staging..production
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
When used, only one the diff of the specified file will be returned.
Type: string
Returns the specific snippet comment.
The id of the comment.
Type: integer
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the patch of the specified commit against its first
parent.
Note that this resource is different in functionality from the diff
resource.
The differences between a diff and a patch are:
path=foo/bar.py
query param to filter theNote that the character encoding of the contents of the patch is
unspecified as Git does not track this, making it hard for
Bitbucket to reliably determine this.
The snippet id.
Type: string
A revspec expression. This can simply be a commit SHA1, a ref name, or a compare expression like staging..production
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Retrieves the raw contents of a specific file in the snippet. TheContent-Disposition
header will be "attachment" to avoid issues with
malevolent executable files.
The file's mime type is derived from its filename and returned in theContent-Type
header.
Note that for text files, no character encoding is included as part of
the content type.
The snippet id.
Type: string
A commit revision (SHA1).
Type: string
Path to the file.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Convenience resource for getting to a snippet's raw files without the
need for first having to retrieve the snippet itself and having to pull
out the versioned file links.
The snippet id.
Type: string
Path to the file.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Identical to GET /snippets/encoded_id
, except that this endpoint
can be used to retrieve the contents of the snippet as it was at an
older revision, while /snippets/encoded_id
always returns the
snippet's current revision.
Note that only the snippet's file contents are versioned, not its
meta data properties like the title.
Other than that, the two endpoints are identical in behavior.
The snippet id.
Type: string
A commit revision (SHA1).
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a specific SSH public key belonging to a user.
The SSH key's UUID value.
Type: string
This can either be the UUID of the account, surrounded by curly-braces, for
example: {account UUID}
, OR an Atlassian Account ID.
Type: string
Returns the specified tag.
The name of the tag.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Gets the public information associated with a user account.
If the user's profile is private, location
, website
andcreated_on
elements are omitted.
Note that the user object returned by this operation is changing significantly, due to privacy changes.
See the announcement for details.
This can either be the UUID of the account, surrounded by curly-braces, for
example: {account UUID}
, OR an Atlassian Account ID.
Type: string
Retrieve an application property value stored against a user.
The key of the Connect app.
Type: string
The name of the property.
Type: string
Either the UUID of the account surrounded by curly-braces, for example {account UUID}
, OR an Atlassian Account ID.
Type: string
Check whether the authenticated user has voted for this issue.
A 204 status code indicates that the user has voted, while a 404
implies they haven't.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Indicated whether or not the authenticated user is watching this
issue.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Used to check if the current user is watching a specific snippet.
Returns 204 (No Content) if the user is watching the snippet and 404 if
not.
Hitting this endpoint anonymously always returns a 404.
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
This operation has no parameters
Returns the requested workspace.
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns an object for the repository permission of each user in the
requested repository.
Permissions returned are effective permissions: the highest level of
permission the user has. This does not distinguish between direct and
indirect (group) privileges.
Only users with admin permission for the repository may access this resource.
Permissions can be:
admin
write
read
Results may be further filtered or sorted
by user, or permission by adding the following query string parameters:
q=permission>"read"
sort=user.display_name
Note that the query parameter values need to be URL escaped so that =
would become %3D
.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
Name of a response property sort the result by as per
filtering and sorting.
Type: string
Returns the workspace membership, which includes
a User
object for the member and a Workspace
object
for the requested workspace.
Member's UUID or Atlassian ID.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Retrieve a workspace level variable.
The UUID of the variable to retrieve.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Returns the webhook with the specified id installed on the given
workspace.
Installed webhook's ID
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
A POST request to this endpoint will import the zip file given by the archive parameter into the repository. All
existing issues will be deleted and replaced by the contents of the imported zip file.
When the import job is accepted, here is example output:
< HTTP/1.1 202 Accepted
{
"type": "issue_job_status",
"status": "ACCEPTED",
"phase": "Attachments",
"total": 15,
"count": 0,
"percent": 0
}
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a paginated list of all branch restrictions on the
repository.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Branch restrictions of this type
Type: string
Branch restrictions applied to branches of this pattern
Type: string
Returns the branches and tags in the repository.
By default, results will be in the order the underlying source control system returns them and identical to
the ordering one sees when running "$ git show-ref". Note that this follows simple
lexical ordering of the ref names.
This can be undesirable as it does apply any natural sorting semantics, meaning for instance that refs are
sorted ["branch1", "branch10", "branch2", "v10", "v11", "v9"] instead of ["branch1", "branch2",
"branch10", "v9", "v10", "v11"].
Sorting can be changed using the ?sort= query parameter. When using ?sort=name to explicitly sort on ref name,
Bitbucket will apply natural sorting and interpret numerical values as numbers instead of strings.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
Field by which the results should be sorted as per
filtering and sorting. The name
field is handled specially for refs in that, if specified as the sort field, it
uses a natural sort order instead of the default lexicographical sort order. For example,
it will return ['1.1', '1.2', '1.10'] instead of ['1.1', '1.10', '1.2'].
Type: string
Retrieve the repository pipelines caches.
The repository.
Type: string
The account.
Type: string
Returns the commit's comments.
This includes both global and inline comments.
The default sorting is oldest to newest and can be overridden with
the sort
query parameter.
The commit's SHA1.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
Field by which the results should be sorted as per
filtering and sorting.
Type: string
Returns a paginated list of Annotations for a specified report.
The commit for which to retrieve reports.
Type: string
The repository.
Type: string
Uuid or external-if of the report for which to get annotations for.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Returns a paginated list of Reports linked to this commit.
The commit for which to retrieve reports.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Returns all statuses (e.g. build results) for a specific commit.
The commit's SHA1.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
Field by which the results should be sorted as per
filtering and sorting.
Defaults to created_on
.
Type: string
Returns all statuses (e.g. build results) for the given pull
request.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
Field by which the results should be sorted as per
filtering and sorting.
Defaults to created_on
.
Type: string
These are the repository's commits. They are paginated and returned
in reverse chronological order, similar to the output of git log
.
Like these tools, the DAG can be filtered.
Returns all commits in the repo in topological order (newest commit
first). All branches and tags are included (similar togit log --all
).
Returns all commits in the repo that are not on master
(similar to git log --all ^master
).
Returns all commits that are on refs foo
or bar
, but not on fu
orfubar
(similar to git log foo bar ^fu ^fubar
).
An optional path
parameter can be specified that will limit the
results to commits that affect that path. path
can either be a file
or a directory. If a directory is specified, commits are returned that
have modified any file in the directory tree rooted by path
. It is
important to note that if the path
parameter is specified, the commits
returned by this endpoint may no longer be a DAG, parent commits that
do not modify the path will be omitted from the response.
Returns all commits that are on refs foo
or bar
, but not on master
that changed the file README.md.
Returns all commits that are on refs foo
or bar
, but not on master
that changed to a file in any file in the directory src or its children.
Because the response could include a very large number of commits, it
is paginated. Follow the 'next' link in the response to navigate to the
next page of commits. As with other paginated resources, do not
construct your own links.
When the include and exclude parameters are more than can fit in a
query string, clients can use a x-www-form-urlencoded
POST instead.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Identical to GET /repositories/{workspace}/{repo_slug}/commits
,
except that POST allows clients to place the include and exclude
parameters in the request body to avoid URL length issues.
Note that this resource does NOT support new commit creation.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a paginated list of commits that modified the specified file.
Commits are returned in reverse chronological order. This is roughly
equivalent to the following commands:
$ git log --follow --date-order
$ hg log --follow
By default, Bitbucket will follow renames and the path name in the
returned entries reflects that. This can be turned off using the?renames=false
query parameter.
Results are returned in descending chronological order by default, and
like most endpoints you can
filter and sort the response to
only provide exactly the data you want.
The commit's SHA1.
Type: string
Path to the file.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
When true
, Bitbucket will follow the history of the file across
renames (this is the default behavior). This can be turned off by
specifying false
.
Type: string
Name of a response property sort the result by as per
filtering and sorting.
Type: string
These are the repository's commits. They are paginated and returned
in reverse chronological order, similar to the output of git log
.
Like these tools, the DAG can be filtered.
Returns all commits on rev master
(similar to git log master
).
Returns all commits on ref dev
or foo
, except those that are reachable onmaster
(similar to git log dev foo ^master
).
An optional path
parameter can be specified that will limit the
results to commits that affect that path. path
can either be a file
or a directory. If a directory is specified, commits are returned that
have modified any file in the directory tree rooted by path
. It is
important to note that if the path
parameter is specified, the commits
returned by this endpoint may no longer be a DAG, parent commits that
do not modify the path will be omitted from the response.
Returns all commits that are on refs dev
or foo
or bar
, but not on master
that changed the file README.md.
Returns all commits that are on refs dev
or foo
, but not on master
that changed to a file in any file in the directory src or its children.
Because the response could include a very large number of commits, it
is paginated. Follow the 'next' link in the response to navigate to the
next page of commits. As with other paginated resources, do not
construct your own links.
When the include and exclude parameters are more than can fit in a
query string, clients can use a x-www-form-urlencoded
POST instead.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
The commit's SHA1.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Identical to GET /repositories/{workspace}/{repo_slug}/commits/{revision}
,
except that POST allows clients to place the include and exclude
parameters in the request body to avoid URL length issues.
Note that this resource does NOT support new commit creation.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
The commit's SHA1.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the components that have been defined in the issue tracker.
This resource is only available on repositories that have the issue
tracker enabled.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
This operation has no parameters
Returns the repository's default reviewers.
These are the users that are automatically added as reviewers on every
new pull request that is created.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns all deploy-keys belonging to a repository.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Find deployment environment level variables.
The environment.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Find deployments
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Returns a list of download links associated with the repository.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Find environments
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Returns all attachments for this issue.
This returns the files' meta data. This does not return the files'
actual contents.
The files are always ordered by their upload date.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the list of all changes that have been made to the specified
issue. Changes are returned in chronological order with the oldest
change first.
Each time an issue is edited in the UI or through the API, an immutable
change record is created under the /issues/123/changes
endpoint. It
also has a comment associated with the change.
Note that this operation is changing significantly, due to privacy changes.
See the announcement
for details.
Changes support filtering and sorting that
can be used to search for specific changes.
This resource is only available on repositories that have the issue
tracker enabled.
N.B.
The changes.assignee
and changes.assignee_account_id
fields are not
a user
object. Instead, they contain the raw username
andaccount_id
of the user. This is to protect the integrity of the audit
log even after a user account gets deleted.
The changes.assignee
field is deprecated will disappear in the
future. Use changes.assignee_account_id
instead.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response. See
filtering and sorting for details.
Type: string
Name of a response property to sort results. See
filtering and sorting
for details.
Type: string
Returns a paginated list of all comments that were made on the
specified issue.
The default sorting is oldest to newest and can be overridden with
the sort
query parameter.
This endpoint also supports filtering and sorting of the results. See
filtering and sorting for more details.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
Returns the versions that have been defined in the issue tracker.
This resource is only available on repositories that have the issue
tracker enabled.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the issues in the issue tracker.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the milestones that have been defined in the issue tracker.
This resource is only available on repositories that have the issue
tracker enabled.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a list of all open branches within the specified repository.
Results will be in the order the source control manager returns them.
Branches support [filtering and sorting](/cloud/bitbucket/rest/intro/#filtering)
that can be used to search for specific branches.
By default, results will be in the order the underlying source control system returns them and identical to
the ordering one sees when running "$ hg branches" or "$ git branch --list". Note that this follows simple
lexical ordering of the ref names.
This can be undesirable as it does apply any natural sorting semantics, meaning for instance that tags are
sorted ["v10", "v11", "v9"] instead of ["v9", "v10", "v11"].
Sorting can be changed using the ?q= query parameter. When using ?q=name to explicitly sort on ref name,
Bitbucket will apply natural sorting and interpret numerical values as numbers instead of strings.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
Field by which the results should be sorted as per
filtering and sorting. The name
field is handled specially for branches in that, if specified as the sort field, it
uses a natural sort order instead of the default lexicographical sort order. For example,
it will return ['branch1', 'branch2', 'branch10'] instead of ['branch1', 'branch10', 'branch2'].
Type: string
Find repository level known hosts.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Retrieve the executions of a given schedule.
The repository.
Type: string
The uuid of the schedule.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Retrieve the configured schedules for the given repository.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Find steps for the given pipeline.
The UUID of the pipeline.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Find repository level variables.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Find pipelines
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Returns a paginated list of all public repositories.
This endpoint also supports filtering and sorting of the results. See
filtering and sorting for more details.
Filter the results to include only repositories created on or
after this ISO-8601
timestamp. Example: YYYY-MM-DDTHH:mm:ss.sssZ
Type: string
Query string to narrow down the response as per filtering and sorting.role
parameter must also be specified.
Type: string
Filters the result based on the authenticated user's role on each repository.
Type: string
Potential values: admin, contributor, member, owner
Field by which the results should be sorted as per filtering and sorting.
Type: string
Returns a paginated list of the pull request's activity log.
This handler serves both a v20 and internal endpoint. The v20 endpoint
returns reviewer comments, updates, approvals and request changes. The internal
endpoint includes those plus tasks and attachments.
Comments created on a file or a line of code have an inline property.
Updates include a state property of OPEN, MERGED, or DECLINED.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Redirects to the repository diff
with the revspec that corresponds to the pull request.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a paginated list of the pull request's comments.
This includes both global, inline comments and replies.
The default sorting is oldest to newest and can be overridden with
the sort
query parameter.
This endpoint also supports filtering and sorting of the results. See
filtering and sorting for more
details.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a paginated list of the pull request's commits.
These are the commits that are being merged into the destination
branch when the pull requests gets accepted.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns all pull requests on the specified repository.
By default only open pull requests are returned. This can be controlled
using the state
query parameter. To retrieve pull requests that are
in one of multiple states, repeat the state
parameter for each
individual state.
This endpoint also supports filtering and sorting of the results. See
filtering and sorting for more details.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Only return pull requests that are in this state. This parameter can be repeated.
Type: string
Potential values: MERGED, SUPERSEDED, OPEN, DECLINED
Returns a paginated list of all pull requests as part of which this commit was reviewed. Pull Request Commit Links app must be installed first before using this API; installation automatically occurs when 'Go to pull request' is clicked from the web interface for a commit's details.
The SHA1 of the commit
Type: string
The repository; either the UUID in curly braces, or the slug
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces
Type: string
Returns all pull requests authored by the specified user.
By default only open pull requests are returned. This can be controlled
using the state
query parameter. To retrieve pull requests that are
in one of multiple states, repeat the state
parameter for each
individual state.
This endpoint also supports filtering and sorting of the results. See
filtering and sorting for more details.
This can either be the username of the pull request author, the author's UUID
surrounded by curly-braces, for example: {account UUID}
, or the author's Atlassian ID.
Type: string
Only return pull requests that are in this state. This parameter can be repeated.
Type: string
Potential values: MERGED, SUPERSEDED, OPEN, DECLINED
Returns a paginated list of all repositories owned by the specified
account or UUID.
The result can be narrowed down based on the authenticated user's role.
E.g. with ?role=contributor
, only those repositories that the
authenticated user has write access to are returned (this includes any
repo the user is an admin on, as that implies write access).
This endpoint also supports filtering and sorting of the results. See
filtering and sorting for more details.
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per filtering and sorting.
Type: string
Filters the result based on the authenticated user's role on each repository.
Type: string
Potential values: admin, contributor, member, owner
Field by which the results should be sorted as per filtering and sorting.
Type: string
Returns a paginated list of all the forks of the specified
repository.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per filtering and sorting.
Type: string
Filters the result based on the authenticated user's role on each repository.
Type: string
Potential values: admin, contributor, member, owner
Field by which the results should be sorted as per filtering and sorting.
Type: string
Returns an object for each repository the caller has explicit access
to and their effective permission — the highest level of permission the
caller has. This does not return public repositories that the user was
not granted any specific permission in, and does not distinguish between
direct and indirect privileges.
Permissions can be:
admin
write
read
Results may be further filtered or sorted by
repository or permission by adding the following query string
parameters:
q=repository.name="geordi"
or q=permission>"read"
sort=repository.name
Note that the query parameter values need to be URL escaped so that =
would become %3D
.
Query string to narrow down the response as per
filtering and sorting.
Type: string
Name of a response property sort the result by as per
filtering and sorting.
Type: string
Returns a paginated list of all the watchers on the specified
repository.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a paginated list of webhooks installed on this repository.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns the changes (commits) made on this snippet.
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Used to retrieve a paginated list of all comments for a specific
snippet.
This resource works identical to commit and pull request comments.
The default sorting is oldest to newest and can be overridden with
the sort
query parameter.
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns all snippets. Like pull requests, repositories and workspaces, the
full set of snippets is defined by what the current user has access to.
This includes all snippets owned by any of the workspaces the user is a member of,
or snippets by other users that the current user is either watching or has collaborated
on (for instance by commenting on it).
To limit the set of returned snippets, apply the?role=[owner|contributor|member]
query parameter where the roles are
defined as follows:
owner
: all snippets owned by the current usercontributor
: all snippets owned by, or watched by the current usermember
: created in a workspaces or watched by the current userWhen no role is specified, all public snippets are returned, as well as all
privately owned snippets watched or commented on.
The returned response is a normal paginated JSON list. This endpoint
only supports application/json
responses and nomultipart/form-data
or multipart/related
. As a result, it is not
possible to include the file contents.
Filter down the result based on the authenticated user's role (owner
, contributor
, or member
).
Type: string
Potential values: owner, contributor, member
Identical to /snippets
, except that the result is further filtered
by the snippet owner and only those that are owned by {workspace}
are
returned.
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Filter down the result based on the authenticated user's role (owner
, contributor
, or member
).
Type: string
Potential values: owner, contributor, member
Returns a paginated list of the user's SSH public keys.
This can either be the UUID of the account, surrounded by curly-braces, for
example: {account UUID}
, OR an Atlassian Account ID.
Type: string
Returns a paginated list of all valid webhook events for the
specified entity.
The team and user webhooks are deprecated, and you should use workspace instead.
For more information, see the announcement.
This is public data that does not require any scopes or authentication.
A resource or subject type.
Type: string
Potential values: workspace, user, repository, team
Returns the tags in the repository.
By default, results will be in the order the underlying source control system returns them and identical to
the ordering one sees when running "$ hg tags" or "$ git tag --list". Note that this follows simple
lexical ordering of the ref names.
This can be undesirable as it does apply any natural sorting semantics, meaning for instance that tags are
sorted ["v10", "v11", "v9"] instead of ["v9", "v10", "v11"].
Sorting can be changed using the ?sort= query parameter. When using ?sort=name to explicitly sort on ref name,
Bitbucket will apply natural sorting and interpret numerical values as numbers instead of strings.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
Field by which the results should be sorted as per
filtering and sorting. The name
field is handled specially for tags in that, if specified as the sort field, it
uses a natural sort order instead of the default lexicographical sort order. For example,
it will return ['1.1', '1.2', '1.10'] instead of ['1.1', '1.10', '1.2'].
Type: string
Returns the list of members in a workspace
and their permission levels.
Permission can be:
owner
collaborator
member
Results may be further filtered by
permission by adding the following query string parameters:
q=permission="owner"
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
Returns the list of projects in this workspace.
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns an object for each repository permission for all of a
workspace's repositories.
Permissions returned are effective permissions: the highest level of
permission the user has. This does not distinguish between direct and
indirect (group) privileges.
Only users with admin permission for the team may access this resource.
Permissions can be:
admin
write
read
Results may be further filtered or sorted
by repository, user, or permission by adding the following query string
parameters:
q=repository.name="geordi"
or q=permission>"read"
sort=user.display_name
Note that the query parameter values need to be URL escaped so that =
would become %3D
.
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Query string to narrow down the response as per
filtering and sorting.
Type: string
Name of a response property sort the result by as per
filtering and sorting.
Type: string
Returns all members of the requested workspace.
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Find workspace level variables.
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Returns a paginated list of webhooks installed on this workspace.
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Returns a list of workspaces accessible by the authenticated user.
Results may be further filtered or sorted by
workspace or permission by adding the following query string parameters:
q=slug="bbworkspace1"
or q=is_private=true
sort=created_on
Note that the query parameter values need to be URL escaped so that =
would become %3D
.
Query string to narrow down the response. See
filtering and sorting for details.
Type: string
Filters the workspaces based on the authenticated user's role on each workspace.
* **member**: returns a list of all the workspaces which the caller is a member of
at least one workspace group or repository
* **collaborator**: returns a list of workspaces which the caller has write access
to at least one repository in the workspace
* **owner**: returns a list of workspaces which the caller has administrator access
Type: string
Potential values: owner, collaborator, member
Name of a response property to sort results. See
filtering and sorting
for details.
Type: string
Returns an object for each workspace the caller is a member of, and
their effective role - the highest level of privilege the caller has.
If a user is a member of multiple groups with distinct roles, only the
highest level is returned.
Permissions can be:
owner
collaborator
member
Results may be further filtered or sorted by
workspace or permission by adding the following query string parameters:
q=workspace.slug="bbworkspace1"
or q=permission="owner"
sort=workspace.slug
Note that the query parameter values need to be URL escaped so that =
would become %3D
.
Query string to narrow down the response. See
filtering and sorting for details.
Type: string
Name of a response property to sort results. See
filtering and sorting
for details.
Type: string
Merges the pull request.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The metadata that describes a pull request merge.
Type: object
{
"merge_strategy" : "The merge strategy that will be used to merge the pull request.",
"close_source_branch" : "Whether the source branch should be deleted. If this is not provided, we fallback to the value used when the pull request was created, which defaults to False",
"type" : "Required string",
"message" : "The commit message that will be used on the resulting commit."
}
Default value is false.
When set to true, runs merge asynchronously and
immediately returns a 202 with polling link to
the task-status API in the Location header.
When set to false, runs merge and waits for it to
complete, returning 200 when it succeeds. If the
duration of the merge exceeds a timeout threshold,
the API returns a 202 with polling link to the
task-status API in the Location header.
Type: boolean
Removes a default reviewer from the repository.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the username or the UUID of the default reviewer,
surrounded by curly-braces, for example: {account UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Remove change request for a pull request
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Remove vote for an issue
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Request changes for a pull request
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Endpoint to create and initiate a pipeline.
There are a couple of different options to initiate a pipeline, where the payload of the request will determine which type of pipeline will be instantiated.
One way to trigger pipelines is by specifying the branch for which you want to trigger a pipeline.
The specified branch will be used to determine which pipeline definition from the bitbucket-pipelines.yml
file will be applied to initiate the pipeline. The pipeline will then do a clone of the repository and checkout the latest revision of the specified branch.
You can initiate a pipeline for a specific commit and in the context of a specified reference (e.g. a branch, tag or bookmark).
The specified reference will be used to determine which pipeline definition from the bitbucket-pipelines.yml file will be applied to initiate the pipeline. The pipeline will clone the repository and then do a checkout the specified reference.
The following reference types are supported:
branch
named_branch
bookmark
tag
You can trigger a specific pipeline that is defined in your bitbucket-pipelines.yml
file for a specific commit.
In addition to the commit revision, you specify the type and pattern of the selector that identifies the pipeline definition. The resulting pipeline will then clone the repository and checkout the specified revision.
You can trigger a specific pipeline that is defined in your bitbucket-pipelines.yml
file for a specific commit in the context of a specified reference.
In addition to the commit revision, you specify the type and pattern of the selector that identifies the pipeline definition, as well as the reference information. The resulting pipeline will then clone the repository a checkout the specified reference.
In addition to triggering a custom pipeline that is defined in your bitbucket-pipelines.yml
file as shown in the examples above, you can specify variables that will be available for your build. In the request, provide a list of variables, specifying the following for each variable: key, value, and whether it should be secured or not (this field is optional and defaults to not secured).
You can also initiate a pipeline for a specific pull request.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The pipeline to initiate.
Type: object
{
"type" : "Required string",
"creator" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"build_seconds_used" : "The number of build seconds used by this pipeline.",
"created_on" : "The timestamp when the pipeline was created.",
"completed_on" : "The timestamp when the Pipeline was completed. This is not set if the pipeline is still in progress.",
"build_number" : "The build number of the pipeline.",
"trigger" : {
"type" : "Required string"
},
"state" : {
"type" : "Required string"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"uuid" : "The UUID identifying the pipeline.",
"target" : {
"type" : "Required string"
}
}
Search for code in the repositories of the specified team.
Note that searches can match in the file's text (content_matches
),
the path (path_matches
), or both.
You can use the same syntax for the search query as in the UI, e.g.
to only search within a specific repository:
Similar to other APIs, you can request more fields using afields
query parameter.
Try fields=%2Bvalues.*.*.*.*
to get an idea what's possible.
The search query
Type: string
The account to search in; either the username or the UUID in curly braces
Type: string
Search for code in the repositories of the specified user.
Note that searches can match in the file's text (content_matches
),
the path (path_matches
), or both.
You can use the same syntax for the search query as in the UI, e.g.
to only search within a specific repository:
Similar to other APIs, you can request more fields using afields
query parameter. E.g. to get some more information about
the repository of matched files (the %2B
is a URL-encoded +
):
Try fields=%2Bvalues.*.*.*.*
to get an idea what's possible.
The search query
Type: string
Either the UUID of the account surrounded by curly-braces, for example {account UUID}
, OR an Atlassian Account ID.
Type: string
Search for code in the repositories of the specified workspace.
Note that searches can match in the file's text (content_matches
),
the path (path_matches
), or both.
You can use the same syntax for the search query as in the UI, e.g.
to only search within a specific repository:
Similar to other APIs, you can request more fields using afields
query parameter. E.g. to get some more information about
the repository of matched files (the %2B
is a URL-encoded +
):
Try fields=%2Bvalues.*.*.*.*
to get an idea what's possible.
The search query
Type: string
The workspace to search in; either the slug or the UUID in curly braces
Type: string
Signal the stop of a pipeline and all of its steps that not have completed yet.
The UUID of the pipeline.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Stop watching this issue.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Used to stop watching a specific snippet. Returns 204 (No Content)
to indicate success.
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Redact the authenticated user's approval of the specified commit.
This operation is only available to users that have explicit access to
the repository. In contrast, just the fact that a repository is
publicly accessible to users does not give them the ability to approve
commits.
The commit's SHA1.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Redact the authenticated user's approval of the specified pull
request.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Update an application property value stored against a repository.
The key of the Connect app.
Type: string
The name of the property.
Type: string
The repository.
Type: string
The repository container; either the workspace slug or the UUID in curly braces.
Type: string
Updates an existing branch restriction rule.
Fields not present in the request body are ignored.
See POST
for details.
The restriction rule's id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The new version of the existing rule
Type: object
{
"type" : "Required string",
"branch_match_kind" : "Indicates how the restriction is matched against a branch. The default is `glob`.",
"branch_type" : "Apply the restriction to branches of this type. Active when `branch_match_kind` is `branching_model`. The branch type will be calculated using the branching model configured for the repository.",
"kind" : "The type of restriction that is being applied.",
"pattern" : "Apply the restriction to branches that match this pattern. Active when `branch_match_kind` is `glob`. Will be empty when `branch_match_kind` is `branching_model`.",
"groups" : [ {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"full_slug" : "The concatenation of the workspace's slug and the group's slug,\nseparated with a colon (e.g. `acme:developers`)\n",
"workspace" : {
"type" : "Required string",
"is_private" : "Indicates whether the workspace is publicly accessible, or whether it is\nprivate to the members and consequently only visible to members.\nNote that private workspaces cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the workspace.",
"links" : {
"projects" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"snippets" : {
"name" : "string",
"href" : "uri"
},
"members" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"owners" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"uuid" : "The workspace's immutable id.",
"slug" : "The short label that identifies this workspace."
},
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"slug" : "The \"sluggified\" version of the group's name. This contains only ASCII\ncharacters and can therefore be slightly different than the name"
} ],
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "The branch restriction status' id.",
"value" : "integer",
"users" : [ {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
} ]
}
Update the branching model configuration for a repository.
The development
branch can be configured to a specific branch or to
track the main branch. When set to a specific branch it must
currently exist. Only the passed properties will be updated. The
properties not passed will be left unchanged. A request without adevelopment
property will leave the development branch unchanged.
It is possible for the development
branch to be invalid. This
happens when it points at a specific branch that has been
deleted. This is indicated in the is_valid
field for the branch. It is
not possible to update the settings for development
if that
would leave the branch in an invalid state. Such a request will be
rejected.
The production
branch can be a specific branch, the main
branch or disabled. When set to a specific branch it must currently
exist. The enabled
property can be used to enable (true
) or
disable (false
) it. Only the passed properties will be updated. The
properties not passed will be left unchanged. A request without aproduction
property will leave the production branch unchanged.
It is possible for the production
branch to be invalid. This
happens when it points at a specific branch that has been
deleted. This is indicated in the is_valid
field for the branch. A
request that would leave production
enabled and invalid will be
rejected. It is possible to update production
and make it invalid if
it would also be left disabled.
The branch_types
property contains the branch types to be updated.
Only the branch types passed will be updated. All updates will be
rejected if it would leave the branching model in an invalid state.
For branch types this means that:
It is possible to store an invalid prefix if that branch type would be
left disabled. Only the passed properties will be updated. The
properties not passed will be left unchanged. Each branch type must
have a kind
property to identify it.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Used to update the current status of a build status object on the
specific commit.
This operation can also be used to change other properties of the
build status:
state
name
description
url
refname
The key
cannot be changed.
The commit's SHA1.
Type: string
The build status' unique key
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The updated build status object
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "An identifier for the build itself, e.g. BB-DEPLOY-1",
"description" : "A description of the build (e.g. \"Unit tests in Bamboo\")",
"links" : {
"commit" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
}
},
"state" : "Provides some indication of the status of this commit",
"uuid" : "The commit status' id.",
"key" : "An identifier for the status that's unique to\n its type (current \"build\" is the only supported type) and the vendor,\n e.g. BB-DEPLOY",
"refname" : "\nThe name of the ref that pointed to this commit at the time the status\nobject was created. Note that this the ref may since have moved off of\nthe commit. This optional field can be useful for build systems whose\nbuild triggers and configuration are branch-dependent (e.g. a Pipeline\nbuild).\nIt is legitimate for this field to not be set, or even apply (e.g. a\nstatic linting job).",
"url" : "A URL linking back to the vendor or build system, for providing more information about whatever process produced this status. Accepts context variables `repository` and `commit` that Bitbucket will evaluate at runtime whenever at runtime. For example, one could use https://foo.com/builds/{repository.full_name} which Bitbucket will turn into https://foo.com/builds/foo/bar at render time."
}
Update an application property value stored against a commit.
The key of the Connect app.
Type: string
The commit.
Type: string
The name of the property.
Type: string
The repository.
Type: string
The repository container; either the workspace slug or the UUID in curly braces.
Type: string
Create a new deploy key in a repository.
The same key needs to be passed in but the comment and label can change.
The key ID matching the deploy key.
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Update a deployment environment level variable.
The environment.
Type: string
The repository.
Type: string
The UUID of the variable to update.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The updated deployment variable.
Type: object
{
"type" : "Required string",
"uuid" : "The UUID identifying the variable.",
"value" : "The value of the variable. If the variable is secured, this will be empty.",
"secured" : "If true, this variable will be treated as secured. The value will never be exposed in the logs or the REST API.",
"key" : "The unique name of the variable."
}
Update an environment
The environment UUID.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
Modifies the issue.
Any field not present keeps its existing value.
Each time an issue is edited in the UI or through the API, an immutable
change record is created under the /issues/123/changes
endpoint. It
also has a comment associated with the change.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Updates the content of the specified issue comment. Note that only
the content.raw
field can be modified.
The id of the comment.
Type: integer
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The updated comment.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"parent" : "comment",
"deleted" : "boolean",
"inline" : {
"path" : "The path of the file this comment is anchored to.",
"from" : "The comment's anchor line in the old version of the file.",
"to" : "The comment's anchor line in the new version of the file. If the 'from' line is also provided, this value will be removed."
},
"created_on" : "date-time",
"links" : {
"code" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"issue" : {
"type" : "Required string",
"updated_on" : "date-time",
"edited_on" : "date-time",
"kind" : "string. Possible values: bug | enhancement | proposal | task",
"reporter" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"title" : "string",
"priority" : "string. Possible values: trivial | minor | major | critical | blocker",
"version" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"component" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"milestone" : {
"type" : "Required string",
"name" : "string",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer"
},
"created_on" : "date-time",
"links" : {
"comments" : {
"name" : "string",
"href" : "uri"
},
"attachments" : {
"name" : "string",
"href" : "uri"
},
"watch" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"vote" : {
"name" : "string",
"href" : "uri"
}
},
"votes" : "integer",
"id" : "integer",
"assignee" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"state" : "string. Possible values: new | open | resolved | on hold | invalid | duplicate | wontfix | closed"
}
}
Update the next build number that should be assigned to a pipeline. The next build number that will be configured has to be strictly higher than the current latest build number for this repository.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The build number to update.
Type: object
{
"type" : "Required string",
"next" : "The next number that will be used as build number."
}
Update the pipelines configuration for a repository.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The updated repository pipelines configuration.
Type: object
{
"type" : "Required string",
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"enabled" : "Whether Pipelines is enabled for the repository."
}
Update a repository level known host.
The UUID of the known host to update.
Type: string
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The updated known host.
Type: object
{
"type" : "Required string",
"public_key" : {
"type" : "Required string",
"key_type" : "The type of the public key.",
"md5_fingerprint" : "The MD5 fingerprint of the public key.",
"sha256_fingerprint" : "The SHA-256 fingerprint of the public key.",
"key" : "The base64 encoded public key."
},
"hostname" : "The hostname of the known host.",
"uuid" : "The UUID identifying the known host."
}
Update a schedule.
The repository.
Type: string
The uuid of the schedule.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The schedule to update.
Type: object
{
"type" : "Required string",
"updated_on" : "The timestamp when the schedule was updated.",
"created_on" : "The timestamp when the schedule was created.",
"selector" : {
"type" : "The type of selector.",
"pattern" : "The name of the matching pipeline definition."
},
"uuid" : "The UUID identifying the schedule.",
"cron_pattern" : "The cron expression that the schedule applies.",
"enabled" : "Whether the schedule is enabled.",
"target" : {
"type" : "Required string"
}
}
Create or update the repository SSH key pair. The private key will be set as a default SSH identity in your build container.
The repository.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The created or updated SSH key pair.
Type: object
{
"type" : "Required string",
"public_key" : "The SSH public key.",
"private_key" : "The SSH private key. This value will be empty when retrieving the SSH key pair."
}
Update a repository level variable.
The repository.
Type: string
The UUID of the variable to update.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The updated variable
Type: object
{
"type" : "Required string",
"uuid" : "The UUID identifying the variable.",
"value" : "The value of the variable. If the variable is secured, this will be empty.",
"secured" : "If true, this variable will be treated as secured. The value will never be exposed in the logs or the REST API.",
"key" : "The unique name of the variable."
}
Since this endpoint can be used to both update and to create a
project, the request body depends on the intent.
See the POST documentation for the project collection for an
example of the request body.
Note: The key
should not be specified in the body of request
(since it is already present in the URL). The name
is required,
everything else is optional.
See the POST documentation for the project collection for an
example of the request body.
Note: The key is not required in the body (since it is already in
the URL). The key may be specified in the body, if the intent is
to change the key itself. In such a scenario, the location of the
project is changed and is returned in the Location
header of the
response.
The project in question. This is the actual key
assigned
to the project.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Type: object
{
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
}
Mutates the specified pull request.
This can be used to change the pull request's branches or description.
Only open pull requests can be mutated.
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The pull request that is to be updated.
Type: object
{
"type" : "Required string",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"comment_count" : "The number of comments for a specific pull request.",
"updated_on" : "The ISO8601 timestamp the request was last updated.",
"reason" : "Explains why a pull request was declined. This field is only applicable to pull requests in rejected state.",
"author" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"destination" : {
"commit" : {
"hash" : "string"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"branch" : {
"default_merge_strategy" : "The default merge strategy, when this endpoint is the destination of the pull request.",
"name" : "string",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
}
},
"source" : {
"commit" : {
"hash" : "string"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"branch" : {
"default_merge_strategy" : "The default merge strategy, when this endpoint is the destination of the pull request.",
"name" : "string",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
}
},
"title" : "Title of the pull request.",
"reviewers" : [ {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
} ],
"task_count" : "The number of open tasks for a specific pull request.",
"closed_by" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"rendered" : {
"reason" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"description" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"title" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
}
},
"created_on" : "The ISO8601 timestamp the request was created.",
"links" : {
"comments" : {
"name" : "string",
"href" : "uri"
},
"activity" : {
"name" : "string",
"href" : "uri"
},
"approve" : {
"name" : "string",
"href" : "uri"
},
"merge" : {
"name" : "string",
"href" : "uri"
},
"decline" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"diff" : {
"name" : "string",
"href" : "uri"
},
"diffstat" : {
"name" : "string",
"href" : "uri"
}
},
"close_source_branch" : "A boolean flag indicating if merging the pull request closes the source branch.",
"id" : "The pull request's unique ID. Note that pull request IDs are only unique within their associated repository.",
"state" : "The pull request's current status.",
"merge_commit" : {
"hash" : "string"
},
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
}
Update an application property value stored against a pull request.
The key of the Connect app.
Type: string
The name of the property.
Type: string
The pull request ID.
Type: string
The repository.
Type: string
The repository container; either the workspace slug or the UUID in curly braces.
Type: string
Updates a specific pull request comment.
The id of the comment.
Type: integer
The id of the pull request.
Type: integer
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The contents of the updated comment.
Type: object
{
"type" : "Required string",
"updated_on" : "date-time",
"parent" : "comment",
"deleted" : "boolean",
"inline" : {
"path" : "The path of the file this comment is anchored to.",
"from" : "The comment's anchor line in the old version of the file.",
"to" : "The comment's anchor line in the new version of the file. If the 'from' line is also provided, this value will be removed."
},
"created_on" : "date-time",
"links" : {
"code" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"id" : "integer",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"content" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"pullrequest" : {
"type" : "Required string",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"comment_count" : "The number of comments for a specific pull request.",
"updated_on" : "The ISO8601 timestamp the request was last updated.",
"reason" : "Explains why a pull request was declined. This field is only applicable to pull requests in rejected state.",
"author" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"destination" : {
"commit" : {
"hash" : "string"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"branch" : {
"default_merge_strategy" : "The default merge strategy, when this endpoint is the destination of the pull request.",
"name" : "string",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
}
},
"source" : {
"commit" : {
"hash" : "string"
},
"repository" : {
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
},
"branch" : {
"default_merge_strategy" : "The default merge strategy, when this endpoint is the destination of the pull request.",
"name" : "string",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
}
},
"title" : "Title of the pull request.",
"reviewers" : [ {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
} ],
"task_count" : "The number of open tasks for a specific pull request.",
"closed_by" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"rendered" : {
"reason" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"description" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"title" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
}
},
"created_on" : "The ISO8601 timestamp the request was created.",
"links" : {
"comments" : {
"name" : "string",
"href" : "uri"
},
"activity" : {
"name" : "string",
"href" : "uri"
},
"approve" : {
"name" : "string",
"href" : "uri"
},
"merge" : {
"name" : "string",
"href" : "uri"
},
"decline" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"diff" : {
"name" : "string",
"href" : "uri"
},
"diffstat" : {
"name" : "string",
"href" : "uri"
}
},
"close_source_branch" : "A boolean flag indicating if merging the pull request closes the source branch.",
"id" : "The pull request's unique ID. Note that pull request IDs are only unique within their associated repository.",
"state" : "The pull request's current status.",
"merge_commit" : {
"hash" : "string"
},
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
}
}
Since this endpoint can be used to both update and to create a
repository, the request body depends on the intent.
See the POST documentation for the repository endpoint for an example
of the request body.
Note: Changing the name
of the repository will cause the location to
be changed. This is because the URL of the repo is derived from the
name (a process called slugification). In such a scenario, it is
possible for the request to fail if the newly created slug conflicts
with an existing repository's slug. But if there is no conflict,
the new location will be returned in the Location
header of the
response.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
The repository that is to be updated.
Note that the elements "owner" and "full_name" are ignored since the
URL implies them.
Type: object
{
"type" : "Required string",
"is_private" : "boolean",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"updated_on" : "date-time",
"parent" : "repository",
"fork_policy" : "\nControls the rules for forking this repository.\n\n* **allow_forks**: unrestricted forking\n* **no_public_forks**: restrict forking to private forks (forks cannot\n be made public later)\n* **no_forks**: deny all forking\n",
"description" : "string",
"project" : {
"type" : "Required string",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
},
"is_private" : "\nIndicates whether the project is publicly accessible, or whether it is\nprivate to the team and consequently only visible to team members.\nNote that private projects cannot contain public repositories.",
"updated_on" : "date-time",
"created_on" : "date-time",
"name" : "The name of the project.",
"description" : "string",
"links" : {
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_publicly_visible_repos" : "\nIndicates whether the project contains publicly visible repositories.\nNote that private projects cannot contain public repositories.",
"uuid" : "The project's immutable id.",
"key" : "The project's key."
},
"language" : "string",
"uuid" : "The repository's immutable id. This can be used as a substitute for the slug segment in URLs. Doing this guarantees your URLs will survive renaming of the repository by its owner, or even transfer of the repository to a different user.",
"has_issues" : "boolean",
"mainbranch" : {
"name" : "The name of the ref.",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
}
},
"type" : "Required string",
"target" : {
"type" : "Required string",
"date" : "date-time",
"summary" : {
"markup" : "The type of markup language the raw content is to be interpreted in.",
"raw" : "The text as it was typed by a user.",
"html" : "The user's content rendered as HTML."
},
"author" : {
"type" : "Required string",
"raw" : "The raw author value from the repository. This may be the only value available if the author does not match a user in Bitbucket.",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
},
"message" : "string",
"hash" : "string",
"parents" : [ "base_commit" ],
"repository" : "repository",
"participants" : [ {
"type" : "Required string",
"approved" : "boolean",
"role" : "string. Possible values: PARTICIPANT | REVIEWER",
"state" : "string. Possible values: approved | changes_requested",
"user" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string",
"account_id" : "The user's Atlassian account ID.",
"is_staff" : "boolean"
},
"participated_on" : "The ISO8601 timestamp of the participant's action. For approvers, this is the time of their approval. For commenters and pull request reviewers who are not approvers, this is the time they last commented, or null if they have not commented."
} ]
},
"default_merge_strategy" : "The default merge strategy for pull requests targeting this branch.",
"merge_strategies" : [ "string. Possible values: merge_commit | squash | fast_forward" ]
},
"full_name" : "The concatenation of the repository owner's username and the slugified name, e.g. \"evzijst/interruptingcow\". This is the same string used in Bitbucket URLs.",
"has_wiki" : "boolean",
"size" : "integer",
"created_on" : "date-time",
"name" : "string",
"links" : {
"forks" : {
"name" : "string",
"href" : "uri"
},
"downloads" : {
"name" : "string",
"href" : "uri"
},
"clone" : [ {
"name" : "string",
"href" : "uri"
} ],
"self" : {
"name" : "string",
"href" : "uri"
},
"commits" : {
"name" : "string",
"href" : "uri"
},
"watchers" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
},
"hooks" : {
"name" : "string",
"href" : "uri"
},
"pullrequests" : {
"name" : "string",
"href" : "uri"
}
},
"scm" : "string. Possible values: git"
}
Updates the specified webhook subscription.
The following properties can be mutated:
description
url
active
events
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
Installed webhook's ID
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Used to update a snippet. Use this to add and delete files and to
change a snippet's title.
To update a snippet, one can either PUT a full snapshot, or only the
parts that need to be changed.
The contract for PUT on this API is that properties missing from the
request remain untouched so that snippets can be efficiently
manipulated with differential payloads.
To delete a property (e.g. the title, or a file), include its name in
the request, but omit its value (use null
).
As in Git, explicit renaming of files is not supported. Instead, to
rename a file, delete it and add it again under another name. This can
be done atomically in a single request. Rename detection is left to
the SCM.
PUT supports three different content types for both request and
response bodies:
application/json
multipart/related
multipart/form-data
The content type used for the request body can be different than that
used for the response. Content types are specified using standard HTTP
headers.
Use the Content-Type
and Accept
headers to select the desired
request and response format.
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Updates a comment.
Comments can only be updated by their author.
The id of the comment.
Type: integer
The snippet id.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Identical to UPDATE /snippets/encoded_id
, except that this endpoint
takes an explicit commit revision. Only the snippet's "HEAD"/"tip"
(most recent) version can be updated and requests on all other,
older revisions fail by returning a 405 status.
Usage of this endpoint over the unrestricted /snippets/encoded_id
could be desired if the caller wants to be sure no concurrent
modifications have taken place between the moment of the UPDATE
request and the original GET.
This can be considered a so-called "Compare And Swap", or CAS
operation.
Other than that, the two endpoints are identical in behavior.
The snippet id.
Type: string
A commit revision (SHA1).
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Updates a specific SSH public key on a user's account
Note: Only the 'comment' field can be updated using this API. To modify the key or comment values, you must delete and add the key again.
The SSH key's UUID value.
Type: string
This can either be the UUID of the account, surrounded by curly-braces, for
example: {account UUID}
, OR an Atlassian Account ID.
Type: string
The updated SSH key object
Type: object
{
"type" : "Required string",
"created_on" : "date-time",
"last_used" : "date-time",
"comment" : "The comment parsed from the SSH key (if present)",
"links" : {
"self" : {
"name" : "string",
"href" : "uri"
}
},
"label" : "The user-defined label for the SSH key",
"uuid" : "The SSH key's immutable ID.",
"key" : "The SSH public key value in OpenSSH format.",
"owner" : {
"type" : "Required string",
"website" : "string",
"created_on" : "date-time",
"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.",
"links" : {
"followers" : {
"name" : "string",
"href" : "uri"
},
"repositories" : {
"name" : "string",
"href" : "uri"
},
"following" : {
"name" : "string",
"href" : "uri"
},
"self" : {
"name" : "string",
"href" : "uri"
},
"html" : {
"name" : "string",
"href" : "uri"
},
"avatar" : {
"name" : "string",
"href" : "uri"
}
},
"has_2fa_enabled" : "boolean",
"account_status" : "The status of the account. Currently the only possible value is \"active\", but more values may be added in the future.",
"display_name" : "string",
"uuid" : "string",
"username" : "string"
}
}
Update an application property value stored against a user.
The key of the Connect app.
Type: string
The name of the property.
Type: string
Either the UUID of the account surrounded by curly-braces, for example {account UUID}
, OR an Atlassian Account ID.
Type: string
Update a workspace level variable.
The UUID of the variable.
Type: string
This can either be the workspace ID (slug) or the workspace UUID surrounded by curly-braces, for example {workspace UUID}
.
Type: string
The updated variable.
Type: object
{
"type" : "Required string",
"uuid" : "The UUID identifying the variable.",
"value" : "The value of the variable. If the variable is secured, this will be empty.",
"secured" : "If true, this variable will be treated as secured. The value will never be exposed in the logs or the REST API.",
"key" : "The unique name of the variable."
}
Updates the specified webhook subscription.
The following properties can be mutated:
description
url
active
events
Installed webhook's ID
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Upload new download artifacts.
To upload files, perform a multipart/form-data
POST containing one
or more files
fields:
When a file is uploaded with the same name as an existing artifact,
then the existing file will be replaced.
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Upload new issue attachments.
To upload files, perform a multipart/form-data
POST containing one
or more file fields.
When a file is uploaded with the same name as an existing attachment,
then the existing file will be replaced.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Vote for this issue.
To cast your vote, do an empty PUT. The 204 status code indicates that
the operation was successful.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Start watching this issue.
To start watching this issue, do an empty PUT. The 204 status code
indicates that the operation was successful.
The issue id
Type: string
This can either be the repository slug or the UUID of the repository,
surrounded by curly-braces, for example: {repository UUID}
.
Type: string
This can either be the workspace ID (slug) or the workspace UUID
surrounded by curly-braces, for example: {workspace UUID}
.
Type: string
Used to start watching a specific snippet. Returns 204 (No Content).