0

I'm working on a lambda which does some processing and creates a pandas DataFrame as output. I want the contents of this dataframe to be mailed to users in form of a table. Can this be done thorugh Amazon SNS or do I need SES? We already have SNS setup for our project and using SES just for this seems a bit overkill.

Amol Borkar
  • 2,321
  • 7
  • 32
  • 63
  • Write the DataFrame to S3. Trigger another lambda which will download this file and send it via SNS. https://stackoverflow.com/questions/66475678/aws-s3-sending-content-as-attachment – Devang Sanghani Mar 21 '22 at 06:54
  • How do you expect your email to look when it is received? Would it just be plain text, or would it be formatted (eg HTML)? Also, who are these "users" -- are they staff, or customers? (Staff don't need things as pretty as customers!) – John Rotenstein Mar 21 '22 at 07:36
  • @JohnRotenstein Users are staff members. I want the data to be in a simple html table nothing fancy. – Amol Borkar Mar 21 '22 at 07:41
  • 1
    One option is to put the pretty stuff in an Amazon S3 object and simply send them a link to the object via Amazon SNS. Otherwise, you'll need to somehow turn it into pretty HTML and use Amazon SES to send an email. – John Rotenstein Mar 21 '22 at 08:37

1 Answers1

1

There is currently no way to provide a custom format for SNS emails and on top of that, the table columns won't line up as mentioned here.

So unfortunately if you want prettier emails you'd need to set up SES.

LRutten
  • 1,634
  • 7
  • 17