validate method

Future<DecryptedInvoice> validate(
  1. String sdkId,
  2. String invoiceId,
  3. String scheme,
  4. String forcedValue,
)

Implementation

Future<DecryptedInvoice> validate(String sdkId, String invoiceId, String scheme, String forcedValue) async {
	final res = await _methodChannel.invokeMethod<String>(
		'InvoiceApi.validate',
		{
			"sdkId": sdkId,
			"invoiceId": jsonEncode(invoiceId),
			"scheme": jsonEncode(scheme),
			"forcedValue": jsonEncode(forcedValue),
		}
	);
	if (res == null) throw AssertionError("received null result from platform method validate");
	final parsedResJson = jsonDecode(res);
	return DecryptedInvoice.fromJSON(parsedResJson);
}