Send a 'new item in inbox' notification to external address?

I have some Workspace users who log on very infrequently and so they may not be aware of new email in their Workspace Gmail inbox for a considerable time.  They are generally not sophisticated users and so multiple profiles or similar wouldn't really be a solution.

I could use Admin Console > Apps > Google Workspace > Settings for Gmail  > Routing > Email forwarding using recipient address map  to create a table to forward emails to these infrequent users personal email addresses.  However there are data protection implications for certain emails being forwarded outside of the organisation's domain.

Ideally I'd like to have something similar to the above that could be configured for selective users to send them a 'new item in inbox' message to their personal email address to prompt them to log in to access the new email, which remains confidential to the domain.  

I've not found any solution for this at an admin level.  At a user level, I could use Zapier to write a 'new item in inbox' email with a trigger of an incoming gmail message.  But this is clunky and potentially expensive for a small organisation.

Any suggestions gratefully received!  Thanks

0 8 1,829
8 REPLIES 8

Hi,

 

did you manage to find a solution? 

thanks 

jo

Hi Jo,

No I didn't find a solution. 

In the end I wrote a Google Apps Script to achieve this, but I'm not much of a coder and so it's not very elegant or good enough to distribute. 

The code calls GmailApp.getMessagesForThreads(thread) and then, using a timestamp, looks for new messages and sends a notification email including the sender name and subject but not the body.

As nothing has been forthcoming from my original question here, I have just posted this as a feature suggestion (using a different ID that has access to the Feature group)

Coblynau/Absinthe

thanks so much for responding, appreciate it. I am also not much of a coder and will probably just have to trust that people are not forwarding emails out and also going to check them reasonably regularly... 🙂 

You can stop people auto-forwarding emails out.  Because of data protection issues I have the following settings OFF via the Admin Console:

  • Apps > Gmail>  End User Access> Automatic forwarding > OFF 
  • Apps > Gmail>  End User Access> IMAP & POP > OFF

If they are manually forwarding, and you have policies about data protection, then data loss would be less likely (I'm assuming you don't have DLP features enabled in Workspace)

(I can't see a PM option in googlecloudcommunity.com, but was going to offer you my code if you want to try it?)

I would love to try your code Coblynau if you were willing to share?

I have shared my code.  It's clunky but works for me.  It could do with better error trapping and converting to a proper deployment.

The instructions below are from when I was using a single version of the code shared between users, but might help with setting it up.

Configure the New Email Notifier AppScript 

These steps are performed whilst signed in as the new user.

  1. In user's MyDrive, create a new folder called .config

  2. Create a file called notify.txt with the first line as your name and the second line as your email address (not the user's).  This will be used for testing the installation.  It is easiest to create/edit this in Windows and upload it to the .config folder.

  3. Open a new tab and paste URL:
    https://script.google.com/home/projects/<address  of administrator's shared script>/triggers  

  4. Click Add Trigger and accept the default settings (one hour).  Select the account and Accept the security notification.

  5. Start Gmail to generate the welcome messages.  

  6. Go to Gmail Settings  > See all settings > Inbox Tab and turn on the Promotions tab and SaveThis is important as the script filters on tabs and won't work unless they are enabled.  

  7. Visit the script code page <> on the open App Script Chrome tab and Run.  This should generate a notification sent to your email about the Gmail welcome messages.

  8. If you are happy it is working.  Upload a replacement notify.txt with the first line as the user's first name  and the second line as their external email address.  

  9. Lock the notify.txt  file: Right Click > File Information > Lock to minimise risk of accidental modification.

  10. Share the folder.config with the Administrators group with Edit access.  This is to ease maintenance.  To tidy up, you can go to the Drive > Priority folder and click the vertical ellipsis ⋮ next to the recently edited file and select 'not a helpful suggestion'.

  11. Optionally, clean up footprints of the setup; Chrome suggested sites panel and History so the user has a clean start. Close tabs other than the Home page.

  12. Close the Profile window but don't log out or delete it yet.

Thank you so much! Will give it a go over the holiday period 👍

You might consider using Google Apps Script to create a custom solution that sends a simple notification to users' personal emails, prompting them to log in without forwarding actual email content. Another option could be using Google Chat for alerts, if that's part of your Workspace setup. This keeps it within the domain while helping users stay informed.

Top Labels in this Space