Interface Cors.Builder
- All Superinterfaces:
Buildable
,CopyableBuilder<Cors.Builder,
,Cors> SdkBuilder<Cors.Builder,
,Cors> SdkPojo
- Enclosing class:
Cors
-
Method Summary
Modifier and TypeMethodDescriptionallowCredentials
(Boolean allowCredentials) Whether to allow cookies or other credentials in requests to your function URL.allowHeaders
(String... allowHeaders) The HTTP headers that origins can include in requests to your function URL.allowHeaders
(Collection<String> allowHeaders) The HTTP headers that origins can include in requests to your function URL.allowMethods
(String... allowMethods) The HTTP methods that are allowed when calling your function URL.allowMethods
(Collection<String> allowMethods) The HTTP methods that are allowed when calling your function URL.allowOrigins
(String... allowOrigins) The origins that can access your function URL.allowOrigins
(Collection<String> allowOrigins) The origins that can access your function URL.exposeHeaders
(String... exposeHeaders) The HTTP headers in your function response that you want to expose to origins that call your function URL.exposeHeaders
(Collection<String> exposeHeaders) The HTTP headers in your function response that you want to expose to origins that call your function URL.The maximum amount of time, in seconds, that web browsers can cache results of a preflight request.Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copy
Methods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, build
Methods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFields
-
Method Details
-
allowCredentials
Whether to allow cookies or other credentials in requests to your function URL. The default is
false
.- Parameters:
allowCredentials
- Whether to allow cookies or other credentials in requests to your function URL. The default isfalse
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
allowHeaders
The HTTP headers that origins can include in requests to your function URL. For example:
Date
,Keep-Alive
,X-Custom-Header
.- Parameters:
allowHeaders
- The HTTP headers that origins can include in requests to your function URL. For example:Date
,Keep-Alive
,X-Custom-Header
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
allowHeaders
The HTTP headers that origins can include in requests to your function URL. For example:
Date
,Keep-Alive
,X-Custom-Header
.- Parameters:
allowHeaders
- The HTTP headers that origins can include in requests to your function URL. For example:Date
,Keep-Alive
,X-Custom-Header
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
allowMethods
The HTTP methods that are allowed when calling your function URL. For example:
GET
,POST
,DELETE
, or the wildcard character (*
).- Parameters:
allowMethods
- The HTTP methods that are allowed when calling your function URL. For example:GET
,POST
,DELETE
, or the wildcard character (*
).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
allowMethods
The HTTP methods that are allowed when calling your function URL. For example:
GET
,POST
,DELETE
, or the wildcard character (*
).- Parameters:
allowMethods
- The HTTP methods that are allowed when calling your function URL. For example:GET
,POST
,DELETE
, or the wildcard character (*
).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
allowOrigins
The origins that can access your function URL. You can list any number of specific origins, separated by a comma. For example:
https://www.example.com
,http://localhost:60905
.Alternatively, you can grant access to all origins using the wildcard character (
*
).- Parameters:
allowOrigins
- The origins that can access your function URL. You can list any number of specific origins, separated by a comma. For example:https://www.example.com
,http://localhost:60905
.Alternatively, you can grant access to all origins using the wildcard character (
*
).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
allowOrigins
The origins that can access your function URL. You can list any number of specific origins, separated by a comma. For example:
https://www.example.com
,http://localhost:60905
.Alternatively, you can grant access to all origins using the wildcard character (
*
).- Parameters:
allowOrigins
- The origins that can access your function URL. You can list any number of specific origins, separated by a comma. For example:https://www.example.com
,http://localhost:60905
.Alternatively, you can grant access to all origins using the wildcard character (
*
).- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
exposeHeaders
The HTTP headers in your function response that you want to expose to origins that call your function URL. For example:
Date
,Keep-Alive
,X-Custom-Header
.- Parameters:
exposeHeaders
- The HTTP headers in your function response that you want to expose to origins that call your function URL. For example:Date
,Keep-Alive
,X-Custom-Header
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
exposeHeaders
The HTTP headers in your function response that you want to expose to origins that call your function URL. For example:
Date
,Keep-Alive
,X-Custom-Header
.- Parameters:
exposeHeaders
- The HTTP headers in your function response that you want to expose to origins that call your function URL. For example:Date
,Keep-Alive
,X-Custom-Header
.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
maxAge
The maximum amount of time, in seconds, that web browsers can cache results of a preflight request. By default, this is set to
0
, which means that the browser doesn't cache results.- Parameters:
maxAge
- The maximum amount of time, in seconds, that web browsers can cache results of a preflight request. By default, this is set to0
, which means that the browser doesn't cache results.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-