> For the complete documentation index, see [llms.txt](https://skedway.gitbook.io/skedway-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://skedway.gitbook.io/skedway-documentation/integrations/integrations-general-specifications/google-workplace-integration-calendar-+-directory.md).

# Google Workplace Integration - Calendar + Directory

This document aims to detail the whole process and the main implications of integrating a Skedway account with Google Workplace

## Gateway

Skedway platform uses the **Google Directory API** and **Calendar API** to access users (read-only) accounts/groups and manipulate (read-write) resource and user calendars.

## Scopes

* <https://www.googleapis.com/auth/calendar>
* <https://www.googleapis.com/auth/admin.directory.user.readonly>
* <https://www.googleapis.com/auth/admin.directory.resource.calendar.readonly>
* <https://www.googleapis.com/auth/admin.directory.resource.calendar.readonly>
* <https://www.googleapis.com/auth/admin.directory.group.readonly> <br>

## Steps

### Activating the Skedway Integration

{% hint style="warning" %}

* Access Skedway with an account that has the access profile enabled for reading and writing from the Integrations submenu.
* If you do not have the appropriate credentials, contact the manager of your company responsible for Skedway.
  {% endhint %}

1. Access the integration submenu by following these steps: Menu-<mark style="background-color:purple;">ADMINISTRATION</mark> > Section-<mark style="background-color:purple;">CONECTIONS</mark> > submenu-<mark style="background-color:purple;">INTEGRATIONS</mark>
2. Create a new integration by clicking on the <mark style="background-color:green;">NEW</mark> button and select the desired gateway. The following information and fields will be updated according to the chosen gateway. Select <mark style="background-color:green;">"Google Calendar & Google Directory"</mark>
3. Fill in the fields according to the requirements
   1. Account to impersonate (email)
   2. Primary domain
4. Configuration done!! The settings in Skedway are finished, now it is necessary to configure Google Workspace
   1. Scopes
   2. Client ID

### Enabling Integration in Google Workspace

{% hint style="warning" %}
In Google Workspace it is necessary that the user has the domain configuration permission

The organization and layout of the menus may vary due to constant changes and improvements made by Google
{% endhint %}

1. Within the Google Console, go to <mark style="background-color:purple;">MAIN MENU</mark> > <mark style="background-color:purple;">SECURITY</mark> > <mark style="background-color:purple;">APIS CONTROL</mark> > <mark style="background-color:purple;">ENTIRE DOMAIN DELEGATION</mark>
2. In this panel select the option to <mark style="background-color:green;">MANAGE ENTIRE DOMAIN DELEGATION</mark>.
3. Create a new API control in <mark style="background-color:green;">ADD NEW</mark>
4. On the screen, set the Skedway identifier code with the Client ID generated in the Skedway.
5. Copy the access links (Scopos) in each Auth Scopes field.\
   ![](https://3934577800-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FE8umnxI5WAUgx2x4WiSA%2Fuploads%2FtWlT0YarCZ91JihaolZ3%2Fimage.png?alt=media\&token=7014f6e1-2114-4869-bc1e-83a7d6ca50d1)
6. Authorize the scopes.
7. Done!

{% hint style="info" %}

* Scopes and permissions are mandatory for integration completion
* The registered manager will have full control of the permissions given to the Skedway application.
* These permissions can be revoked at any time if necessary.
  {% endhint %}

## References

{% embed url="<https://developers.google.com/calendar>" %}

{% embed url="<https://developers.google.com/admin-sdk/directory>" %}

{% embed url="<https://developers.google.com/identity/protocols/oauth2/service-account#deegatingauthority>" %}

{% embed url="<https://support.google.com/a/answer/162106?hl=en>" %}
