4

I'm trying to send a properly formatted iCalendar file as an attachment to a gmail address from Google App Engine.

When I send the email (programmatically) to a gmail address, the email with attachment is received, but gmail is not automatically providing a link to add event to Google Calendar. If I forward the exact same email, with the attachment to the same gmail address, gmail does prompt to automatically add the event. This tells me my iCalendar file is formatted properly and makes me think it may have to do with my headers:

Content-Type: text/calendar; charset=US-ASCII; name="cal.ics"
Content-Disposition: attachment; filename="cal.ics"
Content-Transfer-Encoding: base64

Any insight as to why it isn't recognizing/automatically asking to add the google calendar event when I sent it through my app, but it does recognize the ics file when I simply send an email manually?

flynn
  • 1,572
  • 2
  • 12
  • 26
  • I am having the same issue. It seems you need to set the content type to "text/calendar; charset=utf-8; method=REQUEST;", as mentioned in this post http://stackoverflow.com/questions/7359474/send-meeting-invitation-mail-over-google-app-engine. Only, there doesn't seem to be a way to do this in python. Did you manage to solve this issue? – Gwyn Howell May 14 '14 at 13:38
  • @GwynHowell, not sure I solved it, but it's some sort of behavior related to the Google platform. Since my GAE account was associated under the same email address as the gmail that I was sending it to, it wasn't working properly. When I sent it to external gmails, it worked. – flynn May 14 '14 at 19:40
  • thanks. i have an issue here http://stackoverflow.com/questions/23656802/set-content-type-of-mail-message-for-ical-attachment-to-text-calendar-method-r. if you have any further insight i'd appreciate it – Gwyn Howell May 14 '14 at 20:36

0 Answers0