diff --git a/CHANGELOG.md b/CHANGELOG.md
index ac6a1f8375e..46fd0415d0e 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -6,6 +6,17 @@
* Add support for `external_account_collection` on `AccountSessionCreateParams.components.financial_account.features`
* Add support for `subscription_trial_from_plan` on `InvoiceUpcomingLinesParams` and `InvoiceUpcomingParams`
+## 25.3.0 - 2024-04-18
+* [#1782](https://github.com/stripe/stripe-java/pull/1782) Update generated code
+ * Add support for `create_preview` method on resource `Invoice`
+ * Add support for `payment_method_data` on `checkout.SessionCreateParams`
+ * Add support for `saved_payment_method_options` on `Checkout.Session` and `checkout.SessionCreateParams`
+ * Add support for `mobilepay` on `Checkout.Session.payment_method_options` and `checkout.SessionCreateParams.payment_method_options`
+ * Add support for new value `mobilepay` on enum `checkout.SessionCreateParams.payment_method_types[]`
+ * Add support for `allow_redisplay` on `ConfirmationTokenCreateParams.payment_method_data`, `CustomerListPaymentMethodsParams`, `PaymentIntentConfirmParams.payment_method_data`, `PaymentIntentCreateParams.payment_method_data`, `PaymentIntentUpdateParams.payment_method_data`, `PaymentMethodCreateParams`, `PaymentMethodUpdateParams`, `SetupIntentConfirmParams.payment_method_data`, `SetupIntentCreateParams.payment_method_data`, and `SetupIntentUpdateParams.payment_method_data`
+ * Add support for `schedule_details` and `subscription_details` on `InvoiceUpcomingLinesParams` and `InvoiceUpcomingParams`
+ * Add support for new value `other` on enums `issuing.AuthorizationCaptureParams.purchase_details.fuel.unit`, `issuing.TransactionCreateForceCaptureParams.purchase_details.fuel.unit`, and `issuing.TransactionCreateUnlinkedRefundParams.purchase_details.fuel.unit`
+
## 25.2.0 - 2024-04-16
* [#1780](https://github.com/stripe/stripe-java/pull/1780) Update generated code
* Add support for new resource `Entitlements.ActiveEntitlementSummary`
diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION
index e0b27350867..6eb80deb21c 100644
--- a/OPENAPI_VERSION
+++ b/OPENAPI_VERSION
@@ -1 +1 @@
-v972
\ No newline at end of file
+v992
\ No newline at end of file
diff --git a/src/main/java/com/stripe/model/Account.java b/src/main/java/com/stripe/model/Account.java
index 711396c1f91..59b94a9596a 100644
--- a/src/main/java/com/stripe/model/Account.java
+++ b/src/main/java/com/stripe/model/Account.java
@@ -29,12 +29,17 @@
* account like its current requirements or if the account is enabled to make live charges or
* receive payouts.
*
- *
For Custom accounts, the properties below are always returned. For other accounts, some
- * properties are returned until that account has started to go through Connect Onboarding. Once you
- * create an Account Link or Account Session, some properties are only
- * returned for Custom accounts. Learn about the differences between accounts.
+ *
For accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, the properties below are always returned.
+ *
+ *
For accounts where controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, some properties are only
+ * returned until you create an Account Link or
+ * Account Session to start Connect
+ * Onboarding. Learn about the differences between
+ * accounts.
*/
@Getter
@Setter
@@ -45,10 +50,11 @@ public class Account extends ApiResource implements MetadataStore, Paym
BusinessProfile businessProfile;
/**
- * The business type. Once you create an Account Link or Account Session, this property is only
- * returned for Custom accounts.
+ * The business type. After you create an Account
+ * Link or Account Session, this
+ * property is only returned for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*
* One of {@code company}, {@code government_entity}, {@code individual}, or {@code
* non_profit}.
@@ -90,8 +96,8 @@ public class Account extends ApiResource implements MetadataStore, Paym
Boolean deleted;
/**
- * Whether account details have been submitted. Standard accounts cannot receive payouts before
- * this is true.
+ * Whether account details have been submitted. Accounts with Stripe Dashboard access, which
+ * includes Standard accounts, cannot receive payouts before this is true.
*/
@SerializedName("details_submitted")
Boolean detailsSubmitted;
@@ -121,15 +127,16 @@ public class Account extends ApiResource implements MetadataStore, Paym
/**
* This is an object representing a person associated with a Stripe account.
*
- * A platform cannot access a Standard or Express account's persons after the account starts
- * onboarding, such as after generating an account link for the account. See the Standard onboarding or Express onboarding documentation
- * for information about platform prefilling and account onboarding steps.
+ *
A platform cannot access a person for an account where account.controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, after creating an Account Link
+ * or Account Session to start Connect onboarding.
*
- *
Related guide: Handling
- * identity verification with the API
+ *
See the Standard onboarding or Express onboarding documentation for
+ * information about prefilling information and account onboarding steps. Learn more about handling
+ * identity verification with the API.
*/
@SerializedName("individual")
Person individual;
@@ -168,7 +175,10 @@ public class Account extends ApiResource implements MetadataStore, Paym
@SerializedName("tos_acceptance")
TosAcceptance tosAcceptance;
- /** The Stripe account type. Can be {@code standard}, {@code express}, or {@code custom}. */
+ /**
+ * The Stripe account type. Can be {@code standard}, {@code express}, {@code custom}, or {@code
+ * none}.
+ */
@SerializedName("type")
String type;
@@ -304,11 +314,14 @@ public static Account create(AccountCreateParams params, RequestOptions options)
}
/**
- * With Connect, you can delete accounts you manage.
+ * With Connect, you can delete accounts you manage.
*
- * Accounts created using test-mode keys can be deleted at any time. Standard accounts created
- * using live-mode keys cannot be deleted. Custom or Express accounts created using live-mode keys
- * can only be deleted once all balances are zero.
+ *
Test-mode accounts can be deleted at any time.
+ *
+ *
Live-mode accounts where Stripe is responsible for negative account balances cannot be
+ * deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for
+ * negative account balances, which includes Custom and Express accounts, can be deleted when all
+ * balances are zero.
*
*
If you want to delete your own account, use the account information tab in your account
@@ -319,11 +332,14 @@ public Account delete() throws StripeException {
}
/**
- * With Connect, you can delete accounts you manage.
+ * With Connect, you can delete accounts you manage.
+ *
+ *
Test-mode accounts can be deleted at any time.
*
- *
Accounts created using test-mode keys can be deleted at any time. Standard accounts created
- * using live-mode keys cannot be deleted. Custom or Express accounts created using live-mode keys
- * can only be deleted once all balances are zero.
+ *
Live-mode accounts where Stripe is responsible for negative account balances cannot be
+ * deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for
+ * negative account balances, which includes Custom and Express accounts, can be deleted when all
+ * balances are zero.
*
*
If you want to delete your own account, use the account information tab in your account
@@ -334,11 +350,14 @@ public Account delete(RequestOptions options) throws StripeException {
}
/**
- * With Connect, you can delete accounts you manage.
+ * With Connect, you can delete accounts you manage.
+ *
+ *
Test-mode accounts can be deleted at any time.
*
- *
Accounts created using test-mode keys can be deleted at any time. Standard accounts created
- * using live-mode keys cannot be deleted. Custom or Express accounts created using live-mode keys
- * can only be deleted once all balances are zero.
+ *
Live-mode accounts where Stripe is responsible for negative account balances cannot be
+ * deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for
+ * negative account balances, which includes Custom and Express accounts, can be deleted when all
+ * balances are zero.
*
*
If you want to delete your own account, use the account information tab in your account
@@ -349,11 +368,14 @@ public Account delete(Map params) throws StripeException {
}
/**
- * With Connect, you can delete accounts you manage.
+ * With Connect, you can delete accounts you manage.
*
- * Accounts created using test-mode keys can be deleted at any time. Standard accounts created
- * using live-mode keys cannot be deleted. Custom or Express accounts created using live-mode keys
- * can only be deleted once all balances are zero.
+ *
Test-mode accounts can be deleted at any time.
+ *
+ *
Live-mode accounts where Stripe is responsible for negative account balances cannot be
+ * deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for
+ * negative account balances, which includes Custom and Express accounts, can be deleted when all
+ * balances are zero.
*
*
If you want to delete your own account, use the account information tab in your account
@@ -476,22 +498,24 @@ public PersonCollection persons(AccountPersonsParams params, RequestOptions opti
}
/**
- * With Connect, you may flag accounts as
- * suspicious.
+ * With Connect, you can reject accounts that you have
+ * flagged as suspicious.
*
- *
Test-mode Custom and Express accounts can be rejected at any time. Accounts created using
- * live-mode keys may only be rejected once all balances are zero.
+ *
Only accounts where your platform is liable for negative account balances, which includes
+ * Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time.
+ * Live-mode accounts can only be rejected after all balances are zero.
*/
public Account reject(Map params) throws StripeException {
return reject(params, (RequestOptions) null);
}
/**
- * With Connect, you may flag accounts as
- * suspicious.
+ * With Connect, you can reject accounts that you have
+ * flagged as suspicious.
*
- * Test-mode Custom and Express accounts can be rejected at any time. Accounts created using
- * live-mode keys may only be rejected once all balances are zero.
+ *
Only accounts where your platform is liable for negative account balances, which includes
+ * Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time.
+ * Live-mode accounts can only be rejected after all balances are zero.
*/
public Account reject(Map params, RequestOptions options) throws StripeException {
String path = String.format("/v1/accounts/%s/reject", ApiResource.urlEncodeId(this.getId()));
@@ -502,22 +526,24 @@ public Account reject(Map params, RequestOptions options) throws
}
/**
- * With Connect, you may flag accounts as
- * suspicious.
+ * With Connect, you can reject accounts that you have
+ * flagged as suspicious.
*
- * Test-mode Custom and Express accounts can be rejected at any time. Accounts created using
- * live-mode keys may only be rejected once all balances are zero.
+ *
Only accounts where your platform is liable for negative account balances, which includes
+ * Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time.
+ * Live-mode accounts can only be rejected after all balances are zero.
*/
public Account reject(AccountRejectParams params) throws StripeException {
return reject(params, (RequestOptions) null);
}
/**
- * With Connect, you may flag accounts as
- * suspicious.
+ * With Connect, you can reject accounts that you have
+ * flagged as suspicious.
*
- *
Test-mode Custom and Express accounts can be rejected at any time. Accounts created using
- * live-mode keys may only be rejected once all balances are zero.
+ *
Only accounts where your platform is liable for negative account balances, which includes
+ * Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time.
+ * Live-mode accounts can only be rejected after all balances are zero.
*/
public Account reject(AccountRejectParams params, RequestOptions options) throws StripeException {
String path = String.format("/v1/accounts/%s/reject", ApiResource.urlEncodeId(this.getId()));
@@ -606,14 +632,20 @@ public static Account retrieve(AccountRetrieveParams params, RequestOptions opti
}
/**
- * Updates a connected account by setting
- * the values of the parameters passed. Any parameters not provided are left unchanged.
+ * Updates a connected account by setting the
+ * values of the parameters passed. Any parameters not provided are left unchanged.
+ *
+ *
For accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, you can update any information on the
+ * account.
*
- *
For Custom accounts, you can update any information on the account. For other accounts, you
- * can update all information until that account has started to go through Connect Onboarding.
- * Once you create an Account Link or Account Session, some properties can
- * only be changed or updated for Custom accounts.
+ *
For accounts where controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, you can update all information
+ * until you create an Account Link or Account Session to start Connect onboarding,
+ * after which some properties can no longer be updated.
*
*
To update your own account, use the Dashboard. Refer to our params) throws StripeException {
}
/**
- * Updates a connected account by setting
- * the values of the parameters passed. Any parameters not provided are left unchanged.
+ * Updates a connected account by setting the
+ * values of the parameters passed. Any parameters not provided are left unchanged.
+ *
+ *
For accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, you can update any information on the
+ * account.
*
- *
For Custom accounts, you can update any information on the account. For other accounts, you
- * can update all information until that account has started to go through Connect Onboarding.
- * Once you create an Account Link or Account Session, some properties can
- * only be changed or updated for Custom accounts.
+ *
For accounts where controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, you can update all information
+ * until you create an Account Link or Account Session to start Connect onboarding,
+ * after which some properties can no longer be updated.
*
*
To update your own account, use the Dashboard. Refer to our params, RequestOptions options) throws
}
/**
- * Updates a connected account by setting
- * the values of the parameters passed. Any parameters not provided are left unchanged.
+ * Updates a connected account by setting the
+ * values of the parameters passed. Any parameters not provided are left unchanged.
*
- *
For Custom accounts, you can update any information on the account. For other accounts, you
- * can update all information until that account has started to go through Connect Onboarding.
- * Once you create an Account Link or Account Session, some properties can
- * only be changed or updated for Custom accounts.
+ *
For accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, you can update any information on the
+ * account.
+ *
+ *
For accounts where controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, you can update all information
+ * until you create an Account Link or Account Session to start Connect onboarding,
+ * after which some properties can no longer be updated.
*
*
To update your own account, use the Dashboard. Refer to our connected account by setting
- * the values of the parameters passed. Any parameters not provided are left unchanged.
+ * Updates a connected account by setting the
+ * values of the parameters passed. Any parameters not provided are left unchanged.
+ *
+ *
For accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, you can update any information on the
+ * account.
*
- *
For Custom accounts, you can update any information on the account. For other accounts, you
- * can update all information until that account has started to go through Connect Onboarding.
- * Once you create an Account Link or Account Session, some properties can
- * only be changed or updated for Custom accounts.
+ *
For accounts where controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, you can update all information
+ * until you create an Account Link or Account Session to start Connect onboarding,
+ * after which some properties can no longer be updated.
*
*
To update your own account, use the Dashboard. Refer to our fee behavior on
+ * connected accounts.
*
*
One of {@code account}, {@code application}, {@code application_custom}, {@code
* application_express}, or {@code application_unified_accounts_beta}.
@@ -2308,10 +2360,10 @@ public static class Payments extends StripeObject {
public static class Payouts extends StripeObject {
/**
* A Boolean indicating if Stripe should try to reclaim negative balances from an attached
- * bank account. See our Understanding Connect Account
- * Balances documentation for details. Default value is {@code false} for Custom accounts,
- * otherwise {@code true}.
+ * bank account. See Understanding
+ * Connect account balances for details. The default value is {@code false} when controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, otherwise {@code true}.
*/
@SerializedName("debit_negative_balances")
Boolean debitNegativeBalances;
diff --git a/src/main/java/com/stripe/model/Balance.java b/src/main/java/com/stripe/model/Balance.java
index 7f4bbf7a542..f1d056f3533 100644
--- a/src/main/java/com/stripe/model/Balance.java
+++ b/src/main/java/com/stripe/model/Balance.java
@@ -45,8 +45,10 @@ public class Balance extends ApiResource {
List available;
/**
- * Funds held due to negative balances on connected Custom accounts. You can find the connect
- * reserve balance for each currency and payment type in the {@code source_types} property.
+ * Funds held due to negative balances on connected accounts where account.controller.requirement_collection
+ * is {@code application}, which includes Custom accounts. You can find the connect reserve
+ * balance for each currency and payment type in the {@code source_types} property.
*/
@SerializedName("connect_reserved")
List connectReserved;
diff --git a/src/main/java/com/stripe/model/BankAccount.java b/src/main/java/com/stripe/model/BankAccount.java
index 1a544855c35..66e83d3a74c 100644
--- a/src/main/java/com/stripe/model/BankAccount.java
+++ b/src/main/java/com/stripe/model/BankAccount.java
@@ -23,13 +23,15 @@
/**
* These bank accounts are payment methods on {@code Customer} objects.
*
- * On the other hand External
- * Accounts are transfer destinations on {@code Account} objects for Custom accounts. They can be bank
- * accounts or debit cards as well, and are documented in the links above.
+ *
On the other hand External Accounts are
+ * transfer destinations on {@code Account} objects for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts. They can be bank accounts
+ * or debit cards as well, and are documented in the links above.
*
- *
Related guide: Bank debits
- * and transfers
+ *
Related guide: Bank debits and
+ * transfers
*/
@Getter
@Setter
diff --git a/src/main/java/com/stripe/model/Capability.java b/src/main/java/com/stripe/model/Capability.java
index 79ed5b62d65..0efd8ecc523 100644
--- a/src/main/java/com/stripe/model/Capability.java
+++ b/src/main/java/com/stripe/model/Capability.java
@@ -333,18 +333,23 @@ public static class Requirements extends StripeObject {
/**
* If the capability is disabled, this string describes why. Can be {@code
- * requirements.past_due}, {@code requirements.pending_verification}, {@code listed}, {@code
- * platform_paused}, {@code rejected.fraud}, {@code rejected.listed}, {@code
- * rejected.terms_of_service}, {@code rejected.other}, {@code under_review}, or {@code other}.
+ * requirements.fields_needed}, {@code pending.onboarding}, {@code pending.review}, {@code
+ * rejected.fraud}, {@code rejected.other}, {@code platform_paused}, {@code
+ * action_required.requested_capabilities}, {@code rejected.inactivty}, or {@code
+ * rejected.unsupported_business}.
*
*
{@code rejected.unsupported_business} means that the account's business is not supported
* by the capability. For example, payment methods may restrict the businesses they support in
- * their terms of service:
+ * their terms of service, such as in Afterpay Clearpay's
+ * terms of service.
*
- *
- Afterpay
- * Clearpay's terms of service
+ *
{@code rejected.inactivity} means that the capability has been paused for inactivity. This
+ * disabled reason currently only applies to the Issuing capability. See Issuing:
+ * Managing Inactive Connects for more details.
*
- *
If you believe that the rejection is in error, please contact support at
+ *
If you believe that a rejection is in error, please contact support at
* https://support.stripe.com/contact/ for assistance.
*/
@SerializedName("disabled_reason")
diff --git a/src/main/java/com/stripe/model/Card.java b/src/main/java/com/stripe/model/Card.java
index 748e835a287..570012472a9 100644
--- a/src/main/java/com/stripe/model/Card.java
+++ b/src/main/java/com/stripe/model/Card.java
@@ -31,7 +31,10 @@ public class Card extends ApiResource
implements MetadataStore, ExternalAccount, PaymentSource {
/**
* The account this card belongs to. This attribute will not be in the card object if the card
- * belongs to a customer or recipient instead.
+ * belongs to a customer or recipient instead. This property is only available for accounts where
+ * controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("account")
@Getter(lombok.AccessLevel.NONE)
@@ -101,7 +104,9 @@ public class Card extends ApiResource
/**
* Three-letter ISO code for currency. Only
* applicable on accounts (not customers or recipients). The card can be used as a transfer
- * destination for funds in this currency.
+ * destination for funds in this currency. This property is only available for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("currency")
String currency;
@@ -126,7 +131,12 @@ public class Card extends ApiResource
@SerializedName("cvc_check")
String cvcCheck;
- /** Whether this card is the default external account for its currency. */
+ /**
+ * Whether this card is the default external account for its currency. This property is only
+ * available for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
+ */
@SerializedName("default_for_currency")
Boolean defaultForCurrency;
diff --git a/src/main/java/com/stripe/model/ConfirmationToken.java b/src/main/java/com/stripe/model/ConfirmationToken.java
index 5a66e815e31..b58fb4b1480 100644
--- a/src/main/java/com/stripe/model/ConfirmationToken.java
+++ b/src/main/java/com/stripe/model/ConfirmationToken.java
@@ -38,7 +38,7 @@ public class ConfirmationToken extends ApiResource implements HasId {
/**
* Time at which this ConfirmationToken expires and can no longer be used to confirm a
- * PaymentIntent or SetupIntent. This is set to null once this ConfirmationToken has been used.
+ * PaymentIntent or SetupIntent.
*/
@SerializedName("expires_at")
Long expiresAt;
diff --git a/src/main/java/com/stripe/model/Event.java b/src/main/java/com/stripe/model/Event.java
index 6d1c3387567..7aebc547b60 100644
--- a/src/main/java/com/stripe/model/Event.java
+++ b/src/main/java/com/stripe/model/Event.java
@@ -37,10 +37,10 @@
* separate webhooks system for sending the
* {@code Event} objects directly to an endpoint on your server. You can manage webhooks in your account settings. Learn how to listen for events so that your integration can
+ * href="https://docs.stripe.com/webhooks">listen for events
so that your integration can
* automatically trigger reactions.
*
- *
When using Connect, you can also receive event
+ *
When using Connect, you can also receive event
* notifications that occur in connected accounts. For these events, there's an additional {@code
* account} attribute in the received {@code Event} object.
*
@@ -98,8 +98,8 @@ public class Event extends ApiResource implements HasId {
/**
* Information about the action that causes the event. Only present when the event is triggered by
- * an API request or an Automation action.
+ * an API request or an Automation
+ * action.
*/
@SerializedName("reason")
Reason reason;
@@ -231,7 +231,7 @@ public class Event extends ApiResource implements HasId {
/**
* List events, going back up to 30 days. Each event data is rendered according to Stripe API
* version at its creation time, specified in event object {@code api_version} attribute
+ * href="https://docs.stripe.com/api/events/object">event object {@code api_version} attribute
* (not according to your current Stripe API version or {@code Stripe-Version} header).
*/
public static EventCollection list(Map params) throws StripeException {
@@ -241,7 +241,7 @@ public static EventCollection list(Map params) throws StripeExce
/**
* List events, going back up to 30 days. Each event data is rendered according to Stripe API
* version at its creation time, specified in event object {@code api_version} attribute
+ * href="https://docs.stripe.com/api/events/object">event object {@code api_version} attribute
* (not according to your current Stripe API version or {@code Stripe-Version} header).
*/
public static EventCollection list(Map params, RequestOptions options)
@@ -256,7 +256,7 @@ public static EventCollection list(Map params, RequestOptions op
/**
* List events, going back up to 30 days. Each event data is rendered according to Stripe API
* version at its creation time, specified in event object {@code api_version} attribute
+ * href="https://docs.stripe.com/api/events/object">event object {@code api_version} attribute
* (not according to your current Stripe API version or {@code Stripe-Version} header).
*/
public static EventCollection list(EventListParams params) throws StripeException {
@@ -266,7 +266,7 @@ public static EventCollection list(EventListParams params) throws StripeExceptio
/**
* List events, going back up to 30 days. Each event data is rendered according to Stripe API
* version at its creation time, specified in event object {@code api_version} attribute
+ * href="https://docs.stripe.com/api/events/object">event object {@code api_version} attribute
* (not according to your current Stripe API version or {@code Stripe-Version} header).
*/
public static EventCollection list(EventListParams params, RequestOptions options)
@@ -420,8 +420,8 @@ public static class AutomationAction extends StripeObject {
/**
* The trigger name of the automation that triggered this action. Please visit Revenue
- * and retention automations for all possible trigger names.
+ * href="https://docs.stripe.com/billing/automations#choose-a-trigger">Revenue and retention
+ * automations for all possible trigger names.
*/
@SerializedName("trigger")
String trigger;
diff --git a/src/main/java/com/stripe/model/Invoice.java b/src/main/java/com/stripe/model/Invoice.java
index 98be6e66267..28a2f5ad64f 100644
--- a/src/main/java/com/stripe/model/Invoice.java
+++ b/src/main/java/com/stripe/model/Invoice.java
@@ -1867,10 +1867,10 @@ public Invoice sendInvoice(InvoiceSendInvoiceParams params, RequestOptions optio
*
* You can preview the effects of updating a subscription, including a preview of what
* proration will take place. To ensure that the actual proration is calculated exactly the same
- * as the previewed proration, you should pass the {@code subscription_proration_date} parameter
- * when doing the actual subscription update. The recommended way to get only the prorations being
- * previewed is to consider only proration line items where {@code period[start]} is equal to the
- * {@code subscription_proration_date} value passed in the request.
+ * as the previewed proration, you should pass the {@code subscription_details.proration_date}
+ * parameter when doing the actual subscription update. The recommended way to get only the
+ * prorations being previewed is to consider only proration line items where {@code period[start]}
+ * is equal to the {@code subscription_details.proration_date} value passed in the request.
*/
public static Invoice upcoming() throws StripeException {
return upcoming((Map) null, (RequestOptions) null);
@@ -1889,10 +1889,10 @@ public static Invoice upcoming() throws StripeException {
*
* You can preview the effects of updating a subscription, including a preview of what
* proration will take place. To ensure that the actual proration is calculated exactly the same
- * as the previewed proration, you should pass the {@code subscription_proration_date} parameter
- * when doing the actual subscription update. The recommended way to get only the prorations being
- * previewed is to consider only proration line items where {@code period[start]} is equal to the
- * {@code subscription_proration_date} value passed in the request.
+ * as the previewed proration, you should pass the {@code subscription_details.proration_date}
+ * parameter when doing the actual subscription update. The recommended way to get only the
+ * prorations being previewed is to consider only proration line items where {@code period[start]}
+ * is equal to the {@code subscription_details.proration_date} value passed in the request.
*/
public static Invoice upcoming(Map params) throws StripeException {
return upcoming(params, (RequestOptions) null);
@@ -1911,10 +1911,10 @@ public static Invoice upcoming(Map params) throws StripeExceptio
*
* You can preview the effects of updating a subscription, including a preview of what
* proration will take place. To ensure that the actual proration is calculated exactly the same
- * as the previewed proration, you should pass the {@code subscription_proration_date} parameter
- * when doing the actual subscription update. The recommended way to get only the prorations being
- * previewed is to consider only proration line items where {@code period[start]} is equal to the
- * {@code subscription_proration_date} value passed in the request.
+ * as the previewed proration, you should pass the {@code subscription_details.proration_date}
+ * parameter when doing the actual subscription update. The recommended way to get only the
+ * prorations being previewed is to consider only proration line items where {@code period[start]}
+ * is equal to the {@code subscription_details.proration_date} value passed in the request.
*/
public static Invoice upcoming(Map params, RequestOptions options)
throws StripeException {
@@ -1938,10 +1938,10 @@ public static Invoice upcoming(Map params, RequestOptions option
*
* You can preview the effects of updating a subscription, including a preview of what
* proration will take place. To ensure that the actual proration is calculated exactly the same
- * as the previewed proration, you should pass the {@code subscription_proration_date} parameter
- * when doing the actual subscription update. The recommended way to get only the prorations being
- * previewed is to consider only proration line items where {@code period[start]} is equal to the
- * {@code subscription_proration_date} value passed in the request.
+ * as the previewed proration, you should pass the {@code subscription_details.proration_date}
+ * parameter when doing the actual subscription update. The recommended way to get only the
+ * prorations being previewed is to consider only proration line items where {@code period[start]}
+ * is equal to the {@code subscription_details.proration_date} value passed in the request.
*/
public static Invoice upcoming(InvoiceUpcomingParams params) throws StripeException {
return upcoming(params, (RequestOptions) null);
@@ -1960,10 +1960,10 @@ public static Invoice upcoming(InvoiceUpcomingParams params) throws StripeExcept
*
*
You can preview the effects of updating a subscription, including a preview of what
* proration will take place. To ensure that the actual proration is calculated exactly the same
- * as the previewed proration, you should pass the {@code subscription_proration_date} parameter
- * when doing the actual subscription update. The recommended way to get only the prorations being
- * previewed is to consider only proration line items where {@code period[start]} is equal to the
- * {@code subscription_proration_date} value passed in the request.
+ * as the previewed proration, you should pass the {@code subscription_details.proration_date}
+ * parameter when doing the actual subscription update. The recommended way to get only the
+ * prorations being previewed is to consider only proration line items where {@code period[start]}
+ * is equal to the {@code subscription_details.proration_date} value passed in the request.
*/
public static Invoice upcoming(InvoiceUpcomingParams params, RequestOptions options)
throws StripeException {
diff --git a/src/main/java/com/stripe/model/InvoiceLineItem.java b/src/main/java/com/stripe/model/InvoiceLineItem.java
index eb491026bad..a1947cf40f6 100644
--- a/src/main/java/com/stripe/model/InvoiceLineItem.java
+++ b/src/main/java/com/stripe/model/InvoiceLineItem.java
@@ -99,8 +99,9 @@ public class InvoiceLineItem extends ApiResource implements HasId, MetadataStore
/**
* 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. Note that for line items with {@code type=subscription} this will reflect
- * the metadata of the subscription that caused the line item to be created.
+ * structured format. Note that for line items with {@code type=subscription}, {@code metadata}
+ * reflects the current metadata from the subscription associated with the line item, unless the
+ * invoice line was directly updated with different metadata after creation.
*/
@Getter(onMethod_ = {@Override})
@SerializedName("metadata")
diff --git a/src/main/java/com/stripe/model/LoginLink.java b/src/main/java/com/stripe/model/LoginLink.java
index d1e362a7513..352dcbb36a8 100644
--- a/src/main/java/com/stripe/model/LoginLink.java
+++ b/src/main/java/com/stripe/model/LoginLink.java
@@ -16,7 +16,10 @@
import lombok.Setter;
/**
- * Login Links are single-use login link for an Express account to access their Stripe dashboard.
+ * Login Links are single-use URLs for a connected account to access the Express Dashboard. The
+ * connected account's account.controller.stripe_dashboard.type
+ * must be {@code express} to have access to the Express Dashboard.
*/
@Getter
@Setter
@@ -39,22 +42,22 @@ public class LoginLink extends ApiResource {
String url;
/**
- * Creates a single-use login link for an Express account to access their Stripe dashboard.
+ * Creates a single-use login link for a connected account to access the Express Dashboard.
*
- *
You may only create login links for Express accounts connected to your
- * platform.
+ *
You can only create login links for accounts that use the Express Dashboard and are connected to
+ * your platform.
*/
public static LoginLink createOnAccount(String account) throws StripeException {
return createOnAccount(account, (Map) null, (RequestOptions) null);
}
/**
- * Creates a single-use login link for an Express account to access their Stripe dashboard.
+ * Creates a single-use login link for a connected account to access the Express Dashboard.
*
- * You may only create login links for Express accounts connected to your
- * platform.
+ *
You can only create login links for accounts that use the Express Dashboard and are connected to
+ * your platform.
*/
public static LoginLink createOnAccount(String account, RequestOptions options)
throws StripeException {
@@ -62,11 +65,11 @@ public static LoginLink createOnAccount(String account, RequestOptions options)
}
/**
- * Creates a single-use login link for an Express account to access their Stripe dashboard.
+ * Creates a single-use login link for a connected account to access the Express Dashboard.
*
- *
You may only create login links for Express accounts connected to your
- * platform.
+ *
You can only create login links for accounts that use the Express Dashboard and are connected to
+ * your platform.
*/
public static LoginLink createOnAccount(String account, Map params)
throws StripeException {
@@ -74,11 +77,11 @@ public static LoginLink createOnAccount(String account, Map para
}
/**
- * Creates a single-use login link for an Express account to access their Stripe dashboard.
+ * Creates a single-use login link for a connected account to access the Express Dashboard.
*
- * You may only create login links for Express accounts connected to your
- * platform.
+ *
You can only create login links for accounts that use the Express Dashboard and are connected to
+ * your platform.
*/
public static LoginLink createOnAccount(
String account, Map params, RequestOptions options) throws StripeException {
@@ -90,11 +93,11 @@ public static LoginLink createOnAccount(
}
/**
- * Creates a single-use login link for an Express account to access their Stripe dashboard.
+ * Creates a single-use login link for a connected account to access the Express Dashboard.
*
- * You may only create login links for Express accounts connected to your
- * platform.
+ *
You can only create login links for accounts that use the Express Dashboard and are connected to
+ * your platform.
*/
public static LoginLink createOnAccount(String account, LoginLinkCreateOnAccountParams params)
throws StripeException {
@@ -102,11 +105,11 @@ public static LoginLink createOnAccount(String account, LoginLinkCreateOnAccount
}
/**
- * Creates a single-use login link for an Express account to access their Stripe dashboard.
+ * Creates a single-use login link for a connected account to access the Express Dashboard.
*
- *
You may only create login links for Express accounts connected to your
- * platform.
+ *
You can only create login links for accounts that use the Express Dashboard and are connected to
+ * your platform.
*/
public static LoginLink createOnAccount(
String account, LoginLinkCreateOnAccountParams params, RequestOptions options)
diff --git a/src/main/java/com/stripe/model/Mandate.java b/src/main/java/com/stripe/model/Mandate.java
index 9e928f2ad30..58f0397cabe 100644
--- a/src/main/java/com/stripe/model/Mandate.java
+++ b/src/main/java/com/stripe/model/Mandate.java
@@ -192,6 +192,9 @@ public static class PaymentMethodDetails extends StripeObject {
@SerializedName("acss_debit")
AcssDebit acssDebit;
+ @SerializedName("amazon_pay")
+ AmazonPay amazonPay;
+
@SerializedName("au_becs_debit")
AuBecsDebit auBecsDebit;
@@ -213,6 +216,9 @@ public static class PaymentMethodDetails extends StripeObject {
@SerializedName("payto")
Payto payto;
+ @SerializedName("revolut_pay")
+ RevolutPay revolutPay;
+
@SerializedName("sepa_debit")
SepaDebit sepaDebit;
@@ -259,6 +265,11 @@ public static class AcssDebit extends StripeObject {
String transactionType;
}
+ @Getter
+ @Setter
+ @EqualsAndHashCode(callSuper = false)
+ public static class AmazonPay extends StripeObject {}
+
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
@@ -406,6 +417,11 @@ public static class Payto extends StripeObject {
String startDate;
}
+ @Getter
+ @Setter
+ @EqualsAndHashCode(callSuper = false)
+ public static class RevolutPay extends StripeObject {}
+
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
diff --git a/src/main/java/com/stripe/model/PaymentIntent.java b/src/main/java/com/stripe/model/PaymentIntent.java
index ca2a1c17226..2b0d72cdd4c 100644
--- a/src/main/java/com/stripe/model/PaymentIntent.java
+++ b/src/main/java/com/stripe/model/PaymentIntent.java
@@ -3018,6 +3018,26 @@ public static class AmazonPay extends StripeObject {
*/
@SerializedName("capture_method")
String captureMethod;
+
+ /**
+ * Indicates that you intend to make future payments with this PaymentIntent's payment method.
+ *
+ *
Providing this parameter will attach the payment method
+ * to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any
+ * required actions from the user are complete. If no Customer was provided, the payment
+ * method can still be attached to a Customer after
+ * the transaction completes.
+ *
+ *
When processing card payments, Stripe also uses {@code setup_future_usage} to
+ * dynamically optimize your payment flow and comply with regional legislation and network
+ * rules, such as SCA.
+ *
+ *
One of {@code none}, or {@code off_session}.
+ */
+ @SerializedName("setup_future_usage")
+ String setupFutureUsage;
}
@Getter
@@ -4227,6 +4247,26 @@ public static class RevolutPay extends StripeObject {
*/
@SerializedName("capture_method")
String captureMethod;
+
+ /**
+ * Indicates that you intend to make future payments with this PaymentIntent's payment method.
+ *
+ *
Providing this parameter will attach the payment method
+ * to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any
+ * required actions from the user are complete. If no Customer was provided, the payment
+ * method can still be attached to a Customer after
+ * the transaction completes.
+ *
+ *
When processing card payments, Stripe also uses {@code setup_future_usage} to
+ * dynamically optimize your payment flow and comply with regional legislation and network
+ * rules, such as SCA.
+ *
+ *
One of {@code none}, or {@code off_session}.
+ */
+ @SerializedName("setup_future_usage")
+ String setupFutureUsage;
}
@Getter
diff --git a/src/main/java/com/stripe/model/PaymentMethodConfiguration.java b/src/main/java/com/stripe/model/PaymentMethodConfiguration.java
index 6c4855ce977..fb676668245 100644
--- a/src/main/java/com/stripe/model/PaymentMethodConfiguration.java
+++ b/src/main/java/com/stripe/model/PaymentMethodConfiguration.java
@@ -152,6 +152,9 @@ public class PaymentMethodConfiguration extends ApiResource implements HasId {
@SerializedName("livemode")
Boolean livemode;
+ @SerializedName("mobilepay")
+ Mobilepay mobilepay;
+
@SerializedName("multibanco")
Multibanco multibanco;
@@ -1444,6 +1447,49 @@ public static class DisplayPreference extends StripeObject {
}
}
+ @Getter
+ @Setter
+ @EqualsAndHashCode(callSuper = false)
+ public static class Mobilepay 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)
@@ -2031,6 +2077,7 @@ public void setResponseGetter(StripeResponseGetter responseGetter) {
trySetResponseGetter(klarna, responseGetter);
trySetResponseGetter(konbini, responseGetter);
trySetResponseGetter(link, responseGetter);
+ trySetResponseGetter(mobilepay, responseGetter);
trySetResponseGetter(multibanco, responseGetter);
trySetResponseGetter(oxxo, responseGetter);
trySetResponseGetter(p24, responseGetter);
diff --git a/src/main/java/com/stripe/model/Person.java b/src/main/java/com/stripe/model/Person.java
index bb27327fa45..5cab04c11b5 100644
--- a/src/main/java/com/stripe/model/Person.java
+++ b/src/main/java/com/stripe/model/Person.java
@@ -21,15 +21,16 @@
/**
* This is an object representing a person associated with a Stripe account.
*
- *
A platform cannot access a Standard or Express account's persons after the account starts
- * onboarding, such as after generating an account link for the account. See the Standard onboarding or Express onboarding documentation for
- * information about platform prefilling and account onboarding steps.
+ *
A platform cannot access a person for an account where account.controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, after creating an Account Link
+ * or Account Session to start Connect onboarding.
*
- *
Related guide: Handling
- * identity verification with the API
+ *
See the Standard onboarding or Express onboarding documentation for
+ * information about prefilling information and account onboarding steps. Learn more about handling identity
+ * verification with the API.
*/
@Getter
@Setter
diff --git a/src/main/java/com/stripe/model/QuoteLine.java b/src/main/java/com/stripe/model/QuoteLine.java
index 6ea35ecaaa6..9f0abf8bc5d 100644
--- a/src/main/java/com/stripe/model/QuoteLine.java
+++ b/src/main/java/com/stripe/model/QuoteLine.java
@@ -34,6 +34,16 @@ public class QuoteLine extends StripeObject implements HasId {
@SerializedName("billing_cycle_anchor")
String billingCycleAnchor;
+ /**
+ * A point-in-time operation that cancels an existing subscription schedule at the line's
+ * starts_at timestamp. Currently only compatible with {@code quote_acceptance_date} for {@code
+ * starts_at}. When using cancel_subscription_schedule, the subscription schedule on the quote
+ * remains unalterable, except for modifications to the metadata, collection_method or
+ * invoice_settings.
+ */
+ @SerializedName("cancel_subscription_schedule")
+ CancelSubscriptionSchedule cancelSubscriptionSchedule;
+
/**
* Details to identify the end of the time range modified by the proposed change. If not supplied,
* the quote line is considered a point-in-time operation that only affects the exact timestamp at
@@ -856,6 +866,36 @@ public static class AppliesTo extends StripeObject {
String type;
}
+ /** Configures the immediate cancellation settings for a subscription schedule via quotes. */
+ @Getter
+ @Setter
+ @EqualsAndHashCode(callSuper = false)
+ public static class CancelSubscriptionSchedule extends StripeObject {
+ /**
+ * Timestamp helper to cancel the underlying schedule on the accompanying line's start date.
+ * Must be set to {@code line_starts_at}.
+ *
+ *
Equal to {@code line_starts_at}.
+ */
+ @SerializedName("cancel_at")
+ String cancelAt;
+
+ /**
+ * If the subscription schedule is {@code active}, indicates if a final invoice will be
+ * generated that contains any un-invoiced metered usage and new/pending proration invoice
+ * items. Boolean that defaults to {@code true}.
+ */
+ @SerializedName("invoice_now")
+ Boolean invoiceNow;
+
+ /**
+ * If the subscription schedule is {@code active}, indicates if the cancellation should be
+ * prorated. Boolean that defaults to {@code true}.
+ */
+ @SerializedName("prorate")
+ Boolean prorate;
+ }
+
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
diff --git a/src/main/java/com/stripe/model/SetupAttempt.java b/src/main/java/com/stripe/model/SetupAttempt.java
index 15151815318..87aa6226f10 100644
--- a/src/main/java/com/stripe/model/SetupAttempt.java
+++ b/src/main/java/com/stripe/model/SetupAttempt.java
@@ -270,6 +270,9 @@ public static class PaymentMethodDetails extends StripeObject {
@SerializedName("acss_debit")
AcssDebit acssDebit;
+ @SerializedName("amazon_pay")
+ AmazonPay amazonPay;
+
@SerializedName("au_becs_debit")
AuBecsDebit auBecsDebit;
@@ -306,6 +309,9 @@ public static class PaymentMethodDetails extends StripeObject {
@SerializedName("payto")
Payto payto;
+ @SerializedName("revolut_pay")
+ RevolutPay revolutPay;
+
@SerializedName("sepa_debit")
SepaDebit sepaDebit;
@@ -328,6 +334,11 @@ public static class PaymentMethodDetails extends StripeObject {
@EqualsAndHashCode(callSuper = false)
public static class AcssDebit extends StripeObject {}
+ @Getter
+ @Setter
+ @EqualsAndHashCode(callSuper = false)
+ public static class AmazonPay extends StripeObject {}
+
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
@@ -801,6 +812,11 @@ public static class Paypal extends StripeObject {}
@EqualsAndHashCode(callSuper = false)
public static class Payto extends StripeObject {}
+ @Getter
+ @Setter
+ @EqualsAndHashCode(callSuper = false)
+ public static class RevolutPay extends StripeObject {}
+
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
diff --git a/src/main/java/com/stripe/model/Token.java b/src/main/java/com/stripe/model/Token.java
index cecad6f2404..7f97e8638e7 100644
--- a/src/main/java/com/stripe/model/Token.java
+++ b/src/main/java/com/stripe/model/Token.java
@@ -33,7 +33,7 @@
*
*
You can't store or use tokens more than once. To store card or bank account information for
* later use, create Customer objects or Custom accounts. External accounts. Radar, our integrated solution for automatic fraud
* protection, performs best with integrations that use client-side tokenization.
*/
@@ -44,13 +44,15 @@ public class Token extends ApiResource implements HasId {
/**
* These bank accounts are payment methods on {@code Customer} objects.
*
- *
On the other hand External
- * Accounts are transfer destinations on {@code Account} objects for Custom accounts. They can be bank
+ *
On the other hand External Accounts
+ * are transfer destinations on {@code Account} objects for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts. They can be bank
* accounts or debit cards as well, and are documented in the links above.
*
- *
Related guide: Bank debits
- * and transfers
+ *
Related guide: Bank debits and
+ * transfers
*/
@SerializedName("bank_account")
BankAccount bankAccount;
@@ -104,7 +106,10 @@ public class Token extends ApiResource implements HasId {
/**
* Creates a single-use token that represents a bank account’s details. You can use this token
* with any API method in place of a bank account dictionary. You can only use this token once. To
- * do so, attach it to a Custom account.
+ * do so, attach it to a connected account
+ * where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public static Token create(Map params) throws StripeException {
return create(params, (RequestOptions) null);
@@ -113,7 +118,10 @@ public static Token create(Map params) throws StripeException {
/**
* Creates a single-use token that represents a bank account’s details. You can use this token
* with any API method in place of a bank account dictionary. You can only use this token once. To
- * do so, attach it to a Custom account.
+ * do so, attach it to a connected account
+ * where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public static Token create(Map params, RequestOptions options)
throws StripeException {
@@ -127,7 +135,10 @@ public static Token create(Map params, RequestOptions options)
/**
* Creates a single-use token that represents a bank account’s details. You can use this token
* with any API method in place of a bank account dictionary. You can only use this token once. To
- * do so, attach it to a Custom account.
+ * do so, attach it to a connected account
+ * where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public static Token create(TokenCreateParams params) throws StripeException {
return create(params, (RequestOptions) null);
@@ -136,7 +147,10 @@ public static Token create(TokenCreateParams params) throws StripeException {
/**
* Creates a single-use token that represents a bank account’s details. You can use this token
* with any API method in place of a bank account dictionary. You can only use this token once. To
- * do so, attach it to a Custom account.
+ * do so, attach it to a connected account
+ * where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public static Token create(TokenCreateParams params, RequestOptions options)
throws StripeException {
diff --git a/src/main/java/com/stripe/model/WebhookEndpoint.java b/src/main/java/com/stripe/model/WebhookEndpoint.java
index 218e0582963..1e22e7352bc 100644
--- a/src/main/java/com/stripe/model/WebhookEndpoint.java
+++ b/src/main/java/com/stripe/model/WebhookEndpoint.java
@@ -20,14 +20,14 @@
import lombok.Setter;
/**
- * You can configure webhook endpoints via the API
+ * You can configure webhook endpoints via the API
* to be notified about events that happen in your Stripe account or connected accounts.
*
* Most users configure webhooks from the
* dashboard, which provides a user interface for registering and testing your webhook
* endpoints.
*
- *
Related guide: Setting up webhooks
+ *
Related guide: Setting up webhooks
*/
@Getter
@Setter
@@ -91,7 +91,7 @@ public class WebhookEndpoint extends ApiResource implements HasId, MetadataStore
/**
* The endpoint's secret, used to generate webhook signatures. Only returned at
+ * href="https://docs.stripe.com/webhooks/signatures">webhook signatures. Only returned at
* creation.
*/
@SerializedName("secret")
diff --git a/src/main/java/com/stripe/model/checkout/Session.java b/src/main/java/com/stripe/model/checkout/Session.java
index 7a33fc3caaa..4be8be387fc 100644
--- a/src/main/java/com/stripe/model/checkout/Session.java
+++ b/src/main/java/com/stripe/model/checkout/Session.java
@@ -1630,7 +1630,27 @@ public static class Alipay extends StripeObject {
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
- public static class AmazonPay extends StripeObject {}
+ public static class AmazonPay extends StripeObject {
+ /**
+ * Indicates that you intend to make future payments with this PaymentIntent's payment method.
+ *
+ *
Providing this parameter will attach the payment method
+ * to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any
+ * required actions from the user are complete. If no Customer was provided, the payment
+ * method can still be attached to a Customer after
+ * the transaction completes.
+ *
+ *
When processing card payments, Stripe also uses {@code setup_future_usage} to
+ * dynamically optimize your payment flow and comply with regional legislation and network
+ * rules, such as SCA.
+ *
+ *
One of {@code none}, or {@code off_session}.
+ */
+ @SerializedName("setup_future_usage")
+ String setupFutureUsage;
+ }
@Getter
@Setter
@@ -2301,7 +2321,27 @@ public static class Pix extends StripeObject {
@Getter
@Setter
@EqualsAndHashCode(callSuper = false)
- public static class RevolutPay extends StripeObject {}
+ public static class RevolutPay extends StripeObject {
+ /**
+ * Indicates that you intend to make future payments with this PaymentIntent's payment method.
+ *
+ *
Providing this parameter will attach the payment method
+ * to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any
+ * required actions from the user are complete. If no Customer was provided, the payment
+ * method can still be attached to a Customer after
+ * the transaction completes.
+ *
+ *
When processing card payments, Stripe also uses {@code setup_future_usage} to
+ * dynamically optimize your payment flow and comply with regional legislation and network
+ * rules, such as SCA.
+ *
+ *
One of {@code none}, or {@code off_session}.
+ */
+ @SerializedName("setup_future_usage")
+ String setupFutureUsage;
+ }
@Getter
@Setter
diff --git a/src/main/java/com/stripe/model/entitlements/ActiveEntitlement.java b/src/main/java/com/stripe/model/entitlements/ActiveEntitlement.java
index 720a5008042..f65ad2b80d8 100644
--- a/src/main/java/com/stripe/model/entitlements/ActiveEntitlement.java
+++ b/src/main/java/com/stripe/model/entitlements/ActiveEntitlement.java
@@ -3,6 +3,7 @@
import com.google.gson.annotations.SerializedName;
import com.stripe.exception.StripeException;
+import com.stripe.model.ExpandableField;
import com.stripe.model.HasId;
import com.stripe.net.ApiMode;
import com.stripe.net.ApiRequest;
@@ -10,6 +11,7 @@
import com.stripe.net.ApiResource;
import com.stripe.net.BaseAddress;
import com.stripe.net.RequestOptions;
+import com.stripe.net.StripeResponseGetter;
import com.stripe.param.entitlements.ActiveEntitlementListParams;
import com.stripe.param.entitlements.ActiveEntitlementRetrieveParams;
import java.util.Map;
@@ -22,9 +24,14 @@
@Setter
@EqualsAndHashCode(callSuper = false)
public class ActiveEntitlement extends ApiResource implements HasId {
- /** The feature that the customer is entitled to. */
+ /**
+ * The Feature that the customer is
+ * entitled to.
+ */
@SerializedName("feature")
- String feature;
+ @Getter(lombok.AccessLevel.NONE)
+ @Setter(lombok.AccessLevel.NONE)
+ ExpandableField feature;
/** Unique identifier for the object. */
@Getter(onMethod_ = {@Override})
@@ -50,6 +57,24 @@ public class ActiveEntitlement extends ApiResource implements HasId {
@SerializedName("object")
String object;
+ /** Get ID of expandable {@code feature} object. */
+ public String getFeature() {
+ return (this.feature != null) ? this.feature.getId() : null;
+ }
+
+ public void setFeature(String id) {
+ this.feature = ApiResource.setExpandableFieldId(id, this.feature);
+ }
+
+ /** Get expanded {@code feature}. */
+ public Feature getFeatureObject() {
+ return (this.feature != null) ? this.feature.getExpanded() : null;
+ }
+
+ public void setFeatureObject(Feature expandableObject) {
+ this.feature = new ExpandableField(expandableObject.getId(), expandableObject);
+ }
+
/** Retrieve a list of active entitlements for a customer. */
public static ActiveEntitlementCollection list(Map params)
throws StripeException {
@@ -127,4 +152,10 @@ public static ActiveEntitlement retrieve(
ApiMode.V1);
return getGlobalResponseGetter().request(request, ActiveEntitlement.class);
}
+
+ @Override
+ public void setResponseGetter(StripeResponseGetter responseGetter) {
+ super.setResponseGetter(responseGetter);
+ trySetResponseGetter(feature, responseGetter);
+ }
}
diff --git a/src/main/java/com/stripe/model/issuing/Authorization.java b/src/main/java/com/stripe/model/issuing/Authorization.java
index 7f402f577a1..bd78d35ac69 100644
--- a/src/main/java/com/stripe/model/issuing/Authorization.java
+++ b/src/main/java/com/stripe/model/issuing/Authorization.java
@@ -263,6 +263,7 @@ public void setTokenObject(Token expandableObject) {
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to approve an authorization.
*/
+ @Deprecated
public Authorization approve() throws StripeException {
return approve((Map) null, (RequestOptions) null);
}
@@ -275,6 +276,7 @@ public Authorization approve() throws StripeException {
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to approve an authorization.
*/
+ @Deprecated
public Authorization approve(RequestOptions options) throws StripeException {
return approve((Map) null, options);
}
@@ -287,6 +289,7 @@ public Authorization approve(RequestOptions options) throws StripeException {
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to approve an authorization.
*/
+ @Deprecated
public Authorization approve(Map params) throws StripeException {
return approve(params, (RequestOptions) null);
}
@@ -299,6 +302,7 @@ public Authorization approve(Map params) throws StripeException
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to approve an authorization.
*/
+ @Deprecated
public Authorization approve(Map params, RequestOptions options)
throws StripeException {
String path =
@@ -318,6 +322,7 @@ public Authorization approve(Map params, RequestOptions options)
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to approve an authorization.
*/
+ @Deprecated
public Authorization approve(AuthorizationApproveParams params) throws StripeException {
return approve(params, (RequestOptions) null);
}
@@ -330,6 +335,7 @@ public Authorization approve(AuthorizationApproveParams params) throws StripeExc
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to approve an authorization.
*/
+ @Deprecated
public Authorization approve(AuthorizationApproveParams params, RequestOptions options)
throws StripeException {
String path =
@@ -355,6 +361,7 @@ public Authorization approve(AuthorizationApproveParams params, RequestOptions o
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to decline an authorization.
*/
+ @Deprecated
public Authorization decline() throws StripeException {
return decline((Map) null, (RequestOptions) null);
}
@@ -367,6 +374,7 @@ public Authorization decline() throws StripeException {
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to decline an authorization.
*/
+ @Deprecated
public Authorization decline(RequestOptions options) throws StripeException {
return decline((Map) null, options);
}
@@ -379,6 +387,7 @@ public Authorization decline(RequestOptions options) throws StripeException {
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to decline an authorization.
*/
+ @Deprecated
public Authorization decline(Map params) throws StripeException {
return decline(params, (RequestOptions) null);
}
@@ -391,6 +400,7 @@ public Authorization decline(Map params) throws StripeException
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to decline an authorization.
*/
+ @Deprecated
public Authorization decline(Map params, RequestOptions options)
throws StripeException {
String path =
@@ -410,6 +420,7 @@ public Authorization decline(Map params, RequestOptions options)
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to decline an authorization.
*/
+ @Deprecated
public Authorization decline(AuthorizationDeclineParams params) throws StripeException {
return decline(params, (RequestOptions) null);
}
@@ -422,6 +433,7 @@ public Authorization decline(AuthorizationDeclineParams params) throws StripeExc
* href="https://stripe.com/docs/issuing/controls/real-time-authorizations#authorization-handling">respond
* directly to the webhook request to decline an authorization.
*/
+ @Deprecated
public Authorization decline(AuthorizationDeclineParams params, RequestOptions options)
throws StripeException {
String path =
diff --git a/src/main/java/com/stripe/param/AccountCreateParams.java b/src/main/java/com/stripe/param/AccountCreateParams.java
index 0e9d0d0349a..52065f390fc 100644
--- a/src/main/java/com/stripe/param/AccountCreateParams.java
+++ b/src/main/java/com/stripe/param/AccountCreateParams.java
@@ -25,28 +25,35 @@ public class AccountCreateParams extends ApiRequestParams {
BusinessProfile businessProfile;
/**
- * The business type. Once you create an Account Link or Account Session, this property can only
- * be updated for Custom accounts.
+ * The business type. Once you create an Account
+ * Link or Account Session, this
+ * property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("business_type")
BusinessType businessType;
/**
* Each key of the dictionary represents a capability, and each capability maps to its settings
- * (e.g. whether it has been requested or not). Each capability will be inactive until you have
- * provided its specific requirements and Stripe has verified them. An account may have some of
+ * (for example, whether it has been requested or not). Each capability is inactive until you have
+ * provided its specific requirements and Stripe has verified them. An account might have some of
* its requested capabilities be active and some be inactive.
+ *
+ * Required when account.controller.stripe_dashboard.type
+ * is {@code none}, which includes Custom accounts.
*/
@SerializedName("capabilities")
Capabilities capabilities;
/**
* Information about the company or business. This field is available for any {@code
- * business_type}. Once you create an Account
- * Link or Account Session, this
- * property can only be updated for Custom accounts.
+ * business_type}. Once you create an Account
+ * Link or Account Session, this
+ * property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("company")
Company company;
@@ -81,7 +88,10 @@ public class AccountCreateParams extends ApiRequestParams {
/**
* The email address of the account holder. This is only to make the account easier to identify to
- * you. Stripe only emails Custom accounts with your consent.
+ * you. If controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, Stripe doesn't email the account
+ * without your consent.
*/
@SerializedName("email")
String email;
@@ -92,20 +102,22 @@ public class AccountCreateParams extends ApiRequestParams {
/**
* A card or bank account to attach to the account for receiving payouts (you won’t be able
- * to use it for top-ups). You can provide either a token, like the ones returned by Stripe.js, or a dictionary, as documented in the {@code
+ * href="https://stripe.com/connect/bank-debit-card-payouts">payouts (you won’t be able to use
+ * it for top-ups). You can provide either a token, like the ones returned by Stripe.js, or a dictionary, as documented in the {@code
* external_account} parameter for bank account creation.
+ * href="https://stripe.com/api#account_create_bank_account">bank account creation.
*
* By default, providing an external account sets it as the new default external account for its
* currency, and deletes the old default if one exists. To add additional external accounts
* without replacing the existing default for the currency, use the bank account or card creation APIs. After you create
- * an Account Link or Account Session, this property can only
- * be updated for Custom accounts.
+ * href="https://stripe.com/api#account_create_bank_account">bank account or card creation APIs. After you create an
+ * Account Link or Account Session, this property can only be
+ * updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("external_account")
String externalAccount;
@@ -122,9 +134,11 @@ public class AccountCreateParams extends ApiRequestParams {
/**
* Information about the person represented by the account. This field is null unless {@code
* business_type} is set to {@code individual}. Once you create an Account Link or Account Session, this property can only
- * be updated for Custom accounts.
+ * href="https://stripe.com/api/account_links">Account Link or Account Session, this property can only be
+ * updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("individual")
Individual individual;
@@ -152,8 +166,10 @@ public class AccountCreateParams extends ApiRequestParams {
/**
* Details on the account's acceptance of the Stripe Services
- * Agreement This property can only be updated for Custom accounts.
+ * href="https://stripe.com/connect/updating-accounts#tos-acceptance">Stripe Services
+ * Agreement. This property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("tos_acceptance")
TosAcceptance tosAcceptance;
@@ -289,10 +305,11 @@ public Builder setBusinessProfile(AccountCreateParams.BusinessProfile businessPr
}
/**
- * The business type. Once you create an Account Link or Account Session, this property can
- * only be updated for Custom accounts.
+ * The business type. Once you create an Account
+ * Link or Account Session, this
+ * property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setBusinessType(AccountCreateParams.BusinessType businessType) {
this.businessType = businessType;
@@ -301,9 +318,13 @@ public Builder setBusinessType(AccountCreateParams.BusinessType businessType) {
/**
* Each key of the dictionary represents a capability, and each capability maps to its settings
- * (e.g. whether it has been requested or not). Each capability will be inactive until you have
- * provided its specific requirements and Stripe has verified them. An account may have some of
- * its requested capabilities be active and some be inactive.
+ * (for example, whether it has been requested or not). Each capability is inactive until you
+ * have provided its specific requirements and Stripe has verified them. An account might have
+ * some of its requested capabilities be active and some be inactive.
+ *
+ *
Required when account.controller.stripe_dashboard.type
+ * is {@code none}, which includes Custom accounts.
*/
public Builder setCapabilities(AccountCreateParams.Capabilities capabilities) {
this.capabilities = capabilities;
@@ -312,10 +333,11 @@ public Builder setCapabilities(AccountCreateParams.Capabilities capabilities) {
/**
* Information about the company or business. This field is available for any {@code
- * business_type}. Once you create an Account Link or Account Session, this property can
- * only be updated for Custom accounts.
+ * business_type}. Once you create an Account
+ * Link or Account Session, this
+ * property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setCompany(AccountCreateParams.Company company) {
this.company = company;
@@ -361,7 +383,10 @@ public Builder setDocuments(AccountCreateParams.Documents documents) {
/**
* The email address of the account holder. This is only to make the account easier to identify
- * to you. Stripe only emails Custom accounts with your consent.
+ * to you. If controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, Stripe doesn't email the account
+ * without your consent.
*/
public Builder setEmail(String email) {
this.email = email;
@@ -396,21 +421,22 @@ public Builder addAllExpand(List elements) {
/**
* A card or bank account to attach to the account for receiving payouts (you won’t be able
- * to use it for top-ups). You can provide either a token, like the ones returned by Stripe.js, or a dictionary, as documented in the {@code
+ * href="https://stripe.com/connect/bank-debit-card-payouts">payouts (you won’t be able to
+ * use it for top-ups). You can provide either a token, like the ones returned by Stripe.js, or a dictionary, as documented in the {@code
* external_account} parameter for bank account creation.
- *
+ * href="https://stripe.com/api#account_create_bank_account">bank account creation.
*
* By default, providing an external account sets it as the new default external account for its
* currency, and deletes the old default if one exists. To add additional external accounts
* without replacing the existing default for the currency, use the bank account or card creation APIs. After you
- * create an Account Link or Account Session, this property can
- * only be updated for Custom accounts.
+ * href="https://stripe.com/api#account_create_bank_account">bank account or card creation APIs. After you create an
+ * Account Link or Account Session, this property can only be
+ * updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setExternalAccount(String externalAccount) {
this.externalAccount = externalAccount;
@@ -446,9 +472,11 @@ public Builder putAllExtraParam(Map map) {
/**
* Information about the person represented by the account. This field is null unless {@code
* business_type} is set to {@code individual}. Once you create an Account Link or Account Session, this property can
- * only be updated for Custom accounts.
+ * href="https://stripe.com/api/account_links">Account Link or Account Session, this property can only be
+ * updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setIndividual(AccountCreateParams.Individual individual) {
this.individual = individual;
@@ -523,8 +551,10 @@ public Builder setSettings(AccountCreateParams.Settings settings) {
/**
* Details on the account's acceptance of the Stripe Services
- * Agreement This property can only be updated for Custom accounts.
+ * href="https://stripe.com/connect/updating-accounts#tos-acceptance">Stripe Services
+ * Agreement. This property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setTosAcceptance(AccountCreateParams.TosAcceptance tosAcceptance) {
this.tosAcceptance = tosAcceptance;
@@ -6944,7 +6974,9 @@ public static class Fees {
/**
* A value indicating the responsible payer of Stripe fees on this account. Defaults to {@code
- * account}.
+ * account}. Learn more about fee behavior on
+ * connected accounts.
*/
@SerializedName("payer")
Payer payer;
@@ -6998,7 +7030,9 @@ public Builder putAllExtraParam(Map map) {
/**
* A value indicating the responsible payer of Stripe fees on this account. Defaults to
- * {@code account}.
+ * {@code account}. Learn more about fee behavior on
+ * connected accounts.
*/
public Builder setPayer(AccountCreateParams.Controller.Fees.Payer payer) {
this.payer = payer;
diff --git a/src/main/java/com/stripe/param/AccountSessionCreateParams.java b/src/main/java/com/stripe/param/AccountSessionCreateParams.java
index 34e43ec159e..511aa992a8c 100644
--- a/src/main/java/com/stripe/param/AccountSessionCreateParams.java
+++ b/src/main/java/com/stripe/param/AccountSessionCreateParams.java
@@ -190,6 +190,10 @@ public static class Components {
@SerializedName("payment_details")
PaymentDetails paymentDetails;
+ /** Configuration for the payment method settings embedded component. */
+ @SerializedName("payment_method_settings")
+ PaymentMethodSettings paymentMethodSettings;
+
/** Configuration for the payments embedded component. */
@SerializedName("payments")
Payments payments;
@@ -224,6 +228,7 @@ private Components(
IssuingCardsList issuingCardsList,
NotificationBanner notificationBanner,
PaymentDetails paymentDetails,
+ PaymentMethodSettings paymentMethodSettings,
Payments payments,
Payouts payouts,
PayoutsList payoutsList,
@@ -242,6 +247,7 @@ private Components(
this.issuingCardsList = issuingCardsList;
this.notificationBanner = notificationBanner;
this.paymentDetails = paymentDetails;
+ this.paymentMethodSettings = paymentMethodSettings;
this.payments = payments;
this.payouts = payouts;
this.payoutsList = payoutsList;
@@ -280,6 +286,8 @@ public static class Builder {
private PaymentDetails paymentDetails;
+ private PaymentMethodSettings paymentMethodSettings;
+
private Payments payments;
private Payouts payouts;
@@ -306,6 +314,7 @@ public AccountSessionCreateParams.Components build() {
this.issuingCardsList,
this.notificationBanner,
this.paymentDetails,
+ this.paymentMethodSettings,
this.payments,
this.payouts,
this.payoutsList,
@@ -421,6 +430,13 @@ public Builder setPaymentDetails(
return this;
}
+ /** Configuration for the payment method settings embedded component. */
+ public Builder setPaymentMethodSettings(
+ AccountSessionCreateParams.Components.PaymentMethodSettings paymentMethodSettings) {
+ this.paymentMethodSettings = paymentMethodSettings;
+ return this;
+ }
+
/** Configuration for the payments embedded component. */
public Builder setPayments(AccountSessionCreateParams.Components.Payments payments) {
this.payments = payments;
@@ -2487,6 +2503,153 @@ public Builder setRefundManagement(Boolean refundManagement) {
}
}
+ @Getter
+ public static class PaymentMethodSettings {
+ /** Required. Whether the embedded component is enabled. */
+ @SerializedName("enabled")
+ Boolean enabled;
+
+ /**
+ * 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 list of features enabled in the embedded component. */
+ @SerializedName("features")
+ Features features;
+
+ private PaymentMethodSettings(
+ Boolean enabled, Map extraParams, Features features) {
+ this.enabled = enabled;
+ this.extraParams = extraParams;
+ this.features = features;
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ public static class Builder {
+ private Boolean enabled;
+
+ private Map extraParams;
+
+ private Features features;
+
+ /** Finalize and obtain parameter instance from this builder. */
+ public AccountSessionCreateParams.Components.PaymentMethodSettings build() {
+ return new AccountSessionCreateParams.Components.PaymentMethodSettings(
+ this.enabled, this.extraParams, this.features);
+ }
+
+ /** Required. Whether the embedded component is enabled. */
+ public Builder setEnabled(Boolean enabled) {
+ this.enabled = enabled;
+ 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 AccountSessionCreateParams.Components.PaymentMethodSettings#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 AccountSessionCreateParams.Components.PaymentMethodSettings#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 list of features enabled in the embedded component. */
+ public Builder setFeatures(
+ AccountSessionCreateParams.Components.PaymentMethodSettings.Features features) {
+ this.features = features;
+ return this;
+ }
+ }
+
+ @Getter
+ public static class Features {
+ /**
+ * 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 Features(Map extraParams) {
+ this.extraParams = extraParams;
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ public static class Builder {
+ private Map extraParams;
+
+ /** Finalize and obtain parameter instance from this builder. */
+ public AccountSessionCreateParams.Components.PaymentMethodSettings.Features build() {
+ return new AccountSessionCreateParams.Components.PaymentMethodSettings.Features(
+ this.extraParams);
+ }
+
+ /**
+ * 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
+ * AccountSessionCreateParams.Components.PaymentMethodSettings.Features#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
+ * AccountSessionCreateParams.Components.PaymentMethodSettings.Features#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 Payments {
/** Required. Whether the embedded component is enabled. */
diff --git a/src/main/java/com/stripe/param/AccountUpdateParams.java b/src/main/java/com/stripe/param/AccountUpdateParams.java
index 7448f437529..4fa2ab62238 100644
--- a/src/main/java/com/stripe/param/AccountUpdateParams.java
+++ b/src/main/java/com/stripe/param/AccountUpdateParams.java
@@ -25,28 +25,35 @@ public class AccountUpdateParams extends ApiRequestParams {
BusinessProfile businessProfile;
/**
- * The business type. Once you create an Account Link or Account Session, this property can only
- * be updated for Custom accounts.
+ * The business type. Once you create an Account
+ * Link or Account Session, this
+ * property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("business_type")
BusinessType businessType;
/**
* Each key of the dictionary represents a capability, and each capability maps to its settings
- * (e.g. whether it has been requested or not). Each capability will be inactive until you have
- * provided its specific requirements and Stripe has verified them. An account may have some of
+ * (for example, whether it has been requested or not). Each capability is inactive until you have
+ * provided its specific requirements and Stripe has verified them. An account might have some of
* its requested capabilities be active and some be inactive.
+ *
+ * Required when account.controller.stripe_dashboard.type
+ * is {@code none}, which includes Custom accounts.
*/
@SerializedName("capabilities")
Capabilities capabilities;
/**
* Information about the company or business. This field is available for any {@code
- * business_type}. Once you create an Account
- * Link or Account Session, this
- * property can only be updated for Custom accounts.
+ * business_type}. Once you create an Account
+ * Link or Account Session, this
+ * property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("company")
Company company;
@@ -65,7 +72,10 @@ public class AccountUpdateParams extends ApiRequestParams {
/**
* The email address of the account holder. This is only to make the account easier to identify to
- * you. Stripe only emails Custom accounts with your consent.
+ * you. If controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, Stripe doesn't email the account
+ * without your consent.
*/
@SerializedName("email")
Object email;
@@ -76,20 +86,22 @@ public class AccountUpdateParams extends ApiRequestParams {
/**
* A card or bank account to attach to the account for receiving payouts (you won’t be able
- * to use it for top-ups). You can provide either a token, like the ones returned by Stripe.js, or a dictionary, as documented in the {@code
+ * href="https://stripe.com/connect/bank-debit-card-payouts">payouts (you won’t be able to use
+ * it for top-ups). You can provide either a token, like the ones returned by Stripe.js, or a dictionary, as documented in the {@code
* external_account} parameter for bank account creation.
+ * href="https://stripe.com/api#account_create_bank_account">bank account creation.
*
* By default, providing an external account sets it as the new default external account for its
* currency, and deletes the old default if one exists. To add additional external accounts
* without replacing the existing default for the currency, use the bank account or card creation APIs. After you create
- * an Account Link or Account Session, this property can only
- * be updated for Custom accounts.
+ * href="https://stripe.com/api#account_create_bank_account">bank account or card creation APIs. After you create an
+ * Account Link or Account Session, this property can only be
+ * updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("external_account")
Object externalAccount;
@@ -106,9 +118,11 @@ public class AccountUpdateParams extends ApiRequestParams {
/**
* Information about the person represented by the account. This field is null unless {@code
* business_type} is set to {@code individual}. Once you create an Account Link or Account Session, this property can only
- * be updated for Custom accounts.
+ * href="https://stripe.com/api/account_links">Account Link or Account Session, this property can only be
+ * updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("individual")
Individual individual;
@@ -136,8 +150,10 @@ public class AccountUpdateParams extends ApiRequestParams {
/**
* Details on the account's acceptance of the Stripe Services
- * Agreement This property can only be updated for Custom accounts.
+ * href="https://stripe.com/connect/updating-accounts#tos-acceptance">Stripe Services
+ * Agreement. This property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
@SerializedName("tos_acceptance")
TosAcceptance tosAcceptance;
@@ -260,10 +276,11 @@ public Builder setBusinessProfile(AccountUpdateParams.BusinessProfile businessPr
}
/**
- * The business type. Once you create an Account Link or Account Session, this property can
- * only be updated for Custom accounts.
+ * The business type. Once you create an Account
+ * Link or Account Session, this
+ * property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setBusinessType(AccountUpdateParams.BusinessType businessType) {
this.businessType = businessType;
@@ -272,9 +289,13 @@ public Builder setBusinessType(AccountUpdateParams.BusinessType businessType) {
/**
* Each key of the dictionary represents a capability, and each capability maps to its settings
- * (e.g. whether it has been requested or not). Each capability will be inactive until you have
- * provided its specific requirements and Stripe has verified them. An account may have some of
- * its requested capabilities be active and some be inactive.
+ * (for example, whether it has been requested or not). Each capability is inactive until you
+ * have provided its specific requirements and Stripe has verified them. An account might have
+ * some of its requested capabilities be active and some be inactive.
+ *
+ *
Required when account.controller.stripe_dashboard.type
+ * is {@code none}, which includes Custom accounts.
*/
public Builder setCapabilities(AccountUpdateParams.Capabilities capabilities) {
this.capabilities = capabilities;
@@ -283,10 +304,11 @@ public Builder setCapabilities(AccountUpdateParams.Capabilities capabilities) {
/**
* Information about the company or business. This field is available for any {@code
- * business_type}. Once you create an Account Link or Account Session, this property can
- * only be updated for Custom accounts.
+ * business_type}. Once you create an Account
+ * Link or Account Session, this
+ * property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setCompany(AccountUpdateParams.Company company) {
this.company = company;
@@ -321,7 +343,10 @@ public Builder setDocuments(AccountUpdateParams.Documents documents) {
/**
* The email address of the account holder. This is only to make the account easier to identify
- * to you. Stripe only emails Custom accounts with your consent.
+ * to you. If controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, Stripe doesn't email the account
+ * without your consent.
*/
public Builder setEmail(String email) {
this.email = email;
@@ -330,7 +355,10 @@ public Builder setEmail(String email) {
/**
* The email address of the account holder. This is only to make the account easier to identify
- * to you. Stripe only emails Custom accounts with your consent.
+ * to you. If controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, Stripe doesn't email the account
+ * without your consent.
*/
public Builder setEmail(EmptyParam email) {
this.email = email;
@@ -365,21 +393,22 @@ public Builder addAllExpand(List elements) {
/**
* A card or bank account to attach to the account for receiving payouts (you won’t be able
- * to use it for top-ups). You can provide either a token, like the ones returned by Stripe.js, or a dictionary, as documented in the {@code
+ * href="https://stripe.com/connect/bank-debit-card-payouts">payouts (you won’t be able to
+ * use it for top-ups). You can provide either a token, like the ones returned by Stripe.js, or a dictionary, as documented in the {@code
* external_account} parameter for bank account creation.
- *
+ * href="https://stripe.com/api#account_create_bank_account">bank account creation.
*
* By default, providing an external account sets it as the new default external account for its
* currency, and deletes the old default if one exists. To add additional external accounts
* without replacing the existing default for the currency, use the bank account or card creation APIs. After you
- * create an Account Link or Account Session, this property can
- * only be updated for Custom accounts.
+ * href="https://stripe.com/api#account_create_bank_account">bank account or card creation APIs. After you create an
+ * Account Link or Account Session, this property can only be
+ * updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setExternalAccount(String externalAccount) {
this.externalAccount = externalAccount;
@@ -388,21 +417,22 @@ public Builder setExternalAccount(String externalAccount) {
/**
* A card or bank account to attach to the account for receiving payouts (you won’t be able
- * to use it for top-ups). You can provide either a token, like the ones returned by Stripe.js, or a dictionary, as documented in the {@code
+ * href="https://stripe.com/connect/bank-debit-card-payouts">payouts (you won’t be able to
+ * use it for top-ups). You can provide either a token, like the ones returned by Stripe.js, or a dictionary, as documented in the {@code
* external_account} parameter for bank account creation.
- *
+ * href="https://stripe.com/api#account_create_bank_account">bank account creation.
*
* By default, providing an external account sets it as the new default external account for its
* currency, and deletes the old default if one exists. To add additional external accounts
* without replacing the existing default for the currency, use the bank account or card creation APIs. After you
- * create an Account Link or Account Session, this property can
- * only be updated for Custom accounts.
+ * href="https://stripe.com/api#account_create_bank_account">bank account or card creation APIs. After you create an
+ * Account Link or Account Session, this property can only be
+ * updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setExternalAccount(EmptyParam externalAccount) {
this.externalAccount = externalAccount;
@@ -438,9 +468,11 @@ public Builder putAllExtraParam(Map map) {
/**
* Information about the person represented by the account. This field is null unless {@code
* business_type} is set to {@code individual}. Once you create an Account Link or Account Session, this property can
- * only be updated for Custom accounts.
+ * href="https://stripe.com/api/account_links">Account Link or Account Session, this property can only be
+ * updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setIndividual(AccountUpdateParams.Individual individual) {
this.individual = individual;
@@ -515,8 +547,10 @@ public Builder setSettings(AccountUpdateParams.Settings settings) {
/**
* Details on the account's acceptance of the Stripe Services
- * Agreement This property can only be updated for Custom accounts.
+ * href="https://stripe.com/connect/updating-accounts#tos-acceptance">Stripe Services
+ * Agreement. This property can only be updated for accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Builder setTosAcceptance(AccountUpdateParams.TosAcceptance tosAcceptance) {
this.tosAcceptance = tosAcceptance;
diff --git a/src/main/java/com/stripe/param/InvoiceCreateParams.java b/src/main/java/com/stripe/param/InvoiceCreateParams.java
index cfd8be76416..a19bff2555a 100644
--- a/src/main/java/com/stripe/param/InvoiceCreateParams.java
+++ b/src/main/java/com/stripe/param/InvoiceCreateParams.java
@@ -3849,6 +3849,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam {
@SerializedName("acss_debit")
ACSS_DEBIT("acss_debit"),
+ @SerializedName("amazon_pay")
+ AMAZON_PAY("amazon_pay"),
+
@SerializedName("au_becs_debit")
AU_BECS_DEBIT("au_becs_debit"),
@@ -3903,6 +3906,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam {
@SerializedName("promptpay")
PROMPTPAY("promptpay"),
+ @SerializedName("revolut_pay")
+ REVOLUT_PAY("revolut_pay"),
+
@SerializedName("sepa_credit_transfer")
SEPA_CREDIT_TRANSFER("sepa_credit_transfer"),
diff --git a/src/main/java/com/stripe/param/InvoiceLineItemUpdateParams.java b/src/main/java/com/stripe/param/InvoiceLineItemUpdateParams.java
index 58cd5088d33..a2d35a06acf 100644
--- a/src/main/java/com/stripe/param/InvoiceLineItemUpdateParams.java
+++ b/src/main/java/com/stripe/param/InvoiceLineItemUpdateParams.java
@@ -66,7 +66,10 @@ public class InvoiceLineItemUpdateParams extends ApiRequestParams {
* 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}.
+ * be unset by posting an empty value to {@code metadata}. For {@code type=recurring} line items,
+ * the incoming metadata specified on the request is directly used to set this value, in contrast
+ * to {@code type=invoiceitem} line items, where any existing metadata on the invoice line is
+ * merged with the incoming data.
*/
@SerializedName("metadata")
Object metadata;
@@ -415,7 +418,10 @@ public Builder putAllMetadata(Map map) {
* 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}.
+ * can be unset by posting an empty value to {@code metadata}. For {@code type=recurring} line
+ * items, the incoming metadata specified on the request is directly used to set this value, in
+ * contrast to {@code type=invoiceitem} line items, where any existing metadata on the invoice
+ * line is merged with the incoming data.
*/
public Builder setMetadata(EmptyParam metadata) {
this.metadata = metadata;
@@ -426,7 +432,10 @@ public Builder setMetadata(EmptyParam metadata) {
* 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}.
+ * can be unset by posting an empty value to {@code metadata}. For {@code type=recurring} line
+ * items, the incoming metadata specified on the request is directly used to set this value, in
+ * contrast to {@code type=invoiceitem} line items, where any existing metadata on the invoice
+ * line is merged with the incoming data.
*/
public Builder setMetadata(Map metadata) {
this.metadata = metadata;
diff --git a/src/main/java/com/stripe/param/InvoiceUpdateLinesParams.java b/src/main/java/com/stripe/param/InvoiceUpdateLinesParams.java
index 211430e6a53..4c7802f9812 100644
--- a/src/main/java/com/stripe/param/InvoiceUpdateLinesParams.java
+++ b/src/main/java/com/stripe/param/InvoiceUpdateLinesParams.java
@@ -30,7 +30,10 @@ public class InvoiceUpdateLinesParams extends ApiRequestParams {
* 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}.
+ * be unset by posting an empty value to {@code metadata}. For {@code type=recurring} line items,
+ * the incoming metadata specified on the request is directly used to set this value, in contrast
+ * to {@code type=invoiceitem} line items, where any existing metadata on the invoice line is
+ * merged with the incoming data.
*/
@SerializedName("invoice_metadata")
Object invoiceMetadata;
@@ -153,7 +156,10 @@ public Builder putAllInvoiceMetadata(Map map) {
* 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}.
+ * can be unset by posting an empty value to {@code metadata}. For {@code type=recurring} line
+ * items, the incoming metadata specified on the request is directly used to set this value, in
+ * contrast to {@code type=invoiceitem} line items, where any existing metadata on the invoice
+ * line is merged with the incoming data.
*/
public Builder setInvoiceMetadata(EmptyParam invoiceMetadata) {
this.invoiceMetadata = invoiceMetadata;
@@ -164,7 +170,10 @@ public Builder setInvoiceMetadata(EmptyParam invoiceMetadata) {
* 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}.
+ * can be unset by posting an empty value to {@code metadata}. For {@code type=recurring} line
+ * items, the incoming metadata specified on the request is directly used to set this value, in
+ * contrast to {@code type=invoiceitem} line items, where any existing metadata on the invoice
+ * line is merged with the incoming data.
*/
public Builder setInvoiceMetadata(Map invoiceMetadata) {
this.invoiceMetadata = invoiceMetadata;
@@ -253,7 +262,10 @@ public static class Line {
* 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}.
+ * can be unset by posting an empty value to {@code metadata}. For {@code type=recurring} line
+ * items, the incoming metadata specified on the request is directly used to set this value, in
+ * contrast to {@code type=invoiceitem} line items, where any existing metadata on the invoice
+ * line is merged with the incoming data.
*/
@SerializedName("metadata")
Object metadata;
@@ -575,7 +587,10 @@ public Builder putAllMetadata(Map map) {
* 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}.
+ * keys can be unset by posting an empty value to {@code metadata}. For {@code type=recurring}
+ * line items, the incoming metadata specified on the request is directly used to set this
+ * value, in contrast to {@code type=invoiceitem} line items, where any existing metadata on
+ * the invoice line is merged with the incoming data.
*/
public Builder setMetadata(EmptyParam metadata) {
this.metadata = metadata;
@@ -586,7 +601,10 @@ public Builder setMetadata(EmptyParam metadata) {
* 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}.
+ * keys can be unset by posting an empty value to {@code metadata}. For {@code type=recurring}
+ * line items, the incoming metadata specified on the request is directly used to set this
+ * value, in contrast to {@code type=invoiceitem} line items, where any existing metadata on
+ * the invoice line is merged with the incoming data.
*/
public Builder setMetadata(Map metadata) {
this.metadata = metadata;
diff --git a/src/main/java/com/stripe/param/InvoiceUpdateParams.java b/src/main/java/com/stripe/param/InvoiceUpdateParams.java
index c9847b989f3..775a953238d 100644
--- a/src/main/java/com/stripe/param/InvoiceUpdateParams.java
+++ b/src/main/java/com/stripe/param/InvoiceUpdateParams.java
@@ -3886,6 +3886,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam {
@SerializedName("acss_debit")
ACSS_DEBIT("acss_debit"),
+ @SerializedName("amazon_pay")
+ AMAZON_PAY("amazon_pay"),
+
@SerializedName("au_becs_debit")
AU_BECS_DEBIT("au_becs_debit"),
@@ -3940,6 +3943,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam {
@SerializedName("promptpay")
PROMPTPAY("promptpay"),
+ @SerializedName("revolut_pay")
+ REVOLUT_PAY("revolut_pay"),
+
@SerializedName("sepa_credit_transfer")
SEPA_CREDIT_TRANSFER("sepa_credit_transfer"),
diff --git a/src/main/java/com/stripe/param/PaymentMethodConfigurationCreateParams.java b/src/main/java/com/stripe/param/PaymentMethodConfigurationCreateParams.java
index a3c66932ae8..2efa496cc72 100644
--- a/src/main/java/com/stripe/param/PaymentMethodConfigurationCreateParams.java
+++ b/src/main/java/com/stripe/param/PaymentMethodConfigurationCreateParams.java
@@ -258,6 +258,16 @@ public class PaymentMethodConfigurationCreateParams extends ApiRequestParams {
@SerializedName("link")
Link link;
+ /**
+ * MobilePay is a single-use
+ * card wallet payment method used in Denmark and Finland. It allows customers to authenticate and
+ * approve payments using the MobilePay app. Check this page for more details.
+ */
+ @SerializedName("mobilepay")
+ Mobilepay mobilepay;
+
/**
* Stripe users in Europe and the United States can accept Multibanco payments from customers in
* Portugal using Sources—a single integration path
@@ -409,6 +419,7 @@ private PaymentMethodConfigurationCreateParams(
Klarna klarna,
Konbini konbini,
Link link,
+ Mobilepay mobilepay,
Multibanco multibanco,
String name,
Oxxo oxxo,
@@ -452,6 +463,7 @@ private PaymentMethodConfigurationCreateParams(
this.klarna = klarna;
this.konbini = konbini;
this.link = link;
+ this.mobilepay = mobilepay;
this.multibanco = multibanco;
this.name = name;
this.oxxo = oxxo;
@@ -530,6 +542,8 @@ public static class Builder {
private Link link;
+ private Mobilepay mobilepay;
+
private Multibanco multibanco;
private String name;
@@ -591,6 +605,7 @@ public PaymentMethodConfigurationCreateParams build() {
this.klarna,
this.konbini,
this.link,
+ this.mobilepay,
this.multibanco,
this.name,
this.oxxo,
@@ -950,6 +965,19 @@ public Builder setLink(PaymentMethodConfigurationCreateParams.Link link) {
return this;
}
+ /**
+ * MobilePay is a single-use card wallet
+ * payment method used in Denmark and Finland. It allows customers to authenticate and
+ * approve payments using the MobilePay app. Check this page for more details.
+ */
+ public Builder setMobilepay(PaymentMethodConfigurationCreateParams.Mobilepay mobilepay) {
+ this.mobilepay = mobilepay;
+ return this;
+ }
+
/**
* Stripe users in Europe and the United States can accept Multibanco payments from customers in
* Portugal using Sources—a single integration
@@ -5361,6 +5389,170 @@ public enum Preference implements ApiRequestParams.EnumParam {
}
}
+ @Getter
+ public static class Mobilepay {
+ /** 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 Mobilepay(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.Mobilepay build() {
+ return new PaymentMethodConfigurationCreateParams.Mobilepay(
+ this.displayPreference, this.extraParams);
+ }
+
+ /** Whether or not the payment method should be displayed. */
+ public Builder setDisplayPreference(
+ PaymentMethodConfigurationCreateParams.Mobilepay.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.Mobilepay#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.Mobilepay#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.Mobilepay.DisplayPreference build() {
+ return new PaymentMethodConfigurationCreateParams.Mobilepay.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.Mobilepay.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.Mobilepay.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.Mobilepay.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 Multibanco {
/** Whether or not the payment method should be displayed. */
diff --git a/src/main/java/com/stripe/param/PaymentMethodConfigurationListParams.java b/src/main/java/com/stripe/param/PaymentMethodConfigurationListParams.java
index b78e8051114..49e8e18aed9 100644
--- a/src/main/java/com/stripe/param/PaymentMethodConfigurationListParams.java
+++ b/src/main/java/com/stripe/param/PaymentMethodConfigurationListParams.java
@@ -16,6 +16,15 @@ public class PaymentMethodConfigurationListParams extends ApiRequestParams {
@SerializedName("application")
Object application;
+ /**
+ * A cursor for use in pagination. {@code ending_before} is an object ID that defines your place
+ * in the list. For instance, if you make a list request and receive 100 objects, starting with
+ * {@code obj_bar}, your subsequent call can include {@code ending_before=obj_bar} in order to
+ * fetch the previous page of the list.
+ */
+ @SerializedName("ending_before")
+ String endingBefore;
+
/** Specifies which fields in the response should be expanded. */
@SerializedName("expand")
List expand;
@@ -29,11 +38,35 @@ public class PaymentMethodConfigurationListParams extends ApiRequestParams {
@SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY)
Map extraParams;
+ /**
+ * A limit on the number of objects to be returned. Limit can range between 1 and 100, and the
+ * default is 10.
+ */
+ @SerializedName("limit")
+ Long limit;
+
+ /**
+ * A cursor for use in pagination. {@code starting_after} is an object ID that defines your place
+ * in the list. For instance, if you make a list request and receive 100 objects, ending with
+ * {@code obj_foo}, your subsequent call can include {@code starting_after=obj_foo} in order to
+ * fetch the next page of the list.
+ */
+ @SerializedName("starting_after")
+ String startingAfter;
+
private PaymentMethodConfigurationListParams(
- Object application, List expand, Map extraParams) {
+ Object application,
+ String endingBefore,
+ List expand,
+ Map extraParams,
+ Long limit,
+ String startingAfter) {
this.application = application;
+ this.endingBefore = endingBefore;
this.expand = expand;
this.extraParams = extraParams;
+ this.limit = limit;
+ this.startingAfter = startingAfter;
}
public static Builder builder() {
@@ -43,14 +76,25 @@ public static Builder builder() {
public static class Builder {
private Object application;
+ private String endingBefore;
+
private List expand;
private Map extraParams;
+ private Long limit;
+
+ private String startingAfter;
+
/** Finalize and obtain parameter instance from this builder. */
public PaymentMethodConfigurationListParams build() {
return new PaymentMethodConfigurationListParams(
- this.application, this.expand, this.extraParams);
+ this.application,
+ this.endingBefore,
+ this.expand,
+ this.extraParams,
+ this.limit,
+ this.startingAfter);
}
/** The Connect application to filter by. */
@@ -65,6 +109,17 @@ public Builder setApplication(EmptyParam application) {
return this;
}
+ /**
+ * A cursor for use in pagination. {@code ending_before} is an object ID that defines your place
+ * in the list. For instance, if you make a list request and receive 100 objects, starting with
+ * {@code obj_bar}, your subsequent call can include {@code ending_before=obj_bar} in order to
+ * fetch the previous page of the list.
+ */
+ public Builder setEndingBefore(String endingBefore) {
+ this.endingBefore = endingBefore;
+ return this;
+ }
+
/**
* 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
@@ -116,5 +171,25 @@ public Builder putAllExtraParam(Map map) {
this.extraParams.putAll(map);
return this;
}
+
+ /**
+ * A limit on the number of objects to be returned. Limit can range between 1 and 100, and the
+ * default is 10.
+ */
+ public Builder setLimit(Long limit) {
+ this.limit = limit;
+ return this;
+ }
+
+ /**
+ * A cursor for use in pagination. {@code starting_after} is an object ID that defines your
+ * place in the list. For instance, if you make a list request and receive 100 objects, ending
+ * with {@code obj_foo}, your subsequent call can include {@code starting_after=obj_foo} in
+ * order to fetch the next page of the list.
+ */
+ public Builder setStartingAfter(String startingAfter) {
+ this.startingAfter = startingAfter;
+ return this;
+ }
}
}
diff --git a/src/main/java/com/stripe/param/PaymentMethodConfigurationUpdateParams.java b/src/main/java/com/stripe/param/PaymentMethodConfigurationUpdateParams.java
index 926990f0895..625aaa5b30c 100644
--- a/src/main/java/com/stripe/param/PaymentMethodConfigurationUpdateParams.java
+++ b/src/main/java/com/stripe/param/PaymentMethodConfigurationUpdateParams.java
@@ -263,6 +263,16 @@ public class PaymentMethodConfigurationUpdateParams extends ApiRequestParams {
@SerializedName("link")
Link link;
+ /**
+ * MobilePay is a single-use
+ * card wallet payment method used in Denmark and Finland. It allows customers to authenticate and
+ * approve payments using the MobilePay app. Check this page for more details.
+ */
+ @SerializedName("mobilepay")
+ Mobilepay mobilepay;
+
/**
* Stripe users in Europe and the United States can accept Multibanco payments from customers in
* Portugal using Sources—a single integration path
@@ -411,6 +421,7 @@ private PaymentMethodConfigurationUpdateParams(
Klarna klarna,
Konbini konbini,
Link link,
+ Mobilepay mobilepay,
Multibanco multibanco,
Object name,
Oxxo oxxo,
@@ -454,6 +465,7 @@ private PaymentMethodConfigurationUpdateParams(
this.klarna = klarna;
this.konbini = konbini;
this.link = link;
+ this.mobilepay = mobilepay;
this.multibanco = multibanco;
this.name = name;
this.oxxo = oxxo;
@@ -533,6 +545,8 @@ public static class Builder {
private Link link;
+ private Mobilepay mobilepay;
+
private Multibanco multibanco;
private Object name;
@@ -593,6 +607,7 @@ public PaymentMethodConfigurationUpdateParams build() {
this.klarna,
this.konbini,
this.link,
+ this.mobilepay,
this.multibanco,
this.name,
this.oxxo,
@@ -957,6 +972,19 @@ public Builder setLink(PaymentMethodConfigurationUpdateParams.Link link) {
return this;
}
+ /**
+ * MobilePay is a single-use card wallet
+ * payment method used in Denmark and Finland. It allows customers to authenticate and
+ * approve payments using the MobilePay app. Check this page for more details.
+ */
+ public Builder setMobilepay(PaymentMethodConfigurationUpdateParams.Mobilepay mobilepay) {
+ this.mobilepay = mobilepay;
+ return this;
+ }
+
/**
* Stripe users in Europe and the United States can accept Multibanco payments from customers in
* Portugal using Sources—a single integration
@@ -5368,6 +5396,170 @@ public enum Preference implements ApiRequestParams.EnumParam {
}
}
+ @Getter
+ public static class Mobilepay {
+ /** 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 Mobilepay(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.Mobilepay build() {
+ return new PaymentMethodConfigurationUpdateParams.Mobilepay(
+ this.displayPreference, this.extraParams);
+ }
+
+ /** Whether or not the payment method should be displayed. */
+ public Builder setDisplayPreference(
+ PaymentMethodConfigurationUpdateParams.Mobilepay.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.Mobilepay#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.Mobilepay#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.Mobilepay.DisplayPreference build() {
+ return new PaymentMethodConfigurationUpdateParams.Mobilepay.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.Mobilepay.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.Mobilepay.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.Mobilepay.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 Multibanco {
/** Whether or not the payment method should be displayed. */
diff --git a/src/main/java/com/stripe/param/PriceCreateParams.java b/src/main/java/com/stripe/param/PriceCreateParams.java
index 27b67eefbf9..90ae7bf8209 100644
--- a/src/main/java/com/stripe/param/PriceCreateParams.java
+++ b/src/main/java/com/stripe/param/PriceCreateParams.java
@@ -137,8 +137,8 @@ public class PriceCreateParams extends ApiRequestParams {
/**
* A positive integer in cents (or local equivalent) (or 0 for a free price) representing how much
- * to charge. One of {@code unit_amount} or {@code custom_unit_amount} is required, unless {@code
- * billing_scheme=tiered}.
+ * to charge. One of {@code unit_amount}, {@code unit_amount_decimal}, or {@code
+ * custom_unit_amount} is required, unless {@code billing_scheme=tiered}.
*/
@SerializedName("unit_amount")
Long unitAmount;
@@ -508,8 +508,8 @@ public Builder setTransformQuantity(PriceCreateParams.TransformQuantity transfor
/**
* A positive integer in cents (or local equivalent) (or 0 for a free price) representing how
- * much to charge. One of {@code unit_amount} or {@code custom_unit_amount} is required, unless
- * {@code billing_scheme=tiered}.
+ * much to charge. One of {@code unit_amount}, {@code unit_amount_decimal}, or {@code
+ * custom_unit_amount} is required, unless {@code billing_scheme=tiered}.
*/
public Builder setUnitAmount(Long unitAmount) {
this.unitAmount = unitAmount;
diff --git a/src/main/java/com/stripe/param/ProductFeatureCreateParams.java b/src/main/java/com/stripe/param/ProductFeatureCreateParams.java
index 3234caa9662..80b9c20653f 100644
--- a/src/main/java/com/stripe/param/ProductFeatureCreateParams.java
+++ b/src/main/java/com/stripe/param/ProductFeatureCreateParams.java
@@ -12,8 +12,9 @@
@Getter
public class ProductFeatureCreateParams extends ApiRequestParams {
/**
- * Required. The ID of the Feature
- * object attached to this product.
+ * Required. The ID of the Feature object attached to this
+ * product.
*/
@SerializedName("entitlement_feature")
String entitlementFeature;
@@ -55,8 +56,9 @@ public ProductFeatureCreateParams build() {
}
/**
- * Required. The ID of the Feature
- * object attached to this product.
+ * Required. The ID of the Feature object attached to this
+ * product.
*/
public Builder setEntitlementFeature(String entitlementFeature) {
this.entitlementFeature = entitlementFeature;
diff --git a/src/main/java/com/stripe/param/QuoteCreateParams.java b/src/main/java/com/stripe/param/QuoteCreateParams.java
index 141cd6b881b..98bec9aaa95 100644
--- a/src/main/java/com/stripe/param/QuoteCreateParams.java
+++ b/src/main/java/com/stripe/param/QuoteCreateParams.java
@@ -1633,6 +1633,16 @@ public static class Line {
@SerializedName("billing_cycle_anchor")
BillingCycleAnchor billingCycleAnchor;
+ /**
+ * A point-in-time operation that cancels an existing subscription schedule at the line's
+ * starts_at timestamp. Currently only compatible with {@code quote_acceptance_date} for {@code
+ * starts_at}. When using cancel_subscription_schedule, the subscription schedule on the quote
+ * remains unalterable, except for modifications to the metadata, collection_method or
+ * invoice_settings.
+ */
+ @SerializedName("cancel_subscription_schedule")
+ CancelSubscriptionSchedule cancelSubscriptionSchedule;
+
/**
* Details to identify the end of the time range modified by the proposed change. If not
* supplied, the quote line is considered a point-in-time operation that only affects the exact
@@ -1684,6 +1694,7 @@ private Line(
List actions,
AppliesTo appliesTo,
BillingCycleAnchor billingCycleAnchor,
+ CancelSubscriptionSchedule cancelSubscriptionSchedule,
EndsAt endsAt,
Map extraParams,
ProrationBehavior prorationBehavior,
@@ -1694,6 +1705,7 @@ private Line(
this.actions = actions;
this.appliesTo = appliesTo;
this.billingCycleAnchor = billingCycleAnchor;
+ this.cancelSubscriptionSchedule = cancelSubscriptionSchedule;
this.endsAt = endsAt;
this.extraParams = extraParams;
this.prorationBehavior = prorationBehavior;
@@ -1714,6 +1726,8 @@ public static class Builder {
private BillingCycleAnchor billingCycleAnchor;
+ private CancelSubscriptionSchedule cancelSubscriptionSchedule;
+
private EndsAt endsAt;
private Map extraParams;
@@ -1734,6 +1748,7 @@ public QuoteCreateParams.Line build() {
this.actions,
this.appliesTo,
this.billingCycleAnchor,
+ this.cancelSubscriptionSchedule,
this.endsAt,
this.extraParams,
this.prorationBehavior,
@@ -1785,6 +1800,19 @@ public Builder setBillingCycleAnchor(
return this;
}
+ /**
+ * A point-in-time operation that cancels an existing subscription schedule at the line's
+ * starts_at timestamp. Currently only compatible with {@code quote_acceptance_date} for
+ * {@code starts_at}. When using cancel_subscription_schedule, the subscription schedule on
+ * the quote remains unalterable, except for modifications to the metadata, collection_method
+ * or invoice_settings.
+ */
+ public Builder setCancelSubscriptionSchedule(
+ QuoteCreateParams.Line.CancelSubscriptionSchedule cancelSubscriptionSchedule) {
+ this.cancelSubscriptionSchedule = cancelSubscriptionSchedule;
+ return this;
+ }
+
/**
* Details to identify the end of the time range modified by the proposed change. If not
* supplied, the quote line is considered a point-in-time operation that only affects the
@@ -4315,6 +4343,137 @@ public enum Type implements ApiRequestParams.EnumParam {
}
}
+ @Getter
+ public static class CancelSubscriptionSchedule {
+ /**
+ * Required. Timestamp helper to cancel the underlying schedule on the
+ * accompanying line's start date. Must be set to {@code line_starts_at}.
+ */
+ @SerializedName("cancel_at")
+ CancelAt cancelAt;
+
+ /**
+ * 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;
+
+ /**
+ * If the subscription schedule is {@code active}, indicates if a final invoice will be
+ * generated that contains any un-invoiced metered usage and new/pending proration invoice
+ * items. Boolean that defaults to {@code true}.
+ */
+ @SerializedName("invoice_now")
+ Boolean invoiceNow;
+
+ /**
+ * If the subscription schedule is {@code active}, indicates if the cancellation should be
+ * prorated. Boolean that defaults to {@code true}.
+ */
+ @SerializedName("prorate")
+ Boolean prorate;
+
+ private CancelSubscriptionSchedule(
+ CancelAt cancelAt, Map extraParams, Boolean invoiceNow, Boolean prorate) {
+ this.cancelAt = cancelAt;
+ this.extraParams = extraParams;
+ this.invoiceNow = invoiceNow;
+ this.prorate = prorate;
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ public static class Builder {
+ private CancelAt cancelAt;
+
+ private Map extraParams;
+
+ private Boolean invoiceNow;
+
+ private Boolean prorate;
+
+ /** Finalize and obtain parameter instance from this builder. */
+ public QuoteCreateParams.Line.CancelSubscriptionSchedule build() {
+ return new QuoteCreateParams.Line.CancelSubscriptionSchedule(
+ this.cancelAt, this.extraParams, this.invoiceNow, this.prorate);
+ }
+
+ /**
+ * Required. Timestamp helper to cancel the underlying schedule on the
+ * accompanying line's start date. Must be set to {@code line_starts_at}.
+ */
+ public Builder setCancelAt(
+ QuoteCreateParams.Line.CancelSubscriptionSchedule.CancelAt cancelAt) {
+ this.cancelAt = cancelAt;
+ 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 QuoteCreateParams.Line.CancelSubscriptionSchedule#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 QuoteCreateParams.Line.CancelSubscriptionSchedule#extraParams} for the
+ * field documentation.
+ */
+ public Builder putAllExtraParam(Map map) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.putAll(map);
+ return this;
+ }
+
+ /**
+ * If the subscription schedule is {@code active}, indicates if a final invoice will be
+ * generated that contains any un-invoiced metered usage and new/pending proration invoice
+ * items. Boolean that defaults to {@code true}.
+ */
+ public Builder setInvoiceNow(Boolean invoiceNow) {
+ this.invoiceNow = invoiceNow;
+ return this;
+ }
+
+ /**
+ * If the subscription schedule is {@code active}, indicates if the cancellation should be
+ * prorated. Boolean that defaults to {@code true}.
+ */
+ public Builder setProrate(Boolean prorate) {
+ this.prorate = prorate;
+ return this;
+ }
+ }
+
+ public enum CancelAt implements ApiRequestParams.EnumParam {
+ @SerializedName("line_starts_at")
+ LINE_STARTS_AT("line_starts_at");
+
+ @Getter(onMethod_ = {@Override})
+ private final String value;
+
+ CancelAt(String value) {
+ this.value = value;
+ }
+ }
+ }
+
@Getter
public static class EndsAt {
/** Use the {@code end} time of a given discount. */
diff --git a/src/main/java/com/stripe/param/QuoteUpdateParams.java b/src/main/java/com/stripe/param/QuoteUpdateParams.java
index 44cb0f653e4..8317db6d6e2 100644
--- a/src/main/java/com/stripe/param/QuoteUpdateParams.java
+++ b/src/main/java/com/stripe/param/QuoteUpdateParams.java
@@ -1538,6 +1538,16 @@ public static class Line {
@SerializedName("billing_cycle_anchor")
BillingCycleAnchor billingCycleAnchor;
+ /**
+ * A point-in-time operation that cancels an existing subscription schedule at the line's
+ * starts_at timestamp. Currently only compatible with {@code quote_acceptance_date} for {@code
+ * starts_at}. When using cancel_subscription_schedule, the subscription schedule on the quote
+ * remains unalterable, except for modifications to the metadata, collection_method or
+ * invoice_settings.
+ */
+ @SerializedName("cancel_subscription_schedule")
+ CancelSubscriptionSchedule cancelSubscriptionSchedule;
+
/**
* Details to identify the end of the time range modified by the proposed change. If not
* supplied, the quote line is considered a point-in-time operation that only affects the exact
@@ -1593,6 +1603,7 @@ private Line(
List actions,
AppliesTo appliesTo,
BillingCycleAnchor billingCycleAnchor,
+ CancelSubscriptionSchedule cancelSubscriptionSchedule,
EndsAt endsAt,
Map extraParams,
Object id,
@@ -1604,6 +1615,7 @@ private Line(
this.actions = actions;
this.appliesTo = appliesTo;
this.billingCycleAnchor = billingCycleAnchor;
+ this.cancelSubscriptionSchedule = cancelSubscriptionSchedule;
this.endsAt = endsAt;
this.extraParams = extraParams;
this.id = id;
@@ -1625,6 +1637,8 @@ public static class Builder {
private BillingCycleAnchor billingCycleAnchor;
+ private CancelSubscriptionSchedule cancelSubscriptionSchedule;
+
private EndsAt endsAt;
private Map extraParams;
@@ -1647,6 +1661,7 @@ public QuoteUpdateParams.Line build() {
this.actions,
this.appliesTo,
this.billingCycleAnchor,
+ this.cancelSubscriptionSchedule,
this.endsAt,
this.extraParams,
this.id,
@@ -1699,6 +1714,19 @@ public Builder setBillingCycleAnchor(
return this;
}
+ /**
+ * A point-in-time operation that cancels an existing subscription schedule at the line's
+ * starts_at timestamp. Currently only compatible with {@code quote_acceptance_date} for
+ * {@code starts_at}. When using cancel_subscription_schedule, the subscription schedule on
+ * the quote remains unalterable, except for modifications to the metadata, collection_method
+ * or invoice_settings.
+ */
+ public Builder setCancelSubscriptionSchedule(
+ QuoteUpdateParams.Line.CancelSubscriptionSchedule cancelSubscriptionSchedule) {
+ this.cancelSubscriptionSchedule = cancelSubscriptionSchedule;
+ return this;
+ }
+
/**
* Details to identify the end of the time range modified by the proposed change. If not
* supplied, the quote line is considered a point-in-time operation that only affects the
@@ -4365,6 +4393,137 @@ public enum Type implements ApiRequestParams.EnumParam {
}
}
+ @Getter
+ public static class CancelSubscriptionSchedule {
+ /**
+ * Required. Timestamp helper to cancel the underlying schedule on the
+ * accompanying line's start date. Must be set to {@code line_starts_at}.
+ */
+ @SerializedName("cancel_at")
+ CancelAt cancelAt;
+
+ /**
+ * 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;
+
+ /**
+ * If the subscription schedule is {@code active}, indicates if a final invoice will be
+ * generated that contains any un-invoiced metered usage and new/pending proration invoice
+ * items. Boolean that defaults to {@code true}.
+ */
+ @SerializedName("invoice_now")
+ Boolean invoiceNow;
+
+ /**
+ * If the subscription schedule is {@code active}, indicates if the cancellation should be
+ * prorated. Boolean that defaults to {@code true}.
+ */
+ @SerializedName("prorate")
+ Boolean prorate;
+
+ private CancelSubscriptionSchedule(
+ CancelAt cancelAt, Map extraParams, Boolean invoiceNow, Boolean prorate) {
+ this.cancelAt = cancelAt;
+ this.extraParams = extraParams;
+ this.invoiceNow = invoiceNow;
+ this.prorate = prorate;
+ }
+
+ public static Builder builder() {
+ return new Builder();
+ }
+
+ public static class Builder {
+ private CancelAt cancelAt;
+
+ private Map extraParams;
+
+ private Boolean invoiceNow;
+
+ private Boolean prorate;
+
+ /** Finalize and obtain parameter instance from this builder. */
+ public QuoteUpdateParams.Line.CancelSubscriptionSchedule build() {
+ return new QuoteUpdateParams.Line.CancelSubscriptionSchedule(
+ this.cancelAt, this.extraParams, this.invoiceNow, this.prorate);
+ }
+
+ /**
+ * Required. Timestamp helper to cancel the underlying schedule on the
+ * accompanying line's start date. Must be set to {@code line_starts_at}.
+ */
+ public Builder setCancelAt(
+ QuoteUpdateParams.Line.CancelSubscriptionSchedule.CancelAt cancelAt) {
+ this.cancelAt = cancelAt;
+ 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 QuoteUpdateParams.Line.CancelSubscriptionSchedule#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 QuoteUpdateParams.Line.CancelSubscriptionSchedule#extraParams} for the
+ * field documentation.
+ */
+ public Builder putAllExtraParam(Map map) {
+ if (this.extraParams == null) {
+ this.extraParams = new HashMap<>();
+ }
+ this.extraParams.putAll(map);
+ return this;
+ }
+
+ /**
+ * If the subscription schedule is {@code active}, indicates if a final invoice will be
+ * generated that contains any un-invoiced metered usage and new/pending proration invoice
+ * items. Boolean that defaults to {@code true}.
+ */
+ public Builder setInvoiceNow(Boolean invoiceNow) {
+ this.invoiceNow = invoiceNow;
+ return this;
+ }
+
+ /**
+ * If the subscription schedule is {@code active}, indicates if the cancellation should be
+ * prorated. Boolean that defaults to {@code true}.
+ */
+ public Builder setProrate(Boolean prorate) {
+ this.prorate = prorate;
+ return this;
+ }
+ }
+
+ public enum CancelAt implements ApiRequestParams.EnumParam {
+ @SerializedName("line_starts_at")
+ LINE_STARTS_AT("line_starts_at");
+
+ @Getter(onMethod_ = {@Override})
+ private final String value;
+
+ CancelAt(String value) {
+ this.value = value;
+ }
+ }
+ }
+
@Getter
public static class EndsAt {
/** Use the {@code end} time of a given discount. */
diff --git a/src/main/java/com/stripe/param/SubscriptionCreateParams.java b/src/main/java/com/stripe/param/SubscriptionCreateParams.java
index 5f404045b4b..758fc8262df 100644
--- a/src/main/java/com/stripe/param/SubscriptionCreateParams.java
+++ b/src/main/java/com/stripe/param/SubscriptionCreateParams.java
@@ -5961,6 +5961,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam {
@SerializedName("acss_debit")
ACSS_DEBIT("acss_debit"),
+ @SerializedName("amazon_pay")
+ AMAZON_PAY("amazon_pay"),
+
@SerializedName("au_becs_debit")
AU_BECS_DEBIT("au_becs_debit"),
@@ -6015,6 +6018,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam {
@SerializedName("promptpay")
PROMPTPAY("promptpay"),
+ @SerializedName("revolut_pay")
+ REVOLUT_PAY("revolut_pay"),
+
@SerializedName("sepa_credit_transfer")
SEPA_CREDIT_TRANSFER("sepa_credit_transfer"),
diff --git a/src/main/java/com/stripe/param/SubscriptionUpdateParams.java b/src/main/java/com/stripe/param/SubscriptionUpdateParams.java
index 1794e02828a..a27082ab985 100644
--- a/src/main/java/com/stripe/param/SubscriptionUpdateParams.java
+++ b/src/main/java/com/stripe/param/SubscriptionUpdateParams.java
@@ -6239,6 +6239,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam {
@SerializedName("acss_debit")
ACSS_DEBIT("acss_debit"),
+ @SerializedName("amazon_pay")
+ AMAZON_PAY("amazon_pay"),
+
@SerializedName("au_becs_debit")
AU_BECS_DEBIT("au_becs_debit"),
@@ -6293,6 +6296,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam {
@SerializedName("promptpay")
PROMPTPAY("promptpay"),
+ @SerializedName("revolut_pay")
+ REVOLUT_PAY("revolut_pay"),
+
@SerializedName("sepa_credit_transfer")
SEPA_CREDIT_TRANSFER("sepa_credit_transfer"),
diff --git a/src/main/java/com/stripe/param/identity/VerificationSessionCreateParams.java b/src/main/java/com/stripe/param/identity/VerificationSessionCreateParams.java
index b7f49e8c15d..6c10b864dff 100644
--- a/src/main/java/com/stripe/param/identity/VerificationSessionCreateParams.java
+++ b/src/main/java/com/stripe/param/identity/VerificationSessionCreateParams.java
@@ -55,12 +55,16 @@ public class VerificationSessionCreateParams extends ApiRequestParams {
/**
* The type of verification
- * check to be performed.
+ * check to be performed. You must provide a {@code type} if not passing {@code
+ * verification_flow}.
*/
@SerializedName("type")
Type type;
- /** The ID of a Verification Flow from the Dashboard. */
+ /**
+ * The ID of a Verification Flow from the Dashboard. See
+ * https://docs.stripe.com/identity/verification-flows.
+ */
@SerializedName("verification_flow")
String verificationFlow;
@@ -230,14 +234,18 @@ public Builder setReturnUrl(String returnUrl) {
/**
* The type of verification
- * check to be performed.
+ * check to be performed. You must provide a {@code type} if not passing {@code
+ * verification_flow}.
*/
public Builder setType(VerificationSessionCreateParams.Type type) {
this.type = type;
return this;
}
- /** The ID of a Verification Flow from the Dashboard. */
+ /**
+ * The ID of a Verification Flow from the Dashboard. See
+ * https://docs.stripe.com/identity/verification-flows.
+ */
public Builder setVerificationFlow(String verificationFlow) {
this.verificationFlow = verificationFlow;
return this;
@@ -253,10 +261,6 @@ public static class Options {
@SerializedName("document")
Object document;
- /** Options that apply to the email check. */
- @SerializedName("email")
- Object email;
-
/**
* 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
@@ -266,15 +270,9 @@ public static class Options {
@SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY)
Map extraParams;
- /** Options that apply to the phone check. */
- @SerializedName("phone")
- Object phone;
-
- private Options(Object document, Object email, Map extraParams, Object phone) {
+ private Options(Object document, Map extraParams) {
this.document = document;
- this.email = email;
this.extraParams = extraParams;
- this.phone = phone;
}
public static Builder builder() {
@@ -284,16 +282,11 @@ public static Builder builder() {
public static class Builder {
private Object document;
- private Object email;
-
private Map extraParams;
- private Object phone;
-
/** Finalize and obtain parameter instance from this builder. */
public VerificationSessionCreateParams.Options build() {
- return new VerificationSessionCreateParams.Options(
- this.document, this.email, this.extraParams, this.phone);
+ return new VerificationSessionCreateParams.Options(this.document, this.extraParams);
}
/**
@@ -316,18 +309,6 @@ public Builder setDocument(EmptyParam document) {
return this;
}
- /** Options that apply to the email check. */
- public Builder setEmail(VerificationSessionCreateParams.Options.Email email) {
- this.email = email;
- return this;
- }
-
- /** Options that apply to the email check. */
- public Builder setEmail(EmptyParam email) {
- this.email = email;
- 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
@@ -354,18 +335,6 @@ public Builder putAllExtraParam(Map map) {
this.extraParams.putAll(map);
return this;
}
-
- /** Options that apply to the phone check. */
- public Builder setPhone(VerificationSessionCreateParams.Options.Phone phone) {
- this.phone = phone;
- return this;
- }
-
- /** Options that apply to the phone check. */
- public Builder setPhone(EmptyParam phone) {
- this.phone = phone;
- return this;
- }
}
@Getter
@@ -556,148 +525,6 @@ public enum AllowedType implements ApiRequestParams.EnumParam {
}
}
}
-
- @Getter
- public static class Email {
- /**
- * 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;
-
- /** Request one time password verification of {@code provided_details.email}. */
- @SerializedName("require_verification")
- Boolean requireVerification;
-
- private Email(Map extraParams, Boolean requireVerification) {
- this.extraParams = extraParams;
- this.requireVerification = requireVerification;
- }
-
- public static Builder builder() {
- return new Builder();
- }
-
- public static class Builder {
- private Map extraParams;
-
- private Boolean requireVerification;
-
- /** Finalize and obtain parameter instance from this builder. */
- public VerificationSessionCreateParams.Options.Email build() {
- return new VerificationSessionCreateParams.Options.Email(
- this.extraParams, this.requireVerification);
- }
-
- /**
- * 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 VerificationSessionCreateParams.Options.Email#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 VerificationSessionCreateParams.Options.Email#extraParams} for the field
- * documentation.
- */
- public Builder putAllExtraParam(Map map) {
- if (this.extraParams == null) {
- this.extraParams = new HashMap<>();
- }
- this.extraParams.putAll(map);
- return this;
- }
-
- /** Request one time password verification of {@code provided_details.email}. */
- public Builder setRequireVerification(Boolean requireVerification) {
- this.requireVerification = requireVerification;
- return this;
- }
- }
- }
-
- @Getter
- public static class Phone {
- /**
- * 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;
-
- /** Request one time password verification of {@code provided_details.phone}. */
- @SerializedName("require_verification")
- Boolean requireVerification;
-
- private Phone(Map extraParams, Boolean requireVerification) {
- this.extraParams = extraParams;
- this.requireVerification = requireVerification;
- }
-
- public static Builder builder() {
- return new Builder();
- }
-
- public static class Builder {
- private Map extraParams;
-
- private Boolean requireVerification;
-
- /** Finalize and obtain parameter instance from this builder. */
- public VerificationSessionCreateParams.Options.Phone build() {
- return new VerificationSessionCreateParams.Options.Phone(
- this.extraParams, this.requireVerification);
- }
-
- /**
- * 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 VerificationSessionCreateParams.Options.Phone#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 VerificationSessionCreateParams.Options.Phone#extraParams} for the field
- * documentation.
- */
- public Builder putAllExtraParam(Map map) {
- if (this.extraParams == null) {
- this.extraParams = new HashMap<>();
- }
- this.extraParams.putAll(map);
- return this;
- }
-
- /** Request one time password verification of {@code provided_details.phone}. */
- public Builder setRequireVerification(Boolean requireVerification) {
- this.requireVerification = requireVerification;
- return this;
- }
- }
- }
}
@Getter
diff --git a/src/main/java/com/stripe/param/identity/VerificationSessionUpdateParams.java b/src/main/java/com/stripe/param/identity/VerificationSessionUpdateParams.java
index 9983bea36d9..a2795f9d122 100644
--- a/src/main/java/com/stripe/param/identity/VerificationSessionUpdateParams.java
+++ b/src/main/java/com/stripe/param/identity/VerificationSessionUpdateParams.java
@@ -202,10 +202,6 @@ public static class Options {
@SerializedName("document")
Object document;
- /** Options that apply to the email check. */
- @SerializedName("email")
- Object email;
-
/**
* 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
@@ -215,15 +211,9 @@ public static class Options {
@SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY)
Map extraParams;
- /** Options that apply to the phone check. */
- @SerializedName("phone")
- Object phone;
-
- private Options(Object document, Object email, Map extraParams, Object phone) {
+ private Options(Object document, Map extraParams) {
this.document = document;
- this.email = email;
this.extraParams = extraParams;
- this.phone = phone;
}
public static Builder builder() {
@@ -233,16 +223,11 @@ public static Builder builder() {
public static class Builder {
private Object document;
- private Object email;
-
private Map extraParams;
- private Object phone;
-
/** Finalize and obtain parameter instance from this builder. */
public VerificationSessionUpdateParams.Options build() {
- return new VerificationSessionUpdateParams.Options(
- this.document, this.email, this.extraParams, this.phone);
+ return new VerificationSessionUpdateParams.Options(this.document, this.extraParams);
}
/**
@@ -265,18 +250,6 @@ public Builder setDocument(EmptyParam document) {
return this;
}
- /** Options that apply to the email check. */
- public Builder setEmail(VerificationSessionUpdateParams.Options.Email email) {
- this.email = email;
- return this;
- }
-
- /** Options that apply to the email check. */
- public Builder setEmail(EmptyParam email) {
- this.email = email;
- 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
@@ -303,18 +276,6 @@ public Builder putAllExtraParam(Map map) {
this.extraParams.putAll(map);
return this;
}
-
- /** Options that apply to the phone check. */
- public Builder setPhone(VerificationSessionUpdateParams.Options.Phone phone) {
- this.phone = phone;
- return this;
- }
-
- /** Options that apply to the phone check. */
- public Builder setPhone(EmptyParam phone) {
- this.phone = phone;
- return this;
- }
}
@Getter
@@ -505,148 +466,6 @@ public enum AllowedType implements ApiRequestParams.EnumParam {
}
}
}
-
- @Getter
- public static class Email {
- /**
- * 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;
-
- /** Request one time password verification of {@code provided_details.email}. */
- @SerializedName("require_verification")
- Boolean requireVerification;
-
- private Email(Map extraParams, Boolean requireVerification) {
- this.extraParams = extraParams;
- this.requireVerification = requireVerification;
- }
-
- public static Builder builder() {
- return new Builder();
- }
-
- public static class Builder {
- private Map extraParams;
-
- private Boolean requireVerification;
-
- /** Finalize and obtain parameter instance from this builder. */
- public VerificationSessionUpdateParams.Options.Email build() {
- return new VerificationSessionUpdateParams.Options.Email(
- this.extraParams, this.requireVerification);
- }
-
- /**
- * 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 VerificationSessionUpdateParams.Options.Email#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 VerificationSessionUpdateParams.Options.Email#extraParams} for the field
- * documentation.
- */
- public Builder putAllExtraParam(Map map) {
- if (this.extraParams == null) {
- this.extraParams = new HashMap<>();
- }
- this.extraParams.putAll(map);
- return this;
- }
-
- /** Request one time password verification of {@code provided_details.email}. */
- public Builder setRequireVerification(Boolean requireVerification) {
- this.requireVerification = requireVerification;
- return this;
- }
- }
- }
-
- @Getter
- public static class Phone {
- /**
- * 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;
-
- /** Request one time password verification of {@code provided_details.phone}. */
- @SerializedName("require_verification")
- Boolean requireVerification;
-
- private Phone(Map extraParams, Boolean requireVerification) {
- this.extraParams = extraParams;
- this.requireVerification = requireVerification;
- }
-
- public static Builder builder() {
- return new Builder();
- }
-
- public static class Builder {
- private Map extraParams;
-
- private Boolean requireVerification;
-
- /** Finalize and obtain parameter instance from this builder. */
- public VerificationSessionUpdateParams.Options.Phone build() {
- return new VerificationSessionUpdateParams.Options.Phone(
- this.extraParams, this.requireVerification);
- }
-
- /**
- * 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 VerificationSessionUpdateParams.Options.Phone#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 VerificationSessionUpdateParams.Options.Phone#extraParams} for the field
- * documentation.
- */
- public Builder putAllExtraParam(Map map) {
- if (this.extraParams == null) {
- this.extraParams = new HashMap<>();
- }
- this.extraParams.putAll(map);
- return this;
- }
-
- /** Request one time password verification of {@code provided_details.phone}. */
- public Builder setRequireVerification(Boolean requireVerification) {
- this.requireVerification = requireVerification;
- return this;
- }
- }
- }
}
@Getter
diff --git a/src/main/java/com/stripe/service/AccountExternalAccountService.java b/src/main/java/com/stripe/service/AccountExternalAccountService.java
index 0fcd47505f1..8b722513ca7 100644
--- a/src/main/java/com/stripe/service/AccountExternalAccountService.java
+++ b/src/main/java/com/stripe/service/AccountExternalAccountService.java
@@ -78,8 +78,13 @@ public ExternalAccount retrieve(
}
/**
* Updates the metadata, account holder name, account holder type of a bank account belonging to a
- * Custom account, and optionally
- * sets it as the default for its currency. Other bank account details are not editable by design.
+ * connected account and optionally sets it as the default for its currency. Other bank account
+ * details are not editable by design.
+ *
+ * You can only update bank accounts when account.controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*
*
You can re-enable a disabled bank account by performing an update call without providing any
* arguments or changes.
@@ -90,8 +95,13 @@ public ExternalAccount update(
}
/**
* Updates the metadata, account holder name, account holder type of a bank account belonging to a
- * Custom account, and optionally
- * sets it as the default for its currency. Other bank account details are not editable by design.
+ * connected account and optionally sets it as the default for its currency. Other bank account
+ * details are not editable by design.
+ *
+ *
You can only update bank accounts when account.controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*
*
You can re-enable a disabled bank account by performing an update call without providing any
* arguments or changes.
@@ -102,8 +112,13 @@ public ExternalAccount update(String account, String id, RequestOptions options)
}
/**
* Updates the metadata, account holder name, account holder type of a bank account belonging to a
- * Custom account, and optionally
- * sets it as the default for its currency. Other bank account details are not editable by design.
+ * connected account and optionally sets it as the default for its currency. Other bank account
+ * details are not editable by design.
+ *
+ *
You can only update bank accounts when account.controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*
*
You can re-enable a disabled bank account by performing an update call without providing any
* arguments or changes.
@@ -113,8 +128,13 @@ public ExternalAccount update(String account, String id) throws StripeException
}
/**
* Updates the metadata, account holder name, account holder type of a bank account belonging to a
- * Custom account, and optionally
- * sets it as the default for its currency. Other bank account details are not editable by design.
+ * connected account and optionally sets it as the default for its currency. Other bank account
+ * details are not editable by design.
+ *
+ *
You can only update bank accounts when account.controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*
*
You can re-enable a disabled bank account by performing an update call without providing any
* arguments or changes.
diff --git a/src/main/java/com/stripe/service/AccountLoginLinkService.java b/src/main/java/com/stripe/service/AccountLoginLinkService.java
index 9ce2f478e83..47f91d1a9c5 100644
--- a/src/main/java/com/stripe/service/AccountLoginLinkService.java
+++ b/src/main/java/com/stripe/service/AccountLoginLinkService.java
@@ -19,42 +19,42 @@ public AccountLoginLinkService(StripeResponseGetter responseGetter) {
}
/**
- * Creates a single-use login link for an Express account to access their Stripe dashboard.
+ * Creates a single-use login link for a connected account to access the Express Dashboard.
*
- *
You may only create login links for Express accounts connected to your
- * platform.
+ *
You can only create login links for accounts that use the Express Dashboard and are connected to
+ * your platform.
*/
public LoginLink create(String account, AccountLoginLinkCreateParams params)
throws StripeException {
return create(account, params, (RequestOptions) null);
}
/**
- * Creates a single-use login link for an Express account to access their Stripe dashboard.
+ * Creates a single-use login link for a connected account to access the Express Dashboard.
*
- *
You may only create login links for Express accounts connected to your
- * platform.
+ *
You can only create login links for accounts that use the Express Dashboard and are connected to
+ * your platform.
*/
public LoginLink create(String account, RequestOptions options) throws StripeException {
return create(account, (AccountLoginLinkCreateParams) null, options);
}
/**
- * Creates a single-use login link for an Express account to access their Stripe dashboard.
+ * Creates a single-use login link for a connected account to access the Express Dashboard.
*
- *
You may only create login links for Express accounts connected to your
- * platform.
+ *
You can only create login links for accounts that use the Express Dashboard and are connected to
+ * your platform.
*/
public LoginLink create(String account) throws StripeException {
return create(account, (AccountLoginLinkCreateParams) null, (RequestOptions) null);
}
/**
- * Creates a single-use login link for an Express account to access their Stripe dashboard.
+ * Creates a single-use login link for a connected account to access the Express Dashboard.
*
- *
You may only create login links for Express accounts connected to your
- * platform.
+ *
You can only create login links for accounts that use the Express Dashboard and are connected to
+ * your platform.
*/
public LoginLink create(
String account, AccountLoginLinkCreateParams params, RequestOptions options)
diff --git a/src/main/java/com/stripe/service/AccountService.java b/src/main/java/com/stripe/service/AccountService.java
index 588f148642a..d9f59b62281 100644
--- a/src/main/java/com/stripe/service/AccountService.java
+++ b/src/main/java/com/stripe/service/AccountService.java
@@ -26,11 +26,14 @@ public AccountService(StripeResponseGetter responseGetter) {
}
/**
- * With Connect, you can delete accounts you manage.
+ * With Connect, you can delete accounts you manage.
*
- *
Accounts created using test-mode keys can be deleted at any time. Standard accounts created
- * using live-mode keys cannot be deleted. Custom or Express accounts created using live-mode keys
- * can only be deleted once all balances are zero.
+ *
Test-mode accounts can be deleted at any time.
+ *
+ *
Live-mode accounts where Stripe is responsible for negative account balances cannot be
+ * deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for
+ * negative account balances, which includes Custom and Express accounts, can be deleted when all
+ * balances are zero.
*
*
If you want to delete your own account, use the account information tab in your account
@@ -40,11 +43,14 @@ public Account delete(String account) throws StripeException {
return delete(account, (RequestOptions) null);
}
/**
- * With Connect, you can delete accounts you manage.
+ * With Connect, you can delete accounts you manage.
+ *
+ *
Test-mode accounts can be deleted at any time.
*
- *
Accounts created using test-mode keys can be deleted at any time. Standard accounts created
- * using live-mode keys cannot be deleted. Custom or Express accounts created using live-mode keys
- * can only be deleted once all balances are zero.
+ *
Live-mode accounts where Stripe is responsible for negative account balances cannot be
+ * deleted, which includes Standard accounts. Live-mode accounts where your platform is liable for
+ * negative account balances, which includes Custom and Express accounts, can be deleted when all
+ * balances are zero.
*
*
If you want to delete your own account, use the account information tab in your account
@@ -84,14 +90,20 @@ public Account retrieve(String account, AccountRetrieveParams params, RequestOpt
return this.request(request, Account.class);
}
/**
- * Updates a connected account by setting
- * the values of the parameters passed. Any parameters not provided are left unchanged.
+ * Updates a connected account by setting the
+ * values of the parameters passed. Any parameters not provided are left unchanged.
+ *
+ *
For accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, you can update any information on the
+ * account.
*
- *
For Custom accounts, you can update any information on the account. For other accounts, you
- * can update all information until that account has started to go through Connect Onboarding.
- * Once you create an Account Link or Account Session, some properties can
- * only be changed or updated for Custom accounts.
+ *
For accounts where controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, you can update all information
+ * until you create an Account Link or Account Session to start Connect onboarding,
+ * after which some properties can no longer be updated.
*
*
To update your own account, use the Dashboard. Refer to our connected account by setting
- * the values of the parameters passed. Any parameters not provided are left unchanged.
+ * Updates a connected account by setting the
+ * values of the parameters passed. Any parameters not provided are left unchanged.
*
- *
For Custom accounts, you can update any information on the account. For other accounts, you
- * can update all information until that account has started to go through Connect Onboarding.
- * Once you create an Account Link or Account Session, some properties can
- * only be changed or updated for Custom accounts.
+ *
For accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, you can update any information on the
+ * account.
+ *
+ *
For accounts where controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, you can update all information
+ * until you create an Account Link or Account Session to start Connect onboarding,
+ * after which some properties can no longer be updated.
*
*
To update your own account, use the Dashboard. Refer to our connected account by setting
- * the values of the parameters passed. Any parameters not provided are left unchanged.
+ * Updates a connected account by setting the
+ * values of the parameters passed. Any parameters not provided are left unchanged.
+ *
+ *
For accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, you can update any information on the
+ * account.
*
- *
For Custom accounts, you can update any information on the account. For other accounts, you
- * can update all information until that account has started to go through Connect Onboarding.
- * Once you create an Account Link or Account Session, some properties can
- * only be changed or updated for Custom accounts.
+ *
For accounts where controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, you can update all information
+ * until you create an Account Link or Account Session to start Connect onboarding,
+ * after which some properties can no longer be updated.
*
*
To update your own account, use the Dashboard. Refer to our connected account by setting
- * the values of the parameters passed. Any parameters not provided are left unchanged.
+ * Updates a connected account by setting the
+ * values of the parameters passed. Any parameters not provided are left unchanged.
+ *
+ *
For accounts where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts, you can update any information on the
+ * account.
*
- *
For Custom accounts, you can update any information on the account. For other accounts, you
- * can update all information until that account has started to go through Connect Onboarding.
- * Once you create an Account Link or Account Session, some properties can
- * only be changed or updated for Custom accounts.
+ *
For accounts where controller.requirement_collection
+ * is {@code stripe}, which includes Standard and Express accounts, you can update all information
+ * until you create an Account Link or Account Session to start Connect onboarding,
+ * after which some properties can no longer be updated.
*
*
To update your own account, use the Dashboard. Refer to our Connect, you may flag accounts as
- * suspicious.
+ * With Connect, you can reject accounts that you have
+ * flagged as suspicious.
*
- *
Test-mode Custom and Express accounts can be rejected at any time. Accounts created using
- * live-mode keys may only be rejected once all balances are zero.
+ *
Only accounts where your platform is liable for negative account balances, which includes
+ * Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time.
+ * Live-mode accounts can only be rejected after all balances are zero.
*/
public Account reject(String account, AccountRejectParams params) throws StripeException {
return reject(account, params, (RequestOptions) null);
}
/**
- * With Connect, you may flag accounts as
- * suspicious.
+ * With Connect, you can reject accounts that you have
+ * flagged as suspicious.
*
- *
Test-mode Custom and Express accounts can be rejected at any time. Accounts created using
- * live-mode keys may only be rejected once all balances are zero.
+ *
Only accounts where your platform is liable for negative account balances, which includes
+ * Custom and Express accounts, can be rejected. Test-mode accounts can be rejected at any time.
+ * Live-mode accounts can only be rejected after all balances are zero.
*/
public Account reject(String account, AccountRejectParams params, RequestOptions options)
throws StripeException {
diff --git a/src/main/java/com/stripe/service/EventService.java b/src/main/java/com/stripe/service/EventService.java
index 8a91e4ec0cb..c64a00c9c18 100644
--- a/src/main/java/com/stripe/service/EventService.java
+++ b/src/main/java/com/stripe/service/EventService.java
@@ -24,7 +24,7 @@ public EventService(StripeResponseGetter responseGetter) {
/**
* List events, going back up to 30 days. Each event data is rendered according to Stripe API
* version at its creation time, specified in event object {@code api_version} attribute
+ * href="https://docs.stripe.com/api/events/object">event object {@code api_version} attribute
* (not according to your current Stripe API version or {@code Stripe-Version} header).
*/
public StripeCollection list(EventListParams params) throws StripeException {
@@ -33,7 +33,7 @@ public StripeCollection list(EventListParams params) throws StripeExcepti
/**
* List events, going back up to 30 days. Each event data is rendered according to Stripe API
* version at its creation time, specified in event object {@code api_version} attribute
+ * href="https://docs.stripe.com/api/events/object">event object {@code api_version} attribute
* (not according to your current Stripe API version or {@code Stripe-Version} header).
*/
public StripeCollection list(RequestOptions options) throws StripeException {
@@ -42,7 +42,7 @@ public StripeCollection list(RequestOptions options) throws StripeExcepti
/**
* List events, going back up to 30 days. Each event data is rendered according to Stripe API
* version at its creation time, specified in event object {@code api_version} attribute
+ * href="https://docs.stripe.com/api/events/object">event object {@code api_version} attribute
* (not according to your current Stripe API version or {@code Stripe-Version} header).
*/
public StripeCollection list() throws StripeException {
@@ -51,7 +51,7 @@ public StripeCollection list() throws StripeException {
/**
* List events, going back up to 30 days. Each event data is rendered according to Stripe API
* version at its creation time, specified in event object {@code api_version} attribute
+ * href="https://docs.stripe.com/api/events/object">event object {@code api_version} attribute
* (not according to your current Stripe API version or {@code Stripe-Version} header).
*/
public StripeCollection list(EventListParams params, RequestOptions options)
diff --git a/src/main/java/com/stripe/service/InvoiceService.java b/src/main/java/com/stripe/service/InvoiceService.java
index 28e81c5d077..c702a033b0e 100644
--- a/src/main/java/com/stripe/service/InvoiceService.java
+++ b/src/main/java/com/stripe/service/InvoiceService.java
@@ -274,10 +274,10 @@ public StripeSearchResult search(InvoiceSearchParams params, RequestOpt
*
* You can preview the effects of updating a subscription, including a preview of what
* proration will take place. To ensure that the actual proration is calculated exactly the same
- * as the previewed proration, you should pass the {@code subscription_proration_date} parameter
- * when doing the actual subscription update. The recommended way to get only the prorations being
- * previewed is to consider only proration line items where {@code period[start]} is equal to the
- * {@code subscription_proration_date} value passed in the request.
+ * as the previewed proration, you should pass the {@code subscription_details.proration_date}
+ * parameter when doing the actual subscription update. The recommended way to get only the
+ * prorations being previewed is to consider only proration line items where {@code period[start]}
+ * is equal to the {@code subscription_details.proration_date} value passed in the request.
*/
public Invoice upcoming(InvoiceUpcomingParams params) throws StripeException {
return upcoming(params, (RequestOptions) null);
@@ -295,10 +295,10 @@ public Invoice upcoming(InvoiceUpcomingParams params) throws StripeException {
*
*
You can preview the effects of updating a subscription, including a preview of what
* proration will take place. To ensure that the actual proration is calculated exactly the same
- * as the previewed proration, you should pass the {@code subscription_proration_date} parameter
- * when doing the actual subscription update. The recommended way to get only the prorations being
- * previewed is to consider only proration line items where {@code period[start]} is equal to the
- * {@code subscription_proration_date} value passed in the request.
+ * as the previewed proration, you should pass the {@code subscription_details.proration_date}
+ * parameter when doing the actual subscription update. The recommended way to get only the
+ * prorations being previewed is to consider only proration line items where {@code period[start]}
+ * is equal to the {@code subscription_details.proration_date} value passed in the request.
*/
public Invoice upcoming(RequestOptions options) throws StripeException {
return upcoming((InvoiceUpcomingParams) null, options);
@@ -316,10 +316,10 @@ public Invoice upcoming(RequestOptions options) throws StripeException {
*
*
You can preview the effects of updating a subscription, including a preview of what
* proration will take place. To ensure that the actual proration is calculated exactly the same
- * as the previewed proration, you should pass the {@code subscription_proration_date} parameter
- * when doing the actual subscription update. The recommended way to get only the prorations being
- * previewed is to consider only proration line items where {@code period[start]} is equal to the
- * {@code subscription_proration_date} value passed in the request.
+ * as the previewed proration, you should pass the {@code subscription_details.proration_date}
+ * parameter when doing the actual subscription update. The recommended way to get only the
+ * prorations being previewed is to consider only proration line items where {@code period[start]}
+ * is equal to the {@code subscription_details.proration_date} value passed in the request.
*/
public Invoice upcoming() throws StripeException {
return upcoming((InvoiceUpcomingParams) null, (RequestOptions) null);
@@ -337,10 +337,10 @@ public Invoice upcoming() throws StripeException {
*
*
You can preview the effects of updating a subscription, including a preview of what
* proration will take place. To ensure that the actual proration is calculated exactly the same
- * as the previewed proration, you should pass the {@code subscription_proration_date} parameter
- * when doing the actual subscription update. The recommended way to get only the prorations being
- * previewed is to consider only proration line items where {@code period[start]} is equal to the
- * {@code subscription_proration_date} value passed in the request.
+ * as the previewed proration, you should pass the {@code subscription_details.proration_date}
+ * parameter when doing the actual subscription update. The recommended way to get only the
+ * prorations being previewed is to consider only proration line items where {@code period[start]}
+ * is equal to the {@code subscription_details.proration_date} value passed in the request.
*/
public Invoice upcoming(InvoiceUpcomingParams params, RequestOptions options)
throws StripeException {
diff --git a/src/main/java/com/stripe/service/TokenService.java b/src/main/java/com/stripe/service/TokenService.java
index 9913bec3797..1d325d99d4f 100644
--- a/src/main/java/com/stripe/service/TokenService.java
+++ b/src/main/java/com/stripe/service/TokenService.java
@@ -48,7 +48,10 @@ public Token retrieve(String token, TokenRetrieveParams params, RequestOptions o
/**
* Creates a single-use token that represents a bank account’s details. You can use this token
* with any API method in place of a bank account dictionary. You can only use this token once. To
- * do so, attach it to a Custom account.
+ * do so, attach it to a connected account
+ * where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Token create(TokenCreateParams params) throws StripeException {
return create(params, (RequestOptions) null);
@@ -56,7 +59,10 @@ public Token create(TokenCreateParams params) throws StripeException {
/**
* Creates a single-use token that represents a bank account’s details. You can use this token
* with any API method in place of a bank account dictionary. You can only use this token once. To
- * do so, attach it to a Custom account.
+ * do so, attach it to a connected account
+ * where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Token create(RequestOptions options) throws StripeException {
return create((TokenCreateParams) null, options);
@@ -64,7 +70,10 @@ public Token create(RequestOptions options) throws StripeException {
/**
* Creates a single-use token that represents a bank account’s details. You can use this token
* with any API method in place of a bank account dictionary. You can only use this token once. To
- * do so, attach it to a Custom account.
+ * do so, attach it to a connected account
+ * where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Token create() throws StripeException {
return create((TokenCreateParams) null, (RequestOptions) null);
@@ -72,7 +81,10 @@ public Token create() throws StripeException {
/**
* Creates a single-use token that represents a bank account’s details. You can use this token
* with any API method in place of a bank account dictionary. You can only use this token once. To
- * do so, attach it to a Custom account.
+ * do so, attach it to a connected account
+ * where controller.requirement_collection
+ * is {@code application}, which includes Custom accounts.
*/
public Token create(TokenCreateParams params, RequestOptions options) throws StripeException {
String path = "/v1/tokens";