• Addon
  • Branch restrictions
  • Branching model
  • Commit statuses
  • Commits
  • Deployments
  • Downloads
  • Issue tracker
  • Pipelines
  • Projects
  • Pullrequests
  • Refs
  • Reports
  • Repositories
  • Snippets
  • Source
  • Ssh
  • Users
  • Webhooks
  • Workspaces
  • Other operations
Cloud
Bitbucket Cloud / Reference / REST APIs

Deployments

Postman Collection
OpenAPI
GET

List repository deploy keys

Returns all deploy-keys belonging to a repository.

repository
,
repository:admin

Request

Path parameters

repo_slug

string

Required
workspace

string

Required

Responses

Deploy keys matching the repository

application/json

Paginated Deploy Keys

A paginated list of deploy keys.

GET/repositories/{workspace}/{repo_slug}/deploy-keys
1 2 3 4 curl --request GET \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/deploy-keys' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 { "pagelen": 10, "values": [ { "id": 123, "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAK/b1cHHDr/TEV1JGQl+WjCwStKG6Bhrv0rFpEsYlyTBm1fzN0VOJJYn4ZOPCPJwqse6fGbXntEs+BbXiptR+++HycVgl65TMR0b5ul5AgwrVdZdT7qjCOCgaSV74/9xlHDK8oqgGnfA7ZoBBU+qpVyaloSjBdJfLtPY/xqj4yHnXKYzrtn/uFc4Kp9Tb7PUg9Io3qohSTGJGVHnsVblq/rToJG7L5xIo0OxK0SJSQ5vuId93ZuFZrCNMXj8JDHZeSEtjJzpRCBEXHxpOPhAcbm4MzULgkFHhAVgp4JbkrT99/wpvZ7r9AdkTg7HGqL3rlaDrEcWfL7Lu6TnhBdq5", "label": "mykey", "type": "deploy_key", "created_on": "2018-08-15T23:50:59.993890+00:00", "repository": { "full_name": "mleu/test", "name": "test", "type": "repository", "uuid": "{85d08b4e-571d-44e9-a507-fa476535aa98}" }, "links": { "self": { "href": "https://api.bitbucket.org/2.0/repositories/mleu/test/deploy-keys/123" } }, "last_used": null, "comment": "mleu@C02W454JHTD8" } ], "page": 1, "size": 1 }
POST

Add a repository deploy key

Create a new deploy key in a repository. Note: If authenticating a deploy key with an OAuth consumer, any changes to the OAuth consumer will subsequently invalidate the deploy key.

Example:

1 2 3 4 5 6 7 8 $ curl -X POST \ -H "Authorization <auth header>" \ -H "Content-type: application/json" \ https://api.bitbucket.org/2.0/repositories/mleu/test/deploy-keys -d \ '{ "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAK/b1cHHDr/TEV1JGQl+WjCwStKG6Bhrv0rFpEsYlyTBm1fzN0VOJJYn4ZOPCPJwqse6fGbXntEs+BbXiptR+++HycVgl65TMR0b5ul5AgwrVdZdT7qjCOCgaSV74/9xlHDK8oqgGnfA7ZoBBU+qpVyaloSjBdJfLtPY/xqj4yHnXKYzrtn/uFc4Kp9Tb7PUg9Io3qohSTGJGVHnsVblq/rToJG7L5xIo0OxK0SJSQ5vuId93ZuFZrCNMXj8JDHZeSEtjJzpRCBEXHxpOPhAcbm4MzULgkFHhAVgp4JbkrT99/wpvZ7r9AdkTg7HGqL3rlaDrEcWfL7Lu6TnhBdq5 mleu@C02W454JHTD8", "label": "mydeploykey" }'
repository
,
repository:admin

Request

Path parameters

repo_slug

string

Required
workspace

string

Required

Responses

The deploy key that was created

application/json

allOf [object, Deploy Key]

object

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

Deploy Key

Represents deploy key for a repository.

