create method
Create data R
along with P
Implementation
@override
Future<PaymentAttributesResponse> create(
CreatePaymentAttributes attributes,
) async {
final options = PayMongoOptions(
path: '/payments',
data: {
'attributes': attributes.toMap(),
},
);
final response = await _httpClient.post(options);
final json = serialize<Map<String, dynamic>>(response, options.path);
return PaymentAttributesResponse.fromMap(json);
}