Skip to content

ufundo/org.civicrm.googlegroups

 
 

Repository files navigation

org.civicrm.googlegroups

Screenshot

Google Groups Screenshot

The extension uses Google's directory API to sync Google Groups member list with that of contacts in CiviCRM Groups. The extension supports latest version of CiviCRM ver 5.x and based on Google Client Library v2.x.

Features:

  • Syncs the contacts from multiple CiviCRM groups (regular or smart) to specified Google Groups.
  • Adds a scheduled job to automatically sync once per day.
  • Requires only one time Authorization, and works based on long lived Refresh Token.
  • Supports multiple domains within a Google Apps system.
  • An email other than home/work could be used for the sync. Email with location type "Google" is given preference over primary email.

The extension is licensed under AGPL-3.0.

Requirements

  • PHP v5.6+
  • CiviCRM v5.0+
  • A G Suite domain with API access enabled.
  • A Google account in that domain with administrator privileges.

Installation (Web UI)

TODO: this extension is currently not available to install through the web ui

Installation (CLI, Zip)

Sysadmins and developers may download the .zip file for this extension and install it with the command-line tool cv.

cd <extension-dir>
cv dl org.civicrm.googlegroups@https://github.com/greenleafadvancement/org.civicrm.googlegroups/archive/master.zip

Installation (CLI, Git)

Sysadmins and developers may clone the Git repo for this extension and install it with the command-line tool cv.

git clone https://github.com/greenleafadvancement/org.civicrm.googlegroups.git
cv en googlegroups

G Suite Setup: Enabling API, Creating Project, OAuth and Consent

  • Before you can begin, you need to create a new project in the Google APIs Console. Screenshot

  • Enable the API access from Google Cloud Console in order to make requests to the Directory API. To enable the API, At the top-left, click Menu menu > APIs & Services > Library, and enable “Admin SDK API”.

Screenshot

Screenshot

The enabled api should now be visible in "Enabled APIs and Services" section.

Screenshot

  • Create OAuth consent screen. Screenshot Screenshot

  • Create authorization credentials. Open the Credentials section from "APIs & Services". Click Create credentials > OAuth client ID. Screenshot Screenshot Screenshot Screenshot

Extension Setup

  • Goto Administer >> System Settings >> Google Groups Settings.

  • Take a note of the url. This should match with redirect uri setup in OAuth consent screen earlier. If it does not match, edit your oauth consent screen again to correct it.

  • Enter client id and secret from the credentials created earlier.

  • Enter GSuite domain. For multiple domains enter comma separated domains.

  • Save would redirect to google authorization (OAuth) prompt. Once authorized it should redirect back to extension's Google Groups Settings screen. If it does not, either: A. Redirect uri has not been setup correctly OR B. Your setup is a local one and not accessible to public.

  • Once setup, CiviCRM group add or edit screen would render a Google Group dropdown. Select a matching google group. Sync process will make sure that members of google groups are synced from that of matching Civi Group.

  • Use Contacts >> Google Groups Sync to run the sync process manually.

  • To automate the sync, enable the 'Google Groups Sync (Daily)' job on Administer >> System Settings >> Scheduled Jobs screen.

Screenshot

Known Issues

Sync is only one way - from CiviCRM to GoogleGroups.

Credits

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • PHP 94.6%
  • Smarty 5.4%