Bounced email on Google App Engine
I'm developing application for google app engine (python), witch needs not only to send emails, but also know which ones bounce back.
I created special account for my domain noreply@example.com, added it as an app admin and sending messages from it.
The problem is (and it was described here http://code.google.co开发者_如何转开发m/p/googleappengine/issues/detail?id=1800) - GAE sets the Return-Path to some internal email address, not allowing to receive bounced email messages.
Anyone aware of any possible workaround for this? Thanks.
It looks like someone bypassed this problem by switching to Yahoo's Mail API, which uses OAuth and can be used over HTTP. Until google fixes your problem, this looks like a viable solution.
Until the issue is resolved, workaround for my project is using typhoonae, bind mail service to google app's gmail as SMTP (to send messages from noreply@example.com). When sending this way, noreply@example.com receives bounced messages.
Google has actually since added a method for receiving bounced messages via an HTTP Request. It requires adding to your app.yaml:
inbound_services:
- mail_bounce
Which will cause a request to hit /_ah/bounce
each time a bounce is received. You can then handle the bounce by adding a handler for it. See the section there on Handling Bounce Notifications for more details on how to glean the additional information from those requests.
You could use use a third party "email marketing" API like CampaignMonitor that keeps track of the bounced addresses: http://www.campaignmonitor.com/api/method/subscribers-getbounced/
But you'd have to send mail through them, and sync your user list with theirs through their API.
精彩评论