Skip to content

Commit

Permalink
Properties update for Metadata, Purpose and Profile (#400)
Browse files Browse the repository at this point in the history
* Update card metadata response properties

* Update purpose types

* Update profile class with holding currencies
  • Loading branch information
armando-rodriguez-cko authored Apr 16, 2024
1 parent 6d90cf2 commit a5d1cea
Show file tree
Hide file tree
Showing 6 changed files with 93 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main/java/com/checkout/accounts/AccountsFilePurpose.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,11 @@
public enum AccountsFilePurpose {

BANK_VERIFICATION("bank_verification"),
IDENTIFICATION("identification"),
IDENTITY_VERIFICATION("identity_verification"),
COMPANY_VERIFICATION("company_verification"),
FINANCIAL_VERIFICATION("financial_verification");
FINANCIAL_VERIFICATION("financial_verification"),
TAX_VERIFICATION("tax_verification");

@Getter
private final String purpose;
Expand Down
3 changes: 3 additions & 0 deletions src/main/java/com/checkout/accounts/Profile.java
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,7 @@ public final class Profile {
@SerializedName("default_holding_currency")
private Currency defaultHoldingCurrency;

@SerializedName("holding_currencies")
private List<Currency> holdingCurrencies;

}
10 changes: 10 additions & 0 deletions src/main/java/com/checkout/common/SchemeLocalType.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,20 @@

public enum SchemeLocalType {

@SerializedName("accel")
ACCEL,
@SerializedName("cartes_bancaires")
CARTES_BANCAIRES,
@SerializedName("mada")
MADA,
@SerializedName("nyce")
NYCE,
@SerializedName("omannet")
OMANNET,
@SerializedName("pulse")
PULSE,
@SerializedName("star")
STAR,
@SerializedName("upi")
UPI,
}
23 changes: 23 additions & 0 deletions src/main/java/com/checkout/metadata/card/CardMetadataResponse.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import com.checkout.common.CardCategory;
import com.checkout.common.CardType;
import com.checkout.common.CountryCode;
import com.checkout.common.Currency;
import com.checkout.common.SchemeLocalType;
import com.google.gson.annotations.SerializedName;
import lombok.Data;
Expand All @@ -19,15 +20,25 @@ public final class CardMetadataResponse extends HttpMetadata {

private String scheme;

/**
* @deprecated This property will be removed in the future, and should be used
* {@link CardMetadataResponse#localSchemes} instead
*/
@Deprecated
@SerializedName("scheme_local")
private SchemeLocalType schemeLocal;

@SerializedName("local_schemes")
private SchemeLocalType localSchemes;

@SerializedName("card_type")
private CardType cardType;

@SerializedName("card_category")
private CardCategory cardCategory;

private Currency currency;

private String issuer;

@SerializedName("issuer_country")
Expand All @@ -42,6 +53,18 @@ public final class CardMetadataResponse extends HttpMetadata {
@SerializedName("product_type")
private String productType;

@SerializedName("subproduct_id")
private String subproductId;

@SerializedName("regulated_indicator")
private Boolean regulatedIndicator;

@SerializedName("regulated_type")
private String regulatedType;

@SerializedName("card_payouts")
private CardMetadataPayouts payouts;

@SerializedName("scheme_metadata")
private SchemeMetadata schemeMetadata;
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
package com.checkout.metadata.card;

import com.google.gson.annotations.SerializedName;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@AllArgsConstructor
@NoArgsConstructor
public final class PinlessDebitSchemeMetadata {

@SerializedName("network_id")
private String networkId;

@SerializedName("network_description")
private String networkDescription;

@SerializedName("bill_pay_indicator")
private Boolean billPayIndicator;

@SerializedName("ecommerce_indicator")
private Boolean ecommerceIndicator;

@SerializedName("interchange_fee_indicator")
private String InterchangeFeeIndicator;

@SerializedName("money_transfer_indicator")
private Boolean moneyTransferIndicator;

@SerializedName("token_indicator")
private Boolean tokenIndicator;

}
20 changes: 20 additions & 0 deletions src/main/java/com/checkout/metadata/card/SchemeMetadata.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
package com.checkout.metadata.card;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@AllArgsConstructor
@NoArgsConstructor
public final class SchemeMetadata {

private PinlessDebitSchemeMetadata accel;

private PinlessDebitSchemeMetadata pulse;

private PinlessDebitSchemeMetadata nyce;

private PinlessDebitSchemeMetadata star;

}

0 comments on commit a5d1cea

Please sign in to comment.