Class CfnApiMixinProps.Builder
java.lang.Object
software.amazon.awscdk.cfnpropertymixins.services.apigatewayv2.CfnApiMixinProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnApiMixinProps>
- Enclosing interface:
CfnApiMixinProps
@Stability(Stable)
public static final class CfnApiMixinProps.Builder
extends Object
implements software.amazon.jsii.Builder<CfnApiMixinProps>
A builder for
CfnApiMixinProps-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionapiKeySelectionExpression(String apiKeySelectionExpression) Sets the value ofCfnApiMixinProps.getApiKeySelectionExpression()Sets the value ofCfnApiMixinProps.getBasePath()Sets the value ofCfnApiMixinProps.getBody()bodyS3Location(CfnApiPropsMixin.BodyS3LocationProperty bodyS3Location) Sets the value ofCfnApiMixinProps.getBodyS3Location()bodyS3Location(IResolvable bodyS3Location) Sets the value ofCfnApiMixinProps.getBodyS3Location()build()Builds the configured instance.corsConfiguration(CfnApiPropsMixin.CorsProperty corsConfiguration) Sets the value ofCfnApiMixinProps.getCorsConfiguration()corsConfiguration(IResolvable corsConfiguration) Sets the value ofCfnApiMixinProps.getCorsConfiguration()credentialsArn(String credentialsArn) Sets the value ofCfnApiMixinProps.getCredentialsArn()description(String description) Sets the value ofCfnApiMixinProps.getDescription()disableExecuteApiEndpoint(Boolean disableExecuteApiEndpoint) Sets the value ofCfnApiMixinProps.getDisableExecuteApiEndpoint()disableExecuteApiEndpoint(IResolvable disableExecuteApiEndpoint) Sets the value ofCfnApiMixinProps.getDisableExecuteApiEndpoint()disableSchemaValidation(Boolean disableSchemaValidation) Sets the value ofCfnApiMixinProps.getDisableSchemaValidation()disableSchemaValidation(IResolvable disableSchemaValidation) Sets the value ofCfnApiMixinProps.getDisableSchemaValidation()failOnWarnings(Boolean failOnWarnings) Sets the value ofCfnApiMixinProps.getFailOnWarnings()failOnWarnings(IResolvable failOnWarnings) Sets the value ofCfnApiMixinProps.getFailOnWarnings()ipAddressType(String ipAddressType) Sets the value ofCfnApiMixinProps.getIpAddressType()Sets the value ofCfnApiMixinProps.getName()protocolType(String protocolType) Sets the value ofCfnApiMixinProps.getProtocolType()Sets the value ofCfnApiMixinProps.getRouteKey()routeSelectionExpression(String routeSelectionExpression) Sets the value ofCfnApiMixinProps.getRouteSelectionExpression()Sets the value ofCfnApiMixinProps.getTags()Sets the value ofCfnApiMixinProps.getTarget()target(IFunctionRef target) Sets the value ofCfnApiMixinProps.getTarget()Sets the value ofCfnApiMixinProps.getVersion()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
apiKeySelectionExpression
@Stability(Stable) public CfnApiMixinProps.Builder apiKeySelectionExpression(String apiKeySelectionExpression) Sets the value ofCfnApiMixinProps.getApiKeySelectionExpression()- Parameters:
apiKeySelectionExpression- An API key selection expression. Supported only for WebSocket APIs. See API Key Selection Expressions .- Returns:
this
-
basePath
Sets the value ofCfnApiMixinProps.getBasePath()- Parameters:
basePath- Specifies how to interpret the base path of the API during import. Valid values areignore,prepend, andsplit. The default value isignore. To learn more, see Set the OpenAPI basePath Property . Supported only for HTTP APIs.- Returns:
this
-
body
Sets the value ofCfnApiMixinProps.getBody()- Parameters:
body- The OpenAPI definition. Supported only for HTTP APIs. To import an HTTP API, you must specify aBodyorBodyS3Location. If you specify aBodyorBodyS3Location, don't specify CloudFormation resources such asAWS::ApiGatewayV2::AuthorizerorAWS::ApiGatewayV2::Route. API Gateway doesn't support the combination of OpenAPI and CloudFormation resources.- Returns:
this
-
bodyS3Location
Sets the value ofCfnApiMixinProps.getBodyS3Location()- Parameters:
bodyS3Location- The S3 location of an OpenAPI definition. Supported only for HTTP APIs. To import an HTTP API, you must specify aBodyorBodyS3Location. If you specify aBodyorBodyS3Location, don't specify CloudFormation resources such asAWS::ApiGatewayV2::AuthorizerorAWS::ApiGatewayV2::Route. API Gateway doesn't support the combination of OpenAPI and CloudFormation resources.- Returns:
this
-
bodyS3Location
@Stability(Stable) public CfnApiMixinProps.Builder bodyS3Location(CfnApiPropsMixin.BodyS3LocationProperty bodyS3Location) Sets the value ofCfnApiMixinProps.getBodyS3Location()- Parameters:
bodyS3Location- The S3 location of an OpenAPI definition. Supported only for HTTP APIs. To import an HTTP API, you must specify aBodyorBodyS3Location. If you specify aBodyorBodyS3Location, don't specify CloudFormation resources such asAWS::ApiGatewayV2::AuthorizerorAWS::ApiGatewayV2::Route. API Gateway doesn't support the combination of OpenAPI and CloudFormation resources.- Returns:
this
-
corsConfiguration
Sets the value ofCfnApiMixinProps.getCorsConfiguration()- Parameters:
corsConfiguration- A CORS configuration. Supported only for HTTP APIs. See Configuring CORS for more information.- Returns:
this
-
corsConfiguration
@Stability(Stable) public CfnApiMixinProps.Builder corsConfiguration(CfnApiPropsMixin.CorsProperty corsConfiguration) Sets the value ofCfnApiMixinProps.getCorsConfiguration()- Parameters:
corsConfiguration- A CORS configuration. Supported only for HTTP APIs. See Configuring CORS for more information.- Returns:
this
-
credentialsArn
Sets the value ofCfnApiMixinProps.getCredentialsArn()- Parameters:
credentialsArn- This property is part of quick create. It specifies the credentials required for the integration, if any. For a Lambda integration, three options are available. To specify an IAM Role for API Gateway to assume, use the role's Amazon Resource Name (ARN). To require that the caller's identity be passed through from the request, specifyarn:aws:iam::*:user/*. To use resource-based permissions on supported AWS services, specifynull. Currently, this property is not used for HTTP integrations. Supported only for HTTP APIs.- Returns:
this
-
description
Sets the value ofCfnApiMixinProps.getDescription()- Parameters:
description- The description of the API.- Returns:
this
-
disableExecuteApiEndpoint
@Stability(Stable) public CfnApiMixinProps.Builder disableExecuteApiEndpoint(Boolean disableExecuteApiEndpoint) Sets the value ofCfnApiMixinProps.getDisableExecuteApiEndpoint()- Parameters:
disableExecuteApiEndpoint- Specifies whether clients can invoke your API by using the defaultexecute-apiendpoint. By default, clients can invoke your API with the default https://{api_id}.execute-api.{region}.amazonaws.com endpoint. To require that clients use a custom domain name to invoke your API, disable the default endpoint.- Returns:
this
-
disableExecuteApiEndpoint
@Stability(Stable) public CfnApiMixinProps.Builder disableExecuteApiEndpoint(IResolvable disableExecuteApiEndpoint) Sets the value ofCfnApiMixinProps.getDisableExecuteApiEndpoint()- Parameters:
disableExecuteApiEndpoint- Specifies whether clients can invoke your API by using the defaultexecute-apiendpoint. By default, clients can invoke your API with the default https://{api_id}.execute-api.{region}.amazonaws.com endpoint. To require that clients use a custom domain name to invoke your API, disable the default endpoint.- Returns:
this
-
disableSchemaValidation
@Stability(Stable) public CfnApiMixinProps.Builder disableSchemaValidation(Boolean disableSchemaValidation) Sets the value ofCfnApiMixinProps.getDisableSchemaValidation()- Parameters:
disableSchemaValidation- Avoid validating models when creating a deployment. Supported only for WebSocket APIs.- Returns:
this
-
disableSchemaValidation
@Stability(Stable) public CfnApiMixinProps.Builder disableSchemaValidation(IResolvable disableSchemaValidation) Sets the value ofCfnApiMixinProps.getDisableSchemaValidation()- Parameters:
disableSchemaValidation- Avoid validating models when creating a deployment. Supported only for WebSocket APIs.- Returns:
this
-
failOnWarnings
Sets the value ofCfnApiMixinProps.getFailOnWarnings()- Parameters:
failOnWarnings- Specifies whether to rollback the API creation when a warning is encountered. By default, API creation continues if a warning is encountered.- Returns:
this
-
failOnWarnings
Sets the value ofCfnApiMixinProps.getFailOnWarnings()- Parameters:
failOnWarnings- Specifies whether to rollback the API creation when a warning is encountered. By default, API creation continues if a warning is encountered.- Returns:
this
-
ipAddressType
Sets the value ofCfnApiMixinProps.getIpAddressType()- Parameters:
ipAddressType- The IP address types that can invoke the API. Useipv4to allow only IPv4 addresses to invoke your API, or usedualstackto allow both IPv4 and IPv6 addresses to invoke your API.Don’t use IP address type for an HTTP API based on an OpenAPI specification. Instead, specify the IP address type in the OpenAPI specification.
- Returns:
this
-
name
Sets the value ofCfnApiMixinProps.getName()- Parameters:
name- The name of the API. Required unless you specify an OpenAPI definition forBodyorS3BodyLocation.- Returns:
this
-
protocolType
Sets the value ofCfnApiMixinProps.getProtocolType()- Parameters:
protocolType- The API protocol. Valid values areWEBSOCKETorHTTP. Required unless you specify an OpenAPI definition forBodyorS3BodyLocation.- Returns:
this
-
routeKey
Sets the value ofCfnApiMixinProps.getRouteKey()- Parameters:
routeKey- This property is part of quick create. If you don't specify arouteKey, a default route of$defaultis created. The$defaultroute acts as a catch-all for any request made to your API, for a particular stage. The$defaultroute key can't be modified. You can add routes after creating the API, and you can update the route keys of additional routes. Supported only for HTTP APIs.- Returns:
this
-
routeSelectionExpression
@Stability(Stable) public CfnApiMixinProps.Builder routeSelectionExpression(String routeSelectionExpression) Sets the value ofCfnApiMixinProps.getRouteSelectionExpression()- Parameters:
routeSelectionExpression- The route selection expression for the API. For HTTP APIs, therouteSelectionExpressionmust be${request.method} ${request.path}. If not provided, this will be the default for HTTP APIs. This property is required for WebSocket APIs.- Returns:
this
-
tags
Sets the value ofCfnApiMixinProps.getTags()- Parameters:
tags- The collection of tags. Each tag element is associated with a given resource.- Returns:
this
-
target
Sets the value ofCfnApiMixinProps.getTarget()- Parameters:
target- This property is part of quick create. Quick create produces an API with an integration, a default catch-all route, and a default stage which is configured to automatically deploy changes. For HTTP integrations, specify a fully qualified URL. For Lambda integrations, specify a function ARN. The type of the integration will be HTTP_PROXY or AWS_PROXY, respectively. Supported only for HTTP APIs.- Returns:
this
-
target
Sets the value ofCfnApiMixinProps.getTarget()- Parameters:
target- This property is part of quick create. Quick create produces an API with an integration, a default catch-all route, and a default stage which is configured to automatically deploy changes. For HTTP integrations, specify a fully qualified URL. For Lambda integrations, specify a function ARN. The type of the integration will be HTTP_PROXY or AWS_PROXY, respectively. Supported only for HTTP APIs.- Returns:
this
-
version
Sets the value ofCfnApiMixinProps.getVersion()- Parameters:
version- A version identifier for the API.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnApiMixinProps>- Returns:
- a new instance of
CfnApiMixinProps - Throws:
NullPointerException- if any required attribute was not provided
-