initializeConfidentialSecretId method

Future<EncryptedPatient> initializeConfidentialSecretId(
  1. String sdkId,
  2. EncryptedPatient patient
)

Implementation

Future<EncryptedPatient> initializeConfidentialSecretId(String sdkId, EncryptedPatient patient) async {
	final res = await _methodChannel.invokeMethod<String>(
		'PatientApi.encrypted.initializeConfidentialSecretId',
		{
			"sdkId": sdkId,
			"patient": jsonEncode(EncryptedPatient.encode(patient)),
		}
	);
	if (res == null) throw AssertionError("received null result from platform method initializeConfidentialSecretId");
	final parsedResJson = jsonDecode(res);
	return EncryptedPatient.fromJSON(parsedResJson);
}