Google App Engine - Receive Email from gmail and parse it

249 views
Skip to first unread message

MANIKANDAN S

unread,
Mar 2, 2017, 9:23:00 AM3/2/17
to Google App Engine

I am wondering whether Flask app in Google App Engine Production server can receive email with attachment from gmail or any other third party.


As I am having a requirement now that I would receive a email with csv attachment, need to parse it - take the decision and change the content on the website.


I am thinking of automating the entire thing, but I do no how to setup mail with google app engine, that is my application whenever receive a mail with attachment, parse it, do the computations and change the page content and display on the website.


I have gone through google app engine document but it doesn't provide much information.


I have setup the inbound_email in app.yaml and also handlers for the email, now the only question is how to get the email to the handler script. enter link description here


I tried to send email from my gmail to app engine but the email delivery has been failed, please help !!


Is there any way on doing the above requirements ???

Nicholas (Google Cloud Support)

unread,
Mar 17, 2017, 6:10:41 PM3/17/17
to Google App Engine
Hey there,

You mention that you are following the Receiving Email article and have done the following:
  • Set up the inbound service in the app.yaml
inbound_services:
- mail
  • Added mappings that associate URL-mapped email addresses with script handlers
  • Define handler methods in your Python application
It seems like you've performing the steps necessary to start handling emails from you App Engine standard application.  You also mention that the email delivery has failed.  As this seems like more of a technical question, I'd recommend posting this question to Stack Overflow with the google-app-engine tag.  We monitor that forum closely and is better suited for this type of report.

When posting your question there, be sure to include your app.yaml (to show the inbound service and handlers) and the Python Flask handler in question that is intended to receive the POST request containing the email.  Mentioning the error message received when attempting to send the email to your application is also a good idea.  Once you've done this, please post a link to your question here so that others in the community can follow through, including myself.
Reply all
Reply to author
Forward
0 new messages