invoking lambda function on receiving email by ses

0

i used an gmail for aws ses email and got it verified.i then created a rule which invokes lambda function and it added the permission. i have attached awsSesfull access to lambda function.So now if i send an email to the aws ses verified email the lambda function is not invoking

1 Answer
0

In the Lambda console it will show (in the function overview) which services are allowed to invoke it. Does SES show there? There are instructions in the documention for how to give permission for SES to invoke Lambda.

Otherwise, check the rule in the "Email receiving" part of the SES console to make sure that the correct Lambda function is selected.

Another way to do this is to have SES deliver the mail to S3; then use a trigger from S3 to Lambda. It's an extra step but it gets around the Lambda payload limits for large emails.

profile pictureAWS
EXPERT
answered a year ago
  • i created a rule in aws ses to store the incoming email to s3 bucket with appropriate name and permissions and also set up sns.When i sent an email containing spreadsheet attachment to aws ses email sns notification was stored in s3,but not the spreadsheet.please can u help the resolve the issue

  • Did the Lambda function get triggered when the email was saved in S3? If not, check the configuration of the bucket to make sure that it covers the correct prefix (where the emails are configured to be saved) and that it is triggering the correct Lambda function.

  • i didnt set up lambda function trigger,but the incoming ses email is not stored in s3 bucket.only the sns topic notification is stored in s3 bucket but not the attachment.how to attach iam roles to aws ses

  • In the past, I've set up direct SES delivery to S3 because it handles larger emails better. From there, you can trigger a Lambda function when a message is delivered.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions