virgil_sdk.jwt.providers.callback_jwt_provider module

class virgil_sdk.jwt.providers.callback_jwt_provider.CallbackJwtProvider(get_token_callback)[source]

Bases: virgil_sdk.jwt.abstractions.access_token_provider.AccessTokenProvider

The CallbackJwtProvider class provides an opportunity to get access token using callback mechanism.

get_token(token_context)[source]

Gets access token by provided callback.

Parameters

token_context – Access token context.

Returns

Instance of access token.

Raises

ValueError – Token context empty.