Google Integration instructions/setup difficulties

I have been working on Google Integration for our Gibbon instance (a feature I am super excited about, thank you for doing it, @admin . However, I am having a little trouble getting it set up.

Before I describe my trouble, I have a bug report: The link to instructions in v. 12 is broken. The link from /index.php?q=/modules/System%20Admin/thirdPartySettings.php opens https://gibbonedu.org/support/administrators/authenticating-with-google-oauth/. I believe the correct URL is https://gibbonedu.org/support/administrators/installing-gibbon/authenticating-with-google-oauth/.

Also, the instructions are a little dated. If I succeed, I’d be happy to help update them. But there is one piece that I cannot find in the Google developer console. After creating the Client ID, the instructions guide you through creating a key for Public API Access. I was not sure how to do that in the current Google developer console. If this is no longer necessary, great, but since I am having trouble, I wondered if I was missing something.

But I have the following problem. If I try to log in using an email address that is in Gibbon, the Log in with Google sends me through the usual steps (entering my Google credentials, accepting that Gibbon will see my information), but then it redirects back to ./index.php# and gives me HTTP ERROR 500. I then tested with an address that was NOT in the system, and it redirects back to /index.php?loginReturn=fail8#. I assume this means that Google is handling the credentials correctly and Gibbon is talking with Google enough to decide whether the user is in the system. But then users who should be logged in are not. I am not sure what I am doing wrong. Any ideas?

PS: I was not sure about the Public API Access, so I created an API Key in the same project. Login fails whether or not I have the key in the Google Developers Developer Key field in Gibbon.

David,

Thanks for the heads up on the broken link…but someone else ninja’d you, and it is already fixed in v13 ; ) Appreciate the report all the same!

The Google integration is great (once it is up and running), especially as it allows your Google Calendar to be displayed within your timetable. The Login With Google part was actually coded up by @george.

As you note, the instructions are unfortunately out of date…although last time I tried them, I was able to make them work. Appreciate your offer of helping to improve them if/when you get it working.

In order to assist troubleshooting, are you using Gibbon v12 or v13? If v12, can you do a test install with v13, and see if you get the same issue? We have done some work on v13 with the Google libraries, and that may help. If not, we can then dig in.

In terms of the 500 error, you could always dig into your web server log to see if you can get any more information.

Cheers,

Ross

Ah, yes. Error logs can be so helpful… I checked, and the problem was that the Calendar API was not enabled. Problem solved. Thanks, Ross.

Glad someone else caught the link problem.

David,

Excellent news, thanks! Was that part of the user guide that you overlooked? I see it is text only, and not in the screenshot. To be honest, the guide is a bit of a mess with some image alignment issues (that I’ll fix now), and as you noted some out of date images.

If you want to create some new images, feel free to send them over and I can get them into the guide. Same with text!

Ross

David,

Excellent news, thanks! Was that part of the user guide that you overlooked? I see it is text only, and not in the screenshot. To be honest, the guide is a bit of a mess with some image alignment issues (that I’ll fix now), and as you noted some out of date images.

If you want to create some new images, feel free to send them over and I can get them into the guide. Same with text!

Ross

Ross,

Here are some images, with a few notes. I am numbering the steps the same as your latest instructions.

  1. Create Project

  2. Project Name

  3. [This step is no longer necessary because the Credentials tab appears already after step 3.]

  4. Credentials tab

Create credentials

  1. Choose OAuth2 Client ID

  2. If you have not already configured the consent screen, at this point you will be required to do so:

Fill in the details for the Product Name and click Save.

Create Client ID (cannot have trailing “/”)

After this is complete, the client id details will be given to you:

(Save this for step 11)

  1. I am not sure if the Google Developers Developer Key is really necessary. I created one using this screen:

API Key Created:

(Save this for step 11)

  1. [Unless I am mistaken, this step is obsolete.]

  2. Leave the Key Restriction blank

  3. Enter your authentication settings in Gibbon in Home > System Admin > Third Party Settings.

Use details from steps 7-8 or click on the Credentials tab:

For the following use:
Google Developers Client Name = Blue
Google Developers Client ID = Yellow
Google Developers Client Secret = Red
Google Developers Redirect Url = Green

Google Developers Developer Key = Yellow

  1. Click on Library tab for APIs.

Enable:

  • Google+ API
  • Google+ Domains API
  • Calendar API

For example:

  1. See step 7.

  2. Okay.

  3. Okay.

  4. This is now in a new location in Gibbon: Home > System Admin > Third Party Settings.

Sorry, Ross, I was focusing on images since that took the most time. But I made a few notes above to clarify some of the terminology and to suggest revisions.

Oh, and I am not sure why the two graphics appear at the bottom (and I am not sure how to edit them). You can just ignore them because I created updated images in place above.

David,

This is awesome, thanks : ) If I was to give you a login to the site, would you be willing to update the article directly? I know I am pushing my luck here, but worth a try ; )

Thanks,

Ross

That might be easier. Please do send a login.

I can help elsewhere with keeping documentation updated as well, if that would be helpful.

I have been using the documentation (which on the whole is very helpful!), but sometimes I have to root around to find how to do things. I cannot really code, but I can write.

David,

That is very kind of you. Welcome aboard! You’ll get an email in a few minutes with editing rights, so feel free to get stuck in. See how you get on…longer term I am looking for someone to lead on documentation…there might even be a free Gibbon tshirt in it ; )

The site is WordPress based, so should be fairly easy to work out, but let me know if you get stuck.

Cheers,

Ross

Okay, so I finally updated the Google instructions. Sorry it took so long. Anybody looking for the instructions can go to https://gibbonedu.org/support/administrators/installing-gibbon/authenticating-with-google-oauth/.

I am not sure if I am reliable enough to lead on documentation, but I can contribute as I learn Gibbon.

The free tshirt would be fun, though.

Daniel,

Looks fantastic, thanks! I knew I was pushing my luck ont he documentation lead…but anything you can add would be appreciated. Email us your address on support@gibbonedu.org and we’ll sort you out with a sticker/tshirt pack (adult small or kids sizes only!).

Ross