Skip to content

A Symfony console application to sync contacts from Planning Center to Google Groups

Notifications You must be signed in to change notification settings

nrutman/contacts-sync

Repository files navigation

Contacts Sync

A Symfony console application to sync contacts from Planning Center to Google Groups. The application queries both sources for lists named after distribution groups. It then diffs the contacts and makes sure the Google group mirrors the contacts found in Planning Center.

Installation

All dependencies can be installed using the Composer PHP dependency manager. Once Composer is installed, download this repository and run the following command:

composer install

Configuration

Included in the config folder is a parameters.yml.dist file. Complete the following steps:

  1. Copy this file and rename it parameters.yml.
  2. Fill in all of the tokens with configuration for Planning Center and Google.
  3. Make sure the lists parameter is completed with the lists to sync from Planning Center into G Suite.
  4. Run bin/console sync:configure to get a Google G Suite token.

Usage

Sync:Configure

To configure the command by provisioning a token with your Google G Suite user, run the following command:

bin/console sync:configure

The command will provide a Google authentication URL which will require you to login with a G Suite Groups administrator and paste the provided the access token back to the command. If a valid token has already been provided, the command will exit gracefully.

Parameter Description
--force Forces the command to overwrite an existing Google token.

Note: the resulting Google token is stored in the var/google-token.json file. If at any time you have problems with Google authentication, delete this file and rerun the sync:configure command (or use the --force parameter).

Sync:Run

To sync contacts between lists, simply run the following command:

bin/console sync:run

This will fetch the lists, run a diff, and display information for changes it is making to the groups.

Parameter Description
--dry-run Computes the diff and outputs data without actually updating the groups.

About

A Symfony console application to sync contacts from Planning Center to Google Groups

Resources

Stars

Watchers

Forks

Packages

No packages published