Credential
A Git credential that Databricks uses to authenticate to a Git provider on behalf of a user or service principal. Each user has one default credential per Git provider, which is used when no specific credential is selected.
Credential object
A Git credential that Databricks uses to authenticate to a Git provider on behalf of a user or service principal. Each user has one default credential per Git provider, which is used when no specific credential is selected.
- credential_idint64
ID of the credential object in the workspace.
- git_providerstring
The Git provider associated with the credential. One of
gitHub,bitbucketCloud,gitLab,azureDevOpsServices(Azure DevOps Services, including Microsoft Entra ID authentication),gitHubEnterprise,bitbucketServer(Bitbucket Data Center),gitLabEnterpriseEdition(GitLab Self-Managed), orawsCodeCommit.
- git_usernamestring
The username provided with your Git provider account and associated with the credential. For most Git providers it is only used to set the Git committer & author names for commits, however it may be required for authentication depending on your Git provider / token requirements. Required for AWS CodeCommit.
- namestringPublic Preview
The name of the Git credential, used for identification and ease of lookup.
- is_default_for_providerbooleanPublic Preview
Whether this credential is the default for its Git provider. The default credential is the fallback that is used when no specific credential is selected. See https://docs.databricks.com/aws/en/repos/repos-setup#how-default-credentials-work.
- git_emailstring
The authenticating email associated with your Git provider user account. Used for authentication with the remote repository and also sets the author & committer identity for commits. Required for most Git providers except AWS CodeCommit. Learn more at https://docs.databricks.com/aws/en/repos/get-access-tokens-from-git-provider
Get a credential entry GA
GET
Gets the Git credential with the specified credential ID.
API scopes: workspace
Parameters
- idint64Requiredpath
The ID for the corresponding credential to access.
- principal_idint64query
The ID of the service principal whose credential will be returned. Only service principal managers can perform this action.
Response
- credential_idint64Required
ID of the credential object in the workspace.
- git_providerstring
The Git provider associated with the credential.
- git_usernamestring
The username provided with your Git provider account and associated with the credential. For most Git providers it is only used to set the Git committer & author names for commits, however it may be required for authentication depending on your Git provider / token requirements. Required for AWS CodeCommit.
- namestringPublic Preview
The name of the Git credential, used for identification and ease of lookup.
- is_default_for_providerbooleanPublic Preview
Whether this credential is the default for its Git provider. The default credential is the fallback that is used when no specific credential is selected.
- git_emailstring
The authenticating email associated with your Git provider user account. Used for authentication with the remote repository and also sets the author & committer identity for commits. Required for most Git providers except AWS CodeCommit. Learn more at https://docs.databricks.com/aws/en/repos/get-access-tokens-from-git-provider
Get Git credentials GA
GET
Lists the calling user's Git credentials.
API scopes: workspace
Parameters
- principal_idint64query
The ID of the service principal whose credentials will be listed. Only service principal managers can perform this action.
Response
Returns a list of Credential objects.
Create a credential entry GA
POST
Creates a Git credential entry for the user. Use the PATCH endpoint to update existing credentials, or the DELETE endpoint to delete existing credentials.
API scopes: workspace
Request body
- git_providerstringRequired
Git provider. This field is case-insensitive. The available Git providers are
gitHub,bitbucketCloud,gitLab,azureDevOpsServices(Azure DevOps Services, including Microsoft Entra ID authentication),gitHubEnterprise,bitbucketServer(Bitbucket Data Center),gitLabEnterpriseEdition(GitLab Self-Managed), andawsCodeCommit.
- git_usernamestring
The username provided with your Git provider account and associated with the credential. For most Git providers it is only used to set the Git committer & author names for commits, however it may be required for authentication depending on your Git provider / token requirements. Required for AWS CodeCommit.
- personal_access_tokenstring
The personal access token used to authenticate to the corresponding Git provider. For certain providers, support may exist for other types of scoped access tokens. Learn more.
- principal_idint64
The ID of the service principal for which the credential will be created. Only service principal managers can perform this action.
- namestringPublic Preview
The name of the Git credential, used for identification and ease of lookup. It must not exceed 100 characters.
- is_default_for_providerbooleanPublic Preview
Set to true to make the new credential the default for its Git provider, replacing the current default. The first credential created for a provider becomes the default regardless of this value.
- git_emailstring
The authenticating email associated with your Git provider user account. Used for authentication with the remote repository and also sets the author & committer identity for commits. Required for most Git providers except AWS CodeCommit. Learn more at https://docs.databricks.com/aws/en/repos/get-access-tokens-from-git-provider
Response
- credential_idint64Required
ID of the credential object in the workspace.
- git_providerstringRequired
The Git provider associated with the credential.
- git_usernamestring
The username provided with your Git provider account and associated with the credential. For most Git providers it is only used to set the Git committer & author names for commits, however it may be required for authentication depending on your Git provider / token requirements. Required for AWS CodeCommit.
- namestringPublic Preview
The name of the Git credential, used for identification and ease of lookup.
- is_default_for_providerbooleanPublic Preview
Whether this credential is the default for its Git provider. The default credential is the fallback that is used when no specific credential is selected.
- git_emailstring
The authenticating email associated with your Git provider user account. Used for authentication with the remote repository and also sets the author & committer identity for commits. Required for most Git providers except AWS CodeCommit. Learn more at https://docs.databricks.com/aws/en/repos/get-access-tokens-from-git-provider
Update a credential GA
PATCH
Updates the specified Git credential. Fields that are omitted keep their current values.
API scopes: workspace
Parameters
- idint64Requiredpath
The ID for the corresponding credential to access.
Request body
- personal_access_tokenstring
The personal access token used to authenticate to the corresponding Git provider. For certain providers, support may exist for other types of scoped access tokens. Learn more.
- git_providerstringRequired
Git provider. This field is case-insensitive. The available Git providers are
gitHub,bitbucketCloud,gitLab,azureDevOpsServices(Azure DevOps Services, including Microsoft Entra ID authentication),gitHubEnterprise,bitbucketServer(Bitbucket Data Center),gitLabEnterpriseEdition(GitLab Self-Managed), andawsCodeCommit. Must match the Git provider of the existing credential; the provider cannot be changed.
- git_usernamestring
The username provided with your Git provider account and associated with the credential. For most Git providers it is only used to set the Git committer & author names for commits, however it may be required for authentication depending on your Git provider / token requirements. Required for AWS CodeCommit.
- principal_idint64
The ID of the service principal whose credentials will be modified. Only service principal managers can perform this action.
- namestringPublic Preview
The name of the Git credential, used for identification and ease of lookup. It must not exceed 100 characters.
- is_default_for_providerbooleanPublic Preview
Set to true to make this credential the default for its Git provider, replacing the current default. Cannot be set to false; make another credential the default instead.
- git_emailstring
The authenticating email associated with your Git provider user account. Used for authentication with the remote repository and also sets the author & committer identity for commits. Required for most Git providers except AWS CodeCommit. Learn more at https://docs.databricks.com/aws/en/repos/get-access-tokens-from-git-provider
Delete a credential GA
DELETE
Deletes the specified Git credential.
API scopes: workspace
Parameters
- idint64Requiredpath
The ID for the corresponding credential to access.
- principal_idint64query
The ID of the service principal whose credential will be deleted. Only service principal managers can perform this action.