Thse sendgrid commercetools serverless connector for AWS, allows you to quickly deploy a cloud service to manage your emails in Sendgrid based on commercetools messaging and subscriptions.
Install the Node.js packages
$ npm install
To run unit tests on your local
$ npm test
To run the function on your local (this will require passing a message in the event)
$ serverless invoke local --function lambda
We use Jest to run our tests. You can read more about setting up your tests here.
Deploy your project
$ serverless deploy
Deploy a single function
$ serverless deploy function --function lambda
Once deployed, follow the instructions to set up your commercetools subscription to use this connector here