POST/repositories/{workspace}/{repo_slug}/deploy-keys
1 2 3 4 curl --request POST \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/deploy-keys' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 { "id": 123, "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAK/b1cHHDr/TEV1JGQl+WjCwStKG6Bhrv0rFpEsYlyTBm1fzN0VOJJYn4ZOPCPJwqse6fGbXntEs+BbXiptR+++HycVgl65TMR0b5ul5AgwrVdZdT7qjCOCgaSV74/9xlHDK8oqgGnfA7ZoBBU+qpVyaloSjBdJfLtPY/xqj4yHnXKYzrtn/uFc4Kp9Tb7PUg9Io3qohSTGJGVHnsVblq/rToJG7L5xIo0OxK0SJSQ5vuId93ZuFZrCNMXj8JDHZeSEtjJzpRCBEXHxpOPhAcbm4MzULgkFHhAVgp4JbkrT99/wpvZ7r9AdkTg7HGqL3rlaDrEcWfL7Lu6TnhBdq5", "label": "mydeploykey", "type": "deploy_key", "created_on": "2018-08-15T23:50:59.993890+00:00", "repository": { "full_name": "mleu/test", "name": "test", "type": "repository", "uuid": "{85d08b4e-571d-44e9-a507-fa476535aa98}" }, "links": { "self": { "href": "https://api.bitbucket.org/2.0/repositories/mleu/test/deploy-keys/123" } }, "last_used": null, "comment": "mleu@C02W454JHTD8" }
GET

Get a repository deploy key

Returns the deploy key belonging to a specific key.

repository
,
repository:admin

Request

Path parameters

key_id

string

Required
repo_slug

string

Required
workspace

string

Required

Responses

Deploy key matching the key ID

application/json

allOf [object, Deploy Key]

object

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

Deploy Key

Represents deploy key for a repository.

GET/repositories/{workspace}/{repo_slug}/deploy-keys/{key_id}
1 2 3 4 curl --request GET \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/deploy-keys/{key_id}' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 { "comment": "mleu@C02W454JHTD8", "last_used": null, "links": { "self": { "href": "https://api.bitbucket.org/2.0/repositories/mleu/test/deploy-key/1234" } }, "repository": { "full_name": "mleu/test", "name": "test", "type": "repository", "uuid": "{85d08b4e-571d-44e9-a507-fa476535aa98}" }, "label": "mykey", "created_on": "2018-08-15T23:50:59.993890+00:00", "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAK/b1cHHDr/TEV1JGQl+WjCwStKG6Bhrv0rFpEsYlyTBm1fzN0VOJJYn4ZOPCPJwqse6fGbXntEs+BbXiptR+++HycVgl65TMR0b5ul5AgwrVdZdT7qjCOCgaSV74/9xlHDK8oqgGnfA7ZoBBU+qpVyaloSjBdJfLtPY/xqj4yHnXKYzrtn/uFc4Kp9Tb7PUg9Io3qohSTGJGVHnsVblq/rToJG7L5xIo0OxK0SJSQ5vuId93ZuFZrCNMXj8JDHZeSEtjJzpRCBEXHxpOPhAcbm4MzULgkFHhAVgp4JbkrT99/wpvZ7r9AdkTg7HGqL3rlaDrEcWfL7Lu6TnhBdq5", "id": 1234, "type": "deploy_key" }
PUT

Update a repository deploy key

Create a new deploy key in a repository.

The same key needs to be passed in but the comment and label can change.

Example:

1 2 3 4 5 6 7 8 $ curl -X PUT \ -H "Authorization <auth header>" \ -H "Content-type: application/json" \ https://api.bitbucket.org/2.0/repositories/mleu/test/deploy-keys/1234 -d \ '{ "label": "newlabel", "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAK/b1cHHDr/TEV1JGQl+WjCwStKG6Bhrv0rFpEsYlyTBm1fzN0VOJJYn4ZOPCPJwqse6fGbXntEs+BbXiptR+++HycVgl65TMR0b5ul5AgwrVdZdT7qjCOCgaSV74/9xlHDK8oqgGnfA7ZoBBU+qpVyaloSjBdJfLtPY/xqj4yHnXKYzrtn/uFc4Kp9Tb7PUg9Io3qohSTGJGVHnsVblq/rToJG7L5xIo0OxK0SJSQ5vuId93ZuFZrCNMXj8JDHZeSEtjJzpRCBEXHxpOPhAcbm4MzULgkFHhAVgp4JbkrT99/wpvZ7r9AdkTg7HGqL3rlaDrEcWfL7Lu6TnhBdq5 newcomment", }'
repository
,
repository:admin

Request

Path parameters

key_id

string

Required
repo_slug

string

Required
workspace

string

Required

Responses

The newly updated deploy key.

application/json

allOf [object, Deploy Key]

object

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

Deploy Key

Represents deploy key for a repository.

