Module types

Source
Expand description

Data structures used by operation inputs/outputs.

Modules§

builders
Builders
error
Error types that AWS AppSync can respond with.

Structs§

AdditionalAuthenticationProvider

Describes an additional authentication provider.

Api

Describes an AppSync API. You can use Api for an AppSync API with your preferred configuration, such as an Event API that provides real-time message publishing and message subscriptions over WebSockets.

ApiAssociation

Describes an ApiAssociation object.

ApiCache

The ApiCache object.

ApiKey

Describes an API key.

Customers invoke AppSync GraphQL API operations with API keys as an identity mechanism. There are two key versions:

da1: We introduced this version at launch in November 2017. These keys always expire after 7 days. Amazon DynamoDB TTL manages key expiration. These keys ceased to be valid after February 21, 2018, and they should no longer be used.

  • ListApiKeys returns the expiration time in milliseconds.

  • CreateApiKey returns the expiration time in milliseconds.

  • UpdateApiKey is not available for this key version.

  • DeleteApiKey deletes the item from the table.

  • Expiration is stored in DynamoDB as milliseconds. This results in a bug where keys are not automatically deleted because DynamoDB expects the TTL to be stored in seconds. As a one-time action, we deleted these keys from the table on February 21, 2018.

da2: We introduced this version in February 2018 when AppSync added support to extend key expiration.

  • ListApiKeys returns the expiration time and deletion time in seconds.

  • CreateApiKey returns the expiration time and deletion time in seconds and accepts a user-provided expiration time in seconds.

  • UpdateApiKey returns the expiration time and and deletion time in seconds and accepts a user-provided expiration time in seconds. Expired API keys are kept for 60 days after the expiration time. You can update the key expiration time as long as the key isn't deleted.

  • DeleteApiKey deletes the item from the table.

  • Expiration is stored in DynamoDB as seconds. After the expiration time, using the key to authenticate will fail. However, you can reinstate the key before deletion.

  • Deletion is stored in DynamoDB as seconds. The key is deleted after deletion time.

AppSyncRuntime

Describes a runtime used by an Amazon Web Services AppSync pipeline resolver or Amazon Web Services AppSync function. Specifies the name and version of the runtime to use. Note that if a runtime is specified, code must also be specified.

AuthMode

Describes an authorization configuration. Use AuthMode to specify the publishing and subscription authorization configuration for an Event API.

AuthProvider

Describes an authorization provider.

AuthorizationConfig

The authorization configuration in case the HTTP endpoint requires authorization.

AwsIamConfig

The Identity and Access Management (IAM) configuration.

BadRequestDetail

Provides further details for the reason behind the bad request. For reason type CODE_ERROR, the detail will contain a list of code errors.

CachingConfig

The caching configuration for a resolver that has caching activated.

ChannelNamespace

Describes a channel namespace associated with an Api. The ChannelNamespace contains the definitions for code handlers for the Api.

CodeError

Describes an AppSync error.

CodeErrorLocation

Describes the location of the error in a code sample.

CognitoConfig

Describes an Amazon Cognito configuration.

CognitoUserPoolConfig

Describes an Amazon Cognito user pool configuration.

DataSource

Describes a data source.

DataSourceIntrospectionModel

Contains the introspected data that was retrieved from the data source.

DataSourceIntrospectionModelField

Represents the fields that were retrieved from the introspected data.

DataSourceIntrospectionModelFieldType

Represents the type data for each field retrieved from the introspection.

DataSourceIntrospectionModelIndex

The index that was retrieved from the introspected data.

DataSourceIntrospectionResult

Represents the output of a DataSourceIntrospectionResult. This is the populated result of a GetDataSourceIntrospection operation.

DeltaSyncConfig

Describes a Delta Sync configuration.

DomainNameConfig

Describes a configuration for a custom domain.

DynamodbDataSourceConfig

Describes an Amazon DynamoDB data source configuration.

ElasticsearchDataSourceConfig

Describes an OpenSearch data source configuration.

As of September 2021, Amazon Elasticsearch service is Amazon OpenSearch Service. This configuration is deprecated. For new data sources, use OpenSearchServiceDataSourceConfig to specify an OpenSearch data source.

