Skip to content

deregister_webhook_with_third_party async

deregister_webhook_with_third_party(
    *,
    config_overrides: Optional[AsyncCodePipelineClientConfig] = None,
    webhook_name: Optional[WebhookName] = None,
) -> DeregisterWebhookWithThirdPartyOutput

Removes the connection between the webhook that was created by CodePipeline and the external tool with events to be detected. Currently supported only for webhooks that target an action type of GitHub.

Parameters:

  • webhook_name (Optional[WebhookName], default: None ) –

    The name of the webhook you want to deregister.

Raises:

Source code in docs_src/capo_codepipeline/_services/async_code_pipeline.py
async def deregister_webhook_with_third_party(
    self,
    *,
    config_overrides: Optional[AsyncCodePipelineClientConfig] = None,
    webhook_name: Optional[
        "capo_codepipeline.types.webhook_name.WebhookName"
    ] = None,
) -> "capo_codepipeline.types.deregister_webhook_with_third_party_output.DeregisterWebhookWithThirdPartyOutput":
    """<p>Removes the connection between the webhook that was created by CodePipeline and the external tool with events to be detected. Currently supported only for webhooks that target an action type of GitHub.</p>

    Args:
        webhook_name: <p>The name of the webhook you want to deregister.</p>

    Raises:
        capo_codepipeline.errors.validation_exception.ValidationException: <p>The validation was specified in an invalid format.</p>
        capo_codepipeline.errors.webhook_not_found_exception.WebhookNotFoundException: <p>The specified webhook was entered in an invalid format or cannot be found.</p>
        capo_codepipeline.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_codepipeline.types.deregister_webhook_with_third_party_input.DeregisterWebhookWithThirdPartyInput]",
    ) -> AsyncOperationResponse[
        "capo_codepipeline.types.deregister_webhook_with_third_party_output.DeregisterWebhookWithThirdPartyOutput"
    ]:
        import capo_codepipeline._operations.code_pipeline_20150709.deregister_webhook_with_third_party

        (
            output,
            http_response,
        ) = await capo_codepipeline._operations.code_pipeline_20150709.deregister_webhook_with_third_party.async_deregister_webhook_with_third_party(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("DeregisterWebhookWithThirdParty")
    )
    input_: capo_codepipeline.types.deregister_webhook_with_third_party_input.DeregisterWebhookWithThirdPartyInput = {}
    if webhook_name is not None:
        input_["webhook_name"] = webhook_name

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output