Google FIT API Unlink to Google API without the Account - google-fit

How to remove link of the application id to the google api that is tied to google fit?
I do not have the account that was use to to create the OAuth 2.0

Related

How do you access the Google Sheets API via a Google Apps Script?

I am trying to call the Google Sheets API via a Google Apps Script. As an example, I have followed the instructions provided here:
https://developers.google.com/sheets/api/quickstart/js
I have generated the client ID and API Key via my Google Cloud Platform project as suggested elsewhere.
Now, I have created a google apps script with two files, the Code.gs file and a file called index.html containing the code copied and pasted from the Google Sheets API Quickstart above (with my client ID and API inserted).
When testing deployment, I get the following error message:
{
"error": "idpiframe_initialization_failed",
"details": "Not a valid origin for the client: https://<some numbers>-script.googleusercontent.com has not been registered for client ID <MY_CLIENT_ID>. Please go to https://console.developers.google.com/ and register this origin for your project's client ID."
}
I have registered script.google.com as an origin for my project.
Am I doing something obviously wrong? How would I proceed from here to get past this error?
If you want to make use of the Sheets API in Apps Script you will have to make use of the Sheets Advanced Service.
For this you will have to go to Services + and then add the Google Sheets API:
Since this is an advanced service, the authorization flow will be handled by Google so you won't have to provide the clientId and the API key.
Reference
Apps Script Advanced Google Services.

Google Docs API as Google Apps Script "Advanced Google Service"

I know I can use the Google Docs API along with the UrlFetchApp service. But does anyone know if the Google Docs API will be available as an "Advanced Google Service" in Google Apps Script, if so, can you tell when this will happen?
I can't say for sure (I don't work at Google) but there are information channels you can monitor for news and product updates related to Google Apps Script and GSuite products:
Google Apps Script Release Notes
What's New in GSuite
GSuite Updates
Besides, "Advanced Services" are just wrappers for their respective APIs and their main purpose is to provide code completion. Under the hood, you consume the same resources as you would if you called the API directly via UrlFetch (this includes usage quotas).
If you're up to the task you can write your own implementation based on the discovery docs available for the Google Docs API.

Buying more quota in GCP for Google Apps Script quota

I'm facing quota limits of sending mails via Google Apps Script. The limit is 100 a day. I called the support center, but they say the script is out of the scope of Google Apps Service.
They told me I could buy more quota at GCP (Google Cloud Platform), now my question: Do I have to code new scripts on the GCP, or can I somehow connect the Google Apps Script (which is part of Drive and Apps I guess) with GCP?
I'm not sure if you can link both projects, however, I think Apps script email service would still be limited by it's own quotas.
A possible workaround would be to call the Gmail API directly instead of using the Apps script Gmailapp service.
To call the API you can use the "UrlFetchApp.fetch()" to make the call to the Gmail send endpoint.
To be able to make the call to the Gmail API, you will have to enable it in the developer console, for this in your script go to "Resources -> Advanced Google Services". There you will enable the Gmail API, then you have to click on the link that says "These services must also be enabled in the Google Developers Console."
It will take you to the Developer Console of your Appscript project, there you also have to enable the Gmail API.
The quota for UrlFetch is 20k calls/day, so in this case you would be limited by this quota and the Gmail API quota.

Use Adwords API (MccApp) in Google Apps Script

I have a custom API written in GAS (Google Apps Script) and would like to utilize the Adwords API from within it.
Sometimes used along with the MccApp, the service is readily available from within Adwords Scripts itself (My Client Center > Scripts).
For Example:
function account(client) {
var result = {
'id': null,
'campaigns': {}
}
result.id = client.getCustomerId()
var currentAct = AdWordsApp.currentAccount()
MccApp.select(client)
var campaignIterator = AdWordsApp.campaigns().get()
while (campaignIterator.hasNext()) {
var campaign = campaignIterator.next()
result.campaigns[campaign.getName()] = campaign.getId()
}
MccApp.select(currentAct)
return result
}
However, this API is not readily available inside a Google Apps Script. I have tried enabling it under "Resources > Advanced Google Services" and also under the developer console, but the UI offers no option that I can see.
QUESTION: Is it possible to enable use of the AdwordsApp and MccApp inside a Google Apps script so that the above code snippet would work in GAS?
If not, I understand already there are two workarounds:
Just use Adwords Script
Communicate with the API from GAS as though it were an external service (i.e... using SOAP, REST, etc...)
After much research, there really is no way to add the MccApp and AdwordsApp services for use in a Google Apps script. The nearest solution is to communicate with the API as though it were external or just use an Adwords Script.
It looks like you might be able to get to the AdWord API through the Management API:
See the Conceptual Overview section:
AdWords Links can be constructed at the Web Property level.
Google Developer Guide - What Is The Management API - Overview
and you can get to the Management API with the Google Analytics API.
Quote:
The Analytics service allows you to use the Google Analytics
Management API and Reporting APIs in Apps Script
Google Documentation - Google Analytics API
So, you need to use the RESOURCES menu, Choose, ADVANCED GOOGLE SERVICES, and then turn the Google Analytics API on.
With the Google Analytics API, you can access the Management API.

Can a google marketplace app integrate with the google Drive UI?

So I'm developing a Google Marketplace application for my company. In addition to several other features, my boss wants the app to be able to integrate with the Google Drive UI (eg be able to open files from the UI using the app). Now I understand that it's quite possible to use the Google Drive API to pull information from Drive to our Marketplace app, but is it actually possible for a Marketplace App to integrate with the Drive UI, for instance in the manner described above?
Yes, it is possible and there are many apps on market place that uses Drive UI to create or open file such as Docusign, draw.io, and gantter.
Please take a look at this GDL about integrating Drive API with Google Apps Marketplace. This will give you basic idea of how to use Dirve API with Google Apps Marketplace.
Also, take a look at documentation about Drive UI.