| Copyright | (c) 2013-2023 Brendan Hay |
|---|---|
| License | Mozilla Public License, v. 2.0. |
| Maintainer | Brendan Hay |
| Stability | auto-generated |
| Portability | non-portable (GHC extensions) |
| Safe Haskell | Safe-Inferred |
| Language | Haskell2010 |
Amazonka.S3.GetBucketAcl
Description
This implementation of the GET action uses the acl subresource to return the access control list (ACL) of a bucket. To use GET to return the ACL of the bucket, you must have READ_ACP access to the bucket. If READ_ACP permission is granted to the anonymous user, you can return the ACL of the bucket without using an authorization header.
If your bucket uses the bucket owner enforced setting for S3 Object Ownership, requests to read ACLs are still supported and return the bucket-owner-full-control ACL with the owner being the account that created the bucket. For more information, see Controlling object ownership and disabling ACLs in the Amazon S3 User Guide.
Related Resources
Synopsis
- data GetBucketAcl = GetBucketAcl' {}
- newGetBucketAcl :: BucketName -> GetBucketAcl
- getBucketAcl_expectedBucketOwner :: Lens' GetBucketAcl (Maybe Text)
- getBucketAcl_bucket :: Lens' GetBucketAcl BucketName
- data GetBucketAclResponse = GetBucketAclResponse' {}
- newGetBucketAclResponse :: Int -> GetBucketAclResponse
- getBucketAclResponse_grants :: Lens' GetBucketAclResponse (Maybe [Grant])
- getBucketAclResponse_owner :: Lens' GetBucketAclResponse (Maybe Owner)
- getBucketAclResponse_httpStatus :: Lens' GetBucketAclResponse Int
Creating a Request
data GetBucketAcl Source #
See: newGetBucketAcl smart constructor.
Constructors
| GetBucketAcl' | |
Fields
| |
Instances
Arguments
| :: BucketName | |
| -> GetBucketAcl |
Create a value of GetBucketAcl with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:expectedBucketOwner:GetBucketAcl', getBucketAcl_expectedBucketOwner - The account ID of the expected bucket owner. If the bucket is owned by a different account, the request fails with the HTTP status code 403 Forbidden (access denied).
GetBucketAcl, getBucketAcl_bucket - Specifies the S3 bucket whose ACL is being requested.
Request Lenses
getBucketAcl_expectedBucketOwner :: Lens' GetBucketAcl (Maybe Text) Source #
The account ID of the expected bucket owner. If the bucket is owned by a different account, the request fails with the HTTP status code 403 Forbidden (access denied).
getBucketAcl_bucket :: Lens' GetBucketAcl BucketName Source #
Specifies the S3 bucket whose ACL is being requested.
Destructuring the Response
data GetBucketAclResponse Source #
See: newGetBucketAclResponse smart constructor.
Constructors
| GetBucketAclResponse' | |
Instances
newGetBucketAclResponse Source #
Arguments
| :: Int | |
| -> GetBucketAclResponse |
Create a value of GetBucketAclResponse with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
GetBucketAclResponse, getBucketAclResponse_grants - A list of grants.
GetBucketAclResponse, getBucketAclResponse_owner - Container for the bucket owner's display name and ID.
$sel:httpStatus:GetBucketAclResponse', getBucketAclResponse_httpStatus - The response's http status code.
Response Lenses
getBucketAclResponse_grants :: Lens' GetBucketAclResponse (Maybe [Grant]) Source #
A list of grants.
getBucketAclResponse_owner :: Lens' GetBucketAclResponse (Maybe Owner) Source #
Container for the bucket owner's display name and ID.
getBucketAclResponse_httpStatus :: Lens' GetBucketAclResponse Int Source #
The response's http status code.