import { Injectable } from '@nestjs/common' import { Compute, GoogleAuth } from 'google-auth-library' import { JSONClient } from 'google-auth-library/build/src/auth/googleauth' @Injectable() export class GoogleClientService { async get(scopes: Array = []): Promise { const auth = new GoogleAuth({ scopes, credentials: { client_email: globalThis.secret.google_play_service_account.client_email, private_key: globalThis.secret.google_play_service_account.private_key, }, }) return await auth.getClient() } }