Skip to main content

Google OAuth Authentication

OAuth is a standard for authorisation in the field of technology, which allows users to authorise an app or service to sign in to another without revealing sensitive information such as usernames or passwords. The OAuth 2.0 protocol is used for authentication and authorisation with Google APIs.

Step-by-Step Process

  1. Sign in or create an account on Google Cloud Platform
  2. Click Select a Project

Step 2 - Google OAuth

  1. Press New Project

Step 3 - Google OAuth

  1. Fill in the Project Name field

Step 4 - Google OAuth

  1. When you are done, click Create

Step 5 - Google OAuth

  1. In Notifications, click Create Project: Invent ERP

Step 5 - Google OAuth

  1. Click on the Navigation menu (3 horizontal bars) in the top left corner

Step 7 - Google OAuth

  1. Click APIs & Services then OAuth consent screen

Step 8 - Google OAuth

  1. Choose a User Type, Select Either Internal or External.

Step 9 - Google OAuth

  1. After that, press Create

Step 10 - Google OAuth

  1. Fill the App Name field under App Information

Step 11 - Google OAuth

  1. Fill the User support email field under App Information

Step 12 - Google OAuth

  1. Click Add Domain

Step 13- Google OAuth

  1. Click Authorized domain 1 and enter a domain for example Invent ERP’s website

Step 14- Google OAuth

  1. Press on Email addresses

Step 15- Google OAuth

  1. After that, click on Save and Continue

Step 16- Google OAuth

  1. Press on Save and Continue again

Step 17- Google OAuth

  1. If you chose the External under User Type then you will continue to Test Users. Click Add users

Step 18 - Google OAuth

  1. Fill in the blank under Add Users

Step 19 - Google OAuth

  1. Then click Add

Step 20 - Google OAuth

  1. Click Save and continue

Step 21 - Google OAuth

  1. Select Back to dashboard

Step 22 - Google OAuth

  1. When you are all done, simply press Publish App

Step 23 - Google OAuth

Navigate to Invent ERP

  1. Using the left sidebar menu, under Configuration select Settings

Step 24 - Google OAuth

  1. Then click on Technical then choose Mail Server then Mail Servers.

Step 25 - Google OAuth

  1. Press Add

Step 26 - Google OAuth

  1. Fill in the Mail Server Description field

Step 27 - Google OAuth

  1. Choose Gmail OAuth Authentication in the Authenticate Using drop-down menu

Step 28 - Google OAuth

  1. Click on Copy

Step 29 - Google OAuth

  1. Navigate to (console.cloud.google.com)

Step 30 - Google OAuth

  1. Select Credentials

Step 31 - Google OAuth

  1. Then Press Create Credentials

Step 32 - Google OAuth

  1. Choose OAuth client ID

Step 33 - Google OAuth

  1. Select Application Type

Step 34 - Google OAuth

  1. In the Name field, enter Invent

Step 35 - Google OAuth

  1. Click on Add URL

Step 36 - Google OAuth

  1. Paste the URL you copied earlier from Invent ERP

Step 37 - Google OAuth

  1. Then Press Create

Step 38 - Google OAuth

  1. The next step is to click Copy Client ID

Step 39 - Google OAuth


  1. Open the side menu and go to APIs & Services → OAuth Consent Screen.
  2. Choose a User Type and click Create.
  3. Fill in the App Name and User Support Email.
  4. Click Add Domain and enter inventerp.com.
  5. Add developer contact information and click Save and Continue.
  6. Add test users if using External user type.
  7. Click Back to Dashboard and then Publish App.

Step 3: Configure Mail Server in Invent ERP

  1. Log in to Invent ERP.
  2. Go to Configuration → Settings → Technical → Mail Server → Mail Servers.
  3. Click Add, fill in the Mail Server Description.
  4. Choose Gmail OAuth Authentication under Authenticate Using.
  5. Click Copy to copy the OAuth2 Redirect URL.

Step 4: Create OAuth Credentials in Google Cloud

  1. Go to APIs & Services → Credentials → Create Credentials → OAuth Client ID.
  2. Select Web Application as the application type.
  3. Enter a client name and paste the OAuth2 Redirect URL under Authorized Redirect URIs.
  4. Click Create.
  5. Copy the Client ID and Client Secret.

Step 5: Finalize in Invent ERP

  1. Paste the Client ID and Client Secret in the Mail Server form.
  2. Enter your Gmail address as the Username.
  3. Click Create.
  4. Scroll down and click Connect Your Gmail Account.
  5. Authorize the app in Google.
  6. Verify that Token Valid is displayed.
  7. Click Test Connection to confirm the setup.