@acceleratxr/core_sdk / IOAuth2Service
Interface: IOAuth2Service#
Hierarchy#
IOAuth2Service
Implemented by#
Index#
Methods#
Methods#
authenticate#
▸ authenticate(code: string, verifier?: undefined | string, callbackURL?: undefined | string): Promise<AuthToken | undefined>
Defined in src/services/IOAuth2Service.ts:14
Authenticates the user using a provided Facebook access token and returns a JSON Web Token access token to be used with future API requests.
Parameters:#
Name |
Type |
Description |
|---|---|---|
|
string |
The OAuth 2.0 access token. |
|
undefined | string |
- |
|
undefined | string |
The optional callback URL that was used to generate the access token. |
Returns: Promise<AuthToken | undefined>
connect#
▸ connect(code: string, verifier?: undefined | string, callbackURL?: undefined | string, force?: undefined | false | true): Promise<void>
Defined in src/services/IOAuth2Service.ts:24
Authenticates the user using a provided Facebook access token and returns a JSON Web Token access token to be used with future API requests.
Parameters:#
Name |
Type |
Description |
|---|---|---|
|
string |
The OAuth 2.0 access token. |
|
undefined | string |
- |
|
undefined | string |
The optional callback URL that was used to generate the access token. |
|
undefined | false | true |
Set to |
Returns: Promise<void>
requestAuth#
▸ requestAuth(callbackURL?: undefined | string): Promise<string>
Defined in src/services/IOAuth2Service.ts:31
Initiates an authorization request from the OAuth 2.0 API when PKCE is required. The result is the authorization URL that the client must call in order to receive an auth token. Use this method when PKCE is required by the OAuth provider.
Parameters:#
Name |
Type |
|---|---|
|
undefined | string |
Returns: Promise<string>