EC2 / Client / disassociate_application_status_check

disassociate_application_status_check

EC2.Client.disassociate_application_status_check(**kwargs)

Disassociates an application status check from instances or tags. After disassociation, health monitoring stops for the affected instances. The following rules apply:

  • You must specify either TargetTagAssociations or InstanceIds, but not both. Specifying both results in an InvalidParameterCombination error.

  • The application status check must already exist and belong to your account.

  • Tag keys must not be blank.

See also: AWS API Documentation

Request Syntax

response = client.disassociate_application_status_check(
    ApplicationStatusCheckId='string',
    TargetTagAssociations=[
        {
            'Key': 'string',
            'Value': 'string'
        },
    ],
    InstanceIds=[
        'string',
    ],
    ClientToken='string',
    DryRun=True|False
)
Parameters:
  • ApplicationStatusCheckId (string) –

    [REQUIRED]

    The ID of the application status check to disassociate.

  • TargetTagAssociations (list) –

    The tags to disassociate from the application status check. Specify the same key-value pairs that were used during association.

    • (dict) –

      Describes a tag key-value pair for an application status check association request.

      • Key (string) –

        The key of the tag.

      • Value (string) –

        The value of the tag.

  • InstanceIds (list) –

    The IDs of the instances to disassociate from the application status check.

    • (string) –

  • ClientToken (string) –

    Unique, case-sensitive identifier that you provide to ensure the idempotency of the request. For more information, see Ensuring idempotency.

    This field is autopopulated if not provided.

  • DryRun (boolean) – Checks whether you have the required permissions for the operation, without actually making the request, and provides an error response. If you have the required permissions, the error response is DryRunOperation. Otherwise, it is UnauthorizedOperation.

Return type:

dict

Returns:

Response Syntax

{
    'SuccessfulResults': [
        {
            'ApplicationStatusCheckId': 'string',
            'AssociationType': 'string',
            'AssociationValue': 'string'
        },
    ],
    'UnsuccessfulResults': [
        {
            'ApplicationStatusCheckId': 'string',
            'AssociationType': 'string',
            'AssociationValue': 'string',
            'Reason': 'string'
        },
    ]
}

Response Structure

  • (dict) –

    • SuccessfulResults (list) –

      The associations that were successfully removed.

      • (dict) –

        Describes a successful application status check association.

        • ApplicationStatusCheckId (string) –

          The ID of the application status check.

        • AssociationType (string) –

          The type of association. Valid values: EC2TAG and INSTANCE_ID.

        • AssociationValue (string) –

          The association value. For EC2TAG, the value is formatted as key=value. For INSTANCE_ID, the value is the instance ID.

    • UnsuccessfulResults (list) –

      The associations that failed to be removed.

      • (dict) –

        Describes an unsuccessful application status check association.

        • ApplicationStatusCheckId (string) –

          The ID of the application status check.

        • AssociationType (string) –

          The type of association. Valid values: EC2TAG and INSTANCE_ID.

        • AssociationValue (string) –

          The association value. For EC2TAG, the value is formatted as key=value. For INSTANCE_ID, the value is the instance ID.

        • Reason (string) –

          The reason the association failed.