Table of Contents
Since version 1.10.0, all employees can sync their site schedules with personal Google Calendars. This will allow employees to view their bookings without a need to log into your website.
To add Google Calendar integration to your site and the Appointment Booking plugin, you need to firstly create a dedicated app on the Google Developer Console, then sync each employee’s calendar to their profile on your site.
Keep in mind:
- When an appointment is scheduled via your site, it’s automatically added to the employee’s Google calendar if it’s synced.
- It’s a one-way sync process. Change the booking statuses or reschedule appointments on the site, not via the Google Calendar. Changes made to the appointment booking on the website are updated in the respective Google Calendar. For example, if you change the booking status to ‘Canceled’, it automatically disappears in the synced employee’s Google calendar. However, the changes you make to the booking in the Google Calendar don’t apply to employees’ working schedules on your WordPress site.
Create an app with the Google Developer Console
Register an app with the Google Developer Console and obtain your Client ID and Client Secret. credentials. For this, do the following.
- Go to the Google Developers Console.
- Choose “Create project” or “Select a project” if you have got active ones.
- Fill in the fields like below.
- Wait to be redirected to the project dashboard.
- Go to “Library” in the dashboard.
- Select the Google Calendar API.
- Select this API and click “Enable” on the next step.
- Find the “Create credentials” button and hit it.
- Set Google Calendar API as your credential type. Also select ‘user data’ and click ‘Next”.
- Create an application name and provide your contact email addresses.
- Save the changes and skip the next step by going to the OAuth Client ID step. Publish the app.
Hit “Push to production” and confirm your action.
Find the URL in the Appointment Booking plugin dashboard, copy and paste it to the needed site area. Find it by heading to Appointments > Settings > Integrations > Google Calendar sync URL.
Paste this site URL to the Authorized redirect URL field.
Fill in the fields and click “Create”. It should generate your Client ID and Client Secret key credentials.
Put the appropriate keys to the Appointment Booking dashboard via Appointments > Settings > Integrations > Insert keys > save changes.
Once this connection is established, sync employee’s profile to their Google Calendar.
Connect employee’s Google calendar to your site
In order to connect a Google calendar, an employee must log into your site dashboard with their login details and go to Employee > Employee Google Calendar > Connect to Calendar.
By hitting on that button, they must be redirected to their Google account for confirmation.
There are chances Google will mark this app as not verified. It’s fine, they just need to hit “Advance” and then “Go to <your domain>”. It’s still secure to log in this way since your employees know you and that your website is verified.
Once the connection is successful, they’ll see that the status ‘Connected’ in their profile.
Employees will see all their bookings submitted via the site or added by hand via the site’s dashboard synced to their Google calendars.
Employees might have different Google Calendar settings which can influence their interaction with the calendar and bookings.