Giter VIP home page Giter VIP logo

Comments (5)

tomscript avatar tomscript commented on June 16, 2024 1

for future folks who may see this, i hit this when querying the directory API trying list users. however the list users api requires a domain string be set

unfortunately the err doesn't tell you the field you're missing

from go-samples.

erickoledadevrel avatar erickoledadevrel commented on June 16, 2024

The quickstart uses user (3-legged) OAuth, not service accounts. Have you gotten that to work? When you use the special value "my_customer" for the customer ID, does that work?

from go-samples.

erkolson avatar erkolson commented on June 16, 2024

Thanks! I also get the same error when I used OAuth. When I paste the code from the web browser back in the terminal, I see this:

Saving credential file to: token.json
2018/09/19 13:25:29 Unable to retrieve users in domain: googleapi: Error 400: Bad Request, badRequest

When I use the "my_customer" value it says this:

Unable to retrieve users in domain: googleapi: Error 404: Domain not found., notFound

What is my_customer? I've read a good bit of the documentation and don't really understand how customers come into this.

from go-samples.

erickoledadevrel avatar erickoledadevrel commented on June 16, 2024

The value my_customer is a shortcut for referring to the G Suite organization you are a part of. Is the authorized user part of a G Suite domain, or is it a gmail.com account?

from go-samples.

erickoledadevrel avatar erickoledadevrel commented on June 16, 2024

Closing due to inactivity.

from go-samples.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.