amazonka-s3-2.0: Amazon Simple Storage Service SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

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

Creating a Request

data GetBucketAcl Source #

See: newGetBucketAcl smart constructor.

Constructors

GetBucketAcl' 

Fields

  • expectedBucketOwner :: Maybe Text

    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).

  • bucket :: BucketName

    Specifies the S3 bucket whose ACL is being requested.

Instances

Instances details
ToHeaders GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

ToPath GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

ToQuery GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

AWSRequest GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

Associated Types

type AWSResponse GetBucketAcl #

Generic GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

Associated Types

type Rep GetBucketAcl :: Type -> Type #

Read GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

Show GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

NFData GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

Methods

rnf :: GetBucketAcl -> () #

Eq GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

Hashable GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

type AWSResponse GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

type Rep GetBucketAcl Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

type Rep GetBucketAcl = D1 ('MetaData "GetBucketAcl" "Amazonka.S3.GetBucketAcl" "amazonka-s3-2.0-CNZtv1UmVzj28JXsFvwNoj" 'False) (C1 ('MetaCons "GetBucketAcl'" 'PrefixI 'True) (S1 ('MetaSel ('Just "expectedBucketOwner") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "bucket") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 BucketName)))

newGetBucketAcl Source #

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' 

Fields

Instances

Instances details
Generic GetBucketAclResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

Associated Types

type Rep GetBucketAclResponse :: Type -> Type #

Read GetBucketAclResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

Show GetBucketAclResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

NFData GetBucketAclResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

Methods

rnf :: GetBucketAclResponse -> () #

Eq GetBucketAclResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

type Rep GetBucketAclResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketAcl

type Rep GetBucketAclResponse = D1 ('MetaData "GetBucketAclResponse" "Amazonka.S3.GetBucketAcl" "amazonka-s3-2.0-CNZtv1UmVzj28JXsFvwNoj" 'False) (C1 ('MetaCons "GetBucketAclResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "grants") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [Grant])) :*: (S1 ('MetaSel ('Just "owner") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Owner)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int))))

newGetBucketAclResponse Source #

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_owner :: Lens' GetBucketAclResponse (Maybe Owner) Source #

Container for the bucket owner's display name and ID.