feat(facebook): add FacebookLoginResponse interface

This commit is contained in:
Ibby Hadeed 2016-07-20 07:10:01 -04:00
parent 979838f4b7
commit 8b27bed4df

View File

@ -113,10 +113,10 @@ export class Facebook {
* ```
*
* @param {string[]} permissions List of [permissions](https://developers.facebook.com/docs/facebook-login/permissions) this app has upon logging in.
* @return Returns a Promise that resolves with a status object if login succeeds, and rejects if login fails.
* @return {Promise<FacebookLoginResponse>} Returns a Promise that resolves with a status object if login succeeds, and rejects if login fails.
*/
@Cordova()
static login(permissions: string[]): Promise<any> { return; }
static login(permissions: string[]): Promise<FacebookLoginResponse> { return; }
/**
* Logout of Facebook.
@ -246,3 +246,14 @@ export class Facebook {
picture: string
}): Promise<any> { return; }
}
export interface FacebookLoginResponse {
status: string;
authResponse: {
session_key: boolean;
accessToken: string;
expiresIn: number;
sig: string;
secret: string;
userID: string;
};
}