Questions tagged [google-admin-sdk]

Use for questions about using APIs and services that are part of the Google (G Suite) Admin SDK, platform for developers that write applications to manage G Suite domains, migrate from and integrate with existing IT infrastructure, create users, update settings, audit activity, and more.

About

The Google (G Suite) Admin SDK allows developers to write applications to manage Google Apps domains, migrate from and integrate with existing IT infrastructure, create users, update settings, audit activity, and more.

Use for questions

About APIs and services that are part of the G Suite Admin SDK

Do not use for questions

About general interaction with Google APIs, use instead.

Admin SDK APIs

: Admin Settings API
: Alert Center API
: Directory API
: Domain Shared Contacts API
: Email Audit API
: Enterprise License Manager API
: Groups Migration API
: Groups Settings API
: GSuite Email Audit API
: GSuite Reseller API (former Enterprise Apps Reseller API)
: Reports API

Deprecated APIs

  1. Email Migration API on November 1, 2015
  2. Email Settings API on October 16, 2019
1554 questions
3
votes
1 answer

Google Admin SDK authentication with service account

My team is currently developing an application to list my company's domain users in GCP, using the Admin SDK, for onboarding and offboarding purposes. We're using a service account to do this and we've have added the admin.directory.user.readonly…
3
votes
1 answer

Adding Group using Google Admin Directory API - 403 Not Authorized to Access this Resource/API

I'm trying to add a Group using the Google Admin Directory API, from a Java app that's running on Google App Engine. I've looked at numerous other related questions on SO and tried the suggestions however I'm still getting the issue. I've created a…
3
votes
1 answer

How to add Admin SDK api to android project

I am currently working in an Android application that requires to have Admin and regular users. To illustrate, the admin has the ability to manage the regular users like delete , modify their contents. According to my reserch that firebase provide…
3
votes
2 answers

Google API: How to increase access token expiration date?

Google API expiration date is 1 hour, the problem is that I'm using the API in order allow users to use admin SDK features (List groups, add members to a group etc.) No one can do any of that in one hour, that would require users to login to their…
3
votes
1 answer

Accessing G Suite Admin SDK using service account

I am trying to use a service account to access Directory API (https://developers.google.com/admin-sdk/directory/v1/reference/users/list). The simplest task is to list users in the organization. That works well with my user account, tested with the…
3
votes
2 answers

Get users by Department from Admin Directory API using Google Apps Script

I have the following (mostly) working script using the Admin Directory API. However, rather than pulling the entire domain - I would like to just pull the information for a specific department. function listAllUsers() { var ss =…
Moonie
  • 33
  • 1
  • 5
3
votes
2 answers

PrivateKey Upload to Audit Email Api failing with EncryptionPublicKeyInvalidFormat

I'm accessing the Google Email Audit API (https://developers.google.com/admin-sdk/email-audit/auth#uploading_the_public_key) via NodeJS and simple POST requests. The authentication obviously works fine, I'm using it already for Signatures and User…
3
votes
0 answers

Issue adding members to @googlegroups.com with Google Apps Scripts

I am having an issue creating an automation script with Google Apps script. My function is: function addToGroup(email, group) { // Create a user with membership access var user = { email: email, role: 'MEMBER' }; …
3
votes
3 answers

Is it possible to get all users from the same Google Apps domain?

I need to implement the following scenario: A user signs in with his or her Google credentials. Thereafter my application checks whether or not this user is using Google Apps. If he or she is, my application reads all active users in the same…
3
votes
1 answer

Google admin directory insert user

I am trying to insert a user account through this api using gem 'google-api-client 0.11.1'. I have done the following: Enabled API access Enabled service account domain wide delegation Authorized the scope urls for this service account's client…
3
votes
1 answer

Google Admin SDK > Directory API > User > LastLoginTime inconsistent

I've written a program that's been in use for a couple of years. Using the API described at https://developers.google.com/admin-sdk/directory/v1/reference/users/list, it simply pulls a list of all users in our Google Apps domain and spits the list…
sheppe
  • 708
  • 5
  • 12
3
votes
2 answers

Variable dump shows data but returns as undefined

Hopefully this is a "DOH" moment but I can't figure out why this is happening. I am using a service object to get the members of a group in Google's Directory API. After creating the service object I used the following lines to test
3
votes
3 answers

Google Admin SDK - Service account can't access resource

I've created Service Account client via console.developers.google.com. Generated keys, .p12 cert, enabled DwD, and so ... Then I've continued as describer in Admin API references. (HTTP/REST version). That included asingning scopes to these clients…
Obikson
  • 156
  • 1
  • 9
3
votes
1 answer

How do I use service acct with google's directory API in Coldfusion

I have been trying to create a script to use a service acct with Google's Directory API and having no luck. So far I have: -Downloaded the Admin Directory JAR Files from here and put them all in my WEB-INF/lib dir -Created a service acct according…
3
votes
0 answers

Multiple space-delimited Google Admin SDK scopes causing invalid_scope error

NOTE - Since I am new to StackOverflow and only permitted two links, I've had to modify my URL snippets below and use backslashes after the https: since the editor thinks I'm writing URLs. I have successfully accessed our G Suite Admin SDK directory…
EricN
  • 31
  • 1