Setting Up Google+ Sign-in

As previously mentioned, we now want our CoffeeMate App to interact with a sister Web App (CoffeeMateWeb) so we need Google+ Sign-in support to allow us to connect to the Web App and Add/Edit/Delete/View Coffees stored on the Server.

What we want is something like this:

The user launches the app and (after a Splash Screen) is prompted to login, like so

If the user hasn't previously logged in, they will be asked to choose an existing Account, or add a different account (that's what we'll do here)

The user is then prompted for their Google credentials

and then the app asked for certain permissions

The additional account can now be chosen as the active Google account in the app

and we can display the users Google Profile pic, and email in the Navigation Drawer like so


Before you can start integrating Google+ features in your own app, you must create a Google Developers Console project and initialize the GoogleApiClient within your app.

Step 1: Add Google Sign-In

Before you begin using Google+ in your Android app, follow all of the steps to Start Integrating Google Sign-In into your Android App.

Step 2: Enable the Google+ API

If you followed the steps above to add Google Sign-In to your app, you have already created a project in Google Developers Console. Now enable the Google+ API for that project to access Google+ features.

  • Go to the <Google Developers Console APIs library.
  • From the project drop-down, select the project you previously created.
  • In the list of Google APIs, search for the Google+ API service.
  • Select Google+ API from the results list.
  • Select Enable API.

When the process completes, Google+ API appears in the list of enabled APIs. To access, select API Manager on the left sidebar menu, then select the Enabled APIs tab.

results matching ""

    No results matching ""