fteam_authentication_core 1.0.0 fteam_authentication_core: ^1.0.0 copied to clipboard
FTeam auth Core
fteam_authentication_core #
Install #
Add in your pubspec.yaml
dependencies:
fteam_authentication_core:
hosted:
name: fteam_authentication_core
url: http://165.22.8.0:8080
version: ^0.0.7
Dependency #
You need implement a AuthDatasource
and register with method IAtecAuth.registerAuthDatasource
.
class MyDatasource implements AuthDatasource {
...
}
...
IAtecAuth.registerAuthDatasource(MyDatasource());
OR use fteam_authentication_firebase package;
Usage #
import 'package:fteam_authentication_core/fteam_authentication_core.dart'
...
final result = await FTeamAuth.login(ProviderLogin.google);
result.fold((error){
dispachError(error);
}, (user){
print(user);
});
Methods | Return Success | Return Error |
---|---|---|
login | LoggedUser | AuthFailure |
logout | Unit | LogoutFailure |
getLoggedUser | LoggedUser | AuthFailure |
deleteAccount | Unit | AuthFailure |
linkAccount | LoggedUser | AuthFailure |
sendEmalVerification | Unit | AuthFailure |
signupWithEmail | LoggedUser | AuthFailure |