EnhancedMetricsConfig

Enables and controls the enhanced metrics feature. Enhanced metrics emit granular data on API usage and performance such as AppSync request and error counts, latency, and cache hits/misses. All enhanced metric data is sent to your CloudWatch account, and you can configure the types of data that will be sent.

Enhanced metrics can be configured at the resolver, data source, and operation levels. EnhancedMetricsConfig contains three required parameters, each controlling one of these categories:

  1. resolverLevelMetricsBehavior: Controls how resolver metrics will be emitted to CloudWatch. Resolver metrics include:

    • GraphQL errors: The number of GraphQL errors that occurred.

    • Requests: The number of invocations that occurred during a request.

    • Latency: The time to complete a resolver invocation.

    • Cache hits: The number of cache hits during a request.

    • Cache misses: The number of cache misses during a request.

    These metrics can be emitted to CloudWatch per resolver or for all resolvers in the request. Metrics will be recorded by API ID and resolver name. resolverLevelMetricsBehavior accepts one of these values at a time:

    • FULL_REQUEST_RESOLVER_METRICS: Records and emits metric data for all resolvers in the request.

    • PER_RESOLVER_METRICS: Records and emits metric data for resolvers that have the metricsConfig value set to ENABLED.

  2. dataSourceLevelMetricsBehavior: Controls how data source metrics will be emitted to CloudWatch. Data source metrics include:

    • Requests: The number of invocations that occured during a request.

    • Latency: The time to complete a data source invocation.

    • Errors: The number of errors that occurred during a data source invocation.

    These metrics can be emitted to CloudWatch per data source or for all data sources in the request. Metrics will be recorded by API ID and data source name. dataSourceLevelMetricsBehavior accepts one of these values at a time:

    • FULL_REQUEST_DATA_SOURCE_METRICS: Records and emits metric data for all data sources in the request.

    • PER_DATA_SOURCE_METRICS: Records and emits metric data for data sources that have the metricsConfig value set to ENABLED.

  3. operationLevelMetricsConfig: Controls how operation metrics will be emitted to CloudWatch. Operation metrics include:

    • Requests: The number of times a specified GraphQL operation was called.

    • GraphQL errors: The number of GraphQL errors that occurred during a specified GraphQL operation.

    Metrics will be recorded by API ID and operation name. You can set the value to ENABLED or DISABLED.

ErrorDetail

Contains the list of errors generated. When using JavaScript, this will apply to the request or response function evaluation.

EvaluateCodeErrorDetail

Contains the list of errors from a code evaluation response.

EventBridgeDataSourceConfig

Describes an Amazon EventBridge bus data source configuration.

EventConfig

Describes the authorization configuration for connections, message publishing, message subscriptions, and logging for an Event API.

EventLogConfig

Describes the CloudWatch Logs configuration for the Event API.

FunctionConfiguration

A function is a reusable entity. You can use multiple functions to compose the resolver logic.

GraphqlApi

Describes a GraphQL API.

HandlerConfig

The configuration for a handler.

HandlerConfigs

The configuration for the OnPublish and OnSubscribe handlers.

HttpDataSourceConfig

Describes an HTTP data source configuration.

Integration

The integration data source configuration for the handler.

LambdaAuthorizerConfig

A LambdaAuthorizerConfig specifies how to authorize AppSync API access when using the AWS_LAMBDA authorizer mode. Be aware that an AppSync API can have only one Lambda authorizer configured at a time.

LambdaConfig

The configuration for a Lambda data source.

LambdaConflictHandlerConfig

The LambdaConflictHandlerConfig object when configuring LAMBDA as the Conflict Handler.

LambdaDataSourceConfig

Describes an Lambda data source configuration.

LogConfig

The Amazon CloudWatch Logs configuration.

OpenIdConnectConfig

Describes an OpenID Connect (OIDC) configuration.

OpenSearchServiceDataSourceConfig

Describes an OpenSearch data source configuration.

PipelineConfig

The pipeline configuration for a resolver of kind PIPELINE.

