user3269799
user3269799

Reputation: 33

How to set up a service account for Google Apps API

Inorder to manage google apps using API, iam working with admin-cmdline-sample client project, which i downloaded from admin sdk. Now i am able to connect to the Google apps cloud and manage user features. The problem that i am facing now is that in the process of authorization code flow to get the access token, iam getting redirected to the login page if the emailId that i passed in the code is not already there in the credential store. so is there any mechanism in which i can pass the password in the client code itself so that i wont be redirected to the login page. I found some related post, which recommend to setup service account. I tried that as mentioned in "https://developers.google.com/console/help/new/#serviceaccounts", but i am not able to find generate certificate and download private key links. Currently iam using a free subscription plan,is there any alternative way to generate certificate and download private key for free subscribers or is it possible for paid subscribers only

Upvotes: 0

Views: 875

Answers (1)

Orlando Herrera
Orlando Herrera

Reputation: 3531

I hope this can help you.

  1. You can create a Service Account with a free subscription or a paid subscriber.
  2. Log in with your Google Account.
  3. Visit the Google developer console. (click here)
  4. Create a new project.

When your project is created:

  1. Click on the "APIs" tab.
  2. Turn on the apis that you need.

After that, you will see something like this picture. Click on the "Create new client ID" buttton and choose "service account". After that, your private key (.p12 file) will be downloaded and you will have:

  • A Client ID
  • An Email Adress
  • A Public key fingerprint

You can generate new Keys and download a JSON file.

Creating a service account

You can read more information about the Google developer console here

Upvotes: 1

Related Questions