Google Directory API: Credentials for managing groups - google-admin-sdk

I'm attempting to create a group and add members.
https://developers.google.com/admin-sdk/directory/v1/guides/manage-groups
Which leads to
https://developers.google.com/admin-sdk/directory/v1/guides/authorizing
Which says:
"2. Activate the Directory API in the Google Developers Console. (If the API isn't listed in the Developers Console, then skip this step.)"
Question one is: There's no Directory API in the Console, and when I click on "Credentials", there's a popup that says "Enable the APIs you plan to use"; what to do?
Question two: Creating/Listing a group seems like it should be doable using a server api instead of OAuth? I tried creating a group using the server key from a different project (just for testing) through the oauthplayground (because it seemed like the only place I could see what's going on), and ended up with a 404 "Domain not found." error. In the Console, under Credentials, there is "Domain Verification", but that talks about using Web Hooks, which doesn't seem to apply here...what am I missing?
Thanks!
EDIT Upon further investigation, I've learned a couple of things:
1) As far as I can tell, the relevant API for this is "Admin SDK", however;
2) This all requires Google Apps for Work -- it doesn't apply to the "public" Google Groups, so seems like I am basically out of luck for doing this via API.

Related

Stuck on complying with domain verification requirements

Recently I have been trying to re-boot my app. This includes adding google play services to my app.
I setup a google cloud platform account and then linked it with the developer console for my app.
Next I setup the OAuth consent screen. After completing everything it asked me to verify my website and domain; I completed this step with the google search API.
Despite all of these efforts I still got the error, Pending developer action.
Here is my verified domain (blurred out for obvious reasons):
After observing the documentation a little bit more, it tells me that I must continue/reply to the email thread with their Trust and Safety team, but I have not received any emails from them with my developer email -
Thanks in advance
-James
I have actually found the solution to this problem, and I think I can safely say that this is due to human error every single time.
When linking your google play app in the developer console to google cloud it might automatically create one for you, but if you reload the page it will make a second one. You have to make sure you select the right google cloud app to link because it might not properly connect if you use the wrong one.
Once you have done this you need to create a website or link a website that has been verified (you can verify it yourself) with google. You should then be able to setup your app easily! Not every step will be instant you might sometimes have to wait a day or two for it to work.

How to configure custom domain for Google Cloud Functions for rendering HTML

