Skip to content

disassociate_resource_from_profile

disassociate_resource_from_profile(
    profile_id: ResourceId,
    resource_arn: Arn,
    *,
    config_overrides: Optional[Route53ProfilesClientConfig] = None,
) -> DisassociateResourceFromProfileResponse

Dissoaciated a specified resource, from the Route 53 Profile.

Parameters:

  • profile_id (ResourceId) –

    The ID of the Profile.

  • resource_arn (Arn) –

    The Amazon Resource Name (ARN) of the resource.

Raises:

Source code in docs_src/capo_route53profiles/_services/route53_profiles.py
def disassociate_resource_from_profile(
    self,
    profile_id: "capo_route53profiles.types.resource_id.ResourceId",
    resource_arn: "capo_route53profiles.types.arn.Arn",
    *,
    config_overrides: Optional[Route53ProfilesClientConfig] = None,
) -> "capo_route53profiles.types.disassociate_resource_from_profile_response.DisassociateResourceFromProfileResponse":
    """<p> Dissoaciated a specified resource, from the Route 53 Profile. </p>

    Args:
        profile_id: <p> The ID of the Profile. </p>
        resource_arn: <p>The Amazon Resource Name (ARN) of the resource. </p>

    Raises:
        capo_route53profiles.errors.access_denied_exception.AccessDeniedException: <p> The current account doesn't have the IAM permissions required to perform the specified operation. </p>
        capo_route53profiles.errors.conflict_exception.ConflictException: <p> The request you submitted conflicts with an existing request. </p>
        capo_route53profiles.errors.internal_service_error_exception.InternalServiceErrorException: <p> An internal server error occured. Retry your request. </p>
        capo_route53profiles.errors.invalid_parameter_exception.InvalidParameterException: <p> One or more parameters in this request are not valid. </p>
        capo_route53profiles.errors.limit_exceeded_exception.LimitExceededException: <p> The request caused one or more limits to be exceeded. </p>
        capo_route53profiles.errors.resource_not_found_exception.ResourceNotFoundException: <p> The resource you are associating is not found. </p>
        capo_route53profiles.errors.throttling_exception.ThrottlingException: <p> The request was throttled. Try again in a few minutes. </p>
        capo_route53profiles.errors.validation_exception.ValidationException: <p> You have provided an invalid command. </p>
        capo_route53profiles.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    def _handler(
        req: "OperationRequest[capo_route53profiles.types.disassociate_resource_from_profile_request.DisassociateResourceFromProfileRequest]",
    ) -> OperationResponse[
        "capo_route53profiles.types.disassociate_resource_from_profile_response.DisassociateResourceFromProfileResponse"
    ]:
        import capo_route53profiles._operations.route53_profiles.disassociate_resource_from_profile

        output, http_response = (
            capo_route53profiles._operations.route53_profiles.disassociate_resource_from_profile.disassociate_resource_from_profile(
                req.options, req.input
            )
        )
        return OperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("DisassociateResourceFromProfile")
    )
    input_: capo_route53profiles.types.disassociate_resource_from_profile_request.DisassociateResourceFromProfileRequest = {
        "profile_id": profile_id,
        "resource_arn": resource_arn,
    }

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