Options
All
  • Public
  • Public/Protected
  • All
Menu
AWS Amplify

Discord Chat Language grade: JavaScript build:started

Reporting Bugs / Feature Requests

Open Bugs Feature Requests Closed Issues

Note aws-amplify 5 has been released. If you are looking for upgrade guidance click here

AWS Amplify is a JavaScript library for frontend and mobile developers building cloud-enabled applications

AWS Amplify provides a declarative and easy-to-use interface across different categories of cloud operations. AWS Amplify goes well with any JavaScript based frontend workflow and React Native for mobile developers.

Our default implementation works with Amazon Web Services (AWS), but AWS Amplify is designed to be open and pluggable for any custom backend or service.

Visit our Documentation site to learn more about AWS Amplify. Please see our Amplify JavaScript page within our Documentation site for information around the full list of features we support.

Features

Category AWS Provider Description
Authentication Amazon Cognito APIs and Building blocks to create Authentication experiences.
Analytics Amazon Pinpoint Collect Analytics data for your application including tracking user sessions.
REST API Amazon API Gateway Sigv4 signing and AWS auth for API Gateway and other REST endpoints.
GraphQL API AWS AppSync Interact with your GraphQL or AWS AppSync endpoint(s).
DataStore AWS AppSync Programming model for shared and distributed data, with simple online/offline synchronization.
Storage Amazon S3 Manages content in public, protected, private storage buckets.
Geo (Developer preview) Amazon Location Service Provides APIs and UI components for maps and location search for JavaScript-based web apps.
Push Notifications Amazon Pinpoint Allows you to integrate push notifications in your app with Amazon Pinpoint targeting and campaign management support.
Interactions Amazon Lex Create conversational bots powered by deep learning technologies.
PubSub AWS IoT Provides connectivity with cloud-based message-oriented middleware.
Internationalization --- A lightweight internationalization solution.
Cache --- Provides a generic LRU cache for JavaScript developers to store data with priority and expiration settings.
Predictions Various* Connect your app with machine learning services like NLP, computer vision, TTS, and more.
  • Predictions utilizes a range of Amazon's Machine Learning services, including: Amazon Comprehend, Amazon Polly, Amazon Rekognition, Amazon Textract, and Amazon Translate.

Getting Started

AWS Amplify is available as aws-amplify on npm.

To get started pick your platform from our Getting Started home page

Notice:

