toMap method
Implementation
Map<String, dynamic> toMap() {
return {
'amount': amount,
'currency': currency,
'description': description,
'statement_descriptor': statementDescriptor,
'status': status,
'livemode': livemode,
'client_key': clientKey,
'created_at': createdAt.millisecondsSinceEpoch,
'updated_at': updatedAt.millisecondsSinceEpoch,
'last_payment_error': lastPaymentError,
'payment_method_allowed': paymentMethodAllowed,
'payments': payments,
'next_action': nextAction?.toMap(),
'payment_method_options': paymentMethodOptions.toMap(),
'metadata': metadata,
};
}