Skip to main content

Interface: BitbucketOptions

Bitbucket options. https://bitbucket.org/ Define BITBUCKET_TOKEN environment variable.

Bitbucket Cloud is retiring app passwords in favor of API tokens and access tokens. Authentication is selected by whether a username is provided:

  • With username — the token is sent via HTTP Basic auth. Use a Bitbucket username + app password, or an Atlassian account email + API token.
  • Without username — the token is sent as a repository/project/workspace access token via Bearer auth.

For the auto-updater on a private repository, pass the matching header to autoUpdater.addAuthHeader(...):

// access token (no username)
autoUpdater.addAuthHeader(`Bearer ${token}`)
// app password or API token (with username)
autoUpdater.addAuthHeader(`Basic ${Buffer.from(`${username}:${token}`).toString("base64")}`)

Extends

Properties

channel?

readonly optional channel?: string | null

The channel.

Default

latest

owner

readonly owner: string

Repository owner


provider

readonly provider: "bitbucket"

The provider. Must be bitbucket.

Overrides

PublishConfiguration.provider


publishAutoUpdate?

readonly optional publishAutoUpdate?: boolean

Whether to publish auto update info files.

Auto update relies only on the first provider in the list (you can specify several publishers). Thus, probably, there`s no need to upload the metadata files for the other configured providers. But by default will be uploaded.

Default

true

Inherited from

PublishConfiguration.publishAutoUpdate


requestHeaders?

readonly optional requestHeaders?: OutgoingHttpHeaders

Any custom request headers

Inherited from

PublishConfiguration.requestHeaders


slug

readonly slug: string

Repository slug/name


timeout?

readonly optional timeout?: number | null

Request timeout in milliseconds. (Default is 2 minutes; O is ignored)

Default

120000

Inherited from

PublishConfiguration.timeout


token?

readonly optional token?: string | null

The token to support auto-update from private bitbucket repositories. Depending on username, this is a Bitbucket app password, an Atlassian API token, or a repository/project/workspace access token.


username?

readonly optional username?: string | null

The user name to support auto-update from private bitbucket repositories. Provide a Bitbucket username (for an app password) or an Atlassian account email (for an API token) to authenticate with HTTP Basic auth. Leave unset to send token as a Bearer access token.