preferredLocales;
diff --git a/src/main/java/com/stripe/model/ConfirmationToken.java b/src/main/java/com/stripe/model/ConfirmationToken.java
index 03064afadcb..f24dc4c68a0 100644
--- a/src/main/java/com/stripe/model/ConfirmationToken.java
+++ b/src/main/java/com/stripe/model/ConfirmationToken.java
@@ -722,6 +722,13 @@ public static class CardPresent extends StripeObject {
@SerializedName("brand")
String brand;
+ /**
+ * The product code that
+ * identifies the specific program or product associated with a card.
+ */
+ @SerializedName("brand_product")
+ String brandProduct;
+
/**
* When using manual capture, a future timestamp after which the charge will be
* automatically refunded if uncaptured.
@@ -829,6 +836,17 @@ public static class CardPresent extends StripeObject {
@SerializedName("network")
String network;
+ /**
+ * This is used by the financial networks to identify a transaction. Visa calls this the
+ * Transaction ID, Mastercard calls this the Trace ID, and American Express calls this
+ * the Acquirer Reference Data. The first three digits of the Trace ID is the Financial
+ * Network Code, the next 6 digits is the Banknet Reference Number, and the last 4
+ * digits represent the date (MM/DD). This field will be available for successful Visa,
+ * Mastercard, or American Express transactions and always null for other card brands.
+ */
+ @SerializedName("network_transaction_id")
+ String networkTransactionId;
+
/** Details about payments collected offline. */
@SerializedName("offline")
Offline offline;
@@ -1095,6 +1113,13 @@ public static class CardPresent extends StripeObject {
@SerializedName("brand")
String brand;
+ /**
+ * The product code that identifies
+ * the specific program or product associated with a card.
+ */
+ @SerializedName("brand_product")
+ String brandProduct;
+
/**
* The cardholder name as read from the card, in ISO 7813 format. May include
diff --git a/src/main/java/com/stripe/model/Dispute.java b/src/main/java/com/stripe/model/Dispute.java
index f93de287e32..6b5886c1c0c 100644
--- a/src/main/java/com/stripe/model/Dispute.java
+++ b/src/main/java/com/stripe/model/Dispute.java
@@ -832,6 +832,15 @@ public static class Card extends StripeObject {
@SerializedName("brand")
String brand;
+ /**
+ * The type of dispute opened. Different case types may have varying fees and financial
+ * impact.
+ *
+ * One of {@code chargeback}, or {@code inquiry}.
+ */
+ @SerializedName("case_type")
+ String caseType;
+
/**
* The card network's specific dispute reason code, which maps to one of Stripe's primary
* dispute categories to simplify response guidance. The Charge object created by
+ * this PaymentIntent. This property is {@code null} until PaymentIntent confirmation is
+ * attempted.
+ */
@SerializedName("latest_charge")
@Getter(lombok.AccessLevel.NONE)
@Setter(lombok.AccessLevel.NONE)
diff --git a/src/main/java/com/stripe/model/PaymentMethod.java b/src/main/java/com/stripe/model/PaymentMethod.java
index 66b51c4225a..a08fc373fda 100644
--- a/src/main/java/com/stripe/model/PaymentMethod.java
+++ b/src/main/java/com/stripe/model/PaymentMethod.java
@@ -965,6 +965,13 @@ public static class CardPresent extends StripeObject {
@SerializedName("brand")
String brand;
+ /**
+ * The product code that
+ * identifies the specific program or product associated with a card.
+ */
+ @SerializedName("brand_product")
+ String brandProduct;
+
/**
* When using manual capture, a future timestamp after which the charge will be
* automatically refunded if uncaptured.
@@ -1071,6 +1078,17 @@ public static class CardPresent extends StripeObject {
@SerializedName("network")
String network;
+ /**
+ * This is used by the financial networks to identify a transaction. Visa calls this the
+ * Transaction ID, Mastercard calls this the Trace ID, and American Express calls this the
+ * Acquirer Reference Data. The first three digits of the Trace ID is the Financial
+ * Network Code, the next 6 digits is the Banknet Reference Number, and the last 4 digits
+ * represent the date (MM/DD). This field will be available for successful Visa,
+ * Mastercard, or American Express transactions and always null for other card brands.
+ */
+ @SerializedName("network_transaction_id")
+ String networkTransactionId;
+
/** Details about payments collected offline. */
@SerializedName("offline")
Offline offline;
@@ -1332,6 +1350,13 @@ public static class CardPresent extends StripeObject {
@SerializedName("brand")
String brand;
+ /**
+ * The product code that identifies the
+ * specific program or product associated with a card.
+ */
+ @SerializedName("brand_product")
+ String brandProduct;
+
/**
* The cardholder name as read from the card, in ISO 7813 format. May include
diff --git a/src/main/java/com/stripe/model/PaymentMethodConfiguration.java b/src/main/java/com/stripe/model/PaymentMethodConfiguration.java
index fb676668245..012c6e43a39 100644
--- a/src/main/java/com/stripe/model/PaymentMethodConfiguration.java
+++ b/src/main/java/com/stripe/model/PaymentMethodConfiguration.java
@@ -201,6 +201,9 @@ public class PaymentMethodConfiguration extends ApiResource implements HasId {
@SerializedName("swish")
Swish swish;
+ @SerializedName("twint")
+ Twint twint;
+
@SerializedName("us_bank_account")
UsBankAccount usBankAccount;
@@ -1920,6 +1923,49 @@ public static class DisplayPreference extends StripeObject {
}
}
+ @Getter
+ @Setter
+ @EqualsAndHashCode(callSuper = false)
+ public static class Twint extends StripeObject {
+ /**
+ * Whether this payment method may be offered at checkout. True if {@code display_preference} is
+ * {@code on} and the payment method's capability is active.
+ */
+ @SerializedName("available")
+ Boolean available;
+
+ @SerializedName("display_preference")
+ DisplayPreference displayPreference;
+
+ @Getter
+ @Setter
+ @EqualsAndHashCode(callSuper = false)
+ public static class DisplayPreference extends StripeObject {
+ /**
+ * For child configs, whether or not the account's preference will be observed. If {@code
+ * false}, the parent configuration's default is used.
+ */
+ @SerializedName("overridable")
+ Boolean overridable;
+
+ /**
+ * The account's display preference.
+ *
+ *
One of {@code none}, {@code off}, or {@code on}.
+ */
+ @SerializedName("preference")
+ String preference;
+
+ /**
+ * The effective display preference value.
+ *
+ *
One of {@code off}, or {@code on}.
+ */
+ @SerializedName("value")
+ String value;
+ }
+ }
+
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
@@ -2088,6 +2134,7 @@ public void setResponseGetter(StripeResponseGetter responseGetter) {
trySetResponseGetter(sepaDebit, responseGetter);
trySetResponseGetter(sofort, responseGetter);
trySetResponseGetter(swish, responseGetter);
+ trySetResponseGetter(twint, responseGetter);
trySetResponseGetter(usBankAccount, responseGetter);
trySetResponseGetter(wechatPay, responseGetter);
trySetResponseGetter(zip, responseGetter);
diff --git a/src/main/java/com/stripe/model/Refund.java b/src/main/java/com/stripe/model/Refund.java
index 074d23dbdc2..91eabd858d8 100644
--- a/src/main/java/com/stripe/model/Refund.java
+++ b/src/main/java/com/stripe/model/Refund.java
@@ -444,7 +444,7 @@ public static Refund create(RefundCreateParams params, RequestOptions options)
/**
* Returns a list of all refunds you created. We return the refunds in sorted order, with the most
- * recent refunds appearing first The 10 most recent refunds are always available by default on
+ * recent refunds appearing first. The 10 most recent refunds are always available by default on
* the Charge object.
*/
public static RefundCollection list(Map params) throws StripeException {
@@ -453,7 +453,7 @@ public static RefundCollection list(Map params) throws StripeExc
/**
* Returns a list of all refunds you created. We return the refunds in sorted order, with the most
- * recent refunds appearing first The 10 most recent refunds are always available by default on
+ * recent refunds appearing first. The 10 most recent refunds are always available by default on
* the Charge object.
*/
public static RefundCollection list(Map params, RequestOptions options)
@@ -467,7 +467,7 @@ public static RefundCollection list(Map params, RequestOptions o
/**
* Returns a list of all refunds you created. We return the refunds in sorted order, with the most
- * recent refunds appearing first The 10 most recent refunds are always available by default on
+ * recent refunds appearing first. The 10 most recent refunds are always available by default on
* the Charge object.
*/
public static RefundCollection list(RefundListParams params) throws StripeException {
@@ -476,7 +476,7 @@ public static RefundCollection list(RefundListParams params) throws StripeExcept
/**
* Returns a list of all refunds you created. We return the refunds in sorted order, with the most
- * recent refunds appearing first The 10 most recent refunds are always available by default on
+ * recent refunds appearing first. The 10 most recent refunds are always available by default on
* the Charge object.
*/
public static RefundCollection list(RefundListParams params, RequestOptions options)
diff --git a/src/main/java/com/stripe/model/checkout/Session.java b/src/main/java/com/stripe/model/checkout/Session.java
index e315107cf12..087a6a574b4 100644
--- a/src/main/java/com/stripe/model/checkout/Session.java
+++ b/src/main/java/com/stripe/model/checkout/Session.java
@@ -10,6 +10,7 @@
import com.stripe.model.HasId;
import com.stripe.model.Invoice;
import com.stripe.model.LineItemCollection;
+import com.stripe.model.MetadataStore;
import com.stripe.model.PaymentIntent;
import com.stripe.model.PaymentLink;
import com.stripe.model.SetupIntent;
@@ -30,6 +31,7 @@
import com.stripe.param.checkout.SessionListLineItemsParams;
import com.stripe.param.checkout.SessionListParams;
import com.stripe.param.checkout.SessionRetrieveParams;
+import com.stripe.param.checkout.SessionUpdateParams;
import java.math.BigDecimal;
import java.util.List;
import java.util.Map;
@@ -56,7 +58,7 @@
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
-public class Session extends ApiResource implements HasId {
+public class Session extends ApiResource implements HasId, MetadataStore {
/** When set, provides configuration for actions to take if this Checkout Session expires. */
@SerializedName("after_expiration")
AfterExpiration afterExpiration;
@@ -223,6 +225,7 @@ public class Session extends ApiResource implements HasId {
* to an object. This can be useful for storing additional information about the object in a
* structured format.
*/
+ @Getter(onMethod_ = {@Override})
@SerializedName("metadata")
Map metadata;
@@ -766,6 +769,42 @@ public static Session retrieve(
return getGlobalResponseGetter().request(request, Session.class);
}
+ /** Updates a Session object. */
+ @Override
+ public Session update(Map params) throws StripeException {
+ return update(params, (RequestOptions) null);
+ }
+
+ /** Updates a Session object. */
+ @Override
+ public Session update(Map params, RequestOptions options) throws StripeException {
+ String path = String.format("/v1/checkout/sessions/%s", ApiResource.urlEncodeId(this.getId()));
+ ApiRequest request =
+ new ApiRequest(
+ BaseAddress.API, ApiResource.RequestMethod.POST, path, params, options, ApiMode.V1);
+ return getResponseGetter().request(request, Session.class);
+ }
+
+ /** Updates a Session object. */
+ public Session update(SessionUpdateParams params) throws StripeException {
+ return update(params, (RequestOptions) null);
+ }
+
+ /** Updates a Session object. */
+ public Session update(SessionUpdateParams params, RequestOptions options) throws StripeException {
+ String path = String.format("/v1/checkout/sessions/%s", ApiResource.urlEncodeId(this.getId()));
+ ApiResource.checkNullTypedParams(path, params);
+ ApiRequest request =
+ new ApiRequest(
+ BaseAddress.API,
+ ApiResource.RequestMethod.POST,
+ path,
+ ApiRequestParams.paramsToMap(params),
+ options,
+ ApiMode.V1);
+ return getResponseGetter().request(request, Session.class);
+ }
+
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
diff --git a/src/main/java/com/stripe/model/tax/Calculation.java b/src/main/java/com/stripe/model/tax/Calculation.java
index f01969229e1..cc51e6981cf 100644
--- a/src/main/java/com/stripe/model/tax/Calculation.java
+++ b/src/main/java/com/stripe/model/tax/Calculation.java
@@ -30,7 +30,10 @@
@Setter
@EqualsAndHashCode(callSuper = false)
public class Calculation extends ApiResource implements HasId {
- /** Total after taxes. */
+ /**
+ * Total amount after taxes in the smallest currency unit.
+ */
@SerializedName("amount_total")
Long amountTotal;
diff --git a/src/main/java/com/stripe/param/AccountCreateParams.java b/src/main/java/com/stripe/param/AccountCreateParams.java
index 4a6d281531c..f82049e9658 100644
--- a/src/main/java/com/stripe/param/AccountCreateParams.java
+++ b/src/main/java/com/stripe/param/AccountCreateParams.java
@@ -573,7 +573,7 @@ public static class BusinessProfile {
Map extraParams;
/**
- * The merchant category code for the
+ * The merchant category code for the
* account. MCCs are used to classify businesses based on the goods or services they
* provide.
*/
@@ -734,7 +734,7 @@ public Builder putAllExtraParam(Map map) {
}
/**
- * The merchant category code for the
+ * The merchant category code for the
* account. MCCs are used to classify businesses based on the goods or services they
* provide.
*/
@@ -810,7 +810,7 @@ public Builder setUrl(String url) {
public static class AnnualRevenue {
/**
* Required. A non-negative integer representing the amount in the smallest currency unit.
+ * href="https://stripe.com/currencies#zero-decimal">smallest currency unit.
*/
@SerializedName("amount")
Long amount;
@@ -868,7 +868,7 @@ public AccountCreateParams.BusinessProfile.AnnualRevenue build() {
/**
* Required. A non-negative integer representing the amount in the smallest currency unit.
+ * href="https://stripe.com/currencies#zero-decimal">smallest currency unit.
*/
public Builder setAmount(Long amount) {
this.amount = amount;
@@ -928,7 +928,7 @@ public Builder setFiscalYearEnd(String fiscalYearEnd) {
public static class MonthlyEstimatedRevenue {
/**
* Required. A non-negative integer representing how much to charge in the smallest currency unit.
+ * href="https://stripe.com/currencies#zero-decimal">smallest currency unit.
*/
@SerializedName("amount")
Long amount;
@@ -976,7 +976,7 @@ public AccountCreateParams.BusinessProfile.MonthlyEstimatedRevenue build() {
/**
* Required. A non-negative integer representing how much to charge in the
- * smallest currency unit.
+ * smallest currency unit.
*/
public Builder setAmount(Long amount) {
this.amount = amount;
@@ -5697,7 +5697,7 @@ public static class Company {
/**
* Whether the company's directors have been provided. Set this Boolean to {@code true} after
- * creating all the company's directors with the
+ * creating all the company's directors with the
* Persons API for accounts with a {@code relationship.director} requirement. This value is
* not automatically set to {@code true} after creating directors, so it needs to be updated to
* indicate all directors have been provided.
@@ -5707,7 +5707,7 @@ public static class Company {
/**
* Whether the company's executives have been provided. Set this Boolean to {@code true} after
- * creating all the company's executives with the
+ * creating all the company's executives with the
* Persons API for accounts with a {@code relationship.executive} requirement.
*/
@SerializedName("executives_provided")
@@ -5747,8 +5747,8 @@ public static class Company {
/**
* Whether the company's owners have been provided. Set this Boolean to {@code true} after
- * creating all the company's owners with the
- * Persons API for accounts with a {@code relationship.owner} requirement.
+ * creating all the company's owners with the Persons
+ * API for accounts with a {@code relationship.owner} requirement.
*/
@SerializedName("owners_provided")
Boolean ownersProvided;
@@ -5775,7 +5775,7 @@ public static class Company {
/**
* The category identifying the legal structure of the company or legal entity. See Business
+ * href="https://stripe.com/connect/identity-verification#business-structure">Business
* structure for more details. Pass an empty string to unset this value.
*/
@SerializedName("structure")
@@ -5936,7 +5936,7 @@ public Builder setAddressKanji(AccountCreateParams.Company.AddressKanji addressK
/**
* Whether the company's directors have been provided. Set this Boolean to {@code true} after
- * creating all the company's directors with the
+ * creating all the company's directors with the
* Persons API for accounts with a {@code relationship.director} requirement. This value
* is not automatically set to {@code true} after creating directors, so it needs to be
* updated to indicate all directors have been provided.
@@ -5948,9 +5948,8 @@ public Builder setDirectorsProvided(Boolean directorsProvided) {
/**
* Whether the company's executives have been provided. Set this Boolean to {@code true} after
- * creating all the company's executives with the Persons API for accounts with a {@code
- * relationship.executive} requirement.
+ * creating all the company's executives with the
+ * Persons API for accounts with a {@code relationship.executive} requirement.
*/
public Builder setExecutivesProvided(Boolean executivesProvided) {
this.executivesProvided = executivesProvided;
@@ -6018,8 +6017,8 @@ public Builder setNameKanji(String nameKanji) {
/**
* Whether the company's owners have been provided. Set this Boolean to {@code true} after
- * creating all the company's owners with the
- * Persons API for accounts with a {@code relationship.owner} requirement.
+ * creating all the company's owners with the Persons
+ * API for accounts with a {@code relationship.owner} requirement.
*/
public Builder setOwnersProvided(Boolean ownersProvided) {
this.ownersProvided = ownersProvided;
@@ -6055,7 +6054,7 @@ public Builder setRegistrationNumber(String registrationNumber) {
/**
* The category identifying the legal structure of the company or legal entity. See Business
+ * href="https://stripe.com/connect/identity-verification#business-structure">Business
* structure for more details. Pass an empty string to unset this value.
*/
public Builder setStructure(AccountCreateParams.Company.Structure structure) {
@@ -6065,7 +6064,7 @@ public Builder setStructure(AccountCreateParams.Company.Structure structure) {
/**
* The category identifying the legal structure of the company or legal entity. See Business
+ * href="https://stripe.com/connect/identity-verification#business-structure">Business
* structure for more details. Pass an empty string to unset this value.
*/
public Builder setStructure(EmptyParam structure) {
@@ -8322,7 +8321,7 @@ public static class Individual {
* The government-issued ID number of the individual, as appropriate for the representative's
* country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in
* Canada). Instead of the number itself, you can also provide a PII token created with
+ * href="https://stripe.com/js/tokens/create_token?type=pii">PII token created with
* Stripe.js.
*/
@SerializedName("id_number")
@@ -8332,8 +8331,8 @@ public static class Individual {
* The government-issued secondary ID number of the individual, as appropriate for the
* representative's country, will be used for enhanced verification checks. In Thailand, this
* would be the laser code found on the back of an ID card. Instead of the number itself, you
- * can also provide a PII
- * token created with Stripe.js.
+ * can also provide a PII token
+ * created with Stripe.js.
*/
@SerializedName("id_number_secondary")
String idNumberSecondary;
@@ -8657,7 +8656,7 @@ public Builder setGender(String gender) {
* The government-issued ID number of the individual, as appropriate for the representative's
* country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number
* in Canada). Instead of the number itself, you can also provide a PII token created with
+ * href="https://stripe.com/js/tokens/create_token?type=pii">PII token created with
* Stripe.js.
*/
public Builder setIdNumber(String idNumber) {
@@ -8669,8 +8668,8 @@ public Builder setIdNumber(String idNumber) {
* The government-issued secondary ID number of the individual, as appropriate for the
* representative's country, will be used for enhanced verification checks. In Thailand, this
* would be the laser code found on the back of an ID card. Instead of the number itself, you
- * can also provide a PII
- * token created with Stripe.js.
+ * can also provide a PII token
+ * created with Stripe.js.
*/
public Builder setIdNumberSecondary(String idNumberSecondary) {
this.idNumberSecondary = idNumberSecondary;
@@ -10414,7 +10413,7 @@ public static class CardIssuing {
/**
* Details on the account's acceptance of the Stripe Issuing Terms and
+ * href="https://stripe.com/issuing/connect/tos_acceptance">Stripe Issuing Terms and
* Disclosures.
*/
@SerializedName("tos_acceptance")
@@ -10469,7 +10468,7 @@ public Builder putAllExtraParam(Map map) {
/**
* Details on the account's acceptance of the Stripe Issuing Terms and
+ * href="https://stripe.com/issuing/connect/tos_acceptance">Stripe Issuing Terms and
* Disclosures.
*/
public Builder setTosAcceptance(
@@ -11012,7 +11011,7 @@ public static class Payouts {
/**
* A Boolean indicating whether Stripe should try to reclaim negative balances from an
* attached bank account. For details, see Understanding Connect Account
+ * href="https://stripe.com/connect/account-balances">Understanding Connect Account
* Balances.
*/
@SerializedName("debit_negative_balances")
@@ -11030,8 +11029,8 @@ public static class Payouts {
/**
* Details on when funds from charges are available, and when they are paid out to an external
* account. For details, see our Setting Bank and
- * Debit Card Payouts documentation.
+ * href="https://stripe.com/connect/bank-transfers#payout-information">Setting Bank and Debit
+ * Card Payouts documentation.
*/
@SerializedName("schedule")
Schedule schedule;
@@ -11079,7 +11078,7 @@ public AccountCreateParams.Settings.Payouts build() {
/**
* A Boolean indicating whether Stripe should try to reclaim negative balances from an
* attached bank account. For details, see Understanding Connect Account
+ * href="https://stripe.com/connect/account-balances">Understanding Connect Account
* Balances.
*/
public Builder setDebitNegativeBalances(Boolean debitNegativeBalances) {
@@ -11118,7 +11117,7 @@ public Builder putAllExtraParam(Map map) {
/**
* Details on when funds from charges are available, and when they are paid out to an
* external account. For details, see our Setting Bank and
+ * href="https://stripe.com/connect/bank-transfers#payout-information">Setting Bank and
* Debit Card Payouts documentation.
*/
public Builder setSchedule(AccountCreateParams.Settings.Payouts.Schedule schedule) {
@@ -11143,8 +11142,8 @@ public static class Schedule {
* minimum}, representing the lowest available value for the account country. Default is
* {@code minimum}. The {@code delay_days} parameter remains at the last configured value if
* {@code interval} is {@code manual}. Learn more about
- * controlling payout delay days.
+ * href="https://stripe.com/connect/manage-payout-schedule">Learn more about controlling
+ * payout delay days.
*/
@SerializedName("delay_days")
Object delayDays;
@@ -11226,8 +11225,8 @@ public AccountCreateParams.Settings.Payouts.Schedule build() {
* {@code minimum}, representing the lowest available value for the account country.
* Default is {@code minimum}. The {@code delay_days} parameter remains at the last
* configured value if {@code interval} is {@code manual}. Learn more about
- * controlling payout delay days.
+ * href="https://stripe.com/connect/manage-payout-schedule">Learn more about controlling
+ * payout delay days.
*/
public Builder setDelayDays(
AccountCreateParams.Settings.Payouts.Schedule.DelayDays delayDays) {
@@ -11240,8 +11239,8 @@ public Builder setDelayDays(
* {@code minimum}, representing the lowest available value for the account country.
* Default is {@code minimum}. The {@code delay_days} parameter remains at the last
* configured value if {@code interval} is {@code manual}. Learn more about
- * controlling payout delay days.
+ * href="https://stripe.com/connect/manage-payout-schedule">Learn more about controlling
+ * payout delay days.
*/
public Builder setDelayDays(Long delayDays) {
this.delayDays = delayDays;
diff --git a/src/main/java/com/stripe/param/AccountUpdateParams.java b/src/main/java/com/stripe/param/AccountUpdateParams.java
index aaaa619239a..767918706e3 100644
--- a/src/main/java/com/stripe/param/AccountUpdateParams.java
+++ b/src/main/java/com/stripe/param/AccountUpdateParams.java
@@ -560,7 +560,7 @@ public static class BusinessProfile {
Map extraParams;
/**
- * The merchant category code for the
+ * The merchant category code for the
* account. MCCs are used to classify businesses based on the goods or services they
* provide.
*/
@@ -721,7 +721,7 @@ public Builder putAllExtraParam(Map map) {
}
/**
- * The merchant category code for the
+ * The merchant category code for the
* account. MCCs are used to classify businesses based on the goods or services they
* provide.
*/
@@ -731,7 +731,7 @@ public Builder setMcc(String mcc) {
}
/**
- * The merchant category code for the
+ * The merchant category code for the
* account. MCCs are used to classify businesses based on the goods or services they
* provide.
*/
@@ -840,7 +840,7 @@ public Builder setUrl(EmptyParam url) {
public static class AnnualRevenue {
/**
* Required. A non-negative integer representing the amount in the smallest currency unit.
+ * href="https://stripe.com/currencies#zero-decimal">smallest currency unit.
*/
@SerializedName("amount")
Long amount;
@@ -898,7 +898,7 @@ public AccountUpdateParams.BusinessProfile.AnnualRevenue build() {
/**
* Required. A non-negative integer representing the amount in the smallest currency unit.
+ * href="https://stripe.com/currencies#zero-decimal">smallest currency unit.
*/
public Builder setAmount(Long amount) {
this.amount = amount;
@@ -977,7 +977,7 @@ public Builder setFiscalYearEnd(EmptyParam fiscalYearEnd) {
public static class MonthlyEstimatedRevenue {
/**
* Required. A non-negative integer representing how much to charge in the smallest currency unit.
+ * href="https://stripe.com/currencies#zero-decimal">smallest currency unit.
*/
@SerializedName("amount")
Long amount;
@@ -1025,7 +1025,7 @@ public AccountUpdateParams.BusinessProfile.MonthlyEstimatedRevenue build() {
/**
* Required. A non-negative integer representing how much to charge in the
- * smallest currency unit.
+ * smallest currency unit.
*/
public Builder setAmount(Long amount) {
this.amount = amount;
@@ -5795,7 +5795,7 @@ public static class Company {
/**
* Whether the company's directors have been provided. Set this Boolean to {@code true} after
- * creating all the company's directors with the
+ * creating all the company's directors with the
* Persons API for accounts with a {@code relationship.director} requirement. This value is
* not automatically set to {@code true} after creating directors, so it needs to be updated to
* indicate all directors have been provided.
@@ -5805,7 +5805,7 @@ public static class Company {
/**
* Whether the company's executives have been provided. Set this Boolean to {@code true} after
- * creating all the company's executives with the
+ * creating all the company's executives with the
* Persons API for accounts with a {@code relationship.executive} requirement.
*/
@SerializedName("executives_provided")
@@ -5845,8 +5845,8 @@ public static class Company {
/**
* Whether the company's owners have been provided. Set this Boolean to {@code true} after
- * creating all the company's owners with the
- * Persons API for accounts with a {@code relationship.owner} requirement.
+ * creating all the company's owners with the Persons
+ * API for accounts with a {@code relationship.owner} requirement.
*/
@SerializedName("owners_provided")
Boolean ownersProvided;
@@ -5873,7 +5873,7 @@ public static class Company {
/**
* The category identifying the legal structure of the company or legal entity. See Business
+ * href="https://stripe.com/connect/identity-verification#business-structure">Business
* structure for more details. Pass an empty string to unset this value.
*/
@SerializedName("structure")
@@ -6034,7 +6034,7 @@ public Builder setAddressKanji(AccountUpdateParams.Company.AddressKanji addressK
/**
* Whether the company's directors have been provided. Set this Boolean to {@code true} after
- * creating all the company's directors with the
+ * creating all the company's directors with the
* Persons API for accounts with a {@code relationship.director} requirement. This value
* is not automatically set to {@code true} after creating directors, so it needs to be
* updated to indicate all directors have been provided.
@@ -6046,9 +6046,8 @@ public Builder setDirectorsProvided(Boolean directorsProvided) {
/**
* Whether the company's executives have been provided. Set this Boolean to {@code true} after
- * creating all the company's executives with the Persons API for accounts with a {@code
- * relationship.executive} requirement.
+ * creating all the company's executives with the
+ * Persons API for accounts with a {@code relationship.executive} requirement.
*/
public Builder setExecutivesProvided(Boolean executivesProvided) {
this.executivesProvided = executivesProvided;
@@ -6149,8 +6148,8 @@ public Builder setNameKanji(EmptyParam nameKanji) {
/**
* Whether the company's owners have been provided. Set this Boolean to {@code true} after
- * creating all the company's owners with the
- * Persons API for accounts with a {@code relationship.owner} requirement.
+ * creating all the company's owners with the Persons
+ * API for accounts with a {@code relationship.owner} requirement.
*/
public Builder setOwnersProvided(Boolean ownersProvided) {
this.ownersProvided = ownersProvided;
@@ -6203,7 +6202,7 @@ public Builder setRegistrationNumber(EmptyParam registrationNumber) {
/**
* The category identifying the legal structure of the company or legal entity. See Business
+ * href="https://stripe.com/connect/identity-verification#business-structure">Business
* structure for more details. Pass an empty string to unset this value.
*/
public Builder setStructure(AccountUpdateParams.Company.Structure structure) {
@@ -6213,7 +6212,7 @@ public Builder setStructure(AccountUpdateParams.Company.Structure structure) {
/**
* The category identifying the legal structure of the company or legal entity. See Business
+ * href="https://stripe.com/connect/identity-verification#business-structure">Business
* structure for more details. Pass an empty string to unset this value.
*/
public Builder setStructure(EmptyParam structure) {
@@ -8231,7 +8230,7 @@ public static class Individual {
* The government-issued ID number of the individual, as appropriate for the representative's
* country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number in
* Canada). Instead of the number itself, you can also provide a PII token created with
+ * href="https://stripe.com/js/tokens/create_token?type=pii">PII token created with
* Stripe.js.
*/
@SerializedName("id_number")
@@ -8241,8 +8240,8 @@ public static class Individual {
* The government-issued secondary ID number of the individual, as appropriate for the
* representative's country, will be used for enhanced verification checks. In Thailand, this
* would be the laser code found on the back of an ID card. Instead of the number itself, you
- * can also provide a PII
- * token created with Stripe.js.
+ * can also provide a PII token
+ * created with Stripe.js.
*/
@SerializedName("id_number_secondary")
Object idNumberSecondary;
@@ -8599,7 +8598,7 @@ public Builder setGender(EmptyParam gender) {
* The government-issued ID number of the individual, as appropriate for the representative's
* country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number
* in Canada). Instead of the number itself, you can also provide a PII token created with
+ * href="https://stripe.com/js/tokens/create_token?type=pii">PII token created with
* Stripe.js.
*/
public Builder setIdNumber(String idNumber) {
@@ -8611,7 +8610,7 @@ public Builder setIdNumber(String idNumber) {
* The government-issued ID number of the individual, as appropriate for the representative's
* country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number
* in Canada). Instead of the number itself, you can also provide a PII token created with
+ * href="https://stripe.com/js/tokens/create_token?type=pii">PII token created with
* Stripe.js.
*/
public Builder setIdNumber(EmptyParam idNumber) {
@@ -8623,8 +8622,8 @@ public Builder setIdNumber(EmptyParam idNumber) {
* The government-issued secondary ID number of the individual, as appropriate for the
* representative's country, will be used for enhanced verification checks. In Thailand, this
* would be the laser code found on the back of an ID card. Instead of the number itself, you
- * can also provide a PII
- * token created with Stripe.js.
+ * can also provide a PII token
+ * created with Stripe.js.
*/
public Builder setIdNumberSecondary(String idNumberSecondary) {
this.idNumberSecondary = idNumberSecondary;
@@ -8635,8 +8634,8 @@ public Builder setIdNumberSecondary(String idNumberSecondary) {
* The government-issued secondary ID number of the individual, as appropriate for the
* representative's country, will be used for enhanced verification checks. In Thailand, this
* would be the laser code found on the back of an ID card. Instead of the number itself, you
- * can also provide a PII
- * token created with Stripe.js.
+ * can also provide a PII token
+ * created with Stripe.js.
*/
public Builder setIdNumberSecondary(EmptyParam idNumberSecondary) {
this.idNumberSecondary = idNumberSecondary;
@@ -10694,7 +10693,7 @@ public static class CardIssuing {
/**
* Details on the account's acceptance of the Stripe Issuing Terms and
+ * href="https://stripe.com/issuing/connect/tos_acceptance">Stripe Issuing Terms and
* Disclosures.
*/
@SerializedName("tos_acceptance")
@@ -10749,7 +10748,7 @@ public Builder putAllExtraParam(Map map) {
/**
* Details on the account's acceptance of the Stripe Issuing Terms and
+ * href="https://stripe.com/issuing/connect/tos_acceptance">Stripe Issuing Terms and
* Disclosures.
*/
public Builder setTosAcceptance(
@@ -11456,7 +11455,7 @@ public static class Payouts {
/**
* A Boolean indicating whether Stripe should try to reclaim negative balances from an
* attached bank account. For details, see Understanding Connect Account
+ * href="https://stripe.com/connect/account-balances">Understanding Connect Account
* Balances.
*/
@SerializedName("debit_negative_balances")
@@ -11474,8 +11473,8 @@ public static class Payouts {
/**
* Details on when funds from charges are available, and when they are paid out to an external
* account. For details, see our Setting Bank and
- * Debit Card Payouts documentation.
+ * href="https://stripe.com/connect/bank-transfers#payout-information">Setting Bank and Debit
+ * Card Payouts documentation.
*/
@SerializedName("schedule")
Schedule schedule;
@@ -11523,7 +11522,7 @@ public AccountUpdateParams.Settings.Payouts build() {
/**
* A Boolean indicating whether Stripe should try to reclaim negative balances from an
* attached bank account. For details, see Understanding Connect Account
+ * href="https://stripe.com/connect/account-balances">Understanding Connect Account
* Balances.
*/
public Builder setDebitNegativeBalances(Boolean debitNegativeBalances) {
@@ -11562,7 +11561,7 @@ public Builder putAllExtraParam(Map map) {
/**
* Details on when funds from charges are available, and when they are paid out to an
* external account. For details, see our Setting Bank and
+ * href="https://stripe.com/connect/bank-transfers#payout-information">Setting Bank and
* Debit Card Payouts documentation.
*/
public Builder setSchedule(AccountUpdateParams.Settings.Payouts.Schedule schedule) {
@@ -11596,8 +11595,8 @@ public static class Schedule {
* minimum}, representing the lowest available value for the account country. Default is
* {@code minimum}. The {@code delay_days} parameter remains at the last configured value if
* {@code interval} is {@code manual}. Learn more about
- * controlling payout delay days.
+ * href="https://stripe.com/connect/manage-payout-schedule">Learn more about controlling
+ * payout delay days.
*/
@SerializedName("delay_days")
Object delayDays;
@@ -11679,8 +11678,8 @@ public AccountUpdateParams.Settings.Payouts.Schedule build() {
* {@code minimum}, representing the lowest available value for the account country.
* Default is {@code minimum}. The {@code delay_days} parameter remains at the last
* configured value if {@code interval} is {@code manual}. Learn more about
- * controlling payout delay days.
+ * href="https://stripe.com/connect/manage-payout-schedule">Learn more about controlling
+ * payout delay days.
*/
public Builder setDelayDays(
AccountUpdateParams.Settings.Payouts.Schedule.DelayDays delayDays) {
@@ -11693,8 +11692,8 @@ public Builder setDelayDays(
* {@code minimum}, representing the lowest available value for the account country.
* Default is {@code minimum}. The {@code delay_days} parameter remains at the last
* configured value if {@code interval} is {@code manual}. Learn more about
- * controlling payout delay days.
+ * href="https://stripe.com/connect/manage-payout-schedule">Learn more about controlling
+ * payout delay days.
*/
public Builder setDelayDays(Long delayDays) {
this.delayDays = delayDays;
diff --git a/src/main/java/com/stripe/param/PaymentMethodConfigurationCreateParams.java b/src/main/java/com/stripe/param/PaymentMethodConfigurationCreateParams.java
index 2efa496cc72..554d97e02bf 100644
--- a/src/main/java/com/stripe/param/PaymentMethodConfigurationCreateParams.java
+++ b/src/main/java/com/stripe/param/PaymentMethodConfigurationCreateParams.java
@@ -364,6 +364,13 @@ public class PaymentMethodConfigurationCreateParams extends ApiRequestParams {
@SerializedName("swish")
Swish swish;
+ /**
+ * Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile
+ * phone. Check this page for more details.
+ */
+ @SerializedName("twint")
+ Twint twint;
+
/**
* Stripe users in the United States can accept ACH direct debit payments from customers with a US
* bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check
@@ -432,6 +439,7 @@ private PaymentMethodConfigurationCreateParams(
SepaDebit sepaDebit,
Sofort sofort,
Swish swish,
+ Twint twint,
UsBankAccount usBankAccount,
WechatPay wechatPay,
Zip zip) {
@@ -476,6 +484,7 @@ private PaymentMethodConfigurationCreateParams(
this.sepaDebit = sepaDebit;
this.sofort = sofort;
this.swish = swish;
+ this.twint = twint;
this.usBankAccount = usBankAccount;
this.wechatPay = wechatPay;
this.zip = zip;
@@ -568,6 +577,8 @@ public static class Builder {
private Swish swish;
+ private Twint twint;
+
private UsBankAccount usBankAccount;
private WechatPay wechatPay;
@@ -618,6 +629,7 @@ public PaymentMethodConfigurationCreateParams build() {
this.sepaDebit,
this.sofort,
this.swish,
+ this.twint,
this.usBankAccount,
this.wechatPay,
this.zip);
@@ -1099,6 +1111,16 @@ public Builder setSwish(PaymentMethodConfigurationCreateParams.Swish swish) {
return this;
}
+ /**
+ * Twint is a payment method popular in Switzerland. It allows customers to pay using their
+ * mobile phone. Check this page for more
+ * details.
+ */
+ public Builder setTwint(PaymentMethodConfigurationCreateParams.Twint twint) {
+ this.twint = twint;
+ return this;
+ }
+
/**
* Stripe users in the United States can accept ACH direct debit payments from customers with a
* US bank account using the Automated Clearing House (ACH) payments system operated by Nacha.
@@ -7185,6 +7207,169 @@ public enum Preference implements ApiRequestParams.EnumParam {
}
}
+ @Getter
+ public static class Twint {
+ /** Whether or not the payment method should be displayed. */
+ @SerializedName("display_preference")
+ DisplayPreference displayPreference;
+
+ /**
+ * Map of extra parameters for custom features not available in this client library. The content
+ * in this map is not serialized under this field's {@code @SerializedName} value. Instead, each
+ * key/value pair is serialized as if the key is a root-level field (serialized) name in this
+ * param object. Effectively, this map is flattened to its parent instance.
+ */
+ @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY)
+ Map extraParams;
+
+ private Twint(DisplayPreference displayPreference, Map extraParams) {
+ this.displayPreference = displayPreference;
+ this.extraParams = extraParams;
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ public static class Builder {
+ private DisplayPreference displayPreference;
+
+ private Map extraParams;
+
+ /** Finalize and obtain parameter instance from this builder. */
+ public PaymentMethodConfigurationCreateParams.Twint build() {
+ return new PaymentMethodConfigurationCreateParams.Twint(
+ this.displayPreference, this.extraParams);
+ }
+
+ /** Whether or not the payment method should be displayed. */
+ public Builder setDisplayPreference(
+ PaymentMethodConfigurationCreateParams.Twint.DisplayPreference displayPreference) {
+ this.displayPreference = displayPreference;
+ return this;
+ }
+
+ /**
+ * Add a key/value pair to `extraParams` map. A map is initialized for the first `put/putAll`
+ * call, and subsequent calls add additional key/value pairs to the original map. See {@link
+ * PaymentMethodConfigurationCreateParams.Twint#extraParams} for the field documentation.
+ */
+ public Builder putExtraParam(String key, Object value) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.put(key, value);
+ return this;
+ }
+
+ /**
+ * Add all map key/value pairs to `extraParams` map. A map is initialized for the first
+ * `put/putAll` call, and subsequent calls add additional key/value pairs to the original map.
+ * See {@link PaymentMethodConfigurationCreateParams.Twint#extraParams} for the field
+ * documentation.
+ */
+ public Builder putAllExtraParam(Map map) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.putAll(map);
+ return this;
+ }
+ }
+
+ @Getter
+ public static class DisplayPreference {
+ /**
+ * Map of extra parameters for custom features not available in this client library. The
+ * content in this map is not serialized under this field's {@code @SerializedName} value.
+ * Instead, each key/value pair is serialized as if the key is a root-level field (serialized)
+ * name in this param object. Effectively, this map is flattened to its parent instance.
+ */
+ @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY)
+ Map extraParams;
+
+ /** The account's preference for whether or not to display this payment method. */
+ @SerializedName("preference")
+ Preference preference;
+
+ private DisplayPreference(Map extraParams, Preference preference) {
+ this.extraParams = extraParams;
+ this.preference = preference;
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ public static class Builder {
+ private Map extraParams;
+
+ private Preference preference;
+
+ /** Finalize and obtain parameter instance from this builder. */
+ public PaymentMethodConfigurationCreateParams.Twint.DisplayPreference build() {
+ return new PaymentMethodConfigurationCreateParams.Twint.DisplayPreference(
+ this.extraParams, this.preference);
+ }
+
+ /**
+ * Add a key/value pair to `extraParams` map. A map is initialized for the first
+ * `put/putAll` call, and subsequent calls add additional key/value pairs to the original
+ * map. See {@link
+ * PaymentMethodConfigurationCreateParams.Twint.DisplayPreference#extraParams} for the field
+ * documentation.
+ */
+ public Builder putExtraParam(String key, Object value) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.put(key, value);
+ return this;
+ }
+
+ /**
+ * Add all map key/value pairs to `extraParams` map. A map is initialized for the first
+ * `put/putAll` call, and subsequent calls add additional key/value pairs to the original
+ * map. See {@link
+ * PaymentMethodConfigurationCreateParams.Twint.DisplayPreference#extraParams} for the field
+ * documentation.
+ */
+ public Builder putAllExtraParam(Map map) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.putAll(map);
+ return this;
+ }
+
+ /** The account's preference for whether or not to display this payment method. */
+ public Builder setPreference(
+ PaymentMethodConfigurationCreateParams.Twint.DisplayPreference.Preference preference) {
+ this.preference = preference;
+ return this;
+ }
+ }
+
+ public enum Preference implements ApiRequestParams.EnumParam {
+ @SerializedName("none")
+ NONE("none"),
+
+ @SerializedName("off")
+ OFF("off"),
+
+ @SerializedName("on")
+ ON("on");
+
+ @Getter(onMethod_ = {@Override})
+ private final String value;
+
+ Preference(String value) {
+ this.value = value;
+ }
+ }
+ }
+ }
+
@Getter
public static class UsBankAccount {
/** Whether or not the payment method should be displayed. */
diff --git a/src/main/java/com/stripe/param/PaymentMethodConfigurationUpdateParams.java b/src/main/java/com/stripe/param/PaymentMethodConfigurationUpdateParams.java
index 625aaa5b30c..937586dd0bf 100644
--- a/src/main/java/com/stripe/param/PaymentMethodConfigurationUpdateParams.java
+++ b/src/main/java/com/stripe/param/PaymentMethodConfigurationUpdateParams.java
@@ -365,6 +365,13 @@ public class PaymentMethodConfigurationUpdateParams extends ApiRequestParams {
@SerializedName("swish")
Swish swish;
+ /**
+ * Twint is a payment method popular in Switzerland. It allows customers to pay using their mobile
+ * phone. Check this page for more details.
+ */
+ @SerializedName("twint")
+ Twint twint;
+
/**
* Stripe users in the United States can accept ACH direct debit payments from customers with a US
* bank account using the Automated Clearing House (ACH) payments system operated by Nacha. Check
@@ -433,6 +440,7 @@ private PaymentMethodConfigurationUpdateParams(
SepaDebit sepaDebit,
Sofort sofort,
Swish swish,
+ Twint twint,
UsBankAccount usBankAccount,
WechatPay wechatPay,
Zip zip) {
@@ -477,6 +485,7 @@ private PaymentMethodConfigurationUpdateParams(
this.sepaDebit = sepaDebit;
this.sofort = sofort;
this.swish = swish;
+ this.twint = twint;
this.usBankAccount = usBankAccount;
this.wechatPay = wechatPay;
this.zip = zip;
@@ -569,6 +578,8 @@ public static class Builder {
private Swish swish;
+ private Twint twint;
+
private UsBankAccount usBankAccount;
private WechatPay wechatPay;
@@ -619,6 +630,7 @@ public PaymentMethodConfigurationUpdateParams build() {
this.sepaDebit,
this.sofort,
this.swish,
+ this.twint,
this.usBankAccount,
this.wechatPay,
this.zip);
@@ -1106,6 +1118,16 @@ public Builder setSwish(PaymentMethodConfigurationUpdateParams.Swish swish) {
return this;
}
+ /**
+ * Twint is a payment method popular in Switzerland. It allows customers to pay using their
+ * mobile phone. Check this page for more
+ * details.
+ */
+ public Builder setTwint(PaymentMethodConfigurationUpdateParams.Twint twint) {
+ this.twint = twint;
+ return this;
+ }
+
/**
* Stripe users in the United States can accept ACH direct debit payments from customers with a
* US bank account using the Automated Clearing House (ACH) payments system operated by Nacha.
@@ -7192,6 +7214,169 @@ public enum Preference implements ApiRequestParams.EnumParam {
}
}
+ @Getter
+ public static class Twint {
+ /** Whether or not the payment method should be displayed. */
+ @SerializedName("display_preference")
+ DisplayPreference displayPreference;
+
+ /**
+ * Map of extra parameters for custom features not available in this client library. The content
+ * in this map is not serialized under this field's {@code @SerializedName} value. Instead, each
+ * key/value pair is serialized as if the key is a root-level field (serialized) name in this
+ * param object. Effectively, this map is flattened to its parent instance.
+ */
+ @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY)
+ Map extraParams;
+
+ private Twint(DisplayPreference displayPreference, Map extraParams) {
+ this.displayPreference = displayPreference;
+ this.extraParams = extraParams;
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ public static class Builder {
+ private DisplayPreference displayPreference;
+
+ private Map extraParams;
+
+ /** Finalize and obtain parameter instance from this builder. */
+ public PaymentMethodConfigurationUpdateParams.Twint build() {
+ return new PaymentMethodConfigurationUpdateParams.Twint(
+ this.displayPreference, this.extraParams);
+ }
+
+ /** Whether or not the payment method should be displayed. */
+ public Builder setDisplayPreference(
+ PaymentMethodConfigurationUpdateParams.Twint.DisplayPreference displayPreference) {
+ this.displayPreference = displayPreference;
+ return this;
+ }
+
+ /**
+ * Add a key/value pair to `extraParams` map. A map is initialized for the first `put/putAll`
+ * call, and subsequent calls add additional key/value pairs to the original map. See {@link
+ * PaymentMethodConfigurationUpdateParams.Twint#extraParams} for the field documentation.
+ */
+ public Builder putExtraParam(String key, Object value) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.put(key, value);
+ return this;
+ }
+
+ /**
+ * Add all map key/value pairs to `extraParams` map. A map is initialized for the first
+ * `put/putAll` call, and subsequent calls add additional key/value pairs to the original map.
+ * See {@link PaymentMethodConfigurationUpdateParams.Twint#extraParams} for the field
+ * documentation.
+ */
+ public Builder putAllExtraParam(Map map) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.putAll(map);
+ return this;
+ }
+ }
+
+ @Getter
+ public static class DisplayPreference {
+ /**
+ * Map of extra parameters for custom features not available in this client library. The
+ * content in this map is not serialized under this field's {@code @SerializedName} value.
+ * Instead, each key/value pair is serialized as if the key is a root-level field (serialized)
+ * name in this param object. Effectively, this map is flattened to its parent instance.
+ */
+ @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY)
+ Map extraParams;
+
+ /** The account's preference for whether or not to display this payment method. */
+ @SerializedName("preference")
+ Preference preference;
+
+ private DisplayPreference(Map extraParams, Preference preference) {
+ this.extraParams = extraParams;
+ this.preference = preference;
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ public static class Builder {
+ private Map extraParams;
+
+ private Preference preference;
+
+ /** Finalize and obtain parameter instance from this builder. */
+ public PaymentMethodConfigurationUpdateParams.Twint.DisplayPreference build() {
+ return new PaymentMethodConfigurationUpdateParams.Twint.DisplayPreference(
+ this.extraParams, this.preference);
+ }
+
+ /**
+ * Add a key/value pair to `extraParams` map. A map is initialized for the first
+ * `put/putAll` call, and subsequent calls add additional key/value pairs to the original
+ * map. See {@link
+ * PaymentMethodConfigurationUpdateParams.Twint.DisplayPreference#extraParams} for the field
+ * documentation.
+ */
+ public Builder putExtraParam(String key, Object value) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.put(key, value);
+ return this;
+ }
+
+ /**
+ * Add all map key/value pairs to `extraParams` map. A map is initialized for the first
+ * `put/putAll` call, and subsequent calls add additional key/value pairs to the original
+ * map. See {@link
+ * PaymentMethodConfigurationUpdateParams.Twint.DisplayPreference#extraParams} for the field
+ * documentation.
+ */
+ public Builder putAllExtraParam(Map map) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.putAll(map);
+ return this;
+ }
+
+ /** The account's preference for whether or not to display this payment method. */
+ public Builder setPreference(
+ PaymentMethodConfigurationUpdateParams.Twint.DisplayPreference.Preference preference) {
+ this.preference = preference;
+ return this;
+ }
+ }
+
+ public enum Preference implements ApiRequestParams.EnumParam {
+ @SerializedName("none")
+ NONE("none"),
+
+ @SerializedName("off")
+ OFF("off"),
+
+ @SerializedName("on")
+ ON("on");
+
+ @Getter(onMethod_ = {@Override})
+ private final String value;
+
+ Preference(String value) {
+ this.value = value;
+ }
+ }
+ }
+ }
+
@Getter
public static class UsBankAccount {
/** Whether or not the payment method should be displayed. */
diff --git a/src/main/java/com/stripe/param/TokenCreateParams.java b/src/main/java/com/stripe/param/TokenCreateParams.java
index a63f47f90f6..84688fc1f0e 100644
--- a/src/main/java/com/stripe/param/TokenCreateParams.java
+++ b/src/main/java/com/stripe/param/TokenCreateParams.java
@@ -263,7 +263,7 @@ public static class Account {
/**
* Whether the user described by the data in the token has been shown the
+ * href="https://stripe.com/connect/account-tokens#stripe-connected-account-agreement">the
* Stripe Connected Account Agreement. When creating an account token to create a new
* Connect account, this value must be {@code true}.
*/
@@ -354,7 +354,7 @@ public Builder setIndividual(TokenCreateParams.Account.Individual individual) {
/**
* Whether the user described by the data in the token has been shown the
+ * href="https://stripe.com/connect/account-tokens#stripe-connected-account-agreement">the
* Stripe Connected Account Agreement. When creating an account token to create a new
* Connect account, this value must be {@code true}.
*/
@@ -380,7 +380,7 @@ public static class Company {
/**
* Whether the company's directors have been provided. Set this Boolean to {@code true} after
- * creating all the company's directors with the
+ * creating all the company's directors with the
* Persons API for accounts with a {@code relationship.director} requirement. This value
* is not automatically set to {@code true} after creating directors, so it needs to be
* updated to indicate all directors have been provided.
@@ -390,9 +390,8 @@ public static class Company {
/**
* Whether the company's executives have been provided. Set this Boolean to {@code true} after
- * creating all the company's executives with the Persons API for accounts with a {@code
- * relationship.executive} requirement.
+ * creating all the company's executives with the
+ * Persons API for accounts with a {@code relationship.executive} requirement.
*/
@SerializedName("executives_provided")
Boolean executivesProvided;
@@ -431,8 +430,8 @@ public static class Company {
/**
* Whether the company's owners have been provided. Set this Boolean to {@code true} after
- * creating all the company's owners with the
- * Persons API for accounts with a {@code relationship.owner} requirement.
+ * creating all the company's owners with the Persons
+ * API for accounts with a {@code relationship.owner} requirement.
*/
@SerializedName("owners_provided")
Boolean ownersProvided;
@@ -466,7 +465,7 @@ public static class Company {
/**
* The category identifying the legal structure of the company or legal entity. See Business
+ * href="https://stripe.com/connect/identity-verification#business-structure">Business
* structure for more details. Pass an empty string to unset this value.
*/
@SerializedName("structure")
@@ -634,7 +633,7 @@ public Builder setAddressKanji(
/**
* Whether the company's directors have been provided. Set this Boolean to {@code true}
* after creating all the company's directors with the Persons API for accounts with a {@code
+ * href="https://stripe.com/api/persons">the Persons API for accounts with a {@code
* relationship.director} requirement. This value is not automatically set to {@code true}
* after creating directors, so it needs to be updated to indicate all directors have been
* provided.
@@ -647,7 +646,7 @@ public Builder setDirectorsProvided(Boolean directorsProvided) {
/**
* Whether the company's executives have been provided. Set this Boolean to {@code true}
* after creating all the company's executives with the Persons API for accounts with a {@code
+ * href="https://stripe.com/api/persons">the Persons API for accounts with a {@code
* relationship.executive} requirement.
*/
public Builder setExecutivesProvided(Boolean executivesProvided) {
@@ -718,7 +717,7 @@ public Builder setNameKanji(String nameKanji) {
/**
* Whether the company's owners have been provided. Set this Boolean to {@code true} after
- * creating all the company's owners with the
+ * creating all the company's owners with the
* Persons API for accounts with a {@code relationship.owner} requirement.
*/
public Builder setOwnersProvided(Boolean ownersProvided) {
@@ -765,7 +764,7 @@ public Builder setRegistrationNumber(String registrationNumber) {
/**
* The category identifying the legal structure of the company or legal entity. See Business
+ * href="https://stripe.com/connect/identity-verification#business-structure">Business
* structure for more details. Pass an empty string to unset this value.
*/
public Builder setStructure(TokenCreateParams.Account.Company.Structure structure) {
@@ -775,7 +774,7 @@ public Builder setStructure(TokenCreateParams.Account.Company.Structure structur
/**
* The category identifying the legal structure of the company or legal entity. See Business
+ * href="https://stripe.com/connect/identity-verification#business-structure">Business
* structure for more details. Pass an empty string to unset this value.
*/
public Builder setStructure(EmptyParam structure) {
@@ -1734,7 +1733,7 @@ public static class Individual {
* The government-issued ID number of the individual, as appropriate for the representative's
* country. (Examples are a Social Security Number in the U.S., or a Social Insurance Number
* in Canada). Instead of the number itself, you can also provide a PII token created with
+ * href="https://stripe.com/js/tokens/create_token?type=pii">PII token created with
* Stripe.js.
*/
@SerializedName("id_number")
@@ -1744,8 +1743,8 @@ public static class Individual {
* The government-issued secondary ID number of the individual, as appropriate for the
* representative's country, will be used for enhanced verification checks. In Thailand, this
* would be the laser code found on the back of an ID card. Instead of the number itself, you
- * can also provide a PII
- * token created with Stripe.js.
+ * can also provide a PII token
+ * created with Stripe.js.
*/
@SerializedName("id_number_secondary")
String idNumberSecondary;
@@ -2075,7 +2074,7 @@ public Builder setGender(String gender) {
* The government-issued ID number of the individual, as appropriate for the
* representative's country. (Examples are a Social Security Number in the U.S., or a Social
* Insurance Number in Canada). Instead of the number itself, you can also provide a PII token created with
+ * href="https://stripe.com/js/tokens/create_token?type=pii">PII token created with
* Stripe.js.
*/
public Builder setIdNumber(String idNumber) {
@@ -2088,7 +2087,7 @@ public Builder setIdNumber(String idNumber) {
* representative's country, will be used for enhanced verification checks. In Thailand,
* this would be the laser code found on the back of an ID card. Instead of the number
* itself, you can also provide a PII token created with
+ * href="https://stripe.com/js/tokens/create_token?type=pii">PII token created with
* Stripe.js.
*/
public Builder setIdNumberSecondary(String idNumberSecondary) {
diff --git a/src/main/java/com/stripe/param/WebhookEndpointCreateParams.java b/src/main/java/com/stripe/param/WebhookEndpointCreateParams.java
index a3d87f9e97b..d83120a2280 100644
--- a/src/main/java/com/stripe/param/WebhookEndpointCreateParams.java
+++ b/src/main/java/com/stripe/param/WebhookEndpointCreateParams.java
@@ -865,6 +865,9 @@ public enum EnabledEvent implements ApiRequestParams.EnumParam {
@SerializedName("invoice.marked_uncollectible")
INVOICE__MARKED_UNCOLLECTIBLE("invoice.marked_uncollectible"),
+ @SerializedName("invoice.overdue")
+ INVOICE__OVERDUE("invoice.overdue"),
+
@SerializedName("invoice.paid")
INVOICE__PAID("invoice.paid"),
@@ -889,6 +892,9 @@ public enum EnabledEvent implements ApiRequestParams.EnumParam {
@SerializedName("invoice.voided")
INVOICE__VOIDED("invoice.voided"),
+ @SerializedName("invoice.will_be_due")
+ INVOICE__WILL_BE_DUE("invoice.will_be_due"),
+
@SerializedName("invoiceitem.created")
INVOICEITEM__CREATED("invoiceitem.created"),
diff --git a/src/main/java/com/stripe/param/WebhookEndpointUpdateParams.java b/src/main/java/com/stripe/param/WebhookEndpointUpdateParams.java
index ee68fc889db..ebc63b73f34 100644
--- a/src/main/java/com/stripe/param/WebhookEndpointUpdateParams.java
+++ b/src/main/java/com/stripe/param/WebhookEndpointUpdateParams.java
@@ -529,6 +529,9 @@ public enum EnabledEvent implements ApiRequestParams.EnumParam {
@SerializedName("invoice.marked_uncollectible")
INVOICE__MARKED_UNCOLLECTIBLE("invoice.marked_uncollectible"),
+ @SerializedName("invoice.overdue")
+ INVOICE__OVERDUE("invoice.overdue"),
+
@SerializedName("invoice.paid")
INVOICE__PAID("invoice.paid"),
@@ -553,6 +556,9 @@ public enum EnabledEvent implements ApiRequestParams.EnumParam {
@SerializedName("invoice.voided")
INVOICE__VOIDED("invoice.voided"),
+ @SerializedName("invoice.will_be_due")
+ INVOICE__WILL_BE_DUE("invoice.will_be_due"),
+
@SerializedName("invoiceitem.created")
INVOICEITEM__CREATED("invoiceitem.created"),
diff --git a/src/main/java/com/stripe/param/checkout/SessionUpdateParams.java b/src/main/java/com/stripe/param/checkout/SessionUpdateParams.java
new file mode 100644
index 00000000000..192847b41b9
--- /dev/null
+++ b/src/main/java/com/stripe/param/checkout/SessionUpdateParams.java
@@ -0,0 +1,162 @@
+// File generated from our OpenAPI spec
+package com.stripe.param.checkout;
+
+import com.google.gson.annotations.SerializedName;
+import com.stripe.net.ApiRequestParams;
+import com.stripe.param.common.EmptyParam;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import lombok.Getter;
+
+@Getter
+public class SessionUpdateParams extends ApiRequestParams {
+ /** Specifies which fields in the response should be expanded. */
+ @SerializedName("expand")
+ List expand;
+
+ /**
+ * Map of extra parameters for custom features not available in this client library. The content
+ * in this map is not serialized under this field's {@code @SerializedName} value. Instead, each
+ * key/value pair is serialized as if the key is a root-level field (serialized) name in this
+ * param object. Effectively, this map is flattened to its parent instance.
+ */
+ @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY)
+ Map extraParams;
+
+ /**
+ * Set of key-value pairs that you can attach
+ * to an object. This can be useful for storing additional information about the object in a
+ * structured format. Individual keys can be unset by posting an empty value to them. All keys can
+ * be unset by posting an empty value to {@code metadata}.
+ */
+ @SerializedName("metadata")
+ Object metadata;
+
+ private SessionUpdateParams(
+ List expand, Map extraParams, Object metadata) {
+ this.expand = expand;
+ this.extraParams = extraParams;
+ this.metadata = metadata;
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ public static class Builder {
+ private List expand;
+
+ private Map extraParams;
+
+ private Object metadata;
+
+ /** Finalize and obtain parameter instance from this builder. */
+ public SessionUpdateParams build() {
+ return new SessionUpdateParams(this.expand, this.extraParams, this.metadata);
+ }
+
+ /**
+ * Add an element to `expand` list. A list is initialized for the first `add/addAll` call, and
+ * subsequent calls adds additional elements to the original list. See {@link
+ * SessionUpdateParams#expand} for the field documentation.
+ */
+ public Builder addExpand(String element) {
+ if (this.expand == null) {
+ this.expand = new ArrayList<>();
+ }
+ this.expand.add(element);
+ return this;
+ }
+
+ /**
+ * Add all elements to `expand` list. A list is initialized for the first `add/addAll` call, and
+ * subsequent calls adds additional elements to the original list. See {@link
+ * SessionUpdateParams#expand} for the field documentation.
+ */
+ public Builder addAllExpand(List elements) {
+ if (this.expand == null) {
+ this.expand = new ArrayList<>();
+ }
+ this.expand.addAll(elements);
+ return this;
+ }
+
+ /**
+ * Add a key/value pair to `extraParams` map. A map is initialized for the first `put/putAll`
+ * call, and subsequent calls add additional key/value pairs to the original map. See {@link
+ * SessionUpdateParams#extraParams} for the field documentation.
+ */
+ public Builder putExtraParam(String key, Object value) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.put(key, value);
+ return this;
+ }
+
+ /**
+ * Add all map key/value pairs to `extraParams` map. A map is initialized for the first
+ * `put/putAll` call, and subsequent calls add additional key/value pairs to the original map.
+ * See {@link SessionUpdateParams#extraParams} for the field documentation.
+ */
+ public Builder putAllExtraParam(Map map) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.putAll(map);
+ return this;
+ }
+
+ /**
+ * Add a key/value pair to `metadata` map. A map is initialized for the first `put/putAll` call,
+ * and subsequent calls add additional key/value pairs to the original map. See {@link
+ * SessionUpdateParams#metadata} for the field documentation.
+ */
+ @SuppressWarnings("unchecked")
+ public Builder putMetadata(String key, String value) {
+ if (this.metadata == null || this.metadata instanceof EmptyParam) {
+ this.metadata = new HashMap();
+ }
+ ((Map) this.metadata).put(key, value);
+ return this;
+ }
+
+ /**
+ * Add all map key/value pairs to `metadata` map. A map is initialized for the first
+ * `put/putAll` call, and subsequent calls add additional key/value pairs to the original map.
+ * See {@link SessionUpdateParams#metadata} for the field documentation.
+ */
+ @SuppressWarnings("unchecked")
+ public Builder putAllMetadata(Map map) {
+ if (this.metadata == null || this.metadata instanceof EmptyParam) {
+ this.metadata = new HashMap();
+ }
+ ((Map) this.metadata).putAll(map);
+ return this;
+ }
+
+ /**
+ * Set of key-value pairs that you can attach
+ * to an object. This can be useful for storing additional information about the object in a
+ * structured format. Individual keys can be unset by posting an empty value to them. All keys
+ * can be unset by posting an empty value to {@code metadata}.
+ */
+ public Builder setMetadata(EmptyParam metadata) {
+ this.metadata = metadata;
+ return this;
+ }
+
+ /**
+ * Set of key-value pairs that you can attach
+ * to an object. This can be useful for storing additional information about the object in a
+ * structured format. Individual keys can be unset by posting an empty value to them. All keys
+ * can be unset by posting an empty value to {@code metadata}.
+ */
+ public Builder setMetadata(Map metadata) {
+ this.metadata = metadata;
+ return this;
+ }
+ }
+}
diff --git a/src/main/java/com/stripe/param/tax/CalculationCreateParams.java b/src/main/java/com/stripe/param/tax/CalculationCreateParams.java
index 8256a4d5259..7a834bdbfbc 100644
--- a/src/main/java/com/stripe/param/tax/CalculationCreateParams.java
+++ b/src/main/java/com/stripe/param/tax/CalculationCreateParams.java
@@ -995,13 +995,9 @@ public enum TaxabilityOverride implements ApiRequestParams.EnumParam {
public static class LineItem {
/**
* Required. A positive integer representing the line item's total price in the
- * smallest currency unit (e.g.,
- * 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount
- * is $0.0 US or equivalent in
- * charge currency. The amount value supports up to twelve digits (e.g., a value of
- * 999999999999 for a USD charge of $9,999,999,999.99). If {@code tax_behavior=inclusive}, then
- * this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
+ * smallest currency unit. If
+ * {@code tax_behavior=inclusive}, then this amount includes taxes. Otherwise, taxes are
+ * calculated on top of this amount.
*/
@SerializedName("amount")
Long amount;
@@ -1100,13 +1096,9 @@ public CalculationCreateParams.LineItem build() {
/**
* Required. A positive integer representing the line item's total price in
- * the smallest currency unit
- * (e.g., 100 cents to charge $1.00 or 100 to charge ¥100, a zero-decimal currency). The
- * minimum amount is $0.0 US or equivalent in
- * charge currency. The amount value supports up to twelve digits (e.g., a value of
- * 999999999999 for a USD charge of $9,999,999,999.99). If {@code tax_behavior=inclusive},
- * then this amount includes taxes. Otherwise, taxes are calculated on top of this amount.
+ * the smallest currency unit.
+ * If {@code tax_behavior=inclusive}, then this amount includes taxes. Otherwise, taxes are
+ * calculated on top of this amount.
*/
public Builder setAmount(Long amount) {
this.amount = amount;
diff --git a/src/main/java/com/stripe/service/RefundService.java b/src/main/java/com/stripe/service/RefundService.java
index 66cac1c683e..7670b4473a7 100644
--- a/src/main/java/com/stripe/service/RefundService.java
+++ b/src/main/java/com/stripe/service/RefundService.java
@@ -26,7 +26,7 @@ public RefundService(StripeResponseGetter responseGetter) {
/**
* Returns a list of all refunds you created. We return the refunds in sorted order, with the most
- * recent refunds appearing first The 10 most recent refunds are always available by default on
+ * recent refunds appearing first. The 10 most recent refunds are always available by default on
* the Charge object.
*/
public StripeCollection list(RefundListParams params) throws StripeException {
@@ -34,7 +34,7 @@ public StripeCollection list(RefundListParams params) throws StripeExcep
}
/**
* Returns a list of all refunds you created. We return the refunds in sorted order, with the most
- * recent refunds appearing first The 10 most recent refunds are always available by default on
+ * recent refunds appearing first. The 10 most recent refunds are always available by default on
* the Charge object.
*/
public StripeCollection list(RequestOptions options) throws StripeException {
@@ -42,7 +42,7 @@ public StripeCollection list(RequestOptions options) throws StripeExcept
}
/**
* Returns a list of all refunds you created. We return the refunds in sorted order, with the most
- * recent refunds appearing first The 10 most recent refunds are always available by default on
+ * recent refunds appearing first. The 10 most recent refunds are always available by default on
* the Charge object.
*/
public StripeCollection list() throws StripeException {
@@ -50,7 +50,7 @@ public StripeCollection list() throws StripeException {
}
/**
* Returns a list of all refunds you created. We return the refunds in sorted order, with the most
- * recent refunds appearing first The 10 most recent refunds are always available by default on
+ * recent refunds appearing first. The 10 most recent refunds are always available by default on
* the Charge object.
*/
public StripeCollection list(RefundListParams params, RequestOptions options)
diff --git a/src/main/java/com/stripe/service/checkout/SessionService.java b/src/main/java/com/stripe/service/checkout/SessionService.java
index 48e141856c5..7054d7a80ee 100644
--- a/src/main/java/com/stripe/service/checkout/SessionService.java
+++ b/src/main/java/com/stripe/service/checkout/SessionService.java
@@ -17,6 +17,7 @@
import com.stripe.param.checkout.SessionExpireParams;
import com.stripe.param.checkout.SessionListParams;
import com.stripe.param.checkout.SessionRetrieveParams;
+import com.stripe.param.checkout.SessionUpdateParams;
public final class SessionService extends ApiService {
public SessionService(StripeResponseGetter responseGetter) {
@@ -100,6 +101,32 @@ public Session retrieve(String session, SessionRetrieveParams params, RequestOpt
ApiMode.V1);
return this.request(request, Session.class);
}
+ /** Updates a Session object. */
+ public Session update(String session, SessionUpdateParams params) throws StripeException {
+ return update(session, params, (RequestOptions) null);
+ }
+ /** Updates a Session object. */
+ public Session update(String session, RequestOptions options) throws StripeException {
+ return update(session, (SessionUpdateParams) null, options);
+ }
+ /** Updates a Session object. */
+ public Session update(String session) throws StripeException {
+ return update(session, (SessionUpdateParams) null, (RequestOptions) null);
+ }
+ /** Updates a Session object. */
+ public Session update(String session, SessionUpdateParams params, RequestOptions options)
+ throws StripeException {
+ String path = String.format("/v1/checkout/sessions/%s", ApiResource.urlEncodeId(session));
+ ApiRequest request =
+ new ApiRequest(
+ BaseAddress.API,
+ ApiResource.RequestMethod.POST,
+ path,
+ ApiRequestParams.paramsToMap(params),
+ options,
+ ApiMode.V1);
+ return this.request(request, Session.class);
+ }
/**
* A Session can be expired when it is in one of these statuses: {@code open}
*