Amplify 5.x.x has breaking changes. Please see the breaking changes below:

  • If you are using default exports from any Amplify package, then you will need to migrate to using named exports. For example:

    - import Amplify from 'aws-amplify';
    + import { Amplify } from 'aws-amplify'
    
    - import Analytics from '@aws-amplify/analytics';
    + import { Analytics } from '@aws-amplify/analytics';
    // or better
    + import { Analytics } from 'aws-amplify';
    
    - import Storage from '@aws-amplify/storage';
    + import { Storage } from '@aws-amplify/storage';
    // or better
    + import { Storage } from 'aws-amplify';
  • Datastore predicate syntax has changed, impacting the DataStore.query, DataStore.save, DataStore.delete, and DataStore.observe interfaces. For example:

    - await DataStore.delete(Post, (post) => post.status('eq', PostStatus.INACTIVE));
    + await DataStore.delete(Post, (post) => post.status.eq(PostStatus.INACTIVE));
    
    - await DataStore.query(Post, p => p.and( p => [p.title('eq', 'Amplify Getting Started Guide'), p.score('gt', 8)]));
    + await DataStore.query(Post, p => p.and( p => [p.title.eq('Amplify Getting Started Guide'), p.score.gt(8)]));
  • Storage.list has changed the name of the maxKeys parameter to pageSize and has a new return type that contains the results list. For example:

    - const photos = await Storage.list('photos/', { maxKeys: 100 });
    - const { key } = photos[0];
    
    + const photos = await Storage.list('photos/', { pageSize: 100 });
    + const { key } = photos.results[0];
  • Storage.put with resumable turned on has changed the key to no longer include the bucket name. For example:

    - let uploadedObjectKey;
    - Storage.put(file.name, file, {
    -   resumable: true,
    -   // Necessary to parse the bucket name out to work with the key
    -   completeCallback: (obj) => uploadedObjectKey = obj.key.substring( obj.key.indexOf("/") + 1 )
    - }
    
    + let uploadedObjectKey;
    + Storage.put(file.name, file, {
    +   resumable: true,
    +   completeCallback: (obj) => uploadedObjectKey = obj.key
    + }
  • Analytics.record no longer accepts string as input. For example:

    - Analytics.record('my example event');
    + Analytics.record({ name: 'my example event' });
  • The JS export has been removed from @aws-amplify/core in favor of exporting the functions it contained.

  • Any calls to Amplify.Auth, Amplify.Cache, and Amplify.ServiceWorker are no longer supported. Instead, your code should use the named exports. For example:

    - import { Amplify } from 'aws-amplify';
    - Amplify.configure(...);
    - // ...
    - Amplify.Auth.signIn(...);
    
    + import { Amplify, Auth } from 'aws-amplify';
    + Amplify.configure(...);
    + // ...
    + Auth.signIn(...);

Amplify 4.x.x has breaking changes for React Native. Please see the breaking changes below:

  • If you are using React Native (vanilla or Expo), you will need to add the following React Native community dependencies:
    • @react-native-community/netinfo
    • @react-native-async-storage/async-storage
// React Native
yarn add aws-amplify amazon-cognito-identity-js @react-native-community/netinfo @react-native-async-storage/async-storage
npx pod-install

// Expo
yarn add aws-amplify @react-native-community/netinfo @react-native-async-storage/async-storage

Amplify 3.x.x has breaking changes. Please see the breaking changes below:

  • AWS.credentials and AWS.config don’t exist anymore in Amplify JavaScript.
    • Both options will not be available to use in version 3. You will not be able to use and set your own credentials.
    • For more information on this change, please see the AWS SDK for JavaScript v3
  • aws-sdk@2.x has been removed from Amplify@3.x.x in favor of version 3 of aws-sdk-js. We recommend to migrate to aws-sdk-js-v3 if you rely on AWS services that are not supported by Amplify, since aws-sdk-js-v3 is imported modularly.

If you can't migrate to aws-sdk-js-v3 or rely on aws-sdk@2.x, you will need to import it separately.

  • If you are using exported paths within your Amplify JS application, (e.g. import from "@aws-amplify/analytics/lib/Analytics") this will now break and no longer will be supported. You will need to change to named imports:

    import { Analytics } from 'aws-amplify';
  • If you are using categories as Amplify.<Category>, this will no longer work and we recommend to import the category you are needing to use:

    import { Auth } from 'aws-amplify';

DataStore Docs

For more information on contributing to DataStore / how DataStore works, see the DataStore Docs

Index

Modules

Enumerations

Classes

Interfaces

Type aliases

Variables

Functions

Object literals

Type aliases

AWSAppSyncRealTimeAuthInput

AWSAppSyncRealTimeAuthInput: Partial<AWSAppSyncRealTimeProviderOptions> & object

AWSLexProviderSendResponse

AWSLexProviderSendResponse: PostTextCommandOutput | PostContentCommandOutputFormatted

AWSLexV2ProviderSendResponse

AWSLexV2ProviderSendResponse: RecognizeTextCommandOutput | RecognizeUtteranceCommandOutputFormatted

AllFieldOperators

AllFieldOperators: keyof AllOperators

AllOperators

AllOperators: NumberOperators<any> & StringOperators<any> & ArrayOperators<any>

AmazonLocationServiceBatchGeofenceError

AmazonLocationServiceBatchGeofenceError: Omit<GeofenceError, "error"> & object

AmazonLocationServiceBatchGeofenceErrorMessages

AmazonLocationServiceBatchGeofenceErrorMessages: "AccessDeniedException" | "InternalServerException" | "ResourceNotFoundException" | "ThrottlingException" | "ValidationException"

AmazonLocationServiceDeleteGeofencesResults

AmazonLocationServiceDeleteGeofencesResults: Omit<DeleteGeofencesResults, "errors"> & object

AmazonLocationServiceGeofence

AmazonLocationServiceGeofence: Omit<Geofence, "status"> & object

AmazonLocationServiceGeofenceOptions

AmazonLocationServiceGeofenceOptions: GeofenceOptions & object

AmazonLocationServiceGeofenceStatus

AmazonLocationServiceGeofenceStatus: "ACTIVE" | "PENDING" | "FAILED" | "DELETED" | "DELETING"

AmazonLocationServiceListGeofenceOptions

AmazonLocationServiceListGeofenceOptions: ListGeofenceOptions & object

AmplifyContext

AmplifyContext: object

Type declaration

  • API: typeof API
  • Auth: typeof Auth
  • Cache: typeof Cache

AmplifyThemeType

AmplifyThemeType: Record<string, any>

ApiInfo

ApiInfo: object

Type declaration

  • Optional custom_header?: function
      • (): object
      • Returns object

        • [key: string]: string
  • endpoint: string
  • Optional region?: string
  • Optional service?: string

ArrayOperators

ArrayOperators: object

Type declaration

  • contains: T
  • notContains: T

AssociatedWith

AssociatedWith: object

Type declaration

  • associatedWith: string | string[]
  • connectionType: "HAS_MANY" | "HAS_ONE"
  • Optional targetName?: string
  • Optional targetNames?: string[]

AuthErrorMessages

AuthErrorMessages: object

Type declaration

AuthModeStrategy

AuthModeStrategy: function

Type declaration

AuthModeStrategyParams

AuthModeStrategyParams: object

Type declaration

AuthModeStrategyReturn

AuthModeStrategyReturn: GRAPHQL_AUTH_MODE | GRAPHQL_AUTH_MODE[] | undefined | null

AuthProviders

AuthProviders: object

Type declaration

  • functionAuthProvider: function

AuthorizationInfo

AuthorizationInfo: object

Type declaration

  • authMode: GRAPHQL_AUTH_MODE
  • isOwner: boolean
  • Optional ownerField?: string
  • Optional ownerValue?: string

AuthorizationRule

AuthorizationRule: object

Type declaration

  • areSubscriptionsPublic: boolean
  • authStrategy: "owner" | "groups" | "private" | "public"
  • groupClaim: string
  • groups: [string]
  • identityClaim: string
  • ownerField: string
  • provider: "userPools" | "oidc" | "iam" | "apiKey"

AutoTrackAttributes

AutoTrackAttributes: function | EventAttributes

AxiosHttpHandlerOptions

AxiosHttpHandlerOptions: HttpHandlerOptions & object

BlockList

BlockList: Block[]

BooleanOperators

BooleanOperators: EqualityOperators<T>

BoundingBox

Optional height

height: Number

Optional left

left: Number

Optional top

top: Number

Optional width

width: Number

ClientMetaData

ClientMetaData: object | undefined

CommonStorageOptions

CommonStorageOptions: Omit<StorageOptions, "credentials" | "region" | "bucket" | "dangerouslyConnectToHttpEndpointForTesting">

CompositeIdentifier

CompositeIdentifier: IdentifierBrand<object, "CompositeIdentifier">

ConditionProducer

ConditionProducer: function

Type declaration

    • (...args: A): A["length"] extends keyof Lookup<T> ? Lookup<T>[A["length"]] : never
    • Parameters

      • Rest ...args: A

      Returns A["length"] extends keyof Lookup<T> ? Lookup<T>[A["length"]] : never

Config

Config: object

Type declaration

  • [key: string]: string | number

ConflictHandler

ConflictHandler: function

Type declaration

ConnectionStatus

ConnectionStatus: object

Type declaration

  • online: boolean

Context

Context: object

Type declaration

  • Optional req?: any

ControlMessageType

ControlMessageType: object

Type declaration

  • Optional data?: any
  • type: T

Coordinates

Coordinates: [Longitude, Latitude]

CustomIdentifier

CustomIdentifier: CompositeIdentifier<T, [K]>

CustomPrefix

CustomPrefix: object

Type declaration

DailyInAppMessageCounter

DailyInAppMessageCounter: object

Type declaration

  • count: number
  • lastCountTimestamp: string

DataStoreConfig

DataStoreConfig: object

Type declaration

DataStoreSnapshot

DataStoreSnapshot: object

Type declaration

  • isSynced: boolean
  • items: T[]

DeepWritable

DeepWritable: object

Type declaration

DefaultPersistentModelMetaData

DefaultPersistentModelMetaData: object

Type declaration

DeferredCallbackResolverOptions

DeferredCallbackResolverOptions: object

Type declaration

  • callback: function
      • (): void
      • Returns void

  • Optional errorHandler?: function
      • (error: string): void
      • Parameters

        • error: string

        Returns void

  • Optional maxInterval?: number

Private DelayFunction

DelayFunction: function

Type declaration

    • (attempt: number, args?: any[], error?: Error): number | false
    • Parameters

      • attempt: number
      • Optional args: any[]
      • Optional error: Error

      Returns number | false

DeleteGeofencesResults

DeleteGeofencesResults: object

Type declaration

EndpointBuffer

EndpointBuffer: Array<EventObject>

EndpointFailureData

EndpointFailureData: object

Type declaration

  • endpointObject: EventObject
  • err: any
  • update_params: any

EnumFieldType

EnumFieldType: object

Type declaration

  • enum: string

EqualityOperators

EqualityOperators: object

Type declaration

  • eq: T
  • ne: T

ErrorHandler

ErrorHandler: function

Type declaration

ErrorMap

ErrorMap: Partial<object>

ErrorType

ErrorType: "ConfigError" | "BadModel" | "BadRecord" | "Unauthorized" | "Transient" | "Unknown"

ErrorWithResponse

ErrorWithResponse: object

Type declaration

  • response: object & object

Event

Event: object

Type declaration

  • attributes: string
  • eventId: string
  • immediate: boolean
  • metrics: string
  • name: string
  • session: object

EventBuffer

EventBuffer: Array<EventMap>

EventConfig

EventConfig: object

Type declaration

  • appId: string
  • endpointId: string
  • region: string
  • resendLimit: number

EventMap

EventMap: object

Type declaration

EventObject

EventObject: object

Type declaration

EventParams

EventParams: object

Type declaration

  • config: EventConfig
  • credentials: object
  • event: Event
  • resendLimit: number
  • timestamp: string

EventsBufferConfig

EventsBufferConfig: object

Type declaration

  • bufferSize: number
  • flushInterval: number
  • flushSize: number
  • resendLimit: number

FeatureType

FeatureType: "TABLES" | "FORMS" | string

FeatureTypes

FeatureTypes: FeatureType[]

FederatedSignInOptions

FederatedSignInOptions: object

Type declaration

FederatedSignInOptionsCustom

FederatedSignInOptionsCustom: object

Type declaration

  • customProvider: string
  • Optional customState?: string

FieldAssociation

FieldAssociation: object

Type declaration

  • connectionType: "HAS_ONE" | "BELONGS_TO" | "HAS_MANY"

Geofence

Geofence: GeofenceBase & object

GeofenceBase

GeofenceBase: object

Type declaration

  • Optional createTime?: Date
  • geofenceId: GeofenceId
  • Optional updateTime?: Date

GeofenceError

GeofenceError: object

Type declaration

  • error: object
    • code: string
    • message: string
  • geofenceId: GeofenceId

GeofenceId

GeofenceId: string

GeofenceInput

GeofenceInput: object

Type declaration

GeofenceOptions

GeofenceOptions: object

Type declaration

  • Optional providerName?: string

GeofencePolygon

GeofencePolygon: LinearRing[]

GraphQLCondition

GraphQLCondition: Partial<GraphQLField | object>

GraphQLField

GraphQLField: object

Type declaration

  • [field: string]: object
    • [operator: string]: string | number | [number, number]

GraphQLFilter

GraphQLFilter: Partial<GraphQLField | object | object | object>

GraphQLOperation

GraphQLOperation: Source | string

GraphQLSource or string, the type of the parameter for calling graphql.parse

see:

https://graphql.org/graphql-js/language/#parse

GraphQLQuery

GraphQLQuery: T & object

GraphQLSubscription

GraphQLSubscription: T & object

GraphqlAuthModes

GraphqlAuthModes: keyof typeof GRAPHQL_AUTH_MODE

GroupOperator

GroupOperator: "and" | "or" | "not"

HubCallback

HubCallback: function

Type declaration

HubCapsule

HubCapsule: object

Type declaration

  • channel: string
  • Optional patternInfo?: string[]
  • payload: HubPayload
  • source: string

HubPayload

HubPayload: object

Type declaration

  • Optional data?: any
  • event: string
  • Optional message?: string

Identifier

Identifier: ManagedIdentifier<T, any> | OptionallyManagedIdentifier<T, any> | CompositeIdentifier<T, any> | CustomIdentifier<T, any>

IdentifierBrand

IdentifierBrand: T & object

IdentifierFieldOrIdentifierObject

IdentifierFieldOrIdentifierObject: Pick<T, IdentifierFields<T, M>> | IdentifierFieldValue<T, M>

IdentifierFieldValue

IdentifierFieldValue: MetadataOrDefault<T, M>["identifier"] extends CompositeIdentifier<T, any> ? MetadataOrDefault<T, M>["identifier"]["fields"] extends [any] ? T[MetadataOrDefault<T, M>["identifier"]["fields"][0]] : never : T[MetadataOrDefault<T, M>["identifier"]["field"]]

IdentifierFields

IdentifierFields: string

IdentifierFieldsForInit

IdentifierFieldsForInit: MetadataOrDefault<T, M>["identifier"] extends DefaultPersistentModelMetaData | ManagedIdentifier<T, any> ? never : MetadataOrDefault<T, M>["identifier"] extends OptionallyManagedIdentifier<T, any> ? IdentifierFields<T, M> : MetadataOrDefault<T, M>["identifier"] extends CompositeIdentifier<T, any> ? IdentifierFields<T, M> : never

IdentifySource

ImageBlob

ImageBlob: Buffer | Uint8Array | Blob | string

InAppMessageAction

InAppMessageAction: "CLOSE" | "DEEP_LINK" | "LINK"

InAppMessageConflictHandler

InAppMessageConflictHandler: function

Type declaration

InAppMessageCountMap

InAppMessageCountMap: Record<string, number>

InAppMessageCounts

InAppMessageCounts: object

Type declaration

  • dailyCount: number
  • sessionCount: number
  • totalCount: number

InAppMessageLayout

InAppMessageLayout: "BOTTOM_BANNER" | "CAROUSEL" | "FULL_SCREEN" | "MIDDLE_BANNER" | "MODAL" | "TOP_BANNER"

InAppMessageTextAlign

InAppMessageTextAlign: "center" | "left" | "right"

InAppMessagingEvent

InAppMessagingEvent: object

Type declaration

  • Optional attributes?: Record<string, string>
  • Optional metrics?: Record<string, number>
  • name: string

IndexOptions

IndexOptions: object

Type declaration

  • Optional unique?: boolean

IndexesType

IndexesType: Array<[string, string[], object]>

InteractionsMessage

InteractionsResponse

InteractionsResponse: object

Type declaration

  • [key: string]: any

InteractionsTextMessage

InteractionsTextMessage: object

Type declaration

  • content: string
  • options: object
    • messageType: "text"

InteractionsVoiceMessage

InteractionsVoiceMessage: object

Type declaration

  • content: object
  • options: object
    • messageType: "voice"

InternalSchema

InternalSchema: object

Type declaration

InternalSubscriptionMessage

InternalSubscriptionMessage: object

Type declaration

JobEntry

JobEntry: object

Completely internal to BackgroundProcessManager, and describes the structure of an entry in the jobs registry.

Type declaration

  • Optional description?: string

    An object provided by the caller that can be used to identify the description of the job, which can otherwise be unclear from the promise and terminate function. The description can be a string. (May be extended later to also support object refs.)

    Useful for troubleshooting why a manager is waiting for long periods of time on close().

  • promise: Promise<any>

    The underlying promise provided by the job function to wait for.

  • terminate: function

    Request the termination of the job.

      • (): void
      • Returns void

KeyType

KeyType: object

Type declaration

  • Optional compositeKeys?: Set<string>[]
  • Optional primaryKey?: string[]

KeysOfSuperType

KeysOfSuperType: object[keyof T]

KeysOfType

KeysOfType: object[keyof T]

Last

Last: T[Exclude<keyof T, keyof Tail<T>>]

LastParameter

LastParameter: Last<Parameters<F>>

Latitude

Latitude: number

LegacyCallback

LegacyCallback: object

Type declaration

LegacyProvider

LegacyProvider: "google" | "facebook" | "amazon" | "developer" | string

LinearRing

LinearRing: Coordinates[]

LinkedConnectionState

LinkedConnectionState: "connected" | "disconnected"

LinkedConnectionStates

LinkedConnectionStates: object

Type declaration

LinkedHealthState

LinkedHealthState: "healthy" | "unhealthy"

ListGeofenceOptions

ListGeofenceOptions: GeofenceOptions & object

ListGeofenceResults

ListGeofenceResults: object

Type declaration

  • entries: Geofence[]
  • nextToken: string | undefined

ListObjectsCommandOutputContent

ListObjectsCommandOutputContent: _Object

Longitude

Longitude: number

Lookup

Lookup: object

Type declaration

ManagedIdentifier

ManagedIdentifier: IdentifierBrand<object, "ManagedIdentifier">

MapEntry

MapEntry: [string, RegExp, string]

MapTypeToOperands

MapTypeToOperands: object

Type declaration

MatchableTypes

MatchableTypes: string | string[] | number | number[] | boolean | boolean[]

MetadataOrDefault

MetadataOrDefault: T extends object ? T[typeof __modelMeta__] : DefaultPersistentModelMetaData

MetadataReadOnlyFields

MetadataReadOnlyFields: Extract<MetadataOrDefault<T, M>["readOnlyFields"] | M["readOnlyFields"], keyof T>

MetricsComparator

MetricsComparator: function

Type declaration

    • (metricsVal: number, eventVal: number): boolean
    • Parameters

      • metricsVal: number
      • eventVal: number

      Returns boolean

ModelAssociation

ModelAttribute

ModelAttribute: object

Type declaration

  • Optional properties?: Record<string, any>
  • type: string

ModelAttributeAuth

ModelAttributeAuth: object

Type declaration

ModelAttributeAuthProperty

ModelAttributeAuthProperty: object

Type declaration

ModelAttributeCompositeKey

ModelAttributeCompositeKey: object

Type declaration

  • properties: object
    • fields: [string, string, string, string, string]
    • name: string
  • type: "key"

ModelAttributeKey

ModelAttributeKey: object

Type declaration

  • properties: object
    • fields: string[]
    • Optional name?: string
  • type: "key"

ModelAttributePrimaryKey

ModelAttributePrimaryKey: object

Type declaration

  • properties: object
    • fields: string[]
    • name: never
  • type: "key"

ModelAttributes

ModelAttributes: ModelAttribute[]

ModelAuthModes

ModelAuthModes: Record<string, object>

ModelAuthRule

ModelAuthRule: object

Type declaration

  • allow: string
  • Optional groupClaim?: string
  • Optional groups?: string[]
  • Optional groupsField?: string
  • Optional identityClaim?: string
  • Optional operations?: string[]
  • Optional ownerField?: string
  • Optional provider?: string

ModelField

ModelField: object

Type declaration

ModelFieldType

ModelFieldType: object

Type declaration

ModelFields

ModelFields: Record<string, ModelField>

ModelInit

ModelInit: object & object

ModelInitBase

ModelInitBase: Omit<T, typeof __modelMeta__ | IdentifierFields<T, M> | MetadataReadOnlyFields<T, M>>

ModelInstanceCreator

ModelInstanceCreator: typeof modelInstanceCreator

Constructs a model and records it with its metadata in a weakset. Allows for the separate storage of core model fields and Amplify/DataStore metadata fields that the customer app does not want exposed.

param

The model constructor.

param

Init data that would normally be passed to the constructor.

returns

The initialized model.

ModelInstanceMetadata

ModelInstanceMetadata: object

Type declaration

  • _deleted: boolean
  • _lastChangedAt: number
  • _version: number

ModelInstanceMetadataWithId

ModelInstanceMetadataWithId: ModelInstanceMetadata & object

ModelKeys

ModelKeys: object

Type declaration

ModelMeta

ModelMeta: object

Type declaration

ModelPredicate

ModelPredicate: object & PredicateGroups<M>

ModelPredicateAggregateExtender

ModelPredicateAggregateExtender: function

Type declaration

ModelPredicateExtender

ModelPredicateExtender: function

A function that accepts a ModelPrecicate, which it must use to return a final condition.

This is used as predicates in DataStore.save(), DataStore.delete(), and DataStore sync expressions.

DataStore.save(record, model => model.field.eq('some value'))

Logical operators are supported. But, condtiions are related records are NOT supported. E.g.,

DataStore.delete(record, model => model.or(m => [
    m.field.eq('whatever'),
    m.field.eq('whatever else')
]))

Type declaration

ModelPredicateNegation

ModelPredicateNegation: function

Type declaration

ModelPredicateOperator

ModelPredicateOperator: function

Type declaration

MutableModel

MutableModel: DeepWritable<Omit<T, IdentifierFields<T, M> | MetadataReadOnlyFields<T, M>>> & Readonly<Pick<T, IdentifierFields<T, M> | MetadataReadOnlyFields<T, M>>>

MutationProcessorEvent

MutationProcessorEvent: object

Type declaration

NELatitude

NELatitude: Latitude

NELongitude

NELongitude: Longitude

NamespaceResolver

NamespaceResolver: function

Type declaration

NetworkStatus

NetworkStatus: object

Type declaration

  • online: boolean

NonModelFieldType

NonModelFieldType: object

Type declaration

  • nonModel: string

NonModelTypeConstructor

NonModelTypeConstructor: object

Type declaration

NonNeverKeys

NonNeverKeys: object[keyof T]

NotificationsCategory

NotificationsCategory: "Notifications"

NotificationsSubcategory

NotificationsSubcategory: "InAppMessaging"

NumberOperators

NumberOperators: ScalarNumberOperators<T> & object

OAuthOpts

ObserveQueryOptions

ObserveQueryOptions: Pick<ProducerPaginationInput<T>, "sort">

ObserverQuery

ObserverQuery: object

Type declaration

  • observer: SubscriptionObserver<any>
  • query: string
  • Optional startAckTimeoutId?: ReturnType<typeof setTimeout>
  • Optional subscriptionFailedCallback?: Function
  • Optional subscriptionReadyCallback?: Function
  • subscriptionState: SUBSCRIPTION_STATUS
  • variables: object

OmitOptionalFields

OmitOptionalFields: Omit<T, KeysOfSuperType<T, undefined> | OptionalRelativesOf<T>>

OmitOptionalRelatives

OmitOptionalRelatives: Omit<T, OptionalRelativesOf<T>>

OnMessageInteractionEventHandler

OnMessageInteractionEventHandler: function

Type declaration

Option

Option: Option0 | Option1<T>

Option0

Option0: []

Option1

Option1: [V5ModelPredicate<T> | undefined]

OptionalRelativesOf

OptionalRelativesOf: KeysOfType<T, AsyncCollection<any>> | KeysOfSuperType<T, Promise<undefined>>

OptionallyManagedIdentifier

OptionallyManagedIdentifier: IdentifierBrand<object, "OptionallyManagedIdentifier">

PaginationInput

PaginationInput: object

Type declaration

  • Optional limit?: number
  • Optional page?: number
  • Optional sort?: SortPredicate<T>

ParameterizedStatement

ParameterizedStatement: [string, any[]]

PersistentModel

PersistentModel: Readonly<Record<string, any>>

PersistentModelConstructor

PersistentModelConstructor: object

Type declaration

PersistentModelMetaData

PersistentModelMetaData: object

Type declaration

  • Optional identifier?: Identifier<T>
  • Optional readOnlyFields?: string

PickOptionalFields

PickOptionalFields: Pick<T, KeysOfSuperType<T, undefined> | OptionalRelativesOf<T>>

PickOptionalRelatives

PickOptionalRelatives: Pick<T, OptionalRelativesOf<T>>

PickProviderOutput

PickProviderOutput: T extends StorageProvider ? T["getProviderName"] extends "AWSS3" ? DefaultOutput : T extends StorageProviderWithCopy ? ReturnType<T[api]> : ReturnType<T[Exclude<api, "copy">]> : T extends object ? T extends object ? DefaultOutput : Promise<any> : DefaultOutput

Utility type for checking if the generic type is a provider or a Record that has the key 'provider'. If it's a provider, check if it's the S3 Provider, use the default type else use the generic's 'get' method return type. If it's a Record, check if provider is 'AWSS3', use the default type else use any.

PlaceGeometry

PlaceGeometry: object

Type declaration

Polygon

Polygon: Array<Point> | Iterable<Point>

PolygonGeometry

PolygonGeometry: object

Type declaration

PredicateExpression

PredicateExpression: TypeName<FT> extends keyof MapTypeToOperands<FT> ? function : never

PredicateFieldType

PredicateFieldType: NonNullable<Scalar<T extends Promise<infer InnerPromiseType> ? InnerPromiseType : T extends AsyncCollection<infer InnerCollectionType> ? InnerCollectionType : T>>

PredicateGroups

PredicateGroups: object

Type declaration

PredicateObject

PredicateObject: object

Type declaration

  • field: keyof T
  • operand: any
  • operator: keyof AllOperators

PredicatesGroup

PredicatesGroup: object

Type declaration

ProducerModelPredicate

ProducerModelPredicate: function

Type declaration

ProducerPaginationInput

ProducerPaginationInput: object

Type declaration

ProducerSortPredicate

ProducerSortPredicate: function

Type declaration

Properties

Properties: object

Type declaration

  • [key: string]: any

PutEventsResponse

PutEventsResponse: object

Type declaration

  • EventsResponse: object
    • Optional Results?: object
      • [endpointId: string]: object
        • Optional EventsItemResponse?: object
          • [eventId: string]: object
            • Optional Message?: string
            • Optional StatusCode?: number

PutResult

PutResult: object

Type declaration

  • key: string

RecursiveModelPredicate

RecursiveModelPredicate: object & object & PredicateInternalsKey

RecursiveModelPredicateAggregateExtender

RecursiveModelPredicateAggregateExtender: function

Type declaration

RecursiveModelPredicateExtender

RecursiveModelPredicateExtender: function

A function that accepts a RecursiveModelPrecicate, which it must use to return a final condition.

This is used in DataStore.query(), DataStore.observe(), and DataStore.observeQuery() as the second argument. E.g.,

DataStore.query(MyModel, model => model.field.eq('some value'))

More complex queries should also be supported. E.g.,

DataStore.query(MyModel, model => model.and(m => [
  m.relatedEntity.or(relative => [
    relative.relativeField.eq('whatever'),
    relative.relativeField.eq('whatever else')
  ]),
  m.myModelField.ne('something')
]))

Type declaration

RecursiveModelPredicateNegation

RecursiveModelPredicateNegation: function

Type declaration

RecursiveModelPredicateOperator

RecursiveModelPredicateOperator: function

RelationType

RelationType: object

Type declaration

  • Optional associatedWith?: string | string[]
  • fieldName: string
  • modelName: string
  • relationType: "HAS_ONE" | "HAS_MANY" | "BELONGS_TO"
  • Optional targetName?: string
  • Optional targetNames?: string[]

RelationshipType

RelationshipType: object

Type declaration

ResumableUploadConfig

ResumableUploadConfig: object

Type declaration

S3Bucket

S3Bucket: string

S3ClientOptions

S3ClientOptions: StorageOptions & object & S3ProviderListConfig

S3CopyDestination

S3CopyDestination: Omit<S3CopyTarget, "identityId">

S3CopySource

S3CopySource: S3CopyTarget

S3ObjectName

S3ObjectName: string

S3ObjectVersion

S3ObjectVersion: string

S3ProviderCopyConfig

S3ProviderCopyConfig: Omit<CommonStorageOptions, "level"> & object

S3ProviderCopyOutput

S3ProviderCopyOutput: object

Type declaration

  • key: string

S3ProviderGetConfig

S3ProviderGetConfig: CommonStorageOptions & object

S3ProviderGetOuput

S3ProviderGetOuput: T extends object ? GetObjectCommandOutput : string

S3ProviderListConfig

S3ProviderListConfig: CommonStorageOptions & object

S3ProviderListOutput

S3ProviderListOutput: object

Type declaration

S3ProviderPutConfig

S3ProviderPutConfig: CommonStorageOptions & object | object & object

S3ProviderPutOutput

S3ProviderPutOutput: T extends object ? UploadTask : Promise<PutResult>

S3ProviderRemoveConfig

S3ProviderRemoveConfig: CommonStorageOptions & object

S3ProviderRemoveOutput

S3ProviderRemoveOutput: DeleteObjectCommandOutput

SWLatitude

SWLatitude: Latitude

SWLongitude

SWLongitude: Longitude

SaveGeofencesResults

SaveGeofencesResults: object

Type declaration

Scalar

Scalar: T extends Array<infer InnerType> ? InnerType : T

ScalarNumberOperators

ScalarNumberOperators: EqualityOperators<T> & object

Schema

Schema: UserSchema & object

SchemaEnum

SchemaEnum: object

Type declaration

  • name: string
  • values: string[]

SchemaEnums

SchemaEnums: Record<string, SchemaEnum>

SchemaModel

SchemaModel: object

Type declaration

SchemaModels

SchemaModels: Record<string, SchemaModel>

SchemaNamespace

SchemaNamespace: UserSchema & object

SchemaNamespaces

SchemaNamespaces: Record<string, SchemaNamespace>

SchemaNonModel

SchemaNonModel: object

Type declaration

SchemaNonModels

SchemaNonModels: Record<string, SchemaNonModel>

SearchByCoordinatesOptions

SearchByCoordinatesOptions: object

Type declaration

  • Optional maxResults?: number
  • Optional providerName?: string
  • Optional searchIndexName?: string

SearchByTextOptions

SearchForSuggestionsResult

SearchForSuggestionsResult: object

Type declaration

  • Optional placeId?: string
  • text: string

SearchForSuggestionsResults

SearchForSuggestionsResults: SearchForSuggestionsResult[]

SessionState

SessionState: "started" | "ended"

SessionStateChangeHandler

SessionStateChangeHandler: function

Type declaration

SettableFieldType

SettableFieldType: T extends Promise<infer InnerPromiseType> ? undefined extends InnerPromiseType ? InnerPromiseType | null : InnerPromiseType : T extends AsyncCollection<infer InnerCollectionType> ? InnerCollectionType[] | undefined : undefined extends T ? T | null : T

SettingMetaData

SettingMetaData: object

Type declaration

SignInOpts

SortPredicate

SortPredicate: object

Type declaration

SortPredicateExpression

SortPredicateExpression: TypeName<FT> extends keyof MapTypeToOperands<FT> ? function : never

SortPredicateObject

SortPredicateObject: object

Type declaration

  • field: keyof T
  • sortDirection: keyof typeof SortDirection

SortPredicatesGroup

SortPredicatesGroup: SortPredicateObject<T>[]

StartParams

StartParams: object

Type declaration

  • fullSyncInterval: number

StorageAccessLevel

StorageAccessLevel: "public" | "protected" | "private"

StorageCopyConfig

StorageCopyConfig: T extends StorageProviderWithCopy ? StorageOperationConfig<T, "copy"> : StorageOperationConfigMap<StorageOperationConfig<AWSS3Provider, "copy">, T>

StorageCopyDestination

StorageCopyDestination: Omit<StorageCopyTarget, "identityId">

StorageCopyOutput

StorageCopyOutput: PickProviderOutput<Promise<S3ProviderCopyOutput>, T, "copy">

StorageCopySource

StorageCopySource: StorageCopyTarget

StorageCopyTarget

StorageCopyTarget: object

Type declaration

  • Optional identityId?: string
  • key: string
  • Optional level?: string

StorageFacade

StorageFacade: Omit<Adapter, "setUp">

StorageGetConfig

StorageGetConfig: T extends StorageProvider ? StorageOperationConfig<T, "get"> : StorageOperationConfigMap<StorageOperationConfig<AWSS3Provider, "get">, T>

StorageGetOutput

StorageGetOutput: PickProviderOutput<Promise<S3ProviderGetOuput<T>>, T, "get">

StorageListConfig

StorageListConfig: T extends StorageProvider ? StorageOperationConfig<T, "list"> : StorageOperationConfigMap<StorageOperationConfig<AWSS3Provider, "list">, T>

StorageListOutput

StorageListOutput: PickProviderOutput<Promise<S3ProviderListOutput>, T, "list">

StorageOperationConfig

StorageOperationConfig: ReturnType<T["getProviderName"]> extends "AWSS3" ? LastParameter<AWSS3Provider[U]> : T extends StorageProviderWithCopy ? LastParameter<T[U]> & object : LastParameter<T[Exclude<U, "copy">]> & object

If provider is AWSS3, provider doesn't have to be specified since it's the default, else it has to be passed into config.

StorageOperationConfigMap

StorageOperationConfigMap: T extends object ? T extends object ? Default : T & object : Default

Utility type to allow custom provider to use any config keys, if provider is set to AWSS3 then it should use AWSS3Provider's config.

StorageProviderApi

StorageProviderApi: "copy" | "get" | "put" | "remove" | "list"

StoragePutConfig

StoragePutConfig: T extends StorageProvider ? StorageOperationConfig<T, "put"> : StorageOperationConfigMap<StorageOperationConfig<AWSS3Provider, "put">, T>

StoragePutOutput

StoragePutOutput: PickProviderOutput<S3ProviderPutOutput<T>, T, "put">

StorageRemoveConfig

StorageRemoveConfig: T extends StorageProvider ? StorageOperationConfig<T, "remove"> : StorageOperationConfigMap<StorageOperationConfig<AWSS3Provider, "remove">, T>

StorageRemoveOutput

StorageRemoveOutput: PickProviderOutput<Promise<S3ProviderRemoveOutput>, T, "remove">

StorageSubscriptionMessage

StorageSubscriptionMessage: InternalSubscriptionMessage<T> & object

Store

Store: Record<string, string>

StringOperators

StringOperators: ScalarNumberOperators<T> & object

SubscriptionMessage

SubscriptionMessage: Pick<InternalSubscriptionMessage<T>, "opType" | "element" | "model" | "condition">

SumerianSceneOptions

SumerianSceneOptions: SceneOptions & object

SyncConflict

SyncConflict: object

Type declaration

SyncError

SyncError: object

Type declaration

  • Optional cause?: Error
  • Optional errorInfo?: string
  • errorType: ErrorType
  • localModel: T
  • message: string
  • Optional model?: string
  • operation: string
  • process: ProcessName
  • Optional recoverySuggestion?: string
  • remoteModel: T

SyncExpression

SyncExpression: Promise<object>

SyncModelPage

SyncModelPage: object

Type declaration

SystemComponent

SystemComponent: object

Type declaration

Tail

Tail: function extends function ? R : never

TargetNameAssociation

TargetNameAssociation: object

Type declaration

  • connectionType: "BELONGS_TO"
  • Optional targetName?: string
  • Optional targetNames?: string[]

TextDetectionList

TextDetectionList: TextDetection[]

TrackerTypes

TrackerTypes: keyof typeof trackers

Trackers

Trackers: typeof trackers[TrackerTypes]

TypeConstructorMap

TypeConstructorMap: Record<string, PersistentModelConstructor<any> | NonModelTypeConstructor<unknown>>

TypeName

TypeName: T extends string ? "string" : T extends number ? "number" : T extends boolean ? "boolean" : T extends string[] ? "string[]" : T extends number[] ? "number[]" : T extends boolean[] ? "boolean[]" : never

UntypedCondition

UntypedCondition: object

Type declaration

UserInfo

UserInfo: object

Type declaration

  • Optional attributes?: Record<string, string[]>
  • Optional demographic?: object
    • Optional appVersion?: string
    • Optional locale?: string
    • Optional make?: string
    • Optional model?: string
    • Optional modelVersion?: string
    • Optional platform?: string
    • Optional platformVersion?: string
    • Optional timezone?: string
  • Optional location?: object
    • Optional city?: string
    • Optional country?: string
    • Optional latitude?: number
    • Optional longitude?: number
    • Optional postalCode?: string
    • Optional region?: string
  • Optional metrics?: Record<string, number>

UserSchema

UserSchema: object

Type declaration

UsernamePasswordOpts

UsernamePasswordOpts: object

Type declaration

  • password: string
  • username: string
  • Optional validationData?: object
    • [key: string]: any

V5ModelPredicate

V5ModelPredicate: WithoutNevers<object> & object & PredicateInternalsKey

ValuePredicate

ValuePredicate: object

Type declaration

WithoutNevers

WithoutNevers: Pick<T, NonNeverKeys<T>>

_S3ProviderPutConfig

_S3ProviderPutConfig: object

Type declaration

  • Optional SSECustomerAlgorithm?: PutObjectRequest["SSECustomerAlgorithm"]
  • Optional SSECustomerKey?: PutObjectRequest["SSECustomerKey"]
  • Optional SSECustomerKeyMD5?: PutObjectRequest["SSECustomerKeyMD5"]
  • Optional SSEKMSKeyId?: PutObjectRequest["SSEKMSKeyId"]
  • Optional acl?: PutObjectRequest["ACL"]
  • Optional bucket?: PutObjectRequest["Bucket"]
  • Optional cacheControl?: PutObjectRequest["CacheControl"]
  • Optional contentDisposition?: PutObjectRequest["ContentDisposition"]
  • Optional contentEncoding?: PutObjectRequest["ContentEncoding"]
  • Optional contentType?: PutObjectRequest["ContentType"]
  • Optional expires?: PutObjectRequest["Expires"]
  • Optional metadata?: PutObjectRequest["Metadata"]
  • Optional progressCallback?: function
      • (progress: any): any
      • Parameters

        • progress: any

        Returns any

  • Optional provider?: "AWSS3"
  • Optional resumable?: boolean
  • Optional serverSideEncryption?: PutObjectRequest["ServerSideEncryption"]
  • Optional tagging?: PutObjectRequest["Tagging"]
  • Optional track?: boolean
  • Optional useAccelerateEndpoint?: boolean

lexV2BaseReqParams

lexV2BaseReqParams: object

Type declaration

  • botAliasId: string
  • botId: string
  • localeId: string
  • sessionId: string

searchByPlaceIdOptions

searchByPlaceIdOptions: object

Type declaration

  • Optional searchIndexName?: string

Variables

Const ACCEPTED_CODES

ACCEPTED_CODES: number[] = [202]

Const AMPLIFY_SYMBOL

AMPLIFY_SYMBOL: Symbol = (typeof Symbol !== 'undefined' &&typeof Symbol.for === 'function'? Symbol.for('amplify_default'): '@@amplify_default') as Symbol

Const API

API: APIClass = new APIClass(null)

Const AWS_CLOUDWATCH_BASE_BUFFER_SIZE

AWS_CLOUDWATCH_BASE_BUFFER_SIZE: 26 = 26

Const AWS_CLOUDWATCH_CATEGORY

AWS_CLOUDWATCH_CATEGORY: "Logging" = "Logging"

Const AWS_CLOUDWATCH_MAX_BATCH_EVENT_SIZE

AWS_CLOUDWATCH_MAX_BATCH_EVENT_SIZE: 1048576 = 1048576

Const AWS_CLOUDWATCH_MAX_EVENT_SIZE

AWS_CLOUDWATCH_MAX_EVENT_SIZE: 256000 = 256000

Const AWS_CLOUDWATCH_PROVIDER_NAME

AWS_CLOUDWATCH_PROVIDER_NAME: "AWSCloudWatch" = "AWSCloudWatch"

Const Analytics

Analytics: AnalyticsClass = new AnalyticsClass()

Const AsyncStorage

AsyncStorage: any = browserOrNode().isBrowser? new StorageHelper().getStorage(): undefined

Const Auth

Auth: AuthClass = new AuthClass(null)

Const BASE_USER_AGENT

BASE_USER_AGENT: string = `aws-amplify/${version}`

Const BEACON_SUPPORTED

BEACON_SUPPORTED: boolean = typeof navigator !== 'undefined' &&navigator &&typeof navigator.sendBeacon === 'function'

Const BUFFER_SIZE

BUFFER_SIZE: 1000 = 1000

Const BrowserStorageCache

BrowserStorageCache: ICache = new BrowserStorageCacheClass()

Buffer

Buffer: any = require('buffer/').Buffer

Const CACHE_EXPIRY_IN_DAYS

CACHE_EXPIRY_IN_DAYS: 7 = 7

Const COGNITO_IDENTITY_KEY_PREFIX

COGNITO_IDENTITY_KEY_PREFIX: "CognitoIdentityId-" = "CognitoIdentityId-"

Const COLLECTION

COLLECTION: "Collection" = "Collection"

Const CONNECTION_INIT_TIMEOUT

CONNECTION_INIT_TIMEOUT: 15000 = 15000

Time in milleseconds to wait for GQL_CONNECTION_INIT message

Const CONNECTION_STATE_CHANGE

CONNECTION_STATE_CHANGE: "ConnectionStateChange" = "ConnectionStateChange"

Const CREDENTIALS_TTL

CREDENTIALS_TTL: number = 50 * 60 * 1000

Const Credentials

Credentials: CredentialsClass = new CredentialsClass(null)

Const DATA

DATA: "Data" = "Data"

Const DATASTORE

DATASTORE: DATASTORE = NAMESPACES.DATASTORE

Const DB_NAME

DB_NAME: "@AmplifyDatastore" = "@AmplifyDatastore"

Const DEFAULT_ALGORITHM

DEFAULT_ALGORITHM: "AWS4-HMAC-SHA256" = "AWS4-HMAC-SHA256"

Const DEFAULT_CACHE_PREFIX

DEFAULT_CACHE_PREFIX: "peronslize" = "peronslize"

Const DEFAULT_KEEP_ALIVE_ALERT_TIMEOUT

DEFAULT_KEEP_ALIVE_ALERT_TIMEOUT: number = 65 * 1000

Default Time in milleseconds to alert for missed GQL_CONNECTION_KEEP_ALIVE message

Const DEFAULT_KEEP_ALIVE_TIMEOUT

DEFAULT_KEEP_ALIVE_TIMEOUT: number = 5 * 60 * 1000

Default Time in milleseconds to wait for GQL_CONNECTION_KEEP_ALIVE message

Const DEFAULT_PORT

DEFAULT_PORT: RegExp = RegExp(':(' + HTTP_PORT + '|' + HTTPS_PORT + ')$')

Const DEFAULT_PRESIGN_EXPIRATION

DEFAULT_PRESIGN_EXPIRATION: 900 = 900

Const DEFAULT_PRIMARY_KEY_VALUE_SEPARATOR

DEFAULT_PRIMARY_KEY_VALUE_SEPARATOR: "#" = "#"

Used by the Async Storage Adapter to concatenate key values for a record. For instance, if a model has the following keys: customId: ID! @primaryKey(sortKeyFields: ["createdAt"]), we concatenate the customId and createdAt as: 12-234-5#2022-09-28T00:00:00.000Z

Const DEFAULT_PROVIDER

DEFAULT_PROVIDER: "AWSS3" = "AWSS3"

Const DEFAULT_PROVIDER_NAME

DEFAULT_PROVIDER_NAME: "SumerianProvider" = "SumerianProvider"

Const DEFAULT_QUEUE_SIZE

DEFAULT_QUEUE_SIZE: 4 = 4

Const DEFAULT_STORAGE_LEVEL

DEFAULT_STORAGE_LEVEL: "public" = "public"

Const DELIMITER

DELIMITER: "." = "."

Const DELIVERY_TYPE

DELIVERY_TYPE: "IN_APP_MESSAGE" = "IN_APP_MESSAGE"

Const DISCARD

DISCARD: unique symbol = Symbol('DISCARD')

Const EXPIRED_TOKEN_CODE

EXPIRED_TOKEN_CODE: "ExpiredTokenException" = "ExpiredTokenException"

Const ExpoSQLiteAdapter

ExpoSQLiteAdapter: CommonSQLiteAdapter = new CommonSQLiteAdapter(new ExpoSQLiteDatabase())

Const FIVE_MINUTES_IN_MS

FIVE_MINUTES_IN_MS: number = 1000 * 60 * 5

Date & time utility functions to abstract the aws-sdk away from users. (v2 => v3 modularization is a breaking change)

see

https://github.com/aws/aws-sdk-js/blob/6edf586dcc1de7fe8fbfbbd9a0d2b1847921e6e1/lib/util.js#L262

Const FLUSH_INTERVAL

FLUSH_INTERVAL: number = 5 * 1000

Const FLUSH_SIZE

FLUSH_SIZE: 5 = 5

Const FLUSH_SIZE_THRESHHOLD

FLUSH_SIZE_THRESHHOLD: 10 = 10

Const FORBIDDEN_CODE

FORBIDDEN_CODE: 403 = 403

Const Geo

Geo: GeoClass = new GeoClass()

Const GraphQLAPI

GraphQLAPI: GraphQLAPIClass = new GraphQLAPIClass(null)

Const HTTPS_PORT

HTTPS_PORT: "443" = "443"

Const HTTP_PORT

HTTP_PORT: "80" = "80"

Const Hub

Hub: HubClass = new HubClass('__default__')

Const ID

ID: "id" = "id"

Const IDENTIFIER_KEY_SEPARATOR

IDENTIFIER_KEY_SEPARATOR: "-" = "-"

Used for generating spinal-cased index name from an array of key field names. E.g. for keys [id, title] => 'id-title'

Const IDENTIFY_EVENT

IDENTIFY_EVENT: "Identify" = "Identify"

Const INTERNAL_AWS_APPSYNC_PUBSUB_PROVIDER

INTERNAL_AWS_APPSYNC_PUBSUB_PROVIDER: symbol | "@@INTERNAL_AWS_APPSYNC_PUBSUB_PROVIDER" = hasSymbol? Symbol.for('INTERNAL_AWS_APPSYNC_PUBSUB_PROVIDER'): '@@INTERNAL_AWS_APPSYNC_PUBSUB_PROVIDER'
deprecated

Unused, all usecases have migrated to INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER

Const INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER

INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER: symbol | "@@INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER" = hasSymbol? Symbol.for('INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER'): '@@INTERNAL_AWS_APPSYNC_REALTIME_PUBSUB_PROVIDER'

Const IOT_SERVICE_NAME

IOT_SERVICE_NAME: "iotdevicegateway" = "iotdevicegateway"

Const InMemoryCache

InMemoryCache: ICache = new InMemoryCacheClass()

Const Interactions

Interactions: InteractionsClass = new InteractionsClass()

Const LANGUAGES_CODE_IN_8KHZ

LANGUAGES_CODE_IN_8KHZ: string[] = ['fr-FR', 'en-AU', 'en-GB', 'fr-CA']

Const Linking

Linking: object

Type declaration

Const MAX_ATTEMPTS

MAX_ATTEMPTS: 10 = 10

Const MAX_AUTOSIGNIN_POLLING_MS

MAX_AUTOSIGNIN_POLLING_MS: number = 3 * 60 * 1000

Const MAX_DELAY_MS

MAX_DELAY_MS: 5000 = 5000

Const MAX_DEVICES

MAX_DEVICES: 60 = 60

Const MAX_PARTS

MAX_PARTS: 10000 = 10000

Const MAX_RETRY_DELAY_MS

MAX_RETRY_DELAY_MS: number = 5 * 60 * 1000

Const MEMORY_KEY_PREFIX

MEMORY_KEY_PREFIX: "@MemoryStorage:" = "@MemoryStorage:"

Const MESSAGE_DAILY_COUNT_KEY

MESSAGE_DAILY_COUNT_KEY: "pinpointProvider_inAppMessages_dailyCount" = "pinpointProvider_inAppMessages_dailyCount"

Const MESSAGE_TOTAL_COUNT_KEY

MESSAGE_TOTAL_COUNT_KEY: "pinpointProvider_inAppMessages_totalCount" = "pinpointProvider_inAppMessages_totalCount"

Const MIME_MAP

MIME_MAP: object[] = [{ type: 'text/plain', ext: 'txt' },{ type: 'text/html', ext: 'html' },{ type: 'text/javascript', ext: 'js' },{ type: 'text/css', ext: 'css' },{ type: 'text/csv', ext: 'csv' },{ type: 'text/yaml', ext: 'yml' },{ type: 'text/yaml', ext: 'yaml' },{ type: 'text/calendar', ext: 'ics' },{ type: 'text/calendar', ext: 'ical' },{ type: 'image/apng', ext: 'apng' },{ type: 'image/bmp', ext: 'bmp' },{ type: 'image/gif', ext: 'gif' },{ type: 'image/x-icon', ext: 'ico' },{ type: 'image/x-icon', ext: 'cur' },{ type: 'image/jpeg', ext: 'jpg' },{ type: 'image/jpeg', ext: 'jpeg' },{ type: 'image/jpeg', ext: 'jfif' },{ type: 'image/jpeg', ext: 'pjp' },{ type: 'image/jpeg', ext: 'pjpeg' },{ type: 'image/png', ext: 'png' },{ type: 'image/svg+xml', ext: 'svg' },{ type: 'image/tiff', ext: 'tif' },{ type: 'image/tiff', ext: 'tiff' },{ type: 'image/webp', ext: 'webp' },{ type: 'application/json', ext: 'json' },{ type: 'application/xml', ext: 'xml' },{ type: 'application/x-sh', ext: 'sh' },{ type: 'application/zip', ext: 'zip' },{ type: 'application/x-rar-compressed', ext: 'rar' },{ type: 'application/x-tar', ext: 'tar' },{ type: 'application/x-bzip', ext: 'bz' },{ type: 'application/x-bzip2', ext: 'bz2' },{ type: 'application/pdf', ext: 'pdf' },{ type: 'application/java-archive', ext: 'jar' },{ type: 'application/msword', ext: 'doc' },{ type: 'application/vnd.ms-excel', ext: 'xls' },{ type: 'application/vnd.ms-excel', ext: 'xlsx' },{ type: 'message/rfc822', ext: 'eml' },]

Const MOBILE_SERVICE_NAME

MOBILE_SERVICE_NAME: "mobiletargeting" = "mobiletargeting"

Const MapEntries

MapEntries: MapEntry[] = [['User does not exist', /user.*not.*exist/i],['User already exists', /user.*already.*exist/i],['Incorrect username or password', /incorrect.*username.*password/i],['Invalid password format', /validation.*password/i],['Invalid phone number format',/invalid.*phone/i,'Invalid phone number format. Please use a phone number format of +12345678900',],]

Const NON_RETRYABLE_CODES

NON_RETRYABLE_CODES: number[] = [400, 401, 403]

Const NO_CREDS_ERROR_STRING

NO_CREDS_ERROR_STRING: "No credentials" = "No credentials"

Const Notifications

Notifications: NotificationsClass = new NotificationsClass()

Const OAUTH_FLOW_MS_TIMEOUT

OAUTH_FLOW_MS_TIMEOUT: number = 10 * 1000

OS

OS: any

Const PART_SIZE

PART_SIZE: number = 5 * 1024 * 1024

Const PERSONALIZE_CACHE

PERSONALIZE_CACHE: "_awsct" = "_awsct"

Const PERSONALIZE_CACHE_SESSIONID

PERSONALIZE_CACHE_SESSIONID: "_awsct_sid" = "_awsct_sid"

Const PERSONALIZE_CACHE_USERID

PERSONALIZE_CACHE_USERID: "_awsct_uid" = "_awsct_uid"

Const PREV_URL_KEY

PREV_URL_KEY: "aws-amplify-analytics-prevUrl" = "aws-amplify-analytics-prevUrl"

Const PredicateAll

PredicateAll: unique symbol = Symbol('A predicate that matches all records')

Const Predictions

Predictions: PredictionsClass = new PredictionsClass({})

Const PubSub

PubSub: PubSubClass = new PubSubClass()

Const RECONNECTING_IN

RECONNECTING_IN: 5000 = 5000

Const RECONNECT_DELAY

RECONNECT_DELAY: number = 5 * 1000

Default delay time in milleseconds between when reconnect is triggered vs when it is attempted

Const RECONNECT_INTERVAL

RECONNECT_INTERVAL: number = 60 * 1000

Default interval time in milleseconds between when reconnect is re-attempted

Const REMOTE_NOTIFICATION_OPENED

REMOTE_NOTIFICATION_OPENED: "remoteNotificationOpened" = "remoteNotificationOpened"

Const REMOTE_NOTIFICATION_RECEIVED

REMOTE_NOTIFICATION_RECEIVED: "remoteNotificationReceived" = "remoteNotificationReceived"

Const REMOTE_TOKEN_RECEIVED

REMOTE_TOKEN_RECEIVED: "remoteTokenReceived" = "remoteTokenReceived"

Const RESEND_LIMIT

RESEND_LIMIT: 5 = 5

Const RETRYABLE_CODES

RETRYABLE_CODES: number[] = [429, 500]

Const RETRY_ERROR_CODES

RETRY_ERROR_CODES: string[] = ['ResourceNotFoundException','InvalidSequenceTokenException',]

RNFS

RNFS: any

Const RNPushNotification

RNPushNotification: any = NativeModules.RNPushNotification

Const RestAPI

RestAPI: RestAPIClass = new RestAPIClass(null)

Const SELF

SELF: "_self" = "_self"

Const SEND_DOWNLOAD_PROGRESS_EVENT

SEND_DOWNLOAD_PROGRESS_EVENT: "sendDownloadProgress" = "sendDownloadProgress"

Const SEND_UPLOAD_PROGRESS_EVENT

SEND_UPLOAD_PROGRESS_EVENT: "sendUploadProgress" = "sendUploadProgress"

Const SERVICE_NAME

SERVICE_NAME: "iotdevicegateway" = "iotdevicegateway"

Const SESSION_START

SESSION_START: "_session.start" = "_session.start"

Const SESSION_STOP

SESSION_STOP: "_session.stop" = "_session.stop"

Const SETTING_SCHEMA_VERSION

SETTING_SCHEMA_VERSION: "schemaVersion" = "schemaVersion"

Const SET_CONTENT_LENGTH_HEADER

SET_CONTENT_LENGTH_HEADER: "contentLengthMiddleware" = "contentLengthMiddleware"

Const SQLiteAdapter

SQLiteAdapter: CommonSQLiteAdapter = new CommonSQLiteAdapter(new SQLiteDatabase())

Const START_ACK_TIMEOUT

START_ACK_TIMEOUT: 15000 = 15000

Time in milleseconds to wait for GQL_START_ACK message

Const STORAGE

STORAGE: STORAGE = NAMESPACES.STORAGE

Const STORAGE_KEY_SUFFIX

STORAGE_KEY_SUFFIX: "_inAppMessages" = "_inAppMessages"

Const SUMERIAN_SERVICE_NAME

SUMERIAN_SERVICE_NAME: "sumerian" = "sumerian"

Const SYNC

SYNC: SYNC = NAMESPACES.SYNC

Sound

Sound: any

Const StorageInstance

StorageInstance: Storage = getInstance()

Const TIMER_INTERVAL

TIMER_INTERVAL: number = 30 * 1000

Const UPDATE_ENDPOINT

UPDATE_ENDPOINT: "_update_endpoint" = "_update_endpoint"

Const UPLOADS_STORAGE_KEY

UPLOADS_STORAGE_KEY: "__uploadInProgress" = "__uploadInProgress"

Const USER

USER: USER = NAMESPACES.USER

Const USER_ADMIN_SCOPE

USER_ADMIN_SCOPE: "aws.cognito.signin.user.admin" = "aws.cognito.signin.user.admin"

Const USER_AGENT_HEADER

USER_AGENT_HEADER: "x-amz-user-agent" = "x-amz-user-agent"

Const USER_AGENT_SUFFIX_DATASTORE

USER_AGENT_SUFFIX_DATASTORE: "/DataStore" = "/DataStore"

Voice

Voice: any

Const XR

XR: XRClass = new XRClass(null)

Const __identifierBrand__

__identifierBrand__: keyof symbol

Each identifier type is represented using nominal types, see: https://basarat.gitbook.io/typescript/main-1/nominaltyping

Const __modelMeta__

__modelMeta__: keyof symbol

Let _config

_config: any = null

Let _i18n

_i18n: any = null

Let _instance

_instance: Storage = null

Configure & register Storage singleton instance.

Const a

a: HTMLAnchorElement = browserOrNode().isBrowser ? document.createElement('a') : null

Let analyticsConfigured

analyticsConfigured: boolean = false

Const anyGlobal

anyGlobal: any = global as any

Const attachedModelInstances

attachedModelInstances: WeakMap<object, ModelAttachment> = new WeakMap<PersistentModel, ModelAttachment>()

Tells us which data source a model is attached to (lazy loads from).

If Deatched, the model's lazy properties will only ever return properties from memory provided at construction time.

Let authConfigured

authConfigured: boolean = false

Const buttonColor

buttonColor: "#ff9900" = "#ff9900"

Const cache

cache: object

Type declaration

Const comparisonKeys

comparisonKeys: Set<string> = new Set(['eq','ne','gt','lt','ge','le','contains','notContains','beginsWith','between',])

Let credentialsConfigured

credentialsConfigured: boolean = false

Const customDomainPath

customDomainPath: "/realtime" = "/realtime"

Let dataMemory

dataMemory: object

Type declaration

Let dataStoreClasses

dataStoreClasses: TypeConstructorMap

Const deepSquidInk

deepSquidInk: "#152939" = "#152939"

Const defaultModules

defaultModules: any[] = [API, Auth, DataStore]

Const disabledButtonColor

disabledButtonColor: "#ff990080" = "#ff990080"

Let endpointUpdated

endpointUpdated: boolean = false

Let eventAttributesMemo

eventAttributesMemo: object

Type declaration

Const eventBuilder

eventBuilder: EventStreamMarshaller = new EventStreamMarshaller(toUtf8, fromUtf8)

Let eventMetricsMemo

eventMetricsMemo: object

Type declaration

Let eventNameMemo

eventNameMemo: object

Type declaration

Const getGroupId

getGroupId: (Anonymous function) = (() => {let seed = 1;return () => `group_${seed++}`;})()

Small utility function to generate a monotonically increasing ID. Used by GroupCondition to help keep track of which group is doing what, when, and where during troubleshooting.

Const groupKeys

groupKeys: Set<string> = new Set(['and', 'or', 'not'])

Let handler

handler: any

Const hasSymbol

hasSymbol: boolean = typeof Symbol !== 'undefined' && typeof Symbol.for === 'function'

This Symbol is used to reference an internal-only PubSub provider that is used for AppSync/GraphQL subscriptions in the API category.

Let hidden

hidden: string

Let initialEventSent

initialEventSent: boolean = false

Const instance

instance: DataStore = new DataStore()

Const instancesMetadata

instancesMetadata: WeakSet<object & object> = new WeakSet<ModelInit<any, any>>()

Collection of instantiated models to allow storage of metadata apart from the model visible to the consuming app -- in case the app doesn't have metadata fields (_version, _deleted, etc.) exposed on the model itself.

isBrowser

isBrowser: any

isNode

isNode: any

Const linkUnderlayColor

linkUnderlayColor: "#FFF" = "#FFF"

Const lists

lists: MethodEmbed[] = []

Const localTestingStorageEndpoint

localTestingStorageEndpoint: "http://localhost:20005" = "http://localhost:20005"

Const logger

logger: any = new Logger('XR')

Const loggerStorageInstance

loggerStorageInstance: any = new Logger('Storage')

Const metadataFields

metadataFields: ("_version" | "_lastChangedAt" | "_deleted")[] = <(keyof ModelInstanceMetadata)[]>(Object.keys(dummyMetadata))

Const modelInstanceAssociationsMap

modelInstanceAssociationsMap: WeakMap<object, object> = new WeakMap<PersistentModel, object>()

Maps a model to its related models for memoization/immutability.

Const modelNamespaceMap

modelNamespaceMap: WeakMap<object, string> = new WeakMap<PersistentModelConstructor<any>,string>()

Const modelPatchesMap

modelPatchesMap: WeakMap<object, [Patch[], object]> = new WeakMap<PersistentModel,[Patch[], PersistentModel]>()

Const monotonicFactoriesMap

monotonicFactoriesMap: Map<string, ULID> = new Map<string, ULID>()

Const nativeMatches

nativeMatches: any = proto? proto.matches ||// @ts-ignoreproto.matchesSelector ||// @ts-ignoreproto.webkitMatchesSelector ||// @ts-ignoreproto.mozMatchesSelector ||// @ts-ignoreproto.msMatchesSelector ||// @ts-ignoreproto.oMatchesSelector: null

Const nonModelClasses

nonModelClasses: WeakSet<object> = new WeakSet<NonModelTypeConstructor<any>>()

Const obj

obj: object

Type declaration

  • Optional oauth_state?: string
  • Optional ouath_pkce_key?: string

Const ops

ops: ("beginsWith" | "contains" | "notContains" | "between" | "eq" | "ne" | "le" | "lt" | "ge" | "gt")[] = [...comparisonKeys] as AllFieldOperators[]

Const originalJitteredBackoff

originalJitteredBackoff: any = jitteredBackoff(MAX_RETRY_DELAY_MS)

Const ownSymbol

ownSymbol: unique symbol = Symbol('sync')

Const placeholderColor

placeholderColor: "#C7C7CD" = "#C7C7CD"

Const predicateInternalsMap

predicateInternalsMap: Map<PredicateInternalsKey, GroupCondition> = new Map<PredicateInternalsKey, GroupCondition>()

A map from keys (exposed to customers) to the internal predicate data structures invoking code should not muck with.

Const predicatesAllSet

predicatesAllSet: WeakSet<function> = new WeakSet<ProducerModelPredicate<any>>()

Let privateModeCheckResult

privateModeCheckResult: any

Const proto

proto: Element = browserOrNode().isBrowser && window['Element']? window['Element'].prototype: null

Const queryType

queryType: keyof symbol

Const reactNativeRequestTransformer

reactNativeRequestTransformer: AxiosTransformer[] = [(data: any, headers: AxiosRequestHeaders): any => {if (isBlob(data)) {normalizeHeaders(headers, 'Content-Type');normalizeHeaders(headers, 'Accept');return data;}// Axios' default transformRequest is an arrayreturn axios.defaults.transformRequest[0].call(null, data, headers);},]

Const requiredModules

requiredModules: any[] = [// API cannot function without AuthAuth,// Auth cannot function without CredentialsCredentials,]

Let safariCompatabilityModeResult

safariCompatabilityModeResult: any

Let schema

Const signUpWithEmailFields

signUpWithEmailFields: ISignUpField[] = [{label: 'Email',key: 'email',required: true,placeholder: 'Email',type: 'email',displayOrder: 1,testID: TEST_ID.AUTH.EMAIL_INPUT,},{label: 'Password',key: 'password',required: true,placeholder: 'Password',type: 'password',displayOrder: 2,testID: TEST_ID.AUTH.PASSWORD_INPUT,},{label: 'Phone Number',key: 'phone_number',placeholder: 'Phone Number',required: true,displayOrder: 3,testID: TEST_ID.AUTH.PHONE_INPUT,},]

Const signUpWithPhoneNumberFields

signUpWithPhoneNumberFields: ISignUpField[] = [{label: 'Phone Number',key: 'phone_number',placeholder: 'Phone Number',required: true,displayOrder: 1,testID: TEST_ID.AUTH.PHONE_INPUT,},{label: 'Password',key: 'password',required: true,placeholder: 'Password',type: 'password',displayOrder: 2,testID: TEST_ID.AUTH.PASSWORD_INPUT,},{label: 'Email',key: 'email',required: true,placeholder: 'Email',type: 'email',displayOrder: 3,testID: TEST_ID.AUTH.EMAIL_INPUT,},]

Const standardDomainPattern

standardDomainPattern: RegExp = /^https:\/\/\w{26}\.appsync\-api\.\w{2}(?:(?:\-\w{2,})+)\-\d\.amazonaws.com\/graphql$/i

Let storageClasses

storageClasses: TypeConstructorMap

Let store

store: object

provide an object as the in-memory cache

Type declaration

Let syncClasses

syncClasses: TypeConstructorMap

Let syncSubscription

syncSubscription: