helpers/auth/provider library

Classes

AuthProvider
Authentication provider base class. Should know how to login and to get user details. Also stores an endpoint for making calls.
AuthToken
Authentication token class. Should be subclasses to contain actual token data. It's a good idea to add a factory constructor AuthToken.fromJson to keep serialization and deserialization in one place.
UserDetails
A base class for user details. Override to add more, e.g. an avatar.

Exceptions / Errors

AuthException
An exception thrown when the authentication goes wrong. Please do not forget to provide a message.