Home > @firebase/auth > OAuthCredential
OAuthCredential class
Represents the OAuth credentials returned by an OAuthProvider.
Signature:
export declare class OAuthCredential extends AuthCredential
Extends: AuthCredential
Description
Implementations specify the details about each auth provider's credential requirements.
Properties
| Property | Modifiers | Type | Description |
|---|---|---|---|
| accessToken? | string | (Optional) The OAuth access token associated with the credential if it belongs to an OAuthProvider, such as facebook.com, twitter.com, etc. |
|
| idToken? | string | (Optional) The OAuth ID token associated with the credential if it belongs to an OIDC provider, such as google.com. |
|
| secret? | string | (Optional) The OAuth access token secret associated with the credential if it belongs to an OAuth 1.0 provider, such as twitter.com. |
Methods
| Method | Modifiers | Description |
|---|---|---|
| fromJSON(json) | static |
Static method to deserialize a JSON representation of an object into an AuthCredential. |
| toJSON() | Returns a JSON-serializable representation of this object. |