Amazon SES (Simple E-mail Service) 是最有名的邮件发送服务平台之一,很多大公司都在使用。Amazon SES和阿里云邮件推送类似,可以用来发送通知、触发式邮件、通讯等各类型邮件。它拥有非常高的送达率,非常便宜的价格($1 每10000封),以及完善全面的日志、权限管理、邮件回弹拒收自动管理等实用功能,因此很受各类型网站的青睐。
但是,SES在使用之前需要申请使用权限,而且SES的权限审核非常严格。在网上搜索 AWS SES denied production access, 能找到许多的帖子,抱怨无法通过SES的使用申请。
今天,我就来介绍一下如何使用正确的姿势申请Amazon SES,让你有更高的概率通过SES 生产环境的申请。同时,我也将介绍如何使用SES发送邮件。本文作者为香菇肥牛,原文链接为https://qing.su/article/amazon-ses-production-access-setup.html, 转载请注明原文链接。谢谢!
1. 申请SES production access
Amazon SES的主要使用场景就是各类网站和APP,因此您需要一个网站和对应的域名用来申请SES的使用。网站如果是新建的,没有什么内容,会较难申请成功。有正常内容和谷歌索引的网站,申请成功概率会高很多。
打开网站 https://aws.amazon.com/ses 登录您的AWS账户后,会引导您输入您的域名和邮箱。按照要求做好对应的验证之后,会进入控制台。
没有申请production mode之前,您的账户会处于沙盒模式,每天只能发送200封邮件。如果想要发送更多的邮件,就要申请生产模式 (production mode). 点击火箭图标的 Request production access, 就会开启生产模式的申请流程。
开启申请后,会自动帮你创建一个AWS工单。工单会提示您提交更多的信息以便审核。
这里就是申请的关键了。您需要写一篇小作文,介绍一下您将如何使用Amazon SES. 这里我将详细说明。
2. 如何写SES的申请材料
对于SES的审核人员来说,他们希望了解你的网站的邮件发送使用场景,从而确保你不会用SES来发送垃圾邮件。因此,你需要具体地描述发送的邮件类型,数量,收件人来源等信息。下面是我自己写的几个有效范例,您可以参考修改。
范例1:一个WooCommerce网站
I would like to request access to the SES production mode for my website https://example.com. It is a eCommerce website that sells electric rockets of various brands to local customers. We send emails to website visitors and our customers in the following scenarios.
1) Verification code will be sent through email to visitors who sign up for accounts on my website, or who request a password reset.
2) Transactional emails related to orders on my website will be sent to customers who make a purchase. This includes invoices, receipts of payments, shipping and tracking notification, requests for product review, etc.
3) We send monthly newsletters of our new or promotional products to our current customers, who explicitly opt in to receive such newsletters.
We will take email bounces and rejections seriously. We expect monthly sending volume of ~ 20K at the moment. Please let me know if you need any more information regarding this request. Thank you.
范例2:一个社区论坛
I would like to request access to the SES production mode for my website https://example.org. It is a community forum/discussion board about hiking trails in my county built with the Discourse groupware, with about ~1000 regular visitors. SES will be used in situations below.
1) Whenever a user signs up for a new account on our forum, a verification email need to be sent to verify the visitor’s email address. Similarly, it will be used for password resets.
2) Users may opt in for electronic notifications when their threads or discussions get a reply, and emails will be sent to notify them.
3) Users and other visitors may sign up for our monthly email newsletters about local events. In such case, the newsletters will only be sent to recipients with double opt-in.
Please let me know if you need more information. Thank you.
如果您写的材料有理有据令人信服,且网站真实有效,那么一切顺利的话,很快就能获得生产模式的批准。
初次申请一般会获得每天50000封的发信额度。如果一段时间后需要更高的发信数量,则可以继续申请更高的额度。如果没有获得批准,您也可以根据要求补充材料后再次申请。
3. 如何使用和配置SES
获得生产模式的批准后,您就可以正式使用SES了。登录面板后,您可以看到新的发信额度。
SES的后台面板非常复杂,下面我来简要介绍如何使用SES发信。首先,如果您需要添加其他域名(不需要额外申请),可以点击列表左边的Identities, 然后点击Create Identity, 添加域名。
在打开的界面中,选择添加域名,然后勾选Use a custom MAIL FROM domain.
勾选后,您将会需要给您的域名设置一个子域名,这样您的邮件头中会显示邮件来自这个子域名,比如我的域名是example.com, 我这里设置的子域名是sender.example.com. 系统会让您设置一条MX记录和一条TXT (SPF) 记录,请按照要求设置好。
接下来,在DKIM-based domain verification中,选择Easy DKIM, RSA 2048 Bit, Enable DKIM Signature. 系统会提示您设置三条CNAME记录,请按照要求设置好。
然后,按照自己的需求设置好DMARC策略。全部设置完毕后,回到这个域名,可以看到状态都变成了Verified/Successful.
最后,我们点击左侧SMTP settings, 再点击Create SMTP credentials, 新建SMTP用户名和密码。
图中,SMTP endpoint就是你需要使用的SMTP服务器地址。有了新建的用户名和密码之后,就可以正常发信啦。我们给mail-tester.com发一封测试邮件。
可以看到,mail-tester.com测试拿到了10分满分,说明一切正常,可以开始使用SES啦。
如果您有任何问题,都可以留言讨论。本文作者为香菇肥牛,原文链接为https://qing.su/article/amazon-ses-production-access-setup.html, 转载请注明原文链接。谢谢!