Class AppsyncFunction.Builder
java.lang.Object
software.amazon.awscdk.services.appsync.AppsyncFunction.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<AppsyncFunction>
- Enclosing class:
AppsyncFunction
@Stability(Stable)
public static final class AppsyncFunction.Builder
extends Object
implements software.amazon.jsii.Builder<AppsyncFunction>
A fluent builder for
AppsyncFunction
.-
Method Summary
Modifier and TypeMethodDescriptionapi
(IGraphqlApi api) the GraphQL Api linked to this AppSync Function.build()
The function code.static AppsyncFunction.Builder
dataSource
(BaseDataSource dataSource) the data source linked to this AppSync Function.description
(String description) the description for this AppSync Function.maxBatchSize
(Number maxBatchSize) The maximum number of resolver request inputs that will be sent to a single AWS Lambda function in a BatchInvoke operation.the name of the AppSync Function.requestMappingTemplate
(MappingTemplate requestMappingTemplate) the request mapping template for the AppSync Function.responseMappingTemplate
(MappingTemplate responseMappingTemplate) the response mapping template for the AppSync Function.runtime
(FunctionRuntime runtime) The functions runtime.
-
Method Details
-
create
@Stability(Stable) public static AppsyncFunction.Builder create(software.constructs.Construct scope, String id) - Parameters:
scope
- This parameter is required.id
- This parameter is required.- Returns:
- a new instance of
AppsyncFunction.Builder
.
-
name
the name of the AppSync Function.- Parameters:
name
- the name of the AppSync Function. This parameter is required.- Returns:
this
-
code
The function code.Default: - no code is used
- Parameters:
code
- The function code. This parameter is required.- Returns:
this
-
description
the description for this AppSync Function.Default: - no description
- Parameters:
description
- the description for this AppSync Function. This parameter is required.- Returns:
this
-
maxBatchSize
The maximum number of resolver request inputs that will be sent to a single AWS Lambda function in a BatchInvoke operation.Can only be set when using LambdaDataSource.
Default: - No max batch size
- Parameters:
maxBatchSize
- The maximum number of resolver request inputs that will be sent to a single AWS Lambda function in a BatchInvoke operation. This parameter is required.- Returns:
this
-
requestMappingTemplate
@Stability(Stable) public AppsyncFunction.Builder requestMappingTemplate(MappingTemplate requestMappingTemplate) the request mapping template for the AppSync Function.Default: - no request mapping template
- Parameters:
requestMappingTemplate
- the request mapping template for the AppSync Function. This parameter is required.- Returns:
this
-
responseMappingTemplate
@Stability(Stable) public AppsyncFunction.Builder responseMappingTemplate(MappingTemplate responseMappingTemplate) the response mapping template for the AppSync Function.Default: - no response mapping template
- Parameters:
responseMappingTemplate
- the response mapping template for the AppSync Function. This parameter is required.- Returns:
this
-
runtime
The functions runtime.Default: - no function runtime, VTL mapping templates used
- Parameters:
runtime
- The functions runtime. This parameter is required.- Returns:
this
-
api
the GraphQL Api linked to this AppSync Function.- Parameters:
api
- the GraphQL Api linked to this AppSync Function. This parameter is required.- Returns:
this
-
dataSource
the data source linked to this AppSync Function.- Parameters:
dataSource
- the data source linked to this AppSync Function. This parameter is required.- Returns:
this
-
build
- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<AppsyncFunction>
- Returns:
- a newly built instance of
AppsyncFunction
.
-