urlgoogle-chrome-extensiongmail

Edit or forward an existing mail into Gmail Compose Window


I have a Chrome extension which adds new functionalities to the Gmail interface.

I'm trying to create email "templates" which have a default header, footer and signature (using html, images & css). I want to open these templates in order to edit and send them, just filling the actual content of the email.

I was wondering if there is any way to open these emails directly into the Gmail Compose Window or something like that. Maybe there is a parameter to do this using the URL, like: https://mail.google.com/mail/?view=cm&fs=1&id=xxxxxxx.

I've tried loading the template using the body parameter, but it seems that it doesn't support html.

Any ideas?


Solution

  • Finally, I've found a way to open a mail directly into the "Compose" Window, ready to be edited and sent. It's so simple that I can not believe it takes me 2 days to figure it out:

    Just use the url:

    https://mail.google.com/mail/u/[accountNumber]/?zx=#[tag]?compose=[MailID]

    For instance, https://mail.google.com/mail/u/0/?zx=#inbox?compose=14bbb0dae14fec1f will open the inbox of your first account with a Compose Window opened and pre-populated with the e-mail data.

    Edit from 2024: This is not working anymore. They have changed the API.