Watch Gmail but only for net new emails

I have an email auto reply Scenario that watches my gmail box and replies to new emails. Everything works.

However I want to prevent the Scenario from replying to email threads that already have replies.

For example if I, as a human, reply to an email, and the customer replies back to my email, I do not want the Scenario to trigger, and right now it is.
Or if the Scenario replies to the customer and the customer replies back, I don’t want the Scenario to reply again.

Any recommendations on how to accomplish this?

Hello!! Welcome to the Make Community

One way to do would be to check the field “inReplyTo”. When it’s a first email, this field is not provided by the Gmail API. When it’s a reply, this field is an Array that contains the initial emails.

Here is an example of a replied email

So, in your scenario, you can filter out all email that contain data in “inReplyTo”. You can do like this

Regards.

Benjamin