Skip to content

Commit

Permalink
Inclusao de Campos SDWO (#18)
Browse files Browse the repository at this point in the history
* Inclusao de Campos SDWO

* Setters

---------

Co-authored-by: Vinicius Brito Costa <[email protected]>
  • Loading branch information
Vinicius-Brito-Costa and Vinicius Brito Costa authored Aug 5, 2024
1 parent a4e9c7a commit 94dd22c
Show file tree
Hide file tree
Showing 5 changed files with 70 additions and 2 deletions.
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## [2.1.7] - 15/JUL/2024
### Added
- Inclusao de Campos SDWO

## [2.1.6] - 17/JAN/2024
### Added
- Criação dos campos de SDWO

## [2.1.5] - 29/NOV/2023
### Added
- Inclusão do sendNotification e responseMode no 3DS para callback
Expand Down
9 changes: 8 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -516,7 +516,14 @@ maxiPago.sale()
.setId(12345)
.setProcessingType(SDWOProcessingType.CASH_IN)
.setSenderTaxIdentification("56326738000106")
.setBusinessApplicationIdentifier(BusinessApplicationIdentifier.CBPS)));
.setBusinessApplicationIdentifier(BusinessApplicationIdentifier.CBPS)
.setPaymentDestination("04")
.setMerchantTaxId("11122233344455")
.setReceiverData(new ReceiverData()
.setFirstName("Jose")
.setLastName("Silva")
.setTaxIdNumber("123556")
.setWalletAccountIdentification("342432409"))));


TransactionResponse response = maxiPago.transactionRequest().execute();
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<groupId>com.maxipago</groupId>
<artifactId>sdk-java-v2</artifactId>
<version>2.1.6</version>
<version>2.1.7</version>

<build>
<plugins>
Expand Down
31 changes: 31 additions & 0 deletions src/main/java/com/maxipago/ReceiverData.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
package com.maxipago;

import javax.xml.bind.annotation.XmlElement;

public class ReceiverData {
@XmlElement
public String firstName;
@XmlElement
public String lastName;
@XmlElement
public String taxIdNumber;
@XmlElement
public String walletAccountIdentification;

public ReceiverData setFirstName(String firstName) {
this.firstName = firstName;
return this;
}
public ReceiverData setLastName(String lastName) {
this.lastName = lastName;
return this;
}
public ReceiverData setTaxIdNumber(String taxIdNumber) {
this.taxIdNumber = taxIdNumber;
return this;
}
public ReceiverData setWalletAccountIdentification(String walletAccountIdentification) {
this.walletAccountIdentification = walletAccountIdentification;
return this;
}
}
22 changes: 22 additions & 0 deletions src/main/java/com/maxipago/SDWO.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,13 @@ public class SDWO {
public String senderTaxIdentification;
@XmlElement
public String businessApplicationIdentifier;
@XmlElement
public String paymentDestination;
@XmlElement
public String merchantTaxId;
@XmlElement
public ReceiverData receiverData;


public SDWO setId(int id) {
this.id = id;
Expand All @@ -34,4 +41,19 @@ public SDWO setBusinessApplicationIdentifier(BusinessApplicationIdentifier busin
this.businessApplicationIdentifier = businessApplicationIdentifier.toString();
return this;
}

public SDWO setPaymentDestination(String paymentDestination) {
this.paymentDestination = paymentDestination;
return this;
}

public SDWO setMerchantTaxId(String merchantTaxId) {
this.merchantTaxId = merchantTaxId;
return this;
}

public SDWO setReceiverData(ReceiverData receiverData) {
this.receiverData = receiverData;
return this;
}
}

0 comments on commit 94dd22c

Please sign in to comment.