:doc:`ApplicationInsights <../../application-insights>` / Client / update_application

******************
update_application
******************



.. py:method:: ApplicationInsights.Client.update_application(**kwargs)

  

  Updates the application.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/application-insights-2018-11-25/UpdateApplication>`_  


  **Request Syntax**
  ::

    response = client.update_application(
        ResourceGroupName='string',
        OpsCenterEnabled=True|False,
        CWEMonitorEnabled=True|False,
        OpsItemSNSTopicArn='string',
        SNSNotificationArn='string',
        RemoveSNSTopic=True|False,
        AutoConfigEnabled=True|False,
        AttachMissingPermission=True|False
    )
    
  :type ResourceGroupName: string
  :param ResourceGroupName: **[REQUIRED]** 

    The name of the resource group.

    

  
  :type OpsCenterEnabled: boolean
  :param OpsCenterEnabled: 

    When set to ``true``, creates opsItems for any problems detected on an application.

    

  
  :type CWEMonitorEnabled: boolean
  :param CWEMonitorEnabled: 

    Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as ``instance terminated``, ``failed deployment``, and others.

    

  
  :type OpsItemSNSTopicArn: string
  :param OpsItemSNSTopicArn: 

    The SNS topic provided to Application Insights that is associated to the created opsItem. Allows you to receive notifications for updates to the opsItem.

    

  
  :type SNSNotificationArn: string
  :param SNSNotificationArn: 

    The SNS topic ARN. Allows you to receive SNS notifications for updates and issues with an application.

    

  
  :type RemoveSNSTopic: boolean
  :param RemoveSNSTopic: 

    Disassociates the SNS topic from the opsItem created for detected problems.

    

  
  :type AutoConfigEnabled: boolean
  :param AutoConfigEnabled: 

    Turns auto-configuration on or off.

    

  
  :type AttachMissingPermission: boolean
  :param AttachMissingPermission: 

    If set to true, the managed policies for SSM and CW will be attached to the instance roles if they are missing.

    

  
  
  :rtype: dict
  :returns: 
    
    **Response Syntax**

    
    ::

      {
          'ApplicationInfo': {
              'AccountId': 'string',
              'ResourceGroupName': 'string',
              'LifeCycle': 'string',
              'OpsItemSNSTopicArn': 'string',
              'SNSNotificationArn': 'string',
              'OpsCenterEnabled': True|False,
              'CWEMonitorEnabled': True|False,
              'Remarks': 'string',
              'AutoConfigEnabled': True|False,
              'DiscoveryType': 'RESOURCE_GROUP_BASED'|'ACCOUNT_BASED',
              'AttachMissingPermission': True|False
          }
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **ApplicationInfo** *(dict) --* 

        Information about the application.

        
        

        - **AccountId** *(string) --* 

          The Amazon Web Services account ID for the owner of the application.

          
        

        - **ResourceGroupName** *(string) --* 

          The name of the resource group used for the application.

          
        

        - **LifeCycle** *(string) --* 

          The lifecycle of the application.

          
        

        - **OpsItemSNSTopicArn** *(string) --* 

          The SNS topic provided to Application Insights that is associated to the created opsItems to receive SNS notifications for opsItem updates.

          
        

        - **SNSNotificationArn** *(string) --* 

          The SNS topic ARN that is associated with SNS notifications for updates or issues.

          
        

        - **OpsCenterEnabled** *(boolean) --* 

          Indicates whether Application Insights will create opsItems for any problem detected by Application Insights for an application.

          
        

        - **CWEMonitorEnabled** *(boolean) --* 

          Indicates whether Application Insights can listen to CloudWatch events for the application resources, such as ``instance terminated``, ``failed deployment``, and others.

          
        

        - **Remarks** *(string) --* 

          The issues on the user side that block Application Insights from successfully monitoring an application. Example remarks include:

           

          
          * “Configuring application, detected 1 Errors, 3 Warnings”
           
          * “Configuring application, detected 1 Unconfigured Components”
          

          
        

        - **AutoConfigEnabled** *(boolean) --* 

          Indicates whether auto-configuration is turned on for this application.

          
        

        - **DiscoveryType** *(string) --* 

          The method used by Application Insights to onboard your resources.

          
        

        - **AttachMissingPermission** *(boolean) --* 

          If set to true, the managed policies for SSM and CW will be attached to the instance roles if they are missing.

          
    
  
  **Exceptions**
  
  *   :py:class:`ApplicationInsights.Client.exceptions.InternalServerException`

  
  *   :py:class:`ApplicationInsights.Client.exceptions.ResourceNotFoundException`

  
  *   :py:class:`ApplicationInsights.Client.exceptions.ValidationException`

  