Contents
Google Cloud API
Starting with version 20.1, various Google services can be accessed from Xentral. Google Cloud Print, Google Calendar and Gmail.
Requirements and Procedure
- A usable Google Account is available
- You are using Xentral 20.1 or a newer version
This article outlines how to set up the Google API for the first time. This must be done once and consists of the following steps:- Set up Google API.
- Configure API-Zugang in Xentral
- Authorize Google Account in Xentral
Subsequently, e.g. Google Cloud printers can be connected. For more info read further in the article.
Create Google API-Account
First, log in to your Google Account. Then go to https://console.cloud.google.com in the same browser.
Then three steps are necessary, which we have described in more detail below. You can also use the input values - as far as they are arbitrary. Please adjust the URLs carefully.
Now follow the first three steps- Create a new project
- Create new consent screen
- Create API access
Create new project
- Upon first use, you must first agree to the Google Cloud Terms of Use.
- Then click on the Project drop-down at the top and create a New Project there.
- You can enter any name or use the one from our example. When you are finished, click on Create.
- It takes a while for the project to be created.
- Then you can select the project right away by clicking on it.
Create new consent screen
Once you have selected the project, you can click Credentials to create a new account. To do this, please select the OAuth Client ID option.
On the first run, you need to configure a new consent screen first, this process is necessary only once even when creating multiple API accesses.
To do this, please click on the Configure Consent Screen button.
You can use any name or use our text suggestion. Logo upload is optional.
Here are some important settings where you should pay attention to error-free input:- Authorized domains: Numbered list itemEnter the domain of your own Xentral instance, this is the first part of the address you will see in your browser window when working with Xentral.
- Please leave out the protocol (http: or https://) as well as the beginning of the URL (the so-called subdomain) and take only the last two values of the domain. Only the domain name and the domain extension (TLD) are entered, no subdomains or paths. In our example, the value is xentral.biz
- Please note: After the input you have to confirm with key [1] or [2], otherwise the value will not be saved
- Link to the application's home page: Unlike the last field, the complete path to Xentral must be specified here, including the protocol and paths to your Xentral instanceLink to the application's privacy policy: In case of use within your own company, this value is not relevant. You can enter any value here or use our example
- Click on Save to finish
You will be shown when the consent screen has been successfully configured.
Create API-Access
After creating the consent screen, you will be redirected to the page where you can create the actual API access.
Under Application type, please select the Web application option. Under Name, please enter any name or our suggested text.
The last value to be populated, the Authorized Forwarding URI, is obtained from Xentral in the following step.
Leave the browser window open and switch to your Xentral instance in another tab or window.
Activate Google Calendar API
In order to enable the synchronization of the Google Calendar with Xentral, the Google Calendar API must be explicitly activated beforehand.
To do this, go to the Dashboard and click on "ENABLE APIS AND SERVICES".
Search for the term "calendar" and select the "Google Calendar API".
On the next page click on "Activate".
Note: Appointments imported from Google are always imported as "public", i.e. every user in xentral with access to the calendar can view these appointments. You can hide individual appointments by unchecking the "public" checkbox. After that, only the user associated with the Google account will have access to this appointment.
Configure API-Access in Xentral
Navigate to the Xentral AppStore and search for "Google". You will find the Google API app, which you can launch from the app store.
Create a new entry there by clicking on the "New" button.
First populate the following value: Enable the entry API Type: Select Google Cloud Print Name (internal): Any name (without special characters, without spaces) Description: Any description.
Then copy the value from the Redirect URI field and switch back to the other browser window or the last tab with your Google Cloud Console.
There, populate the value under Authorized Redirect URI and click Create.
Please note: After entering the value, always confirm it with key [3] or [4], otherwise the value will not be applied.After creating the API access, a dialog appears with the last two necessary values, which are required to connect via Xentral to the Google Cloud service. Please copy them one by one into the corresponding field in your Xentral Google API app.
Copy client-ID in Xentral
- Copy client key to Xentral
- Now confirm with Save
After the Google API access has been set up, Xentral can now connect to the Google Cloud Print service.
Authorize Google Account in Xentral
To use the printers registered in Google in Xentral, the corresponding Google account must be authorized once.
To do this, click on Connect in the app. You will be redirected to the authorization of your Google account. Here, please use the Google Account under which you had previously set up the printers. This does not have to match your Google API account.
Depending on which domain the API account and your Google account come from, the following warning may appear, which you should answer as indicated in the images:
You now have to confirm the connection again:
and agree to the necessary rights once again:
Finally, you will be asked to authorize Google access to your printers for this application (Print from Xentral).
Google Cloud Printer
Starting with version 20.1, printers can be conveniently accessed via the Google Cloud Print service. Compatible printers either connect directly to Google's print service or printers are accessed via the Google Chrome browser from the local PC. In this case, Google Chrome takes over the communication with the Google Cloud service.
Note: The Google Cloud Print service is deprecated, you can find more information here.
Requirements & Procedure
- A usable Google Account is available
- Google Cloud Printers are set up. For more information about setting up printers, see 3. Connecting Printers to Google Cloud Print on the Google-Support-Page.
- You are using Xentral 20.1 or a later version
For information on how to set up the Google Cloud API and how to connect Xentral to this API, see the article Google Cloud API
Set up printer in Xentral
To set up the printer(s) in Xentral, three steps are necessary - Create a new printer
- Select Google Account
- Select printer
In Xentral, first navigate to Administration > Printers.
Create a new printer and fill in the fields as described: 1. any name of the printer, this appears for selection in Xentral, so could include location and type designation. 2. technical name of the printer (please use only letters and numbers, no spaces or special characters). 3. activate the printer 4. select Google Cloud Print as option and 5. save the entry once.
You will then get additional features at the bottom of the page. here you can 1. select your Google account (if you have authorized multiple accounts) 2. select the printer you want. 3. then save again to complete the printer setup.
Google Mail via OAuth
Newer Google accounts allow sending emails only with the so-called OAuth authentication.
Note:
For each Google Mail account the "two-step confirmation" must be activated and additionally an "application specific password" must be created, which is then stored as password for the mail account in the mail configuration.
Access to Google Mail API
Create A Project and create a consent screen if they do not already exist. In the Google API Console, create new OAuth credentials or use an existing credential. The client ID and client key are required in the following step.
Configure API Access in Xentral
Create a new Google Api using the "New" button, select the Gmail type and enter the client ID and client key. Complete the form and save.
Configure Google Mail Accounts
Now you can configure Google email addresses for Google OAuth in the Email Accounts app.