PUT/repositories/{workspace}/{repo_slug}/deploy-keys/{key_id}
1 2 3 4 curl --request PUT \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/deploy-keys/{key_id}' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 { "comment": "newcomment", "last_used": null, "links": { "self": { "href": "https://api.bitbucket.org/2.0/repositories/mleu/test/deploy-keys/1234" } }, "repository": { "full_name": "mleu/test", "name": "test", "type": "repository", "uuid": "{85d08b4e-571d-44e9-a507-fa476535aa98}" }, "label": "newlabel", "created_on": "2018-08-15T23:50:59.993890+00:00", "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAK/b1cHHDr/TEV1JGQl+WjCwStKG6Bhrv0rFpEsYlyTBm1fzN0VOJJYn4ZOPCPJwqse6fGbXntEs+BbXiptR+++HycVgl65TMR0b5ul5AgwrVdZdT7qjCOCgaSV74/9xlHDK8oqgGnfA7ZoBBU+qpVyaloSjBdJfLtPY/xqj4yHnXKYzrtn/uFc4Kp9Tb7PUg9Io3qohSTGJGVHnsVblq/rToJG7L5xIo0OxK0SJSQ5vuId93ZuFZrCNMXj8JDHZeSEtjJzpRCBEXHxpOPhAcbm4MzULgkFHhAVgp4JbkrT99/wpvZ7r9AdkTg7HGqL3rlaDrEcWfL7Lu6TnhBdq5", "id": 1234, "type": "deploy_key" }
DEL

Delete a repository deploy key

This deletes a deploy key from a repository.

repository
,
repository:admin

Request

Path parameters

key_id

string

Required
repo_slug

string

Required
workspace

string

Required

Responses

The key has been deleted

DEL/repositories/{workspace}/{repo_slug}/deploy-keys/{key_id}
1 2 3 curl --request DELETE \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/deploy-keys/{key_id}' \ --header 'Authorization: Bearer <access_token>'
GET

List deployments

Find deployments

pipeline

Request

Path parameters

workspace

string

Required
repo_slug

string

Required

Responses

The matching deployments.

application/json

Paginated Deployments

A paged list of deployments

GET/repositories/{workspace}/{repo_slug}/deployments
1 2 3 4 curl --request GET \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/deployments' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 { "page": 102, "values": [ { "type": "<string>", "uuid": "<string>", "state": { "type": "<string>" }, "environment": { "type": "<string>" }, "release": { "type": "<string>" } } ], "size": 142, "pagelen": 159, "next": "<string>", "previous": "<string>" }
GET

Get a deployment

Retrieve a deployment

pipeline

Request

Path parameters

workspace

string

Required
repo_slug

string

Required
deployment_uuid

string

Required

Responses

The deployment.

application/json

allOf [object, Deployment]

object

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

Deployment

A Bitbucket Deployment.

GET/repositories/{workspace}/{repo_slug}/deployments/{deployment_uuid}
1 2 3 4 curl --request GET \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/deployments/{deployment_uuid}' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 6 7 8 9 10 11 12 13 { "type": "<string>", "uuid": "<string>", "state": { "type": "<string>" }, "environment": { "type": "<string>" }, "release": { "type": "<string>" } }
GET

List environments

Find environments

pipeline

Request

Path parameters

workspace

string

Required
repo_slug

string

Required

Responses

The matching environments.

application/json

Paginated Deployment Environments

A paged list of environments

GET/repositories/{workspace}/{repo_slug}/environments
1 2 3 4 curl --request GET \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/environments' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 { "page": 102, "values": [ { "type": "<string>", "uuid": "<string>", "name": "<string>" } ], "size": 142, "pagelen": 159, "next": "<string>", "previous": "<string>" }
POST

Create an environment

Create an environment.

pipeline

Request

Path parameters

workspace

string

Required
repo_slug

string

Required

Request bodyapplication/json

The environment to create.

allOf [object, Deployment Environment]

object

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

Deployment Environment

A Bitbucket Deployment Environment.

Responses

The environment was created.

Headers

Location

string

application/json

allOf [object, Deployment Environment]

object

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

Deployment Environment

A Bitbucket Deployment Environment.

POST/repositories/{workspace}/{repo_slug}/environments
1 2 3 4 5 6 7 8 9 10 curl --request POST \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/environments' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json' \ --header 'Content-Type: application/json' \ --data '{ "type": "<string>", "uuid": "<string>", "name": "<string>" }'
201Response
1 2 3 4 5 { "type": "<string>", "uuid": "<string>", "name": "<string>" }
GET

Get an environment

Retrieve an environment

pipeline

Request

Path parameters

workspace

string

Required
repo_slug

string

Required
environment_uuid

string

Required

Responses

The environment.

application/json

allOf [object, Deployment Environment]

object

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

