- Follow the Get Started from Serverless, Generate default serverless config.
- Create a verified email as contact email for your AWS SES service.
- Replace Serverless config file with the serverless.yml.
- Replace Handler code with handler.js.
- Use the example form and update
LAMBDA_URL
,contactTo
andmyDomain
. - Otherwise, make sure you POST the following json in lambda request.
{
"name": "Sitaram",
"reply_to": "[email protected]",
"message": "Very important message.",
"website": "example.com",
"contact_to": "[email protected]"
}
- Once you have lambda set up for the first time, just update fields
website
andcontact_to
for you next contact us form and domain with a new email.