libZSservicesZSamazonka-s3ZSamazonka-s3
Copyright(c) 2013-2021 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone

Amazonka.S3.GetBucketWebsite

Description

Returns the website configuration for a bucket. To host website on Amazon S3, you can configure a bucket as website by adding a website configuration. For more information about hosting websites, see Hosting Websites on Amazon S3.

This GET action requires the S3:GetBucketWebsite permission. By default, only the bucket owner can read the bucket website configuration. However, bucket owners can allow other users to read the website configuration by writing a bucket policy granting them the S3:GetBucketWebsite permission.

The following operations are related to DeleteBucketWebsite:

Synopsis

Creating a Request

data GetBucketWebsite Source #

See: newGetBucketWebsite smart constructor.

Constructors

GetBucketWebsite' 

Fields

  • expectedBucketOwner :: Maybe Text

    The account ID of the expected bucket owner. If the bucket is owned by a different account, the request will fail with an HTTP 403 (Access Denied) error.

  • bucket :: BucketName

    The bucket name for which to get the website configuration.

Instances

Instances details
Eq GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

Read GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

Show GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

Generic GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

Associated Types

type Rep GetBucketWebsite :: Type -> Type #

NFData GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

Methods

rnf :: GetBucketWebsite -> () #

Hashable GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

AWSRequest GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

Associated Types

type AWSResponse GetBucketWebsite #

ToHeaders GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

ToPath GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

ToQuery GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

type Rep GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

type Rep GetBucketWebsite = D1 ('MetaData "GetBucketWebsite" "Amazonka.S3.GetBucketWebsite" "libZSservicesZSamazonka-s3ZSamazonka-s3" 'False) (C1 ('MetaCons "GetBucketWebsite'" 'PrefixI 'True) (S1 ('MetaSel ('Just "expectedBucketOwner") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "bucket") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 BucketName)))
type AWSResponse GetBucketWebsite Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

newGetBucketWebsite Source #

Create a value of GetBucketWebsite 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:GetBucketWebsite', getBucketWebsite_expectedBucketOwner - The account ID of the expected bucket owner. If the bucket is owned by a different account, the request will fail with an HTTP 403 (Access Denied) error.

$sel:bucket:GetBucketWebsite', getBucketWebsite_bucket - The bucket name for which to get the website configuration.

Request Lenses

getBucketWebsite_expectedBucketOwner :: Lens' GetBucketWebsite (Maybe Text) Source #

The account ID of the expected bucket owner. If the bucket is owned by a different account, the request will fail with an HTTP 403 (Access Denied) error.

getBucketWebsite_bucket :: Lens' GetBucketWebsite BucketName Source #

The bucket name for which to get the website configuration.

Destructuring the Response

data GetBucketWebsiteResponse Source #

See: newGetBucketWebsiteResponse smart constructor.

Constructors

GetBucketWebsiteResponse' 

Fields

Instances

Instances details
Eq GetBucketWebsiteResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

Read GetBucketWebsiteResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

Show GetBucketWebsiteResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

Generic GetBucketWebsiteResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

Associated Types

type Rep GetBucketWebsiteResponse :: Type -> Type #

NFData GetBucketWebsiteResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

type Rep GetBucketWebsiteResponse Source # 
Instance details

Defined in Amazonka.S3.GetBucketWebsite

type Rep GetBucketWebsiteResponse = D1 ('MetaData "GetBucketWebsiteResponse" "Amazonka.S3.GetBucketWebsite" "libZSservicesZSamazonka-s3ZSamazonka-s3" 'False) (C1 ('MetaCons "GetBucketWebsiteResponse'" 'PrefixI 'True) ((S1 ('MetaSel ('Just "redirectAllRequestsTo") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe RedirectAllRequestsTo)) :*: S1 ('MetaSel ('Just "errorDocument") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe ErrorDocument))) :*: (S1 ('MetaSel ('Just "indexDocument") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe IndexDocument)) :*: (S1 ('MetaSel ('Just "routingRules") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe [RoutingRule])) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int)))))

newGetBucketWebsiteResponse Source #

Create a value of GetBucketWebsiteResponse 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:redirectAllRequestsTo:GetBucketWebsiteResponse', getBucketWebsiteResponse_redirectAllRequestsTo - Specifies the redirect behavior of all requests to a website endpoint of an Amazon S3 bucket.

$sel:errorDocument:GetBucketWebsiteResponse', getBucketWebsiteResponse_errorDocument - The object key name of the website error document to use for 4XX class errors.

$sel:indexDocument:GetBucketWebsiteResponse', getBucketWebsiteResponse_indexDocument - The name of the index document for the website (for example index.html).

$sel:routingRules:GetBucketWebsiteResponse', getBucketWebsiteResponse_routingRules - Rules that define when a redirect is applied and the redirect behavior.

$sel:httpStatus:GetBucketWebsiteResponse', getBucketWebsiteResponse_httpStatus - The response's http status code.

Response Lenses

getBucketWebsiteResponse_redirectAllRequestsTo :: Lens' GetBucketWebsiteResponse (Maybe RedirectAllRequestsTo) Source #

Specifies the redirect behavior of all requests to a website endpoint of an Amazon S3 bucket.

getBucketWebsiteResponse_errorDocument :: Lens' GetBucketWebsiteResponse (Maybe ErrorDocument) Source #

The object key name of the website error document to use for 4XX class errors.

getBucketWebsiteResponse_indexDocument :: Lens' GetBucketWebsiteResponse (Maybe IndexDocument) Source #

The name of the index document for the website (for example index.html).

getBucketWebsiteResponse_routingRules :: Lens' GetBucketWebsiteResponse (Maybe [RoutingRule]) Source #

Rules that define when a redirect is applied and the redirect behavior.