getInsurance method
Implementation
Future<Insurance> getInsurance(String sdkId, String insuranceId) async {
final res = await _methodChannel.invokeMethod<String>(
'InsuranceApi.getInsurance',
{
"sdkId": sdkId,
"insuranceId": jsonEncode(insuranceId),
}
);
if (res == null) throw AssertionError("received null result from platform method getInsurance");
final parsedResJson = jsonDecode(res);
return Insurance.fromJSON(parsedResJson);
}