Deployment Environment

A Bitbucket Deployment Environment.

GET/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}
1 2 3 4 curl --request GET \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 { "type": "<string>", "uuid": "<string>", "name": "<string>" }
DEL

Delete an environment

Delete an environment

pipeline

Request

Path parameters

workspace

string

Required
repo_slug

string

Required
environment_uuid

string

Required

Responses

The environment was deleted.

DEL/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}
1 2 3 curl --request DELETE \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}' \ --header 'Authorization: Bearer <access_token>'
POST

Update an environment

Update an environment

pipeline

Request

Path parameters

workspace

string

Required
repo_slug

string

Required
environment_uuid

string

Required

Responses

The environment update request was accepted.

POST/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}/changes
1 2 3 curl --request POST \ --url 'https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/environments/{environment_uuid}/changes' \ --header 'Authorization: Bearer <access_token>'
GET

List project deploy keys

Returns all deploy keys belonging to a project.

project
,
project:admin

Request

Path parameters

project_key

string

Required
workspace

string

Required

Responses

Deploy keys matching the project

application/json

Paginated Project Deploy Keys

A paginated list of project deploy keys.

GET/workspaces/{workspace}/projects/{project_key}/deploy-keys
1 2 3 4 curl --request GET \ --url 'https://api.bitbucket.org/2.0/workspaces/{workspace}/projects/{project_key}/deploy-keys' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 { "pagelen": 10, "values": [ { "comment": "thakseth@C02W454JHTD8", "last_used": null, "links": { "self": { "href": "https://api.bitbucket.org/2.0/workspaces/standard/projects/TEST_PROJECT/deploy-keys/1234" } }, "label": "test", "project": { "links": { "self": { "href": "https://api.bitbucket.org/2.0/workspaces/standard/projects/TEST_PROJECT" } }, "type": "project", "name": "cooperative standard", "key": "TEST_PROJECT", "uuid": "{3b3e510b-7f2b-414d-a2b7-76c4e405c1c0}" }, "created_on": "2021-07-28T21:20:19.491721+00:00", "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDX5yfMOEw6HG9jKTYTisbmDTJ4MCUTSVGr5e4OWvY3UuI2A6F8SdzQqa2f5BABA/4g5Sk5awJrYHlNu3EzV1V2I44tR3A4fnZAG71ZKyDPi1wvdO7UYmFgxV/Vd18H9QZFFjICGDM7W0PT2mI0kON/jN3qNWi+GiB/xgaeQKSqynysdysDp8lnnI/8Sh3ikURP9UP83ShRCpAXszOUNaa+UUlcYQYBDLIGowsg51c4PCkC3DNhAMxppkNRKoSOWwyl+oRVXHSDylkiJSBHW3HH4Q6WHieD54kGrjbhWBKdnnxKX7QAAZBDseY+t01N36m6/ljvXSUEcBWtHxBYye0r", "type": "project_deploy_key", "id": 1234 } ], "page": 1, "size": 1 }
POST

Create a project deploy key

Create a new deploy key in a project.

Example:

1 2 3 4 5 6 7 8 $ curl -X POST \ -H "Authorization <auth header>" \ -H "Content-type: application/json" \ https://api.bitbucket.org/2.0/workspaces/standard/projects/TEST_PROJECT/deploy-keys/ -d \ '{ "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAK/b1cHHDr/TEV1JGQl+WjCwStKG6Bhrv0rFpEsYlyTBm1fzN0VOJJYn4ZOPCPJwqse6fGbXntEs+BbXiptR+++HycVgl65TMR0b5ul5AgwrVdZdT7qjCOCgaSV74/9xlHDK8oqgGnfA7ZoBBU+qpVyaloSjBdJfLtPY/xqj4yHnXKYzrtn/uFc4Kp9Tb7PUg9Io3qohSTGJGVHnsVblq/rToJG7L5xIo0OxK0SJSQ5vuId93ZuFZrCNMXj8JDHZeSEtjJzpRCBEXHxpOPhAcbm4MzULgkFHhAVgp4JbkrT99/wpvZ7r9AdkTg7HGqL3rlaDrEcWfL7Lu6TnhBdq5 mleu@C02W454JHTD8", "label": "mydeploykey" }'
project
,
project:admin

Request

Path parameters

project_key

string

Required
workspace

string

Required

Responses

The project deploy key that was created

application/json

allOf [object, Project Deploy Key]

object

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

Project Deploy Key

Represents deploy key for a project.

