Sending Mail through Gmail¶
Hire2Retire Access Certification supports sending mails through your Gmail account using either OAuth based or a certificate based authentication mechanism.
Service Provider Application¶
The Google application on Hire2Retire uses OAuth authorization. By linking your Google account with Hire2Retire, you authorize the RoboMQ application to send emails on your behalf. During setup, a consent window is displayed where you grant the required permissions. RoboMQ needs the following permissions on your account to provide a seamless integration experience.
| Scopes | Explanation |
|---|---|
| auth/userinfo.email | View your primary Google Account email address |
| auth/userinfo.profile | View your personal info, including any personal info you've made publicly available |
| auth/gmail.send | Send email on your behalf. |
Create a Connection¶
Before configuring Gmail on Hire2Retire, ensure you have a Google account with an active mailbox.
-
Click Link account to begin authentication. You will be redirected to the Google sign-in page.

-
Select an existing account or add a new Google account.

-
After signing in, Google displays a permissions consent page. Review and approve the permissions required by Hire2Retire to send emails on your behalf.

-
After granting consent, you will be redirected back to Hire2Retire. The redirection confirms that the connection has been successfully established.
Customer Owned Application¶
With a customer-owned application, users are not required to sign in interactively. Instead, Hire2Retire will use your application service account to impersonate a user account for automated email delivery. Choosing this connection requires you to configure your service account's application permissions within your Google instance.
Create a Connection¶
-
Create a project in Google Cloud Platform.

-
Enable Gmail API for that project by following the steps mentioned below:
- Go to API’s and services
- Click Enable APIs and services from the top menu bar.
- Search for Gmail and enable it for the project.

-
Create a Service Account for the project
- Go to the Service Account section by selecting the IAM & Admin from the side menu bar and selecting the service account.

- Click on Create new Service Account from the top menu bar and fill the account name field, and select
Create and Continue.

-
Configure Domain-Wide Delegation in the Google Admin Console by following the instructions below
- Select
API controlsby going toSecurity>Access and data Controlfrom the side menu bar.

- Select
Add New, enter the service account client ID, and addhttps://www.googleapis.com/auth/gmail.sendas the scope.
- Select
-
Upload the certificate. You can download the certificate from the Hire2Retire connection UI and add that certificate to the service account created in the Google console by following the steps below:
- Select the service account and go to the keys section from the top navigation menu

- Select Upload existing key, browse the certificate that you downloaded from the Hire2Retire connection UI, and upload it.

-
Enter the service account email and the user account of your organization that will be used to send emails, then link the account in Hire2Retire.