So I have deployed a Google Cloud Function to some place like this:
https://us-central1-my-project.cloudfunctions.net/my-function
I can successfully render a dynamic webpage like this:
https://us-central1-my-project.cloudfunctions.net/my-function?slug=foo
Now, I would like to put this behind a regular URL so it works like this:
https://my-domain.com/some-directory/foo
I would like for it to be https instead of http. And notice that I added some-directory above the foo slug, so there is a little bit of rewriting logic there.
So basically go from here to here:
https://us-central1-my-project.cloudfunctions.net/my-function?slug=foo
https://my-domain.com/some-directory/foo
The question is how to do this. Wondering if you could walk me through how to do it which I think would also help future googlers.
When I search "custom domain for google cloud function" I get this which is for "endpoints" or "openapi" or I don't know, but it doesn't quite seem related. However, I went ahead anyways and changed my DNS nameservers to match what they said:
A 198.51.100.0
A 198.51.100.2
A 198.51.100.4
A 198.51.100.6
AAAA 2001:db8:ffff:32::15
AAAA 2001:db8:ffff:34::15
AAAA 2001:db8:ffff:36::15
AAAA 2001:db8:ffff:38::15
But I am lost as to what to do next. The documentation for Google Cloud is nothing compared to AWS which is unfortunate.
This is as close to what I've found so far, but it's still not even close to getting it working. Maybe this is closer to what I want.
Actually, is possible using Endpoints for cloud functions:
https://cloud.google.com/endpoints/docs/openapi/get-started-cloud-functions
After you have running your API or function in Cloud Run you just need to do a mapping with your custom domain (https://cloud.google.com/run/docs/mapping-custom-domains) and redeploy the OpenApi specification with the new host.
This is not possible using Google Cloud Functions deployed in a GCP project.
Currently, the only way to map a custom domain to your HTTP/S triggered functions is by using Firebase Functions and Firebase Hosting.
After creating the custom domain, you can configure the domain to handle HTTPS/S triggered functions.

How to search for Shiny Apps - Rstudio

I'm entering the world of Shiny Rstudio now. So this is a beginner question
One question I came up with is: how do I search for the Shiny Apps available/created? Are all created Apps available? Is there any way that, once I create my app, I prevent it from being viewed? Or during the creation I "block it"?
From so much searching I found this link via Rstudio's website: http://www.showmeshiny.com/
Would this be the search platform for all apps made?
But in the case of http://www.showmeshiny.com/ it seems that it is necessary to send it via "Submit App".
I am not sure if I understand your questions correctly but I might be able to give you some insights.
Are all created Apps available?
No, some shiny Apps are hosted on private servers or/and are embedded in password-protected websites or Wordpress-pages for example. If you dont have those access rights, then you cannot see those Apps.
How do I search for the Shiny Apps available/created?
There is no way of doing that, except on pages like Showmeshiny, the RStudio Shiny Gallery, this gallery of recent Shiny-Apps or pther similar pages. Those Apps are publicly available and you can submit your own App if you like sharing it. Shinyapps.io is a nice and easy way of deploying your App on a server with a few clicks. But you need at least the standard license to include authentication, otherwise they would be free and open for everyone.
Is there any way that, once I create my app, I prevent it from being
viewed?
I am not quite sure, what you mean. If it should be blocked from being viewed at all, I dont see the reason of building a ShinyApp. If you just want to access it yourself, then there are ways of doing so. Either password-protect it where only you know the password or host it on a local server that only you can access.
Or during the creation I "block it"?
If you create it on your computer and run it, it will run on your computer and only be accessible to yourself, except you explicitly configure it otherwise. So there is no need of "blocking it".

I can't change the boot disk when I try to create a Google Cloud Instance

When I try to create a new instance for deep learning on Google Cloud Platform, by following various tutorials including http://cs231n.github.io/gce-tutorial/, I can't select a zone or boot disk (I'd like to use Ubuntu 16.04. There is no response when I click these features. How can I set them?
I've tried to reproduce this issue with various levels of authorisation in my own project and I've not been able to reproduce this issue. As you have access to the Create Instance page, It looks to like this might be a browser specific issue, rather than and issue with authorisation, or any settings within your project.
Would it be possible for you to try and perform this task from a different browser and see if the result is the same? For example, can you try this in Chrome browser and in an Incognito window?
If you are able to perform the action from a different browser, you probably have an issue with cookies, or a third-party browser add on affecting the functionality with GCP. You could try enabling the cookies for the browser to see if that makes a difference, or disabling/removing third party add ons to see if that makes a difference.

Django Allauth and Google

I've tried to add google login to my web application using django-allauth.
I added to my google application the following callback_uri:
"http://localhost:8000/accounts/google/login/callback"
since i'm running tests on my development server (localhost) and i don't wanna use https.
Even though, i get a 'redirect_uri_mismatch' saying that my redirect URI doesn't match any registred redirect URI.
Does anyone have any ideea about what causes this?
Thanks for your time.
Later Edit:
Using 127.0.0.1 instead of localhost solved this problem.
Recently I ran into problems trying to get Google+ to work as well. I finally got it working. I made some updates to the documentation so it's a bit easier to use. See if using the updated allauth google docs you can get it to work.
Have you try doing the following:
1. Go to the Google Developers console -> Api $ auth -> credentials
2. You should see "Client ID for web application" click "Edit Settings"
3. Change your "Redirect URI" to "http://localhost:8000/accounts/google/login/callback"
Should work after that let me know if it doesn't.
Cheers,
Dan