Creates a new Security instance with Basic or Bearer authentication credentials.
The base URL of the Bitbucket Data Center instance (e.g., https://bitbucket.example.com).
Must be a valid URL; throws if it cannot be parsed.
The username to authenticate with. Ignored when authType is 'bearer'.
The personal access token or password to authenticate with
The authentication scheme to use. Defaults to 'basic'.
Returns the base URL of the Bitbucket Data Center instance, without a trailing slash.
The API base URL
Returns the value of the Authorization header for Basic Authentication.
The Authorization header value in the format Basic <base64-encoded-credentials>
Returns the full set of HTTP headers required for authenticated API requests.
An object containing Authorization, Content-Type, and Accept headers
Handles authentication (Basic or Bearer) for Bitbucket Data Center REST API requests.
Example