Class CfnGraphQLApi
- All Implemented Interfaces:
IInspectable,ITaggable,IGraphQLApiRef,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
AWS::AppSync::GraphQLApi resource creates a new AWS AppSync GraphQL API.
This is the top-level construct for your application. For more information, see Quick Start in the AWS AppSync Developer Guide .
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.appsync.*;
CfnGraphQLApi cfnGraphQLApi = CfnGraphQLApi.Builder.create(this, "MyCfnGraphQLApi")
.authenticationType("authenticationType")
.name("name")
// the properties below are optional
.additionalAuthenticationProviders(List.of(AdditionalAuthenticationProviderProperty.builder()
.authenticationType("authenticationType")
// the properties below are optional
.lambdaAuthorizerConfig(LambdaAuthorizerConfigProperty.builder()
.authorizerResultTtlInSeconds(123)
.authorizerUri("authorizerUri")
.identityValidationExpression("identityValidationExpression")
.build())
.openIdConnectConfig(OpenIDConnectConfigProperty.builder()
.authTtl(123)
.clientId("clientId")
.iatTtl(123)
.issuer("issuer")
.build())
.userPoolConfig(CognitoUserPoolConfigProperty.builder()
.appIdClientRegex("appIdClientRegex")
.awsRegion("awsRegion")
.userPoolId("userPoolId")
.build())
.build()))
.apiType("apiType")
.enhancedMetricsConfig(EnhancedMetricsConfigProperty.builder()
.dataSourceLevelMetricsBehavior("dataSourceLevelMetricsBehavior")
.operationLevelMetricsConfig("operationLevelMetricsConfig")
.resolverLevelMetricsBehavior("resolverLevelMetricsBehavior")
.build())
.environmentVariables(Map.of(
"environmentVariablesKey", "environmentVariables"))
.introspectionConfig("introspectionConfig")
.lambdaAuthorizerConfig(LambdaAuthorizerConfigProperty.builder()
.authorizerResultTtlInSeconds(123)
.authorizerUri("authorizerUri")
.identityValidationExpression("identityValidationExpression")
.build())
.logConfig(LogConfigProperty.builder()
.cloudWatchLogsRoleArn("cloudWatchLogsRoleArn")
.excludeVerboseContent(false)
.fieldLogLevel("fieldLogLevel")
.build())
.mergedApiExecutionRoleArn("mergedApiExecutionRoleArn")
.openIdConnectConfig(OpenIDConnectConfigProperty.builder()
.authTtl(123)
.clientId("clientId")
.iatTtl(123)
.issuer("issuer")
.build())
.ownerContact("ownerContact")
.queryDepthLimit(123)
.resolverCountLimit(123)
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.userPoolConfig(UserPoolConfigProperty.builder()
.appIdClientRegex("appIdClientRegex")
.awsRegion("awsRegion")
.defaultAction("defaultAction")
.userPoolId("userPoolId")
.build())
.visibility("visibility")
.xrayEnabled(false)
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceDescribes an additional authentication provider.static final classA fluent builder forCfnGraphQLApi.static interfaceDescribes an Amazon Cognito user pool configuration.static interfaceDescribes an enhanced metrics configuration.static interfaceConfiguration for AWS Lambda function authorization.static interfaceTheLogConfigproperty type specifies the logging configuration when writing GraphQL operations and tracing to Amazon CloudWatch for an AWS AppSync GraphQL API.static interfaceTheOpenIDConnectConfigproperty type specifies the optional authorization configuration for using an OpenID Connect compliant service with your GraphQL endpoint for an AWS AppSync GraphQL API.static interfaceTheUserPoolConfigproperty type specifies the optional authorization configuration for using Amazon Cognito user pools with your GraphQL endpoint for an AWS AppSync GraphQL API.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.services.appsync.IGraphQLApiRef
IGraphQLApiRef.Jsii$Default, IGraphQLApiRef.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggable
ITaggable.Jsii$Default, ITaggable.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnGraphQLApi(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnGraphQLApi(software.amazon.jsii.JsiiObjectRef objRef) CfnGraphQLApi(software.constructs.Construct scope, String id, CfnGraphQLApiProps props) -
Method Summary
Modifier and TypeMethodDescriptionA list of additional authentication providers for theGraphqlApiAPI.The value that indicates whether the GraphQL API is a standard API (GRAPHQL) or merged API (MERGED).Unique AWS AppSync GraphQL API identifier.The Amazon Resource Name (ARN) of the API key, such asarn:aws:appsync:us-east-1:123456789012:apis/graphqlapiid.The fully qualified domain name (FQDN) of the endpoint URL of your GraphQL API.The GraphQL endpoint ARN.The Endpoint URL of your GraphQL API.The fully qualified domain name (FQDN) of the real-time endpoint URL of your GraphQL API.The GraphQL API real-time endpoint URL.Security configuration for your GraphQL API.Enables and controls the enhanced metrics feature.A map containing the list of resources with their properties and environment variables.A reference to a GraphQLApi resource.Sets the value of the GraphQL API to enable (ENABLED) or disable (DISABLED) introspection.ALambdaAuthorizerConfigholds configuration on how to authorize AWS AppSync API access when using theAWS_LAMBDAauthorizer mode.The Amazon CloudWatch Logs configuration.The AWS Identity and Access Management service role ARN for a merged API.getName()The API name.The OpenID Connect configuration.The owner contact information for an API resource.The maximum depth a query can have in a single request.The maximum number of resolvers that can be invoked in a single request.getTags()Tag Manager which manages the tags for this resource.An arbitrary set of tags (key-value pairs) for this GraphQL API.Optional authorization configuration for using Amazon Cognito user pools with your GraphQL endpoint.Sets the scope of the GraphQL API to public (GLOBAL) or private (PRIVATE).A flag indicating whether to use AWS X-Ray tracing for thisGraphqlApi.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidA list of additional authentication providers for theGraphqlApiAPI.voidA list of additional authentication providers for theGraphqlApiAPI.voidsetApiType(String value) The value that indicates whether the GraphQL API is a standard API (GRAPHQL) or merged API (MERGED).voidsetAuthenticationType(String value) Security configuration for your GraphQL API.voidEnables and controls the enhanced metrics feature.voidEnables and controls the enhanced metrics feature.voidsetEnvironmentVariables(Map<String, String> value) A map containing the list of resources with their properties and environment variables.voidA map containing the list of resources with their properties and environment variables.voidsetIntrospectionConfig(String value) Sets the value of the GraphQL API to enable (ENABLED) or disable (DISABLED) introspection.voidALambdaAuthorizerConfigholds configuration on how to authorize AWS AppSync API access when using theAWS_LAMBDAauthorizer mode.voidALambdaAuthorizerConfigholds configuration on how to authorize AWS AppSync API access when using theAWS_LAMBDAauthorizer mode.voidsetLogConfig(IResolvable value) The Amazon CloudWatch Logs configuration.voidThe Amazon CloudWatch Logs configuration.voidThe AWS Identity and Access Management service role ARN for a merged API.voidThe API name.voidThe OpenID Connect configuration.voidThe OpenID Connect configuration.voidsetOwnerContact(String value) The owner contact information for an API resource.voidsetQueryDepthLimit(Number value) The maximum depth a query can have in a single request.voidsetResolverCountLimit(Number value) The maximum number of resolvers that can be invoked in a single request.voidsetTagsRaw(List<CfnTag> value) An arbitrary set of tags (key-value pairs) for this GraphQL API.voidsetUserPoolConfig(IResolvable value) Optional authorization configuration for using Amazon Cognito user pools with your GraphQL endpoint.voidOptional authorization configuration for using Amazon Cognito user pools with your GraphQL endpoint.voidsetVisibility(String value) Sets the scope of the GraphQL API to public (GLOBAL) or private (PRIVATE).voidsetXrayEnabled(Boolean value) A flag indicating whether to use AWS X-Ray tracing for thisGraphqlApi.voidsetXrayEnabled(IResolvable value) A flag indicating whether to use AWS X-Ray tracing for thisGraphqlApi.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnGraphQLApi
protected CfnGraphQLApi(software.amazon.jsii.JsiiObjectRef objRef) -
CfnGraphQLApi
protected CfnGraphQLApi(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnGraphQLApi
@Stability(Stable) public CfnGraphQLApi(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnGraphQLApiProps props) - Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties. This parameter is required.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrApiId
Unique AWS AppSync GraphQL API identifier. -
getAttrArn
The Amazon Resource Name (ARN) of the API key, such asarn:aws:appsync:us-east-1:123456789012:apis/graphqlapiid. -
getAttrGraphQlDns
The fully qualified domain name (FQDN) of the endpoint URL of your GraphQL API. -
getAttrGraphQlEndpointArn
The GraphQL endpoint ARN. -
getAttrGraphQlUrl
The Endpoint URL of your GraphQL API. -
getAttrRealtimeDns
The fully qualified domain name (FQDN) of the real-time endpoint URL of your GraphQL API. -
getAttrRealtimeUrl
The GraphQL API real-time endpoint URL.For more information, see Discovering the real-time endpoint from the GraphQL endpoint .
-
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getGraphQlApiRef
A reference to a GraphQLApi resource.- Specified by:
getGraphQlApiRefin interfaceIGraphQLApiRef
-
getTags
Tag Manager which manages the tags for this resource. -
getAuthenticationType
Security configuration for your GraphQL API. -
setAuthenticationType
Security configuration for your GraphQL API. -
getName
The API name. -
setName
The API name. -
getAdditionalAuthenticationProviders
A list of additional authentication providers for theGraphqlApiAPI.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnGraphQLApi.AdditionalAuthenticationProviderProperty> -
setAdditionalAuthenticationProviders
A list of additional authentication providers for theGraphqlApiAPI. -
setAdditionalAuthenticationProviders
A list of additional authentication providers for theGraphqlApiAPI. -
getApiType
The value that indicates whether the GraphQL API is a standard API (GRAPHQL) or merged API (MERGED). -
setApiType
The value that indicates whether the GraphQL API is a standard API (GRAPHQL) or merged API (MERGED). -
getEnhancedMetricsConfig
Enables and controls the enhanced metrics feature.Returns union: either
IResolvableorCfnGraphQLApi.EnhancedMetricsConfigProperty -
setEnhancedMetricsConfig
Enables and controls the enhanced metrics feature. -
setEnhancedMetricsConfig
@Stability(Stable) public void setEnhancedMetricsConfig(@Nullable CfnGraphQLApi.EnhancedMetricsConfigProperty value) Enables and controls the enhanced metrics feature. -
getEnvironmentVariables
A map containing the list of resources with their properties and environment variables.Returns union: either Mapinvalid input: '<'String,
String> orIResolvable -
setEnvironmentVariables
A map containing the list of resources with their properties and environment variables. -
setEnvironmentVariables
A map containing the list of resources with their properties and environment variables. -
getIntrospectionConfig
Sets the value of the GraphQL API to enable (ENABLED) or disable (DISABLED) introspection. -
setIntrospectionConfig
Sets the value of the GraphQL API to enable (ENABLED) or disable (DISABLED) introspection. -
getLambdaAuthorizerConfig
ALambdaAuthorizerConfigholds configuration on how to authorize AWS AppSync API access when using theAWS_LAMBDAauthorizer mode.Returns union: either
IResolvableorCfnGraphQLApi.LambdaAuthorizerConfigProperty -
setLambdaAuthorizerConfig
ALambdaAuthorizerConfigholds configuration on how to authorize AWS AppSync API access when using theAWS_LAMBDAauthorizer mode. -
setLambdaAuthorizerConfig
@Stability(Stable) public void setLambdaAuthorizerConfig(@Nullable CfnGraphQLApi.LambdaAuthorizerConfigProperty value) ALambdaAuthorizerConfigholds configuration on how to authorize AWS AppSync API access when using theAWS_LAMBDAauthorizer mode. -
getLogConfig
The Amazon CloudWatch Logs configuration.Returns union: either
IResolvableorCfnGraphQLApi.LogConfigProperty -
setLogConfig
The Amazon CloudWatch Logs configuration. -
setLogConfig
The Amazon CloudWatch Logs configuration. -
getMergedApiExecutionRoleArn
The AWS Identity and Access Management service role ARN for a merged API. -
setMergedApiExecutionRoleArn
The AWS Identity and Access Management service role ARN for a merged API. -
getOpenIdConnectConfig
The OpenID Connect configuration.Returns union: either
IResolvableorCfnGraphQLApi.OpenIDConnectConfigProperty -
setOpenIdConnectConfig
The OpenID Connect configuration. -
setOpenIdConnectConfig
@Stability(Stable) public void setOpenIdConnectConfig(@Nullable CfnGraphQLApi.OpenIDConnectConfigProperty value) The OpenID Connect configuration. -
getOwnerContact
The owner contact information for an API resource. -
setOwnerContact
The owner contact information for an API resource. -
getQueryDepthLimit
The maximum depth a query can have in a single request. -
setQueryDepthLimit
The maximum depth a query can have in a single request. -
getResolverCountLimit
The maximum number of resolvers that can be invoked in a single request. -
setResolverCountLimit
The maximum number of resolvers that can be invoked in a single request. -
getTagsRaw
An arbitrary set of tags (key-value pairs) for this GraphQL API. -
setTagsRaw
An arbitrary set of tags (key-value pairs) for this GraphQL API. -
getUserPoolConfig
Optional authorization configuration for using Amazon Cognito user pools with your GraphQL endpoint.Returns union: either
IResolvableorCfnGraphQLApi.UserPoolConfigProperty -
setUserPoolConfig
Optional authorization configuration for using Amazon Cognito user pools with your GraphQL endpoint. -
setUserPoolConfig
@Stability(Stable) public void setUserPoolConfig(@Nullable CfnGraphQLApi.UserPoolConfigProperty value) Optional authorization configuration for using Amazon Cognito user pools with your GraphQL endpoint. -
getVisibility
Sets the scope of the GraphQL API to public (GLOBAL) or private (PRIVATE). -
setVisibility
Sets the scope of the GraphQL API to public (GLOBAL) or private (PRIVATE). -
getXrayEnabled
A flag indicating whether to use AWS X-Ray tracing for thisGraphqlApi.Returns union: either
BooleanorIResolvable -
setXrayEnabled
A flag indicating whether to use AWS X-Ray tracing for thisGraphqlApi. -
setXrayEnabled
A flag indicating whether to use AWS X-Ray tracing for thisGraphqlApi.
-