In this blog post, we leveraged the capabilities of AWS Lambda and API Gateway to build a serverless application API. We used Terraform to streamline the deployment process, creating all necessary resources such as API Gateway, Lambda function, Cognito user pool, and ACM certificate. The integration was successful once we configured the API Gateway authorizer with the Cognito user pool, set up CORS headers, and mapped a custom domain to access the API. We also implemented authentication using Cognito Authorizer, generating an authentication token from Cognito to access the API. This example showcases how serverless architecture can be effectively used to build scalable and maintainable APIs.