RdsDataApiConfig

Contains the metadata required to introspect the RDS cluster.

RdsHttpEndpointConfig

The Amazon Relational Database Service (Amazon RDS) HTTP endpoint configuration.

RelationalDatabaseDataSourceConfig

Describes a relational database data source configuration.

Resolver

Describes a resolver.

SourceApiAssociation

Describes the configuration of a source API. A source API is a GraphQL API that is linked to a merged API. There can be multiple source APIs attached to each merged API. When linked to a merged API, the source API's schema, data sources, and resolvers will be combined with other linked source API data to form a new, singular API.

Source APIs can originate from your account or from other accounts via Amazon Web Services Resource Access Manager. For more information about sharing resources from other accounts, see What is Amazon Web Services Resource Access Manager? in the Amazon Web Services Resource Access Manager guide.

SourceApiAssociationConfig

Describes properties used to specify configurations related to a source API.

SourceApiAssociationSummary

Describes the ARNs and IDs of associations, Merged APIs, and source APIs.

SyncConfig

Describes a Sync configuration for a resolver.

Specifies which Conflict Detection strategy and Resolution strategy to use when the resolver is invoked.

Type

Describes a type.

UserPoolConfig

Describes an Amazon Cognito user pool configuration.

Enums§

ApiCacheStatus
When writing a match expression against ApiCacheStatus, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
ApiCacheType
When writing a match expression against ApiCacheType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
ApiCachingBehavior
When writing a match expression against ApiCachingBehavior, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
AssociationStatus
When writing a match expression against AssociationStatus, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
AuthenticationType
When writing a match expression against AuthenticationType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
AuthorizationType
When writing a match expression against AuthorizationType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
BadRequestReason
When writing a match expression against BadRequestReason, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
CacheHealthMetricsConfig
When writing a match expression against CacheHealthMetricsConfig, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
ConflictDetectionType
When writing a match expression against ConflictDetectionType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
ConflictHandlerType
When writing a match expression against ConflictHandlerType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
DataSourceIntrospectionStatus
When writing a match expression against DataSourceIntrospectionStatus, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
DataSourceLevelMetricsBehavior
When writing a match expression against DataSourceLevelMetricsBehavior, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
DataSourceLevelMetricsConfig
When writing a match expression against DataSourceLevelMetricsConfig, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
DataSourceType
When writing a match expression against DataSourceType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
DefaultAction
When writing a match expression against DefaultAction, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
EventLogLevel
When writing a match expression against EventLogLevel, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
FieldLogLevel
When writing a match expression against FieldLogLevel, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
GraphQlApiIntrospectionConfig
When writing a match expression against GraphQlApiIntrospectionConfig, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
GraphQlApiType
When writing a match expression against GraphQlApiType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
GraphQlApiVisibility
When writing a match expression against GraphQlApiVisibility, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
HandlerBehavior
When writing a match expression against HandlerBehavior, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
InvokeType
When writing a match expression against InvokeType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
MergeType
When writing a match expression against MergeType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
OperationLevelMetricsConfig
When writing a match expression against OperationLevelMetricsConfig, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
OutputType
When writing a match expression against OutputType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
Ownership
When writing a match expression against Ownership, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
RelationalDatabaseSourceType
When writing a match expression against RelationalDatabaseSourceType, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
ResolverKind
When writing a match expression against ResolverKind, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
ResolverLevelMetricsBehavior
When writing a match expression against ResolverLevelMetricsBehavior, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
ResolverLevelMetricsConfig
When writing a match expression against ResolverLevelMetricsConfig, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
RuntimeName
When writing a match expression against RuntimeName, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
SchemaStatus
When writing a match expression against SchemaStatus, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
SourceApiAssociationStatus
When writing a match expression against SourceApiAssociationStatus, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.
TypeDefinitionFormat
When writing a match expression against TypeDefinitionFormat, it is important to ensure your code is forward-compatible. That is, if a match arm handles a case for a feature that is supported by the service but has not been represented as an enum variant in a current version of SDK, your code should continue to work when you upgrade SDK to a future version in which the enum does include a variant for that feature.