:doc:`OpenSearchServiceServerless <../../opensearchserverless>` / Client / batch_get_effective_lifecycle_policy

************************************
batch_get_effective_lifecycle_policy
************************************



.. py:method:: OpenSearchServiceServerless.Client.batch_get_effective_lifecycle_policy(**kwargs)

  

  Returns a list of successful and failed retrievals for the OpenSearch Serverless indexes. For more information, see `Viewing data lifecycle policies <https://docs.aws.amazon.com/opensearch-service/latest/developerguide/serverless-lifecycle.html#serverless-lifecycle-list>`__.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/opensearchserverless-2021-11-01/BatchGetEffectiveLifecyclePolicy>`_  


  **Request Syntax**
  ::

    response = client.batch_get_effective_lifecycle_policy(
        resourceIdentifiers=[
            {
                'type': 'retention',
                'resource': 'string'
            },
        ]
    )
    
  :type resourceIdentifiers: list
  :param resourceIdentifiers: **[REQUIRED]** 

    The unique identifiers of policy types and resource names.

    

  
    - *(dict) --* 

      The unique identifiers of policy types and resource names.

      

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

        The type of lifecycle policy.

        

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

        The name of the OpenSearch Serverless ilndex resource.

        

      
    

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

    
    ::

      {
          'effectiveLifecyclePolicyDetails': [
              {
                  'type': 'retention',
                  'resource': 'string',
                  'policyName': 'string',
                  'resourceType': 'index',
                  'retentionPeriod': 'string',
                  'noMinRetentionPeriod': True|False
              },
          ],
          'effectiveLifecyclePolicyErrorDetails': [
              {
                  'type': 'retention',
                  'resource': 'string',
                  'errorMessage': 'string',
                  'errorCode': 'string'
              },
          ]
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **effectiveLifecyclePolicyDetails** *(list) --* 

        A list of lifecycle policies applied to the OpenSearch Serverless indexes.

        
        

        - *(dict) --* 

          Error information for an OpenSearch Serverless request.

          
          

          - **type** *(string) --* 

            The type of lifecycle policy.

            
          

          - **resource** *(string) --* 

            The name of the OpenSearch Serverless index resource.

            
          

          - **policyName** *(string) --* 

            The name of the lifecycle policy.

            
          

          - **resourceType** *(string) --* 

            The type of OpenSearch Serverless resource. Currently, the only supported resource is ``index``.

            
          

          - **retentionPeriod** *(string) --* 

            The minimum number of index retention in days or hours. This is an optional parameter that will return only if it’s set.

            
          

          - **noMinRetentionPeriod** *(boolean) --* 

            The minimum number of index retention days set. That is an optional param that will return as ``true`` if the minimum number of days or hours is not set to a index resource.

            
      
    
      

      - **effectiveLifecyclePolicyErrorDetails** *(list) --* 

        A list of resources for which retrieval failed.

        
        

        - *(dict) --* 

          Error information for an OpenSearch Serverless request.

          
          

          - **type** *(string) --* 

            The type of lifecycle policy.

            
          

          - **resource** *(string) --* 

            The name of OpenSearch Serverless index resource.

            
          

          - **errorMessage** *(string) --* 

            A description of the error. For example, ``The specified Index resource is not found``.

            
          

          - **errorCode** *(string) --* 

            The error code for the request.

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

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

  