POST/workspaces/{workspace}/projects/{project_key}/deploy-keys
1 2 3 4 curl --request POST \ --url 'https://api.bitbucket.org/2.0/workspaces/{workspace}/projects/{project_key}/deploy-keys' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 { "comment": "mleu@C02W454JHTD8", "last_used": null, "links": { "self": { "href": "https://api.bitbucket.org/2.0/workspaces/standard/projects/TEST_PROJECT/deploy-keys/5/" } }, "label": "myprojectkey", "project": { "links": { "self": { "href": "https://api.bitbucket.org/2.0/workspaces/standard/projects/TEST_PROJECT" } }, "type": "project", "name": "cooperative standard", "key": "TEST_PROJECT", "uuid": "{3b3e510b-7f2b-414d-a2b7-76c4e405c1c0}" }, "created_on": "2021-08-10T05:28:00.570859+00:00", "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDAK/b1cHHDr/TEV1JGQl+WjCwStKG6Bhrv0rFpEsYlyTBm1fzN0VOJJYn4ZOPCPJwqse6fGbXntEs+BbXiptR+++HycVgl65TMR0b5ul5AgwrVdZdT7qjCOCgaSV74/9xlHDK8oqgGnfA7ZoBBU+qpVyaloSjBdJfLtPY/xqj4yHnXKYzrtn/uFc4Kp9Tb7PUg9Io3qohSTGJGVHnsVblq/rToJG7L5xIo0OxK0SJSQ5vuId93ZuFZrCNMXj8JDHZeSEtjJzpRCBEXHxpOPhAcbm4MzULgkFHhAVgp4JbkrT99/wpvZ7r9AdkTg7HGqL3rlaDrEcWfL7Lu6TnhBdq5", "type": "project_deploy_key", "id": 5 }
GET

Get a project deploy key

Returns the deploy key belonging to a specific key ID.

project
,
project:admin

Request

Path parameters

key_id

string

Required
project_key

string

Required
workspace

string

Required

Responses

Project deploy key matching the key ID

application/json

allOf [object, Project Deploy Key]

object

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

Project Deploy Key

Represents deploy key for a project.

GET/workspaces/{workspace}/projects/{project_key}/deploy-keys/{key_id}
1 2 3 4 curl --request GET \ --url 'https://api.bitbucket.org/2.0/workspaces/{workspace}/projects/{project_key}/deploy-keys/{key_id}' \ --header 'Authorization: Bearer <access_token>' \ --header 'Accept: application/json'
200Response
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 { "pagelen": 10, "values": [ { "comment": "thakseth@C02W454JHTD8", "last_used": null, "links": { "self": { "href": "https://api.bitbucket.org/2.0/workspaces/standard/projects/TEST_PROJECT/deploy-keys/1234" } }, "label": "test", "project": { "links": { "self": { "href": "https://api.bitbucket.org/2.0/workspaces/standard/projects/TEST_PROJECT" } }, "type": "project", "name": "cooperative standard", "key": "TEST_PROJECT", "uuid": "{3b3e510b-7f2b-414d-a2b7-76c4e405c1c0}" }, "created_on": "2021-07-28T21:20:19.491721+00:00", "key": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDX5yfMOEw6HG9jKTYTisbmDTJ4MCUTSVGr5e4OWvY3UuI2A6F8SdzQqa2f5BABA/4g5Sk5awJrYHlNu3EzV1V2I44tR3A4fnZAG71ZKyDPi1wvdO7UYmFgxV/Vd18H9QZFFjICGDM7W0PT2mI0kON/jN3qNWi+GiB/xgaeQKSqynysdysDp8lnnI/8Sh3ikURP9UP83ShRCpAXszOUNaa+UUlcYQYBDLIGowsg51c4PCkC3DNhAMxppkNRKoSOWwyl+oRVXHSDylkiJSBHW3HH4Q6WHieD54kGrjbhWBKdnnxKX7QAAZBDseY+t01N36m6/ljvXSUEcBWtHxBYye0r", "type": "project_deploy_key", "id": 1234 } ] }
DEL

Delete a deploy key from a project

This deletes a deploy key from a project.

project
,
project:admin

Request

Path parameters

key_id

string

Required
project_key

string

Required
workspace

string

Required

Responses

The project deploy key has been deleted

DEL/workspaces/{workspace}/projects/{project_key}/deploy-keys/{key_id}
1 2 3 curl --request DELETE \ --url 'https://api.bitbucket.org/2.0/workspaces/{workspace}/projects/{project_key}/deploy-keys/{key_id}' \ --header 'Authorization: Bearer <access_token>'

Rate this page: