addEvent method
Implementation
Future<void> addEvent({
required String eventName,
required EventType eventType,
Map<String, dynamic>? eventData,
}) async {
final user = sdkDataPersistenceService.currentUser();
if (user != null) {
final request = AddEventRequest(
email: user.email,
eventName: eventName,
eventType: eventType,
eventData: eventData,
);
await network.addEvent(request: request);
} else {
throw const NoUserFoundException(
'No User founded please call createUser First');
}
}