Skip to content

untag_resource

untag_resource(
    resource_arn: str,
    tag_keys: TagKeyList,
    *,
    config_overrides: Optional[ConnectHealthClientConfig] = None,
) -> None

Removes the specified tags from the specified resource

Parameters:

  • resource_arn (str) –

    The ARN of the resource to untag

  • tag_keys (TagKeyList) –

    The tag keys to remove from the resource

Raises:

Source code in docs_src/capo_connecthealth/_services/connect_health.py
def untag_resource(
    self,
    resource_arn: str,
    tag_keys: "capo_connecthealth.types.tag_key_list.TagKeyList",
    *,
    config_overrides: Optional[ConnectHealthClientConfig] = None,
) -> None:
    """<p>Removes the specified tags from the specified resource</p>

    Args:
        resource_arn: <p>The ARN of the resource to untag</p>
        tag_keys: <p>The tag keys to remove from the resource</p>

    Raises:
        capo_connecthealth.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_connecthealth.types.untag_resource_input.UntagResourceInput]",
    ) -> OperationResponse[None]:
        import capo_connecthealth._operations.connect_health.untag_resource

        output, http_response = (
            capo_connecthealth._operations.connect_health.untag_resource.untag_resource(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("UntagResource")
    )
    input_: capo_connecthealth.types.untag_resource_input.UntagResourceInput = {
        "resource_arn": resource_arn,
        "tag_keys": tag_keys,
    }

    response = execute_pipeline(
        OperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    response.response.close()
    return response.output