:doc:`S3 <../../s3>` / Client / delete_bucket_ownership_controls

********************************
delete_bucket_ownership_controls
********************************



.. py:method:: S3.Client.delete_bucket_ownership_controls(**kwargs)

  

  .. note::

    

    This operation is not supported for directory buckets.

    

   

  Removes ``OwnershipControls`` for an Amazon S3 bucket. To use this operation, you must have the ``s3:PutBucketOwnershipControls`` permission. For more information about Amazon S3 permissions, see `Specifying Permissions in a Policy <https://docs.aws.amazon.com/AmazonS3/latest/dev/using-with-s3-actions.html>`__.

   

  For information about Amazon S3 Object Ownership, see `Using Object Ownership <https://docs.aws.amazon.com/AmazonS3/latest/dev/about-object-ownership.html>`__.

   

  The following operations are related to ``DeleteBucketOwnershipControls``:

   

  
  *  GetBucketOwnershipControls
   
  *  PutBucketOwnershipControls
  

   

  .. warning::

     

    You must URL encode any signed header values that contain spaces. For example, if your header value is ``my file.txt``, containing two spaces after ``my``, you must URL encode this value to ``my%20%20file.txt``.

    

  

  See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/s3-2006-03-01/DeleteBucketOwnershipControls>`_  


  **Request Syntax**
  ::

    response = client.delete_bucket_ownership_controls(
        Bucket='string',
        ExpectedBucketOwner='string'
    )
    
  :type Bucket: string
  :param Bucket: **[REQUIRED]** 

    The Amazon S3 bucket whose ``OwnershipControls`` you want to delete.

    

  
  :type ExpectedBucketOwner: string
  :param ExpectedBucketOwner: 

    The account ID of the expected bucket owner. If the account ID that you provide does not match the actual owner of the bucket, the request fails with the HTTP status code ``403 Forbidden`` (access denied).

    

  
  
  :returns: None