UNPKG

1.25 kBTypeScriptView Raw
1/**
2 * @name Google Plus
3 * @description
4 * @usage
5 * ```typescript
6 * import { GooglePlus } from 'ionic-native';
7 *
8 * GooglePlus.login()
9 * .then(res => console.log(res))
10 * .catch(err => console.error(err));
11 *
12 * ```
13 */
14export declare class GooglePlus {
15 /**
16 * The login function walks the user through the Google Auth process.
17 * @param options
18 * @returns {Promise<any>}
19 */
20 static login(options?: any): Promise<any>;
21 /**
22 * You can call trySilentLogin to check if they're already signed in to the app and sign them in silently if they are.
23 * @param options
24 * @returns {Promise<any>}
25 */
26 static trySilentLogin(options?: any): Promise<any>;
27 /**
28 * This will clear the OAuth2 token.
29 * @returns {Promise<any>}
30 */
31 static logout(): Promise<any>;
32 /**
33 * This will clear the OAuth2 token, forget which account was used to login, and disconnect that account from the app. This will require the user to allow the app access again next time they sign in. Be aware that this effect is not always instantaneous. It can take time to completely disconnect.
34 * @returns {Promise<any>}
35 */
36 static disconnect(): Promise<any>;
37}