:doc:`OpenSearchIngestion <../../osis>` / Client / get_resource_policy

*******************
get_resource_policy
*******************



.. py:method:: OpenSearchIngestion.Client.get_resource_policy(**kwargs)

  

  Retrieves the resource-based policy attached to an OpenSearch Ingestion resource.

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/osis-2022-01-01/GetResourcePolicy>`_  


  **Request Syntax**
  ::

    response = client.get_resource_policy(
        ResourceArn='string'
    )
    
  :type ResourceArn: string
  :param ResourceArn: **[REQUIRED]** 

    The Amazon Resource Name (ARN) of the resource for which to retrieve the policy.

    

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

    
    ::

      {
          'ResourceArn': 'string',
          'Policy': 'string'
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **ResourceArn** *(string) --* 

        The Amazon Resource Name (ARN) of the resource.

        
      

      - **Policy** *(string) --* 

        The resource-based policy document in JSON format.

        
  
  **Exceptions**
  
  *   :py:class:`OpenSearchIngestion.Client.exceptions.DisabledOperationException`

  
  *   :py:class:`OpenSearchIngestion.Client.exceptions.LimitExceededException`

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

  
  *   :py:class:`OpenSearchIngestion.Client.exceptions.InternalException`

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

  
  *   :py:class:`OpenSearchIngestion.Client.exceptions.AccessDeniedException`

  