How to Retrieve Replied Emails for Gmail
Description :
This sample script is for retrieving emails which replied for received mails. Because there are no samples which confirm whether the owner (me) replied to the received mails, I created this. The point is as follows.
- When there are more than 2 messages in a thread, there might be a possibility to have replied.
- For more than 2 messages in a thread
- The email address of “from” for the 1st message is the sender’s address.
- When the email address of “to” of after 2nd messages is the same to that of “from” of 1st one, it is indicates that the thread was replied by owner.
This sample script is made of Google Apps Script (GAS). But also this can be applied to other languages.