OutboundPaymentDestinationPaymentMethodData.fromJson constructor
OutboundPaymentDestinationPaymentMethodData.fromJson(
- Object? json
Implementation
factory OutboundPaymentDestinationPaymentMethodData.fromJson(Object? json) {
final map = (json as Map).cast<String, Object?>();
return OutboundPaymentDestinationPaymentMethodData(
billingDetails: map['billing_details'] == null
? null
: PaymentIntentBillingDetails.fromJson(map['billing_details']),
financialAccount: map['financial_account'] == null
? null
: (map['financial_account'] as String),
metadata: map['metadata'] == null
? null
: (map['metadata'] as Map).cast<String, Object?>().map((
key,
value,
) =>
MapEntry(
key,
(value as String),
)),
type: OutboundPaymentsPaymentMethodDetailsType.fromJson(map['type']),
usBankAccount: map['us_bank_account'] == null
? null
: PaymentIntentUsBankAccount.fromJson(map['us_bank_account']),
);
}