| 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.Types.CORSRule
Description
Synopsis
- data CORSRule = CORSRule' {
- allowedHeaders :: Maybe [Text]
- exposeHeaders :: Maybe [Text]
- id :: Maybe Text
- maxAgeSeconds :: Maybe Int
- allowedMethods :: [Text]
- allowedOrigins :: [Text]
- newCORSRule :: CORSRule
- cORSRule_allowedHeaders :: Lens' CORSRule (Maybe [Text])
- cORSRule_exposeHeaders :: Lens' CORSRule (Maybe [Text])
- cORSRule_id :: Lens' CORSRule (Maybe Text)
- cORSRule_maxAgeSeconds :: Lens' CORSRule (Maybe Int)
- cORSRule_allowedMethods :: Lens' CORSRule [Text]
- cORSRule_allowedOrigins :: Lens' CORSRule [Text]
Documentation
Specifies a cross-origin access rule for an Amazon S3 bucket.
See: newCORSRule smart constructor.
Constructors
| CORSRule' | |
Fields
| |
Instances
newCORSRule :: CORSRule Source #
Create a value of CORSRule 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:allowedHeaders:CORSRule', cORSRule_allowedHeaders - Headers that are specified in the Access-Control-Request-Headers
header. These headers are allowed in a preflight OPTIONS request. In
response to any preflight OPTIONS request, Amazon S3 returns any
requested headers that are allowed.
$sel:exposeHeaders:CORSRule', cORSRule_exposeHeaders - One or more headers in the response that you want customers to be able
to access from their applications (for example, from a JavaScript
XMLHttpRequest object).
$sel:id:CORSRule', cORSRule_id - Unique identifier for the rule. The value cannot be longer than 255
characters.
$sel:maxAgeSeconds:CORSRule', cORSRule_maxAgeSeconds - The time in seconds that your browser is to cache the preflight response
for the specified resource.
$sel:allowedMethods:CORSRule', cORSRule_allowedMethods - An HTTP method that you allow the origin to execute. Valid values are
GET, PUT, HEAD, POST, and DELETE.
$sel:allowedOrigins:CORSRule', cORSRule_allowedOrigins - One or more origins you want customers to be able to access the bucket
from.
cORSRule_allowedHeaders :: Lens' CORSRule (Maybe [Text]) Source #
Headers that are specified in the Access-Control-Request-Headers
header. These headers are allowed in a preflight OPTIONS request. In
response to any preflight OPTIONS request, Amazon S3 returns any
requested headers that are allowed.
cORSRule_exposeHeaders :: Lens' CORSRule (Maybe [Text]) Source #
One or more headers in the response that you want customers to be able
to access from their applications (for example, from a JavaScript
XMLHttpRequest object).
cORSRule_id :: Lens' CORSRule (Maybe Text) Source #
Unique identifier for the rule. The value cannot be longer than 255 characters.
cORSRule_maxAgeSeconds :: Lens' CORSRule (Maybe Int) Source #
The time in seconds that your browser is to cache the preflight response for the specified resource.