UNPKG

@xmobitea/gn-server

Version:

GearN Server by XmobiTea (Pro)

28 lines (27 loc) 926 B
import { IGoogleService } from "./IGoogleService"; export declare class GoogleService implements IGoogleService { private static readonly googleAPIUrl; private static readonly googleAPITokenInfoAccessTokenURL; private static readonly googleAPIUserInfoAccessTokenURL; private static readonly googleAPITokenInfoIdTokenURL; private googleClientId; private packageId; private publicKeyString; init(request: { googleClientId: string; packageId: string; publicRSAKey: string; }): void; verifyGoogleTokenViaAccessToken(accessToken: string): Promise<{ [k: string]: any; }>; verifyGoogleTokenViaIdToken(idToken: string): Promise<{ [k: string]: any; }>; validateReceipt(payload: string): Promise<{ success: boolean; productId?: string; }>; private androidValidationReceipt; private generateFormattedPublickey; }