Bitbucket

Bitbucket logo

Bitbucket

Configuration

Bitbucket source connector integrates with the Bitbucket REST API to extract data.

Connects to your Bitbucket workspaces and repositories.

It supports syncing workspaces, repositories, directories, and code files with configurable filtering options for branches and file types.

Authentication

This connector uses a custom authentication configuration.

Authentication Configuration

Bitbucket authentication credentials schema.

Requires API token authentication with Atlassian email.

access_token
strRequired

Create a Bitbucket API token here with scopes:

  • account
  • read:user:bitbucket
  • read:workspace:bitbucket
  • read:repository:bitbucket

When using this, also provide your Atlassian email address.

email
strRequired

Your Atlassian email address (required for API token authentication)

workspace
strRequired

Bitbucket workspace slug (e.g., ‘my-workspace’)

repo_slug
Optional[str]

Specific repository to sync (e.g., ‘my-repo’). If empty, syncs all repositories in the workspace.

Configuration Options

The following configuration options are available for this connector:

Configuration Parameters

Bitbucket configuration schema.

branch
str

Specific branch to sync (e.g., ‘main’, ‘develop’). If empty, uses the default branch.

file_extensions
list[str]Defaults to []

List of file extensions to include (e.g., ‘.py’, ‘.js’, ‘.md’). If empty, includes all text files.

Data Models

The following data models are available for this connector:

Schema for Bitbucket workspace entity.

Reference: https://developer.atlassian.com/cloud/bitbucket/rest/api-group-workspaces/

FieldTypeDescription
slugstrWorkspace slug identifier
uuidstrWorkspace UUID
is_privateboolWhether the workspace is private
urlOptional[str]URL to view the workspace

Schema for Bitbucket repository entity.

Reference: https://developer.atlassian.com/cloud/bitbucket/rest/api-group-repositories/

FieldTypeDescription
slugstrRepository slug
full_namestrFull repository name including workspace
descriptionOptional[str]Repository description
is_privateboolWhether the repository is private
fork_policyOptional[str]Fork policy of the repository
languageOptional[str]Primary language of the repository
sizeOptional[int]Size of the repository in bytes
mainbranchOptional[str]Main branch name
workspace_slugstrSlug of the parent workspace
urlOptional[str]URL to view the repository

Schema for Bitbucket directory entity.

FieldTypeDescription
pathstrPath of the directory within the repository
repo_slugstrSlug of the repository containing this directory
repo_full_namestrFull name of the repository
workspace_slugstrSlug of the workspace
urlOptional[str]URL to view the directory

Schema for Bitbucket code file entity.

Reference: https://developer.atlassian.com/cloud/bitbucket/rest/api-group-source/

FieldTypeDescription
commit_hashOptional[str]Commit hash of the file version
repo_slugstrSlug of the repository
repo_full_namestrFull name of the repository
workspace_slugstrSlug of the workspace
line_countOptional[int]Number of lines in the file