Constructs a new instance of the IDM client with the provided client options.
The options to configure the IDM client.
None
Clears the session data by setting it to null and cleaning specific keys from storage. If logging is not disabled, a debug message is logged.
A promise that resolves once the data is cleared.
Retrieves external providers from storage and parses them into a FederationProvidersResponse object.
A Promise that resolves to the external providers stored in the storage or null if no providers are found.
Asynchronously retrieves the public key from storage.
The public key if found, otherwise null.
Retrieves the renewal token from the session data or storage. If the renewal token is already present in the session data, it is returned. Otherwise, it is retrieved from storage and stored in the session data for future use.
The renewal token.
Retrieves the resources token from the session data or storage. If the token is already present in the session data, it returns that token. Otherwise, it retrieves the token from storage and stores it in the session data for future use.
The resources token.
Retrieves the token from the session data or storage if not already present.
The token value.
Asynchronously retrieves user data from storage.
A promise that resolves to the user data retrieved from storage.
Retrieves the user object asynchronously. If the user object is already present in the session data, it returns the user object. Otherwise, it fetches the user data, updates the session data with the user data, and returns the user object.
A promise that resolves to the user object.
Saves the external providers data to the storage.
The external providers data to be saved.
A promise that resolves once the data is saved.
Saves the public key to the storage with the specified expiration time.
The public key to be saved.
A promise that resolves once the public key is saved.
Saves the session data to local storage along with necessary tokens and metadata.
The session data to be saved.
Represents a Persistent Session class that manages session data using cookies.