Use cases → Admin and governance
Send template-based welcome emails to new users automatically
Trigger a consistent, customisable welcome message for each new account, using templates and delegated sending from a real mailbox.
| Who it is for | IT or onboarding teams automating standard user welcome messages across multiple domains. |
|---|---|
| APIs | Admin SDK, Gmail API |
| Typical scopes | admin.directory.user.readonly, gmail.send |
The problem
Manual welcome emails are inconsistent and sometimes forgotten, especially at scale or across multiple domains. Automating this with a service account ensures every new user gets the correct information, but only if the process is triggered reliably and messages are sent from the right mailbox.
How it works
- Poll the Admin SDK for newly created users at a regular interval.
- On detecting a new user, populate a standardised template with user-specific details.
- Send the welcome email using the Gmail API, with the service account delegated to the intended sender's mailbox.
- Record the sent message ID and user details to prevent duplicate sends.
What changes
Every new user receives a timely, branded welcome email from the correct sender, with no manual intervention required.
Watch it explained
“Build an Automated Email Workflow using Google Apps Script — Part1 | Aryan Irani” — Aryan Irani on YouTube. Third-party video, included because it covers this ground well. We are not affiliated with the channel.
Questions people ask
Can I use dynamic content in the welcome template?
Yes, merge user attributes from the Admin SDK into the template before sending. Just ensure you handle missing or unexpected values gracefully.
What if a user is deleted before the email is sent?
The Gmail API will return an error when sending to a non-existent account. Log and surface these errors so you can review missed welcomes.
Want this built?
This is a pattern we run in production. We will set up the delegation and build this on top of it — $500 per hour, most of it working the same day.
Talk to us Or read the setup guideRelated use cases
Automate joiners, movers and leavers
Create accounts, set group membership, provision Drive and hand over mailboxes without a manual checklist.
Continuously verify your delegation still works
A scheduled probe that proves every API still answers under every tenant, before a customer finds out otherwise.
Reduce an over-broad delegation grant safely
Find out which scopes your automation genuinely uses, then cut the grant down to them.