Skip to content

Commit 0b5c685

Browse files
Update generated code for v763
1 parent 6ad6cc4 commit 0b5c685

File tree

136 files changed

+891
-1
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

136 files changed

+891
-1
lines changed

OPENAPI_VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v762
1+
v763

src/main/java/com/stripe/model/PaymentMethodConfiguration.java

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,9 @@ public class PaymentMethodConfiguration extends ApiResource implements HasId {
100100
@SerializedName("cashapp")
101101
Cashapp cashapp;
102102

103+
@SerializedName("customer_balance")
104+
CustomerBalance customerBalance;
105+
103106
@SerializedName("eps")
104107
Eps eps;
105108

@@ -928,6 +931,49 @@ public static class DisplayPreference extends StripeObject {
928931
}
929932
}
930933

934+
@Getter
935+
@Setter
936+
@EqualsAndHashCode(callSuper = false)
937+
public static class CustomerBalance extends StripeObject {
938+
/**
939+
* Whether this payment method may be offered at checkout. True if {@code display_preference} is
940+
* {@code on} and the payment method's capability is active.
941+
*/
942+
@SerializedName("available")
943+
Boolean available;
944+
945+
@SerializedName("display_preference")
946+
DisplayPreference displayPreference;
947+
948+
@Getter
949+
@Setter
950+
@EqualsAndHashCode(callSuper = false)
951+
public static class DisplayPreference extends StripeObject {
952+
/**
953+
* For child configs, whether or not the account's preference will be observed. If {@code
954+
* false}, the parent configuration's default is used.
955+
*/
956+
@SerializedName("overridable")
957+
Boolean overridable;
958+
959+
/**
960+
* The account's display preference.
961+
*
962+
* <p>One of {@code none}, {@code off}, or {@code on}.
963+
*/
964+
@SerializedName("preference")
965+
String preference;
966+
967+
/**
968+
* The effective display preference value.
969+
*
970+
* <p>One of {@code off}, or {@code on}.
971+
*/
972+
@SerializedName("value")
973+
String value;
974+
}
975+
}
976+
931977
@Getter
932978
@Setter
933979
@EqualsAndHashCode(callSuper = false)
@@ -2019,6 +2065,7 @@ public void setResponseGetter(StripeResponseGetter responseGetter) {
20192065
trySetResponseGetter(card, responseGetter);
20202066
trySetResponseGetter(cartesBancaires, responseGetter);
20212067
trySetResponseGetter(cashapp, responseGetter);
2068+
trySetResponseGetter(customerBalance, responseGetter);
20222069
trySetResponseGetter(eps, responseGetter);
20232070
trySetResponseGetter(fpx, responseGetter);
20242071
trySetResponseGetter(giropay, responseGetter);

src/main/java/com/stripe/param/AccountUpdateParams.java

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -388,6 +388,26 @@ public Builder setExternalAccount(AccountUpdateParams.Card externalAccount) {
388388
return this;
389389
}
390390

391+
/**
392+
* A card or bank account to attach to the account for receiving <a
393+
* href="https://stripe.com/docs/connect/bank-debit-card-payouts">payouts</a> (you won’t be able
394+
* to use it for top-ups). You can provide either a token, like the ones returned by <a
395+
* href="https://stripe.com/docs/js">Stripe.js</a>, or a dictionary, as documented in the {@code
396+
* external_account} parameter for <a
397+
* href="https://stripe.com/docs/api#account_create_bank_account">bank account</a> creation.
398+
* <br>
399+
* <br>
400+
* By default, providing an external account sets it as the new default external account for its
401+
* currency, and deletes the old default if one exists. To add additional external accounts
402+
* without replacing the existing default for the currency, use the <a
403+
* href="https://stripe.com/docs/api#account_create_bank_account">bank account</a> or <a
404+
* href="https://stripe.com/docs/api#account_create_card">card creation</a> APIs.
405+
*/
406+
public Builder setExternalAccount(EmptyParam externalAccount) {
407+
this.externalAccount = externalAccount;
408+
return this;
409+
}
410+
391411
/**
392412
* Add a key/value pair to `extraParams` map. A map is initialized for the first `put/putAll`
393413
* call, and subsequent calls add additional key/value pairs to the original map. See {@link

src/main/java/com/stripe/param/PaymentMethodConfigurationCreateParams.java

Lines changed: 190 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,14 @@ public class PaymentMethodConfigurationCreateParams extends ApiRequestParams {
132132
@SerializedName("cashapp")
133133
Cashapp cashapp;
134134

135+
/**
136+
* Uses a customer’s <a href="https://stripe.com/docs/payments/customer-balance">cash balance</a>
137+
* for the payment. The cash balance can be funded via a bank transfer. Check this <a
138+
* href="https://stripe.com/docs/payments/bank-transfers">page</a> for more details.
139+
*/
140+
@SerializedName("customer_balance")
141+
CustomerBalance customerBalance;
142+
135143
/**
136144
* EPS is an Austria-based payment method that allows customers to complete transactions online
137145
* using their bank credentials. EPS is supported by all Austrian banks and is accepted by over
@@ -354,6 +362,7 @@ private PaymentMethodConfigurationCreateParams(
354362
Card card,
355363
CartesBancaires cartesBancaires,
356364
Cashapp cashapp,
365+
CustomerBalance customerBalance,
357366
Eps eps,
358367
List<String> expand,
359368
Map<String, Object> extraParams,
@@ -392,6 +401,7 @@ private PaymentMethodConfigurationCreateParams(
392401
this.card = card;
393402
this.cartesBancaires = cartesBancaires;
394403
this.cashapp = cashapp;
404+
this.customerBalance = customerBalance;
395405
this.eps = eps;
396406
this.expand = expand;
397407
this.extraParams = extraParams;
@@ -451,6 +461,8 @@ public static class Builder {
451461

452462
private Cashapp cashapp;
453463

464+
private CustomerBalance customerBalance;
465+
454466
private Eps eps;
455467

456468
private List<String> expand;
@@ -516,6 +528,7 @@ public PaymentMethodConfigurationCreateParams build() {
516528
this.card,
517529
this.cartesBancaires,
518530
this.cashapp,
531+
this.customerBalance,
519532
this.eps,
520533
this.expand,
521534
this.extraParams,
@@ -694,6 +707,17 @@ public Builder setCashapp(PaymentMethodConfigurationCreateParams.Cashapp cashapp
694707
return this;
695708
}
696709

710+
/**
711+
* Uses a customer’s <a href="https://stripe.com/docs/payments/customer-balance">cash
712+
* balance</a> for the payment. The cash balance can be funded via a bank transfer. Check this
713+
* <a href="https://stripe.com/docs/payments/bank-transfers">page</a> for more details.
714+
*/
715+
public Builder setCustomerBalance(
716+
PaymentMethodConfigurationCreateParams.CustomerBalance customerBalance) {
717+
this.customerBalance = customerBalance;
718+
return this;
719+
}
720+
697721
/**
698722
* EPS is an Austria-based payment method that allows customers to complete transactions online
699723
* using their bank credentials. EPS is supported by all Austrian banks and is accepted by over
@@ -3285,6 +3309,172 @@ public enum Preference implements ApiRequestParams.EnumParam {
32853309
}
32863310
}
32873311

3312+
@Getter
3313+
public static class CustomerBalance {
3314+
/** Whether or not the payment method should be displayed. */
3315+
@SerializedName("display_preference")
3316+
DisplayPreference displayPreference;
3317+
3318+
/**
3319+
* Map of extra parameters for custom features not available in this client library. The content
3320+
* in this map is not serialized under this field's {@code @SerializedName} value. Instead, each
3321+
* key/value pair is serialized as if the key is a root-level field (serialized) name in this
3322+
* param object. Effectively, this map is flattened to its parent instance.
3323+
*/
3324+
@SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY)
3325+
Map<String, Object> extraParams;
3326+
3327+
private CustomerBalance(DisplayPreference displayPreference, Map<String, Object> extraParams) {
3328+
this.displayPreference = displayPreference;
3329+
this.extraParams = extraParams;
3330+
}
3331+
3332+
public static Builder builder() {
3333+
return new Builder();
3334+
}
3335+
3336+
public static class Builder {
3337+
private DisplayPreference displayPreference;
3338+
3339+
private Map<String, Object> extraParams;
3340+
3341+
/** Finalize and obtain parameter instance from this builder. */
3342+
public PaymentMethodConfigurationCreateParams.CustomerBalance build() {
3343+
return new PaymentMethodConfigurationCreateParams.CustomerBalance(
3344+
this.displayPreference, this.extraParams);
3345+
}
3346+
3347+
/** Whether or not the payment method should be displayed. */
3348+
public Builder setDisplayPreference(
3349+
PaymentMethodConfigurationCreateParams.CustomerBalance.DisplayPreference
3350+
displayPreference) {
3351+
this.displayPreference = displayPreference;
3352+
return this;
3353+
}
3354+
3355+
/**
3356+
* Add a key/value pair to `extraParams` map. A map is initialized for the first `put/putAll`
3357+
* call, and subsequent calls add additional key/value pairs to the original map. See {@link
3358+
* PaymentMethodConfigurationCreateParams.CustomerBalance#extraParams} for the field
3359+
* documentation.
3360+
*/
3361+
public Builder putExtraParam(String key, Object value) {
3362+
if (this.extraParams == null) {
3363+
this.extraParams = new HashMap<>();
3364+
}
3365+
this.extraParams.put(key, value);
3366+
return this;
3367+
}
3368+
3369+
/**
3370+
* Add all map key/value pairs to `extraParams` map. A map is initialized for the first
3371+
* `put/putAll` call, and subsequent calls add additional key/value pairs to the original map.
3372+
* See {@link PaymentMethodConfigurationCreateParams.CustomerBalance#extraParams} for the
3373+
* field documentation.
3374+
*/
3375+
public Builder putAllExtraParam(Map<String, Object> map) {
3376+
if (this.extraParams == null) {
3377+
this.extraParams = new HashMap<>();
3378+
}
3379+
this.extraParams.putAll(map);
3380+
return this;
3381+
}
3382+
}
3383+
3384+
@Getter
3385+
public static class DisplayPreference {
3386+
/**
3387+
* Map of extra parameters for custom features not available in this client library. The
3388+
* content in this map is not serialized under this field's {@code @SerializedName} value.
3389+
* Instead, each key/value pair is serialized as if the key is a root-level field (serialized)
3390+
* name in this param object. Effectively, this map is flattened to its parent instance.
3391+
*/
3392+
@SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY)
3393+
Map<String, Object> extraParams;
3394+
3395+
/** The account's preference for whether or not to display this payment method. */
3396+
@SerializedName("preference")
3397+
Preference preference;
3398+
3399+
private DisplayPreference(Map<String, Object> extraParams, Preference preference) {
3400+
this.extraParams = extraParams;
3401+
this.preference = preference;
3402+
}
3403+
3404+
public static Builder builder() {
3405+
return new Builder();
3406+
}
3407+
3408+
public static class Builder {
3409+
private Map<String, Object> extraParams;
3410+
3411+
private Preference preference;
3412+
3413+
/** Finalize and obtain parameter instance from this builder. */
3414+
public PaymentMethodConfigurationCreateParams.CustomerBalance.DisplayPreference build() {
3415+
return new PaymentMethodConfigurationCreateParams.CustomerBalance.DisplayPreference(
3416+
this.extraParams, this.preference);
3417+
}
3418+
3419+
/**
3420+
* Add a key/value pair to `extraParams` map. A map is initialized for the first
3421+
* `put/putAll` call, and subsequent calls add additional key/value pairs to the original
3422+
* map. See {@link
3423+
* PaymentMethodConfigurationCreateParams.CustomerBalance.DisplayPreference#extraParams} for
3424+
* the field documentation.
3425+
*/
3426+
public Builder putExtraParam(String key, Object value) {
3427+
if (this.extraParams == null) {
3428+
this.extraParams = new HashMap<>();
3429+
}
3430+
this.extraParams.put(key, value);
3431+
return this;
3432+
}
3433+
3434+
/**
3435+
* Add all map key/value pairs to `extraParams` map. A map is initialized for the first
3436+
* `put/putAll` call, and subsequent calls add additional key/value pairs to the original
3437+
* map. See {@link
3438+
* PaymentMethodConfigurationCreateParams.CustomerBalance.DisplayPreference#extraParams} for
3439+
* the field documentation.
3440+
*/
3441+
public Builder putAllExtraParam(Map<String, Object> map) {
3442+
if (this.extraParams == null) {
3443+
this.extraParams = new HashMap<>();
3444+
}
3445+
this.extraParams.putAll(map);
3446+
return this;
3447+
}
3448+
3449+
/** The account's preference for whether or not to display this payment method. */
3450+
public Builder setPreference(
3451+
PaymentMethodConfigurationCreateParams.CustomerBalance.DisplayPreference.Preference
3452+
preference) {
3453+
this.preference = preference;
3454+
return this;
3455+
}
3456+
}
3457+
3458+
public enum Preference implements ApiRequestParams.EnumParam {
3459+
@SerializedName("none")
3460+
NONE("none"),
3461+
3462+
@SerializedName("off")
3463+
OFF("off"),
3464+
3465+
@SerializedName("on")
3466+
ON("on");
3467+
3468+
@Getter(onMethod_ = {@Override})
3469+
private final String value;
3470+
3471+
Preference(String value) {
3472+
this.value = value;
3473+
}
3474+
}
3475+
}
3476+
}
3477+
32883478
@Getter
32893479
public static class Eps {
32903480
/** Whether or not the payment method should be displayed. */

0 commit comments

Comments
 (0)