Deployments

Create an environment

Create an environment.

post/repositories/{workspace}/{repo_slug}/environments

Request

  • Base URL
    https://api.bitbucket.org/2.0
  • URL
    https://api.bitbucket.org/2.0/repositories/{workspace}/{repo_slug}/environments
  • Auth
    • OAuth 2
      Authorization code: https://bitbucket.org/site/oauth2/authorize
      Token URL: https://bitbucket.org/site/oauth2/access_token scopes: pipeline
    • or HTTP basic
    • or API key in header Authorization

Path parameters

workspacestring required

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

repo_slugstring required

The repository.

Request body

typestring required
uuidstring

The UUID identifying the environment.

namestring

The name of the environment.

Response

The environment was created.

typestring required
uuidstring

The UUID identifying the environment.

namestring

The name of the environment.

Changes

No recorded changes to this operation across all 15 revisions of this API.