Skip to main content

GetBucketAcl

Returns the access control list (ACL) of a bucket.

Description

The GetBucketAcl operation returns the access control list (ACL) of a bucket. To use this operation, you must have s3:GetBucketAcl permissions on the bucket, or be the bucket owner.

note

If your bucket uses the bucket owner enforced setting for S3 Object Ownership, ACLs are disabled and no longer affect permissions. You must use policies to grant access to your bucket and the objects in it.

Request Syntax

GET /?acl HTTP/1.1
Host: BucketName.qstorage.quilibrium.com
x-amz-expected-bucket-owner: OwnerAccountId
Values in italics indicate user input and should be replaced with actual values.

This operation does not have a request body.

Request Parameters

Headers

NameDescriptionRequiredType
x-amz-expected-bucket-ownerThe account ID of the expected bucket ownerNotext

Response Syntax

HTTP/1.1 200 OK
x-amz-id-2: RequestId
x-amz-request-id: AmazonRequestId
Date: ISO8601Date
Last-Modified: Fri, 25 Dec 2020 12:00:00 GMT
Content-Length: 123
Content-Type: text/plain
Connection: close
<?xml version="1.0" encoding="UTF-8"?> <AccessControlPolicy> <Owner> <ID>ID</ID> <DisplayName>DisplayName</DisplayName> </Owner> <AccessControlList> <Grant> <Grantee xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="Type"> <ID>ID</ID> <DisplayName>DisplayName</DisplayName> </Grantee> <Permission>Permission</Permission> </Grant> </AccessControlList> </AccessControlPolicy>
Values in italics indicate variable response values.

Response Elements

If the action is successful, the service sends back an response of HTTP 200.

Response Headers

NameDescriptionRequiredType
x-amz-id-2An identifier for the requestNoString
x-amz-request-idA unique identifier for the requestNoString
DateThe date and time at which the response was sentNoString
Last-ModifiedThe date and time at which the resource was last modifiedNoString
Content-LengthThe size of the response body in bytesNoString
Content-TypeThe MIME type of the responseNoString
ConnectionThe type of connection used for the HTTP responseNoString

Response Body Elements

The response body will be in XML format.

NameDescriptionRequiredType
AccessControlPolicyContainer for the responseNoString
GrantsA list of Grants.

See Grant data type.
NoString
OwnerContainer for the bucket owner's ID.

See Owner data type.
NoString

Special Errors

Error CodeDescription
NoSuchBucketThe specified bucket does not exist
403Forbidden. Authentication failed or you do not have permission to access the bucket ACL

Permissions

You must have the s3:GetBucketAcl permission.

Examples

GET /?acl HTTP/1.1
Host: my-bucket.qstorage.quilibrium.com
x-amz-expected-bucket-owner: 123456789012
Values in italics indicate user input and should be replaced with actual values.
HTTP/1.1 200 OK
x-amz-id-2: Example7qoYGN7uMuFuYS6m7a4l
x-amz-request-id: TX234S0F24A06C7
Date: Wed, 01 Mar 2024 12:00:00 GMT
Last-Modified: Fri, 25 Dec 2020 12:00:00 GMT
Content-Length: 123
Content-Type: text/plain
Connection: close
<?xml version="1.0" encoding="UTF-8"?> <AccessControlPolicy> <Owner> <ID>123456789012</ID> <DisplayName>user@example.com</DisplayName> </Owner> <AccessControlList> <Grant> <Grantee xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:type="CanonicalUser"> <ID>123456789012</ID> <DisplayName>user@example.com</DisplayName> </Grantee> <Permission>FULL_CONTROL</Permission> </Grant> </AccessControlList> </AccessControlPolicy>
Values in italics indicate variable response values.

Try It Out

Test GetBucketAcl

Get the access control list (ACL) of a bucket.

Coming Soon

This feature is currently under development and will be available soon.