getProfileId static method
Gets the ID of the BlueConic profile asynchronously.
The profile ID uniquely identifies the current user's profile in BlueConic.
Returns: A Future<String> containing the profile ID.
Implementation
static Future<String> getProfileId() {
final Completer<String> completer = Completer<String>();
BlueConicPlatform.instance.getProfileId().then((result) {
if (result.success) {
completer.complete((result.data as String?) ?? '');
} else {
completer.completeError(Exception(result.error ?? 'Unknown error'));
}
});
return completer.future;
}