AWS Amplify provides the possibility to have a GraphQL API out of the box with simple steps and lots of additional options including authentication, deployments, and environments. This provides us with the ability to develop an API fast with just a GraphQL SDL schema, and AWS Amplify will build the API, DynamoDB instance, and the proxy server for the connection.
In this recipe, we will learn how to create a GraphQL API using AWS Amplify and add AWS Cognito functionality for authentication.
Getting ready
The prerequisites for this recipe are as follows:
- The previous recipe's project
- Node.js 12+
The Node.js global object that is required is @aws-amplify/cli.
To install AWS Amplify, you need to open the Terminal (macOS or Linux) or the Command Prompt/PowerShell (Windows) and execute the following command:
> npm install -g @aws-amplify/cli
In this recipe, we will use the project from the Creating your AWS Amplify Environment recipe. Please complete...