:doc:`SSM <../../ssm>` / Client / update_resource_data_sync

*************************
update_resource_data_sync
*************************



.. py:method:: SSM.Client.update_resource_data_sync(**kwargs)

  

  Update a resource data sync. After you create a resource data sync for a Region, you can't change the account options for that sync. For example, if you create a sync in the us-east-2 (Ohio) Region and you choose the ``Include only the current account`` option, you can't edit that sync later and choose the ``Include all accounts from my Organizations configuration`` option. Instead, you must delete the first resource data sync, and create a new one.

   

  .. note::

    

    This API operation only supports a resource data sync that was created with a SyncFromSource ``SyncType``.

    

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/ssm-2014-11-06/UpdateResourceDataSync>`_  


  **Request Syntax**
  ::

    response = client.update_resource_data_sync(
        SyncName='string',
        SyncType='string',
        SyncSource={
            'SourceType': 'string',
            'AwsOrganizationsSource': {
                'OrganizationSourceType': 'string',
                'OrganizationalUnits': [
                    {
                        'OrganizationalUnitId': 'string'
                    },
                ]
            },
            'SourceRegions': [
                'string',
            ],
            'IncludeFutureRegions': True|False,
            'EnableAllOpsDataSources': True|False
        }
    )
    
  :type SyncName: string
  :param SyncName: **[REQUIRED]** 

    The name of the resource data sync you want to update.

    

  
  :type SyncType: string
  :param SyncType: **[REQUIRED]** 

    The type of resource data sync. The supported ``SyncType`` is SyncFromSource.

    

  
  :type SyncSource: dict
  :param SyncSource: **[REQUIRED]** 

    Specify information about the data sources to synchronize.

    

  
    - **SourceType** *(string) --* **[REQUIRED]** 

      The type of data source for the resource data sync. ``SourceType`` is either ``AwsOrganizations`` (if an organization is present in Organizations) or ``SingleAccountMultiRegions``.

      

    
    - **AwsOrganizationsSource** *(dict) --* 

      Information about the ``AwsOrganizationsSource`` resource data sync source. A sync source of this type can synchronize data from Organizations.

      

    
      - **OrganizationSourceType** *(string) --* **[REQUIRED]** 

        If an Amazon Web Services organization is present, this is either ``OrganizationalUnits`` or ``EntireOrganization``. For ``OrganizationalUnits``, the data is aggregated from a set of organization units. For ``EntireOrganization``, the data is aggregated from the entire Amazon Web Services organization.

        

      
      - **OrganizationalUnits** *(list) --* 

        The Organizations organization units included in the sync.

        

      
        - *(dict) --* 

          The Organizations organizational unit data source for the sync.

          

        
          - **OrganizationalUnitId** *(string) --* 

            The Organizations unit ID data source for the sync.

            

          
        
    
    
    - **SourceRegions** *(list) --* **[REQUIRED]** 

      The ``SyncSource`` Amazon Web Services Regions included in the resource data sync.

      

    
      - *(string) --* 

      
  
    - **IncludeFutureRegions** *(boolean) --* 

      Whether to automatically synchronize and aggregate data from new Amazon Web Services Regions when those Regions come online.

      

    
    - **EnableAllOpsDataSources** *(boolean) --* 

      When you create a resource data sync, if you choose one of the Organizations options, then Systems Manager automatically enables all OpsData sources in the selected Amazon Web Services Regions for all Amazon Web Services accounts in your organization (or in the selected organization units). For more information, see `Setting up Systems Manager Explorer to display data from multiple accounts and Regions <https://docs.aws.amazon.com/systems-manager/latest/userguide/Explorer-resource-data-sync.html>`__ in the *Amazon Web Services Systems Manager User Guide*.

      

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

    
    ::

      {}
      
    **Response Structure**

    

    - *(dict) --* 
  
  **Exceptions**
  
  *   :py:class:`SSM.Client.exceptions.ResourceDataSyncNotFoundException`

  
  *   :py:class:`SSM.Client.exceptions.ResourceDataSyncInvalidConfigurationException`

  
  *   :py:class:`SSM.Client.exceptions.ResourceDataSyncConflictException`

  
  *   :py:class:`SSM.Client.exceptions.InternalServerError`

  