CodeCommit / Client / create_branch
create_branch#
- CodeCommit.Client.create_branch(**kwargs)#
- Creates a branch in a repository and points the branch to a commit. - Note- Calling the create branch operation does not set a repository’s default branch. To do this, call the update default branch operation. - See also: AWS API Documentation - Request Syntax- response = client.create_branch( repositoryName='string', branchName='string', commitId='string' ) - Parameters:
- repositoryName (string) – - [REQUIRED] - The name of the repository in which you want to create the new branch. 
- branchName (string) – - [REQUIRED] - The name of the new branch to create. 
- commitId (string) – - [REQUIRED] - The ID of the commit to point the new branch to. 
 
- Returns:
- None 
 - Exceptions- CodeCommit.Client.exceptions.RepositoryNameRequiredException
- CodeCommit.Client.exceptions.InvalidRepositoryNameException
- CodeCommit.Client.exceptions.RepositoryDoesNotExistException
- CodeCommit.Client.exceptions.BranchNameRequiredException
- CodeCommit.Client.exceptions.BranchNameExistsException
- CodeCommit.Client.exceptions.InvalidBranchNameException
- CodeCommit.Client.exceptions.CommitIdRequiredException
- CodeCommit.Client.exceptions.CommitDoesNotExistException
- CodeCommit.Client.exceptions.InvalidCommitIdException
- CodeCommit.Client.exceptions.EncryptionIntegrityChecksFailedException
- CodeCommit.Client.exceptions.EncryptionKeyAccessDeniedException
- CodeCommit.Client.exceptions.EncryptionKeyDisabledException
- CodeCommit.Client.exceptions.EncryptionKeyNotFoundException
- CodeCommit.Client.exceptions.EncryptionKeyUnavailableException