Addon3
The addon resource is intended to use used by Bitbucket Cloud Connect
Apps, and only supports JWT authentication.
PUT/addonUpdate an installed app
Responses| Status | Description | Schema |
|---|
204 | Request has succeeded. The installation has been updated to the new descriptor. | — |
400 | Scopes have increased or decreased to none. | error |
401 | No authorization. | error |
403 | Improper authentication. | error |
DELETE/addonDelete an app
Responses| Status | Description | Schema |
|---|
204 | Request has succeeded. The application has been deleted for the user. | — |
401 | No authorization. | error |
403 | Improper authentication. | error |
GET/addon/{addon_key}/client-keyGet the client key of a Connect addon
Parameters| Name | In | Required | Type |
|---|
addon_key | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The client key of the Connect addon linked to the Forge app installation where the request was made | — |
401 | Invalid authentication. | error |
403 | Improper authorization. | error |
404 | The Connect addon or the Forge app does not exist. | error |
Branch restrictions5
Repository owners and administrators can set branch management
rules on a repository that control what can be pushed by whom.
Through these rules, you can enforce a project or team
workflow. For example, owners or administrators can:
* Limit push powers
* Prevent branch deletion
* Prevent history re-writes (Git only)
GET/repositories/{workspace}/{repo_slug}/branch-restrictionsList branch restrictions
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
kind | query | no | string |
pattern | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of branch restrictions | paginated_branchrestrictions |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have admin access to the repository | error |
404 | If the repository does not exist | error |
POST/repositories/{workspace}/{repo_slug}/branch-restrictionsCreate a branch restriction rule
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — branchrestriction (required)
Responses| Status | Description | Schema |
|---|
201 | A paginated list of branch restrictions | branchrestriction |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have admin access to the repository | error |
404 | If the repository does not exist | error |
GET/repositories/{workspace}/{repo_slug}/branch-restrictions/{id}Get a branch restriction rule
Parameters| Name | In | Required | Type |
|---|
id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The branch restriction rule | branchrestriction |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have admin access to the repository | error |
404 | If the repository or branch restriction id does not exist | error |
PUT/repositories/{workspace}/{repo_slug}/branch-restrictions/{id}Update a branch restriction rule
Parameters| Name | In | Required | Type |
|---|
id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — branchrestriction (required)
Responses| Status | Description | Schema |
|---|
200 | The updated branch restriction rule | branchrestriction |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have admin access to the repository | error |
404 | If the repository or branch restriction id does not exist | error |
DELETE/repositories/{workspace}/{repo_slug}/branch-restrictions/{id}Delete a branch restriction rule
Parameters| Name | In | Required | Type |
|---|
id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | | — |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have admin access to the repository | error |
404 | If the repository or branch restriction id does not exist | error |
Branching model7
The branching model resource is used to modify the branching model
for a repository.
You can use the branching model to define a branch based workflow
for your repositories. When you map your workflow to branch types,
you can ensure that branches are named consistently by configuring
which branch types to make available.
GET/repositories/{workspace}/{repo_slug}/branching-modelGet the branching model for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The branching model object | branching_model |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have read access to the repository | error |
404 | If the repository does not exist | error |
GET/repositories/{workspace}/{repo_slug}/branching-model/settingsGet the branching model config for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The branching model configuration | branching_model_settings |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have admin access to the repository | error |
404 | If the repository does not exist | error |
PUT/repositories/{workspace}/{repo_slug}/branching-model/settingsUpdate the branching model config for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The updated branching model configuration | branching_model_settings |
400 | If the request contains invalid branching model configuration | error |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have admin access to the repository | error |
404 | If the repository does not exist | error |
GET/repositories/{workspace}/{repo_slug}/effective-branching-modelGet the effective, or currently applied, branching model for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The effective branching model object | effective_repo_branching_model |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have read access to the repository | error |
404 | If the repository does not exist | error |
GET/workspaces/{workspace}/projects/{project_key}/branching-modelGet the branching model for a project
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The branching model object | project_branching_model |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have read access to the project | error |
404 | If the project does not exist | error |
GET/workspaces/{workspace}/projects/{project_key}/branching-model/settingsGet the branching model config for a project
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The branching model configuration | branching_model_settings |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have admin access to the project | error |
404 | If the project does not exist | error |
PUT/workspaces/{workspace}/projects/{project_key}/branching-model/settingsUpdate the branching model config for a project
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The updated branching model configuration | branching_model_settings |
400 | If the request contains an invalid branching model configuration | error |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have admin access to the project | error |
404 | If the project does not exist | error |
Commit statuses4
Commit statuses provide a way to tag commits with meta data,
like automated build results.
GET/repositories/{workspace}/{repo_slug}/commit/{commit}/statusesList commit statuses for a commit
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
refname | query | no | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of all commit statuses for this commit. | paginated_commitstatuses |
401 | If the repository is private and the request was not authenticated. | — |
404 | If the repository or commit does not exist | error |
POST/repositories/{workspace}/{repo_slug}/commit/{commit}/statuses/buildCreate a build status for a commit
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — commitstatus
Responses| Status | Description | Schema |
|---|
201 | The newly created build status object. | commitstatus |
401 | If the repository is private and the request was not authenticated. | — |
404 | If the repository, commit, or build status key does not exist | error |
GET/repositories/{workspace}/{repo_slug}/commit/{commit}/statuses/build/{key}Get a build status for a commit
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
key | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The build status object with the specified key. | commitstatus |
401 | If the repository is private and the request was not authenticated. | — |
404 | If the repository, commit, or build status key does not exist | error |
PUT/repositories/{workspace}/{repo_slug}/commit/{commit}/statuses/build/{key}Update a build status for a commit
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
key | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — commitstatus
Responses| Status | Description | Schema |
|---|
200 | The updated build status object. | commitstatus |
401 | If the repository is private and the request was not authenticated. | — |
404 | If the repository or build does not exist | error |
Commits17
These are the repository's commits. They are paginated and returned in
reverse chronological order, similar to the output of git log.
GET/repositories/{workspace}/{repo_slug}/commit/{commit}Get a commit
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The commit object | commit |
404 | If the specified commit or repository does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/commit/{commit}/approveApprove a commit
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The `participant` object recording that the authenticated user approved the commit. | participant |
404 | If the specified commit, or the repository does not exist. | error |
DELETE/repositories/{workspace}/{repo_slug}/commit/{commit}/approveUnapprove a commit
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response indicating the authenticated user's approval has been withdrawn. | — |
404 | If the specified commit, or the repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/commit/{commit}/commentsList a commit's comments
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of commit comments. | paginated_commit_comments |
POST/repositories/{workspace}/{repo_slug}/commit/{commit}/commentsCreate comment for a commit
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — commit_comment (required)
Responses| Status | Description | Schema |
|---|
201 | The newly created comment. | — |
400 | If the comment was detected as spam, or if the parent comment is not attached to the same node as the new comment | — |
404 | If a parent ID was passed in that cannot be found | — |
GET/repositories/{workspace}/{repo_slug}/commit/{commit}/comments/{comment_id}Get a commit comment
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
commit | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The commit comment. | commit_comment |
PUT/repositories/{workspace}/{repo_slug}/commit/{commit}/comments/{comment_id}Update a commit comment
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
commit | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — commit_comment (required)
Responses| Status | Description | Schema |
|---|
201 | The newly updated comment. | — |
400 | If the comment update was detected as spam | — |
DELETE/repositories/{workspace}/{repo_slug}/commit/{commit}/comments/{comment_id}Delete a commit comment
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
commit | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates the comment was deleted by this action or a previous delete. | — |
404 | If the comment doesn't exist | — |
GET/repositories/{workspace}/{repo_slug}/commitsList commits
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of commits | paginated_changeset |
404 | If the specified repository does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/commitsList commits with include/exclude
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of commits | paginated_changeset |
404 | If the specified repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/commits/{revision}List commits for revision
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
revision | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of commits | paginated_changeset |
404 | If the specified revision does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/commits/{revision}List commits for revision using include/exclude
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
revision | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of commits | paginated_changeset |
404 | If the specified revision does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/diff/{spec}Compare two commits
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
spec | path | yes | string |
workspace | path | yes | string |
context | query | no | integer |
path | query | no | string |
ignore_whitespace | query | no | boolean |
binary | query | no | boolean |
renames | query | no | boolean |
merge | query | no | boolean |
topic | query | no | boolean |
Responses| Status | Description | Schema |
|---|
200 | The raw diff | — |
555 | If the diff was too large and timed out.
Since this endpoint does not employ any form of pagination, but
instead returns the diff as a single document, it can run into
trouble on very large diffs. If Bitbucket times out in cases
like these, a 555 status code is returned. | error |
GET/repositories/{workspace}/{repo_slug}/diffstat/{spec}Compare two commit diff stats
Parameters| Name | In | Required | Type |
|---|
ignore_whitespace | query | no | boolean |
merge | query | no | boolean |
path | query | no | string |
renames | query | no | boolean |
repo_slug | path | yes | string |
spec | path | yes | string |
topic | query | no | boolean |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The diff stats | paginated_diffstats |
555 | If generating the diffstat timed out. | error |
GET/repositories/{workspace}/{repo_slug}/file-conflicts/{spec}Get file conflicts for a commit spec
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
spec | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of file conflicts | paginated_file_conflicts |
404 | If the spec cannot be resolved, which may be due to an invalid spec, or commits/refs not present in the repository | error |
GET/repositories/{workspace}/{repo_slug}/merge-base/{revspec}Get the common ancestor between two commits
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
revspec | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The merge base of the provided spec. | commit |
401 | If the request was not authenticated. | error |
403 | If the authenticated user does not have access to any of the repositories specified. | error |
404 | If the repository or ref in the spec does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/patch/{spec}Get a patch for two commits
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
spec | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The raw patches | — |
555 | If the diff was too large and timed out.
Since this endpoint does not employ any form of pagination, but
instead returns the diff as a single document, it can run into
trouble on very large diffs. If Bitbucket times out in cases
like these, a 555 status code is returned. | error |
Deployments16
Teams are deploying code faster than ever, thanks to continuous
delivery practices and tools like Bitbucket Pipelines. Bitbucket
Deployments gives teams visibility into their deployment
environments and helps teams to track how far changes have
progressed in their deployment pipeline.
GET/repositories/{workspace}/{repo_slug}/deploy-keysList repository deploy keys
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Deploy keys matching the repository | paginated_deploy_keys |
403 | If the specified user or repository is not accessible to the current user | — |
404 | If the specified user or repository does not exist | error |
POST/repositories/{workspace}/{repo_slug}/deploy-keysAdd a repository deploy key
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The deploy key that was created | deploy_key |
400 | Invalid deploy key inputs | — |
403 | If the specified user or repository is not accessible to the current user | — |
404 | If the specified user or repository does not exist | error |
GET/repositories/{workspace}/{repo_slug}/deploy-keys/{key_id}Get a repository deploy key
Parameters| Name | In | Required | Type |
|---|
key_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Deploy key matching the key ID | deploy_key |
403 | If the specified user or repository is not accessible to the current user | — |
404 | If the specified user or repository does not exist | error |
PUT/repositories/{workspace}/{repo_slug}/deploy-keys/{key_id}Update a repository deploy key
Parameters| Name | In | Required | Type |
|---|
key_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The newly updated deploy key. | deploy_key |
400 | If the submitted key or related value is invalid | error |
403 | If the current user does not have permission to add a key for the specified user | — |
404 | If the specified user, repository, or deploy key does not exist | error |
DELETE/repositories/{workspace}/{repo_slug}/deploy-keys/{key_id}Delete a repository deploy key
Parameters| Name | In | Required | Type |
|---|
key_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The key has been deleted | — |
403 | If the current user does not have permission to delete a key for the specified user | — |
404 | If the specified user, repository, or deploy key does not exist | error |
GET/repositories/{workspace}/{repo_slug}/deploymentsList deployments
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The matching deployments. | paginated_deployments |
GET/repositories/{workspace}/{repo_slug}/deployments/{deployment_uuid}Get a deployment
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
deployment_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The deployment. | deployment |
404 | No account, repository or deployment with the UUID provided exists. | error |
GET/repositories/{workspace}/{repo_slug}/environmentsList environments
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The matching environments. | paginated_environments |
POST/repositories/{workspace}/{repo_slug}/environmentsCreate an environment
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Request bodyapplication/json — deployment_environment (required)
Responses| Status | Description | Schema |
|---|
201 | The environment was created. | deployment_environment |
404 | The account or repository does not exist. | error |
409 | An environment host with the provided name already exists. | error |
GET/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}Get an environment
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
environment_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The environment. | deployment_environment |
404 | No account, repository or environment with the UUID provided exists. | error |
DELETE/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}Delete an environment
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
environment_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The environment was deleted. | — |
404 | No account or repository with the UUID provided exists. | error |
POST/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}/changesUpdate an environment
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
environment_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
202 | The environment update request was accepted. | — |
404 | No account, repository or environment with the UUID provided exists. | error |
GET/workspaces/{workspace}/projects/{project_key}/deploy-keysList project deploy keys
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Deploy keys matching the project | paginated_project_deploy_keys |
403 | If the specified workspace or project is not accessible to the current user | error |
404 | If the specified workspace or project does not exist | error |
POST/workspaces/{workspace}/projects/{project_key}/deploy-keysCreate a project deploy key
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The project deploy key that was created | project_deploy_key |
400 | Invalid deploy key inputs | error |
403 | If the specified workspace or project is not accessible to the current user | error |
404 | If the specified workspace or project does not exist | error |
GET/workspaces/{workspace}/projects/{project_key}/deploy-keys/{key_id}Get a project deploy key
Parameters| Name | In | Required | Type |
|---|
key_id | path | yes | string |
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Project deploy key matching the key ID | project_deploy_key |
403 | If the specified workspace or project is not accessible to the current user | error |
404 | If the specified workspace or project does not exist | error |
DELETE/workspaces/{workspace}/projects/{project_key}/deploy-keys/{key_id}Delete a deploy key from a project
Parameters| Name | In | Required | Type |
|---|
key_id | path | yes | string |
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The project deploy key has been deleted | — |
403 | If the current user does not have permission to delete a key for the specified project | error |
404 | If the specified workspace, project, or project deploy key does not exist | error |
Downloads4
Access the list of download links associated with the repository.
GET/repositories/{workspace}/{repo_slug}/downloadsList download artifacts
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Returns a paginated list of the downloads associated with the repository. | — |
403 | User is not authorized to read from the repository. | error |
POST/repositories/{workspace}/{repo_slug}/downloadsUpload a download artifact
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
201 | The artifact was uploaded sucessfully. | — |
400 | Bad Request. | error |
403 | User is not authorized to write to the repository. | error |
406 | Unsupported Content-Type. Use multiplart/form-data. | error |
GET/repositories/{workspace}/{repo_slug}/downloads/{filename}Get a download artifact link
Parameters| Name | In | Required | Type |
|---|
filename | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
302 | Redirects to the url of the specified download artifact. | — |
403 | User is not authorized to read from the repository. | error |
404 | The specified download artifact does not exist. | error |
DELETE/repositories/{workspace}/{repo_slug}/downloads/{filename}Delete a download artifact
Parameters| Name | In | Required | Type |
|---|
filename | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The specified download artifact was deleted. | — |
403 | User is not authorized to write to the repository. | error |
404 | The specified download does not exist. | error |
GPG4
The GPG resource allows you to manage GPG keys.
GET/users/{selected_user}/gpg-keysList GPG keys
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A list of the GPG keys associated with the account. | paginated_gpg_user_keys |
403 | If the specified user's keys are not accessible to the current user | — |
404 | If the specified user does not exist | error |
POST/users/{selected_user}/gpg-keysAdd a new GPG key
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
Request bodyapplication/json — GPG_account_key
Responses| Status | Description | Schema |
|---|
201 | The newly created GPG key. | GPG_account_key |
400 | If the submitted key or related value is invalid | error |
403 | If the current user does not have permission to add a key for the specified user | — |
404 | If the specified user does not exist | error |
GET/users/{selected_user}/gpg-keys/{fingerprint}Get a GPG key
Parameters| Name | In | Required | Type |
|---|
fingerprint | path | yes | string |
selected_user | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specific GPG key matching the user and fingerprint. | GPG_account_key |
403 | If the specified user's keys are not accessible to the current user | — |
404 | If the specified user does not exist | error |
DELETE/users/{selected_user}/gpg-keys/{fingerprint}Delete a GPG key
Parameters| Name | In | Required | Type |
|---|
fingerprint | path | yes | string |
selected_user | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The key has been deleted | — |
400 | If the submitted key or related value is invalid | error |
403 | If the current user does not have permission to delete a key for the specified user, or the submitted key is a subkey | — |
404 | If the specified key does not exist | error |
Issue tracker33
The issue resources provide functionality for getting information on
issues in an issue tracker, creating new issues, updating them and deleting
them.
You can access public issues without authentication, but you can't gain access
to private repositories' issues. By authenticating, you will get the ability
to create issues, as well as access to updating data or deleting issues you
have access to. Issue Tracker features are not supported for repositories in workspaces administered through admin.atlassian.com.
GET/repositories/{workspace}/{repo_slug}/componentsList components
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The components that have been defined in the issue tracker. | paginated_components |
404 | The specified repository does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/components/{component_id}Get a component for issues
Parameters| Name | In | Required | Type |
|---|
component_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specified component object. | component |
404 | The specified repository or component does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/issuesList issues
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of the issues matching any filter criteria that were provided. | paginated_issues |
404 | The specified repository does not exist or does not have the issue tracker enabled. | error |
POST/repositories/{workspace}/{repo_slug}/issuesCreate an issue
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — issue (required)
Responses| Status | Description | Schema |
|---|
201 | The newly created issue. | issue |
401 | When the request wasn't authenticated. | error |
403 | When the authenticated user isn't authorized to create the issue. | error |
404 | The specified repository does not exist or does not have the issue tracker enabled. | error |
POST/repositories/{workspace}/{repo_slug}/issues/exportExport issues
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — export_options
Responses| Status | Description | Schema |
|---|
202 | The export job has been accepted | — |
401 | The request wasn't authenticated properly | error |
403 | When the authenticated user does not have admin permission on the repo | error |
404 | The repo does not exist or does not have an issue tracker | error |
GET/repositories/{workspace}/{repo_slug}/issues/export/{repo_name}-issues-{task_id}.zipCheck issue export status
Parameters| Name | In | Required | Type |
|---|
repo_name | path | yes | string |
repo_slug | path | yes | string |
task_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
202 | Export job accepted | issue_job_status |
401 | The request wasn't authenticated properly | error |
403 | When the authenticated user does not have admin permission on the repo | error |
404 | No export job has begun | error |
GET/repositories/{workspace}/{repo_slug}/issues/importCheck issue import status
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Import job complete with either FAILURE or SUCCESS status | issue_job_status |
202 | Import job started | issue_job_status |
401 | The request wasn't authenticated properly | error |
403 | When the authenticated user does not have admin permission on the repo | error |
404 | No export job has begun | error |
POST/repositories/{workspace}/{repo_slug}/issues/importImport issues
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
202 | Import job accepted | issue_job_status |
401 | The request wasn't authenticated properly | error |
403 | When the authenticated user does not have admin permission on the repo | error |
404 | No export job has begun | error |
409 | Import already running | error |
GET/repositories/{workspace}/{repo_slug}/issues/{issue_id}Get an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The issue object. | issue |
403 | When the authenticated user isn't authorized to access the issue. | error |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
410 | The specified issue is unavailable. | error |
PUT/repositories/{workspace}/{repo_slug}/issues/{issue_id}Update an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The updated issue object. | issue |
403 | When the authenticated user isn't authorized to access the issue. | error |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
DELETE/repositories/{workspace}/{repo_slug}/issues/{issue_id}Delete an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates the issue was deleted successfully. | — |
403 | When the authenticated user isn't authorized to delete the issue. | error |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/issues/{issue_id}/attachmentsList attachments for an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of all attachments for this issue. | paginated_issue_attachments |
401 | If the issue tracker is private and the request was not authenticated. | — |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
POST/repositories/{workspace}/{repo_slug}/issues/{issue_id}/attachmentsUpload an attachment to an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
201 | An empty response document. | — |
400 | If no files were uploaded, or if the wrong `Content-Type` was used. | — |
401 | If the issue tracker is private and the request was not authenticated. | — |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/issues/{issue_id}/attachments/{path}Get attachment for an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
path | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
302 | A redirect to the file's contents | — |
401 | If the issue tracker is private and the request was not authenticated. | — |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
DELETE/repositories/{workspace}/{repo_slug}/issues/{issue_id}/attachments/{path}Delete an attachment for an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
path | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates that the deletion was successful | — |
401 | If the issue tracker is private and the request was not authenticated. | — |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/issues/{issue_id}/changesList changes on an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | Returns all the issue changes that were made on the specified issue. | paginated_log_entries |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
POST/repositories/{workspace}/{repo_slug}/issues/{issue_id}/changesModify the state of an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — issue_change (required)
Responses| Status | Description | Schema |
|---|
201 | The newly created issue change. | issue_change |
401 | When the request wasn't authenticated. | error |
403 | When the authenticated user isn't authorized to modify the issue. | error |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/issues/{issue_id}/changes/{change_id}Get issue change object
Parameters| Name | In | Required | Type |
|---|
change_id | path | yes | string |
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specified issue change object. | issue_change |
404 | The specified repository or issue change does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/issues/{issue_id}/commentsList comments on an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
q | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of issue comments. | paginated_issue_comments |
POST/repositories/{workspace}/{repo_slug}/issues/{issue_id}/commentsCreate a comment on an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — issue_comment (required)
Responses| Status | Description | Schema |
|---|
201 | The newly created comment. | — |
400 | If the input was invalid, or if the comment being created is detected as spam | error |
GET/repositories/{workspace}/{repo_slug}/issues/{issue_id}/comments/{comment_id}Get a comment on an issue
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The issue comment. | issue_comment |
PUT/repositories/{workspace}/{repo_slug}/issues/{issue_id}/comments/{comment_id}Update a comment on an issue
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — issue_comment (required)
Responses| Status | Description | Schema |
|---|
200 | The updated issue comment. | issue_comment |
400 | If the input was invalid, or if the update to the comment is detected as spam | error |
DELETE/repositories/{workspace}/{repo_slug}/issues/{issue_id}/comments/{comment_id}Delete a comment on an issue
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates successful deletion. | — |
GET/repositories/{workspace}/{repo_slug}/issues/{issue_id}/voteCheck if current user voted for an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | If the authenticated user has not voted for this issue. | error |
401 | When the request wasn't authenticated. | error |
404 | If the authenticated user has not voted for this issue, or when the repo does not exist, or does not have an issue tracker. | error |
PUT/repositories/{workspace}/{repo_slug}/issues/{issue_id}/voteVote for an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicating the authenticated user has cast their vote successfully. | error |
401 | When the request wasn't authenticated. | error |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
DELETE/repositories/{workspace}/{repo_slug}/issues/{issue_id}/voteRemove vote for an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
default | Unexpected error. | error |
GET/repositories/{workspace}/{repo_slug}/issues/{issue_id}/watchCheck if current user is watching a issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | If the authenticated user is watching this issue. | error |
401 | When the request wasn't authenticated. | error |
404 | If the authenticated user is not watching this issue, or when the repo does not exist, or does not have an issue tracker. | error |
PUT/repositories/{workspace}/{repo_slug}/issues/{issue_id}/watchWatch an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates that the authenticated user successfully started watching this issue. | error |
401 | When the request wasn't authenticated. | error |
404 | If the authenticated user is not watching this issue, or when the repo does not exist, or does not have an issue tracker. | error |
DELETE/repositories/{workspace}/{repo_slug}/issues/{issue_id}/watchStop watching an issue
Parameters| Name | In | Required | Type |
|---|
issue_id | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates that the authenticated user successfully stopped watching this issue. | error |
401 | When the request wasn't authenticated. | error |
404 | The specified repository or issue does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/milestonesList milestones
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The milestones that have been defined in the issue tracker. | paginated_milestones |
404 | The specified repository does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/milestones/{milestone_id}Get a milestone
Parameters| Name | In | Required | Type |
|---|
milestone_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specified milestone object. | milestone |
404 | The specified repository or milestone does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/versionsList defined versions for issues
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The versions that have been defined in the issue tracker. | paginated_versions |
404 | The specified repository does not exist or does not have the issue tracker enabled. | error |
GET/repositories/{workspace}/{repo_slug}/versions/{version_id}Get a defined version for issues
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
version_id | path | yes | integer |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specified version object. | version |
404 | The specified repository or version does not exist or does not have the issue tracker enabled. | error |
Pipelines68
Bitbucket Pipelines brings continuous delivery to Bitbucket
Cloud, empowering teams with full branching to deployment
visibility and faster feedback loops.
GET/repositories/{workspace}/{repo_slug}/deployments_config/environments/{environment_uuid}/variablesList variables for an environment
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
environment_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The retrieved deployment variables. | paginated_deployment_variable |
POST/repositories/{workspace}/{repo_slug}/deployments_config/environments/{environment_uuid}/variablesCreate a variable for an environment
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
environment_uuid | path | yes | string |
Request bodyapplication/json — deployment_variable (required)
Responses| Status | Description | Schema |
|---|
201 | The variable was created. | deployment_variable |
404 | The account, repository, environment or variable with the given UUID was not found. | error |
409 | A variable with the provided key already exists. | error |
PUT/repositories/{workspace}/{repo_slug}/deployments_config/environments/{environment_uuid}/variables/{variable_uuid}Update a variable for an environment
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
environment_uuid | path | yes | string |
variable_uuid | path | yes | string |
Request bodyapplication/json — deployment_variable (required)
Responses| Status | Description | Schema |
|---|
200 | The deployment variable was updated. | deployment_variable |
404 | The account, repository, environment or variable with the given UUID was not found. | error |
DELETE/repositories/{workspace}/{repo_slug}/deployments_config/environments/{environment_uuid}/variables/{variable_uuid}Delete a variable for an environment
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
environment_uuid | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The variable was deleted. | — |
404 | The account, repository, environment or variable with given UUID was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelinesList pipelines
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
creator.uuid | query | no | string |
target.ref_type | query | no | string |
target.ref_name | query | no | string |
target.branch | query | no | string |
target.commit.hash | query | no | string |
target.selector.pattern | query | no | string |
target.selector.type | query | no | string |
created_on | query | no | string |
trigger_type | query | no | string |
status | query | no | string |
sort | query | no | string |
page | query | no | integer |
pagelen | query | no | integer |
Responses| Status | Description | Schema |
|---|
200 | The matching pipelines. | paginated_pipelines |
POST/repositories/{workspace}/{repo_slug}/pipelinesRun a pipeline
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Request bodyapplication/json — pipeline (required)
Responses| Status | Description | Schema |
|---|
201 | The initiated pipeline. | pipeline |
400 | The account or repository is not enabled, the yml file does not exist in the repository for the given revision, or the request body contained invalid properties. | error |
404 | The account or repository was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines-config/cachesList caches
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The list of caches for the given repository. | paginated_pipeline_caches |
404 | The account or repository was not found. | error |
DELETE/repositories/{workspace}/{repo_slug}/pipelines-config/cachesDelete caches
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
name | query | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The caches were deleted. | — |
404 | The workspace, repository or cache name was not found. | error |
DELETE/repositories/{workspace}/{repo_slug}/pipelines-config/caches/{cache_uuid}Delete a cache
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
cache_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The cache was deleted. | — |
404 | The workspace, repository or cache_uuid with given UUID was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines-config/caches/{cache_uuid}/content-uriGet cache content URI
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
cache_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The cache content uri. | pipeline_cache_content_uri |
404 | The workspace, repository or cache_uuid with given UUID was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines-config/runnersGet repository runners
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The repository runners. | paginated_pipeline_runners |
POST/repositories/{workspace}/{repo_slug}/pipelines-config/runnersCreate repository runner
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The repository runner. | pipeline_runner |
400 | The request body contained invalid properties or runner limit exceeded. | error |
409 | The repository runner with the provided UUID already exists. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines-config/runners/{runner_uuid}Get repository runner
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
runner_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The repository runner. | pipeline_runner |
404 | The repository runner was not found. | error |
PUT/repositories/{workspace}/{repo_slug}/pipelines-config/runners/{runner_uuid}Update repository runner
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
runner_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The repository runner. | pipeline_runner |
404 | The repository runner was not found. | error |
DELETE/repositories/{workspace}/{repo_slug}/pipelines-config/runners/{runner_uuid}Delete repository runner
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
runner_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The repository runner was deleted. | — |
404 | The repository runner was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}Get a pipeline
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pipeline_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The pipeline. | pipeline |
404 | No account, repository or pipeline with the UUID provided exists. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}/stepsList steps for a pipeline
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pipeline_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The steps. | paginated_pipeline_steps |
GET/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}/steps/{step_uuid}Get a step of a pipeline
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pipeline_uuid | path | yes | string |
step_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The step. | pipeline_step |
404 | No account, repository, pipeline or step with the UUID provided exists for the pipeline with the UUID provided. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}/steps/{step_uuid}/logGet log file for a step
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pipeline_uuid | path | yes | string |
step_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The raw log file for this pipeline step. | — |
304 | The log has the same etag as the provided If-None-Match header. | error |
307 | After the step is completed, the log is moved to long term storage and a redirection to the log file is returned. | — |
404 | A pipeline with the given UUID does not exist, a step with the given UUID does not exist in the pipeline or a log file does not exist for the given step. | error |
416 | The requested range does not exist for requests that specified the [HTTP Range header](https://tools.ietf.org/html/rfc7233#section-3.1). | error |
GET/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}/steps/{step_uuid}/logs/{log_uuid}Get the logs for the build container or a service container for a given step of a pipeline.
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pipeline_uuid | path | yes | string |
step_uuid | path | yes | string |
log_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The raw log file for the build container or service container. | — |
307 | After the step is completed, the log is moved to long term storage and a redirection to the log file is returned. | — |
404 | No account, repository, pipeline, step or log exist for the provided path. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}/steps/{step_uuid}/test_reportsGet a summary of test reports for a given step of a pipeline.
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pipeline_uuid | path | yes | string |
step_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A summary of test reports for this pipeline step. | — |
404 | No account, repository, pipeline, step or test reports exist for the provided path. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}/steps/{step_uuid}/test_reports/test_casesGet test cases for a given step of a pipeline.
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pipeline_uuid | path | yes | string |
step_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Test cases for this pipeline step. | — |
404 | No account, repository, pipeline, step or test reports exist for the provided path. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}/steps/{step_uuid}/test_reports/test_cases/{test_case_uuid}/test_case_reasonsGet test case reasons (output) for a given test case in a step of a pipeline.
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pipeline_uuid | path | yes | string |
step_uuid | path | yes | string |
test_case_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Test case reasons (output). | — |
404 | No account, repository, pipeline, step or test case with the UUID provided exists for the pipeline with the UUID provided. | error |
POST/repositories/{workspace}/{repo_slug}/pipelines/{pipeline_uuid}/stopPipelineStop a pipeline
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pipeline_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The pipeline has been signaled to stop. | — |
400 | The specified pipeline has already completed. | error |
404 | Either the account, repository or pipeline with the given UUID does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines_configGet configuration
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The repository pipelines configuration. | pipelines_config |
PUT/repositories/{workspace}/{repo_slug}/pipelines_configUpdate configuration
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Request bodyapplication/json — pipelines_config (required)
Responses| Status | Description | Schema |
|---|
200 | The repository pipelines configuration was updated. | pipelines_config |
PUT/repositories/{workspace}/{repo_slug}/pipelines_config/build_numberUpdate the next build number
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Request bodyapplication/json — pipeline_build_number (required)
Responses| Status | Description | Schema |
|---|
200 | The build number has been configured. | pipeline_build_number |
400 | The update failed because the next number was invalid (it should be higher than the current number). | error |
404 | The account or repository was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines_config/schedulesList schedules
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The list of schedules. | paginated_pipeline_schedules |
404 | The account or repository was not found. | error |
POST/repositories/{workspace}/{repo_slug}/pipelines_config/schedulesCreate a schedule
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Request bodyapplication/json — pipeline_schedule_post_request_body (required)
Responses| Status | Description | Schema |
|---|
201 | The created schedule. | pipeline_schedule |
400 | There were errors validating the request. | error |
401 | The maximum limit of schedules for this repository was reached. | error |
404 | The account or repository was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines_config/schedules/{schedule_uuid}Get a schedule
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
schedule_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The requested schedule. | pipeline_schedule |
404 | The account, repository or schedule was not found. | error |
PUT/repositories/{workspace}/{repo_slug}/pipelines_config/schedules/{schedule_uuid}Update a schedule
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
schedule_uuid | path | yes | string |
Request bodyapplication/json — pipeline_schedule_put_request_body (required)
Responses| Status | Description | Schema |
|---|
200 | The schedule is updated. | pipeline_schedule |
404 | The account, repository or schedule was not found. | error |
DELETE/repositories/{workspace}/{repo_slug}/pipelines_config/schedules/{schedule_uuid}Delete a schedule
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
schedule_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The schedule was deleted. | — |
404 | The account, repository or schedule was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines_config/schedules/{schedule_uuid}/executionsList executions of a schedule
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
schedule_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The list of executions of a schedule. | paginated_pipeline_schedule_executions |
404 | The account or repository was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines_config/ssh/key_pairGet SSH key pair
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The SSH key pair. | pipeline_ssh_key_pair |
404 | The account, repository or SSH key pair was not found. | error |
PUT/repositories/{workspace}/{repo_slug}/pipelines_config/ssh/key_pairUpdate SSH key pair
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Request bodyapplication/json — pipeline_ssh_key_pair (required)
Responses| Status | Description | Schema |
|---|
200 | The SSH key pair was created or updated. | pipeline_ssh_key_pair |
404 | The account, repository or SSH key pair was not found. | error |
DELETE/repositories/{workspace}/{repo_slug}/pipelines_config/ssh/key_pairDelete SSH key pair
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The SSH key pair was deleted. | — |
404 | The account, repository or SSH key pair was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines_config/ssh/known_hostsList known hosts
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The retrieved known hosts. | paginated_pipeline_known_hosts |
POST/repositories/{workspace}/{repo_slug}/pipelines_config/ssh/known_hostsCreate a known host
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Request bodyapplication/json — pipeline_known_host (required)
Responses| Status | Description | Schema |
|---|
201 | The known host was created. | pipeline_known_host |
404 | The account or repository does not exist. | error |
409 | A known host with the provided hostname already exists. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines_config/ssh/known_hosts/{known_host_uuid}Get a known host
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
known_host_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The known host. | pipeline_known_host |
404 | The account, repository or known host with the specified UUID was not found. | error |
PUT/repositories/{workspace}/{repo_slug}/pipelines_config/ssh/known_hosts/{known_host_uuid}Update a known host
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
known_host_uuid | path | yes | string |
Request bodyapplication/json — pipeline_known_host (required)
Responses| Status | Description | Schema |
|---|
200 | The known host was updated. | pipeline_known_host |
404 | The account, repository or known host with the given UUID was not found. | error |
DELETE/repositories/{workspace}/{repo_slug}/pipelines_config/ssh/known_hosts/{known_host_uuid}Delete a known host
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
known_host_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The known host was deleted. | — |
404 | The account, repository or known host with given UUID was not found. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines_config/variablesList variables for a repository
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The retrieved variables. | paginated_pipeline_variables |
POST/repositories/{workspace}/{repo_slug}/pipelines_config/variablesCreate a variable for a repository
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
Request bodyapplication/json — pipeline_variable (required)
Responses| Status | Description | Schema |
|---|
201 | The variable was created. | pipeline_variable |
404 | The account or repository does not exist. | error |
409 | A variable with the provided key already exists. | error |
GET/repositories/{workspace}/{repo_slug}/pipelines_config/variables/{variable_uuid}Get a variable for a repository
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The variable. | pipeline_variable |
404 | The account, repository or variable with the specified UUID was not found. | error |
PUT/repositories/{workspace}/{repo_slug}/pipelines_config/variables/{variable_uuid}Update a variable for a repository
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
variable_uuid | path | yes | string |
Request bodyapplication/json — pipeline_variable (required)
Responses| Status | Description | Schema |
|---|
200 | The variable was updated. | pipeline_variable |
404 | The account, repository or variable with the given UUID was not found. | error |
DELETE/repositories/{workspace}/{repo_slug}/pipelines_config/variables/{variable_uuid}Delete a variable for a repository
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The variable was deleted. | — |
404 | The account, repository or variable with given UUID was not found. | error |
GET/teams/{username}/pipelines_config/variablesList variables for an account
Parameters| Name | In | Required | Type |
|---|
username | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The found account level variables. | paginated_pipeline_variables |
POST/teams/{username}/pipelines_config/variablesCreate a variable for a user
Parameters| Name | In | Required | Type |
|---|
username | path | yes | string |
Responses| Status | Description | Schema |
|---|
201 | The created variable. | pipeline_variable |
404 | The account does not exist. | error |
409 | A variable with the provided key already exists. | error |
GET/teams/{username}/pipelines_config/variables/{variable_uuid}Get a variable for a team
Parameters| Name | In | Required | Type |
|---|
username | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The variable. | pipeline_variable |
404 | The account or variable with the given UUID was not found. | error |
PUT/teams/{username}/pipelines_config/variables/{variable_uuid}Update a variable for a team
Parameters| Name | In | Required | Type |
|---|
username | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The variable was updated. | pipeline_variable |
404 | The account or the variable was not found. | error |
DELETE/teams/{username}/pipelines_config/variables/{variable_uuid}Delete a variable for a team
Parameters| Name | In | Required | Type |
|---|
username | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The variable was deleted | — |
404 | The account or the variable with the provided UUID does not exist. | error |
GET/users/{selected_user}/pipelines_config/variablesList variables for a user
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The found user level variables. | paginated_pipeline_variables |
POST/users/{selected_user}/pipelines_config/variablesCreate a variable for a user
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
Responses| Status | Description | Schema |
|---|
201 | The created variable. | pipeline_variable |
404 | The account does not exist. | error |
409 | A variable with the provided key already exists. | error |
GET/users/{selected_user}/pipelines_config/variables/{variable_uuid}Get a variable for a user
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The variable. | pipeline_variable |
404 | The account or variable with the given UUID was not found. | error |
PUT/users/{selected_user}/pipelines_config/variables/{variable_uuid}Update a variable for a user
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The variable was updated. | pipeline_variable |
404 | The account or the variable was not found. | error |
DELETE/users/{selected_user}/pipelines_config/variables/{variable_uuid}Delete a variable for a user
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The variable was deleted | — |
404 | The account or the variable with the provided UUID does not exist. | error |
GET/workspaces/{workspace}/pipelines-config/identity/oidc/.well-known/openid-configurationGet OpenID configuration for OIDC in Pipelines
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The OpenID configuration | — |
404 | The workspace was not found. | error |
GET/workspaces/{workspace}/pipelines-config/identity/oidc/keys.jsonGet keys for OIDC in Pipelines
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The keys in JSON web key format | — |
404 | The workspace was not found. | error |
GET/workspaces/{workspace}/pipelines-config/runnersGet workspace runners
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The workspace runners. | paginated_pipeline_runners |
POST/workspaces/{workspace}/pipelines-config/runnersCreate workspace runner
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The workspace runner. | pipeline_runner |
400 | The request body contained invalid properties or runner limit exceeded. | error |
409 | The workspace runner with the provided UUID already exists. | error |
GET/workspaces/{workspace}/pipelines-config/runners/{runner_uuid}Get workspace runner
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
runner_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The workspace runner. | pipeline_runner |
404 | The workspace runner was not found. | error |
PUT/workspaces/{workspace}/pipelines-config/runners/{runner_uuid}Update workspace runner
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
runner_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The workspace runner. | pipeline_runner |
404 | The workspace runner was not found. | error |
DELETE/workspaces/{workspace}/pipelines-config/runners/{runner_uuid}Delete workspace runner
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
runner_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The workspace runner was deleted. | — |
404 | The workspace runner was not found. | error |
GET/workspaces/{workspace}/pipelines-config/variablesList variables for a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The found workspace level variables. | paginated_pipeline_variables |
POST/workspaces/{workspace}/pipelines-config/variablesCreate a variable for a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
201 | The created variable. | pipeline_variable |
404 | The workspace does not exist. | error |
409 | A variable with the provided key already exists. | error |
GET/workspaces/{workspace}/pipelines-config/variables/{variable_uuid}Get variable for a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The variable. | pipeline_variable |
404 | The workspace or variable with the given UUID was not found. | error |
PUT/workspaces/{workspace}/pipelines-config/variables/{variable_uuid}Update variable for a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The variable was updated. | pipeline_variable |
404 | The workspace or the variable was not found. | error |
DELETE/workspaces/{workspace}/pipelines-config/variables/{variable_uuid}Delete a variable for a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
variable_uuid | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The variable was deleted | — |
404 | The workspace or the variable with the provided UUID does not exist. | error |
Projects16
Bitbucket Cloud projects make it easier for teams to focus on
a goal, product, or process by organizing their repositories.
POST/workspaces/{workspace}/projectsCreate a project in a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
201 | A new project has been created. | project |
403 | The user requesting to create a project does not have the necessary permissions. | error |
404 | A workspace doesn't exist at this location. | error |
GET/workspaces/{workspace}/projects/{project_key}Get a project for a workspace
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The project that is part of a workspace. | project |
401 | The request wasn't authenticated. | error |
403 | The requesting user isn't authorized to access the project. | error |
404 | A project isn't hosted at this location. | error |
PUT/workspaces/{workspace}/projects/{project_key}Update a project for a workspace
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The existing project is has been updated. | project |
201 | A new project has been created. | project |
403 | The requesting user isn't authorized to update or create the project. | error |
404 | A workspace doesn't exist at the location. Note that the project's absence from this location doesn't raise a 404, since a PUT at a non-existent location can be used to create a new project. | error |
DELETE/workspaces/{workspace}/projects/{project_key}Delete a project for a workspace
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Successful deletion. | — |
403 | The requesting user isn't authorized to delete the project or the project isn't empty. | error |
404 | A project isn't hosted at this location. | error |
GET/workspaces/{workspace}/projects/{project_key}/default-reviewersList the default reviewers in a project
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The list of project default reviewers | paginated_default_reviewer_and_type |
403 | If the authenticated user does not have admin access to the project | error |
404 | If the workspace or project does not exist at this location | error |
GET/workspaces/{workspace}/projects/{project_key}/default-reviewers/{selected_user}Get a default reviewer
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
selected_user | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specified user that is a default reviewer | user |
400 | If the specified user is not a default reviewer for the project | error |
403 | If the authenticated user does not have admin access to the project | error |
404 | If the specified user, project, or workspace does not exist | error |
PUT/workspaces/{workspace}/projects/{project_key}/default-reviewers/{selected_user}Add the specific user as a default reviewer for the project
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
selected_user | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specified user was added as a project default reviewer | user |
400 | If the specified user cannot be added as a default reviewer for the project | error |
403 | If the authenticated user does not have admin access to the project | error |
404 | If the specified user, project, or workspace does not exist | error |
DELETE/workspaces/{workspace}/projects/{project_key}/default-reviewers/{selected_user}Remove the specific user from the project's default reviewers
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
selected_user | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The specified user was removed from the list of project default reviewers | — |
400 | If the specified user is not a default reviewer for the project | error |
403 | If the authenticated user does not have admin access to the project | error |
404 | If the specified user, project, or workspace does not exist | error |
GET/workspaces/{workspace}/projects/{project_key}/permissions-config/groupsList explicit group permissions for a project
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Paginated list of project group permissions | paginated_project_group_permissions |
401 | The user couldn't be authenticated. | error |
403 | The user doesn't have admin access to the project. | error |
404 | One or both of the workspace and project don't exist for the given identifiers or the requesting user is not authenticated | error |
GET/workspaces/{workspace}/projects/{project_key}/permissions-config/groups/{group_slug}Get an explicit group permission for a project
Parameters| Name | In | Required | Type |
|---|
group_slug | path | yes | string |
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Project group permission | project_group_permission |
401 | The user couldn't be authenticated. | error |
403 | The user doesn't have admin access to the project. | error |
404 | One or more of the workspace, project, and group doesn't exist for the given identifiers or the requesting user is not authenticated | error |
PUT/workspaces/{workspace}/projects/{project_key}/permissions-config/groups/{group_slug}Update an explicit group permission for a project
Parameters| Name | In | Required | Type |
|---|
group_slug | path | yes | string |
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Project group permission updated. | project_group_permission |
400 | No permission value was provided or the value is invalid(not one of read, write, create-repo, or admin). | error |
401 | The user couldn't be authenticated. | error |
402 | You have reached your plan's user limit and must upgrade before giving access to additional users. | error |
403 | The requesting user isn't an admin of the project, or the authentication method was not via app password. | error |
404 | One or more of the workspace, project, and group doesn't exist for the given identifiers or the requesting user is not authenticated | error |
DELETE/workspaces/{workspace}/projects/{project_key}/permissions-config/groups/{group_slug}Delete an explicit group permission for a project
Parameters| Name | In | Required | Type |
|---|
group_slug | path | yes | string |
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The project group permission was deleted and no content returned. | — |
401 | The user couldn't be authenticated. | error |
403 | The requesting user isn't an admin of the project, or the authentication method was not via app password. | error |
404 | One or more of the workspace, project, and group doesn't exist for the given identifiers or the requesting user is not authenticated | error |
GET/workspaces/{workspace}/projects/{project_key}/permissions-config/usersList explicit user permissions for a project
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Paginated list of explicit user permissions. | paginated_project_user_permissions |
401 | The user couldn't be authenticated. | error |
403 | The user doesn't have admin access to the project. | error |
404 | One or both of the workspace and project don't exist for the given identifiers or the requesting user is not authenticated | error |
GET/workspaces/{workspace}/projects/{project_key}/permissions-config/users/{selected_user_id}Get an explicit user permission for a project
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
selected_user_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Explicit user permission for user and project | project_user_permission |
401 | The user couldn't be authenticated. | error |
403 | The requesting user isn't an admin of the project. | error |
404 | One or more of the workspace, project, and selected user doesn't exist for the given identifiers or the requesting user is not authenticated | error |
PUT/workspaces/{workspace}/projects/{project_key}/permissions-config/users/{selected_user_id}Update an explicit user permission for a project
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
selected_user_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Explicit user permission updated | project_user_permission |
400 | No permission value was provided or the value is invalid (not one of read, write, create-repo, or admin) | error |
401 | The user couldn't be authenticated. | error |
402 | You have reached your plan's user limit and must upgrade before giving access to additional users. | error |
403 | The requesting user isn't an admin of the project, or the authentication method was not via app password. | error |
404 | One or more of the workspace, project, and selected user doesn't exist for the given identifiers or the requesting user is not authenticated | error |
DELETE/workspaces/{workspace}/projects/{project_key}/permissions-config/users/{selected_user_id}Delete an explicit user permission for a project
Parameters| Name | In | Required | Type |
|---|
project_key | path | yes | string |
selected_user_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The project user permission was deleted and no content returned. | — |
401 | The user couldn't be authenticated. | error |
403 | The requesting user isn't an admin of the project, or the authentication method was not via app password. | error |
404 | One or more of the workspace, project, and selected user doesn't exist for the given identifiers or the requesting user is not authenticated | error |
Pullrequests37
Pull requests are a feature that makes it easier for developers
to collaborate using Bitbucket. They provide a user-friendly web
interface for discussing proposed changes before integrating them
into the official project.
GET/repositories/{workspace}/{repo_slug}/commit/{commit}/pullrequestsList pull requests that contain a commit
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
page | query | no | integer |
pagelen | query | no | integer |
Responses| Status | Description | Schema |
|---|
200 | The paginated list of pull requests. | paginated_pullrequests |
202 | The repository's pull requests are still being indexed. | paginated_pullrequests |
404 | Either the repository does not exist, or pull request commit links have not yet been indexed. | error |
GET/repositories/{workspace}/{repo_slug}/default-reviewersList default reviewers
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The paginated list of default reviewers | paginated_accounts |
403 | If the authenticated user does not have access to view the default reviewers | error |
GET/repositories/{workspace}/{repo_slug}/default-reviewers/{target_username}Get a default reviewer
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
target_username | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specified user is a default reviewer | account |
403 | If the authenticated user does not have access to check if the specified user is a default reviewer | error |
404 | If the specified user does not exist or is not a default reviewer | error |
PUT/repositories/{workspace}/{repo_slug}/default-reviewers/{target_username}Add a user to the default reviewers
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
target_username | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specified user was successfully added to the default reviewers | account |
400 | If the authenticated user tried to add a team, bot user, or user without access to the repository to the default reviewers | error |
403 | If the authenticated user does not have permission to modify the default reviewers | error |
404 | If the specified user does not exist | error |
DELETE/repositories/{workspace}/{repo_slug}/default-reviewers/{target_username}Remove a user from the default reviewers
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
target_username | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The specified user successfully removed from the default reviewers | — |
403 | If the authenticated user does not have access modify the default reviewers | error |
404 | If the specified user does not exist | error |
GET/repositories/{workspace}/{repo_slug}/effective-default-reviewersList effective default reviewers
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The paginated list of effective default reviewers | paginated_default_reviewer_and_type |
403 | If the authenticated user does not have access to view the default reviewers | error |
GET/repositories/{workspace}/{repo_slug}/pullrequestsList pull requests
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
state | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | All pull requests on the specified repository. | paginated_pullrequests |
401 | If the repository is private and the request was not authenticated. | — |
404 | If the specified repository does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/pullrequestsCreate a pull request
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — pullrequest
Responses| Status | Description | Schema |
|---|
201 | The newly created pull request. | pullrequest |
400 | If the input document was invalid, or if the caller lacks the privilege to create repositories under the targeted account. | error |
401 | If the request was not authenticated. | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/activityList a pull request activity log
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The pull request activity log | — |
401 | If the repository is private and the request was not authenticated. | — |
404 | If the specified repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}Get a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The pull request object | pullrequest |
401 | If the repository is private and the request was not authenticated. | — |
404 | If the repository or pull request does not exist | error |
PUT/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}Update a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — pullrequest
Responses| Status | Description | Schema |
|---|
200 | The updated pull request | pullrequest |
400 | If the input document was invalid. | error |
401 | If the request was not authenticated. | error |
404 | If the repository or pull request id does not exist | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/activityList a pull request activity log
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The pull request activity log | — |
401 | If the repository is private and the request was not authenticated. | — |
404 | If the specified repository does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/approveApprove a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The `participant` object recording that the authenticated user approved the pull request. | participant |
401 | The request wasn't authenticated. | error |
404 | The specified pull request or the repository does not exist. | error |
DELETE/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/approveUnapprove a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response indicating the authenticated user's approval has been withdrawn. | — |
400 | Pull request cannot be unapproved because the pull request has already been merged. | error |
401 | The request wasn't authenticated. | error |
404 | The specified pull request or the repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/commentsList comments on a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of comments made on the given pull request, in chronological order. | paginated_pullrequest_comments |
403 | If the authenticated user does not have access to the pull request. | error |
404 | If the pull request does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/commentsCreate a comment on a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — pullrequest_comment (required)
Responses| Status | Description | Schema |
|---|
201 | The newly created comment. | pullrequest_comment |
403 | If the authenticated user does not have access to the pull request. | error |
404 | If the pull request does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/comments/{comment_id}Get a comment on a pull request
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The comment. | pullrequest_comment |
403 | If the authenticated user does not have access to the pull request. | error |
404 | If the comment does not exist. | error |
PUT/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/comments/{comment_id}Update a comment on a pull request
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — pullrequest_comment (required)
Responses| Status | Description | Schema |
|---|
200 | The updated comment. | pullrequest_comment |
403 | If the authenticated user does not have access to the comment. | error |
404 | If the comment does not exist. | error |
DELETE/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/comments/{comment_id}Delete a comment on a pull request
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Successful deletion. | — |
403 | If the authenticated user does not have access to delete the comment. | error |
404 | If the comment does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/comments/{comment_id}/resolveResolve a comment thread
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The comment resolution details. | comment_resolution |
403 | If the authenticated user does not have access to the pull request,
if the provided comment is not a top-level comment,
or if the comment is not on the diff. | error |
404 | If the comment does not exist. | error |
409 | If the comment has already been resolved. | error |
DELETE/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/comments/{comment_id}/resolveReopen a comment thread
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The comment is reopened. | — |
403 | If the authenticated user does not have access to the pull request,
or if the provided comment is not a top-level comment. | error |
404 | If the comment does not exist, or if the comment has not been resolved | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/commitsList commits on a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of commits made on the given pull request, in chronological order. This list will be empty if the source branch no longer exists. | — |
403 | If the authenticated user does not have access to the pull request. | error |
404 | If the pull request does not exist or the source branch is from a forked repository which no longer exists. | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/conflictsGet file conflicts for a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
302 | Redirects to the [repository file conflicts](/cloud/bitbucket/rest/api-group-commits/#api-repositories-workspace-repo-slug-file-conflicts-spec-get) with the
revspec that corresponds to the pull request.
| — |
POST/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/declineDecline a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The pull request was successfully declined. | pullrequest |
555 | If the decline took too long and timed out.
In this case the caller should retry the request later. | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/diffList changes in a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
302 | Redirects to the [repository diff](/cloud/bitbucket/rest/api-group-commits/#api-repositories-workspace-repo-slug-diff-spec-get) with the
revspec that corresponds to the pull request.
| — |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/diffstatGet the diff stat for a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
302 | Redirects to the [repository diffstat](/cloud/bitbucket/rest/api-group-commits/#api-repositories-workspace-repo-slug-diffstat-spec-get) with
the revspec that corresponds to pull request.
| — |
POST/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/mergeMerge a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
async | query | no | boolean |
Request bodyapplication/json — pullrequest_merge_parameters
Responses| Status | Description | Schema |
|---|
200 | The pull request object. | pullrequest |
202 | In the Location header, the URL to poll for the pull request merge status | — |
409 | Unable to merge because one of the refs involved changed while attempting to merge | — |
555 | If the merge took too long and timed out.
In this case the caller should retry the request later | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/merge/task-status/{task_id}Get the merge task status for a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
task_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Returns a task status if the merge is either pending or successful, and if it is successful, a pull request | — |
400 | If the provided task ID does not relate to this pull request, or if something went wrong during the merge operation | — |
403 | The user making the request does not have permission to the repo and is different from the user who queued the task | — |
409 | Unable to merge because one of the refs involved changed while attempting to merge | — |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/patchGet the patch for a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
302 | Redirects to the [repository patch](/cloud/bitbucket/rest/api-group-commits/#api-repositories-workspace-repo-slug-patch-spec-get) with
the revspec that corresponds to pull request.
| — |
POST/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/request-changesRequest changes for a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The `participant` object recording that the authenticated user requested changes on the pull request. | participant |
400 | Pull request changes cannot be requested because the pull request has already been merged. | error |
401 | The request wasn't authenticated. | error |
404 | The specified pull request or the repository does not exist. | error |
DELETE/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/request-changesRemove change request for a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response indicating the authenticated user's request for change has been withdrawn. | — |
400 | Pull request requested changes cannot be removed because the pull request has already been merged. | error |
401 | The request wasn't authenticated. | error |
404 | The specified pull request or the repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/statusesList commit statuses for a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of all commit statuses for this pull request. | paginated_commitstatuses |
401 | If the repository is private and the request was not authenticated. | — |
404 | If the specified repository or pull request does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/tasksList tasks on a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
q | query | no | string |
sort | query | no | string |
pagelen | query | no | integer |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of pull request tasks for the given pull request. | paginated_tasks |
400 | If the user provides an invalid filter, sort, or fields query parameter. | error |
403 | If the authenticated user does not have access to the pull request. | error |
404 | If the pull request does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/tasksCreate a task on a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — pullrequest_task_create (required)
Responses| Status | Description | Schema |
|---|
201 | The newly created task. | pullrequest_comment_task |
400 | There is a missing required field in the request or the task content is blank. | error |
403 | If the authenticated user does not have access to the pull request. | error |
404 | If the pull request does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/tasks/{task_id}Get a task on a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
task_id | path | yes | integer |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The task. | pullrequest_comment_task |
403 | If the authenticated user does not have access to the pull request. | error |
404 | If the task does not exist. | error |
PUT/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/tasks/{task_id}Update a task on a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
task_id | path | yes | integer |
workspace | path | yes | string |
Request bodyapplication/json — pullrequest_task_update (required)
Responses| Status | Description | Schema |
|---|
200 | The updated task. | pullrequest_comment_task |
400 | There is a missing required field in the request or the task content is blank. | error |
403 | If the authenticated user does not have access to the pull request. | error |
404 | If the task does not exist. | error |
DELETE/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/tasks/{task_id}Delete a task on a pull request
Parameters| Name | In | Required | Type |
|---|
pull_request_id | path | yes | integer |
repo_slug | path | yes | string |
task_id | path | yes | integer |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Successful deletion. | — |
403 | If the authenticated user does not have access to delete the task. | error |
404 | If the task does not exist. | error |
Refs9
The refs resource allows you access branches and tags in a 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.
GET/repositories/{workspace}/{repo_slug}/refsList branches and tags
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of refs matching any filter criteria that were provided. | paginated_refs |
403 | If the repository is private and the authenticated user does not have
access to it.
| error |
404 | The specified repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/refs/branchesList open branches
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of branches matching any filter criteria that were provided. | paginated_branches |
403 | If the repository is private and the authenticated user does not have
access to it.
| error |
404 | The specified repository does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/refs/branchesCreate a branch
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
201 | The newly created branch object. | branch |
403 | If the repository is private and the authenticated user does not have
access to it.
| error |
404 | The specified repository or branch does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/refs/branches/{name}Get a branch
Parameters| Name | In | Required | Type |
|---|
name | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The branch object. | branch |
403 | If the repository is private and the authenticated user does not have
access to it.
| error |
404 | The specified repository or branch does not exist. | error |
DELETE/repositories/{workspace}/{repo_slug}/refs/branches/{name}Delete a branch
Parameters| Name | In | Required | Type |
|---|
name | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates that the specified branch was successfully deleted. | — |
403 | If the repository is private and the authenticated user does not have
access to it.
| error |
404 | The specified repository or branch does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/refs/tagsList tags
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of tags matching any filter criteria that were provided. | paginated_tags |
403 | If the repository is private and the authenticated user does not have
access to it.
| error |
404 | The specified repository does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/refs/tagsCreate a tag
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — tag (required)
Responses| Status | Description | Schema |
|---|
201 | The newly created tag. | tag |
400 | If the target hash is missing, ambiguous, or invalid, or if the name is not provided. | error |
GET/repositories/{workspace}/{repo_slug}/refs/tags/{name}Get a tag
Parameters| Name | In | Required | Type |
|---|
name | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The tag object. | tag |
403 | If the repository is private and the authenticated user does not have
access to it.
| error |
404 | The specified repository or tag does not exist. | error |
DELETE/repositories/{workspace}/{repo_slug}/refs/tags/{name}Delete a tag
Parameters| Name | In | Required | Type |
|---|
name | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates the specified tag was successfully deleted. | — |
403 | If the repository is private and the authenticated user does not have
access to it.
| error |
404 | The specified repository or tag does not exist. | error |
Reports9
Code insights provides reports, annotations, and metrics to help you
and your team improve code quality in pull requests throughout the code
review process. Some of the available code insights are static analysis
reports, security scan results, artifact links, unit tests, and build
status.
GET/repositories/{workspace}/{repo_slug}/commit/{commit}/reportsList reports
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | OK | paginated_reports |
GET/repositories/{workspace}/{repo_slug}/commit/{commit}/reports/{reportId}Get a report
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
reportId | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | OK | report |
404 | The report with the given ID was not found. | error |
PUT/repositories/{workspace}/{repo_slug}/commit/{commit}/reports/{reportId}Create or update a report
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
reportId | path | yes | string |
Request bodyapplication/json — report (required)
Responses| Status | Description | Schema |
|---|
200 | OK | report |
400 | The provided Report object is malformed or incomplete. | error |
DELETE/repositories/{workspace}/{repo_slug}/commit/{commit}/reports/{reportId}Delete a report
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
reportId | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | No content | — |
GET/repositories/{workspace}/{repo_slug}/commit/{commit}/reports/{reportId}/annotationsList annotations
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
reportId | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | OK | paginated_annotations |
POST/repositories/{workspace}/{repo_slug}/commit/{commit}/reports/{reportId}/annotationsBulk create or update annotations
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
reportId | path | yes | string |
Request bodyapplication/json (required)
Responses| Status | Description | Schema |
|---|
200 | OK | — |
GET/repositories/{workspace}/{repo_slug}/commit/{commit}/reports/{reportId}/annotations/{annotationId}Get an annotation
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
reportId | path | yes | string |
annotationId | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | OK | report_annotation |
404 | The annotation with the given ID was not found. | error |
PUT/repositories/{workspace}/{repo_slug}/commit/{commit}/reports/{reportId}/annotations/{annotationId}Create or update an annotation
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
reportId | path | yes | string |
annotationId | path | yes | string |
Request bodyapplication/json — report_annotation (required)
Responses| Status | Description | Schema |
|---|
200 | OK | report_annotation |
400 | The provided Annotation object is malformed or incomplete. | error |
DELETE/repositories/{workspace}/{repo_slug}/commit/{commit}/reports/{reportId}/annotations/{annotationId}Delete an annotation
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
reportId | path | yes | string |
annotationId | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | No content | — |
Repositories26
A Git repository is a virtual storage of your project. It
allows you to save versions of your code, which you can access
when needed. The repo resource allows you to access public repos,
or repos that belong to a specific workspace.
GET/repositoriesList public repositories
Parameters| Name | In | Required | Type |
|---|
after | query | no | string |
role | query | no | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | All public repositories. | paginated_repositories |
GET/repositories/{workspace}List repositories in a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
role | query | no | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | The repositories owned by the specified account. | paginated_repositories |
404 | If the specified account does not exist. | error |
410 | If the specified account marked as spam. | error |
GET/repositories/{workspace}/{repo_slug}Get a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The repository object. | repository |
403 | If the repository is private and the authenticated user does not have access to it. | error |
404 | If no repository exists at this location. | error |
POST/repositories/{workspace}/{repo_slug}Create a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — repository
Responses| Status | Description | Schema |
|---|
200 | The newly created repository. | repository |
400 | If the input document was invalid, or if the caller lacks the privilege to create repositories under the targeted account. | error |
401 | If the request was not authenticated. | error |
PUT/repositories/{workspace}/{repo_slug}Update a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — repository
Responses| Status | Description | Schema |
|---|
200 | The existing repository has been updated | repository |
201 | A new repository has been created | repository |
400 | If the input document was invalid, or if the caller lacks the privilege to create repositories under the targeted account. | error |
401 | If the request was not authenticated. | error |
DELETE/repositories/{workspace}/{repo_slug}Delete a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
redirect_to | query | no | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates successful deletion. | — |
403 | If the caller either does not have admin access to the repository, or the repository is set to read-only. | error |
404 | If the repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/forksList repository forks
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
role | query | no | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | All forks. | paginated_repositories |
POST/repositories/{workspace}/{repo_slug}/forksFork a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — repository
Responses| Status | Description | Schema |
|---|
201 | The newly created fork. | repository |
GET/repositories/{workspace}/{repo_slug}/hooksList webhooks for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The paginated list of installed webhooks. | paginated_webhook_subscriptions |
403 | If the authenticated user does not have permission to access the webhooks. | error |
404 | If the repository does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/hooksCreate a webhook for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
201 | If the webhook was registered successfully. | webhook_subscription |
403 | If the authenticated user does not have permission to install webhooks on the specified repository. | error |
404 | If the repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/hooks/{uid}Get a webhook for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
uid | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The webhook subscription object. | webhook_subscription |
404 | If the webhook or repository does not exist. | error |
PUT/repositories/{workspace}/{repo_slug}/hooks/{uid}Update a webhook for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
uid | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The webhook subscription object. | webhook_subscription |
403 | If the authenticated user does not have permission to update the webhook. | error |
404 | If the webhook or repository does not exist. | error |
DELETE/repositories/{workspace}/{repo_slug}/hooks/{uid}Delete a webhook for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
uid | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | When the webhook was deleted successfully | — |
403 | If the authenticated user does not have permission to delete the webhook. | error |
404 | If the webhook or repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/override-settingsRetrieve the inheritance state for repository settings
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The repository setting inheritance state | repository_inheritance_state |
404 | If no repository exists at this location | error |
PUT/repositories/{workspace}/{repo_slug}/override-settingsSet the inheritance state for repository settings
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The repository setting inheritance state was set and no content returned | — |
404 | If no repository exists at this location | error |
GET/repositories/{workspace}/{repo_slug}/permissions-config/groupsList explicit group permissions for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Paginated of explicit group permissions on the repository. | paginated_repository_group_permissions |
401 | The user couldn't be authenticated. | error |
403 | The requesting user isn't an admin of the repository. | error |
404 | One or both of the workspace and repository doesn't exist for the given identifiers. | error |
GET/repositories/{workspace}/{repo_slug}/permissions-config/groups/{group_slug}Get an explicit group permission for a repository
Parameters| Name | In | Required | Type |
|---|
group_slug | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Group permission for group slug and repository | repository_group_permission |
401 | The user couldn't be authenticated. | error |
403 | The requesting user isn't an admin of the repository. | error |
404 | The given user, workspace, and/or repository could not be found | error |
PUT/repositories/{workspace}/{repo_slug}/permissions-config/groups/{group_slug}Update an explicit group permission for a repository
Parameters| Name | In | Required | Type |
|---|
group_slug | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Group permission updated | repository_group_permission |
400 | No permission value was provided or the value is invalid(not one of read, write, or admin) | error |
401 | The user couldn't be authenticated. | error |
402 | You have reached your plan's user limit and must upgrade before giving access to additional users. | error |
403 | The requesting user isn't an admin of the repository, or the authentication method was not via app password. | error |
404 | The workspace does not exist, the repository does not exist, or the group does not exist. | error |
DELETE/repositories/{workspace}/{repo_slug}/permissions-config/groups/{group_slug}Delete an explicit group permission for a repository
Parameters| Name | In | Required | Type |
|---|
group_slug | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Group permission deleted | — |
401 | The user couldn't be authenticated. | error |
403 | The requesting user isn't an admin of the repository, or the authentication method was not via app password. | error |
404 | The workspace does not exist, the repository does not exist, or the group does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/permissions-config/usersList explicit user permissions for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Paginated of explicit user permissions on the repository. | paginated_repository_user_permissions |
401 | The user couldn't be authenticated. | error |
403 | The requesting user isn't an admin of the repository. | error |
404 | No repository exists for the given repository slug and workspace. | error |
GET/repositories/{workspace}/{repo_slug}/permissions-config/users/{selected_user_id}Get an explicit user permission for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
selected_user_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Explicit user permission for user and repository | repository_user_permission |
401 | The user couldn't be authenticated. | error |
403 | The requesting user isn't an admin of the repository. | error |
404 | One or both of the workspace and repository doesn't exist for the given identifiers. | error |
PUT/repositories/{workspace}/{repo_slug}/permissions-config/users/{selected_user_id}Update an explicit user permission for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
selected_user_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Explicit user permission updated | repository_user_permission |
400 | No permission value was provided or the value is invalid (not one of read, write, or admin), or the selected user is not a valid user to update. | error |
401 | The user couldn't be authenticated. | error |
402 | You have reached your plan's user limit and must upgrade before giving access to additional users. | error |
403 | The requesting user isn't an admin of the repository, or the authentication method was not via app password. | error |
404 | One or more of the workspace, repository, and selected user doesn't exist for the given identifiers. | error |
DELETE/repositories/{workspace}/{repo_slug}/permissions-config/users/{selected_user_id}Delete an explicit user permission for a repository
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
selected_user_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The repository user permission was deleted and no content returned. | — |
401 | The user couldn't be authenticated. | error |
403 | The requesting user isn't an admin of the repository, or the authentication method was not via app password. | error |
404 | One or more of the workspace, repository, and user doesn't exist for the given identifiers. | error |
GET/repositories/{workspace}/{repo_slug}/watchersList repositories watchers
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of all the watchers on the specified repository. | paginated_accounts |
GET/user/permissions/repositoriesList repository permissions for a user
Parameters| Name | In | Required | Type |
|---|
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | Repository permissions for the repositories a caller has explicit access to. | paginated_repository_permissions |
GET/user/workspaces/{workspace}/permissions/repositoriesList repository permissions in a workspace for a user
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | The list of repository permissions for the authenticated user in the specified workspace. | paginated_repository_permissions |
400 | The request was invalid. | error |
401 | The request wasn't authenticated. | error |
403 | The requesting user does not have access to the workspace. | error |
SSH5
The SSH resource allows you to manage SSH keys.
GET/users/{selected_user}/ssh-keysList SSH keys
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A list of the SSH keys associated with the account. | paginated_ssh_user_keys |
403 | If the specified user's keys are not accessible to the current user | — |
404 | If the specified user does not exist | error |
POST/users/{selected_user}/ssh-keysAdd a new SSH key
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
expires_on | query | no | string |
Request bodyapplication/json — ssh_account_key
Responses| Status | Description | Schema |
|---|
201 | The newly created SSH key. | ssh_account_key |
400 | If the submitted key or related value is invalid | error |
403 | If the current user does not have permission to add a key for the specified user | — |
404 | If the specified user does not exist | error |
GET/users/{selected_user}/ssh-keys/{key_id}Get a SSH key
Parameters| Name | In | Required | Type |
|---|
key_id | path | yes | string |
selected_user | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specific SSH key matching the user and UUID | ssh_account_key |
403 | If the specified user or key is not accessible to the current user | — |
404 | If the specified user or key does not exist | error |
PUT/users/{selected_user}/ssh-keys/{key_id}Update a SSH key
Parameters| Name | In | Required | Type |
|---|
key_id | path | yes | string |
selected_user | path | yes | string |
Request bodyapplication/json — ssh_account_key
Responses| Status | Description | Schema |
|---|
200 | The newly updated SSH key. | ssh_account_key |
400 | If the submitted key or related value is invalid | error |
403 | If the current user does not have permission to add a key for the specified user | — |
404 | If the specified user does not exist | error |
DELETE/users/{selected_user}/ssh-keys/{key_id}Delete a SSH key
Parameters| Name | In | Required | Type |
|---|
key_id | path | yes | string |
selected_user | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | The key has been deleted | — |
400 | If the submitted key or related value is invalid | error |
403 | If the current user does not have permission to add a key for the specified user | — |
404 | If the specified user does not exist | error |
Snippets25
Snippets allow you share code segments or files with yourself, members of
your workspace, or the world.
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).
GET/snippetsList snippets
Parameters| Name | In | Required | Type |
|---|
role | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of snippets. | paginated_snippets |
404 | If the snippet does not exist. | error |
POST/snippetsCreate a snippet
Responses| Status | Description | Schema |
|---|
201 | The newly created snippet object. | snippet |
401 | If the request was not authenticated | error |
GET/snippets/{workspace}List snippets in a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
role | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of snippets. | paginated_snippets |
404 | If the user does not exist. | error |
POST/snippets/{workspace}Create a snippet for a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
201 | The newly created snippet object. | snippet |
401 | If the request was not authenticated | error |
403 | If the authenticated user does not have permission to create snippets in the specified workspace. | error |
GET/snippets/{workspace}/{encoded_id}Get a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The snippet object. | snippet |
401 | If the snippet is private and the request was not authenticated. | error |
403 | If authenticated user does not have access to the private snippet. | error |
404 | If the snippet does not exist. | error |
410 | If the snippet marked as spam. | error |
PUT/snippets/{workspace}/{encoded_id}Update a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The updated snippet object. | snippet |
401 | If the snippet is private and the request was not authenticated. | error |
403 | If authenticated user does not have permission to update the private snippet. | error |
404 | If the snippet does not exist. | error |
DELETE/snippets/{workspace}/{encoded_id}Delete a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | If the snippet was deleted successfully. | — |
401 | If the snippet is private and the request was not authenticated. | error |
403 | If authenticated user does not have permission to delete the private snippet. | error |
404 | If the snippet does not exist. | error |
GET/snippets/{workspace}/{encoded_id}/commentsList comments on a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of snippet comments, ordered by creation date. | paginated_snippet_comments |
403 | If the authenticated user does not have access to the snippet. | error |
404 | If the snippet does not exist. | error |
POST/snippets/{workspace}/{encoded_id}/commentsCreate a comment on a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — snippet_comment (required)
Responses| Status | Description | Schema |
|---|
201 | The newly created comment. | snippet_comment |
403 | If the authenticated user does not have access to the snippet. | error |
404 | If the snippet does not exist. | error |
GET/snippets/{workspace}/{encoded_id}/comments/{comment_id}Get a comment on a snippet
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specified comment. | snippet_comment |
403 | If the authenticated user does not have access to the snippet. | error |
404 | If the comment or snippet does not exist. | error |
PUT/snippets/{workspace}/{encoded_id}/comments/{comment_id}Update a comment on a snippet
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
encoded_id | path | yes | string |
workspace | path | yes | string |
Request bodyapplication/json — snippet_comment (required)
Responses| Status | Description | Schema |
|---|
200 | The updated comment object. | snippet_comment |
403 | If the authenticated user does not have access to the snippet. | error |
404 | If the comment or snippet does not exist. | error |
DELETE/snippets/{workspace}/{encoded_id}/comments/{comment_id}Delete a comment on a snippet
Parameters| Name | In | Required | Type |
|---|
comment_id | path | yes | integer |
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates the comment was deleted successfully. | — |
403 | If the authenticated user is not the author of the comment. | error |
404 | If the comment or the snippet does not exist. | error |
GET/snippets/{workspace}/{encoded_id}/commitsList snippet changes
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The paginated list of snippet commits. | paginated_snippet_commit |
403 | If the authenticated user does not have access to the snippet. | error |
404 | If the snippet does not exist. | error |
GET/snippets/{workspace}/{encoded_id}/commits/{revision}Get a previous snippet change
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
revision | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The specified snippet commit. | snippet_commit |
403 | If the authenticated user does not have access to the snippet. | error |
404 | If the commit or the snippet does not exist. | error |
GET/snippets/{workspace}/{encoded_id}/files/{path}Get a snippet's raw file at HEAD
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
path | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
302 | A redirect to the most recent revision of the specified file. | — |
403 | If the authenticated user does not have access to the snippet. | error |
404 | If the snippet does not exist. | error |
GET/snippets/{workspace}/{encoded_id}/watchCheck if the current user is watching a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | If the authenticated user is watching the snippet. | — |
404 | If the snippet does not exist, or if the authenticated user is not watching the snippet. | error |
PUT/snippets/{workspace}/{encoded_id}/watchWatch a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates the authenticated user is now watching the snippet. | — |
401 | If the request was not authenticated. | error |
404 | If the snippet does not exist. | error |
DELETE/snippets/{workspace}/{encoded_id}/watchStop watching a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | Indicates the user stopped watching the snippet successfully. | — |
401 | If the request was not authenticated. | error |
404 | If the snippet does not exist. | error |
GET/snippets/{workspace}/{encoded_id}/watchersList users watching a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The paginated list of users watching this snippet | paginated_accounts |
404 | If the snippet does not exist. | error |
GET/snippets/{workspace}/{encoded_id}/{node_id}Get a previous revision of a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
node_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The snippet object. | snippet |
401 | If the snippet is private and the request was not authenticated. | error |
403 | If authenticated user does not have access to the private snippet. | error |
404 | If the snippet, or the revision does not exist. | error |
PUT/snippets/{workspace}/{encoded_id}/{node_id}Update a previous revision of a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
node_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The updated snippet object. | snippet |
401 | If the snippet is private and the request was not authenticated. | error |
403 | If authenticated user does not have permission to update the private snippet. | error |
404 | If the snippet or the revision does not exist. | error |
405 | If `{node_id}` is not the latest revision. | error |
DELETE/snippets/{workspace}/{encoded_id}/{node_id}Delete a previous revision of a snippet
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
node_id | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | If the snippet was deleted successfully. | — |
401 | If the snippet is private and the request was not authenticated. | error |
403 | If authenticated user does not have permission to delete the private snippet. | error |
404 | If the snippet does not exist. | error |
405 | If `{node_id}` is not the latest revision. | error |
GET/snippets/{workspace}/{encoded_id}/{node_id}/files/{path}Get a snippet's raw file
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
node_id | path | yes | string |
path | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | Returns the contents of the specified file. | — |
403 | If the authenticated user does not have access to the snippet. | error |
404 | If the file or snippet does not exist. | error |
GET/snippets/{workspace}/{encoded_id}/{revision}/diffGet snippet changes between versions
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
revision | path | yes | string |
workspace | path | yes | string |
path | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | The raw diff contents. | — |
403 | If the authenticated user does not have access to the snippet. | error |
404 | If the snippet does not exist. | error |
GET/snippets/{workspace}/{encoded_id}/{revision}/patchGet snippet patch between versions
Parameters| Name | In | Required | Type |
|---|
encoded_id | path | yes | string |
revision | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The raw patch contents. | — |
403 | If the authenticated user does not have access to the snippet. | error |
404 | If the snippet does not exist. | error |
Source4
Browse the source code in the repository and
create new commits by uploading.
GET/repositories/{workspace}/{repo_slug}/filehistory/{commit}/{path}List commits that modified a file
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
path | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
renames | query | no | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of commits that modified the specified file | paginated_files |
404 | If the repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/srcGet the root directory of the main branch
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
format | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | If the path matches a file, then the raw contents of the file are
returned (unless the `format=meta` query parameter was provided,
in which case a json document containing the file's meta data is
returned). If the path matches a directory, then a paginated
list of file and directory entries is returned (if the
`format=meta` query parameter was provided, then the json document
containing the directory's meta data is returned).
| paginated_treeentries |
404 | If the path or commit in the URL does not exist. | error |
POST/repositories/{workspace}/{repo_slug}/srcCreate a commit by uploading a file
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
message | query | no | string |
author | query | no | string |
parents | query | no | string |
files | query | no | string |
branch | query | no | string |
Responses| Status | Description | Schema |
|---|
201 |
| — |
403 | If the authenticated user does not have write or admin access | error |
404 | If the repository does not exist. | error |
GET/repositories/{workspace}/{repo_slug}/src/{commit}/{path}Get file or directory contents
Parameters| Name | In | Required | Type |
|---|
commit | path | yes | string |
path | path | yes | string |
repo_slug | path | yes | string |
workspace | path | yes | string |
format | query | no | string |
q | query | no | string |
sort | query | no | string |
max_depth | query | no | integer |
Responses| Status | Description | Schema |
|---|
200 | If the path matches a file, then the raw contents of the file are
returned. If the `format=meta` query parameter is provided,
a json document containing the file's meta data is
returned. If the `format=rendered` query parameter is provided,
the contents of the file in HTML-formated rendered markup is returned.
If the path matches a directory, then a paginated
list of file and directory entries is returned (if the
`format=meta` query parameter was provided, then the json document
containing the directory's meta data is returned.)
| paginated_treeentries |
404 | If the path or commit in the URL does not exist. | error |
555 | If the call times out, possibly because the specified recursion depth is too large. | error |
Users4
The users resource allows you to access public information
associated with a user account. Most resources in the users
endpoint have been deprecated in favor of workspaces.
GET/userGet current user
Responses| Status | Description | Schema |
|---|
200 | The current user. | account |
401 | When the request wasn't authenticated. | error |
GET/user/emailsList email addresses for current user
Responses| Status | Description | Schema |
|---|
default | Unexpected error. | error |
GET/user/emails/{email}Get an email address for current user
Parameters| Name | In | Required | Type |
|---|
email | path | yes | string |
Responses| Status | Description | Schema |
|---|
default | Unexpected error. | error |
GET/users/{selected_user}Get a user
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The user object | account |
404 | If no user exists for the specified UUID, or if the specified account is a team account, not a personal account. | error |
Webhooks2
Webhooks provide a way to configure Bitbucket Cloud to make requests to
your server (or another external service) whenever certain events occur in
Bitbucket Cloud.
A webhook consists of:
* A subject -- The resource that generates the events. Currently, this resource
is the repository, user account, or team where you create the webhook.
* One or more event -- The default event is a repository push, but you can
select multiple events that can trigger the webhook.
* A URL -- The endpoint where you want Bitbucket to send the event payloads
when a matching event happens.
There are two parts to getting a webhook to work: creating the webhook and
triggering the webhook. After you create a webhook for an event, every time
that event occurs, Bitbucket sends a payload request that describes the event
to the specified URL. Thus, you can think of webhooks as a kind of
notification system.
Use webhooks to integrate applications with Bitbucket Cloud. The following
use cases provides examples of when you would want to use webhooks:
* Every time a user pushes commits in a repository, you may want to notify
your CI server to start a build.
* Every time a user pushes commits or creates a pull request, you may want to
display a notification in your application.
GET/hook_eventsGet a webhook resource
Responses| Status | Description | Schema |
|---|
200 | A mapping of resource/subject types pointing to their individual event types. | subject_types |
GET/hook_events/{subject_type}List subscribable webhook types
Parameters| Name | In | Required | Type |
|---|
subject_type | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | A paginated list of webhook types available to subscribe on. | paginated_hook_events |
404 | If an invalid `{subject_type}` value was specified. | error |
Workspaces18
A workspace is where you create repositories, collaborate on
your code, and organize different streams of work in your Bitbucket
Cloud account. Workspaces replace the use of teams and users in API
calls.
GET/user/permissions/workspacesList workspaces for the current user
Parameters| Name | In | Required | Type |
|---|
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | All of the workspace memberships for the authenticated user. | paginated_workspace_memberships |
401 | The request wasn't authenticated. | error |
GET/user/workspacesList workspaces for the current user
Parameters| Name | In | Required | Type |
|---|
sort | query | no | string |
administrator | query | no | boolean |
Responses| Status | Description | Schema |
|---|
200 | The list of workspaces accessible by the authenticated user. | paginated_workspace_access |
400 | The request was invalid. | error |
401 | The request wasn't authenticated. | error |
GET/user/workspaces/{workspace}/permissionGet user permission on a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The user that is part of a workspace. | workspace_membership |
401 | The request wasn't authenticated. | error |
403 | The requesting user does not have access to the workspace. | error |
GET/workspacesList workspaces for user
Parameters| Name | In | Required | Type |
|---|
role | query | no | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | The list of workspaces accessible by the authenticated user. | paginated_workspaces |
401 | The request wasn't authenticated. | error |
GET/workspaces/{workspace}Get a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The workspace. | workspace |
404 | If no workspace exists for the specified name or UUID. | error |
GET/workspaces/{workspace}/hooksList webhooks for a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The paginated list of installed webhooks. | paginated_webhook_subscriptions |
403 | If the authenticated user is not an owner on the specified workspace. | error |
404 | If the specified workspace does not exist. | error |
POST/workspaces/{workspace}/hooksCreate a webhook for a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
201 | If the webhook was registered successfully. | webhook_subscription |
403 | If the authenticated user does not have permission to install webhooks on the specified workspace. | error |
404 | If the specified workspace does not exist. | error |
GET/workspaces/{workspace}/hooks/{uid}Get a webhook for a workspace
Parameters| Name | In | Required | Type |
|---|
uid | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The webhook subscription object. | webhook_subscription |
404 | If the webhook or workspace does not exist. | error |
PUT/workspaces/{workspace}/hooks/{uid}Update a webhook for a workspace
Parameters| Name | In | Required | Type |
|---|
uid | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The webhook subscription object. | webhook_subscription |
403 | If the authenticated user does not have permission to update the webhook. | error |
404 | If the webhook or workspace does not exist. | error |
DELETE/workspaces/{workspace}/hooks/{uid}Delete a webhook for a workspace
Parameters| Name | In | Required | Type |
|---|
uid | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | When the webhook was deleted successfully | — |
403 | If the authenticated user does not have permission to delete the webhook. | error |
404 | If the webhook or workspace does not exist. | error |
GET/workspaces/{workspace}/membersList users in a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The list of users that are part of a workspace. | paginated_workspace_memberships |
400 | When more than 90 emails were provided when querying by email. | error |
401 | The request wasn't authenticated. | error |
GET/workspaces/{workspace}/members/{member}Get user membership for a workspace
Parameters| Name | In | Required | Type |
|---|
member | path | yes | string |
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The user that is part of a workspace. | workspace_membership |
401 | The request wasn't authenticated. | error |
404 | A workspace cannot be found, or a user cannot be found, or the user is not a a member of the workspace. | error |
GET/workspaces/{workspace}/permissionsList user permissions in a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
q | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | The list of users that are part of a workspace, along with their permission. | paginated_workspace_memberships |
401 | The request wasn't authenticated. | error |
GET/workspaces/{workspace}/permissions/repositoriesList all repository permissions for a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | List of workspace's repository permissions. | paginated_repository_permissions |
403 | The requesting user isn't an admin of the workspace. | error |
GET/workspaces/{workspace}/permissions/repositories/{repo_slug}List a repository permissions for a workspace
Parameters| Name | In | Required | Type |
|---|
repo_slug | path | yes | string |
workspace | path | yes | string |
q | query | no | string |
sort | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | The repository permission for all users in this repository. | paginated_repository_permissions |
403 | The requesting user isn't an admin of the repository. | error |
GET/workspaces/{workspace}/projectsList projects in a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The list of projects in this workspace. | paginated_projects |
404 | A workspace doesn't exist at this location. | error |
GET/workspaces/{workspace}/pullrequests/{selected_user}List workspace pull requests for a user
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
workspace | path | yes | string |
state | query | no | string |
Responses| Status | Description | Schema |
|---|
200 | All pull requests authored by the specified user. | paginated_pullrequests |
404 | If the specified user does not exist. | error |
GET/workspaces/{workspace}/settings/gpg/public-keyGet the workspace system GPG public key(s)
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The system public GPG key(s). | — |
401 | The request wasn't authenticated. | error |
403 | The requesting user is not a workspace member. | error |
404 | The workspace does not exist. | error |
Search3
GET/teams/{username}/search/codeSearch for code in a team's repositories
Parameters| Name | In | Required | Type |
|---|
username | path | yes | string |
search_query | query | yes | string |
page | query | no | integer |
pagelen | query | no | integer |
Responses| Status | Description | Schema |
|---|
200 | Successful search | search_result_page |
400 | If the search request was invalid due to one of the
following reasons:
* the specified type of target account doesn''t match the actual
account type;
* malformed pagination properties;
* missing or malformed search query, in the latter case an error
key will be returned in `error.data.key` property.
| error |
404 | Search is not enabled for the requested team, navigate to [https://bitbucket.org/search](https://bitbucket.org/search) to turn it on | error |
429 | Too many requests, try again later | error |
GET/users/{selected_user}/search/codeSearch for code in a user's repositories
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
search_query | query | yes | string |
page | query | no | integer |
pagelen | query | no | integer |
Responses| Status | Description | Schema |
|---|
200 | Successful search | search_result_page |
400 | If the search request was invalid due to one of the
following reasons:
* the specified type of target account doesn''t match the actual
account type;
* malformed pagination properties;
* missing or malformed search query, in the latter case an error
key will be returned in `error.data.key` property.
| error |
404 | Search is not enabled for the requested user, navigate to [https://bitbucket.org/search](https://bitbucket.org/search) to turn it on | error |
429 | Too many requests, try again later | error |
GET/workspaces/{workspace}/search/codeSearch for code in a workspace
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
search_query | query | yes | string |
page | query | no | integer |
pagelen | query | no | integer |
Responses| Status | Description | Schema |
|---|
200 | Successful search | search_result_page |
400 | If the search request was invalid due to one of the
following reasons:
* the specified type of target account doesn''t match the actual
account type;
* malformed pagination properties;
* missing or malformed search query, in the latter case an error
key will be returned in `error.data.key` property.
| error |
404 | Search is not enabled for the requested workspace, navigate to [https://bitbucket.org/search](https://bitbucket.org/search) to turn it on | error |
429 | Too many requests, try again later | error |
properties12
GET/repositories/{workspace}/{repo_slug}/commit/{commit}/properties/{app_key}/{property_name}Get a commit application property
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The value of the property. | application_property |
PUT/repositories/{workspace}/{repo_slug}/commit/{commit}/properties/{app_key}/{property_name}Update a commit application property
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response. | — |
DELETE/repositories/{workspace}/{repo_slug}/commit/{commit}/properties/{app_key}/{property_name}Delete a commit application property
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
commit | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response. | — |
GET/repositories/{workspace}/{repo_slug}/properties/{app_key}/{property_name}Get a repository application property
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The value of the property. | application_property |
PUT/repositories/{workspace}/{repo_slug}/properties/{app_key}/{property_name}Update a repository application property
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response. | — |
DELETE/repositories/{workspace}/{repo_slug}/properties/{app_key}/{property_name}Delete a repository application property
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response. | — |
GET/repositories/{workspace}/{repo_slug}/pullrequests/{pullrequest_id}/properties/{app_key}/{property_name}Get a pull request application property
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pullrequest_id | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The value of the property. | application_property |
PUT/repositories/{workspace}/{repo_slug}/pullrequests/{pullrequest_id}/properties/{app_key}/{property_name}Update a pull request application property
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pullrequest_id | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response. | — |
DELETE/repositories/{workspace}/{repo_slug}/pullrequests/{pullrequest_id}/properties/{app_key}/{property_name}Delete a pull request application property
Parameters| Name | In | Required | Type |
|---|
workspace | path | yes | string |
repo_slug | path | yes | string |
pullrequest_id | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response. | — |
GET/users/{selected_user}/properties/{app_key}/{property_name}Get a user application property
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
200 | The value of the property. | application_property |
PUT/users/{selected_user}/properties/{app_key}/{property_name}Update a user application property
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response. | — |
DELETE/users/{selected_user}/properties/{app_key}/{property_name}Delete a user application property
Parameters| Name | In | Required | Type |
|---|
selected_user | path | yes | string |
app_key | path | yes | string |
property_name | path | yes | string |
Responses| Status | Description | Schema |
|---|
204 | An empty response. | — |