getCurrentPrincipal()
Home > @gooddata/sdk-backend-spi > IAuthenticationProvider > getCurrentPrincipal
IAuthenticationProvider.getCurrentPrincipal() method
Returns the currently authenticated principal, or undefined if not authenticated. Does not trigger authentication if no principal is available.
Signature:
getCurrentPrincipal(context: IAuthenticationContext): Promise<IAuthenticatedPrincipal | null>;
Parameters
Parameter | Type | Description |
---|---|---|
context | IAuthenticationContext |
Returns:
Promise<IAuthenticatedPrincipal | null>