(upbeat music)
- Hi, I'm Apoorv, a cloud support engineer
here at the AWS office in Bangalore, India.
Sometimes customers asked me if it is possible to track
who opened the email or clicked any link present in
that email that they have sent
using Amazon simple email service or Amazon SES?
So let me show you how to do this.
Before proceeding to use SES, we will first create
an Amazon simple notification service topic
or Amazon SNS topic, which will send the details
to our configured email address about who clicked that email
sent by SES.
As you can see, I've already logged in my AWS account,
we need to open our SNS console, type SNS.
Now, we need to create that SNS topic,
click on create topic, enter these details,
any name you want to enter,
click on create topic.
Now, we need to add the subscription to this topic,
choose create subscription,
and then choose email in this protocol.
In the endpoint, type the email address
where you want to get the notifications.
Click on create subscription.
Now you will receive a pending confirmation link on
that email address that you have entered in the details.
Go to the inbox and click on this email.
Now click on this link to confirm the subscription.
And it's done.
Now that we have configured SNS
let's proceed to the next step.
Go back to your AWS console, open Amazon SES console.
Go to the configuration sets,
click on Create configuration set,
enter any name you wanna have,
and click on create configuration set.
Now we need to open this configuration set
to enter the details.
In add destination, choose SNS.
Enter any name of your choice, in the event type,
choose click and open for this case.
Now in the topic, choose the topic
that has just been created.
Click on save.
Now that the configurations are set up, let's test this.
Go to the domains in your SES console, click here,
choose any verified domain and then choose
send a test message.
Choose raw, here you will add the details
related to the email that you are sending.
I'm just pasting here a sample test email message.
Add the from email address here,
be sure to use the name of the configuration set
created earlier for this parameter X-SES configuration set,
and now choose send.
Now let's go to the inbox and check
whether we have received the email.
And you can see we have received that email
that we sent using Amazon SES.
Now open this email.
We will now see that Amazon SES
already sent a notification message
to the email id configured in the SNS,which is this one.
And see here we have received an Amazon SNS notification.
And we can also see the email address of the customer
who opened the original email.
Now suppose you want to also monitor
how many emails were opened.
To do this, we need to add another destination
that is Amazon CloudWatch to the same config set.
Go back to our Amazon SES console, open your conflict set
that you have created earlier.
In add destination, choose CloudWatch.
Again, we will add the details,
enter any name of your choice, in the event types,
choose click and open, and in the value source,
choose message tag, and then type the dimension in
any default values for this dimension.
Remember, this will be the tab
to monitor the CloudWatch metric that will be created.
Click on save.
All set, let's test this again by sending a test email.
Go to the domains in your SES console,
choose any verified domain
and then choose send a test email, select raw,
here you will add the details related to the email
that you're sending.
Add the from and the to email address,
and here I'm just again pasting a sample test email message.
Be sure to use the name of the configuration set
created earlier for this parameter X-SES configuration set.
Also, be sure to add the required message tags
so that the data is pushed to the CloudWatch metric.
And now, choose to send.
Now let's go to the inbox to which we have sent email.
Open that email, and check again that inbox
that we received the SNS email with the details.
See, here we have received that Amazon SNS notification.
Now let's go to the CloudWatch console.
Open the metrics, open SES metrics.
You can see that we have created the metric
with the data point that's pushed by the message tags.
So, here you will see a data point
whenever any sent email is open.
Thanks for watching and happy cloud computing
from all of us here at AWS.
(upbeat music)