login method
Logs into the snap store.
Implementation
Future<SnapdLoginResponse> login(String email, String password,
{String? otp}) async {
var request = {'email': email, 'password': password};
if (otp != null) {
request['otp'] = otp;
}
var result = await _postSync('/v2/login', request);
return SnapdLoginResponse.fromJson(result);
}