Google Apps Application

Last modified by Admin on 2026/05/25 00:01

cogThis extension allows to connect Google Apps to XWiki
TypeXAR
Category
Developed by

Ludovic Dubost (XWiki SAS)

Active Installs10
Rating
0 Votes
LicenseGNU Lesser General Public License 2.1

Success

Installable with the Extension Manager

Description

Information

You can also try the Pro version Google Apps Integration (Pro) which offers further improvements and bugfixes including fixes for Restrict domain for users to login doesn't work and missing People API blocker issues.

This is the distribution for the Google Apps extension, allowing to integrate XWiki with Google's editing application (Google Docs, Spreadsheet, Presentations and Drawing). Thanks to this application it is possible to easily import a Google Apps document as an attachment in XWiki (in multiple formats) and also to launch editing of an XWiki attachment in Google Apps. Once your editing session is finished you can reimport it in XWiki.

This integration uses the OAuth2 protocol to connect Google Apps with XWiki. It works with individual Google accounts as well as company wide Google Apps accounts.

The configuration of the application is available on the wiki Administration under the "Applications" section:
ApplicationConfiguration.png

To activate Google Apps you need to register for OAuth access on Google.com and next insert your domain name and key in the settings from the wiki Administration section "Google Apps". You will find more information about registration in Google's registration documentation.

Activate Google Authentication

To activate the Groovy Authentication you need to update the following settings in xwiki.cfg:
xwiki.authentication.authclass=com.xpn.xwiki.user.impl.xwiki.GroovyAuthServiceImpl xwiki.authentication.groovy.pagename=xwiki:GoogleApps.AuthService

Once you have properly configured the application, you will be able to see the feature in the Attachments section of XWiki pages. You can either click on the edit link next to each attachment or use the "Import from Google Apps" button.

googleapps.png

Once you have properly configured the application, you will be able to see the feature in the Attachments section of XWiki pages. You can either click on the edit link next to each attachment or use the "Import from Google Apps" button.

You can also use the "drive" macro to insert (embed) a Google Document in your page.
googlemacro.png
searchfordocument.png

Prerequisites & Installation Instructions

We recommend using the Extension Manager to install this extension (Make sure that the text "Installable with the Extension Manager" is displayed at the top right location on this page to know if this extension can be installed with the Extension Manager). Note that installing Extensions when being offline is currently not supported and you'd need to use some complex manual method.

You can also use the following manual method, which is useful if this extension cannot be installed with the Extension Manager or if you're using an old version of XWiki that doesn't have the Extension Manager:

  1. Log in the wiki with a user having Administration rights
  2. Go to the Administration page and select the Import category
  3. Follow the on-screen instructions to upload the downloaded XAR
  4. Click on the uploaded XAR and follow the instructions
  5. You'll also need to install all dependent Extensions that are not already installed in your wiki

To use this feature you will first need to generated OAuth2 credentials on the Google Developer Console and obtain a secret key for the OAuth authentication integration. You will need to configure these keys in the Google Apps section of the XWiki Preferences

To activate the Groovy Authentication you need to update the following settings in xwiki.cfg:
xwiki.authentication.authclass=com.xpn.xwiki.user.impl.xwiki.GroovyAuthServiceImpl
xwiki.authentication.groovy.pagename=xwiki:GoogleApps.AuthService 

You can verify your installation by visiting the page TestDocumentList, which should list you 10 documents of your Google Docs instance.

The experimental Sync page requires a service accounts, created following this documentation and the certificate named GoogleApps.p12 saved into the WEB-INF directory

Versions

Dependencies

Dependencies for this extension (org.xwiki.contrib:application-googleapps 2.1.9):

  • com.google.api-client:google-api-client 1.30.9
  • com.google.gdata:core 1.47.1
  • com.google.apis:google-api-services-drive v2-rev174-1.20.0
  • com.google.apis:google-api-services-people v1-rev526-1.25.0

Get Connected