I need to automate some flow on google workspace, now I'm stuck at Activating Gmail via API, I couldn't find any resource or example anywhere.
Appreciate for any help pointing out the reference or answer.
Update:
So I have google workspace and I am working on automate user and their gmail account. From the screenshot I can simply click on "Activate Gmail" and it will check against my MX records and have it activated, but I'm looking for a solution where I can do it from google API using Ruby.
For this one, you will most likely make use of Directory API's users.update instead of Gmail API. Gmail API only enables you to access gmail settings and the emails, not the user settings.
Sadly, I haven't found any fields dedicated for activating/enabling Gmail. The closest thing I found was isMailboxSetup, but it only identifies if the user have its Gmail activated.
Indicates if the user's Google mailbox is created. This property is only applicable if the user has been assigned a Gmail license.
Given the circumstances above, you might need to do it manually. For more info regarding the subject, visit the reference below.
Reference:
Admin SDK: Directory API
I am trying to access Google play developer API https://developers.google.com/android-publisher/ to build an inapp purchase product for my company Application.
We have to get authorization to make a GET call to the Google play developer API. https://developers.google.com/android-publisher/api-ref/purchases/subscriptions/get
I followed the steps presented here. https://developers.google.com/android-publisher/authorization
Created an Oauth client and and also service account. The gmail account I used was part of the 'Users and permissions' in play.google.com console.
But when I tried to access the API, I got an error
As I started searching about this error, I understood that there is something else called 'API Access' in play.google.com. When I tried to access it, All I saw was
But I saw in other posts that there exists a screen with details like
https://i.stack.imgur.com/Hdjjy.png
So how can I go forward to access API. I did everything as mentioned in documentation of google but it didnt work. Also I dont have access to see the screen of 'API Access'.
Also I am confused, if you can create service accounts from both 'API Access' screen and also from 'credentials' screen in console.developers.com, which one should be used ?
Just to check you understand there are a few different APIs to do with in-app purchases.
Play billing library is designed to be used in your app. This is what allows users to buy things from your app
Configuring in app products. When your app supports in-app products you have to support what the products are and the prices. This is done via the Play console, either manually or in batches uploading CSV files.
Finally is the API you refer to in your question. This is not designed for use in your app, and you don't have to use it to support in-app products. Instead this API allows your server (not app) to validate a user's purchase. In order to use this API, you need to enable the "API access" in the page you found. This can only be enabled by the account owner for the Play console, for security reasons. You will need to find the Owner of your Google Play account, and get them to log in and create a service account which has API access.
I am able to access it now. I am not the owner of the Google Play console.That was the issue. You just have to go to API Access page and click on "create OAuth Client" or "create Service Account ".
You can use those credentials to access API from postman or through your code.
I am trying to create a connector for Google spreadsheet. So that I try to create an app in Google developer console, After that how can I get oauthConsumerkey and oauthConsumerSecret from it? Are there any links or guidance to explain it? videos or websites? I have refer some Google sites, But I'm unable to get clear information from it.
On The developer console (https://console.developers.google.com), click on Create Project.
Click on APIs & auth on the left hand side menu to enable APIs (this isn't required for spreadsheets)
A new button should appear in the left hand side menu 'Credentials'
Click on Create new Client ID
This will provide you with the ClientID, Client Secret and Email Address. Set Redirect URIs and Javascript Origins as required by your application.
You will also need an API key, which is generated by clicking on the 'Create new Key' button beneath the OAuth section.
In order to allow users to login from your application, you can use http://www.accountchooser.com. Which is farely easy to use and allows for various identities.
I have created a developer account on Google in order to publish an android app on Google Play. After some time I needed GCM, but I cant be able to get a API key. I am able to enter developer console, but when I try to create a new project I get an error as following:
ERROR
Developers Console has not been activated for your account. Your account may be suspended or disabled. If you are a Google Apps user, ask your domain administrator to enable Apphosting Admin on your account.
I have been sent no email about if my account was banned or not. I have posted an email to google support but they did not respond yet(not sure if they care). What should I do? How to find why I am banned from creating a project on Developer Console.
When I try to access some pages I have been redirected to this error page. This is where I have sent email.
From [here][1]:
Go into your domain administration # https://admin.google.com/AdminHome
Click the "More controls" link at the bottom the page
Within the panel that reveals, click "More Google Apps"
Select checkbox for "Google Developers Console" (hexagon nut logo)
In the top-left you will see an icon to "Turn ON services"
Confirm your choice
Apparently Google has changed the flow since this was answered.
I had to:
1) Go to this page via App Settings > Additional Google Services
https://admin.google.com/AdminHome#AppsList:serviceType=ADDITIONAL
2) Look for the "Develop applications using Google APIs and the Google Cloud Platform" setting
3) Click the vertical ... in the right hand corner of the row and select "ON for everyone"
Make sure you are logged in with the Admin account for your domain. If you are redirected to "https://apps.google.com/user/hub" then you are not an admin.
Enable Google Developer Console for G Suite (Google Apps)
admin.google.com
Select: Apps (Manage apps and their settings)
Select: Additional Google services (Blogging, photos, ...)
(bottom right corner you'll find Page 1 of 6, switch pages to locate Google Developers Console)
Check: Google Developers Console and select ON in top right corner
Confirm with TURN ON
You should ask your domain administrator to enable Apphosting Admin on your account.
I am working on Google API like chat, contacts and so on...
I am stuck on developer_key as mentioned in gdata doc.
You can get this at https://code.google.com/apis/console:
'developer_key' => ''
I have already:
// OAuth2 Settings, you can get these keys at https://code.google.com/apis/console
'oauth2_client_id' => '',
'oauth2_client_secret' => '',
'oauth2_redirect_uri' => ''
Where can I find developer key?
I found some thing like this
http://code.google.com/apis/youtube/dashboard/gwt/index.html
But I understand this to be only for youtube.
It's the API key as listed under 'API Access', the 'Simple API Access' box.
First activate Google+ API, then you will get "Simple API access" box, from there you can get
developer key as API key
https://code.google.com/apis/console/?api=plus
or read this: http://code.google.com/p/google-api-php-client/wiki/OAuth2
Update Nov 2015:
Sometime in late 2015, the Google Developers Console interface was overhauled again. For the new interface:
Select your project from the toolbar.
Open the "Gallery" using hamburger menu icon on the left side of the toolbar and select 'API Manager'.
Click 'Credentials' in the left-hand navigation.
Alternatively, you can click 'Switch to old console' under the the three-dot menu (right side of the toolbar), then follow the instructions below.
For the NEW (edit: OLD) Google Developers Console:
You get your 'Developer key' (a.k.a. API key) on the same screen where you get your client ID/secret. (This is the 'Credentials' screen, which can be found under 'APIs & auth' in the left nav.)
Below your client ID keys, there is a section titled 'Public API access'. If there are no keys in this this section, click 'Create new Key'. Your developer key is the 'API key' specified here.
Update no 3:
You can get a Developer_Key from here Get your Google Developer Key
Check this tutorial
{select as answered, if it answered.}
Update no 2:
"API key" is the DEVELOPER_KEY
if you check this code reference,
it states
Set DEVELOPER_KEY to the "API key" value from the "Access" tab of the Google APIs Console http://code.google.com/apis/console#access`
Wiki on step by step to get API Key & secret
Update:
Developer API Key! probably this is what you might be looking for
http://code.garyjones.co.uk/google-developer-api-key
OR
If say, for instance, you have a web app which would require a API key then check this:
Go to Google API Console Select you project OR Create your project.
Select APIs & Auths
API Project from the Dropdown on the left navigation panel
API Access
Click on Create another Client ID
Select Service application refer it here
The Service application that you have created can be used by your Web apps such as PHP, Python, ..., etc.
2017 Update
Open Google API - https://console.developers.google.com
Go to Credentials.
Click on the 'Create Credentials' button. At time of writing it's currently a blue coloured dropdown.
Select API Key.
You should get a dialog from where you can copy this API key to use in your project. Hope this helps.
In the old console layout :
Select your project
Select menu item "API access"
Go to the section below "Create another client ID", called "Simple API Access"
Choose one of the following options, depending on what kind of app you're creating (server side languages should use the first option - JS should use the second) :
Key for server apps (with IP locking)
Key for browser apps (with referers)
In the new cloud console layout :
Select your project
Choose menu item "APIs & auth"
Choose menu item "Registered app"
Register an app of type "web application"
Choose one of the following options, depending on what kind of app you're creating (server side languages should use the first option - JS should use the second) :
Key for server apps (with IP locking)
Key for browser apps (with referers)
In case of both procedures, you find your client ID and client secret at the same page. If you're using a different client ID and client secret, replace it with the ones you find here.
During my first experiments today, I've succesfully used the "Key for server apps" as a developer key for connecting with the "contacts", "userinfo" and "analytics" API. I did this using the PHP client.
Wading through the Google API docs certainly is a pain in the #$$... I hope this info will be useful to anyone.
Please use Google API console
Create a new project
For the created project goto API access
There you will find your Client ID and Secret.
And the API key in the last is your developer key.
Recent Update July 2017:
Go to Google Console
Click on Left most top panel and click credentials.
In the API keys table, you will find the API key in the key column.
API Key is your developer key.
Hit https://www.googleapis.com/webfonts/v1/webfonts?key= in your browser by enabling web fonts api and you will see result.
Refer this blog http://code.garyjones.co.uk/google-developer-api-key/ for more information
I explored the google docs and found that developer key and api is same thing.
in https://code.google.com/apis/console/ , in SERVICES, turn on YOUTUBE API, then click API ACCESS in the left menu.
"Public API access" the key generated there is the key you got to paste into your public static final String DEVELOPER_KEY as part of this writing 26.12.2013
It is not the clientID but you got take the steps mentioned above to obtain one and generate the public api access key.
Go to https://code.google.com/p/google-api-php-client/wiki/OAuth2
Scroll down to where it says 'Visit the Google API Console to generate your developer key, OAuth2 client id, OAuth2 client secret, and register your OAuth2 redirect uri. Copy their values since your will need to input them in your application.'
Click on the 'Google API Console' link.
When it pops up and says 'Welcome to the new Google Developers Console! Prefer the old console? Go back | Dismiss' Click on 'GO BACK'
If you are only calling APIs that do not require user data, such as
the Google Custom Search API, then API keys might be simpler to use
than OAuth 2.0 access tokens. However, if your application already
uses an OAuth 2.0 access token, then there is no need to generate an
API key as well. Google ignores passed API keys if a passed OAuth 2.0
access token is already associated with the corresponding project.
Note: You must use either an OAuth 2.0 access token or an API key for
all requests to Google APIs represented in the Google Developers
Console. Not all APIs require authorized calls. To learn whether
authorization is required for a specific call, see your API
documentation.
Reference: https://developers.google.com/console/help/new/?hl=en_US#credentials-access-security-and-identity
tl;dr
Developer Key = Api Key (any of yours)
find it in Google Console -> Google API -> Credentials
You should be able to generate a Youtube API key there.
The recommended way to authorize your API call is to use OAuth 2.0 (without API key), as pointed by the documentation an API key is only necessary when using OAuth 1.0 credentials.
The API key for your application can be found in the Google APIs Console in API Access > Simple API.