Create service account and get info with Google console
- Visit to https://console.developers.google.com and login
- Click on Credential tab and create new service then select Service account key
- Select the info then click Create button and save *.p12 file into your pc (we will use this file to set up automatic to login with Google) - name it as “service_api.p12”
- You need to move the service_api.p12 file into your folder
- Click on “Manage service account”
- On your service account which you added at step 2 and select Edit link
- Check the Enable Google Apps Domain-wide Delegation and Save
- On your service account which you added at step 2 and select Edit link
- Check the Enable Google Apps Domain-wide Delegation and Save
- Click on your service account
- Copy Client Id and Service email address
Create and get api info with Facebook
- Visit to https://developers.facebook.com/ then create a facebook app
- Copy App ID and App Secret and replace into Config.php
Google Sheet
- Invite Service Email Address to Google Sheet
- Create these columns
- Add your Facebook Group ID
- Click Export!
PHP Packages was used in this project
- https://github.com/tinapc/php-google-spreadsheet-client ⇐ Google Sheet API
- https://github.com/google/google-api-php-client ⇐ Google PHP client
- https://github.com/facebook/facebook-php-sdk-v4/ ⇐ Facebook API