We use an application that sends email notifications to registered users based on the application workflow logic. We use AWS SES SMTP configurations and credentials. The setting works and emails are delivered.
However, I want to intercept the outgoing emails and modify the Subject by adding a prefix based on the AWS environment. For example, if we are in the test environment, I would like to prefix the subject with [TEST]. Since the application does not allow this type of customization, I am wondering if this action can be performed by a custom lambda function or AWS SES.
I have reviewed some of the questions here that intercept and save emails to S3 but none of those questions address or reference an outgoing email function hook. Is there a way to intercept and modify the Subject line on AWS?