core.medplumclient.ensurecodechallenge | Medplum

MedplumClient.ensureCodeChallenge() method

Returns the PKCE code challenge and method. If the login request already includes a code challenge, it is returned. Otherwise, a new PKCE code challenge is generated.

Signature:

ensureCodeChallenge<T extends BaseLoginRequest>(loginRequest: T): Promise<T>;

Parameters

Parameter Type Description
loginRequest T The original login request.

Returns:

Promise

The PKCE code challenge and method.