Deletes a Git connection, so that the service can no longer access repositories through it. This operation doesn't remove the app installation or authorization from your Git provider account. To remove them, use your Git provider's settings. If the connection doesn't exist, the operation succeeds and does nothing.
Parameters:
-
provider
(GitProvider)
–
-
owner
(GitOwnerName)
–
The account that the Git connection is for. The value depends on the provider:
-
For GitHub, specify the user or organization name.
-
For GitLab, specify the user name.
To get this value, call ListGitConnections.
Raises:
Source code in docs_src/capo_amplifygen3/_services/async_amplify_gen3.py
| async def delete_git_connection(
self,
provider: "capo_amplifygen3.types.git_provider.GitProvider",
owner: "capo_amplifygen3.types.git_owner_name.GitOwnerName",
*,
config_overrides: Optional[AsyncAmplifyGen3ClientConfig] = None,
) -> None:
"""<p>Deletes a Git connection, so that the service can no longer access repositories through it. This operation doesn't remove the app installation or authorization from your Git provider account. To remove them, use your Git provider's settings. If the connection doesn't exist, the operation succeeds and does nothing.</p>
Args:
provider: <p>The Git provider.</p>
owner: <p>The account that the Git connection is for. The value depends on the provider:</p> <ul> <li> <p>For GitHub, specify the user or organization name.</p> </li> <li> <p>For GitLab, specify the user name.</p> </li> </ul> <p>To get this value, call ListGitConnections.</p>
Raises:
capo_amplifygen3.errors.access_denied_exception.AccessDeniedException: <p>You do not have sufficient permissions to perform this action.</p>
capo_amplifygen3.errors.internal_server_exception.InternalServerException: <p>An internal error occurred. Retry the request.</p>
capo_amplifygen3.errors.throttling_exception.ThrottlingException: <p>The request was denied because the request rate exceeds the allowed limit.</p>
capo_amplifygen3.errors.validation_exception.ValidationException: <p>The request contains invalid parameters or is otherwise malformed.</p>
capo_amplifygen3.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_amplifygen3.types.delete_git_connection_request.DeleteGitConnectionRequest]",
) -> AsyncOperationResponse[None]:
import capo_amplifygen3._operations.omega.delete_git_connection
(
output,
http_response,
) = await capo_amplifygen3._operations.omega.delete_git_connection.async_delete_git_connection(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("DeleteGitConnection")
)
input_: capo_amplifygen3.types.delete_git_connection_request.DeleteGitConnectionRequest = {
"provider": provider,
"owner": owner,
}
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|