diff --git a/pom.xml b/pom.xml index 9716d8d..dd37078 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ dev.vality service-parent-pom - 1.0.17 + 1.0.18 anapi-v2 @@ -43,12 +43,12 @@ dev.vality swag-anapi-v2 - 1.76-ec7a406-server + 1.77-89e7ff0-server dev.vality bouncer-proto - 1.39-633ba73 + 1.41-5628c61 dev.vality @@ -58,7 +58,7 @@ dev.vality payout-manager-proto - 1.36-063163d + 1.38-635dc24 dev.vality @@ -78,7 +78,7 @@ dev.vality reporter-proto - 1.16-cc187f5 + 1.18-d7d9995 dev.vality.geck @@ -87,7 +87,7 @@ dev.vality damsel - 1.566-03bbf48 + 1.568-9362c08 dev.vality.woody @@ -230,7 +230,7 @@ org.openapitools jackson-databind-nullable - 0.2.2 + 0.2.3 provided @@ -268,7 +268,7 @@ org.springframework.cloud spring-cloud-contract-wiremock - 3.1.1 + 3.1.3 test diff --git a/src/main/java/dev/vality/anapi/v2/converter/magista/response/StatPaymentToPaymentSearchResultConverter.java b/src/main/java/dev/vality/anapi/v2/converter/magista/response/StatPaymentToPaymentSearchResultConverter.java index 7bc3bf6..8575d42 100644 --- a/src/main/java/dev/vality/anapi/v2/converter/magista/response/StatPaymentToPaymentSearchResultConverter.java +++ b/src/main/java/dev/vality/anapi/v2/converter/magista/response/StatPaymentToPaymentSearchResultConverter.java @@ -73,7 +73,8 @@ public class StatPaymentToPaymentSearchResultConverter { return new CustomerPayer() .customerID(customer.getCustomerId()) .paymentToolDetails(mapPaymentToolDetails(paymentTool)) - .paymentToolToken(getPaymentToolToken(paymentTool)); + .paymentToolToken(getPaymentToolToken(paymentTool)) + .payerType("CustomerPayer"); } case PAYMENT_RESOURCE -> { var resource = payer.getPaymentResource(); @@ -91,7 +92,8 @@ public class StatPaymentToPaymentSearchResultConverter { : null) .contactInfo(new ContactInfo() .email(contactInfo.getEmail()) - .phoneNumber(contactInfo.getPhoneNumber())); + .phoneNumber(contactInfo.getPhoneNumber())) + .payerType("PaymentResourcePayer"); } case RECURRENT -> { var recurrent = payer.getRecurrent(); @@ -105,7 +107,8 @@ public class StatPaymentToPaymentSearchResultConverter { .phoneNumber(contactInfo.getPhoneNumber())) .recurrentParentPayment(new PaymentRecurrentParent() .paymentID(recurrent.getRecurrentParent().getPaymentId()) - .invoiceID(recurrent.getRecurrentParent().getInvoiceId())); + .invoiceID(recurrent.getRecurrentParent().getInvoiceId())) + .payerType("RecurrentPayer"); } default -> throw new IllegalArgumentException(); } @@ -133,22 +136,26 @@ public class StatPaymentToPaymentSearchResultConverter { .paymentSystem(getPaymentSystem(card)) .cardNumberMask(MaskUtil.constructCardNumber(card)) .lastDigits(card.getLastDigits()) - .tokenProvider(getTokenProvider(card)); + .tokenProvider(getTokenProvider(card)) + .detailsType("PaymentToolDetailsBankCard"); } case PAYMENT_TERMINAL -> { var terminal = paymentTool.getPaymentTerminal(); return new PaymentToolDetailsPaymentTerminal() - .provider(getProvider(terminal)); + .provider(getProvider(terminal)) + .detailsType("PaymentToolDetailsPaymentTerminal"); } case MOBILE_COMMERCE -> { var mobile = paymentTool.getMobileCommerce(); return new PaymentToolDetailsMobileCommerce() - .phoneNumber(MaskUtil.constructPhoneNumber(mobile.getPhone())); + .phoneNumber(MaskUtil.constructPhoneNumber(mobile.getPhone())) + .detailsType("PaymentToolDetailsMobileCommerce"); } case CRYPTO_CURRENCY -> { var cryptoCurrency = paymentTool.getCryptoCurrency(); return new PaymentToolDetailsCryptoWallet() - .cryptoCurrency(cryptoCurrency.getId()); + .cryptoCurrency(cryptoCurrency.getId()) + .detailsType("PaymentToolDetailsCryptoWallet"); } default -> throw new IllegalArgumentException(); }