Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Synopsis
- data Cors = Cors' {
- maxAge :: Maybe Int
- allowMethods :: Maybe [Text]
- allowHeaders :: Maybe [Text]
- exposeHeaders :: Maybe [Text]
- allowOrigins :: Maybe [Text]
- allowCredentials :: Maybe Bool
- newCors :: Cors
- cors_maxAge :: Lens' Cors (Maybe Int)
- cors_allowMethods :: Lens' Cors (Maybe [Text])
- cors_allowHeaders :: Lens' Cors (Maybe [Text])
- cors_exposeHeaders :: Lens' Cors (Maybe [Text])
- cors_allowOrigins :: Lens' Cors (Maybe [Text])
- cors_allowCredentials :: Lens' Cors (Maybe Bool)
Documentation
Represents a CORS configuration. Supported only for HTTP APIs. See Configuring CORS for more information.
See: newCors
smart constructor.
Cors' | |
|
Instances
Create a value of Cors
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:maxAge:Cors'
, cors_maxAge
- The number of seconds that the browser should cache preflight request
results. Supported only for HTTP APIs.
$sel:allowMethods:Cors'
, cors_allowMethods
- Represents a collection of allowed HTTP methods. Supported only for HTTP
APIs.
$sel:allowHeaders:Cors'
, cors_allowHeaders
- Represents a collection of allowed headers. Supported only for HTTP
APIs.
$sel:exposeHeaders:Cors'
, cors_exposeHeaders
- Represents a collection of exposed headers. Supported only for HTTP
APIs.
$sel:allowOrigins:Cors'
, cors_allowOrigins
- Represents a collection of allowed origins. Supported only for HTTP
APIs.
$sel:allowCredentials:Cors'
, cors_allowCredentials
- Specifies whether credentials are included in the CORS request.
Supported only for HTTP APIs.
cors_maxAge :: Lens' Cors (Maybe Int) Source #
The number of seconds that the browser should cache preflight request results. Supported only for HTTP APIs.
cors_allowMethods :: Lens' Cors (Maybe [Text]) Source #
Represents a collection of allowed HTTP methods. Supported only for HTTP APIs.
cors_allowHeaders :: Lens' Cors (Maybe [Text]) Source #
Represents a collection of allowed headers. Supported only for HTTP APIs.
cors_exposeHeaders :: Lens' Cors (Maybe [Text]) Source #
Represents a collection of exposed headers. Supported only for HTTP APIs.