We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hello,
it isn't quite clear from the docs that this library supports oAuth2 on behalf of other users (offline use).
The docs only show authentication with json credential file. But that way only works when accessing my own Google services.
It took me a long while and the help of Stackoverflow to figure out that this is how it works with oAuth2 tokens:
const analyticsAdminClient = new analyticsAdmin.AnalyticsAdminServiceClient( { credentials: { type: 'authorized_user', client_id: GOOGLE_CLIENT_ID, client_secret: GOOGLE_CLIENT_SECRET, refresh_token: refresh_token, access_token: access_token }} );
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hello,
it isn't quite clear from the docs that this library supports oAuth2 on behalf of other users (offline use).
The docs only show authentication with json credential file. But that way only works when accessing my own Google services.
It took me a long while and the help of Stackoverflow to figure out that this is how it works with oAuth2 tokens:
const analyticsAdminClient = new analyticsAdmin.AnalyticsAdminServiceClient( { credentials: { type: 'authorized_user', client_id: GOOGLE_CLIENT_ID, client_secret: GOOGLE_CLIENT_SECRET, refresh_token: refresh_token, access_token: access_token }} );
The text was updated successfully, but these errors were encountered: