Function: exchangeServerAuthorizationCode()
ts
function exchangeServerAuthorizationCode(params): Promise<OAuth2TokenResponse>;Defined in: src/core/oauthServer/helpers.ts:113
Exchange the authorization code from the redirect callback for tokens.
Parameters
| Parameter | Type | Description |
|---|---|---|
params | { clientId: string; clientSecret: string; code: string; fetch?: FetchLike; host: string; redirectUri: string; } | - |
params.clientId | string | - |
params.clientSecret | string | - |
params.code | string | - |
params.fetch? | FetchLike | The fetch to reach the instance by. Defaults to the global one. |
params.host | string | - |
params.redirectUri | string | - |
Returns
Promise<OAuth2TokenResponse>