Building a Client App - AWS AppSync

Building a Client App

You can use any HTTP or GraphQL client to connect to a GraphQL API in AWS AppSync.

For front-end web and mobile development, we recommend using the AWS Amplify clients, which are optimized to connect to the AWS AppSync backend. There are some options depending on your application’s use case:

  • For Amazon DynamoDB data sources, use the DataStore category in the AWS Amplify client. It provides the best developer experience and built-in conflict detection and resolution.

  • For non-DynamoDB data sources in scenarios where you have no offline requirements, use the API (GraphQL) category in the AWS Amplify client.

  • For use cases where you are utilizing the Apollo V3 JavaScript client, use the Apollo Links provided in the AWS AppSync SDK repository to easily enable authorization and subscriptions.

See the AWS Amplify documentation for more information on the Amplify clients:

To connect to your AWS AppSync GraphQL endpoints from your backend applications (such as AWS Lambda function or Amazon EC2 instances), we recommend using an HTTP client and signing your requests using IAM by following the Authorization and authentication guide.

For more information on working with GraphQL in the backend, see GraphQL from NodeJS.