Get New Email Notification on Discord

How can I get a notification on Discord with Subject Line when a new email arrives in Gmail?

If have done something similar for an email assistant.

Basically, you need to add Gmail node and use query to recover emails by modifiers.

Check this

You need to create a function item at the beginning to generate the date 5 minutes before, convert it to seconds and use seconds in Gmail node query to recover emails

And add a cron node to run workflow every 5 minutes.

Won’t consume more API Limit?

If something can be done through IMAP. It’ll be a lot easier.

Nope. A query every 5 minutes is enough and you can limit what messages you want to recover by query.

Related to Imap, some time ago I did some tests, but I was getting errors with credentials (probably I was doing something wrong). Additionally, I am not sure if you can limit message recovering some way.

Ha ha. Me too got same error.
Here is the solution for that.

Let’s find some working stuff other than Gmail API

Perfect. It works :slight_smile:

You can add custom rules for IMAP also, this way

You can check rules at

Probably this will work (not checked)
[ "UNSEEN", ["SUBJECT", "subject-to-detect"] ]

1 Like