callAuthenticate method

Future<APIAuthentication?> callAuthenticate(
  1. String email,
  2. String password
)

Implementation

Future<APIAuthentication?> callAuthenticate(
    String email, String password) async {
  var auth = await call(APIRequest.get('/authenticate',
      parameters: {'email': email, 'password': password}));
  if (auth.isNotOK) return null;

  var authentication = APIAuthentication.fromJson(auth.payload);
  return authentication;
}