Create an access token for a workspace
Access tokens for a workspace are a premium feature. To learn about the Bitbucket Cloud Premium plan, visit: Bitbucket Cloud Premium.
Access tokens for a workspace are single-purpose access tokens (or passwords) with access to a single workspace with limited permissions (specified at creation time). Use tokens for tasks such as scripting, CI/CD tools, and testing Bitbucket integrations or Marketplace apps while in development.
To create an access token for a workspace:
At bitbucket.org, navigate to the target workspace for the Access Token. This workspace is the only one that the Workspace Access Token can access.
On the sidebar, select Settings.
On the sidebar, under Security, select Access tokens.
Select Create access token.
Give the access token a name, usually related to the app or task that will use the token.
Under Expiry, select the date picker and select or input a specific date on which your access token will expire. The expiry date will need to be within the date range set by the workspace admin. Note: If a workspace admin does not require tokens to have an expiry date, the No expiry option will be available. Select the No expiry radio button to create your token with no expiry date, or you can select the Expires on radio button to set an expiry date for your token.
Select the permissions the access token needs. For detailed descriptions of each permission, see Workspace-level access token permissions.
Select the Create button. The page will display the Access token created dialog.
Copy the generated token and either record or paste it into the app that requires access. The token is only displayed once and can't be retrieved later. Rather than recovering or reusing a Workspace Access Token, create a new token and consider revoking the old token.
Access token expiry
For more information on setting up and requiring access token expiry, refer to Require access token expiry.
Was this helpful?