tokenize method

Future<PEBankAccount> tokenize(
  1. String merchantId
)

Implementation

Future<PEBankAccount> tokenize(String merchantId) async {
  try {
    final jsonString = await formController.tokenize(merchantId);
    print(jsonString);
    final json = jsonDecode(jsonString);
    return PEBankAccount.fromJson(json);
  } catch (e) {
    print(e);
    throw Exception('Failed to tokenize bank account: $e');
  }
}