:doc:`CodeArtifact <../../codeartifact>` / Client / delete_repository_permissions_policy

************************************
delete_repository_permissions_policy
************************************



.. py:method:: CodeArtifact.Client.delete_repository_permissions_policy(**kwargs)

  

  Deletes the resource policy that is set on a repository. After a resource policy is deleted, the permissions allowed and denied by the deleted policy are removed. The effect of deleting a resource policy might not be immediate.

   

  .. warning::

     

    Use ``DeleteRepositoryPermissionsPolicy`` with caution. After a policy is deleted, Amazon Web Services users, roles, and accounts lose permissions to perform the repository actions granted by the deleted policy.

    

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/DeleteRepositoryPermissionsPolicy>`_  


  **Request Syntax**
  ::

    response = client.delete_repository_permissions_policy(
        domain='string',
        domainOwner='string',
        repository='string',
        policyRevision='string'
    )
    
  :type domain: string
  :param domain: **[REQUIRED]** 

    The name of the domain that contains the repository associated with the resource policy to be deleted.

    

  
  :type domainOwner: string
  :param domainOwner: 

    The 12-digit account number of the Amazon Web Services account that owns the domain. It does not include dashes or spaces.

    

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

    The name of the repository that is associated with the resource policy to be deleted

    

  
  :type policyRevision: string
  :param policyRevision: 

    The revision of the repository's resource policy to be deleted. This revision is used for optimistic locking, which prevents others from accidentally overwriting your changes to the repository's resource policy.

    

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

    
    ::

      {
          'policy': {
              'resourceArn': 'string',
              'revision': 'string',
              'document': 'string'
          }
      }
      
    **Response Structure**

    

    - *(dict) --* 
      

      - **policy** *(dict) --* 

        Information about the deleted policy after processing the request.

        
        

        - **resourceArn** *(string) --* 

          The ARN of the resource associated with the resource policy

          
        

        - **revision** *(string) --* 

          The current revision of the resource policy.

          
        

        - **document** *(string) --* 

          The resource policy formatted in JSON.

          
    
  
  **Exceptions**
  
  *   :py:class:`CodeArtifact.Client.exceptions.AccessDeniedException`

  
  *   :py:class:`CodeArtifact.Client.exceptions.ConflictException`

  
  *   :py:class:`CodeArtifact.Client.exceptions.InternalServerException`

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

  
  *   :py:class:`CodeArtifact.Client.exceptions.ThrottlingException`

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

  