login method
Login with existing credentials.
Returns the AuthResponse. Check AuthResponse.success and AuthResponse.errorCode to determine the outcome:
| errorCode | Meaning |
|---|---|
| 0 | Success |
| 1 | User not found |
| 2 | Wrong credentials |
Implementation
Future<AuthResponse> login(String email, String password) async {
final request = LoginRequest()
..email = email
..password = password;
return await _stub.login(request);
}