get_branch
async
¶
get_branch(
*,
config_overrides: Optional[AsyncCodeCommitClientConfig] = None,
repository_name: Optional[RepositoryName] = None,
branch_name: Optional[BranchName] = None,
) -> GetBranchOutput
Returns information about a repository branch, including its name and the last commit ID.
Parameters:
-
repository_name(Optional[RepositoryName], default:None) –The name of the repository that contains the branch for which you want to retrieve information.
-
branch_name(Optional[BranchName], default:None) –The name of the branch for which you want to retrieve information.
Raises:
-
BranchDoesNotExistException–The specified branch does not exist.
-
BranchNameRequiredException–A branch name is required, but was not specified.
-
EncryptionIntegrityChecksFailedException–An encryption integrity check failed.
-
EncryptionKeyAccessDeniedException–An encryption key could not be accessed.
-
EncryptionKeyDisabledException–The encryption key is disabled.
-
EncryptionKeyNotFoundException–No encryption key was found.
-
EncryptionKeyUnavailableException–The encryption key is not available.
-
InvalidBranchNameException–The specified reference name is not valid.
-
InvalidRepositoryNameException–A specified repository name is not valid.
This exception occurs only when a specified repository name is not valid. Other exceptions occur when a required repository parameter is missing, or when a specified repository does not exist.
-
RepositoryDoesNotExistException–The specified repository does not exist.
-
RepositoryNameRequiredException–A repository name is required, but was not specified.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_codecommit/_services/async_code_commit.py
2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 | |