From 3ae83bb645aa14c0961402b588c28fa0870bdc33 Mon Sep 17 00:00:00 2001 From: David Brownman Date: Wed, 25 Mar 2026 18:50:56 -0700 Subject: [PATCH 01/11] Bump version to 32.0.0 --- CHANGELOG.md | 52 ++++++++++++++++++++++++++++ README.md | 10 +++--- VERSION | 2 +- gradle.properties | 2 +- src/main/java/com/stripe/Stripe.java | 2 +- 5 files changed, 60 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index de0b98767cf..8a5865fee46 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,57 @@ # Changelog +## 32.0.0 - 2026-03-25 + +This release changes the pinned API version to `2026-03-25.dahlia` and contains breaking changes (prefixed with ⚠️ below). There's also a [detailed migration guide](https://github.com/stripe/stripe-java/wiki/Migration-guide-for-v32) to simplify your upgrade process. + +Please review details for the breaking changes and alternatives in the [Stripe API changelog](https://docs.stripe.com/changelog/dahlia) before upgrading. + +* ⚠️ **Breaking change:** [#2182](https://github.com/stripe/stripe-java/pull/2182) Add setHttpClient to StripeClientBuilder; clean up apiKey/authenticator coupling + - ⚠️ Removed `RequestOptions.getApiKey()`, `RequestOptions.RequestOptionsBuilder.getApiKey()`, and `StripeClient.StripeClientBuilder.getApiKey()`. Use `getAuthenticator()` instead. + - Added `StripeClient.StripeClientBuilder.setHttpClient(HttpClient)` to allow injecting a custom HTTP client. +* ⚠️ **Breaking change:** [#2187](https://github.com/stripe/stripe-java/pull/2187) Regenerate with decimal_string enabled for v2 APIs + - V2 API decimal fields changed type from `String` to `BigDecimal`. Code that reads or writes these fields as `String` will need to use `BigDecimal` instead. Affected fields: + - **V2.Core.Account** / **V2.Core.AccountPerson**: `percentOwnership` + - **PaymentEvaluation.Signals.FraudulentPayment**: `score` + - Params: `AccountCreateParams`, `PersonCreateParams`, `AccountTokenCreateParams`, `PersonTokenCreateParams` (all: `percentOwnership`) + - Params: `InvoiceItemCreateParams`, `InvoiceAddLinesParams`, `InvoiceUpdateLinesParams`, `InvoiceCreatePreviewParams` (all: `quantityDecimal`) +* ⚠️ **Breaking change:** [#2131](https://github.com/stripe/stripe-java/pull/2131) Use HTTP status code in V2 errors + - `RateLimitException` now extends `StripeException` rather than `ApiException` + - Non-200 status codes from V2 endpoints will throw a `StripeException` (e.g. `RateLimitException`, `InvalidRequestException`, etc.) like in V1 instead of a generic `ApiException` +* ⚠️ **Breaking change:** [#2190](https://github.com/stripe/stripe-java/pull/2190) Throw an error when using the wrong webhook parsing method +* ⚠️ **Breaking change:** [#2172](https://github.com/stripe/stripe-java/pull/2172) Make `RequestOptions` & `RawRequestOptions` constructors private and add Stripe-Request-Trigger header +* ⚠️ **Breaking change:** [#2181](https://github.com/stripe/stripe-java/pull/2181) Change Automatic-Module-Name to com.stripe + - Changes `Automatic-Module-Name` from `stripe.java` to `com.stripe`. Users with `requires stripe.java;` in their `module-info.java` will need to update to `requires com.stripe;`. +* [#2179](https://github.com/stripe/stripe-java/pull/2179) Add runtime support for V2 int64 string-encoded fields + + +### ⚠️ Breaking changes due to changes in the Stripe API + +* Generated changes from [#2170](https://github.com/stripe/stripe-java/pull/2170), [#2193](https://github.com/stripe/stripe-java/pull/2193), [#2191](https://github.com/stripe/stripe-java/pull/2191) + * Add support for `upiPayments` on `Account.capabilities`, `AccountCreateParams.capabilities`, and `AccountUpdateParams.capabilities` + * Add support for `upi` on `Charge.payment_method_details`, `ConfirmationToken.payment_method_preview`, `ConfirmationTokenCreateParams.payment_method_data`, `Mandate.payment_method_details`, `PaymentAttemptRecord.payment_method_details`, `PaymentIntent.payment_method_options`, `PaymentIntentConfirmParams.payment_method_data`, `PaymentIntentConfirmParams.payment_method_options`, `PaymentIntentCreateParams.payment_method_data`, `PaymentIntentCreateParams.payment_method_options`, `PaymentIntentUpdateParams.payment_method_data`, `PaymentIntentUpdateParams.payment_method_options`, `PaymentMethodConfigurationCreateParams`, `PaymentMethodConfigurationUpdateParams`, `PaymentMethodConfiguration`, `PaymentMethodCreateParams`, `PaymentMethod`, `PaymentRecord.payment_method_details`, `SetupAttempt.payment_method_details`, `SetupIntent.payment_method_options`, `SetupIntentConfirmParams.payment_method_data`, `SetupIntentConfirmParams.payment_method_options`, `SetupIntentCreateParams.payment_method_data`, `SetupIntentCreateParams.payment_method_options`, `SetupIntentUpdateParams.payment_method_data`, `SetupIntentUpdateParams.payment_method_options`, `checkout.Session.payment_method_options`, and `checkout.SessionCreateParams.payment_method_options` + * Add support for `integrationIdentifier` on `checkout.SessionCreateParams` and `checkout.Session` + * Add support for new value `upi` on enums `PaymentIntentConfirmParams.excludedPaymentMethodTypes`, `PaymentIntentCreateParams.excludedPaymentMethodTypes`, `PaymentIntentUpdateParams.excludedPaymentMethodTypes`, `SetupIntentCreateParams.excludedPaymentMethodTypes`, `SetupIntentUpdateParams.excludedPaymentMethodTypes`, and `checkout.SessionCreateParams.excludedPaymentMethodTypes` + * Add support for `crypto` on `checkout.SessionCreateParams.payment_method_options` + * Add support for new value `upi` on enum `checkout.SessionCreateParams.paymentMethodTypes` + * Add support for `pendingInvoiceItemInterval` on `checkout.SessionCreateParams.subscription_data` + * Add support for new values `elements`, `embedded_page`, `form`, and `hosted_page` on enum `checkout.SessionCreateParams.uiMode` + * Add support for new value `upi` on enums `ConfirmationTokenCreateParams.payment_method_data.type`, `PaymentIntentConfirmParams.payment_method_data.type`, `PaymentIntentCreateParams.payment_method_data.type`, `PaymentIntentUpdateParams.payment_method_data.type`, `SetupIntentConfirmParams.payment_method_data.type`, `SetupIntentCreateParams.payment_method_data.type`, and `SetupIntentUpdateParams.payment_method_data.type` + * Add support for `metadata` on `CreditNoteCreateParams.lines[]`, `CreditNoteLineItem`, `CreditNotePreviewLinesParams.lines[]`, and `CreditNotePreviewParams.lines[]` + * Add support for new value `upi` on enums `CustomerListPaymentMethodsParams.type`, `PaymentMethodCreateParams.type`, and `PaymentMethodListParams.type` + * Add support for `quantityDecimal` on `InvoiceAddLinesParams.lines[]`, `InvoiceCreatePreviewParams.invoice_items[]`, `InvoiceItemCreateParams`, `InvoiceItemUpdateParams`, `InvoiceItem`, `InvoiceLineItemUpdateParams`, `InvoiceLineItem`, and `InvoiceUpdateLinesParams.lines[]` + * ⚠️ Add support for `level` on `issuing.AuthorizationCreateParams.risk_assessment.card_testing_risk` and `issuing.AuthorizationCreateParams.risk_assessment.merchant_dispute_risk` + * ⚠️ Remove support for `riskLevel` on `issuing.AuthorizationCreateParams.risk_assessment.card_testing_risk` and `issuing.AuthorizationCreateParams.risk_assessment.merchant_dispute_risk` + * Add support for `lifecycleControls` on `issuing.CardCreateParams` and `issuing.Card` + * Add support for `cryptogram`, `electronicCommerceIndicator`, `exemptionIndicatorApplied`, and `exemptionIndicator` on `PaymentAttemptRecord.payment_method_details.card.three_d_secure` and `PaymentRecord.payment_method_details.card.three_d_secure` + * Add support for `upiHandleRedirectOrDisplayQrCode` on `PaymentIntent.next_action` and `SetupIntent.next_action` + * Add support for new value `upi` on enums `PaymentLinkCreateParams.paymentMethodTypes` and `PaymentLinkUpdateParams.paymentMethodTypes` + * Add support for `recommendedAction` and `signals` on `radar.PaymentEvaluation` + * ⚠️ Remove support for `insights` on `radar.PaymentEvaluation` + * Add support for new value `crypto_fingerprint` on enum `radar.ValueListCreateParams.itemType` + * Add support for new value `2026-03-25.dahlia` on enum `WebhookEndpointCreateParams.apiVersion` + * ⚠️ Change type of `v2.core.EventDestinationCreateParams.eventsFrom` from `enum('other_accounts'|'self')` to `string` + ## 31.4.1 - 2026-03-06 * [#2168](https://github.com/stripe/stripe-java/pull/2168) Support serializing Stripe objects with ApiResource.GSON * `ApiResource.GSON` now supports serializing Stripe objects back into compatible JSON diff --git a/README.md b/README.md index 9b0aa187bc5..2642db8fe38 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Stripe Java client library -[![Maven Central](https://img.shields.io/badge/maven--central-v31.4.1-blue)](https://mvnrepository.com/artifact/com.stripe/stripe-java) +[![Maven Central](https://img.shields.io/badge/maven--central-v32.0.0-blue)](https://mvnrepository.com/artifact/com.stripe/stripe-java) [![JavaDoc](http://img.shields.io/badge/javadoc-reference-blue.svg)](https://stripe.dev/stripe-java) [![Build Status](https://github.com/stripe/stripe-java/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/stripe/stripe-java/actions?query=branch%3Amaster) @@ -26,7 +26,7 @@ We support LTS versions of the JDK. Currently, that's Java versions: Add this dependency to your project's build file: ```groovy -implementation "com.stripe:stripe-java:31.4.1" +implementation "com.stripe:stripe-java:32.0.0" ``` ### Maven users @@ -37,7 +37,7 @@ Add this dependency to your project's POM: com.stripe stripe-java - 31.4.1 + 32.0.0 ``` @@ -46,8 +46,8 @@ Add this dependency to your project's POM: If you are not using Gradle or Maven, you will need to manually install the following JARs: 1. The Stripe JAR: - - Download the latest release version from [Maven Central](https://repo1.maven.org/maven2/com/stripe/stripe-java/31.4.1/stripe-java-31.4.1.jar) - - Current release version: 31.4.1 + - Download the latest release version from [Maven Central](https://repo1.maven.org/maven2/com/stripe/stripe-java/32.0.0/stripe-java-32.0.0.jar) + - Current release version: 32.0.0 2. Google Gson: - The Stripe JAR builds and tests with Gson version 2.10.1 diff --git a/VERSION b/VERSION index 5ea9e3e99ca..308b186242c 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -31.4.1 +32.0.0 diff --git a/gradle.properties b/gradle.properties index 1343a12179c..d7fc85c1409 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,5 +1,5 @@ GROUP=com.stripe -VERSION_NAME=31.4.1 +VERSION_NAME=32.0.0 POM_URL=https://github.com/stripe/stripe-java POM_SCM_URL=git@github.com:stripe/stripe-java.git diff --git a/src/main/java/com/stripe/Stripe.java b/src/main/java/com/stripe/Stripe.java index 52b74db33bb..d4c6c0e531e 100644 --- a/src/main/java/com/stripe/Stripe.java +++ b/src/main/java/com/stripe/Stripe.java @@ -14,7 +14,7 @@ public abstract class Stripe { public static final String LIVE_API_BASE = "https://api.stripe.com"; public static final String UPLOAD_API_BASE = "https://files.stripe.com"; public static final String METER_EVENTS_API_BASE = "https://meter-events.stripe.com"; - public static final String VERSION = "31.4.1"; + public static final String VERSION = "32.0.0"; public static volatile String apiKey; public static volatile String clientId; From 25716131c29994ab553359cf6b1ca789f4b274c5 Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Mon, 30 Mar 2026 22:17:09 +0000 Subject: [PATCH 02/11] Update generated code for v2208 and --- CODEGEN_VERSION | 2 +- OPENAPI_VERSION | 2 +- ...RecipientCapabilityStatusUpdatedEvent.java | 2 +- ...ionStorerCapabilityStatusUpdatedEvent.java | 5 +- .../V2CoreHealthApiErrorResolvedEvent.java | 3 + .../V2CoreHealthApiLatencyResolvedEvent.java | 3 + ...lthAuthorizationRateDropResolvedEvent.java | 3 + ...AuthorizationRequestErrorsFiringEvent.java | 3 + ...thorizationRequestErrorsResolvedEvent.java | 3 + ...horizationRequestTimeoutResolvedEvent.java | 3 + ...HealthPaymentMethodErrorResolvedEvent.java | 3 + ...CoreHealthSepaDebitDelayedFiringEvent.java | 3 + ...reHealthSepaDebitDelayedResolvedEvent.java | 3 + ...eHealthTrafficVolumeDropResolvedEvent.java | 3 + ...CoreHealthWebhookLatencyResolvedEvent.java | 3 + .../V2DataReportingQueryRunCreatedEvent.java | 22 + ...rtingQueryRunCreatedEventNotification.java | 27 + .../V2DataReportingQueryRunFailedEvent.java | 22 + ...ortingQueryRunFailedEventNotification.java | 27 + ...V2DataReportingQueryRunSucceededEvent.java | 22 + ...ingQueryRunSucceededEventNotification.java | 27 + .../V2DataReportingQueryRunUpdatedEvent.java | 22 + ...rtingQueryRunUpdatedEventNotification.java | 27 + .../events/V2IamApiKeyCreatedEvent.java | 18 +- ...V2IamApiKeyDefaultSecretRevealedEvent.java | 18 +- .../events/V2IamApiKeyExpiredEvent.java | 18 +- .../V2IamApiKeyPermissionsUpdatedEvent.java | 18 +- .../events/V2IamApiKeyRotatedEvent.java | 3 + .../events/V2IamApiKeyUpdatedEvent.java | 18 +- .../V2IamStripeAccessGrantApprovedEvent.java | 18 +- .../V2IamStripeAccessGrantCanceledEvent.java | 18 +- .../V2IamStripeAccessGrantDeniedEvent.java | 18 +- .../V2IamStripeAccessGrantRemovedEvent.java | 18 +- .../V2IamStripeAccessGrantRequestedEvent.java | 18 +- .../V2IamStripeAccessGrantUpdatedEvent.java | 18 +- ...2PaymentsOffSessionPaymentPausedEvent.java | 22 + ...SessionPaymentPausedEventNotification.java | 27 + ...PaymentsOffSessionPaymentResumedEvent.java | 22 + ...essionPaymentResumedEventNotification.java | 27 + src/main/java/com/stripe/model/Coupon.java | 13 + .../stripe/model/EventDataClassLookup.java | 2 + .../QuotePreviewSubscriptionSchedule.java | 30 - .../java/com/stripe/model/Subscription.java | 30 - .../stripe/model/SubscriptionSchedule.java | 30 - .../delegatedcheckout/RequestedSession.java | 28 +- .../model/sharedpayment/GrantedToken.java | 134 ++++ .../model/sharedpayment/IssuedToken.java | 319 +++++++++ .../stripe/model/v2/EventDataClassLookup.java | 21 + .../v2/EventNotificationClassLookup.java | 18 + .../com/stripe/model/v2/core/Account.java | 144 +++- .../com/stripe/model/v2/core/BatchJob.java | 84 +-- .../model/v2/data/reporting/QueryRun.java | 170 +++++ .../v2/moneymanagement/OutboundPayment.java | 12 +- .../model/v2/payments/OffSessionPayment.java | 15 +- .../stripe/model/v2/reporting/ReportRun.java | 14 +- .../com/stripe/param/ChargeCaptureParams.java | 190 +++++ .../com/stripe/param/ChargeUpdateParams.java | 190 +++++ .../param/PaymentIntentCaptureParams.java | 191 +++++ .../param/PaymentIntentConfirmParams.java | 667 ++++++++++++++++++ .../param/PaymentIntentCreateParams.java | 666 +++++++++++++++++ .../param/PaymentIntentUpdateParams.java | 666 +++++++++++++++++ .../RequestedSessionConfirmParams.java | 523 -------------- .../RequestedSessionCreateParams.java | 523 -------------- .../RequestedSessionUpdateParams.java | 601 ---------------- .../param/v2/core/AccountCreateParams.java | 201 +++++- .../param/v2/core/AccountUpdateParams.java | 201 +++++- .../param/v2/core/BatchJobCreateParams.java | 2 +- .../data/reporting/QueryRunCreateParams.java | 167 +++++ .../v2/reporting/ReportRunCreateParams.java | 8 +- .../java/com/stripe/service/V2Services.java | 4 + .../com/stripe/service/v2/DatumService.java | 15 + .../service/v2/data/ReportingService.java | 15 + .../v2/data/reporting/QueryRunService.java | 60 ++ .../v2/payments/OffSessionPaymentService.java | 24 + .../stripe/functional/GeneratedExamples.java | 105 ++- 75 files changed, 4776 insertions(+), 1846 deletions(-) create mode 100644 src/main/java/com/stripe/events/V2DataReportingQueryRunCreatedEvent.java create mode 100644 src/main/java/com/stripe/events/V2DataReportingQueryRunCreatedEventNotification.java create mode 100644 src/main/java/com/stripe/events/V2DataReportingQueryRunFailedEvent.java create mode 100644 src/main/java/com/stripe/events/V2DataReportingQueryRunFailedEventNotification.java create mode 100644 src/main/java/com/stripe/events/V2DataReportingQueryRunSucceededEvent.java create mode 100644 src/main/java/com/stripe/events/V2DataReportingQueryRunSucceededEventNotification.java create mode 100644 src/main/java/com/stripe/events/V2DataReportingQueryRunUpdatedEvent.java create mode 100644 src/main/java/com/stripe/events/V2DataReportingQueryRunUpdatedEventNotification.java create mode 100644 src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentPausedEvent.java create mode 100644 src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentPausedEventNotification.java create mode 100644 src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentResumedEvent.java create mode 100644 src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentResumedEventNotification.java create mode 100644 src/main/java/com/stripe/model/sharedpayment/IssuedToken.java create mode 100644 src/main/java/com/stripe/model/v2/data/reporting/QueryRun.java create mode 100644 src/main/java/com/stripe/param/v2/data/reporting/QueryRunCreateParams.java create mode 100644 src/main/java/com/stripe/service/v2/DatumService.java create mode 100644 src/main/java/com/stripe/service/v2/data/ReportingService.java create mode 100644 src/main/java/com/stripe/service/v2/data/reporting/QueryRunService.java diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index 31a051624c7..dc6102b6b2f 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -50a0fd5b547588149f12172b5fae94ff530d1870 \ No newline at end of file +fdfc6818cc42c9db80a55ff8ecf63542f7e97014 \ No newline at end of file diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 1808fc9412e..4385b2e9e81 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2207 \ No newline at end of file +v2208 \ No newline at end of file diff --git a/src/main/java/com/stripe/events/V2CoreAccountIncludingConfigurationRecipientCapabilityStatusUpdatedEvent.java b/src/main/java/com/stripe/events/V2CoreAccountIncludingConfigurationRecipientCapabilityStatusUpdatedEvent.java index 63914bc8350..7e5f8c6ff59 100644 --- a/src/main/java/com/stripe/events/V2CoreAccountIncludingConfigurationRecipientCapabilityStatusUpdatedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreAccountIncludingConfigurationRecipientCapabilityStatusUpdatedEvent.java @@ -23,7 +23,7 @@ public static final class EventData { * Open Enum. The capability which had its status updated. * *

One of {@code bank_accounts.instant}, {@code bank_accounts.local}, {@code - * bank_accounts.wire}, {@code cards}, {@code crypto_wallets_v2}, {@code + * bank_accounts.wire}, {@code cards}, {@code crypto_wallets_v2}, {@code paper_checks}, {@code * stripe_balance.payouts}, {@code stripe_balance.stripe_transfers}, or {@code * stripe.transfers}. */ diff --git a/src/main/java/com/stripe/events/V2CoreAccountIncludingConfigurationStorerCapabilityStatusUpdatedEvent.java b/src/main/java/com/stripe/events/V2CoreAccountIncludingConfigurationStorerCapabilityStatusUpdatedEvent.java index 416f86bcd4d..6d6e94af6f7 100644 --- a/src/main/java/com/stripe/events/V2CoreAccountIncludingConfigurationStorerCapabilityStatusUpdatedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreAccountIncludingConfigurationStorerCapabilityStatusUpdatedEvent.java @@ -27,8 +27,9 @@ public static final class EventData { * holds_currencies.gbp}, {@code holds_currencies.usd}, {@code holds_currencies.usdc}, {@code * inbound_transfers.bank_accounts}, {@code outbound_payments.bank_accounts}, {@code * outbound_payments.cards}, {@code outbound_payments.crypto_wallets}, {@code - * outbound_payments.financial_accounts}, {@code outbound_transfers.bank_accounts}, {@code - * outbound_transfers.crypto_wallets}, or {@code outbound_transfers.financial_accounts}. + * outbound_payments.financial_accounts}, {@code outbound_payments.paper_checks}, {@code + * outbound_transfers.bank_accounts}, {@code outbound_transfers.crypto_wallets}, or {@code + * outbound_transfers.financial_accounts}. */ @SerializedName("updated_capability") String updatedCapability; diff --git a/src/main/java/com/stripe/events/V2CoreHealthApiErrorResolvedEvent.java b/src/main/java/com/stripe/events/V2CoreHealthApiErrorResolvedEvent.java index a8e99ea0933..f08367de76f 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthApiErrorResolvedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthApiErrorResolvedEvent.java @@ -18,6 +18,9 @@ public final class V2CoreHealthApiErrorResolvedEvent extends Event { @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2CoreHealthApiLatencyResolvedEvent.java b/src/main/java/com/stripe/events/V2CoreHealthApiLatencyResolvedEvent.java index 154ab9a5904..4df7f9dd45f 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthApiLatencyResolvedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthApiLatencyResolvedEvent.java @@ -18,6 +18,9 @@ public final class V2CoreHealthApiLatencyResolvedEvent extends Event { @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2CoreHealthAuthorizationRateDropResolvedEvent.java b/src/main/java/com/stripe/events/V2CoreHealthAuthorizationRateDropResolvedEvent.java index b3ae9e68e8a..1cb21f4728a 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthAuthorizationRateDropResolvedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthAuthorizationRateDropResolvedEvent.java @@ -18,6 +18,9 @@ public final class V2CoreHealthAuthorizationRateDropResolvedEvent extends Event @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestErrorsFiringEvent.java b/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestErrorsFiringEvent.java index 3bc15bf47d6..3d03e0d8ecb 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestErrorsFiringEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestErrorsFiringEvent.java @@ -17,6 +17,9 @@ public final class V2CoreHealthIssuingAuthorizationRequestErrorsFiringEvent exte @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestErrorsResolvedEvent.java b/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestErrorsResolvedEvent.java index fce01ca74c9..b53b0866a8b 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestErrorsResolvedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestErrorsResolvedEvent.java @@ -17,6 +17,9 @@ public final class V2CoreHealthIssuingAuthorizationRequestErrorsResolvedEvent ex @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestTimeoutResolvedEvent.java b/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestTimeoutResolvedEvent.java index f374cedcf01..552d93cd629 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestTimeoutResolvedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthIssuingAuthorizationRequestTimeoutResolvedEvent.java @@ -17,6 +17,9 @@ public final class V2CoreHealthIssuingAuthorizationRequestTimeoutResolvedEvent e @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2CoreHealthPaymentMethodErrorResolvedEvent.java b/src/main/java/com/stripe/events/V2CoreHealthPaymentMethodErrorResolvedEvent.java index b040970e8d5..460d483e6f9 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthPaymentMethodErrorResolvedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthPaymentMethodErrorResolvedEvent.java @@ -18,6 +18,9 @@ public final class V2CoreHealthPaymentMethodErrorResolvedEvent extends Event { @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2CoreHealthSepaDebitDelayedFiringEvent.java b/src/main/java/com/stripe/events/V2CoreHealthSepaDebitDelayedFiringEvent.java index f8ad9009a65..82f8f090b8c 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthSepaDebitDelayedFiringEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthSepaDebitDelayedFiringEvent.java @@ -17,6 +17,9 @@ public final class V2CoreHealthSepaDebitDelayedFiringEvent extends Event { @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2CoreHealthSepaDebitDelayedResolvedEvent.java b/src/main/java/com/stripe/events/V2CoreHealthSepaDebitDelayedResolvedEvent.java index 56a57140d75..50fac295b8c 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthSepaDebitDelayedResolvedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthSepaDebitDelayedResolvedEvent.java @@ -17,6 +17,9 @@ public final class V2CoreHealthSepaDebitDelayedResolvedEvent extends Event { @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2CoreHealthTrafficVolumeDropResolvedEvent.java b/src/main/java/com/stripe/events/V2CoreHealthTrafficVolumeDropResolvedEvent.java index 1859a3a4d02..c53386d3ccc 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthTrafficVolumeDropResolvedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthTrafficVolumeDropResolvedEvent.java @@ -16,6 +16,9 @@ public final class V2CoreHealthTrafficVolumeDropResolvedEvent extends Event { @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2CoreHealthWebhookLatencyResolvedEvent.java b/src/main/java/com/stripe/events/V2CoreHealthWebhookLatencyResolvedEvent.java index 6139a471bd8..22b4dcb66a0 100644 --- a/src/main/java/com/stripe/events/V2CoreHealthWebhookLatencyResolvedEvent.java +++ b/src/main/java/com/stripe/events/V2CoreHealthWebhookLatencyResolvedEvent.java @@ -16,6 +16,9 @@ public final class V2CoreHealthWebhookLatencyResolvedEvent extends Event { @Getter @Setter public static final class EventData { + /** The alert ID. */ + @SerializedName("alert_id") + String alertId; /** The grouping key for the alert. */ @SerializedName("grouping_key") String groupingKey; diff --git a/src/main/java/com/stripe/events/V2DataReportingQueryRunCreatedEvent.java b/src/main/java/com/stripe/events/V2DataReportingQueryRunCreatedEvent.java new file mode 100644 index 00000000000..fc47f1897da --- /dev/null +++ b/src/main/java/com/stripe/events/V2DataReportingQueryRunCreatedEvent.java @@ -0,0 +1,22 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.data.reporting.QueryRun; +import lombok.Getter; + +@Getter +public final class V2DataReportingQueryRunCreatedEvent extends Event { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public QueryRun fetchRelatedObject() throws StripeException { + return (QueryRun) super.fetchRelatedObject(this.relatedObject); + } +} diff --git a/src/main/java/com/stripe/events/V2DataReportingQueryRunCreatedEventNotification.java b/src/main/java/com/stripe/events/V2DataReportingQueryRunCreatedEventNotification.java new file mode 100644 index 00000000000..7b5085e303c --- /dev/null +++ b/src/main/java/com/stripe/events/V2DataReportingQueryRunCreatedEventNotification.java @@ -0,0 +1,27 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.core.EventNotification; +import com.stripe.model.v2.data.reporting.QueryRun; +import lombok.Getter; + +@Getter +public final class V2DataReportingQueryRunCreatedEventNotification extends EventNotification { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public QueryRun fetchRelatedObject() throws StripeException { + return (QueryRun) super.fetchRelatedObject(this.relatedObject); + } + /** Retrieve the corresponding full event from the Stripe API. */ + @Override + public V2DataReportingQueryRunCreatedEvent fetchEvent() throws StripeException { + return (V2DataReportingQueryRunCreatedEvent) super.fetchEvent(); + } +} diff --git a/src/main/java/com/stripe/events/V2DataReportingQueryRunFailedEvent.java b/src/main/java/com/stripe/events/V2DataReportingQueryRunFailedEvent.java new file mode 100644 index 00000000000..734c0e28e71 --- /dev/null +++ b/src/main/java/com/stripe/events/V2DataReportingQueryRunFailedEvent.java @@ -0,0 +1,22 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.data.reporting.QueryRun; +import lombok.Getter; + +@Getter +public final class V2DataReportingQueryRunFailedEvent extends Event { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public QueryRun fetchRelatedObject() throws StripeException { + return (QueryRun) super.fetchRelatedObject(this.relatedObject); + } +} diff --git a/src/main/java/com/stripe/events/V2DataReportingQueryRunFailedEventNotification.java b/src/main/java/com/stripe/events/V2DataReportingQueryRunFailedEventNotification.java new file mode 100644 index 00000000000..9ddb13d3e18 --- /dev/null +++ b/src/main/java/com/stripe/events/V2DataReportingQueryRunFailedEventNotification.java @@ -0,0 +1,27 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.core.EventNotification; +import com.stripe.model.v2.data.reporting.QueryRun; +import lombok.Getter; + +@Getter +public final class V2DataReportingQueryRunFailedEventNotification extends EventNotification { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public QueryRun fetchRelatedObject() throws StripeException { + return (QueryRun) super.fetchRelatedObject(this.relatedObject); + } + /** Retrieve the corresponding full event from the Stripe API. */ + @Override + public V2DataReportingQueryRunFailedEvent fetchEvent() throws StripeException { + return (V2DataReportingQueryRunFailedEvent) super.fetchEvent(); + } +} diff --git a/src/main/java/com/stripe/events/V2DataReportingQueryRunSucceededEvent.java b/src/main/java/com/stripe/events/V2DataReportingQueryRunSucceededEvent.java new file mode 100644 index 00000000000..c475f3b010d --- /dev/null +++ b/src/main/java/com/stripe/events/V2DataReportingQueryRunSucceededEvent.java @@ -0,0 +1,22 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.data.reporting.QueryRun; +import lombok.Getter; + +@Getter +public final class V2DataReportingQueryRunSucceededEvent extends Event { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public QueryRun fetchRelatedObject() throws StripeException { + return (QueryRun) super.fetchRelatedObject(this.relatedObject); + } +} diff --git a/src/main/java/com/stripe/events/V2DataReportingQueryRunSucceededEventNotification.java b/src/main/java/com/stripe/events/V2DataReportingQueryRunSucceededEventNotification.java new file mode 100644 index 00000000000..881348c6df3 --- /dev/null +++ b/src/main/java/com/stripe/events/V2DataReportingQueryRunSucceededEventNotification.java @@ -0,0 +1,27 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.core.EventNotification; +import com.stripe.model.v2.data.reporting.QueryRun; +import lombok.Getter; + +@Getter +public final class V2DataReportingQueryRunSucceededEventNotification extends EventNotification { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public QueryRun fetchRelatedObject() throws StripeException { + return (QueryRun) super.fetchRelatedObject(this.relatedObject); + } + /** Retrieve the corresponding full event from the Stripe API. */ + @Override + public V2DataReportingQueryRunSucceededEvent fetchEvent() throws StripeException { + return (V2DataReportingQueryRunSucceededEvent) super.fetchEvent(); + } +} diff --git a/src/main/java/com/stripe/events/V2DataReportingQueryRunUpdatedEvent.java b/src/main/java/com/stripe/events/V2DataReportingQueryRunUpdatedEvent.java new file mode 100644 index 00000000000..2ba22efb6ef --- /dev/null +++ b/src/main/java/com/stripe/events/V2DataReportingQueryRunUpdatedEvent.java @@ -0,0 +1,22 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.data.reporting.QueryRun; +import lombok.Getter; + +@Getter +public final class V2DataReportingQueryRunUpdatedEvent extends Event { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public QueryRun fetchRelatedObject() throws StripeException { + return (QueryRun) super.fetchRelatedObject(this.relatedObject); + } +} diff --git a/src/main/java/com/stripe/events/V2DataReportingQueryRunUpdatedEventNotification.java b/src/main/java/com/stripe/events/V2DataReportingQueryRunUpdatedEventNotification.java new file mode 100644 index 00000000000..fba2b6cb655 --- /dev/null +++ b/src/main/java/com/stripe/events/V2DataReportingQueryRunUpdatedEventNotification.java @@ -0,0 +1,27 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.core.EventNotification; +import com.stripe.model.v2.data.reporting.QueryRun; +import lombok.Getter; + +@Getter +public final class V2DataReportingQueryRunUpdatedEventNotification extends EventNotification { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public QueryRun fetchRelatedObject() throws StripeException { + return (QueryRun) super.fetchRelatedObject(this.relatedObject); + } + /** Retrieve the corresponding full event from the Stripe API. */ + @Override + public V2DataReportingQueryRunUpdatedEvent fetchEvent() throws StripeException { + return (V2DataReportingQueryRunUpdatedEvent) super.fetchEvent(); + } +} diff --git a/src/main/java/com/stripe/events/V2IamApiKeyCreatedEvent.java b/src/main/java/com/stripe/events/V2IamApiKeyCreatedEvent.java index 5cf9db5390d..0c09e7cbb8b 100644 --- a/src/main/java/com/stripe/events/V2IamApiKeyCreatedEvent.java +++ b/src/main/java/com/stripe/events/V2IamApiKeyCreatedEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamApiKeyCreatedEvent extends Event {} +@Getter +public final class V2IamApiKeyCreatedEvent extends Event { + /** Data for the v2.iam.api_key.created event. */ + @SerializedName("data") + V2IamApiKeyCreatedEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of the created key. */ + @SerializedName("api_key") + String apiKey; + } +} diff --git a/src/main/java/com/stripe/events/V2IamApiKeyDefaultSecretRevealedEvent.java b/src/main/java/com/stripe/events/V2IamApiKeyDefaultSecretRevealedEvent.java index e684a9e517b..ab34c8649f7 100644 --- a/src/main/java/com/stripe/events/V2IamApiKeyDefaultSecretRevealedEvent.java +++ b/src/main/java/com/stripe/events/V2IamApiKeyDefaultSecretRevealedEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamApiKeyDefaultSecretRevealedEvent extends Event {} +@Getter +public final class V2IamApiKeyDefaultSecretRevealedEvent extends Event { + /** Data for the v2.iam.api_key.default_secret_revealed event. */ + @SerializedName("data") + V2IamApiKeyDefaultSecretRevealedEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of the default key whose secret was revealed. */ + @SerializedName("api_key") + String apiKey; + } +} diff --git a/src/main/java/com/stripe/events/V2IamApiKeyExpiredEvent.java b/src/main/java/com/stripe/events/V2IamApiKeyExpiredEvent.java index e07fb53cb6b..29ae6acc115 100644 --- a/src/main/java/com/stripe/events/V2IamApiKeyExpiredEvent.java +++ b/src/main/java/com/stripe/events/V2IamApiKeyExpiredEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamApiKeyExpiredEvent extends Event {} +@Getter +public final class V2IamApiKeyExpiredEvent extends Event { + /** Data for the v2.iam.api_key.expired event. */ + @SerializedName("data") + V2IamApiKeyExpiredEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of the expired key. */ + @SerializedName("api_key") + String apiKey; + } +} diff --git a/src/main/java/com/stripe/events/V2IamApiKeyPermissionsUpdatedEvent.java b/src/main/java/com/stripe/events/V2IamApiKeyPermissionsUpdatedEvent.java index 894ae8f5663..c621dd6c387 100644 --- a/src/main/java/com/stripe/events/V2IamApiKeyPermissionsUpdatedEvent.java +++ b/src/main/java/com/stripe/events/V2IamApiKeyPermissionsUpdatedEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamApiKeyPermissionsUpdatedEvent extends Event {} +@Getter +public final class V2IamApiKeyPermissionsUpdatedEvent extends Event { + /** Data for the v2.iam.api_key.permissions_updated event. */ + @SerializedName("data") + V2IamApiKeyPermissionsUpdatedEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of the key whose permissions were updated. */ + @SerializedName("api_key") + String apiKey; + } +} diff --git a/src/main/java/com/stripe/events/V2IamApiKeyRotatedEvent.java b/src/main/java/com/stripe/events/V2IamApiKeyRotatedEvent.java index 636d37e2e71..a9336d471a8 100644 --- a/src/main/java/com/stripe/events/V2IamApiKeyRotatedEvent.java +++ b/src/main/java/com/stripe/events/V2IamApiKeyRotatedEvent.java @@ -15,6 +15,9 @@ public final class V2IamApiKeyRotatedEvent extends Event { @Getter @Setter public static final class EventData { + /** ID of the old key that was rotated. */ + @SerializedName("api_key") + String apiKey; /** ID of the new key that was created due to rotation. */ @SerializedName("new_api_key") String newApiKey; diff --git a/src/main/java/com/stripe/events/V2IamApiKeyUpdatedEvent.java b/src/main/java/com/stripe/events/V2IamApiKeyUpdatedEvent.java index 7a03e94e954..8bd3a678cc5 100644 --- a/src/main/java/com/stripe/events/V2IamApiKeyUpdatedEvent.java +++ b/src/main/java/com/stripe/events/V2IamApiKeyUpdatedEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamApiKeyUpdatedEvent extends Event {} +@Getter +public final class V2IamApiKeyUpdatedEvent extends Event { + /** Data for the v2.iam.api_key.updated event. */ + @SerializedName("data") + V2IamApiKeyUpdatedEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of the updated key. */ + @SerializedName("api_key") + String apiKey; + } +} diff --git a/src/main/java/com/stripe/events/V2IamStripeAccessGrantApprovedEvent.java b/src/main/java/com/stripe/events/V2IamStripeAccessGrantApprovedEvent.java index fc37c220809..917bc642c62 100644 --- a/src/main/java/com/stripe/events/V2IamStripeAccessGrantApprovedEvent.java +++ b/src/main/java/com/stripe/events/V2IamStripeAccessGrantApprovedEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamStripeAccessGrantApprovedEvent extends Event {} +@Getter +public final class V2IamStripeAccessGrantApprovedEvent extends Event { + /** Data for the v2.iam.stripe_access_grant.approved event. */ + @SerializedName("data") + V2IamStripeAccessGrantApprovedEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of approved Stripe Access Grant. */ + @SerializedName("stripe_access_grant") + String stripeAccessGrant; + } +} diff --git a/src/main/java/com/stripe/events/V2IamStripeAccessGrantCanceledEvent.java b/src/main/java/com/stripe/events/V2IamStripeAccessGrantCanceledEvent.java index 58606f9565b..7fedccd76d2 100644 --- a/src/main/java/com/stripe/events/V2IamStripeAccessGrantCanceledEvent.java +++ b/src/main/java/com/stripe/events/V2IamStripeAccessGrantCanceledEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamStripeAccessGrantCanceledEvent extends Event {} +@Getter +public final class V2IamStripeAccessGrantCanceledEvent extends Event { + /** Data for the v2.iam.stripe_access_grant.canceled event. */ + @SerializedName("data") + V2IamStripeAccessGrantCanceledEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of canceled Stripe Access Grant. */ + @SerializedName("stripe_access_grant") + String stripeAccessGrant; + } +} diff --git a/src/main/java/com/stripe/events/V2IamStripeAccessGrantDeniedEvent.java b/src/main/java/com/stripe/events/V2IamStripeAccessGrantDeniedEvent.java index 26893af90c9..b4e983af6b0 100644 --- a/src/main/java/com/stripe/events/V2IamStripeAccessGrantDeniedEvent.java +++ b/src/main/java/com/stripe/events/V2IamStripeAccessGrantDeniedEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamStripeAccessGrantDeniedEvent extends Event {} +@Getter +public final class V2IamStripeAccessGrantDeniedEvent extends Event { + /** Data for the v2.iam.stripe_access_grant.denied event. */ + @SerializedName("data") + V2IamStripeAccessGrantDeniedEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of denied Stripe Access Grant. */ + @SerializedName("stripe_access_grant") + String stripeAccessGrant; + } +} diff --git a/src/main/java/com/stripe/events/V2IamStripeAccessGrantRemovedEvent.java b/src/main/java/com/stripe/events/V2IamStripeAccessGrantRemovedEvent.java index c5ee8cafd2a..0514ffc0b1d 100644 --- a/src/main/java/com/stripe/events/V2IamStripeAccessGrantRemovedEvent.java +++ b/src/main/java/com/stripe/events/V2IamStripeAccessGrantRemovedEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamStripeAccessGrantRemovedEvent extends Event {} +@Getter +public final class V2IamStripeAccessGrantRemovedEvent extends Event { + /** Data for the v2.iam.stripe_access_grant.removed event. */ + @SerializedName("data") + V2IamStripeAccessGrantRemovedEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of removed Stripe Access Grant. */ + @SerializedName("stripe_access_grant") + String stripeAccessGrant; + } +} diff --git a/src/main/java/com/stripe/events/V2IamStripeAccessGrantRequestedEvent.java b/src/main/java/com/stripe/events/V2IamStripeAccessGrantRequestedEvent.java index 2670970dbd3..86b6aaf2498 100644 --- a/src/main/java/com/stripe/events/V2IamStripeAccessGrantRequestedEvent.java +++ b/src/main/java/com/stripe/events/V2IamStripeAccessGrantRequestedEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamStripeAccessGrantRequestedEvent extends Event {} +@Getter +public final class V2IamStripeAccessGrantRequestedEvent extends Event { + /** Data for the v2.iam.stripe_access_grant.requested event. */ + @SerializedName("data") + V2IamStripeAccessGrantRequestedEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of requested Stripe Access Grant. */ + @SerializedName("stripe_access_grant") + String stripeAccessGrant; + } +} diff --git a/src/main/java/com/stripe/events/V2IamStripeAccessGrantUpdatedEvent.java b/src/main/java/com/stripe/events/V2IamStripeAccessGrantUpdatedEvent.java index 0b5ac5d9c3e..12bcc9b90a5 100644 --- a/src/main/java/com/stripe/events/V2IamStripeAccessGrantUpdatedEvent.java +++ b/src/main/java/com/stripe/events/V2IamStripeAccessGrantUpdatedEvent.java @@ -1,6 +1,22 @@ // File generated from our OpenAPI spec package com.stripe.events; +import com.google.gson.annotations.SerializedName; import com.stripe.model.v2.core.Event; +import lombok.Getter; +import lombok.Setter; -public final class V2IamStripeAccessGrantUpdatedEvent extends Event {} +@Getter +public final class V2IamStripeAccessGrantUpdatedEvent extends Event { + /** Data for the v2.iam.stripe_access_grant.updated event. */ + @SerializedName("data") + V2IamStripeAccessGrantUpdatedEvent.EventData data; + + @Getter + @Setter + public static final class EventData { + /** ID of updated Stripe Access Grant. */ + @SerializedName("stripe_access_grant") + String stripeAccessGrant; + } +} diff --git a/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentPausedEvent.java b/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentPausedEvent.java new file mode 100644 index 00000000000..dca3eddfd87 --- /dev/null +++ b/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentPausedEvent.java @@ -0,0 +1,22 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.payments.OffSessionPayment; +import lombok.Getter; + +@Getter +public final class V2PaymentsOffSessionPaymentPausedEvent extends Event { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public OffSessionPayment fetchRelatedObject() throws StripeException { + return (OffSessionPayment) super.fetchRelatedObject(this.relatedObject); + } +} diff --git a/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentPausedEventNotification.java b/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentPausedEventNotification.java new file mode 100644 index 00000000000..53bfba83af9 --- /dev/null +++ b/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentPausedEventNotification.java @@ -0,0 +1,27 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.core.EventNotification; +import com.stripe.model.v2.payments.OffSessionPayment; +import lombok.Getter; + +@Getter +public final class V2PaymentsOffSessionPaymentPausedEventNotification extends EventNotification { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public OffSessionPayment fetchRelatedObject() throws StripeException { + return (OffSessionPayment) super.fetchRelatedObject(this.relatedObject); + } + /** Retrieve the corresponding full event from the Stripe API. */ + @Override + public V2PaymentsOffSessionPaymentPausedEvent fetchEvent() throws StripeException { + return (V2PaymentsOffSessionPaymentPausedEvent) super.fetchEvent(); + } +} diff --git a/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentResumedEvent.java b/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentResumedEvent.java new file mode 100644 index 00000000000..b6b95967b9a --- /dev/null +++ b/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentResumedEvent.java @@ -0,0 +1,22 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.payments.OffSessionPayment; +import lombok.Getter; + +@Getter +public final class V2PaymentsOffSessionPaymentResumedEvent extends Event { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public OffSessionPayment fetchRelatedObject() throws StripeException { + return (OffSessionPayment) super.fetchRelatedObject(this.relatedObject); + } +} diff --git a/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentResumedEventNotification.java b/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentResumedEventNotification.java new file mode 100644 index 00000000000..a7e87929ffb --- /dev/null +++ b/src/main/java/com/stripe/events/V2PaymentsOffSessionPaymentResumedEventNotification.java @@ -0,0 +1,27 @@ +// File generated from our OpenAPI spec +package com.stripe.events; + +import com.google.gson.annotations.SerializedName; +import com.stripe.exception.StripeException; +import com.stripe.model.v2.core.Event.RelatedObject; +import com.stripe.model.v2.core.EventNotification; +import com.stripe.model.v2.payments.OffSessionPayment; +import lombok.Getter; + +@Getter +public final class V2PaymentsOffSessionPaymentResumedEventNotification extends EventNotification { + @SerializedName("related_object") + + /** Object containing the reference to API resource relevant to the event. */ + RelatedObject relatedObject; + + /** Retrieves the related object from the API. Make an API request on every call. */ + public OffSessionPayment fetchRelatedObject() throws StripeException { + return (OffSessionPayment) super.fetchRelatedObject(this.relatedObject); + } + /** Retrieve the corresponding full event from the Stripe API. */ + @Override + public V2PaymentsOffSessionPaymentResumedEvent fetchEvent() throws StripeException { + return (V2PaymentsOffSessionPaymentResumedEvent) super.fetchEvent(); + } +} diff --git a/src/main/java/com/stripe/model/Coupon.java b/src/main/java/com/stripe/model/Coupon.java index 026f479f4b9..97ff2cf2542 100644 --- a/src/main/java/com/stripe/model/Coupon.java +++ b/src/main/java/com/stripe/model/Coupon.java @@ -455,9 +455,13 @@ public static class Script extends StripeObject implements HasId { @Setter @EqualsAndHashCode(callSuper = false) public static class ServicePeriod extends StripeObject { + /** + * Specifies coupon frequency. Either {@code day}, {@code week}, {@code month} or {@code year}. + */ @SerializedName("interval") String interval; + /** The number of intervals for which the coupon will be applied. */ @SerializedName("interval_count") Long intervalCount; @@ -472,9 +476,18 @@ public static class ServicePeriod extends StripeObject { @Setter @EqualsAndHashCode(callSuper = false) public static class Iterations extends StripeObject { + /** + * The number of iterations the service period will repeat for. Only used when type is {@code + * count}. + */ @SerializedName("count") Long count; + /** + * The type of iterations. + * + *

One of {@code count}, or {@code forever}. + */ @SerializedName("type") String type; } diff --git a/src/main/java/com/stripe/model/EventDataClassLookup.java b/src/main/java/com/stripe/model/EventDataClassLookup.java index 42d937baf96..e5ba41dcdf3 100644 --- a/src/main/java/com/stripe/model/EventDataClassLookup.java +++ b/src/main/java/com/stripe/model/EventDataClassLookup.java @@ -249,6 +249,8 @@ public final class EventDataClassLookup { classLookup.put( "shared_payment.granted_token", com.stripe.model.sharedpayment.GrantedToken.class); + classLookup.put( + "shared_payment.issued_token", com.stripe.model.sharedpayment.IssuedToken.class); classLookup.put("tax.association", com.stripe.model.tax.Association.class); classLookup.put("tax.calculation", com.stripe.model.tax.Calculation.class); diff --git a/src/main/java/com/stripe/model/QuotePreviewSubscriptionSchedule.java b/src/main/java/com/stripe/model/QuotePreviewSubscriptionSchedule.java index 2552faceacf..6fd4f5c7317 100644 --- a/src/main/java/com/stripe/model/QuotePreviewSubscriptionSchedule.java +++ b/src/main/java/com/stripe/model/QuotePreviewSubscriptionSchedule.java @@ -391,10 +391,6 @@ public static class BillingSchedule extends StripeObject { @SerializedName("applies_to") List appliesTo; - /** Specifies the start of the billing period. */ - @SerializedName("bill_from") - BillFrom billFrom; - /** Specifies the end of billing period. */ @SerializedName("bill_until") BillUntil billUntil; @@ -441,32 +437,6 @@ public void setPriceObject(Price expandableObject) { } } - /** Specifies the start of the billing period. */ - @Getter - @Setter - @EqualsAndHashCode(callSuper = false) - public static class BillFrom extends StripeObject { - /** The time the billing schedule applies from. */ - @SerializedName("computed_timestamp") - Long computedTimestamp; - - /** - * Use a precise Unix timestamp for prebilling to start. Must be earlier than {@code - * bill_until}. - */ - @SerializedName("timestamp") - Long timestamp; - - /** - * Describes how the billing schedule determines the start date. Possible values are {@code - * timestamp}. - * - *

Equal to {@code timestamp}. - */ - @SerializedName("type") - String type; - } - /** Specifies the end of billing period. */ @Getter @Setter diff --git a/src/main/java/com/stripe/model/Subscription.java b/src/main/java/com/stripe/model/Subscription.java index 961475d042b..ed931f35e12 100644 --- a/src/main/java/com/stripe/model/Subscription.java +++ b/src/main/java/com/stripe/model/Subscription.java @@ -1589,10 +1589,6 @@ public static class BillingSchedule extends StripeObject { @SerializedName("applies_to") List appliesTo; - /** Specifies the start of the billing period. */ - @SerializedName("bill_from") - BillFrom billFrom; - /** Specifies the end of billing period. */ @SerializedName("bill_until") BillUntil billUntil; @@ -1639,32 +1635,6 @@ public void setPriceObject(Price expandableObject) { } } - /** Specifies the start of the billing period. */ - @Getter - @Setter - @EqualsAndHashCode(callSuper = false) - public static class BillFrom extends StripeObject { - /** The time the billing schedule applies from. */ - @SerializedName("computed_timestamp") - Long computedTimestamp; - - /** - * Use a precise Unix timestamp for prebilling to start. Must be earlier than {@code - * bill_until}. - */ - @SerializedName("timestamp") - Long timestamp; - - /** - * Describes how the billing schedule determines the start date. Possible values are {@code - * timestamp}. - * - *

Equal to {@code timestamp}. - */ - @SerializedName("type") - String type; - } - /** Specifies the end of billing period. */ @Getter @Setter diff --git a/src/main/java/com/stripe/model/SubscriptionSchedule.java b/src/main/java/com/stripe/model/SubscriptionSchedule.java index 8e04b74e31d..1ebba4d396f 100644 --- a/src/main/java/com/stripe/model/SubscriptionSchedule.java +++ b/src/main/java/com/stripe/model/SubscriptionSchedule.java @@ -706,10 +706,6 @@ public static class BillingSchedule extends StripeObject { @SerializedName("applies_to") List appliesTo; - /** Specifies the start of the billing period. */ - @SerializedName("bill_from") - BillFrom billFrom; - /** Specifies the end of billing period. */ @SerializedName("bill_until") BillUntil billUntil; @@ -756,32 +752,6 @@ public void setPriceObject(Price expandableObject) { } } - /** Specifies the start of the billing period. */ - @Getter - @Setter - @EqualsAndHashCode(callSuper = false) - public static class BillFrom extends StripeObject { - /** The time the billing schedule applies from. */ - @SerializedName("computed_timestamp") - Long computedTimestamp; - - /** - * Use a precise Unix timestamp for prebilling to start. Must be earlier than {@code - * bill_until}. - */ - @SerializedName("timestamp") - Long timestamp; - - /** - * Describes how the billing schedule determines the start date. Possible values are {@code - * timestamp}. - * - *

Equal to {@code timestamp}. - */ - @SerializedName("type") - String type; - } - /** Specifies the end of billing period. */ @Getter @Setter diff --git a/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java b/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java index 7366067e7b0..bc82cc6b674 100644 --- a/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java +++ b/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java @@ -8,6 +8,7 @@ import com.stripe.model.MetadataStore; import com.stripe.model.Profile; import com.stripe.model.StripeObject; +import com.stripe.model.sharedpayment.IssuedToken; import com.stripe.net.ApiRequest; import com.stripe.net.ApiRequestParams; import com.stripe.net.ApiResource; @@ -132,7 +133,9 @@ public class RequestedSession extends ApiResource /** The SPT used for payment. */ @SerializedName("shared_payment_issued_token") - String sharedPaymentIssuedToken; + @Getter(lombok.AccessLevel.NONE) + @Setter(lombok.AccessLevel.NONE) + ExpandableField sharedPaymentIssuedToken; /** * The status of the requested session. @@ -149,6 +152,28 @@ public class RequestedSession extends ApiResource @SerializedName("updated_at") Long updatedAt; + /** Get ID of expandable {@code sharedPaymentIssuedToken} object. */ + public String getSharedPaymentIssuedToken() { + return (this.sharedPaymentIssuedToken != null) ? this.sharedPaymentIssuedToken.getId() : null; + } + + public void setSharedPaymentIssuedToken(String id) { + this.sharedPaymentIssuedToken = + ApiResource.setExpandableFieldId(id, this.sharedPaymentIssuedToken); + } + + /** Get expanded {@code sharedPaymentIssuedToken}. */ + public IssuedToken getSharedPaymentIssuedTokenObject() { + return (this.sharedPaymentIssuedToken != null) + ? this.sharedPaymentIssuedToken.getExpanded() + : null; + } + + public void setSharedPaymentIssuedTokenObject(IssuedToken expandableObject) { + this.sharedPaymentIssuedToken = + new ExpandableField(expandableObject.getId(), expandableObject); + } + /** Confirms a requested session. */ public RequestedSession confirm() throws StripeException { return confirm((Map) null, (RequestOptions) null); @@ -1146,6 +1171,7 @@ public void setResponseGetter(StripeResponseGetter responseGetter) { trySetResponseGetter(paymentMethodPreview, responseGetter); trySetResponseGetter(riskDetails, responseGetter); trySetResponseGetter(sellerDetails, responseGetter); + trySetResponseGetter(sharedPaymentIssuedToken, responseGetter); trySetResponseGetter(totalDetails, responseGetter); } } diff --git a/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java b/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java index 752ae1ca3b4..d2d2ddc575f 100644 --- a/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java +++ b/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java @@ -14,6 +14,7 @@ import com.stripe.param.sharedpayment.GrantedTokenCreateParams; import com.stripe.param.sharedpayment.GrantedTokenRetrieveParams; import com.stripe.param.sharedpayment.GrantedTokenRevokeParams; +import java.math.BigDecimal; import java.util.Map; import lombok.EqualsAndHashCode; import lombok.Getter; @@ -29,6 +30,10 @@ @Setter @EqualsAndHashCode(callSuper = false) public class GrantedToken extends ApiResource implements HasId { + /** Details about the agent that issued this SharedPaymentGrantedToken. */ + @SerializedName("agent_details") + AgentDetails agentDetails; + /** Time at which the object was created. Measured in seconds since the Unix epoch. */ @SerializedName("created") Long created; @@ -68,6 +73,10 @@ public class GrantedToken extends ApiResource implements HasId { @SerializedName("object") String object; + /** Risk details of the SharedPaymentGrantedToken. */ + @SerializedName("risk_details") + RiskDetails riskDetails; + /** Metadata about the SharedPaymentGrantedToken. */ @SerializedName("shared_metadata") Map sharedMetadata; @@ -123,6 +132,129 @@ public static GrantedToken retrieve( return getGlobalResponseGetter().request(request, GrantedToken.class); } + /** + * For more details about AgentDetails, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class AgentDetails extends StripeObject { + /** The Stripe Profile ID of the agent that issued this SharedPaymentGrantedToken. */ + @SerializedName("network_business_profile") + String networkBusinessProfile; + } + + /** Risk details of the SharedPaymentGrantedToken. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class RiskDetails extends StripeObject { + /** + * Risk insights for this token, including scores and recommended actions for each risk type. + */ + @SerializedName("insights") + Insights insights; + + /** + * Risk insights for this token, including scores and recommended actions for each risk type. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Insights extends StripeObject { + /** Bot risk insight (score: Float, recommended_action). */ + @SerializedName("bot") + Bot bot; + + /** Card issuer decline risk insight (score: Float, recommended_action). */ + @SerializedName("card_issuer_decline") + CardIssuerDecline cardIssuerDecline; + + /** Card testing risk insight (score: Float, recommended_action). */ + @SerializedName("card_testing") + CardTesting cardTesting; + + /** Fraudulent dispute risk insight (score: Integer, recommended_action). */ + @SerializedName("fraudulent_dispute") + FraudulentDispute fraudulentDispute; + + /** Stolen card risk insight (score: Integer, recommended_action). */ + @SerializedName("stolen_card") + StolenCard stolenCard; + + /** Risk insight with a float score and recommended action. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Bot extends StripeObject { + /** Recommended action for this insight. */ + @SerializedName("recommended_action") + String recommendedAction; + + /** Risk score for this insight (float). */ + @SerializedName("score") + BigDecimal score; + } + + /** Risk insight with a float score and recommended action. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CardIssuerDecline extends StripeObject { + /** Recommended action for this insight. */ + @SerializedName("recommended_action") + String recommendedAction; + + /** Risk score for this insight (float). */ + @SerializedName("score") + BigDecimal score; + } + + /** Risk insight with a float score and recommended action. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CardTesting extends StripeObject { + /** Recommended action for this insight. */ + @SerializedName("recommended_action") + String recommendedAction; + + /** Risk score for this insight (float). */ + @SerializedName("score") + BigDecimal score; + } + + /** Risk insight with an integer score and recommended action. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class FraudulentDispute extends StripeObject { + /** Recommended action for this insight. */ + @SerializedName("recommended_action") + String recommendedAction; + + /** Risk score for this insight (integer). */ + @SerializedName("score") + Long score; + } + + /** Risk insight with an integer score and recommended action. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class StolenCard extends StripeObject { + /** Recommended action for this insight. */ + @SerializedName("recommended_action") + String recommendedAction; + + /** Risk score for this insight (integer). */ + @SerializedName("score") + Long score; + } + } + } + /** Some details on how the SharedPaymentGrantedToken has been used so far. */ @Getter @Setter @@ -313,6 +445,8 @@ public GrantedToken revoke(GrantedTokenRevokeParams params, RequestOptions optio @Override public void setResponseGetter(StripeResponseGetter responseGetter) { super.setResponseGetter(responseGetter); + trySetResponseGetter(agentDetails, responseGetter); + trySetResponseGetter(riskDetails, responseGetter); trySetResponseGetter(usageDetails, responseGetter); trySetResponseGetter(usageLimits, responseGetter); } diff --git a/src/main/java/com/stripe/model/sharedpayment/IssuedToken.java b/src/main/java/com/stripe/model/sharedpayment/IssuedToken.java new file mode 100644 index 00000000000..8d72ffbf18f --- /dev/null +++ b/src/main/java/com/stripe/model/sharedpayment/IssuedToken.java @@ -0,0 +1,319 @@ +// File generated from our OpenAPI spec +package com.stripe.model.sharedpayment; + +import com.google.gson.annotations.SerializedName; +import com.stripe.model.HasId; +import com.stripe.model.StripeObject; +import java.math.BigDecimal; +import java.util.List; +import java.util.Map; +import lombok.EqualsAndHashCode; +import lombok.Getter; +import lombok.Setter; + +/** + * A SharedPaymentIssuedToken is a limited-use reference to a PaymentMethod that can be created with + * a secret key. When shared with another Stripe account (Seller), it enables that account to either + * process a payment on Stripe against a PaymentMethod that your Stripe account owns, or to forward + * a usable credential created against the originalPaymentMethod to then process the payment + * off-Stripe. + */ +@Getter +@Setter +@EqualsAndHashCode(callSuper = false) +public class IssuedToken extends StripeObject implements HasId { + /** Time at which the object was created. Measured in seconds since the Unix epoch. */ + @SerializedName("created") + Long created; + + /** ID of an existing Customer. */ + @SerializedName("customer") + String customer; + + /** Time at which this SharedPaymentIssuedToken was deactivated. */ + @SerializedName("deactivated_at") + Long deactivatedAt; + + /** + * The reason why the SharedPaymentIssuedToken has been deactivated. + * + *

One of {@code consumed}, {@code expired}, {@code resolved}, or {@code revoked}. + */ + @SerializedName("deactivated_reason") + String deactivatedReason; + + /** Which requested uses have been enabled for this SharedPaymentIssuedToken. */ + @SerializedName("enabled_uses") + List enabledUses; + + /** Unique identifier for the object. */ + @Getter(onMethod_ = {@Override}) + @SerializedName("id") + String id; + + /** + * If the object exists in live mode, the value is {@code true}. If the object exists in test + * mode, the value is {@code false}. + */ + @SerializedName("livemode") + Boolean livemode; + + /** + * String representing the object's type. Objects of the same type share the same value. + * + *

Equal to {@code shared_payment.issued_token}. + */ + @SerializedName("object") + String object; + + /** ID of an existing PaymentMethod. */ + @SerializedName("payment_method") + String paymentMethod; + + /** + * Requested uses for this SharedPaymentIssuedToken, which controls which Stripe APIs it can be + * used with. + */ + @SerializedName("requested_uses") + List requestedUses; + + /** + * If the customer does not exit their browser while authenticating, they will be redirected to + * this specified URL after completion. + */ + @SerializedName("return_url") + String returnUrl; + + /** Risk details of the SharedPaymentIssuedToken. */ + @SerializedName("risk_details") + RiskDetails riskDetails; + + /** Seller details of the SharedPaymentIssuedToken, including network_id and external_id. */ + @SerializedName("seller_details") + SellerDetails sellerDetails; + + /** + * Indicates that you intend to save the PaymentMethod of this SharedPaymentToken to a customer + * later. + * + *

Equal to {@code on_session}. + */ + @SerializedName("setup_future_usage") + String setupFutureUsage; + + /** Metadata about the SharedPaymentIssuedToken. */ + @SerializedName("shared_metadata") + Map sharedMetadata; + + /** Usage details of the SharedPaymentIssuedToken. */ + @SerializedName("usage_details") + UsageDetails usageDetails; + + /** Usage limits of the SharedPaymentIssuedToken. */ + @SerializedName("usage_limits") + UsageLimits usageLimits; + + /** + * For more details about RiskDetails, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class RiskDetails extends StripeObject { + /** + * Risk insights for this token, including scores and recommended actions for each risk type. + */ + @SerializedName("insights") + Insights insights; + + /** + * Risk insights for this token, including scores and recommended actions for each risk type. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Insights extends StripeObject { + /** Bot risk insight (score: Float, recommended_action). */ + @SerializedName("bot") + Bot bot; + + /** Card issuer decline risk insight (score: Float, recommended_action). */ + @SerializedName("card_issuer_decline") + CardIssuerDecline cardIssuerDecline; + + /** Card testing risk insight (score: Float, recommended_action). */ + @SerializedName("card_testing") + CardTesting cardTesting; + + /** Fraudulent dispute risk insight (score: Integer, recommended_action). */ + @SerializedName("fraudulent_dispute") + FraudulentDispute fraudulentDispute; + + /** Stolen card risk insight (score: Integer, recommended_action). */ + @SerializedName("stolen_card") + StolenCard stolenCard; + + /** Risk insight with a float score and recommended action. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Bot extends StripeObject { + /** Recommended action for this insight. */ + @SerializedName("recommended_action") + String recommendedAction; + + /** Risk score for this insight (float). */ + @SerializedName("score") + BigDecimal score; + } + + /** Risk insight with a float score and recommended action. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CardIssuerDecline extends StripeObject { + /** Recommended action for this insight. */ + @SerializedName("recommended_action") + String recommendedAction; + + /** Risk score for this insight (float). */ + @SerializedName("score") + BigDecimal score; + } + + /** Risk insight with a float score and recommended action. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CardTesting extends StripeObject { + /** Recommended action for this insight. */ + @SerializedName("recommended_action") + String recommendedAction; + + /** Risk score for this insight (float). */ + @SerializedName("score") + BigDecimal score; + } + + /** Risk insight with an integer score and recommended action. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class FraudulentDispute extends StripeObject { + /** Recommended action for this insight. */ + @SerializedName("recommended_action") + String recommendedAction; + + /** Risk score for this insight (integer). */ + @SerializedName("score") + Long score; + } + + /** Risk insight with an integer score and recommended action. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class StolenCard extends StripeObject { + /** Recommended action for this insight. */ + @SerializedName("recommended_action") + String recommendedAction; + + /** Risk score for this insight (integer). */ + @SerializedName("score") + Long score; + } + } + } + + /** + * For more details about SellerDetails, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class SellerDetails extends StripeObject { + /** + * A unique id within a network that identifies a logical seller. This should usually be the + * merchant id on the seller platform. + */ + @SerializedName("external_id") + String externalId; + + /** + * The unique and logical string that identifies the seller platform that this SharedToken is + * being created for. + */ + @SerializedName("network_business_profile") + String networkBusinessProfile; + + /** + * The unique and logical string that identifies the seller platform that this SharedToken is + * being created for. + */ + @SerializedName("network_id") + String networkId; + } + + /** Some details on how the SharedPaymentGrantedToken has been used so far. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class UsageDetails extends StripeObject { + /** The total amount captured using this SharedPaymentToken. */ + @SerializedName("amount_captured") + AmountCaptured amountCaptured; + + /** A representation of an amount of money, consisting of an amount and a currency. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class AmountCaptured extends StripeObject { + /** + * Three-letter ISO currency + * code, in lowercase. Must be a supported + * currency. + */ + @SerializedName("currency") + String currency; + + /** Integer value of the amount in the smallest currency unit. */ + @SerializedName("value") + Long value; + } + } + + /** Limits on how this SharedPaymentGrantedToken can be used. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class UsageLimits extends StripeObject { + /** + * Three-letter ISO currency + * code, in lowercase. Must be a supported + * currency. + */ + @SerializedName("currency") + String currency; + + /** + * Time at which this SharedPaymentToken expires and can no longer be used to confirm a + * PaymentIntent. + */ + @SerializedName("expires_at") + Long expiresAt; + + /** Max amount that can be captured using this SharedPaymentToken. */ + @SerializedName("max_amount") + Long maxAmount; + + /** + * The recurring interval at which the shared payment token's amount usage restrictions reset. + * + *

One of {@code month}, {@code week}, or {@code year}. + */ + @SerializedName("recurring_interval") + String recurringInterval; + } +} diff --git a/src/main/java/com/stripe/model/v2/EventDataClassLookup.java b/src/main/java/com/stripe/model/v2/EventDataClassLookup.java index 619371d772f..4651ef61132 100644 --- a/src/main/java/com/stripe/model/v2/EventDataClassLookup.java +++ b/src/main/java/com/stripe/model/v2/EventDataClassLookup.java @@ -94,6 +94,9 @@ public final class EventDataClassLookup { classLookup.put( "v2.core.vault.us_bank_account", com.stripe.model.v2.core.vault.UsBankAccount.class); + classLookup.put( + "v2.data.reporting.query_run", com.stripe.model.v2.data.reporting.QueryRun.class); + classLookup.put("v2.iam.api_key", com.stripe.model.v2.iam.ApiKey.class); classLookup.put( @@ -436,6 +439,18 @@ public final class EventDataClassLookup { eventClassLookup.put( "v2.core.health.webhook_latency.resolved", com.stripe.events.V2CoreHealthWebhookLatencyResolvedEvent.class); + eventClassLookup.put( + "v2.data.reporting.query_run.created", + com.stripe.events.V2DataReportingQueryRunCreatedEvent.class); + eventClassLookup.put( + "v2.data.reporting.query_run.failed", + com.stripe.events.V2DataReportingQueryRunFailedEvent.class); + eventClassLookup.put( + "v2.data.reporting.query_run.succeeded", + com.stripe.events.V2DataReportingQueryRunSucceededEvent.class); + eventClassLookup.put( + "v2.data.reporting.query_run.updated", + com.stripe.events.V2DataReportingQueryRunUpdatedEvent.class); eventClassLookup.put("v2.iam.api_key.created", com.stripe.events.V2IamApiKeyCreatedEvent.class); eventClassLookup.put( "v2.iam.api_key.default_secret_revealed", @@ -599,9 +614,15 @@ public final class EventDataClassLookup { eventClassLookup.put( "v2.payments.off_session_payment.failed", com.stripe.events.V2PaymentsOffSessionPaymentFailedEvent.class); + eventClassLookup.put( + "v2.payments.off_session_payment.paused", + com.stripe.events.V2PaymentsOffSessionPaymentPausedEvent.class); eventClassLookup.put( "v2.payments.off_session_payment.requires_capture", com.stripe.events.V2PaymentsOffSessionPaymentRequiresCaptureEvent.class); + eventClassLookup.put( + "v2.payments.off_session_payment.resumed", + com.stripe.events.V2PaymentsOffSessionPaymentResumedEvent.class); eventClassLookup.put( "v2.payments.off_session_payment.succeeded", com.stripe.events.V2PaymentsOffSessionPaymentSucceededEvent.class); diff --git a/src/main/java/com/stripe/model/v2/EventNotificationClassLookup.java b/src/main/java/com/stripe/model/v2/EventNotificationClassLookup.java index 0cbbd818354..4c1ef6ea777 100644 --- a/src/main/java/com/stripe/model/v2/EventNotificationClassLookup.java +++ b/src/main/java/com/stripe/model/v2/EventNotificationClassLookup.java @@ -334,6 +334,18 @@ public final class EventNotificationClassLookup { eventClassLookup.put( "v2.core.health.webhook_latency.resolved", com.stripe.events.V2CoreHealthWebhookLatencyResolvedEventNotification.class); + eventClassLookup.put( + "v2.data.reporting.query_run.created", + com.stripe.events.V2DataReportingQueryRunCreatedEventNotification.class); + eventClassLookup.put( + "v2.data.reporting.query_run.failed", + com.stripe.events.V2DataReportingQueryRunFailedEventNotification.class); + eventClassLookup.put( + "v2.data.reporting.query_run.succeeded", + com.stripe.events.V2DataReportingQueryRunSucceededEventNotification.class); + eventClassLookup.put( + "v2.data.reporting.query_run.updated", + com.stripe.events.V2DataReportingQueryRunUpdatedEventNotification.class); eventClassLookup.put( "v2.iam.api_key.created", com.stripe.events.V2IamApiKeyCreatedEventNotification.class); eventClassLookup.put( @@ -505,9 +517,15 @@ public final class EventNotificationClassLookup { eventClassLookup.put( "v2.payments.off_session_payment.failed", com.stripe.events.V2PaymentsOffSessionPaymentFailedEventNotification.class); + eventClassLookup.put( + "v2.payments.off_session_payment.paused", + com.stripe.events.V2PaymentsOffSessionPaymentPausedEventNotification.class); eventClassLookup.put( "v2.payments.off_session_payment.requires_capture", com.stripe.events.V2PaymentsOffSessionPaymentRequiresCaptureEventNotification.class); + eventClassLookup.put( + "v2.payments.off_session_payment.resumed", + com.stripe.events.V2PaymentsOffSessionPaymentResumedEventNotification.class); eventClassLookup.put( "v2.payments.off_session_payment.succeeded", com.stripe.events.V2PaymentsOffSessionPaymentSucceededEventNotification.class); diff --git a/src/main/java/com/stripe/model/v2/core/Account.java b/src/main/java/com/stripe/model/v2/core/Account.java index e5a1256f95c..22e69eed313 100644 --- a/src/main/java/com/stripe/model/v2/core/Account.java +++ b/src/main/java/com/stripe/model/v2/core/Account.java @@ -4253,6 +4253,10 @@ public static class Capabilities extends StripeObject { @SerializedName("crypto_wallets") CryptoWallets cryptoWallets; + /** Capabilities that enable OutboundPayments via paper check. */ + @SerializedName("paper_checks") + PaperChecks paperChecks; + /** Capabilities that enable the recipient to manage their Stripe Balance (/v1/balance). */ @SerializedName("stripe_balance") StripeBalance stripeBalance; @@ -4545,6 +4549,56 @@ public static class StatusDetail extends StripeObject { } } + /** Capabilities that enable OutboundPayments via paper check. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class PaperChecks extends StripeObject { + /** + * The status of the Capability. + * + *

One of {@code active}, {@code pending}, {@code restricted}, or {@code unsupported}. + */ + @SerializedName("status") + String status; + + /** + * Additional details about the capability's status. This value is empty when {@code + * status} is {@code active}. + */ + @SerializedName("status_details") + List statusDetails; + + /** + * For more details about StatusDetail, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class StatusDetail extends StripeObject { + /** + * Machine-readable code explaining the reason for the Capability to be in its current + * status. + * + *

One of {@code determining_status}, {@code requirements_past_due}, {@code + * requirements_pending_verification}, {@code restricted_other}, {@code + * unsupported_business}, {@code unsupported_country}, or {@code + * unsupported_entity_type}. + */ + @SerializedName("code") + String code; + + /** + * Machine-readable code explaining how to make the Capability active. + * + *

One of {@code contact_stripe}, {@code no_resolution}, or {@code provide_info}. + */ + @SerializedName("resolution") + String resolution; + } + } + /** Capabilities that enable the recipient to manage their Stripe Balance (/v1/balance). */ @Getter @Setter @@ -5367,6 +5421,10 @@ public static class OutboundPayments extends StripeObject { @SerializedName("financial_accounts") FinancialAccounts financialAccounts; + /** Can send funds from a FinancialAccount to someone else via paper check. */ + @SerializedName("paper_checks") + PaperChecks paperChecks; + /** * Can send funds from a FinancialAccount to a bank account owned by a different entity. */ @@ -5587,6 +5645,60 @@ public static class StatusDetail extends StripeObject { String resolution; } } + + /** Can send funds from a FinancialAccount to someone else via paper check. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class PaperChecks extends StripeObject { + /** + * The status of the Capability. + * + *

One of {@code active}, {@code pending}, {@code restricted}, or {@code + * unsupported}. + */ + @SerializedName("status") + String status; + + /** + * Additional details about the capability's status. This value is empty when {@code + * status} is {@code active}. + */ + @SerializedName("status_details") + List< + Account.Configuration.Storer.Capabilities.OutboundPayments.PaperChecks + .StatusDetail> + statusDetails; + + /** + * For more details about StatusDetail, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class StatusDetail extends StripeObject { + /** + * Machine-readable code explaining the reason for the Capability to be in its current + * status. + * + *

One of {@code determining_status}, {@code requirements_past_due}, {@code + * requirements_pending_verification}, {@code restricted_other}, {@code + * unsupported_business}, {@code unsupported_country}, or {@code + * unsupported_entity_type}. + */ + @SerializedName("code") + String code; + + /** + * Machine-readable code explaining how to make the Capability active. + * + *

One of {@code contact_stripe}, {@code no_resolution}, or {@code provide_info}. + */ + @SerializedName("resolution") + String resolution; + } + } } /** @@ -6103,14 +6215,14 @@ public static class RestrictsCapability extends StripeObject { * mobilepay_payments}, {@code multibanco_payments}, {@code mx_bank_transfer_payments}, * {@code naver_pay_payments}, {@code outbound_payments.bank_accounts}, {@code * outbound_payments.cards}, {@code outbound_payments.financial_accounts}, {@code - * outbound_transfers.bank_accounts}, {@code outbound_transfers.financial_accounts}, - * {@code oxxo_payments}, {@code p24_payments}, {@code payco_payments}, {@code - * paynow_payments}, {@code pay_by_bank_payments}, {@code promptpay_payments}, {@code - * revolut_pay_payments}, {@code samsung_pay_payments}, {@code - * sepa_bank_transfer_payments}, {@code sepa_debit_payments}, {@code - * stripe_balance.payouts}, {@code stripe_balance.stripe_transfers}, {@code - * swish_payments}, {@code twint_payments}, {@code us_bank_transfer_payments}, or {@code - * zip_payments}. + * outbound_payments.paper_checks}, {@code outbound_transfers.bank_accounts}, {@code + * outbound_transfers.financial_accounts}, {@code oxxo_payments}, {@code p24_payments}, + * {@code paper_checks}, {@code payco_payments}, {@code paynow_payments}, {@code + * pay_by_bank_payments}, {@code promptpay_payments}, {@code revolut_pay_payments}, {@code + * samsung_pay_payments}, {@code sepa_bank_transfer_payments}, {@code + * sepa_debit_payments}, {@code stripe_balance.payouts}, {@code + * stripe_balance.stripe_transfers}, {@code swish_payments}, {@code twint_payments}, + * {@code us_bank_transfer_payments}, or {@code zip_payments}. */ @SerializedName("capability") String capability; @@ -9857,14 +9969,14 @@ public static class RestrictsCapability extends StripeObject { * mobilepay_payments}, {@code multibanco_payments}, {@code mx_bank_transfer_payments}, * {@code naver_pay_payments}, {@code outbound_payments.bank_accounts}, {@code * outbound_payments.cards}, {@code outbound_payments.financial_accounts}, {@code - * outbound_transfers.bank_accounts}, {@code outbound_transfers.financial_accounts}, - * {@code oxxo_payments}, {@code p24_payments}, {@code payco_payments}, {@code - * paynow_payments}, {@code pay_by_bank_payments}, {@code promptpay_payments}, {@code - * revolut_pay_payments}, {@code samsung_pay_payments}, {@code - * sepa_bank_transfer_payments}, {@code sepa_debit_payments}, {@code - * stripe_balance.payouts}, {@code stripe_balance.stripe_transfers}, {@code - * swish_payments}, {@code twint_payments}, {@code us_bank_transfer_payments}, or {@code - * zip_payments}. + * outbound_payments.paper_checks}, {@code outbound_transfers.bank_accounts}, {@code + * outbound_transfers.financial_accounts}, {@code oxxo_payments}, {@code p24_payments}, + * {@code paper_checks}, {@code payco_payments}, {@code paynow_payments}, {@code + * pay_by_bank_payments}, {@code promptpay_payments}, {@code revolut_pay_payments}, {@code + * samsung_pay_payments}, {@code sepa_bank_transfer_payments}, {@code + * sepa_debit_payments}, {@code stripe_balance.payouts}, {@code + * stripe_balance.stripe_transfers}, {@code swish_payments}, {@code twint_payments}, + * {@code us_bank_transfer_payments}, or {@code zip_payments}. */ @SerializedName("capability") String capability; diff --git a/src/main/java/com/stripe/model/v2/core/BatchJob.java b/src/main/java/com/stripe/model/v2/core/BatchJob.java index 9bc1c8bf3e6..2e737877b67 100644 --- a/src/main/java/com/stripe/model/v2/core/BatchJob.java +++ b/src/main/java/com/stripe/model/v2/core/BatchJob.java @@ -12,16 +12,16 @@ import lombok.Getter; import lombok.Setter; -/** BatchJob resource. */ +/** A batch job allows you to perform an API operation on a large set of records asynchronously. */ @Getter @Setter @EqualsAndHashCode(callSuper = false) public class BatchJob extends StripeObject implements HasId { - /** Timestamp at which BatchJob was created. */ + /** Timestamp at which the {@code batch_job} was created. */ @SerializedName("created") Instant created; - /** Unique identifier for the BatchJob. */ + /** Unique identifier for the {@code batch_job}. */ @Getter(onMethod_ = {@Override}) @SerializedName("id") String id; @@ -33,11 +33,11 @@ public class BatchJob extends StripeObject implements HasId { @SerializedName("livemode") Boolean livemode; - /** The maximum rps defined for the {@code BatchJob}. */ + /** The maximum requests per second defined for the {@code batch_job}. */ @SerializedName("maximum_rps") Long maximumRps; - /** The metadata of the {@code BatchJob} object. */ + /** The metadata of the {@code batch_job}. */ @SerializedName("metadata") Map metadata; @@ -50,12 +50,12 @@ public class BatchJob extends StripeObject implements HasId { @SerializedName("object") String object; - /** If the validation will be run previous to the execution of the {@code BatchJob}. */ + /** Whether validation runs before executing the {@code batch_job}. */ @SerializedName("skip_validation") Boolean skipValidation; /** - * The current status of the {@code BatchJob}. + * The current status of the {@code batch_job}. * *

One of {@code batch_failed}, {@code canceled}, {@code cancelling}, {@code complete}, {@code * in_progress}, {@code ready_for_upload}, {@code timeout}, {@code upload_timeout}, {@code @@ -64,58 +64,58 @@ public class BatchJob extends StripeObject implements HasId { @SerializedName("status") String status; - /** Additional details about the current state of the {@code BatchJob}. */ + /** Additional details about the current state of the {@code batch_job}. */ @SerializedName("status_details") StatusDetails statusDetails; - /** Additional details about the current state of the {@code BatchJob}. */ + /** Additional details about the current state of the {@code batch_job}. */ @Getter @Setter @EqualsAndHashCode(callSuper = false) public static class StatusDetails extends StripeObject { - /** Additional details for the {@code BATCH_FAILED} status of the {@code BatchJob}. */ + /** Additional details for the {@code BATCH_FAILED} status of the {@code batch_job}. */ @SerializedName("batch_failed") BatchFailed batchFailed; - /** Additional details for the {@code CANCELED} status of the {@code BatchJob}. */ + /** Additional details for the {@code CANCELED} status of the {@code batch_job}. */ @SerializedName("canceled") Canceled canceled; - /** Additional details for the {@code COMPLETE} status of the {@code BatchJob}. */ + /** Additional details for the {@code COMPLETE} status of the {@code batch_job}. */ @SerializedName("complete") Complete complete; - /** Additional details for the {@code IN_PROGRESS} status of the {@code BatchJob}. */ + /** Additional details for the {@code IN_PROGRESS} status of the {@code batch_job}. */ @SerializedName("in_progress") InProgress inProgress; - /** Additional details for the {@code READY_FOR_UPLOAD} status of the {@code BatchJob}. */ + /** Additional details for the {@code READY_FOR_UPLOAD} status of the {@code batch_job}. */ @SerializedName("ready_for_upload") ReadyForUpload readyForUpload; - /** Additional details for the {@code TIMEOUT} status of the {@code BatchJob}. */ + /** Additional details for the {@code TIMEOUT} status of the {@code batch_job}. */ @SerializedName("timeout") Timeout timeout; - /** Additional details for the {@code VALIDATING} status of the {@code BatchJob}. */ + /** Additional details for the {@code VALIDATING} status of the {@code batch_job}. */ @SerializedName("validating") Validating validating; - /** Additional details for the {@code VALIDATION_FAILED} status of the {@code BatchJob}. */ + /** Additional details for the {@code VALIDATION_FAILED} status of the {@code batch_job}. */ @SerializedName("validation_failed") ValidationFailed validationFailed; - /** Additional details for the {@code BATCH_FAILED} status of the {@code BatchJob}. */ + /** Additional details for the {@code BATCH_FAILED} status of the {@code batch_job}. */ @Getter @Setter @EqualsAndHashCode(callSuper = false) public static class BatchFailed extends StripeObject { - /** Details about the {@code BatchJob} failure. */ + /** Details about the {@code batch_job} failure. */ @SerializedName("error") String error; } - /** Additional details for the {@code CANCELED} status of the {@code BatchJob}. */ + /** Additional details for the {@code CANCELED} status of the {@code batch_job}. */ @Getter @Setter @EqualsAndHashCode(callSuper = false) @@ -126,8 +126,8 @@ public static class Canceled extends StripeObject { Long failureCount; /** - * The output file details. If BatchJob is cancelled it's provided only if there is already - * output at this point. + * The output file details. If the {@code batch_job} is canceled, this is provided only if + * there is already output at this point. */ @SerializedName("output_file") OutputFile outputFile; @@ -138,8 +138,8 @@ public static class Canceled extends StripeObject { Long successCount; /** - * The output file details. If BatchJob is cancelled it's provided only if there is already - * output at this point. + * The output file details. If the {@code batch_job} is canceled, this is provided only if + * there is already output at this point. */ @Getter @Setter @@ -174,7 +174,7 @@ public static class DownloadUrl extends StripeObject { } } - /** Additional details for the {@code COMPLETE} status of the {@code BatchJob}. */ + /** Additional details for the {@code COMPLETE} status of the {@code batch_job}. */ @Getter @Setter @EqualsAndHashCode(callSuper = false) @@ -185,8 +185,8 @@ public static class Complete extends StripeObject { Long failureCount; /** - * The output file details. If BatchJob is cancelled it's provided only if there is already - * output at this point. + * The output file details. If the {@code batch_job} is canceled, this is provided only if + * there is already output at this point. */ @SerializedName("output_file") OutputFile outputFile; @@ -197,8 +197,8 @@ public static class Complete extends StripeObject { Long successCount; /** - * The output file details. If BatchJob is cancelled it's provided only if there is already - * output at this point. + * The output file details. If the {@code batch_job} is canceled, this is provided only if + * there is already output at this point. */ @Getter @Setter @@ -233,7 +233,7 @@ public static class DownloadUrl extends StripeObject { } } - /** Additional details for the {@code IN_PROGRESS} status of the {@code BatchJob}. */ + /** Additional details for the {@code IN_PROGRESS} status of the {@code batch_job}. */ @Getter @Setter @EqualsAndHashCode(callSuper = false) @@ -249,7 +249,7 @@ public static class InProgress extends StripeObject { Long successCount; } - /** Additional details for the {@code READY_FOR_UPLOAD} status of the {@code BatchJob}. */ + /** Additional details for the {@code READY_FOR_UPLOAD} status of the {@code batch_job}. */ @Getter @Setter @EqualsAndHashCode(callSuper = false) @@ -273,7 +273,7 @@ public static class UploadUrl extends StripeObject { } } - /** Additional details for the {@code TIMEOUT} status of the {@code BatchJob}. */ + /** Additional details for the {@code TIMEOUT} status of the {@code batch_job}. */ @Getter @Setter @EqualsAndHashCode(callSuper = false) @@ -284,8 +284,8 @@ public static class Timeout extends StripeObject { Long failureCount; /** - * The output file details. If BatchJob is cancelled it's provided only if there is already - * output at this point. + * The output file details. If the {@code batch_job} is canceled, this is provided only if + * there is already output at this point. */ @SerializedName("output_file") OutputFile outputFile; @@ -296,8 +296,8 @@ public static class Timeout extends StripeObject { Long successCount; /** - * The output file details. If BatchJob is cancelled it's provided only if there is already - * output at this point. + * The output file details. If the {@code batch_job} is canceled, this is provided only if + * there is already output at this point. */ @Getter @Setter @@ -332,7 +332,7 @@ public static class DownloadUrl extends StripeObject { } } - /** Additional details for the {@code VALIDATING} status of the {@code BatchJob}. */ + /** Additional details for the {@code VALIDATING} status of the {@code batch_job}. */ @Getter @Setter @EqualsAndHashCode(callSuper = false) @@ -346,7 +346,7 @@ public static class Validating extends StripeObject { Long validatedCount; } - /** Additional details for the {@code VALIDATION_FAILED} status of the {@code BatchJob}. */ + /** Additional details for the {@code VALIDATION_FAILED} status of the {@code batch_job}. */ @Getter @Setter @EqualsAndHashCode(callSuper = false) @@ -357,8 +357,8 @@ public static class ValidationFailed extends StripeObject { Long failureCount; /** - * The output file details. If BatchJob is cancelled it's provided only if there is already - * output at this point. + * The output file details. If the {@code batch_job} is canceled, this is provided only if + * there is already output at this point. */ @SerializedName("output_file") OutputFile outputFile; @@ -369,8 +369,8 @@ public static class ValidationFailed extends StripeObject { Long successCount; /** - * The output file details. If BatchJob is cancelled it's provided only if there is already - * output at this point. + * The output file details. If the {@code batch_job} is canceled, this is provided only if + * there is already output at this point. */ @Getter @Setter diff --git a/src/main/java/com/stripe/model/v2/data/reporting/QueryRun.java b/src/main/java/com/stripe/model/v2/data/reporting/QueryRun.java new file mode 100644 index 00000000000..99a6aab79b5 --- /dev/null +++ b/src/main/java/com/stripe/model/v2/data/reporting/QueryRun.java @@ -0,0 +1,170 @@ +// File generated from our OpenAPI spec +package com.stripe.model.v2.data.reporting; + +import com.google.gson.annotations.JsonAdapter; +import com.google.gson.annotations.SerializedName; +import com.stripe.model.HasId; +import com.stripe.model.StringInt64TypeAdapter; +import com.stripe.model.StripeObject; +import java.time.Instant; +import java.util.Map; +import lombok.EqualsAndHashCode; +import lombok.Getter; +import lombok.Setter; + +/** + * The {@code QueryRun} object represents an ad-hoc SQL execution. Once created, Stripe processes + * the query. When the query has finished running, the object provides a reference to the results. + */ +@Getter +@Setter +@EqualsAndHashCode(callSuper = false) +public class QueryRun extends StripeObject implements HasId { + /** Time at which the object was created. */ + @SerializedName("created") + Instant created; + + /** The unique identifier of the {@code QueryRun} object. */ + @Getter(onMethod_ = {@Override}) + @SerializedName("id") + String id; + + /** + * Has the value {@code true} if the object exists in live mode or the value {@code false} if the + * object exists in test mode. + */ + @SerializedName("livemode") + Boolean livemode; + + /** + * String representing the object's type. Objects of the same type share the same value of the + * object field. + * + *

Equal to {@code v2.data.reporting.query_run}. + */ + @SerializedName("object") + String object; + + /** Details how to retrieve the results of a successfully completed {@code QueryRun}. */ + @SerializedName("result") + Result result; + + /** The options specified for customizing the output of the {@code QueryRun}. */ + @SerializedName("result_options") + ResultOptions resultOptions; + + /** The SQL that was executed. */ + @SerializedName("sql") + String sql; + + /** + * The current status of the {@code QueryRun}. + * + *

One of {@code failed}, {@code running}, or {@code succeeded}. + */ + @SerializedName("status") + String status; + + /** + * Additional details about the current state of the {@code QueryRun}. Populated when the {@code + * QueryRun} is in the {@code failed} state, providing more information about why the query + * failed. + */ + @SerializedName("status_details") + Map statusDetails; + + /** Details how to retrieve the results of a successfully completed {@code QueryRun}. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Result extends StripeObject { + /** + * Contains metadata about the file produced by the {@code ReportRun} or {@code QueryRun}, + * including its content type, size, and a URL to download its contents. + */ + @SerializedName("file") + File file; + + /** + * The type of the {@code ReportRun} or {@code QueryRun} result. + * + *

Equal to {@code file}. + */ + @SerializedName("type") + String type; + + /** + * Contains metadata about the file produced by the {@code ReportRun} or {@code QueryRun}, + * including its content type, size, and a URL to download its contents. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class File extends StripeObject { + /** + * The content type of the file. + * + *

One of {@code csv}, or {@code zip}. + */ + @SerializedName("content_type") + String contentType; + + /** A pre-signed URL that allows secure, time-limited access to download the file. */ + @SerializedName("download_url") + DownloadUrl downloadUrl; + + /** The total size of the file in bytes. */ + @SerializedName("size") + @JsonAdapter(StringInt64TypeAdapter.class) + Long size; + + /** A pre-signed URL that allows secure, time-limited access to download the file. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class DownloadUrl extends StripeObject { + /** The time that the URL expires. */ + @SerializedName("expires_at") + Instant expiresAt; + + /** The URL that can be used for accessing the file. */ + @SerializedName("url") + String url; + } + } + } + + /** The options specified for customizing the output of the {@code QueryRun}. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class ResultOptions extends StripeObject { + /** + * If set, the generated results file will be compressed into a ZIP folder. This is useful for + * reducing file size and download time for large results. + */ + @SerializedName("compress_file") + Boolean compressFile; + } + + /** + * For more details about StatusDetail, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class StatusDetail extends StripeObject { + /** + * Error code categorizing the reason the {@code QueryRun} failed. + * + *

One of {@code file_size_above_limit}, or {@code internal_error}. + */ + @SerializedName("error_code") + String errorCode; + + /** Error message with additional details about the failure. */ + @SerializedName("error_message") + String errorMessage; + } +} diff --git a/src/main/java/com/stripe/model/v2/moneymanagement/OutboundPayment.java b/src/main/java/com/stripe/model/v2/moneymanagement/OutboundPayment.java index f028a1da013..066e5ae122a 100644 --- a/src/main/java/com/stripe/model/v2/moneymanagement/OutboundPayment.java +++ b/src/main/java/com/stripe/model/v2/moneymanagement/OutboundPayment.java @@ -261,9 +261,11 @@ public static class Failed extends StripeObject { /** * Open Enum. The {@code failed} status reason. * - *

One of {@code payout_method_declined}, {@code payout_method_does_not_exist}, {@code - * payout_method_expired}, {@code payout_method_unsupported}, {@code - * payout_method_usage_frequency_limit_exceeded}, or {@code unknown_failure}. + *

One of {@code paper_check_attachment_too_large}, {@code paper_check_expired}, {@code + * paper_check_undeliverable}, {@code payout_method_declined}, {@code + * payout_method_does_not_exist}, {@code payout_method_expired}, {@code + * payout_method_unsupported}, {@code payout_method_usage_frequency_limit_exceeded}, or {@code + * unknown_failure}. */ @SerializedName("reason") String reason; @@ -450,10 +452,6 @@ public static class MailingAddress extends StripeObject { /** State, county, province, or region. */ @SerializedName("state") String state; - - /** Town or district. */ - @SerializedName("town") - String town; } } } diff --git a/src/main/java/com/stripe/model/v2/payments/OffSessionPayment.java b/src/main/java/com/stripe/model/v2/payments/OffSessionPayment.java index 1966e8230f0..2475d12d953 100644 --- a/src/main/java/com/stripe/model/v2/payments/OffSessionPayment.java +++ b/src/main/java/com/stripe/model/v2/payments/OffSessionPayment.java @@ -45,10 +45,6 @@ public class OffSessionPayment extends StripeObject implements HasId { @SerializedName("capture") Capture capture; - /** ID of the owning compartment. */ - @SerializedName("compartment_id") - String compartmentId; - /** * Creation time of the OffSessionPayment. Represented as a RFC 3339 date & time UTC value in * millisecond precision, for example: 2022-09-18T13:22:18.123Z. @@ -63,8 +59,8 @@ public class OffSessionPayment extends StripeObject implements HasId { /** * The reason why the OffSessionPayment failed. * - *

One of {@code authorization_expired}, {@code no_valid_payment_method}, {@code - * rejected_by_partner}, or {@code retries_exhausted}. + *

One of {@code authorization_expired}, {@code exceeded_retry_window}, {@code + * no_valid_payment_method}, {@code rejected_by_partner}, or {@code retries_exhausted}. */ @SerializedName("failure_reason") String failureReason; @@ -217,6 +213,13 @@ public static class RetryDetails extends StripeObject { */ @SerializedName("retry_strategy") String retryStrategy; + + /** + * The timestamp when this payment is no longer eligible to be retried. When this timestamp is + * reached, the payment will be marked as failed. + */ + @SerializedName("retry_until") + Instant retryUntil; } /** diff --git a/src/main/java/com/stripe/model/v2/reporting/ReportRun.java b/src/main/java/com/stripe/model/v2/reporting/ReportRun.java index 659323dcc14..4d7e745da22 100644 --- a/src/main/java/com/stripe/model/v2/reporting/ReportRun.java +++ b/src/main/java/com/stripe/model/v2/reporting/ReportRun.java @@ -88,14 +88,14 @@ public class ReportRun extends StripeObject implements HasId { @EqualsAndHashCode(callSuper = false) public static class Result extends StripeObject { /** - * Contains metadata about the file produced by the {@code ReportRun}, including its content - * type, size, and a URL to download its contents. + * Contains metadata about the file produced by the {@code ReportRun} or {@code QueryRun}, + * including its content type, size, and a URL to download its contents. */ @SerializedName("file") File file; /** - * The type of the {@code ReportRun} result. + * The type of the {@code ReportRun} or {@code QueryRun} result. * *

Equal to {@code file}. */ @@ -103,8 +103,8 @@ public static class Result extends StripeObject { String type; /** - * Contains metadata about the file produced by the {@code ReportRun}, including its content - * type, size, and a URL to download its contents. + * Contains metadata about the file produced by the {@code ReportRun} or {@code QueryRun}, + * including its content type, size, and a URL to download its contents. */ @Getter @Setter @@ -149,8 +149,8 @@ public static class DownloadUrl extends StripeObject { @EqualsAndHashCode(callSuper = false) public static class ResultOptions extends StripeObject { /** - * If set, the generated report file will be compressed into a ZIP folder. This is useful for - * reducing file size and download time for large reports. + * If set, the generated results file will be compressed into a ZIP folder. This is useful for + * reducing file size and download time for large results. */ @SerializedName("compress_file") Boolean compressFile; diff --git a/src/main/java/com/stripe/param/ChargeCaptureParams.java b/src/main/java/com/stripe/param/ChargeCaptureParams.java index 5378c15e0e8..4a495e62578 100644 --- a/src/main/java/com/stripe/param/ChargeCaptureParams.java +++ b/src/main/java/com/stripe/param/ChargeCaptureParams.java @@ -348,6 +348,10 @@ public static class PaymentDetails { @SerializedName("lodging_data") Object lodgingData; + /** Money services details for this PaymentIntent. */ + @SerializedName("money_services") + Object moneyServices; + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -373,6 +377,7 @@ private PaymentDetails( Object flightData, Lodging lodging, Object lodgingData, + Object moneyServices, Object orderReference, Subscription subscription) { this.carRental = carRental; @@ -384,6 +389,7 @@ private PaymentDetails( this.flightData = flightData; this.lodging = lodging; this.lodgingData = lodgingData; + this.moneyServices = moneyServices; this.orderReference = orderReference; this.subscription = subscription; } @@ -411,6 +417,8 @@ public static class Builder { private Object lodgingData; + private Object moneyServices; + private Object orderReference; private Subscription subscription; @@ -427,6 +435,7 @@ public ChargeCaptureParams.PaymentDetails build() { this.flightData, this.lodging, this.lodgingData, + this.moneyServices, this.orderReference, this.subscription); } @@ -629,6 +638,19 @@ public Builder setLodgingData( return this; } + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices( + ChargeCaptureParams.PaymentDetails.MoneyServices moneyServices) { + this.moneyServices = moneyServices; + return this; + } + + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices(EmptyParam moneyServices) { + this.moneyServices = moneyServices; + return this; + } + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -10411,6 +10433,174 @@ public Builder setType(String type) { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; + + /** + * 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 type of money services transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; + + private MoneyServices( + Object accountFunding, Map extraParams, TransactionType transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object accountFunding; + + private Map extraParams; + + private TransactionType transactionType; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeCaptureParams.PaymentDetails.MoneyServices build() { + return new ChargeCaptureParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + 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 ChargeCaptureParams.PaymentDetails.MoneyServices#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 ChargeCaptureParams.PaymentDetails.MoneyServices#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 type of money services transaction. */ + public Builder setTransactionType( + ChargeCaptureParams.PaymentDetails.MoneyServices.TransactionType transactionType) { + this.transactionType = transactionType; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding( + 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 + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding#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 + * ChargeCaptureParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + public enum TransactionType implements ApiRequestParams.EnumParam { + @SerializedName("account_funding") + ACCOUNT_FUNDING("account_funding"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TransactionType(String value) { + this.value = value; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class Subscription { diff --git a/src/main/java/com/stripe/param/ChargeUpdateParams.java b/src/main/java/com/stripe/param/ChargeUpdateParams.java index 024f5f587c6..311c33a51d2 100644 --- a/src/main/java/com/stripe/param/ChargeUpdateParams.java +++ b/src/main/java/com/stripe/param/ChargeUpdateParams.java @@ -495,6 +495,10 @@ public static class PaymentDetails { @SerializedName("lodging_data") Object lodgingData; + /** Money services details for this PaymentIntent. */ + @SerializedName("money_services") + Object moneyServices; + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -520,6 +524,7 @@ private PaymentDetails( Object flightData, Lodging lodging, Object lodgingData, + Object moneyServices, Object orderReference, Subscription subscription) { this.carRental = carRental; @@ -531,6 +536,7 @@ private PaymentDetails( this.flightData = flightData; this.lodging = lodging; this.lodgingData = lodgingData; + this.moneyServices = moneyServices; this.orderReference = orderReference; this.subscription = subscription; } @@ -558,6 +564,8 @@ public static class Builder { private Object lodgingData; + private Object moneyServices; + private Object orderReference; private Subscription subscription; @@ -574,6 +582,7 @@ public ChargeUpdateParams.PaymentDetails build() { this.flightData, this.lodging, this.lodgingData, + this.moneyServices, this.orderReference, this.subscription); } @@ -775,6 +784,19 @@ public Builder setLodgingData( return this; } + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices( + ChargeUpdateParams.PaymentDetails.MoneyServices moneyServices) { + this.moneyServices = moneyServices; + return this; + } + + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices(EmptyParam moneyServices) { + this.moneyServices = moneyServices; + return this; + } + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -11542,6 +11564,174 @@ public Builder setType(EmptyParam type) { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; + + /** + * 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 type of money services transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; + + private MoneyServices( + Object accountFunding, Map extraParams, TransactionType transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object accountFunding; + + private Map extraParams; + + private TransactionType transactionType; + + /** Finalize and obtain parameter instance from this builder. */ + public ChargeUpdateParams.PaymentDetails.MoneyServices build() { + return new ChargeUpdateParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + 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 ChargeUpdateParams.PaymentDetails.MoneyServices#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 ChargeUpdateParams.PaymentDetails.MoneyServices#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 type of money services transaction. */ + public Builder setTransactionType( + ChargeUpdateParams.PaymentDetails.MoneyServices.TransactionType transactionType) { + this.transactionType = transactionType; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding( + 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 + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding#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 + * ChargeUpdateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + public enum TransactionType implements ApiRequestParams.EnumParam { + @SerializedName("account_funding") + ACCOUNT_FUNDING("account_funding"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TransactionType(String value) { + this.value = value; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class Subscription { diff --git a/src/main/java/com/stripe/param/PaymentIntentCaptureParams.java b/src/main/java/com/stripe/param/PaymentIntentCaptureParams.java index 608d54a5db1..15d3a6a8239 100644 --- a/src/main/java/com/stripe/param/PaymentIntentCaptureParams.java +++ b/src/main/java/com/stripe/param/PaymentIntentCaptureParams.java @@ -2158,6 +2158,10 @@ public static class PaymentDetails { @SerializedName("lodging_data") Object lodgingData; + /** Money services details for this PaymentIntent. */ + @SerializedName("money_services") + Object moneyServices; + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -2183,6 +2187,7 @@ private PaymentDetails( Object flightData, Lodging lodging, Object lodgingData, + Object moneyServices, Object orderReference, Subscription subscription) { this.carRental = carRental; @@ -2194,6 +2199,7 @@ private PaymentDetails( this.flightData = flightData; this.lodging = lodging; this.lodgingData = lodgingData; + this.moneyServices = moneyServices; this.orderReference = orderReference; this.subscription = subscription; } @@ -2221,6 +2227,8 @@ public static class Builder { private Object lodgingData; + private Object moneyServices; + private Object orderReference; private Subscription subscription; @@ -2237,6 +2245,7 @@ public PaymentIntentCaptureParams.PaymentDetails build() { this.flightData, this.lodging, this.lodgingData, + this.moneyServices, this.orderReference, this.subscription); } @@ -2449,6 +2458,19 @@ public Builder setLodgingData( return this; } + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices moneyServices) { + this.moneyServices = moneyServices; + return this; + } + + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices(EmptyParam moneyServices) { + this.moneyServices = moneyServices; + return this; + } + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -12355,6 +12377,175 @@ public Builder setType(String type) { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; + + /** + * 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 type of money services transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; + + private MoneyServices( + Object accountFunding, Map extraParams, TransactionType transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object accountFunding; + + private Map extraParams; + + private TransactionType transactionType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCaptureParams.PaymentDetails.MoneyServices build() { + return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + 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 PaymentIntentCaptureParams.PaymentDetails.MoneyServices#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 PaymentIntentCaptureParams.PaymentDetails.MoneyServices#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 type of money services transaction. */ + public Builder setTransactionType( + PaymentIntentCaptureParams.PaymentDetails.MoneyServices.TransactionType + transactionType) { + this.transactionType = transactionType; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding( + 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 + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding#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 + * PaymentIntentCaptureParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + public enum TransactionType implements ApiRequestParams.EnumParam { + @SerializedName("account_funding") + ACCOUNT_FUNDING("account_funding"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TransactionType(String value) { + this.value = value; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class Subscription { diff --git a/src/main/java/com/stripe/param/PaymentIntentConfirmParams.java b/src/main/java/com/stripe/param/PaymentIntentConfirmParams.java index e8fa42c8732..b131b51f2ca 100644 --- a/src/main/java/com/stripe/param/PaymentIntentConfirmParams.java +++ b/src/main/java/com/stripe/param/PaymentIntentConfirmParams.java @@ -2993,6 +2993,10 @@ public static class PaymentDetails { @SerializedName("lodging_data") Object lodgingData; + /** Money services details for this PaymentIntent. */ + @SerializedName("money_services") + Object moneyServices; + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -3019,6 +3023,7 @@ private PaymentDetails( Object flightData, Lodging lodging, Object lodgingData, + Object moneyServices, Object orderReference, Subscription subscription) { this.benefit = benefit; @@ -3031,6 +3036,7 @@ private PaymentDetails( this.flightData = flightData; this.lodging = lodging; this.lodgingData = lodgingData; + this.moneyServices = moneyServices; this.orderReference = orderReference; this.subscription = subscription; } @@ -3060,6 +3066,8 @@ public static class Builder { private Object lodgingData; + private Object moneyServices; + private Object orderReference; private Subscription subscription; @@ -3077,6 +3085,7 @@ public PaymentIntentConfirmParams.PaymentDetails build() { this.flightData, this.lodging, this.lodgingData, + this.moneyServices, this.orderReference, this.subscription); } @@ -3295,6 +3304,19 @@ public Builder setLodgingData( return this; } + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices moneyServices) { + this.moneyServices = moneyServices; + return this; + } + + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices(EmptyParam moneyServices) { + this.moneyServices = moneyServices; + return this; + } + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -13355,6 +13377,175 @@ public Builder setType(String type) { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; + + /** + * 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 type of money services transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; + + private MoneyServices( + Object accountFunding, Map extraParams, TransactionType transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object accountFunding; + + private Map extraParams; + + private TransactionType transactionType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentDetails.MoneyServices build() { + return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + 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 PaymentIntentConfirmParams.PaymentDetails.MoneyServices#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 PaymentIntentConfirmParams.PaymentDetails.MoneyServices#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 type of money services transaction. */ + public Builder setTransactionType( + PaymentIntentConfirmParams.PaymentDetails.MoneyServices.TransactionType + transactionType) { + this.transactionType = transactionType; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding( + 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 + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding#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 + * PaymentIntentConfirmParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + public enum TransactionType implements ApiRequestParams.EnumParam { + @SerializedName("account_funding") + ACCOUNT_FUNDING("account_funding"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TransactionType(String value) { + this.value = value; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class Subscription { @@ -24902,6 +25093,10 @@ public static class Card { @SerializedName("network") Network network; + /** Payment details for payment method specific funding fields. */ + @SerializedName("payment_details") + PaymentDetails paymentDetails; + /** * Request ability to decrement the @@ -25041,6 +25236,7 @@ private Card( MandateOptions mandateOptions, Boolean moto, Network network, + PaymentDetails paymentDetails, RequestDecrementalAuthorization requestDecrementalAuthorization, RequestExtendedAuthorization requestExtendedAuthorization, RequestIncrementalAuthorization requestIncrementalAuthorization, @@ -25062,6 +25258,7 @@ private Card( this.mandateOptions = mandateOptions; this.moto = moto; this.network = network; + this.paymentDetails = paymentDetails; this.requestDecrementalAuthorization = requestDecrementalAuthorization; this.requestExtendedAuthorization = requestExtendedAuthorization; this.requestIncrementalAuthorization = requestIncrementalAuthorization; @@ -25097,6 +25294,8 @@ public static class Builder { private Network network; + private PaymentDetails paymentDetails; + private RequestDecrementalAuthorization requestDecrementalAuthorization; private RequestExtendedAuthorization requestExtendedAuthorization; @@ -25135,6 +25334,7 @@ public PaymentIntentConfirmParams.PaymentMethodOptions.Card build() { this.mandateOptions, this.moto, this.network, + this.paymentDetails, this.requestDecrementalAuthorization, this.requestExtendedAuthorization, this.requestIncrementalAuthorization, @@ -25259,6 +25459,13 @@ public Builder setNetwork( return this; } + /** Payment details for payment method specific funding fields. */ + public Builder setPaymentDetails( + PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails paymentDetails) { + this.paymentDetails = paymentDetails; + return this; + } + /** * Request ability to decrement the @@ -26107,6 +26314,226 @@ public enum SupportedType implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaymentDetails { + /** + * 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; + + /** Money services details for payment method specific funding fields. */ + @SerializedName("money_services") + MoneyServices moneyServices; + + private PaymentDetails(Map extraParams, MoneyServices moneyServices) { + this.extraParams = extraParams; + this.moneyServices = moneyServices; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private MoneyServices moneyServices; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails( + this.extraParams, this.moneyServices); + } + + /** + * 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 + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails#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 + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Money services details for payment method specific funding fields. */ + public Builder setMoneyServices( + PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + moneyServices) { + this.moneyServices = moneyServices; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Payment method specific account funding transaction details. */ + @SerializedName("account_funding") + AccountFunding accountFunding; + + /** + * 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 MoneyServices(AccountFunding accountFunding, Map extraParams) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private AccountFunding accountFunding; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices(this.accountFunding, this.extraParams); + } + + /** Payment method specific account funding transaction details. */ + public Builder setAccountFunding( + PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding + accountFunding) { + this.accountFunding = accountFunding; + 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 + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices#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 + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices#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 + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding(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 + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#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 + * PaymentIntentConfirmParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#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 @EqualsAndHashCode(callSuper = false) public static class StatementDetails { @@ -27152,6 +27579,10 @@ public static class CardPresent { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Payment details for payment method specific funding transaction fields. */ + @SerializedName("payment_details") + PaymentDetails paymentDetails; + /** * Request ability to capture this payment beyond the standard authorization @@ -27189,12 +27620,14 @@ public static class CardPresent { private CardPresent( CaptureMethod captureMethod, Map extraParams, + PaymentDetails paymentDetails, Boolean requestExtendedAuthorization, Boolean requestIncrementalAuthorizationSupport, RequestReauthorization requestReauthorization, Routing routing) { this.captureMethod = captureMethod; this.extraParams = extraParams; + this.paymentDetails = paymentDetails; this.requestExtendedAuthorization = requestExtendedAuthorization; this.requestIncrementalAuthorizationSupport = requestIncrementalAuthorizationSupport; this.requestReauthorization = requestReauthorization; @@ -27210,6 +27643,8 @@ public static class Builder { private Map extraParams; + private PaymentDetails paymentDetails; + private Boolean requestExtendedAuthorization; private Boolean requestIncrementalAuthorizationSupport; @@ -27223,6 +27658,7 @@ public PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent build() { return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent( this.captureMethod, this.extraParams, + this.paymentDetails, this.requestExtendedAuthorization, this.requestIncrementalAuthorizationSupport, this.requestReauthorization, @@ -27274,6 +27710,14 @@ public Builder putAllExtraParam(Map map) { return this; } + /** Payment details for payment method specific funding transaction fields. */ + public Builder setPaymentDetails( + PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + paymentDetails) { + this.paymentDetails = paymentDetails; + return this; + } + /** * Request ability to capture this payment beyond the standard authorization @@ -27321,6 +27765,229 @@ public Builder setRouting( } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaymentDetails { + /** + * 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; + + /** Money services details for payment method specific funding fields. */ + @SerializedName("money_services") + MoneyServices moneyServices; + + private PaymentDetails(Map extraParams, MoneyServices moneyServices) { + this.extraParams = extraParams; + this.moneyServices = moneyServices; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private MoneyServices moneyServices; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails( + this.extraParams, this.moneyServices); + } + + /** + * 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 + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails#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 + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Money services details for payment method specific funding fields. */ + public Builder setMoneyServices( + PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices + moneyServices) { + this.moneyServices = moneyServices; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Payment method specific account funding transaction details. */ + @SerializedName("account_funding") + AccountFunding accountFunding; + + /** + * 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 MoneyServices(AccountFunding accountFunding, Map extraParams) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private AccountFunding accountFunding; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices(this.accountFunding, this.extraParams); + } + + /** Payment method specific account funding transaction details. */ + public Builder setAccountFunding( + PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding + accountFunding) { + this.accountFunding = accountFunding; + 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 + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices#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 + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices#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 + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding + build() { + return new PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent + .PaymentDetails.MoneyServices.AccountFunding(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 + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding#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 + * PaymentIntentConfirmParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding#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 @EqualsAndHashCode(callSuper = false) public static class Routing { diff --git a/src/main/java/com/stripe/param/PaymentIntentCreateParams.java b/src/main/java/com/stripe/param/PaymentIntentCreateParams.java index 478dde3b52d..917d1345c3a 100644 --- a/src/main/java/com/stripe/param/PaymentIntentCreateParams.java +++ b/src/main/java/com/stripe/param/PaymentIntentCreateParams.java @@ -3530,6 +3530,10 @@ public static class PaymentDetails { @SerializedName("lodging_data") Object lodgingData; + /** Money services details for this PaymentIntent. */ + @SerializedName("money_services") + Object moneyServices; + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -3556,6 +3560,7 @@ private PaymentDetails( Object flightData, Lodging lodging, Object lodgingData, + Object moneyServices, Object orderReference, Subscription subscription) { this.benefit = benefit; @@ -3568,6 +3573,7 @@ private PaymentDetails( this.flightData = flightData; this.lodging = lodging; this.lodgingData = lodgingData; + this.moneyServices = moneyServices; this.orderReference = orderReference; this.subscription = subscription; } @@ -3597,6 +3603,8 @@ public static class Builder { private Object lodgingData; + private Object moneyServices; + private Object orderReference; private Subscription subscription; @@ -3614,6 +3622,7 @@ public PaymentIntentCreateParams.PaymentDetails build() { this.flightData, this.lodging, this.lodgingData, + this.moneyServices, this.orderReference, this.subscription); } @@ -3832,6 +3841,19 @@ public Builder setLodgingData( return this; } + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices( + PaymentIntentCreateParams.PaymentDetails.MoneyServices moneyServices) { + this.moneyServices = moneyServices; + return this; + } + + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices(EmptyParam moneyServices) { + this.moneyServices = moneyServices; + return this; + } + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -13874,6 +13896,175 @@ public Builder setType(String type) { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; + + /** + * 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 type of money services transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; + + private MoneyServices( + Object accountFunding, Map extraParams, TransactionType transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object accountFunding; + + private Map extraParams; + + private TransactionType transactionType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentDetails.MoneyServices build() { + return new PaymentIntentCreateParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + 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 PaymentIntentCreateParams.PaymentDetails.MoneyServices#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 PaymentIntentCreateParams.PaymentDetails.MoneyServices#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 type of money services transaction. */ + public Builder setTransactionType( + PaymentIntentCreateParams.PaymentDetails.MoneyServices.TransactionType + transactionType) { + this.transactionType = transactionType; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding( + 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 + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding#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 + * PaymentIntentCreateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + public enum TransactionType implements ApiRequestParams.EnumParam { + @SerializedName("account_funding") + ACCOUNT_FUNDING("account_funding"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TransactionType(String value) { + this.value = value; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class Subscription { @@ -25401,6 +25592,10 @@ public static class Card { @SerializedName("network") Network network; + /** Payment details for payment method specific funding fields. */ + @SerializedName("payment_details") + PaymentDetails paymentDetails; + /** * Request ability to decrement the @@ -25540,6 +25735,7 @@ private Card( MandateOptions mandateOptions, Boolean moto, Network network, + PaymentDetails paymentDetails, RequestDecrementalAuthorization requestDecrementalAuthorization, RequestExtendedAuthorization requestExtendedAuthorization, RequestIncrementalAuthorization requestIncrementalAuthorization, @@ -25561,6 +25757,7 @@ private Card( this.mandateOptions = mandateOptions; this.moto = moto; this.network = network; + this.paymentDetails = paymentDetails; this.requestDecrementalAuthorization = requestDecrementalAuthorization; this.requestExtendedAuthorization = requestExtendedAuthorization; this.requestIncrementalAuthorization = requestIncrementalAuthorization; @@ -25596,6 +25793,8 @@ public static class Builder { private Network network; + private PaymentDetails paymentDetails; + private RequestDecrementalAuthorization requestDecrementalAuthorization; private RequestExtendedAuthorization requestExtendedAuthorization; @@ -25634,6 +25833,7 @@ public PaymentIntentCreateParams.PaymentMethodOptions.Card build() { this.mandateOptions, this.moto, this.network, + this.paymentDetails, this.requestDecrementalAuthorization, this.requestExtendedAuthorization, this.requestIncrementalAuthorization, @@ -25758,6 +25958,13 @@ public Builder setNetwork( return this; } + /** Payment details for payment method specific funding fields. */ + public Builder setPaymentDetails( + PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails paymentDetails) { + this.paymentDetails = paymentDetails; + return this; + } + /** * Request ability to decrement the @@ -26602,6 +26809,226 @@ public enum SupportedType implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaymentDetails { + /** + * 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; + + /** Money services details for payment method specific funding fields. */ + @SerializedName("money_services") + MoneyServices moneyServices; + + private PaymentDetails(Map extraParams, MoneyServices moneyServices) { + this.extraParams = extraParams; + this.moneyServices = moneyServices; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private MoneyServices moneyServices; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails( + this.extraParams, this.moneyServices); + } + + /** + * 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 + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails#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 + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Money services details for payment method specific funding fields. */ + public Builder setMoneyServices( + PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + moneyServices) { + this.moneyServices = moneyServices; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Payment method specific account funding transaction details. */ + @SerializedName("account_funding") + AccountFunding accountFunding; + + /** + * 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 MoneyServices(AccountFunding accountFunding, Map extraParams) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private AccountFunding accountFunding; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices(this.accountFunding, this.extraParams); + } + + /** Payment method specific account funding transaction details. */ + public Builder setAccountFunding( + PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding + accountFunding) { + this.accountFunding = accountFunding; + 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 + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices#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 + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices#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 + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding(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 + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#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 + * PaymentIntentCreateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#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 @EqualsAndHashCode(callSuper = false) public static class StatementDetails { @@ -27647,6 +28074,10 @@ public static class CardPresent { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Payment details for payment method specific funding transaction fields. */ + @SerializedName("payment_details") + PaymentDetails paymentDetails; + /** * Request ability to capture this payment beyond the standard authorization @@ -27684,12 +28115,14 @@ public static class CardPresent { private CardPresent( CaptureMethod captureMethod, Map extraParams, + PaymentDetails paymentDetails, Boolean requestExtendedAuthorization, Boolean requestIncrementalAuthorizationSupport, RequestReauthorization requestReauthorization, Routing routing) { this.captureMethod = captureMethod; this.extraParams = extraParams; + this.paymentDetails = paymentDetails; this.requestExtendedAuthorization = requestExtendedAuthorization; this.requestIncrementalAuthorizationSupport = requestIncrementalAuthorizationSupport; this.requestReauthorization = requestReauthorization; @@ -27705,6 +28138,8 @@ public static class Builder { private Map extraParams; + private PaymentDetails paymentDetails; + private Boolean requestExtendedAuthorization; private Boolean requestIncrementalAuthorizationSupport; @@ -27718,6 +28153,7 @@ public PaymentIntentCreateParams.PaymentMethodOptions.CardPresent build() { return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent( this.captureMethod, this.extraParams, + this.paymentDetails, this.requestExtendedAuthorization, this.requestIncrementalAuthorizationSupport, this.requestReauthorization, @@ -27769,6 +28205,14 @@ public Builder putAllExtraParam(Map map) { return this; } + /** Payment details for payment method specific funding transaction fields. */ + public Builder setPaymentDetails( + PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + paymentDetails) { + this.paymentDetails = paymentDetails; + return this; + } + /** * Request ability to capture this payment beyond the standard authorization @@ -27816,6 +28260,228 @@ public Builder setRouting( } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaymentDetails { + /** + * 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; + + /** Money services details for payment method specific funding fields. */ + @SerializedName("money_services") + MoneyServices moneyServices; + + private PaymentDetails(Map extraParams, MoneyServices moneyServices) { + this.extraParams = extraParams; + this.moneyServices = moneyServices; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private MoneyServices moneyServices; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails( + this.extraParams, this.moneyServices); + } + + /** + * 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 + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails#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 + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Money services details for payment method specific funding fields. */ + public Builder setMoneyServices( + PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices + moneyServices) { + this.moneyServices = moneyServices; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Payment method specific account funding transaction details. */ + @SerializedName("account_funding") + AccountFunding accountFunding; + + /** + * 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 MoneyServices(AccountFunding accountFunding, Map extraParams) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private AccountFunding accountFunding; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices(this.accountFunding, this.extraParams); + } + + /** Payment method specific account funding transaction details. */ + public Builder setAccountFunding( + PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding + accountFunding) { + this.accountFunding = accountFunding; + 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 + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices#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 + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices#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 + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding + build() { + return new PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding(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 + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding#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 + * PaymentIntentCreateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding#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 @EqualsAndHashCode(callSuper = false) public static class Routing { diff --git a/src/main/java/com/stripe/param/PaymentIntentUpdateParams.java b/src/main/java/com/stripe/param/PaymentIntentUpdateParams.java index ddf0d8a2dda..01150119f23 100644 --- a/src/main/java/com/stripe/param/PaymentIntentUpdateParams.java +++ b/src/main/java/com/stripe/param/PaymentIntentUpdateParams.java @@ -3240,6 +3240,10 @@ public static class PaymentDetails { @SerializedName("lodging_data") Object lodgingData; + /** Money services details for this PaymentIntent. */ + @SerializedName("money_services") + Object moneyServices; + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -3266,6 +3270,7 @@ private PaymentDetails( Object flightData, Lodging lodging, Object lodgingData, + Object moneyServices, Object orderReference, Subscription subscription) { this.benefit = benefit; @@ -3278,6 +3283,7 @@ private PaymentDetails( this.flightData = flightData; this.lodging = lodging; this.lodgingData = lodgingData; + this.moneyServices = moneyServices; this.orderReference = orderReference; this.subscription = subscription; } @@ -3307,6 +3313,8 @@ public static class Builder { private Object lodgingData; + private Object moneyServices; + private Object orderReference; private Subscription subscription; @@ -3324,6 +3332,7 @@ public PaymentIntentUpdateParams.PaymentDetails build() { this.flightData, this.lodging, this.lodgingData, + this.moneyServices, this.orderReference, this.subscription); } @@ -3542,6 +3551,19 @@ public Builder setLodgingData( return this; } + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices moneyServices) { + this.moneyServices = moneyServices; + return this; + } + + /** Money services details for this PaymentIntent. */ + public Builder setMoneyServices(EmptyParam moneyServices) { + this.moneyServices = moneyServices; + return this; + } + /** * A unique value assigned by the business to identify the transaction. Required for L2 and L3 * rates. @@ -14581,6 +14603,175 @@ public Builder setType(EmptyParam type) { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Account funding transaction details including sender and beneficiary information. */ + @SerializedName("account_funding") + Object accountFunding; + + /** + * 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 type of money services transaction. */ + @SerializedName("transaction_type") + TransactionType transactionType; + + private MoneyServices( + Object accountFunding, Map extraParams, TransactionType transactionType) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + this.transactionType = transactionType; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object accountFunding; + + private Map extraParams; + + private TransactionType transactionType; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentDetails.MoneyServices build() { + return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices( + this.accountFunding, this.extraParams, this.transactionType); + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding accountFunding) { + this.accountFunding = accountFunding; + return this; + } + + /** Account funding transaction details including sender and beneficiary information. */ + public Builder setAccountFunding(EmptyParam accountFunding) { + this.accountFunding = accountFunding; + 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 PaymentIntentUpdateParams.PaymentDetails.MoneyServices#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 PaymentIntentUpdateParams.PaymentDetails.MoneyServices#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 type of money services transaction. */ + public Builder setTransactionType( + PaymentIntentUpdateParams.PaymentDetails.MoneyServices.TransactionType + transactionType) { + this.transactionType = transactionType; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding build() { + return new PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding( + 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 + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding#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 + * PaymentIntentUpdateParams.PaymentDetails.MoneyServices.AccountFunding#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } + + public enum TransactionType implements ApiRequestParams.EnumParam { + @SerializedName("account_funding") + ACCOUNT_FUNDING("account_funding"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TransactionType(String value) { + this.value = value; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class Subscription { @@ -26396,6 +26587,10 @@ public static class Card { @SerializedName("network") Network network; + /** Payment details for payment method specific funding fields. */ + @SerializedName("payment_details") + PaymentDetails paymentDetails; + /** * Request ability to decrement the @@ -26535,6 +26730,7 @@ private Card( MandateOptions mandateOptions, Boolean moto, Network network, + PaymentDetails paymentDetails, RequestDecrementalAuthorization requestDecrementalAuthorization, RequestExtendedAuthorization requestExtendedAuthorization, RequestIncrementalAuthorization requestIncrementalAuthorization, @@ -26556,6 +26752,7 @@ private Card( this.mandateOptions = mandateOptions; this.moto = moto; this.network = network; + this.paymentDetails = paymentDetails; this.requestDecrementalAuthorization = requestDecrementalAuthorization; this.requestExtendedAuthorization = requestExtendedAuthorization; this.requestIncrementalAuthorization = requestIncrementalAuthorization; @@ -26591,6 +26788,8 @@ public static class Builder { private Network network; + private PaymentDetails paymentDetails; + private RequestDecrementalAuthorization requestDecrementalAuthorization; private RequestExtendedAuthorization requestExtendedAuthorization; @@ -26629,6 +26828,7 @@ public PaymentIntentUpdateParams.PaymentMethodOptions.Card build() { this.mandateOptions, this.moto, this.network, + this.paymentDetails, this.requestDecrementalAuthorization, this.requestExtendedAuthorization, this.requestIncrementalAuthorization, @@ -26763,6 +26963,13 @@ public Builder setNetwork( return this; } + /** Payment details for payment method specific funding fields. */ + public Builder setPaymentDetails( + PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails paymentDetails) { + this.paymentDetails = paymentDetails; + return this; + } + /** * Request ability to decrement the @@ -27622,6 +27829,226 @@ public enum SupportedType implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaymentDetails { + /** + * 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; + + /** Money services details for payment method specific funding fields. */ + @SerializedName("money_services") + MoneyServices moneyServices; + + private PaymentDetails(Map extraParams, MoneyServices moneyServices) { + this.extraParams = extraParams; + this.moneyServices = moneyServices; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private MoneyServices moneyServices; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails( + this.extraParams, this.moneyServices); + } + + /** + * 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 + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails#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 + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Money services details for payment method specific funding fields. */ + public Builder setMoneyServices( + PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + moneyServices) { + this.moneyServices = moneyServices; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Payment method specific account funding transaction details. */ + @SerializedName("account_funding") + AccountFunding accountFunding; + + /** + * 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 MoneyServices(AccountFunding accountFunding, Map extraParams) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private AccountFunding accountFunding; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices(this.accountFunding, this.extraParams); + } + + /** Payment method specific account funding transaction details. */ + public Builder setAccountFunding( + PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices + .AccountFunding + accountFunding) { + this.accountFunding = accountFunding; + 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 + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices#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 + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices#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 + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails + .MoneyServices.AccountFunding(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 + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#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 + * PaymentIntentUpdateParams.PaymentMethodOptions.Card.PaymentDetails.MoneyServices.AccountFunding#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 @EqualsAndHashCode(callSuper = false) public static class StatementDetails { @@ -28754,6 +29181,10 @@ public static class CardPresent { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Payment details for payment method specific funding transaction fields. */ + @SerializedName("payment_details") + PaymentDetails paymentDetails; + /** * Request ability to capture this payment beyond the standard authorization @@ -28791,12 +29222,14 @@ public static class CardPresent { private CardPresent( CaptureMethod captureMethod, Map extraParams, + PaymentDetails paymentDetails, Boolean requestExtendedAuthorization, Boolean requestIncrementalAuthorizationSupport, RequestReauthorization requestReauthorization, Routing routing) { this.captureMethod = captureMethod; this.extraParams = extraParams; + this.paymentDetails = paymentDetails; this.requestExtendedAuthorization = requestExtendedAuthorization; this.requestIncrementalAuthorizationSupport = requestIncrementalAuthorizationSupport; this.requestReauthorization = requestReauthorization; @@ -28812,6 +29245,8 @@ public static class Builder { private Map extraParams; + private PaymentDetails paymentDetails; + private Boolean requestExtendedAuthorization; private Boolean requestIncrementalAuthorizationSupport; @@ -28825,6 +29260,7 @@ public PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent build() { return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent( this.captureMethod, this.extraParams, + this.paymentDetails, this.requestExtendedAuthorization, this.requestIncrementalAuthorizationSupport, this.requestReauthorization, @@ -28876,6 +29312,14 @@ public Builder putAllExtraParam(Map map) { return this; } + /** Payment details for payment method specific funding transaction fields. */ + public Builder setPaymentDetails( + PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + paymentDetails) { + this.paymentDetails = paymentDetails; + return this; + } + /** * Request ability to capture this payment beyond the standard authorization @@ -28923,6 +29367,228 @@ public Builder setRouting( } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaymentDetails { + /** + * 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; + + /** Money services details for payment method specific funding fields. */ + @SerializedName("money_services") + MoneyServices moneyServices; + + private PaymentDetails(Map extraParams, MoneyServices moneyServices) { + this.extraParams = extraParams; + this.moneyServices = moneyServices; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private MoneyServices moneyServices; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails( + this.extraParams, this.moneyServices); + } + + /** + * 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 + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails#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 + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Money services details for payment method specific funding fields. */ + public Builder setMoneyServices( + PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices + moneyServices) { + this.moneyServices = moneyServices; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class MoneyServices { + /** Payment method specific account funding transaction details. */ + @SerializedName("account_funding") + AccountFunding accountFunding; + + /** + * 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 MoneyServices(AccountFunding accountFunding, Map extraParams) { + this.accountFunding = accountFunding; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private AccountFunding accountFunding; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices(this.accountFunding, this.extraParams); + } + + /** Payment method specific account funding transaction details. */ + public Builder setAccountFunding( + PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding + accountFunding) { + this.accountFunding = accountFunding; + 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 + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices#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 + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices#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 + @EqualsAndHashCode(callSuper = false) + public static class AccountFunding { + /** + * 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 AccountFunding(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 PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding + build() { + return new PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails + .MoneyServices.AccountFunding(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 + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding#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 + * PaymentIntentUpdateParams.PaymentMethodOptions.CardPresent.PaymentDetails.MoneyServices.AccountFunding#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 @EqualsAndHashCode(callSuper = false) public static class Routing { diff --git a/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionConfirmParams.java b/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionConfirmParams.java index d4dbbe217ed..7e890cfb752 100644 --- a/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionConfirmParams.java +++ b/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionConfirmParams.java @@ -34,10 +34,6 @@ public class RequestedSessionConfirmParams extends ApiRequestParams { @SerializedName("payment_method") String paymentMethod; - /** The payment method data for this requested session. */ - @SerializedName("payment_method_data") - PaymentMethodData paymentMethodData; - /** Risk details/signals associated with the requested session. */ @SerializedName("risk_details") RiskDetails riskDetails; @@ -47,13 +43,11 @@ private RequestedSessionConfirmParams( List expand, Map extraParams, String paymentMethod, - PaymentMethodData paymentMethodData, RiskDetails riskDetails) { this.affiliateAttribution = affiliateAttribution; this.expand = expand; this.extraParams = extraParams; this.paymentMethod = paymentMethod; - this.paymentMethodData = paymentMethodData; this.riskDetails = riskDetails; } @@ -70,8 +64,6 @@ public static class Builder { private String paymentMethod; - private PaymentMethodData paymentMethodData; - private RiskDetails riskDetails; /** Finalize and obtain parameter instance from this builder. */ @@ -81,7 +73,6 @@ public RequestedSessionConfirmParams build() { this.expand, this.extraParams, this.paymentMethod, - this.paymentMethodData, this.riskDetails); } @@ -150,13 +141,6 @@ public Builder setPaymentMethod(String paymentMethod) { return this; } - /** The payment method data for this requested session. */ - public Builder setPaymentMethodData( - RequestedSessionConfirmParams.PaymentMethodData paymentMethodData) { - this.paymentMethodData = paymentMethodData; - return this; - } - /** Risk details/signals associated with the requested session. */ public Builder setRiskDetails(RequestedSessionConfirmParams.RiskDetails riskDetails) { this.riskDetails = riskDetails; @@ -553,513 +537,6 @@ public enum Touchpoint implements ApiRequestParams.EnumParam { } } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class PaymentMethodData { - /** The billing details for the payment method data. */ - @SerializedName("billing_details") - BillingDetails billingDetails; - - /** The card for the payment method data. */ - @SerializedName("card") - Card card; - - /** - * 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 type of the payment method data. */ - @SerializedName("type") - Type type; - - private PaymentMethodData( - BillingDetails billingDetails, Card card, Map extraParams, Type type) { - this.billingDetails = billingDetails; - this.card = card; - this.extraParams = extraParams; - this.type = type; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private BillingDetails billingDetails; - - private Card card; - - private Map extraParams; - - private Type type; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionConfirmParams.PaymentMethodData build() { - return new RequestedSessionConfirmParams.PaymentMethodData( - this.billingDetails, this.card, this.extraParams, this.type); - } - - /** The billing details for the payment method data. */ - public Builder setBillingDetails( - RequestedSessionConfirmParams.PaymentMethodData.BillingDetails billingDetails) { - this.billingDetails = billingDetails; - return this; - } - - /** The card for the payment method data. */ - public Builder setCard(RequestedSessionConfirmParams.PaymentMethodData.Card card) { - this.card = card; - 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 - * RequestedSessionConfirmParams.PaymentMethodData#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 RequestedSessionConfirmParams.PaymentMethodData#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 type of the payment method data. */ - public Builder setType(RequestedSessionConfirmParams.PaymentMethodData.Type type) { - this.type = type; - return this; - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class BillingDetails { - /** The address for the billing details. */ - @SerializedName("address") - Address address; - - /** The email for the billing details. */ - @SerializedName("email") - String 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; - - /** The name for the billing details. */ - @SerializedName("name") - String name; - - /** The phone for the billing details. */ - @SerializedName("phone") - String phone; - - private BillingDetails( - Address address, - String email, - Map extraParams, - String name, - String phone) { - this.address = address; - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Address address; - - private String email; - - private Map extraParams; - - private String name; - - private String phone; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionConfirmParams.PaymentMethodData.BillingDetails build() { - return new RequestedSessionConfirmParams.PaymentMethodData.BillingDetails( - this.address, this.email, this.extraParams, this.name, this.phone); - } - - /** The address for the billing details. */ - public Builder setAddress( - RequestedSessionConfirmParams.PaymentMethodData.BillingDetails.Address address) { - this.address = address; - return this; - } - - /** The email for the billing details. */ - public Builder setEmail(String 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 - * RequestedSessionConfirmParams.PaymentMethodData.BillingDetails#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 - * RequestedSessionConfirmParams.PaymentMethodData.BillingDetails#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 name for the billing details. */ - public Builder setName(String name) { - this.name = name; - return this; - } - - /** The phone for the billing details. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Address { - /** Required. City, district, suburb, town, or village. */ - @SerializedName("city") - String city; - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - @SerializedName("country") - String country; - - /** - * 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; - - /** Address line 1, such as the street, PO Box, or company name. */ - @SerializedName("line1") - String line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - String line2; - - /** Required. ZIP or postal code. */ - @SerializedName("postal_code") - String postalCode; - - /** - * Required. State, county, province, or region (ISO 3166-2). - */ - @SerializedName("state") - String state; - - private Address( - String city, - String country, - Map extraParams, - String line1, - String line2, - String postalCode, - String state) { - this.city = city; - this.country = country; - this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private String city; - - private String country; - - private Map extraParams; - - private String line1; - - private String line2; - - private String postalCode; - - private String state; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionConfirmParams.PaymentMethodData.BillingDetails.Address build() { - return new RequestedSessionConfirmParams.PaymentMethodData.BillingDetails.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - 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 - * RequestedSessionConfirmParams.PaymentMethodData.BillingDetails.Address#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 - * RequestedSessionConfirmParams.PaymentMethodData.BillingDetails.Address#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - - /** Address line 1, such as the street, PO Box, or company name. */ - public Builder setLine1(String line1) { - this.line1 = line1; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; - return this; - } - - /** Required. ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; - return this; - } - - /** - * Required. State, county, province, or region (ISO 3166-2). - */ - public Builder setState(String state) { - this.state = state; - return this; - } - } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Card { - /** The CVC of the card. */ - @SerializedName("cvc") - String cvc; - - /** Required. The expiration month of the card. */ - @SerializedName("exp_month") - Long expMonth; - - /** Required. The expiration year of the card. */ - @SerializedName("exp_year") - Long expYear; - - /** - * 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; - - /** Required. The number of the card. */ - @SerializedName("number") - String number; - - private Card( - String cvc, Long expMonth, Long expYear, Map extraParams, String number) { - this.cvc = cvc; - this.expMonth = expMonth; - this.expYear = expYear; - this.extraParams = extraParams; - this.number = number; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private String cvc; - - private Long expMonth; - - private Long expYear; - - private Map extraParams; - - private String number; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionConfirmParams.PaymentMethodData.Card build() { - return new RequestedSessionConfirmParams.PaymentMethodData.Card( - this.cvc, this.expMonth, this.expYear, this.extraParams, this.number); - } - - /** The CVC of the card. */ - public Builder setCvc(String cvc) { - this.cvc = cvc; - return this; - } - - /** Required. The expiration month of the card. */ - public Builder setExpMonth(Long expMonth) { - this.expMonth = expMonth; - return this; - } - - /** Required. The expiration year of the card. */ - public Builder setExpYear(Long expYear) { - this.expYear = expYear; - 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 RequestedSessionConfirmParams.PaymentMethodData.Card#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 RequestedSessionConfirmParams.PaymentMethodData.Card#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - - /** Required. The number of the card. */ - public Builder setNumber(String number) { - this.number = number; - return this; - } - } - } - - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("card") - CARD("card"); - - @Getter(onMethod_ = {@Override}) - private final String value; - - Type(String value) { - this.value = value; - } - } - } - @Getter @EqualsAndHashCode(callSuper = false) public static class RiskDetails { diff --git a/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionCreateParams.java b/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionCreateParams.java index 359e6d847ec..f73b846ace3 100644 --- a/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionCreateParams.java +++ b/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionCreateParams.java @@ -54,10 +54,6 @@ public class RequestedSessionCreateParams extends ApiRequestParams { @SerializedName("payment_method") String paymentMethod; - /** The payment method data for this requested session. */ - @SerializedName("payment_method_data") - PaymentMethodData paymentMethodData; - /** Required. The details of the seller. */ @SerializedName("seller_details") SellerDetails sellerDetails; @@ -80,7 +76,6 @@ private RequestedSessionCreateParams( List lineItemDetails, Map metadata, String paymentMethod, - PaymentMethodData paymentMethodData, SellerDetails sellerDetails, SetupFutureUsage setupFutureUsage, Map sharedMetadata) { @@ -93,7 +88,6 @@ private RequestedSessionCreateParams( this.lineItemDetails = lineItemDetails; this.metadata = metadata; this.paymentMethod = paymentMethod; - this.paymentMethodData = paymentMethodData; this.sellerDetails = sellerDetails; this.setupFutureUsage = setupFutureUsage; this.sharedMetadata = sharedMetadata; @@ -122,8 +116,6 @@ public static class Builder { private String paymentMethod; - private PaymentMethodData paymentMethodData; - private SellerDetails sellerDetails; private SetupFutureUsage setupFutureUsage; @@ -142,7 +134,6 @@ public RequestedSessionCreateParams build() { this.lineItemDetails, this.metadata, this.paymentMethod, - this.paymentMethodData, this.sellerDetails, this.setupFutureUsage, this.sharedMetadata); @@ -285,13 +276,6 @@ public Builder setPaymentMethod(String paymentMethod) { return this; } - /** The payment method data for this requested session. */ - public Builder setPaymentMethodData( - RequestedSessionCreateParams.PaymentMethodData paymentMethodData) { - this.paymentMethodData = paymentMethodData; - return this; - } - /** Required. The details of the seller. */ public Builder setSellerDetails(RequestedSessionCreateParams.SellerDetails sellerDetails) { this.sellerDetails = sellerDetails; @@ -1076,513 +1060,6 @@ public Builder setSkuId(String skuId) { } } - @Getter - @EqualsAndHashCode(callSuper = false) - public static class PaymentMethodData { - /** The billing details for the payment method data. */ - @SerializedName("billing_details") - BillingDetails billingDetails; - - /** The card for the payment method data. */ - @SerializedName("card") - Card card; - - /** - * 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 type of the payment method data. */ - @SerializedName("type") - Type type; - - private PaymentMethodData( - BillingDetails billingDetails, Card card, Map extraParams, Type type) { - this.billingDetails = billingDetails; - this.card = card; - this.extraParams = extraParams; - this.type = type; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private BillingDetails billingDetails; - - private Card card; - - private Map extraParams; - - private Type type; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionCreateParams.PaymentMethodData build() { - return new RequestedSessionCreateParams.PaymentMethodData( - this.billingDetails, this.card, this.extraParams, this.type); - } - - /** The billing details for the payment method data. */ - public Builder setBillingDetails( - RequestedSessionCreateParams.PaymentMethodData.BillingDetails billingDetails) { - this.billingDetails = billingDetails; - return this; - } - - /** The card for the payment method data. */ - public Builder setCard(RequestedSessionCreateParams.PaymentMethodData.Card card) { - this.card = card; - 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 - * RequestedSessionCreateParams.PaymentMethodData#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 RequestedSessionCreateParams.PaymentMethodData#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 type of the payment method data. */ - public Builder setType(RequestedSessionCreateParams.PaymentMethodData.Type type) { - this.type = type; - return this; - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class BillingDetails { - /** The address for the billing details. */ - @SerializedName("address") - Address address; - - /** The email for the billing details. */ - @SerializedName("email") - String 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; - - /** The name for the billing details. */ - @SerializedName("name") - String name; - - /** The phone for the billing details. */ - @SerializedName("phone") - String phone; - - private BillingDetails( - Address address, - String email, - Map extraParams, - String name, - String phone) { - this.address = address; - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Address address; - - private String email; - - private Map extraParams; - - private String name; - - private String phone; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionCreateParams.PaymentMethodData.BillingDetails build() { - return new RequestedSessionCreateParams.PaymentMethodData.BillingDetails( - this.address, this.email, this.extraParams, this.name, this.phone); - } - - /** The address for the billing details. */ - public Builder setAddress( - RequestedSessionCreateParams.PaymentMethodData.BillingDetails.Address address) { - this.address = address; - return this; - } - - /** The email for the billing details. */ - public Builder setEmail(String 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 - * RequestedSessionCreateParams.PaymentMethodData.BillingDetails#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 - * RequestedSessionCreateParams.PaymentMethodData.BillingDetails#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 name for the billing details. */ - public Builder setName(String name) { - this.name = name; - return this; - } - - /** The phone for the billing details. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Address { - /** Required. City, district, suburb, town, or village. */ - @SerializedName("city") - String city; - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - @SerializedName("country") - String country; - - /** - * 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; - - /** Address line 1, such as the street, PO Box, or company name. */ - @SerializedName("line1") - String line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - String line2; - - /** Required. ZIP or postal code. */ - @SerializedName("postal_code") - String postalCode; - - /** - * Required. State, county, province, or region (ISO 3166-2). - */ - @SerializedName("state") - String state; - - private Address( - String city, - String country, - Map extraParams, - String line1, - String line2, - String postalCode, - String state) { - this.city = city; - this.country = country; - this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private String city; - - private String country; - - private Map extraParams; - - private String line1; - - private String line2; - - private String postalCode; - - private String state; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionCreateParams.PaymentMethodData.BillingDetails.Address build() { - return new RequestedSessionCreateParams.PaymentMethodData.BillingDetails.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - 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 - * RequestedSessionCreateParams.PaymentMethodData.BillingDetails.Address#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 - * RequestedSessionCreateParams.PaymentMethodData.BillingDetails.Address#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - - /** Address line 1, such as the street, PO Box, or company name. */ - public Builder setLine1(String line1) { - this.line1 = line1; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; - return this; - } - - /** Required. ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; - return this; - } - - /** - * Required. State, county, province, or region (ISO 3166-2). - */ - public Builder setState(String state) { - this.state = state; - return this; - } - } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Card { - /** The CVC of the card. */ - @SerializedName("cvc") - String cvc; - - /** Required. The expiration month of the card. */ - @SerializedName("exp_month") - Long expMonth; - - /** Required. The expiration year of the card. */ - @SerializedName("exp_year") - Long expYear; - - /** - * 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; - - /** Required. The number of the card. */ - @SerializedName("number") - String number; - - private Card( - String cvc, Long expMonth, Long expYear, Map extraParams, String number) { - this.cvc = cvc; - this.expMonth = expMonth; - this.expYear = expYear; - this.extraParams = extraParams; - this.number = number; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private String cvc; - - private Long expMonth; - - private Long expYear; - - private Map extraParams; - - private String number; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionCreateParams.PaymentMethodData.Card build() { - return new RequestedSessionCreateParams.PaymentMethodData.Card( - this.cvc, this.expMonth, this.expYear, this.extraParams, this.number); - } - - /** The CVC of the card. */ - public Builder setCvc(String cvc) { - this.cvc = cvc; - return this; - } - - /** Required. The expiration month of the card. */ - public Builder setExpMonth(Long expMonth) { - this.expMonth = expMonth; - return this; - } - - /** Required. The expiration year of the card. */ - public Builder setExpYear(Long expYear) { - this.expYear = expYear; - 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 RequestedSessionCreateParams.PaymentMethodData.Card#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 RequestedSessionCreateParams.PaymentMethodData.Card#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - - /** Required. The number of the card. */ - public Builder setNumber(String number) { - this.number = number; - return this; - } - } - } - - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("card") - CARD("card"); - - @Getter(onMethod_ = {@Override}) - private final String value; - - Type(String value) { - this.value = value; - } - } - } - @Getter @EqualsAndHashCode(callSuper = false) public static class SellerDetails { diff --git a/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionUpdateParams.java b/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionUpdateParams.java index 5210cf9fe65..1dd81b734dc 100644 --- a/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionUpdateParams.java +++ b/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionUpdateParams.java @@ -43,10 +43,6 @@ public class RequestedSessionUpdateParams extends ApiRequestParams { @SerializedName("payment_method") Object paymentMethod; - /** The payment method data for this requested session. */ - @SerializedName("payment_method_data") - Object paymentMethodData; - /** The shared metadata for this requested session. */ @SerializedName("shared_metadata") Object sharedMetadata; @@ -58,7 +54,6 @@ private RequestedSessionUpdateParams( List lineItemDetails, Object metadata, Object paymentMethod, - Object paymentMethodData, Object sharedMetadata) { this.expand = expand; this.extraParams = extraParams; @@ -66,7 +61,6 @@ private RequestedSessionUpdateParams( this.lineItemDetails = lineItemDetails; this.metadata = metadata; this.paymentMethod = paymentMethod; - this.paymentMethodData = paymentMethodData; this.sharedMetadata = sharedMetadata; } @@ -87,8 +81,6 @@ public static class Builder { private Object paymentMethod; - private Object paymentMethodData; - private Object sharedMetadata; /** Finalize and obtain parameter instance from this builder. */ @@ -100,7 +92,6 @@ public RequestedSessionUpdateParams build() { this.lineItemDetails, this.metadata, this.paymentMethod, - this.paymentMethodData, this.sharedMetadata); } @@ -242,19 +233,6 @@ public Builder setPaymentMethod(EmptyParam paymentMethod) { return this; } - /** The payment method data for this requested session. */ - public Builder setPaymentMethodData( - RequestedSessionUpdateParams.PaymentMethodData paymentMethodData) { - this.paymentMethodData = paymentMethodData; - return this; - } - - /** The payment method data for this requested session. */ - public Builder setPaymentMethodData(EmptyParam paymentMethodData) { - this.paymentMethodData = paymentMethodData; - return this; - } - /** * Add a key/value pair to `sharedMetadata` 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 @@ -1388,583 +1366,4 @@ public Builder setQuantity(Long quantity) { } } } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class PaymentMethodData { - /** The billing details for the payment method data. */ - @SerializedName("billing_details") - BillingDetails billingDetails; - - /** The card for the payment method data. */ - @SerializedName("card") - Card card; - - /** - * 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 type of the payment method data. */ - @SerializedName("type") - Type type; - - private PaymentMethodData( - BillingDetails billingDetails, Card card, Map extraParams, Type type) { - this.billingDetails = billingDetails; - this.card = card; - this.extraParams = extraParams; - this.type = type; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private BillingDetails billingDetails; - - private Card card; - - private Map extraParams; - - private Type type; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionUpdateParams.PaymentMethodData build() { - return new RequestedSessionUpdateParams.PaymentMethodData( - this.billingDetails, this.card, this.extraParams, this.type); - } - - /** The billing details for the payment method data. */ - public Builder setBillingDetails( - RequestedSessionUpdateParams.PaymentMethodData.BillingDetails billingDetails) { - this.billingDetails = billingDetails; - return this; - } - - /** The card for the payment method data. */ - public Builder setCard(RequestedSessionUpdateParams.PaymentMethodData.Card card) { - this.card = card; - 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 - * RequestedSessionUpdateParams.PaymentMethodData#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 RequestedSessionUpdateParams.PaymentMethodData#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 type of the payment method data. */ - public Builder setType(RequestedSessionUpdateParams.PaymentMethodData.Type type) { - this.type = type; - return this; - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class BillingDetails { - /** The address for the billing details. */ - @SerializedName("address") - Address address; - - /** The email for the billing details. */ - @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 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 name for the billing details. */ - @SerializedName("name") - Object name; - - /** The phone for the billing details. */ - @SerializedName("phone") - Object phone; - - private BillingDetails( - Address address, - Object email, - Map extraParams, - Object name, - Object phone) { - this.address = address; - this.email = email; - this.extraParams = extraParams; - this.name = name; - this.phone = phone; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Address address; - - private Object email; - - private Map extraParams; - - private Object name; - - private Object phone; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionUpdateParams.PaymentMethodData.BillingDetails build() { - return new RequestedSessionUpdateParams.PaymentMethodData.BillingDetails( - this.address, this.email, this.extraParams, this.name, this.phone); - } - - /** The address for the billing details. */ - public Builder setAddress( - RequestedSessionUpdateParams.PaymentMethodData.BillingDetails.Address address) { - this.address = address; - return this; - } - - /** The email for the billing details. */ - public Builder setEmail(String email) { - this.email = email; - return this; - } - - /** The email for the billing details. */ - 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 - * RequestedSessionUpdateParams.PaymentMethodData.BillingDetails#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 - * RequestedSessionUpdateParams.PaymentMethodData.BillingDetails#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 name for the billing details. */ - public Builder setName(String name) { - this.name = name; - return this; - } - - /** The name for the billing details. */ - public Builder setName(EmptyParam name) { - this.name = name; - return this; - } - - /** The phone for the billing details. */ - public Builder setPhone(String phone) { - this.phone = phone; - return this; - } - - /** The phone for the billing details. */ - public Builder setPhone(EmptyParam phone) { - this.phone = phone; - return this; - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Address { - /** Required. City, district, suburb, town, or village. */ - @SerializedName("city") - Object city; - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - @SerializedName("country") - Object country; - - /** - * 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; - - /** Address line 1, such as the street, PO Box, or company name. */ - @SerializedName("line1") - Object line1; - - /** Address line 2, such as the apartment, suite, unit, or building. */ - @SerializedName("line2") - Object line2; - - /** Required. ZIP or postal code. */ - @SerializedName("postal_code") - Object postalCode; - - /** - * Required. State, county, province, or region (ISO 3166-2). - */ - @SerializedName("state") - Object state; - - private Address( - Object city, - Object country, - Map extraParams, - Object line1, - Object line2, - Object postalCode, - Object state) { - this.city = city; - this.country = country; - this.extraParams = extraParams; - this.line1 = line1; - this.line2 = line2; - this.postalCode = postalCode; - this.state = state; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Object city; - - private Object country; - - private Map extraParams; - - private Object line1; - - private Object line2; - - private Object postalCode; - - private Object state; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionUpdateParams.PaymentMethodData.BillingDetails.Address build() { - return new RequestedSessionUpdateParams.PaymentMethodData.BillingDetails.Address( - this.city, - this.country, - this.extraParams, - this.line1, - this.line2, - this.postalCode, - this.state); - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(String city) { - this.city = city; - return this; - } - - /** Required. City, district, suburb, town, or village. */ - public Builder setCity(EmptyParam city) { - this.city = city; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(String country) { - this.country = country; - return this; - } - - /** - * Required. Two-letter country code (ISO 3166-1 alpha-2). - */ - public Builder setCountry(EmptyParam country) { - this.country = country; - 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 - * RequestedSessionUpdateParams.PaymentMethodData.BillingDetails.Address#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 - * RequestedSessionUpdateParams.PaymentMethodData.BillingDetails.Address#extraParams} for - * the field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - - /** Address line 1, such as the street, PO Box, or company name. */ - public Builder setLine1(String line1) { - this.line1 = line1; - return this; - } - - /** Address line 1, such as the street, PO Box, or company name. */ - public Builder setLine1(EmptyParam line1) { - this.line1 = line1; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(String line2) { - this.line2 = line2; - return this; - } - - /** Address line 2, such as the apartment, suite, unit, or building. */ - public Builder setLine2(EmptyParam line2) { - this.line2 = line2; - return this; - } - - /** Required. ZIP or postal code. */ - public Builder setPostalCode(String postalCode) { - this.postalCode = postalCode; - return this; - } - - /** Required. ZIP or postal code. */ - public Builder setPostalCode(EmptyParam postalCode) { - this.postalCode = postalCode; - return this; - } - - /** - * Required. State, county, province, or region (ISO 3166-2). - */ - public Builder setState(String state) { - this.state = state; - return this; - } - - /** - * Required. State, county, province, or region (ISO 3166-2). - */ - public Builder setState(EmptyParam state) { - this.state = state; - return this; - } - } - } - } - - @Getter - @EqualsAndHashCode(callSuper = false) - public static class Card { - /** The CVC of the card. */ - @SerializedName("cvc") - Object cvc; - - /** Required. The expiration month of the card. */ - @SerializedName("exp_month") - Long expMonth; - - /** Required. The expiration year of the card. */ - @SerializedName("exp_year") - Long expYear; - - /** - * 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; - - /** Required. The number of the card. */ - @SerializedName("number") - Object number; - - private Card( - Object cvc, Long expMonth, Long expYear, Map extraParams, Object number) { - this.cvc = cvc; - this.expMonth = expMonth; - this.expYear = expYear; - this.extraParams = extraParams; - this.number = number; - } - - public static Builder builder() { - return new Builder(); - } - - public static class Builder { - private Object cvc; - - private Long expMonth; - - private Long expYear; - - private Map extraParams; - - private Object number; - - /** Finalize and obtain parameter instance from this builder. */ - public RequestedSessionUpdateParams.PaymentMethodData.Card build() { - return new RequestedSessionUpdateParams.PaymentMethodData.Card( - this.cvc, this.expMonth, this.expYear, this.extraParams, this.number); - } - - /** The CVC of the card. */ - public Builder setCvc(String cvc) { - this.cvc = cvc; - return this; - } - - /** The CVC of the card. */ - public Builder setCvc(EmptyParam cvc) { - this.cvc = cvc; - return this; - } - - /** Required. The expiration month of the card. */ - public Builder setExpMonth(Long expMonth) { - this.expMonth = expMonth; - return this; - } - - /** Required. The expiration year of the card. */ - public Builder setExpYear(Long expYear) { - this.expYear = expYear; - 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 RequestedSessionUpdateParams.PaymentMethodData.Card#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 RequestedSessionUpdateParams.PaymentMethodData.Card#extraParams} for the - * field documentation. - */ - public Builder putAllExtraParam(Map map) { - if (this.extraParams == null) { - this.extraParams = new HashMap<>(); - } - this.extraParams.putAll(map); - return this; - } - - /** Required. The number of the card. */ - public Builder setNumber(String number) { - this.number = number; - return this; - } - - /** Required. The number of the card. */ - public Builder setNumber(EmptyParam number) { - this.number = number; - return this; - } - } - } - - public enum Type implements ApiRequestParams.EnumParam { - @SerializedName("card") - CARD("card"); - - @Getter(onMethod_ = {@Override}) - private final String value; - - Type(String value) { - this.value = value; - } - } - } } diff --git a/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java b/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java index 284a997f7fe..3a445207e0b 100644 --- a/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java +++ b/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java @@ -10081,6 +10081,10 @@ public static class Capabilities { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Capabilities that enable OutboundPayments via paper check. */ + @SerializedName("paper_checks") + PaperChecks paperChecks; + /** Capabilities that enable the recipient to manage their Stripe Balance (/v1/balance). */ @SerializedName("stripe_balance") StripeBalance stripeBalance; @@ -10090,11 +10094,13 @@ private Capabilities( Cards cards, CryptoWallets cryptoWallets, Map extraParams, + PaperChecks paperChecks, StripeBalance stripeBalance) { this.bankAccounts = bankAccounts; this.cards = cards; this.cryptoWallets = cryptoWallets; this.extraParams = extraParams; + this.paperChecks = paperChecks; this.stripeBalance = stripeBalance; } @@ -10111,6 +10117,8 @@ public static class Builder { private Map extraParams; + private PaperChecks paperChecks; + private StripeBalance stripeBalance; /** Finalize and obtain parameter instance from this builder. */ @@ -10120,6 +10128,7 @@ public AccountCreateParams.Configuration.Recipient.Capabilities build() { this.cards, this.cryptoWallets, this.extraParams, + this.paperChecks, this.stripeBalance); } @@ -10175,6 +10184,13 @@ public Builder putAllExtraParam(Map map) { return this; } + /** Capabilities that enable OutboundPayments via paper check. */ + public Builder setPaperChecks( + AccountCreateParams.Configuration.Recipient.Capabilities.PaperChecks paperChecks) { + this.paperChecks = paperChecks; + return this; + } + /** * Capabilities that enable the recipient to manage their Stripe Balance (/v1/balance). */ @@ -10723,6 +10739,87 @@ public Builder setRequested(Boolean requested) { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaperChecks { + /** + * 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; + + /** + * Required. To request a new Capability for an account, pass true. There + * can be a delay before the requested Capability becomes active. + */ + @SerializedName("requested") + Boolean requested; + + private PaperChecks(Map extraParams, Boolean requested) { + this.extraParams = extraParams; + this.requested = requested; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Boolean requested; + + /** Finalize and obtain parameter instance from this builder. */ + public AccountCreateParams.Configuration.Recipient.Capabilities.PaperChecks build() { + return new AccountCreateParams.Configuration.Recipient.Capabilities.PaperChecks( + this.extraParams, this.requested); + } + + /** + * 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 + * AccountCreateParams.Configuration.Recipient.Capabilities.PaperChecks#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 + * AccountCreateParams.Configuration.Recipient.Capabilities.PaperChecks#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. To request a new Capability for an account, pass true. + * There can be a delay before the requested Capability becomes active. + */ + public Builder setRequested(Boolean requested) { + this.requested = requested; + return this; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class StripeBalance { @@ -12457,17 +12554,23 @@ public static class OutboundPayments { @SerializedName("financial_accounts") FinancialAccounts financialAccounts; + /** Can send funds from a FinancialAccount to someone else via paper check. */ + @SerializedName("paper_checks") + PaperChecks paperChecks; + private OutboundPayments( BankAccounts bankAccounts, Cards cards, CryptoWallets cryptoWallets, Map extraParams, - FinancialAccounts financialAccounts) { + FinancialAccounts financialAccounts, + PaperChecks paperChecks) { this.bankAccounts = bankAccounts; this.cards = cards; this.cryptoWallets = cryptoWallets; this.extraParams = extraParams; this.financialAccounts = financialAccounts; + this.paperChecks = paperChecks; } public static Builder builder() { @@ -12485,6 +12588,8 @@ public static class Builder { private FinancialAccounts financialAccounts; + private PaperChecks paperChecks; + /** Finalize and obtain parameter instance from this builder. */ public AccountCreateParams.Configuration.Storer.Capabilities.OutboundPayments build() { return new AccountCreateParams.Configuration.Storer.Capabilities.OutboundPayments( @@ -12492,7 +12597,8 @@ public AccountCreateParams.Configuration.Storer.Capabilities.OutboundPayments bu this.cards, this.cryptoWallets, this.extraParams, - this.financialAccounts); + this.financialAccounts, + this.paperChecks); } /** Can send funds from a FinancialAccount to a bank account owned by someone else. */ @@ -12560,6 +12666,14 @@ public Builder setFinancialAccounts( this.financialAccounts = financialAccounts; return this; } + + /** Can send funds from a FinancialAccount to someone else via paper check. */ + public Builder setPaperChecks( + AccountCreateParams.Configuration.Storer.Capabilities.OutboundPayments.PaperChecks + paperChecks) { + this.paperChecks = paperChecks; + return this; + } } @Getter @@ -12892,6 +13006,89 @@ public Builder setRequested(Boolean requested) { } } } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaperChecks { + /** + * 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; + + /** + * Required. To request a new Capability for an account, pass true. + * There can be a delay before the requested Capability becomes active. + */ + @SerializedName("requested") + Boolean requested; + + private PaperChecks(Map extraParams, Boolean requested) { + this.extraParams = extraParams; + this.requested = requested; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Boolean requested; + + /** Finalize and obtain parameter instance from this builder. */ + public AccountCreateParams.Configuration.Storer.Capabilities.OutboundPayments + .PaperChecks + build() { + return new AccountCreateParams.Configuration.Storer.Capabilities.OutboundPayments + .PaperChecks(this.extraParams, this.requested); + } + + /** + * 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 + * AccountCreateParams.Configuration.Storer.Capabilities.OutboundPayments.PaperChecks#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 + * AccountCreateParams.Configuration.Storer.Capabilities.OutboundPayments.PaperChecks#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. To request a new Capability for an account, pass true. + * There can be a delay before the requested Capability becomes active. + */ + public Builder setRequested(Boolean requested) { + this.requested = requested; + return this; + } + } + } } @Getter diff --git a/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java b/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java index cbccdcff131..97443bedc14 100644 --- a/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java +++ b/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java @@ -10654,6 +10654,10 @@ public static class Capabilities { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** Capabilities that enable OutboundPayments via paper check. */ + @SerializedName("paper_checks") + PaperChecks paperChecks; + /** Capabilities that enable the recipient to manage their Stripe Balance (/v1/balance). */ @SerializedName("stripe_balance") StripeBalance stripeBalance; @@ -10663,11 +10667,13 @@ private Capabilities( Cards cards, CryptoWallets cryptoWallets, Map extraParams, + PaperChecks paperChecks, StripeBalance stripeBalance) { this.bankAccounts = bankAccounts; this.cards = cards; this.cryptoWallets = cryptoWallets; this.extraParams = extraParams; + this.paperChecks = paperChecks; this.stripeBalance = stripeBalance; } @@ -10684,6 +10690,8 @@ public static class Builder { private Map extraParams; + private PaperChecks paperChecks; + private StripeBalance stripeBalance; /** Finalize and obtain parameter instance from this builder. */ @@ -10693,6 +10701,7 @@ public AccountUpdateParams.Configuration.Recipient.Capabilities build() { this.cards, this.cryptoWallets, this.extraParams, + this.paperChecks, this.stripeBalance); } @@ -10748,6 +10757,13 @@ public Builder putAllExtraParam(Map map) { return this; } + /** Capabilities that enable OutboundPayments via paper check. */ + public Builder setPaperChecks( + AccountUpdateParams.Configuration.Recipient.Capabilities.PaperChecks paperChecks) { + this.paperChecks = paperChecks; + return this; + } + /** * Capabilities that enable the recipient to manage their Stripe Balance (/v1/balance). */ @@ -11296,6 +11312,87 @@ public Builder setRequested(Boolean requested) { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaperChecks { + /** + * 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; + + /** + * To request a new Capability for an account, pass true. There can be a delay before the + * requested Capability becomes active. + */ + @SerializedName("requested") + Boolean requested; + + private PaperChecks(Map extraParams, Boolean requested) { + this.extraParams = extraParams; + this.requested = requested; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Boolean requested; + + /** Finalize and obtain parameter instance from this builder. */ + public AccountUpdateParams.Configuration.Recipient.Capabilities.PaperChecks build() { + return new AccountUpdateParams.Configuration.Recipient.Capabilities.PaperChecks( + this.extraParams, this.requested); + } + + /** + * 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 + * AccountUpdateParams.Configuration.Recipient.Capabilities.PaperChecks#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 + * AccountUpdateParams.Configuration.Recipient.Capabilities.PaperChecks#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * To request a new Capability for an account, pass true. There can be a delay before + * the requested Capability becomes active. + */ + public Builder setRequested(Boolean requested) { + this.requested = requested; + return this; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class StripeBalance { @@ -13075,17 +13172,23 @@ public static class OutboundPayments { @SerializedName("financial_accounts") FinancialAccounts financialAccounts; + /** Can send funds from a FinancialAccount to someone else via paper check. */ + @SerializedName("paper_checks") + PaperChecks paperChecks; + private OutboundPayments( BankAccounts bankAccounts, Cards cards, CryptoWallets cryptoWallets, Map extraParams, - FinancialAccounts financialAccounts) { + FinancialAccounts financialAccounts, + PaperChecks paperChecks) { this.bankAccounts = bankAccounts; this.cards = cards; this.cryptoWallets = cryptoWallets; this.extraParams = extraParams; this.financialAccounts = financialAccounts; + this.paperChecks = paperChecks; } public static Builder builder() { @@ -13103,6 +13206,8 @@ public static class Builder { private FinancialAccounts financialAccounts; + private PaperChecks paperChecks; + /** Finalize and obtain parameter instance from this builder. */ public AccountUpdateParams.Configuration.Storer.Capabilities.OutboundPayments build() { return new AccountUpdateParams.Configuration.Storer.Capabilities.OutboundPayments( @@ -13110,7 +13215,8 @@ public AccountUpdateParams.Configuration.Storer.Capabilities.OutboundPayments bu this.cards, this.cryptoWallets, this.extraParams, - this.financialAccounts); + this.financialAccounts, + this.paperChecks); } /** Can send funds from a FinancialAccount to a bank account owned by someone else. */ @@ -13178,6 +13284,14 @@ public Builder setFinancialAccounts( this.financialAccounts = financialAccounts; return this; } + + /** Can send funds from a FinancialAccount to someone else via paper check. */ + public Builder setPaperChecks( + AccountUpdateParams.Configuration.Storer.Capabilities.OutboundPayments.PaperChecks + paperChecks) { + this.paperChecks = paperChecks; + return this; + } } @Getter @@ -13510,6 +13624,89 @@ public Builder setRequested(Boolean requested) { } } } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaperChecks { + /** + * 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; + + /** + * To request a new Capability for an account, pass true. There can be a delay before + * the requested Capability becomes active. + */ + @SerializedName("requested") + Boolean requested; + + private PaperChecks(Map extraParams, Boolean requested) { + this.extraParams = extraParams; + this.requested = requested; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private Boolean requested; + + /** Finalize and obtain parameter instance from this builder. */ + public AccountUpdateParams.Configuration.Storer.Capabilities.OutboundPayments + .PaperChecks + build() { + return new AccountUpdateParams.Configuration.Storer.Capabilities.OutboundPayments + .PaperChecks(this.extraParams, this.requested); + } + + /** + * 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 + * AccountUpdateParams.Configuration.Storer.Capabilities.OutboundPayments.PaperChecks#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 + * AccountUpdateParams.Configuration.Storer.Capabilities.OutboundPayments.PaperChecks#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * To request a new Capability for an account, pass true. There can be a delay before + * the requested Capability becomes active. + */ + public Builder setRequested(Boolean requested) { + this.requested = requested; + return this; + } + } + } } @Getter diff --git a/src/main/java/com/stripe/param/v2/core/BatchJobCreateParams.java b/src/main/java/com/stripe/param/v2/core/BatchJobCreateParams.java index 518846968df..7e66ea6a2ac 100644 --- a/src/main/java/com/stripe/param/v2/core/BatchJobCreateParams.java +++ b/src/main/java/com/stripe/param/v2/core/BatchJobCreateParams.java @@ -31,7 +31,7 @@ public class BatchJobCreateParams extends ApiRequestParams { @SerializedName("maximum_rps") Long maximumRps; - /** Required. The metadata of the {@code BatchJob} object. */ + /** Required. The metadata of the {@code batch_job}. */ @SerializedName("metadata") Map metadata; diff --git a/src/main/java/com/stripe/param/v2/data/reporting/QueryRunCreateParams.java b/src/main/java/com/stripe/param/v2/data/reporting/QueryRunCreateParams.java new file mode 100644 index 00000000000..718ac58a53f --- /dev/null +++ b/src/main/java/com/stripe/param/v2/data/reporting/QueryRunCreateParams.java @@ -0,0 +1,167 @@ +// File generated from our OpenAPI spec +package com.stripe.param.v2.data.reporting; + +import com.google.gson.annotations.SerializedName; +import com.stripe.net.ApiRequestParams; +import java.util.HashMap; +import java.util.Map; +import lombok.EqualsAndHashCode; +import lombok.Getter; + +@Getter +@EqualsAndHashCode(callSuper = false) +public class QueryRunCreateParams extends ApiRequestParams { + /** + * 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; + + /** Optional settings to customize the results of the {@code QueryRun}. */ + @SerializedName("result_options") + ResultOptions resultOptions; + + /** Required. The SQL to execute. */ + @SerializedName("sql") + String sql; + + private QueryRunCreateParams( + Map extraParams, ResultOptions resultOptions, String sql) { + this.extraParams = extraParams; + this.resultOptions = resultOptions; + this.sql = sql; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private ResultOptions resultOptions; + + private String sql; + + /** Finalize and obtain parameter instance from this builder. */ + public QueryRunCreateParams build() { + return new QueryRunCreateParams(this.extraParams, this.resultOptions, this.sql); + } + + /** + * 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 + * QueryRunCreateParams#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 QueryRunCreateParams#extraParams} for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** Optional settings to customize the results of the {@code QueryRun}. */ + public Builder setResultOptions(QueryRunCreateParams.ResultOptions resultOptions) { + this.resultOptions = resultOptions; + return this; + } + + /** Required. The SQL to execute. */ + public Builder setSql(String sql) { + this.sql = sql; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ResultOptions { + /** + * If set, the generated results file will be compressed into a ZIP folder. This is useful for + * reducing file size and download time for large results. + */ + @SerializedName("compress_file") + Boolean compressFile; + + /** + * 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 ResultOptions(Boolean compressFile, Map extraParams) { + this.compressFile = compressFile; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Boolean compressFile; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public QueryRunCreateParams.ResultOptions build() { + return new QueryRunCreateParams.ResultOptions(this.compressFile, this.extraParams); + } + + /** + * If set, the generated results file will be compressed into a ZIP folder. This is useful for + * reducing file size and download time for large results. + */ + public Builder setCompressFile(Boolean compressFile) { + this.compressFile = compressFile; + 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 + * QueryRunCreateParams.ResultOptions#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 QueryRunCreateParams.ResultOptions#extraParams} for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + } +} diff --git a/src/main/java/com/stripe/param/v2/reporting/ReportRunCreateParams.java b/src/main/java/com/stripe/param/v2/reporting/ReportRunCreateParams.java index c91ef7c0b45..11ca86e83f1 100644 --- a/src/main/java/com/stripe/param/v2/reporting/ReportRunCreateParams.java +++ b/src/main/java/com/stripe/param/v2/reporting/ReportRunCreateParams.java @@ -134,8 +134,8 @@ public Builder setResultOptions(ReportRunCreateParams.ResultOptions resultOption @EqualsAndHashCode(callSuper = false) public static class ResultOptions { /** - * If set, the generated report file will be compressed into a ZIP folder. This is useful for - * reducing file size and download time for large reports. + * If set, the generated results file will be compressed into a ZIP folder. This is useful for + * reducing file size and download time for large results. */ @SerializedName("compress_file") Boolean compressFile; @@ -169,8 +169,8 @@ public ReportRunCreateParams.ResultOptions build() { } /** - * If set, the generated report file will be compressed into a ZIP folder. This is useful for - * reducing file size and download time for large reports. + * If set, the generated results file will be compressed into a ZIP folder. This is useful for + * reducing file size and download time for large results. */ public Builder setCompressFile(Boolean compressFile) { this.compressFile = compressFile; diff --git a/src/main/java/com/stripe/service/V2Services.java b/src/main/java/com/stripe/service/V2Services.java index f7557e710b3..70c96d016b0 100644 --- a/src/main/java/com/stripe/service/V2Services.java +++ b/src/main/java/com/stripe/service/V2Services.java @@ -17,6 +17,10 @@ public com.stripe.service.v2.CoreService core() { return new com.stripe.service.v2.CoreService(this.getResponseGetter()); } + public com.stripe.service.v2.DatumService data() { + return new com.stripe.service.v2.DatumService(this.getResponseGetter()); + } + public com.stripe.service.v2.IamService iam() { return new com.stripe.service.v2.IamService(this.getResponseGetter()); } diff --git a/src/main/java/com/stripe/service/v2/DatumService.java b/src/main/java/com/stripe/service/v2/DatumService.java new file mode 100644 index 00000000000..a8199e24c3b --- /dev/null +++ b/src/main/java/com/stripe/service/v2/DatumService.java @@ -0,0 +1,15 @@ +// File generated from our OpenAPI spec +package com.stripe.service.v2; + +import com.stripe.net.ApiService; +import com.stripe.net.StripeResponseGetter; + +public final class DatumService extends ApiService { + public DatumService(StripeResponseGetter responseGetter) { + super(responseGetter); + } + + public com.stripe.service.v2.data.ReportingService reporting() { + return new com.stripe.service.v2.data.ReportingService(this.getResponseGetter()); + } +} diff --git a/src/main/java/com/stripe/service/v2/data/ReportingService.java b/src/main/java/com/stripe/service/v2/data/ReportingService.java new file mode 100644 index 00000000000..db6a321d413 --- /dev/null +++ b/src/main/java/com/stripe/service/v2/data/ReportingService.java @@ -0,0 +1,15 @@ +// File generated from our OpenAPI spec +package com.stripe.service.v2.data; + +import com.stripe.net.ApiService; +import com.stripe.net.StripeResponseGetter; + +public final class ReportingService extends ApiService { + public ReportingService(StripeResponseGetter responseGetter) { + super(responseGetter); + } + + public com.stripe.service.v2.data.reporting.QueryRunService queryRuns() { + return new com.stripe.service.v2.data.reporting.QueryRunService(this.getResponseGetter()); + } +} diff --git a/src/main/java/com/stripe/service/v2/data/reporting/QueryRunService.java b/src/main/java/com/stripe/service/v2/data/reporting/QueryRunService.java new file mode 100644 index 00000000000..d3e21b5e851 --- /dev/null +++ b/src/main/java/com/stripe/service/v2/data/reporting/QueryRunService.java @@ -0,0 +1,60 @@ +// File generated from our OpenAPI spec +package com.stripe.service.v2.data.reporting; + +import com.stripe.exception.StripeException; +import com.stripe.model.v2.data.reporting.QueryRun; +import com.stripe.net.ApiRequest; +import com.stripe.net.ApiRequestParams; +import com.stripe.net.ApiResource; +import com.stripe.net.ApiService; +import com.stripe.net.BaseAddress; +import com.stripe.net.RequestOptions; +import com.stripe.net.StripeResponseGetter; +import com.stripe.param.v2.data.reporting.QueryRunCreateParams; + +public final class QueryRunService extends ApiService { + public QueryRunService(StripeResponseGetter responseGetter) { + super(responseGetter); + } + + /** + * Creates a query run to execute ad-hoc SQL and returns a {@code QueryRun} object to track + * progress and retrieve results. + */ + public QueryRun create(QueryRunCreateParams params) throws StripeException { + return create(params, (RequestOptions) null); + } + /** + * Creates a query run to execute ad-hoc SQL and returns a {@code QueryRun} object to track + * progress and retrieve results. + */ + public QueryRun create(QueryRunCreateParams params, RequestOptions options) + throws StripeException { + String path = "/v2/data/reporting/query_runs"; + ApiRequest request = + new ApiRequest( + BaseAddress.API, + ApiResource.RequestMethod.POST, + path, + ApiRequestParams.paramsToMap(params), + options); + return this.request(request, QueryRun.class); + } + /** + * Fetches the current state and details of a previously created {@code QueryRun}. If the {@code + * QueryRun} has succeeded, the endpoint will provide details for how to retrieve the results. + */ + public QueryRun retrieve(String id) throws StripeException { + return retrieve(id, (RequestOptions) null); + } + /** + * Fetches the current state and details of a previously created {@code QueryRun}. If the {@code + * QueryRun} has succeeded, the endpoint will provide details for how to retrieve the results. + */ + public QueryRun retrieve(String id, RequestOptions options) throws StripeException { + String path = String.format("/v2/data/reporting/query_runs/%s", ApiResource.urlEncodeId(id)); + ApiRequest request = + new ApiRequest(BaseAddress.API, ApiResource.RequestMethod.GET, path, null, options); + return this.request(request, QueryRun.class); + } +} diff --git a/src/main/java/com/stripe/service/v2/payments/OffSessionPaymentService.java b/src/main/java/com/stripe/service/v2/payments/OffSessionPaymentService.java index 52d5dad7277..cd8a81c21a2 100644 --- a/src/main/java/com/stripe/service/v2/payments/OffSessionPaymentService.java +++ b/src/main/java/com/stripe/service/v2/payments/OffSessionPaymentService.java @@ -108,4 +108,28 @@ public OffSessionPayment capture( options); return this.request(request, OffSessionPayment.class); } + /** Pauses an OffSessionPayment that has previously been created. */ + public OffSessionPayment pause(String id) throws StripeException { + return pause(id, (RequestOptions) null); + } + /** Pauses an OffSessionPayment that has previously been created. */ + public OffSessionPayment pause(String id, RequestOptions options) throws StripeException { + String path = + String.format("/v2/payments/off_session_payments/%s/pause", ApiResource.urlEncodeId(id)); + ApiRequest request = + new ApiRequest(BaseAddress.API, ApiResource.RequestMethod.POST, path, null, options); + return this.request(request, OffSessionPayment.class); + } + /** Resumes an OffSessionPayment that has previously been paused. */ + public OffSessionPayment resume(String id) throws StripeException { + return resume(id, (RequestOptions) null); + } + /** Resumes an OffSessionPayment that has previously been paused. */ + public OffSessionPayment resume(String id, RequestOptions options) throws StripeException { + String path = + String.format("/v2/payments/off_session_payments/%s/resume", ApiResource.urlEncodeId(id)); + ApiRequest request = + new ApiRequest(BaseAddress.API, ApiResource.RequestMethod.POST, path, null, options); + return this.request(request, OffSessionPayment.class); + } } diff --git a/src/test/java/com/stripe/functional/GeneratedExamples.java b/src/test/java/com/stripe/functional/GeneratedExamples.java index 9f80acab1eb..3b09ce6beda 100644 --- a/src/test/java/com/stripe/functional/GeneratedExamples.java +++ b/src/test/java/com/stripe/functional/GeneratedExamples.java @@ -28642,6 +28642,55 @@ public void testV2CoreVaultUsBankAccountPost5Services() throws StripeException { null); } + @Test + public void testV2DataReportingQueryRunPostServices() throws StripeException { + stubRequest( + BaseAddress.API, + ApiResource.RequestMethod.POST, + "/v2/data/reporting/query_runs", + null, + null, + com.stripe.model.v2.data.reporting.QueryRun.class, + "{\"created\":\"1970-01-12T21:42:34.472Z\",\"id\":\"obj_123\",\"object\":\"v2.data.reporting.query_run\",\"status_details\":{\"key\":{}},\"sql\":\"sql\",\"status\":\"failed\",\"livemode\":true}"); + StripeClient client = new StripeClient(networkSpy); + + com.stripe.param.v2.data.reporting.QueryRunCreateParams params = + com.stripe.param.v2.data.reporting.QueryRunCreateParams.builder().setSql("sql").build(); + + com.stripe.model.v2.data.reporting.QueryRun queryRun = + client.v2().data().reporting().queryRuns().create(params); + assertNotNull(queryRun); + verifyRequest( + BaseAddress.API, + ApiResource.RequestMethod.POST, + "/v2/data/reporting/query_runs", + params.toMap(), + null); + } + + @Test + public void testV2DataReportingQueryRunGetServices() throws StripeException { + stubRequest( + BaseAddress.API, + ApiResource.RequestMethod.GET, + "/v2/data/reporting/query_runs/id_123", + null, + null, + com.stripe.model.v2.data.reporting.QueryRun.class, + "{\"created\":\"1970-01-12T21:42:34.472Z\",\"id\":\"obj_123\",\"object\":\"v2.data.reporting.query_run\",\"status_details\":{\"key\":{}},\"sql\":\"sql\",\"status\":\"failed\",\"livemode\":true}"); + StripeClient client = new StripeClient(networkSpy); + + com.stripe.model.v2.data.reporting.QueryRun queryRun = + client.v2().data().reporting().queryRuns().retrieve("id_123"); + assertNotNull(queryRun); + verifyRequest( + BaseAddress.API, + ApiResource.RequestMethod.GET, + "/v2/data/reporting/query_runs/id_123", + null, + null); + } + @Test public void testV2IamApiKeyGetServices() throws StripeException { stubRequest( @@ -30053,7 +30102,7 @@ public void testV2PaymentsOffSessionPaymentGetServices() throws StripeException new TypeToken< com.stripe.model.v2.StripeCollection< com.stripe.model.v2.payments.OffSessionPayment>>() {}.getType(), - "{\"data\":[{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"compartment_id\":\"compartment_id\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"pending\"}],\"next_page_url\":null,\"previous_page_url\":null}"); + "{\"data\":[{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"requires_capture\"}],\"next_page_url\":null,\"previous_page_url\":null}"); StripeClient client = new StripeClient(networkSpy); com.stripe.param.v2.payments.OffSessionPaymentListParams params = @@ -30079,7 +30128,7 @@ public void testV2PaymentsOffSessionPaymentPostServices() throws StripeException null, null, com.stripe.model.v2.payments.OffSessionPayment.class, - "{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"compartment_id\":\"compartment_id\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"pending\"}"); + "{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"requires_capture\"}"); StripeClient client = new StripeClient(networkSpy); com.stripe.param.v2.payments.OffSessionPaymentCreateParams params = @@ -30111,7 +30160,7 @@ public void testV2PaymentsOffSessionPaymentGet2Services() throws StripeException null, null, com.stripe.model.v2.payments.OffSessionPayment.class, - "{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"compartment_id\":\"compartment_id\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"pending\"}"); + "{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"requires_capture\"}"); StripeClient client = new StripeClient(networkSpy); com.stripe.model.v2.payments.OffSessionPayment offSessionPayment = @@ -30134,7 +30183,7 @@ public void testV2PaymentsOffSessionPaymentPost2Services() throws StripeExceptio null, null, com.stripe.model.v2.payments.OffSessionPayment.class, - "{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"compartment_id\":\"compartment_id\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"pending\"}"); + "{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"requires_capture\"}"); StripeClient client = new StripeClient(networkSpy); com.stripe.model.v2.payments.OffSessionPayment offSessionPayment = @@ -30157,7 +30206,7 @@ public void testV2PaymentsOffSessionPaymentPost3Services() throws StripeExceptio null, null, com.stripe.model.v2.payments.OffSessionPayment.class, - "{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"compartment_id\":\"compartment_id\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"pending\"}"); + "{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"requires_capture\"}"); StripeClient client = new StripeClient(networkSpy); com.stripe.param.v2.payments.OffSessionPaymentCaptureParams params = @@ -30176,6 +30225,52 @@ public void testV2PaymentsOffSessionPaymentPost3Services() throws StripeExceptio null); } + @Test + public void testV2PaymentsOffSessionPaymentPost4Services() throws StripeException { + stubRequest( + BaseAddress.API, + ApiResource.RequestMethod.POST, + "/v2/payments/off_session_payments/id_123/pause", + null, + null, + com.stripe.model.v2.payments.OffSessionPayment.class, + "{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"requires_capture\"}"); + StripeClient client = new StripeClient(networkSpy); + + com.stripe.model.v2.payments.OffSessionPayment offSessionPayment = + client.v2().payments().offSessionPayments().pause("id_123"); + assertNotNull(offSessionPayment); + verifyRequest( + BaseAddress.API, + ApiResource.RequestMethod.POST, + "/v2/payments/off_session_payments/id_123/pause", + null, + null); + } + + @Test + public void testV2PaymentsOffSessionPaymentPost5Services() throws StripeException { + stubRequest( + BaseAddress.API, + ApiResource.RequestMethod.POST, + "/v2/payments/off_session_payments/id_123/resume", + null, + null, + com.stripe.model.v2.payments.OffSessionPayment.class, + "{\"amount_requested\":{\"currency\":\"USD\",\"value\":47},\"cadence\":\"unscheduled\",\"created\":\"1970-01-12T21:42:34.472Z\",\"customer\":\"customer\",\"id\":\"obj_123\",\"livemode\":true,\"metadata\":{\"key\":\"metadata\"},\"object\":\"v2.payments.off_session_payment\",\"payment_method\":\"payment_method\",\"payments_orchestration\":{\"enabled\":true},\"retry_details\":{\"attempts\":542738246,\"retry_strategy\":\"scheduled\"},\"status\":\"requires_capture\"}"); + StripeClient client = new StripeClient(networkSpy); + + com.stripe.model.v2.payments.OffSessionPayment offSessionPayment = + client.v2().payments().offSessionPayments().resume("id_123"); + assertNotNull(offSessionPayment); + verifyRequest( + BaseAddress.API, + ApiResource.RequestMethod.POST, + "/v2/payments/off_session_payments/id_123/resume", + null, + null); + } + @Test public void testV2PaymentsSettlementAllocationIntentGetServices() throws StripeException { stubRequest( From 54dab73efbe9be1a9e1b42663ce26b193085f1ce Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 31 Mar 2026 16:32:31 +0000 Subject: [PATCH 03/11] Update generated code for v2209 and --- CODEGEN_VERSION | 2 +- OPENAPI_VERSION | 2 +- .../delegatedcheckout/RequestedSession.java | 51 +++++++++++++++++++ 3 files changed, 53 insertions(+), 2 deletions(-) diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index dc6102b6b2f..5dc01470dc1 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -fdfc6818cc42c9db80a55ff8ecf63542f7e97014 \ No newline at end of file +1cdda26610d74c1e55e0de3949ddb81962fd1dc8 \ No newline at end of file diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 4385b2e9e81..d03e6c0220a 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2208 \ No newline at end of file +v2209 \ No newline at end of file diff --git a/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java b/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java index bc82cc6b674..6a8705b9cd6 100644 --- a/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java +++ b/src/main/java/com/stripe/model/delegatedcheckout/RequestedSession.java @@ -108,6 +108,10 @@ public class RequestedSession extends ApiResource @SerializedName("payment_method") String paymentMethod; + /** The payment method options for this requested session. */ + @SerializedName("payment_method_options") + PaymentMethodOptions paymentMethodOptions; + /** The preview of the payment method to be created when the requested session is confirmed. */ @SerializedName("payment_method_preview") PaymentMethodPreview paymentMethodPreview; @@ -896,6 +900,44 @@ public static class OrderDetails extends StripeObject { String orderStatusUrl; } + /** + * For more details about PaymentMethodOptions, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class PaymentMethodOptions extends StripeObject { + /** Card-specific payment method options. */ + @SerializedName("card") + Card card; + + /** The computed displayable card brands. */ + @SerializedName("displayable_card_brands") + List displayableCardBrands; + + /** The computed displayable payment method types. */ + @SerializedName("displayable_payment_method_types") + List displayablePaymentMethodTypes; + + /** The payment method types excluded by the agent. */ + @SerializedName("excluded_payment_method_types") + List excludedPaymentMethodTypes; + + /** + * For more details about Card, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Card extends StripeObject { + /** The card brands blocked by the agent. */ + @SerializedName("brands_blocked") + List brandsBlocked; + } + } + /** * For more details about PaymentMethodPreview, please refer to the API Reference. @@ -1052,6 +1094,10 @@ public static class ClientDeviceMetadataDetails extends StripeObject { @Setter @EqualsAndHashCode(callSuper = false) public static class SellerDetails extends StripeObject { + /** The card brands supported by the seller. */ + @SerializedName("card_brands") + List cardBrands; + /** The marketplace seller details. */ @SerializedName("marketplace_seller_details") MarketplaceSellerDetails marketplaceSellerDetails; @@ -1062,6 +1108,10 @@ public static class SellerDetails extends StripeObject { @Setter(lombok.AccessLevel.NONE) ExpandableField networkProfile; + /** The payment method types supported by the seller. */ + @SerializedName("payment_method_types") + List paymentMethodTypes; + /** The URL to the seller's privacy notice. */ @SerializedName("privacy_notice_url") String privacyNoticeUrl; @@ -1168,6 +1218,7 @@ public void setResponseGetter(StripeResponseGetter responseGetter) { super.setResponseGetter(responseGetter); trySetResponseGetter(fulfillmentDetails, responseGetter); trySetResponseGetter(orderDetails, responseGetter); + trySetResponseGetter(paymentMethodOptions, responseGetter); trySetResponseGetter(paymentMethodPreview, responseGetter); trySetResponseGetter(riskDetails, responseGetter); trySetResponseGetter(sellerDetails, responseGetter); From 81a73bc35ca1c5d20e19cfaf82c169317cbec1cb Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 31 Mar 2026 16:40:43 +0000 Subject: [PATCH 04/11] Update generated code for v2210 and --- OPENAPI_VERSION | 2 +- ...aymentAttemptRecordReportFailedParams.java | 210 ++++++++- ...ntAttemptRecordReportGuaranteedParams.java | 209 ++++++++- ...ecordReportPaymentAttemptFailedParams.java | 211 ++++++++- ...dReportPaymentAttemptGuaranteedParams.java | 209 ++++++++- ...ymentRecordReportPaymentAttemptParams.java | 422 +++++++++++++++++- .../PaymentRecordReportPaymentParams.java | 417 ++++++++++++++++- 7 files changed, 1663 insertions(+), 17 deletions(-) diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index d03e6c0220a..5fbae17d76e 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2209 \ No newline at end of file +v2210 \ No newline at end of file diff --git a/src/main/java/com/stripe/param/PaymentAttemptRecordReportFailedParams.java b/src/main/java/com/stripe/param/PaymentAttemptRecordReportFailedParams.java index 5cdb21a6ed5..5eb0e47d8c6 100644 --- a/src/main/java/com/stripe/param/PaymentAttemptRecordReportFailedParams.java +++ b/src/main/java/com/stripe/param/PaymentAttemptRecordReportFailedParams.java @@ -47,17 +47,23 @@ public class PaymentAttemptRecordReportFailedParams extends ApiRequestParams { @SerializedName("metadata") Object metadata; + /** Processor information for this payment. */ + @SerializedName("processor_details") + ProcessorDetails processorDetails; + private PaymentAttemptRecordReportFailedParams( List expand, Map extraParams, Long failedAt, FailureCode failureCode, - Object metadata) { + Object metadata, + ProcessorDetails processorDetails) { this.expand = expand; this.extraParams = extraParams; this.failedAt = failedAt; this.failureCode = failureCode; this.metadata = metadata; + this.processorDetails = processorDetails; } public static Builder builder() { @@ -75,10 +81,17 @@ public static class Builder { private Object metadata; + private ProcessorDetails processorDetails; + /** Finalize and obtain parameter instance from this builder. */ public PaymentAttemptRecordReportFailedParams build() { return new PaymentAttemptRecordReportFailedParams( - this.expand, this.extraParams, this.failedAt, this.failureCode, this.metadata); + this.expand, + this.extraParams, + this.failedAt, + this.failureCode, + this.metadata, + this.processorDetails); } /** @@ -197,6 +210,199 @@ public Builder setMetadata(Map metadata) { this.metadata = metadata; return this; } + + /** Processor information for this payment. */ + public Builder setProcessorDetails( + PaymentAttemptRecordReportFailedParams.ProcessorDetails processorDetails) { + this.processorDetails = processorDetails; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ProcessorDetails { + /** Information about the custom processor used to make this payment. */ + @SerializedName("custom") + Custom custom; + + /** + * 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; + + /** + * Required. The type of the processor details. An additional hash is included + * on processor_details with a name matching this value. It contains additional information + * specific to the processor. + */ + @SerializedName("type") + Type type; + + private ProcessorDetails(Custom custom, Map extraParams, Type type) { + this.custom = custom; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Custom custom; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentAttemptRecordReportFailedParams.ProcessorDetails build() { + return new PaymentAttemptRecordReportFailedParams.ProcessorDetails( + this.custom, this.extraParams, this.type); + } + + /** Information about the custom processor used to make this payment. */ + public Builder setCustom( + PaymentAttemptRecordReportFailedParams.ProcessorDetails.Custom custom) { + this.custom = custom; + 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 + * PaymentAttemptRecordReportFailedParams.ProcessorDetails#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 PaymentAttemptRecordReportFailedParams.ProcessorDetails#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + public Builder setType(PaymentAttemptRecordReportFailedParams.ProcessorDetails.Type type) { + this.type = type; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Custom { + /** + * 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; + + /** + * Required. An opaque string for manual reconciliation of this payment, for + * example a check number or a payment processor ID. + */ + @SerializedName("payment_reference") + String paymentReference; + + private Custom(Map extraParams, String paymentReference) { + this.extraParams = extraParams; + this.paymentReference = paymentReference; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String paymentReference; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentAttemptRecordReportFailedParams.ProcessorDetails.Custom build() { + return new PaymentAttemptRecordReportFailedParams.ProcessorDetails.Custom( + this.extraParams, this.paymentReference); + } + + /** + * 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 + * PaymentAttemptRecordReportFailedParams.ProcessorDetails.Custom#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 + * PaymentAttemptRecordReportFailedParams.ProcessorDetails.Custom#extraParams} for the field + * documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + public Builder setPaymentReference(String paymentReference) { + this.paymentReference = paymentReference; + return this; + } + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("custom") + CUSTOM("custom"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } } public enum FailureCode implements ApiRequestParams.EnumParam { diff --git a/src/main/java/com/stripe/param/PaymentAttemptRecordReportGuaranteedParams.java b/src/main/java/com/stripe/param/PaymentAttemptRecordReportGuaranteedParams.java index 62648e04445..ecaedcaa324 100644 --- a/src/main/java/com/stripe/param/PaymentAttemptRecordReportGuaranteedParams.java +++ b/src/main/java/com/stripe/param/PaymentAttemptRecordReportGuaranteedParams.java @@ -40,12 +40,21 @@ public class PaymentAttemptRecordReportGuaranteedParams extends ApiRequestParams @SerializedName("metadata") Object metadata; + /** Processor information for this payment. */ + @SerializedName("processor_details") + ProcessorDetails processorDetails; + private PaymentAttemptRecordReportGuaranteedParams( - List expand, Map extraParams, Long guaranteedAt, Object metadata) { + List expand, + Map extraParams, + Long guaranteedAt, + Object metadata, + ProcessorDetails processorDetails) { this.expand = expand; this.extraParams = extraParams; this.guaranteedAt = guaranteedAt; this.metadata = metadata; + this.processorDetails = processorDetails; } public static Builder builder() { @@ -61,10 +70,12 @@ public static class Builder { private Object metadata; + private ProcessorDetails processorDetails; + /** Finalize and obtain parameter instance from this builder. */ public PaymentAttemptRecordReportGuaranteedParams build() { return new PaymentAttemptRecordReportGuaranteedParams( - this.expand, this.extraParams, this.guaranteedAt, this.metadata); + this.expand, this.extraParams, this.guaranteedAt, this.metadata, this.processorDetails); } /** @@ -175,5 +186,199 @@ public Builder setMetadata(Map metadata) { this.metadata = metadata; return this; } + + /** Processor information for this payment. */ + public Builder setProcessorDetails( + PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails processorDetails) { + this.processorDetails = processorDetails; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ProcessorDetails { + /** Information about the custom processor used to make this payment. */ + @SerializedName("custom") + Custom custom; + + /** + * 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; + + /** + * Required. The type of the processor details. An additional hash is included + * on processor_details with a name matching this value. It contains additional information + * specific to the processor. + */ + @SerializedName("type") + Type type; + + private ProcessorDetails(Custom custom, Map extraParams, Type type) { + this.custom = custom; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Custom custom; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails build() { + return new PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails( + this.custom, this.extraParams, this.type); + } + + /** Information about the custom processor used to make this payment. */ + public Builder setCustom( + PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails.Custom custom) { + this.custom = custom; + 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 + * PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails#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 PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + public Builder setType( + PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails.Type type) { + this.type = type; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Custom { + /** + * 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; + + /** + * Required. An opaque string for manual reconciliation of this payment, for + * example a check number or a payment processor ID. + */ + @SerializedName("payment_reference") + String paymentReference; + + private Custom(Map extraParams, String paymentReference) { + this.extraParams = extraParams; + this.paymentReference = paymentReference; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String paymentReference; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails.Custom build() { + return new PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails.Custom( + this.extraParams, this.paymentReference); + } + + /** + * 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 + * PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails.Custom#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 + * PaymentAttemptRecordReportGuaranteedParams.ProcessorDetails.Custom#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + public Builder setPaymentReference(String paymentReference) { + this.paymentReference = paymentReference; + return this; + } + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("custom") + CUSTOM("custom"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } } } diff --git a/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptFailedParams.java b/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptFailedParams.java index 714b8647cab..003f4308e5a 100644 --- a/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptFailedParams.java +++ b/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptFailedParams.java @@ -47,17 +47,23 @@ public class PaymentRecordReportPaymentAttemptFailedParams extends ApiRequestPar @SerializedName("metadata") Object metadata; + /** Processor information for this payment. */ + @SerializedName("processor_details") + ProcessorDetails processorDetails; + private PaymentRecordReportPaymentAttemptFailedParams( List expand, Map extraParams, Long failedAt, FailureCode failureCode, - Object metadata) { + Object metadata, + ProcessorDetails processorDetails) { this.expand = expand; this.extraParams = extraParams; this.failedAt = failedAt; this.failureCode = failureCode; this.metadata = metadata; + this.processorDetails = processorDetails; } public static Builder builder() { @@ -75,10 +81,17 @@ public static class Builder { private Object metadata; + private ProcessorDetails processorDetails; + /** Finalize and obtain parameter instance from this builder. */ public PaymentRecordReportPaymentAttemptFailedParams build() { return new PaymentRecordReportPaymentAttemptFailedParams( - this.expand, this.extraParams, this.failedAt, this.failureCode, this.metadata); + this.expand, + this.extraParams, + this.failedAt, + this.failureCode, + this.metadata, + this.processorDetails); } /** @@ -200,6 +213,200 @@ public Builder setMetadata(Map metadata) { this.metadata = metadata; return this; } + + /** Processor information for this payment. */ + public Builder setProcessorDetails( + PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails processorDetails) { + this.processorDetails = processorDetails; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ProcessorDetails { + /** Information about the custom processor used to make this payment. */ + @SerializedName("custom") + Custom custom; + + /** + * 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; + + /** + * Required. The type of the processor details. An additional hash is included + * on processor_details with a name matching this value. It contains additional information + * specific to the processor. + */ + @SerializedName("type") + Type type; + + private ProcessorDetails(Custom custom, Map extraParams, Type type) { + this.custom = custom; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Custom custom; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails build() { + return new PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails( + this.custom, this.extraParams, this.type); + } + + /** Information about the custom processor used to make this payment. */ + public Builder setCustom( + PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails.Custom custom) { + this.custom = custom; + 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 + * PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails#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 PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + public Builder setType( + PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails.Type type) { + this.type = type; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Custom { + /** + * 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; + + /** + * Required. An opaque string for manual reconciliation of this payment, for + * example a check number or a payment processor ID. + */ + @SerializedName("payment_reference") + String paymentReference; + + private Custom(Map extraParams, String paymentReference) { + this.extraParams = extraParams; + this.paymentReference = paymentReference; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String paymentReference; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails.Custom build() { + return new PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails.Custom( + this.extraParams, this.paymentReference); + } + + /** + * 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 + * PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails.Custom#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 + * PaymentRecordReportPaymentAttemptFailedParams.ProcessorDetails.Custom#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + public Builder setPaymentReference(String paymentReference) { + this.paymentReference = paymentReference; + return this; + } + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("custom") + CUSTOM("custom"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } } public enum FailureCode implements ApiRequestParams.EnumParam { diff --git a/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptGuaranteedParams.java b/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptGuaranteedParams.java index 19149b01b96..01efe79251a 100644 --- a/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptGuaranteedParams.java +++ b/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptGuaranteedParams.java @@ -40,12 +40,21 @@ public class PaymentRecordReportPaymentAttemptGuaranteedParams extends ApiReques @SerializedName("metadata") Object metadata; + /** Processor information for this payment. */ + @SerializedName("processor_details") + ProcessorDetails processorDetails; + private PaymentRecordReportPaymentAttemptGuaranteedParams( - List expand, Map extraParams, Long guaranteedAt, Object metadata) { + List expand, + Map extraParams, + Long guaranteedAt, + Object metadata, + ProcessorDetails processorDetails) { this.expand = expand; this.extraParams = extraParams; this.guaranteedAt = guaranteedAt; this.metadata = metadata; + this.processorDetails = processorDetails; } public static Builder builder() { @@ -61,10 +70,12 @@ public static class Builder { private Object metadata; + private ProcessorDetails processorDetails; + /** Finalize and obtain parameter instance from this builder. */ public PaymentRecordReportPaymentAttemptGuaranteedParams build() { return new PaymentRecordReportPaymentAttemptGuaranteedParams( - this.expand, this.extraParams, this.guaranteedAt, this.metadata); + this.expand, this.extraParams, this.guaranteedAt, this.metadata, this.processorDetails); } /** @@ -176,5 +187,199 @@ public Builder setMetadata(Map metadata) { this.metadata = metadata; return this; } + + /** Processor information for this payment. */ + public Builder setProcessorDetails( + PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails processorDetails) { + this.processorDetails = processorDetails; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ProcessorDetails { + /** Information about the custom processor used to make this payment. */ + @SerializedName("custom") + Custom custom; + + /** + * 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; + + /** + * Required. The type of the processor details. An additional hash is included + * on processor_details with a name matching this value. It contains additional information + * specific to the processor. + */ + @SerializedName("type") + Type type; + + private ProcessorDetails(Custom custom, Map extraParams, Type type) { + this.custom = custom; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Custom custom; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails build() { + return new PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails( + this.custom, this.extraParams, this.type); + } + + /** Information about the custom processor used to make this payment. */ + public Builder setCustom( + PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails.Custom custom) { + this.custom = custom; + 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 + * PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails#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 PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + public Builder setType( + PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails.Type type) { + this.type = type; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Custom { + /** + * 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; + + /** + * Required. An opaque string for manual reconciliation of this payment, for + * example a check number or a payment processor ID. + */ + @SerializedName("payment_reference") + String paymentReference; + + private Custom(Map extraParams, String paymentReference) { + this.extraParams = extraParams; + this.paymentReference = paymentReference; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String paymentReference; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails.Custom build() { + return new PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails.Custom( + this.extraParams, this.paymentReference); + } + + /** + * 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 + * PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails.Custom#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 + * PaymentRecordReportPaymentAttemptGuaranteedParams.ProcessorDetails.Custom#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + public Builder setPaymentReference(String paymentReference) { + this.paymentReference = paymentReference; + return this; + } + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("custom") + CUSTOM("custom"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } } } diff --git a/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptParams.java b/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptParams.java index cebd6f25e51..8ed2de83088 100644 --- a/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptParams.java +++ b/src/main/java/com/stripe/param/PaymentRecordReportPaymentAttemptParams.java @@ -306,10 +306,19 @@ public static class Failed { @SerializedName("failure_code") FailureCode failureCode; - private Failed(Map extraParams, Long failedAt, FailureCode failureCode) { + /** Processor information for this payment. */ + @SerializedName("processor_details") + ProcessorDetails processorDetails; + + private Failed( + Map extraParams, + Long failedAt, + FailureCode failureCode, + ProcessorDetails processorDetails) { this.extraParams = extraParams; this.failedAt = failedAt; this.failureCode = failureCode; + this.processorDetails = processorDetails; } public static Builder builder() { @@ -323,10 +332,12 @@ public static class Builder { private FailureCode failureCode; + private ProcessorDetails processorDetails; + /** Finalize and obtain parameter instance from this builder. */ public PaymentRecordReportPaymentAttemptParams.Failed build() { return new PaymentRecordReportPaymentAttemptParams.Failed( - this.extraParams, this.failedAt, this.failureCode); + this.extraParams, this.failedAt, this.failureCode, this.processorDetails); } /** @@ -374,6 +385,203 @@ public Builder setFailureCode( this.failureCode = failureCode; return this; } + + /** Processor information for this payment. */ + public Builder setProcessorDetails( + PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails processorDetails) { + this.processorDetails = processorDetails; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ProcessorDetails { + /** Information about the custom processor used to make this payment. */ + @SerializedName("custom") + Custom custom; + + /** + * 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; + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + @SerializedName("type") + Type type; + + private ProcessorDetails(Custom custom, Map extraParams, Type type) { + this.custom = custom; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Custom custom; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails build() { + return new PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails( + this.custom, this.extraParams, this.type); + } + + /** Information about the custom processor used to make this payment. */ + public Builder setCustom( + PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails.Custom custom) { + this.custom = custom; + 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 + * PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails#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 + * PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + public Builder setType( + PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails.Type type) { + this.type = type; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Custom { + /** + * 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; + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + @SerializedName("payment_reference") + String paymentReference; + + private Custom(Map extraParams, String paymentReference) { + this.extraParams = extraParams; + this.paymentReference = paymentReference; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String paymentReference; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails.Custom build() { + return new PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails.Custom( + this.extraParams, this.paymentReference); + } + + /** + * 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 + * PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails.Custom#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 + * PaymentRecordReportPaymentAttemptParams.Failed.ProcessorDetails.Custom#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + public Builder setPaymentReference(String paymentReference) { + this.paymentReference = paymentReference; + return this; + } + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("custom") + CUSTOM("custom"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } } public enum FailureCode implements ApiRequestParams.EnumParam { @@ -411,9 +619,15 @@ public static class Guaranteed { @SerializedName("guaranteed_at") Long guaranteedAt; - private Guaranteed(Map extraParams, Long guaranteedAt) { + /** Processor information for this payment. */ + @SerializedName("processor_details") + ProcessorDetails processorDetails; + + private Guaranteed( + Map extraParams, Long guaranteedAt, ProcessorDetails processorDetails) { this.extraParams = extraParams; this.guaranteedAt = guaranteedAt; + this.processorDetails = processorDetails; } public static Builder builder() { @@ -425,10 +639,12 @@ public static class Builder { private Long guaranteedAt; + private ProcessorDetails processorDetails; + /** Finalize and obtain parameter instance from this builder. */ public PaymentRecordReportPaymentAttemptParams.Guaranteed build() { return new PaymentRecordReportPaymentAttemptParams.Guaranteed( - this.extraParams, this.guaranteedAt); + this.extraParams, this.guaranteedAt, this.processorDetails); } /** @@ -467,6 +683,204 @@ public Builder setGuaranteedAt(Long guaranteedAt) { this.guaranteedAt = guaranteedAt; return this; } + + /** Processor information for this payment. */ + public Builder setProcessorDetails( + PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails processorDetails) { + this.processorDetails = processorDetails; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ProcessorDetails { + /** Information about the custom processor used to make this payment. */ + @SerializedName("custom") + Custom custom; + + /** + * 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; + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + @SerializedName("type") + Type type; + + private ProcessorDetails(Custom custom, Map extraParams, Type type) { + this.custom = custom; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Custom custom; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails build() { + return new PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails( + this.custom, this.extraParams, this.type); + } + + /** Information about the custom processor used to make this payment. */ + public Builder setCustom( + PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails.Custom custom) { + this.custom = custom; + 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 + * PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails#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 + * PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + public Builder setType( + PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails.Type type) { + this.type = type; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Custom { + /** + * 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; + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + @SerializedName("payment_reference") + String paymentReference; + + private Custom(Map extraParams, String paymentReference) { + this.extraParams = extraParams; + this.paymentReference = paymentReference; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String paymentReference; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails.Custom + build() { + return new PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails.Custom( + this.extraParams, this.paymentReference); + } + + /** + * 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 + * PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails.Custom#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 + * PaymentRecordReportPaymentAttemptParams.Guaranteed.ProcessorDetails.Custom#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + public Builder setPaymentReference(String paymentReference) { + this.paymentReference = paymentReference; + return this; + } + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("custom") + CUSTOM("custom"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } } } diff --git a/src/main/java/com/stripe/param/PaymentRecordReportPaymentParams.java b/src/main/java/com/stripe/param/PaymentRecordReportPaymentParams.java index a48a472b62a..945f5e09833 100644 --- a/src/main/java/com/stripe/param/PaymentRecordReportPaymentParams.java +++ b/src/main/java/com/stripe/param/PaymentRecordReportPaymentParams.java @@ -581,10 +581,19 @@ public static class Failed { @SerializedName("failure_code") FailureCode failureCode; - private Failed(Map extraParams, Long failedAt, FailureCode failureCode) { + /** Processor information for this payment. */ + @SerializedName("processor_details") + ProcessorDetails processorDetails; + + private Failed( + Map extraParams, + Long failedAt, + FailureCode failureCode, + ProcessorDetails processorDetails) { this.extraParams = extraParams; this.failedAt = failedAt; this.failureCode = failureCode; + this.processorDetails = processorDetails; } public static Builder builder() { @@ -598,10 +607,12 @@ public static class Builder { private FailureCode failureCode; + private ProcessorDetails processorDetails; + /** Finalize and obtain parameter instance from this builder. */ public PaymentRecordReportPaymentParams.Failed build() { return new PaymentRecordReportPaymentParams.Failed( - this.extraParams, this.failedAt, this.failureCode); + this.extraParams, this.failedAt, this.failureCode, this.processorDetails); } /** @@ -649,6 +660,200 @@ public Builder setFailureCode( this.failureCode = failureCode; return this; } + + /** Processor information for this payment. */ + public Builder setProcessorDetails( + PaymentRecordReportPaymentParams.Failed.ProcessorDetails processorDetails) { + this.processorDetails = processorDetails; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ProcessorDetails { + /** Information about the custom processor used to make this payment. */ + @SerializedName("custom") + Custom custom; + + /** + * 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; + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + @SerializedName("type") + Type type; + + private ProcessorDetails(Custom custom, Map extraParams, Type type) { + this.custom = custom; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Custom custom; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentParams.Failed.ProcessorDetails build() { + return new PaymentRecordReportPaymentParams.Failed.ProcessorDetails( + this.custom, this.extraParams, this.type); + } + + /** Information about the custom processor used to make this payment. */ + public Builder setCustom( + PaymentRecordReportPaymentParams.Failed.ProcessorDetails.Custom custom) { + this.custom = custom; + 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 PaymentRecordReportPaymentParams.Failed.ProcessorDetails#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 PaymentRecordReportPaymentParams.Failed.ProcessorDetails#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + public Builder setType(PaymentRecordReportPaymentParams.Failed.ProcessorDetails.Type type) { + this.type = type; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Custom { + /** + * 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; + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + @SerializedName("payment_reference") + String paymentReference; + + private Custom(Map extraParams, String paymentReference) { + this.extraParams = extraParams; + this.paymentReference = paymentReference; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String paymentReference; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentParams.Failed.ProcessorDetails.Custom build() { + return new PaymentRecordReportPaymentParams.Failed.ProcessorDetails.Custom( + this.extraParams, this.paymentReference); + } + + /** + * 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 + * PaymentRecordReportPaymentParams.Failed.ProcessorDetails.Custom#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 + * PaymentRecordReportPaymentParams.Failed.ProcessorDetails.Custom#extraParams} for the + * field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + public Builder setPaymentReference(String paymentReference) { + this.paymentReference = paymentReference; + return this; + } + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("custom") + CUSTOM("custom"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } } public enum FailureCode implements ApiRequestParams.EnumParam { @@ -686,9 +891,15 @@ public static class Guaranteed { @SerializedName("guaranteed_at") Long guaranteedAt; - private Guaranteed(Map extraParams, Long guaranteedAt) { + /** Processor information for this payment. */ + @SerializedName("processor_details") + ProcessorDetails processorDetails; + + private Guaranteed( + Map extraParams, Long guaranteedAt, ProcessorDetails processorDetails) { this.extraParams = extraParams; this.guaranteedAt = guaranteedAt; + this.processorDetails = processorDetails; } public static Builder builder() { @@ -700,9 +911,12 @@ public static class Builder { private Long guaranteedAt; + private ProcessorDetails processorDetails; + /** Finalize and obtain parameter instance from this builder. */ public PaymentRecordReportPaymentParams.Guaranteed build() { - return new PaymentRecordReportPaymentParams.Guaranteed(this.extraParams, this.guaranteedAt); + return new PaymentRecordReportPaymentParams.Guaranteed( + this.extraParams, this.guaranteedAt, this.processorDetails); } /** @@ -740,6 +954,201 @@ public Builder setGuaranteedAt(Long guaranteedAt) { this.guaranteedAt = guaranteedAt; return this; } + + /** Processor information for this payment. */ + public Builder setProcessorDetails( + PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails processorDetails) { + this.processorDetails = processorDetails; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class ProcessorDetails { + /** Information about the custom processor used to make this payment. */ + @SerializedName("custom") + Custom custom; + + /** + * 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; + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + @SerializedName("type") + Type type; + + private ProcessorDetails(Custom custom, Map extraParams, Type type) { + this.custom = custom; + this.extraParams = extraParams; + this.type = type; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Custom custom; + + private Map extraParams; + + private Type type; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails build() { + return new PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails( + this.custom, this.extraParams, this.type); + } + + /** Information about the custom processor used to make this payment. */ + public Builder setCustom( + PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails.Custom custom) { + this.custom = custom; + 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 PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails#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 PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. The type of the processor details. An additional hash is + * included on processor_details with a name matching this value. It contains additional + * information specific to the processor. + */ + public Builder setType( + PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails.Type type) { + this.type = type; + return this; + } + } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Custom { + /** + * 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; + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + @SerializedName("payment_reference") + String paymentReference; + + private Custom(Map extraParams, String paymentReference) { + this.extraParams = extraParams; + this.paymentReference = paymentReference; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Map extraParams; + + private String paymentReference; + + /** Finalize and obtain parameter instance from this builder. */ + public PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails.Custom build() { + return new PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails.Custom( + this.extraParams, this.paymentReference); + } + + /** + * 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 + * PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails.Custom#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 + * PaymentRecordReportPaymentParams.Guaranteed.ProcessorDetails.Custom#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + /** + * Required. An opaque string for manual reconciliation of this payment, + * for example a check number or a payment processor ID. + */ + public Builder setPaymentReference(String paymentReference) { + this.paymentReference = paymentReference; + return this; + } + } + } + + public enum Type implements ApiRequestParams.EnumParam { + @SerializedName("custom") + CUSTOM("custom"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + Type(String value) { + this.value = value; + } + } } } From 6c8070f8cdb3bacb6ae925bbb44c26b757997d6c Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 31 Mar 2026 18:54:12 +0000 Subject: [PATCH 05/11] Update generated code for v2211 and --- CODEGEN_VERSION | 2 +- OPENAPI_VERSION | 2 +- src/main/java/com/stripe/ApiVersion.java | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index 5dc01470dc1..4bb8958fbbe 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -1cdda26610d74c1e55e0de3949ddb81962fd1dc8 \ No newline at end of file +c87174ec3151f5f52c43dea740e9678a4a32e33c \ No newline at end of file diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 5fbae17d76e..5f2cd81fdfe 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2210 \ No newline at end of file +v2211 \ No newline at end of file diff --git a/src/main/java/com/stripe/ApiVersion.java b/src/main/java/com/stripe/ApiVersion.java index 8b6152d7509..19c382f62d5 100644 --- a/src/main/java/com/stripe/ApiVersion.java +++ b/src/main/java/com/stripe/ApiVersion.java @@ -2,5 +2,5 @@ package com.stripe; final class ApiVersion { - public static final String CURRENT = "2026-03-25.preview"; + public static final String CURRENT = "2026-04-01.preview"; } From eda6b9a9d87b0661a5fe756b0613b9bfde76d24a Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 31 Mar 2026 20:30:33 +0000 Subject: [PATCH 06/11] Update generated code for v2212 and --- CODEGEN_VERSION | 2 +- OPENAPI_VERSION | 2 +- src/main/java/com/stripe/model/Invoice.java | 46 +++ .../com/stripe/model/QuotePreviewInvoice.java | 46 +++ .../java/com/stripe/model/Subscription.java | 46 +++ .../com/stripe/param/InvoiceCreateParams.java | 254 ++++++++++++++++ .../com/stripe/param/InvoiceUpdateParams.java | 284 +++++++++++++++++ .../param/SubscriptionCreateParams.java | 255 ++++++++++++++++ .../param/SubscriptionUpdateParams.java | 285 ++++++++++++++++++ 9 files changed, 1218 insertions(+), 2 deletions(-) diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index 4bb8958fbbe..ffc4d55dce5 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -c87174ec3151f5f52c43dea740e9678a4a32e33c \ No newline at end of file +3276ebff880bc62a0bcd63e41d8570598398a6c1 \ No newline at end of file diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 5f2cd81fdfe..d3af7b26b1a 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2211 \ No newline at end of file +v2212 \ No newline at end of file diff --git a/src/main/java/com/stripe/model/Invoice.java b/src/main/java/com/stripe/model/Invoice.java index cec87b44d3a..d4a65bda485 100644 --- a/src/main/java/com/stripe/model/Invoice.java +++ b/src/main/java/com/stripe/model/Invoice.java @@ -2598,6 +2598,13 @@ public static class PaymentMethodOptions extends StripeObject { @SerializedName("card") Card card; + /** + * If paying by {@code check_scan}, this sub-hash contains details about the Check Scan + * payment method options to pass to the invoice’s PaymentIntent. + */ + @SerializedName("check_scan") + CheckScan checkScan; + /** * If paying by {@code customer_balance}, this sub-hash contains details about the Bank * transfer payment method options to pass to the invoice’s PaymentIntent. @@ -2749,6 +2756,45 @@ public static class Installments extends StripeObject { } } + /** + * For more details about CheckScan, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CheckScan extends StripeObject { + @SerializedName("check_deposit_address") + CheckDepositAddress checkDepositAddress; + + /** + * For more details about CheckDepositAddress, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CheckDepositAddress extends StripeObject { + @SerializedName("city") + String city; + + @SerializedName("country") + String country; + + @SerializedName("line1") + String line1; + + @SerializedName("line2") + String line2; + + @SerializedName("postal_code") + String postalCode; + + @SerializedName("state") + String state; + } + } + /** * For more details about CustomerBalance, please refer to the API Reference. diff --git a/src/main/java/com/stripe/model/QuotePreviewInvoice.java b/src/main/java/com/stripe/model/QuotePreviewInvoice.java index aeff6d938b4..be738e0ccdb 100644 --- a/src/main/java/com/stripe/model/QuotePreviewInvoice.java +++ b/src/main/java/com/stripe/model/QuotePreviewInvoice.java @@ -1419,6 +1419,13 @@ public static class PaymentMethodOptions extends StripeObject { @SerializedName("card") Card card; + /** + * If paying by {@code check_scan}, this sub-hash contains details about the Check Scan + * payment method options to pass to the invoice’s PaymentIntent. + */ + @SerializedName("check_scan") + CheckScan checkScan; + /** * If paying by {@code customer_balance}, this sub-hash contains details about the Bank * transfer payment method options to pass to the invoice’s PaymentIntent. @@ -1570,6 +1577,45 @@ public static class Installments extends StripeObject { } } + /** + * For more details about CheckScan, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CheckScan extends StripeObject { + @SerializedName("check_deposit_address") + CheckDepositAddress checkDepositAddress; + + /** + * For more details about CheckDepositAddress, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CheckDepositAddress extends StripeObject { + @SerializedName("city") + String city; + + @SerializedName("country") + String country; + + @SerializedName("line1") + String line1; + + @SerializedName("line2") + String line2; + + @SerializedName("postal_code") + String postalCode; + + @SerializedName("state") + String state; + } + } + /** * For more details about CustomerBalance, please refer to the API Reference. diff --git a/src/main/java/com/stripe/model/Subscription.java b/src/main/java/com/stripe/model/Subscription.java index ed931f35e12..9c0703f2864 100644 --- a/src/main/java/com/stripe/model/Subscription.java +++ b/src/main/java/com/stripe/model/Subscription.java @@ -1987,6 +1987,13 @@ public static class PaymentMethodOptions extends StripeObject { @SerializedName("card") Card card; + /** + * This sub-hash contains details about the Check Scan payment method options to pass to + * invoices created by the subscription. + */ + @SerializedName("check_scan") + CheckScan checkScan; + /** * This sub-hash contains details about the Bank transfer payment method options to pass to * invoices created by the subscription. @@ -2160,6 +2167,45 @@ public static class MandateOptions extends StripeObject { } } + /** + * For more details about CheckScan, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CheckScan extends StripeObject { + @SerializedName("check_deposit_address") + CheckDepositAddress checkDepositAddress; + + /** + * For more details about CheckDepositAddress, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CheckDepositAddress extends StripeObject { + @SerializedName("city") + String city; + + @SerializedName("country") + String country; + + @SerializedName("line1") + String line1; + + @SerializedName("line2") + String line2; + + @SerializedName("postal_code") + String postalCode; + + @SerializedName("state") + String state; + } + } + /** * For more details about CustomerBalance, please refer to the API Reference. diff --git a/src/main/java/com/stripe/param/InvoiceCreateParams.java b/src/main/java/com/stripe/param/InvoiceCreateParams.java index 486727c7090..1755bd8a1c2 100644 --- a/src/main/java/com/stripe/param/InvoiceCreateParams.java +++ b/src/main/java/com/stripe/param/InvoiceCreateParams.java @@ -2203,6 +2203,13 @@ public static class PaymentMethodOptions { @SerializedName("card") Object card; + /** + * If paying by {@code check_scan}, this sub-hash contains details about the Check Scan + * payment method options to pass to the invoice’s PaymentIntent. + */ + @SerializedName("check_scan") + Object checkScan; + /** * If paying by {@code customer_balance}, this sub-hash contains details about the Bank * transfer payment method options to pass to the invoice’s PaymentIntent. @@ -2272,6 +2279,7 @@ private PaymentMethodOptions( Object acssDebit, Object bancontact, Object card, + Object checkScan, Object customerBalance, Map extraParams, Object idBankTransfer, @@ -2284,6 +2292,7 @@ private PaymentMethodOptions( this.acssDebit = acssDebit; this.bancontact = bancontact; this.card = card; + this.checkScan = checkScan; this.customerBalance = customerBalance; this.extraParams = extraParams; this.idBankTransfer = idBankTransfer; @@ -2306,6 +2315,8 @@ public static class Builder { private Object card; + private Object checkScan; + private Object customerBalance; private Map extraParams; @@ -2330,6 +2341,7 @@ public InvoiceCreateParams.PaymentSettings.PaymentMethodOptions build() { this.acssDebit, this.bancontact, this.card, + this.checkScan, this.customerBalance, this.extraParams, this.idBankTransfer, @@ -2397,6 +2409,25 @@ public Builder setCard(EmptyParam card) { return this; } + /** + * If paying by {@code check_scan}, this sub-hash contains details about the Check Scan + * payment method options to pass to the invoice’s PaymentIntent. + */ + public Builder setCheckScan( + InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan checkScan) { + this.checkScan = checkScan; + return this; + } + + /** + * If paying by {@code check_scan}, this sub-hash contains details about the Check Scan + * payment method options to pass to the invoice’s PaymentIntent. + */ + public Builder setCheckScan(EmptyParam checkScan) { + this.checkScan = checkScan; + return this; + } + /** * If paying by {@code customer_balance}, this sub-hash contains details about the Bank * transfer payment method options to pass to the invoice’s PaymentIntent. @@ -3293,6 +3324,226 @@ public enum RequestThreeDSecure implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class CheckScan { + @SerializedName("check_deposit_address") + CheckDepositAddress checkDepositAddress; + + /** + * 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 CheckScan( + CheckDepositAddress checkDepositAddress, Map extraParams) { + this.checkDepositAddress = checkDepositAddress; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private CheckDepositAddress checkDepositAddress; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan build() { + return new InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan( + this.checkDepositAddress, this.extraParams); + } + + public Builder setCheckDepositAddress( + InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan.CheckDepositAddress + checkDepositAddress) { + this.checkDepositAddress = checkDepositAddress; + 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 + * InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan#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 + * InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan#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 + @EqualsAndHashCode(callSuper = false) + public static class CheckDepositAddress { + @SerializedName("city") + String city; + + @SerializedName("country") + String country; + + /** + * 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; + + @SerializedName("line1") + String line1; + + @SerializedName("line2") + String line2; + + @SerializedName("postal_code") + String postalCode; + + @SerializedName("state") + String state; + + private CheckDepositAddress( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String city; + + private String country; + + private Map extraParams; + + private String line1; + + private String line2; + + private String postalCode; + + private String state; + + /** Finalize and obtain parameter instance from this builder. */ + public InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan + .CheckDepositAddress + build() { + return new InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan + .CheckDepositAddress( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + public Builder setCity(String city) { + this.city = city; + return this; + } + + public Builder setCountry(String country) { + this.country = country; + 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 + * InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan.CheckDepositAddress#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 + * InvoiceCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan.CheckDepositAddress#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + public Builder setState(String state) { + this.state = state; + return this; + } + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class CustomerBalance { @@ -4878,6 +5129,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam { @SerializedName("cashapp") CASHAPP("cashapp"), + @SerializedName("check_scan") + CHECK_SCAN("check_scan"), + @SerializedName("crypto") CRYPTO("crypto"), diff --git a/src/main/java/com/stripe/param/InvoiceUpdateParams.java b/src/main/java/com/stripe/param/InvoiceUpdateParams.java index fcabbaba70f..4dcbe1c385e 100644 --- a/src/main/java/com/stripe/param/InvoiceUpdateParams.java +++ b/src/main/java/com/stripe/param/InvoiceUpdateParams.java @@ -2197,6 +2197,13 @@ public static class PaymentMethodOptions { @SerializedName("card") Object card; + /** + * If paying by {@code check_scan}, this sub-hash contains details about the Check Scan + * payment method options to pass to the invoice’s PaymentIntent. + */ + @SerializedName("check_scan") + Object checkScan; + /** * If paying by {@code customer_balance}, this sub-hash contains details about the Bank * transfer payment method options to pass to the invoice’s PaymentIntent. @@ -2266,6 +2273,7 @@ private PaymentMethodOptions( Object acssDebit, Object bancontact, Object card, + Object checkScan, Object customerBalance, Map extraParams, Object idBankTransfer, @@ -2278,6 +2286,7 @@ private PaymentMethodOptions( this.acssDebit = acssDebit; this.bancontact = bancontact; this.card = card; + this.checkScan = checkScan; this.customerBalance = customerBalance; this.extraParams = extraParams; this.idBankTransfer = idBankTransfer; @@ -2300,6 +2309,8 @@ public static class Builder { private Object card; + private Object checkScan; + private Object customerBalance; private Map extraParams; @@ -2324,6 +2335,7 @@ public InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions build() { this.acssDebit, this.bancontact, this.card, + this.checkScan, this.customerBalance, this.extraParams, this.idBankTransfer, @@ -2391,6 +2403,25 @@ public Builder setCard(EmptyParam card) { return this; } + /** + * If paying by {@code check_scan}, this sub-hash contains details about the Check Scan + * payment method options to pass to the invoice’s PaymentIntent. + */ + public Builder setCheckScan( + InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan checkScan) { + this.checkScan = checkScan; + return this; + } + + /** + * If paying by {@code check_scan}, this sub-hash contains details about the Check Scan + * payment method options to pass to the invoice’s PaymentIntent. + */ + public Builder setCheckScan(EmptyParam checkScan) { + this.checkScan = checkScan; + return this; + } + /** * If paying by {@code customer_balance}, this sub-hash contains details about the Bank * transfer payment method options to pass to the invoice’s PaymentIntent. @@ -3287,6 +3318,256 @@ public enum RequestThreeDSecure implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class CheckScan { + @SerializedName("check_deposit_address") + CheckDepositAddress checkDepositAddress; + + /** + * 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 CheckScan( + CheckDepositAddress checkDepositAddress, Map extraParams) { + this.checkDepositAddress = checkDepositAddress; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private CheckDepositAddress checkDepositAddress; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan build() { + return new InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan( + this.checkDepositAddress, this.extraParams); + } + + public Builder setCheckDepositAddress( + InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan.CheckDepositAddress + checkDepositAddress) { + this.checkDepositAddress = checkDepositAddress; + 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 + * InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan#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 + * InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan#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 + @EqualsAndHashCode(callSuper = false) + public static class CheckDepositAddress { + @SerializedName("city") + Object city; + + @SerializedName("country") + Object country; + + /** + * 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; + + @SerializedName("line1") + Object line1; + + @SerializedName("line2") + Object line2; + + @SerializedName("postal_code") + Object postalCode; + + @SerializedName("state") + Object state; + + private CheckDepositAddress( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object city; + + private Object country; + + private Map extraParams; + + private Object line1; + + private Object line2; + + private Object postalCode; + + private Object state; + + /** Finalize and obtain parameter instance from this builder. */ + public InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan + .CheckDepositAddress + build() { + return new InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan + .CheckDepositAddress( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + public Builder setCity(String city) { + this.city = city; + return this; + } + + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + public Builder setCountry(String country) { + this.country = country; + return this; + } + + public Builder setCountry(EmptyParam country) { + this.country = country; + 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 + * InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan.CheckDepositAddress#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 + * InvoiceUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan.CheckDepositAddress#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; + return this; + } + + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } + + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } + + public Builder setState(String state) { + this.state = state; + return this; + } + + public Builder setState(EmptyParam state) { + this.state = state; + return this; + } + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class CustomerBalance { @@ -4916,6 +5197,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam { @SerializedName("cashapp") CASHAPP("cashapp"), + @SerializedName("check_scan") + CHECK_SCAN("check_scan"), + @SerializedName("crypto") CRYPTO("crypto"), diff --git a/src/main/java/com/stripe/param/SubscriptionCreateParams.java b/src/main/java/com/stripe/param/SubscriptionCreateParams.java index 55a73b7d562..5bf3e609efe 100644 --- a/src/main/java/com/stripe/param/SubscriptionCreateParams.java +++ b/src/main/java/com/stripe/param/SubscriptionCreateParams.java @@ -6351,6 +6351,13 @@ public static class PaymentMethodOptions { @SerializedName("card") Object card; + /** + * This sub-hash contains details about the Check Scan payment method options to pass to the + * invoice’s PaymentIntent. + */ + @SerializedName("check_scan") + Object checkScan; + /** * This sub-hash contains details about the Bank transfer payment method options to pass to * the invoice’s PaymentIntent. @@ -6420,6 +6427,7 @@ private PaymentMethodOptions( Object acssDebit, Object bancontact, Object card, + Object checkScan, Object customerBalance, Map extraParams, Object idBankTransfer, @@ -6432,6 +6440,7 @@ private PaymentMethodOptions( this.acssDebit = acssDebit; this.bancontact = bancontact; this.card = card; + this.checkScan = checkScan; this.customerBalance = customerBalance; this.extraParams = extraParams; this.idBankTransfer = idBankTransfer; @@ -6454,6 +6463,8 @@ public static class Builder { private Object card; + private Object checkScan; + private Object customerBalance; private Map extraParams; @@ -6478,6 +6489,7 @@ public SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions build() { this.acssDebit, this.bancontact, this.card, + this.checkScan, this.customerBalance, this.extraParams, this.idBankTransfer, @@ -6546,6 +6558,25 @@ public Builder setCard(EmptyParam card) { return this; } + /** + * This sub-hash contains details about the Check Scan payment method options to pass to the + * invoice’s PaymentIntent. + */ + public Builder setCheckScan( + SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan checkScan) { + this.checkScan = checkScan; + return this; + } + + /** + * This sub-hash contains details about the Check Scan payment method options to pass to the + * invoice’s PaymentIntent. + */ + public Builder setCheckScan(EmptyParam checkScan) { + this.checkScan = checkScan; + return this; + } + /** * This sub-hash contains details about the Bank transfer payment method options to pass to * the invoice’s PaymentIntent. @@ -7384,6 +7415,227 @@ public enum RequestThreeDSecure implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class CheckScan { + @SerializedName("check_deposit_address") + CheckDepositAddress checkDepositAddress; + + /** + * 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 CheckScan( + CheckDepositAddress checkDepositAddress, Map extraParams) { + this.checkDepositAddress = checkDepositAddress; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private CheckDepositAddress checkDepositAddress; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan build() { + return new SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan( + this.checkDepositAddress, this.extraParams); + } + + public Builder setCheckDepositAddress( + SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan + .CheckDepositAddress + checkDepositAddress) { + this.checkDepositAddress = checkDepositAddress; + 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 + * SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan#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 + * SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan#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 + @EqualsAndHashCode(callSuper = false) + public static class CheckDepositAddress { + @SerializedName("city") + String city; + + @SerializedName("country") + String country; + + /** + * 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; + + @SerializedName("line1") + String line1; + + @SerializedName("line2") + String line2; + + @SerializedName("postal_code") + String postalCode; + + @SerializedName("state") + String state; + + private CheckDepositAddress( + String city, + String country, + Map extraParams, + String line1, + String line2, + String postalCode, + String state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private String city; + + private String country; + + private Map extraParams; + + private String line1; + + private String line2; + + private String postalCode; + + private String state; + + /** Finalize and obtain parameter instance from this builder. */ + public SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan + .CheckDepositAddress + build() { + return new SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan + .CheckDepositAddress( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + public Builder setCity(String city) { + this.city = city; + return this; + } + + public Builder setCountry(String country) { + this.country = country; + 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 + * SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan.CheckDepositAddress#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 + * SubscriptionCreateParams.PaymentSettings.PaymentMethodOptions.CheckScan.CheckDepositAddress#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + public Builder setState(String state) { + this.state = state; + return this; + } + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class CustomerBalance { @@ -9137,6 +9389,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam { @SerializedName("cashapp") CASHAPP("cashapp"), + @SerializedName("check_scan") + CHECK_SCAN("check_scan"), + @SerializedName("crypto") CRYPTO("crypto"), diff --git a/src/main/java/com/stripe/param/SubscriptionUpdateParams.java b/src/main/java/com/stripe/param/SubscriptionUpdateParams.java index d9e9421393c..c1e8b19545f 100644 --- a/src/main/java/com/stripe/param/SubscriptionUpdateParams.java +++ b/src/main/java/com/stripe/param/SubscriptionUpdateParams.java @@ -6427,6 +6427,13 @@ public static class PaymentMethodOptions { @SerializedName("card") Object card; + /** + * This sub-hash contains details about the Check Scan payment method options to pass to the + * invoice’s PaymentIntent. + */ + @SerializedName("check_scan") + Object checkScan; + /** * This sub-hash contains details about the Bank transfer payment method options to pass to * the invoice’s PaymentIntent. @@ -6496,6 +6503,7 @@ private PaymentMethodOptions( Object acssDebit, Object bancontact, Object card, + Object checkScan, Object customerBalance, Map extraParams, Object idBankTransfer, @@ -6508,6 +6516,7 @@ private PaymentMethodOptions( this.acssDebit = acssDebit; this.bancontact = bancontact; this.card = card; + this.checkScan = checkScan; this.customerBalance = customerBalance; this.extraParams = extraParams; this.idBankTransfer = idBankTransfer; @@ -6530,6 +6539,8 @@ public static class Builder { private Object card; + private Object checkScan; + private Object customerBalance; private Map extraParams; @@ -6554,6 +6565,7 @@ public SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions build() { this.acssDebit, this.bancontact, this.card, + this.checkScan, this.customerBalance, this.extraParams, this.idBankTransfer, @@ -6622,6 +6634,25 @@ public Builder setCard(EmptyParam card) { return this; } + /** + * This sub-hash contains details about the Check Scan payment method options to pass to the + * invoice’s PaymentIntent. + */ + public Builder setCheckScan( + SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan checkScan) { + this.checkScan = checkScan; + return this; + } + + /** + * This sub-hash contains details about the Check Scan payment method options to pass to the + * invoice’s PaymentIntent. + */ + public Builder setCheckScan(EmptyParam checkScan) { + this.checkScan = checkScan; + return this; + } + /** * This sub-hash contains details about the Bank transfer payment method options to pass to * the invoice’s PaymentIntent. @@ -7469,6 +7500,257 @@ public enum RequestThreeDSecure implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class CheckScan { + @SerializedName("check_deposit_address") + CheckDepositAddress checkDepositAddress; + + /** + * 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 CheckScan( + CheckDepositAddress checkDepositAddress, Map extraParams) { + this.checkDepositAddress = checkDepositAddress; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private CheckDepositAddress checkDepositAddress; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan build() { + return new SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan( + this.checkDepositAddress, this.extraParams); + } + + public Builder setCheckDepositAddress( + SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan + .CheckDepositAddress + checkDepositAddress) { + this.checkDepositAddress = checkDepositAddress; + 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 + * SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan#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 + * SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan#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 + @EqualsAndHashCode(callSuper = false) + public static class CheckDepositAddress { + @SerializedName("city") + Object city; + + @SerializedName("country") + Object country; + + /** + * 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; + + @SerializedName("line1") + Object line1; + + @SerializedName("line2") + Object line2; + + @SerializedName("postal_code") + Object postalCode; + + @SerializedName("state") + Object state; + + private CheckDepositAddress( + Object city, + Object country, + Map extraParams, + Object line1, + Object line2, + Object postalCode, + Object state) { + this.city = city; + this.country = country; + this.extraParams = extraParams; + this.line1 = line1; + this.line2 = line2; + this.postalCode = postalCode; + this.state = state; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Object city; + + private Object country; + + private Map extraParams; + + private Object line1; + + private Object line2; + + private Object postalCode; + + private Object state; + + /** Finalize and obtain parameter instance from this builder. */ + public SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan + .CheckDepositAddress + build() { + return new SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan + .CheckDepositAddress( + this.city, + this.country, + this.extraParams, + this.line1, + this.line2, + this.postalCode, + this.state); + } + + public Builder setCity(String city) { + this.city = city; + return this; + } + + public Builder setCity(EmptyParam city) { + this.city = city; + return this; + } + + public Builder setCountry(String country) { + this.country = country; + return this; + } + + public Builder setCountry(EmptyParam country) { + this.country = country; + 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 + * SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan.CheckDepositAddress#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 + * SubscriptionUpdateParams.PaymentSettings.PaymentMethodOptions.CheckScan.CheckDepositAddress#extraParams} + * for the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + + public Builder setLine1(String line1) { + this.line1 = line1; + return this; + } + + public Builder setLine1(EmptyParam line1) { + this.line1 = line1; + return this; + } + + public Builder setLine2(String line2) { + this.line2 = line2; + return this; + } + + public Builder setLine2(EmptyParam line2) { + this.line2 = line2; + return this; + } + + public Builder setPostalCode(String postalCode) { + this.postalCode = postalCode; + return this; + } + + public Builder setPostalCode(EmptyParam postalCode) { + this.postalCode = postalCode; + return this; + } + + public Builder setState(String state) { + this.state = state; + return this; + } + + public Builder setState(EmptyParam state) { + this.state = state; + return this; + } + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class CustomerBalance { @@ -9275,6 +9557,9 @@ public enum PaymentMethodType implements ApiRequestParams.EnumParam { @SerializedName("cashapp") CASHAPP("cashapp"), + @SerializedName("check_scan") + CHECK_SCAN("check_scan"), + @SerializedName("crypto") CRYPTO("crypto"), From 5dbbd312a002e7d510388a0e700370fda7aafe74 Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 31 Mar 2026 21:14:25 +0000 Subject: [PATCH 07/11] Update generated code for v2213 and --- OPENAPI_VERSION | 2 +- .../model/sharedpayment/GrantedToken.java | 1905 +++++++++++++++++ 2 files changed, 1906 insertions(+), 1 deletion(-) diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index d3af7b26b1a..bbda295f557 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2212 \ No newline at end of file +v2213 \ No newline at end of file diff --git a/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java b/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java index d2d2ddc575f..88613c91d3d 100644 --- a/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java +++ b/src/main/java/com/stripe/model/sharedpayment/GrantedToken.java @@ -3,7 +3,11 @@ import com.google.gson.annotations.SerializedName; import com.stripe.exception.StripeException; +import com.stripe.model.Address; +import com.stripe.model.Charge; +import com.stripe.model.ExpandableField; import com.stripe.model.HasId; +import com.stripe.model.SetupAttempt; import com.stripe.model.StripeObject; import com.stripe.net.ApiRequest; import com.stripe.net.ApiRequestParams; @@ -15,6 +19,7 @@ import com.stripe.param.sharedpayment.GrantedTokenRetrieveParams; import com.stripe.param.sharedpayment.GrantedTokenRevokeParams; import java.math.BigDecimal; +import java.util.List; import java.util.Map; import lombok.EqualsAndHashCode; import lombok.Getter; @@ -73,6 +78,10 @@ public class GrantedToken extends ApiResource implements HasId { @SerializedName("object") String object; + /** Details of the PaymentMethod that was shared via this token. */ + @SerializedName("payment_method_details") + PaymentMethodDetails paymentMethodDetails; + /** Risk details of the SharedPaymentGrantedToken. */ @SerializedName("risk_details") RiskDetails riskDetails; @@ -145,6 +154,1901 @@ public static class AgentDetails extends StripeObject { String networkBusinessProfile; } + /** Details of the PaymentMethod that was used to create the SharedPaymentGrantedToken. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class PaymentMethodDetails extends StripeObject { + @SerializedName("acss_debit") + AcssDebit acssDebit; + + @SerializedName("affirm") + Affirm affirm; + + @SerializedName("afterpay_clearpay") + AfterpayClearpay afterpayClearpay; + + @SerializedName("alipay") + Alipay alipay; + + @SerializedName("alma") + Alma alma; + + @SerializedName("amazon_pay") + AmazonPay amazonPay; + + @SerializedName("au_becs_debit") + AuBecsDebit auBecsDebit; + + @SerializedName("bacs_debit") + BacsDebit bacsDebit; + + @SerializedName("bancontact") + Bancontact bancontact; + + @SerializedName("billie") + Billie billie; + + /** + * Billing information associated with the PaymentMethod that may be used or required by + * particular types of payment methods. + */ + @SerializedName("billing_details") + BillingDetails billingDetails; + + @SerializedName("blik") + Blik blik; + + @SerializedName("boleto") + Boleto boleto; + + @SerializedName("card") + Card card; + + @SerializedName("card_present") + CardPresent cardPresent; + + @SerializedName("cashapp") + Cashapp cashapp; + + @SerializedName("crypto") + Crypto crypto; + + @SerializedName("customer_balance") + CustomerBalance customerBalance; + + @SerializedName("eps") + Eps eps; + + @SerializedName("fpx") + Fpx fpx; + + @SerializedName("giropay") + Giropay giropay; + + @SerializedName("gopay") + Gopay gopay; + + @SerializedName("grabpay") + Grabpay grabpay; + + @SerializedName("id_bank_transfer") + IdBankTransfer idBankTransfer; + + @SerializedName("ideal") + Ideal ideal; + + @SerializedName("interac_present") + InteracPresent interacPresent; + + @SerializedName("kakao_pay") + KakaoPay kakaoPay; + + @SerializedName("klarna") + Klarna klarna; + + @SerializedName("konbini") + Konbini konbini; + + @SerializedName("kr_card") + KrCard krCard; + + @SerializedName("link") + Link link; + + @SerializedName("mb_way") + MbWay mbWay; + + @SerializedName("mobilepay") + Mobilepay mobilepay; + + @SerializedName("multibanco") + Multibanco multibanco; + + @SerializedName("naver_pay") + NaverPay naverPay; + + @SerializedName("nz_bank_account") + NzBankAccount nzBankAccount; + + @SerializedName("oxxo") + Oxxo oxxo; + + @SerializedName("p24") + P24 p24; + + @SerializedName("pay_by_bank") + PayByBank payByBank; + + @SerializedName("payco") + Payco payco; + + @SerializedName("paynow") + Paynow paynow; + + @SerializedName("paypal") + Paypal paypal; + + @SerializedName("paypay") + Paypay paypay; + + @SerializedName("payto") + Payto payto; + + @SerializedName("pix") + Pix pix; + + @SerializedName("promptpay") + Promptpay promptpay; + + @SerializedName("qris") + Qris qris; + + @SerializedName("rechnung") + Rechnung rechnung; + + @SerializedName("revolut_pay") + RevolutPay revolutPay; + + @SerializedName("samsung_pay") + SamsungPay samsungPay; + + @SerializedName("satispay") + Satispay satispay; + + @SerializedName("sepa_debit") + SepaDebit sepaDebit; + + @SerializedName("shopeepay") + Shopeepay shopeepay; + + @SerializedName("sofort") + Sofort sofort; + + @SerializedName("stripe_balance") + StripeBalance stripeBalance; + + @SerializedName("swish") + Swish swish; + + @SerializedName("twint") + Twint twint; + + /** + * The type of the PaymentMethod. An additional hash is included on the PaymentMethod with a + * name matching this value. It contains additional information specific to the PaymentMethod + * type. + * + *

One of {@code acss_debit}, {@code affirm}, {@code afterpay_clearpay}, {@code alipay}, + * {@code alma}, {@code amazon_pay}, {@code au_becs_debit}, {@code bacs_debit}, {@code + * bancontact}, {@code billie}, {@code blik}, {@code boleto}, {@code card}, {@code + * card_present}, {@code cashapp}, {@code crypto}, {@code custom}, {@code customer_balance}, + * {@code eps}, {@code fpx}, {@code giropay}, {@code gopay}, {@code grabpay}, {@code + * id_bank_transfer}, {@code ideal}, {@code interac_present}, {@code kakao_pay}, {@code klarna}, + * {@code konbini}, {@code kr_card}, {@code link}, {@code mb_way}, {@code mobilepay}, {@code + * multibanco}, {@code naver_pay}, {@code nz_bank_account}, {@code oxxo}, {@code p24}, {@code + * pay_by_bank}, {@code payco}, {@code paynow}, {@code paypal}, {@code paypay}, {@code payto}, + * {@code pix}, {@code promptpay}, {@code qris}, {@code rechnung}, {@code revolut_pay}, {@code + * samsung_pay}, {@code satispay}, {@code sepa_debit}, {@code shopeepay}, {@code sofort}, {@code + * stripe_balance}, {@code swish}, {@code twint}, {@code upi}, {@code us_bank_account}, {@code + * wechat_pay}, or {@code zip}. + */ + @SerializedName("type") + String type; + + @SerializedName("upi") + Upi upi; + + @SerializedName("us_bank_account") + UsBankAccount usBankAccount; + + @SerializedName("wechat_pay") + WechatPay wechatPay; + + @SerializedName("zip") + Zip zip; + + /** + * For more details about AcssDebit, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class AcssDebit extends StripeObject { + /** Account number of the bank account. */ + @SerializedName("account_number") + String accountNumber; + + /** Name of the bank associated with the bank account. */ + @SerializedName("bank_name") + String bankName; + + /** + * Uniquely identifies this particular bank account. You can use this attribute to check + * whether two bank accounts are the same. + */ + @SerializedName("fingerprint") + String fingerprint; + + /** Institution number of the bank account. */ + @SerializedName("institution_number") + String institutionNumber; + + /** Last four digits of the bank account number. */ + @SerializedName("last4") + String last4; + + /** Transit number of the bank account. */ + @SerializedName("transit_number") + String transitNumber; + } + + /** + * For more details about Affirm, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Affirm extends StripeObject {} + + /** + * For more details about AfterpayClearpay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class AfterpayClearpay extends StripeObject {} + + /** + * For more details about Alipay, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Alipay extends StripeObject {} + + /** + * For more details about Alma, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Alma extends StripeObject {} + + /** + * For more details about AmazonPay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class AmazonPay extends StripeObject {} + + /** + * For more details about AuBecsDebit, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class AuBecsDebit extends StripeObject { + /** Six-digit number identifying bank and branch associated with this bank account. */ + @SerializedName("bsb_number") + String bsbNumber; + + /** + * Uniquely identifies this particular bank account. You can use this attribute to check + * whether two bank accounts are the same. + */ + @SerializedName("fingerprint") + String fingerprint; + + /** Last four digits of the bank account number. */ + @SerializedName("last4") + String last4; + } + + /** + * For more details about BacsDebit, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class BacsDebit extends StripeObject { + /** + * Uniquely identifies this particular bank account. You can use this attribute to check + * whether two bank accounts are the same. + */ + @SerializedName("fingerprint") + String fingerprint; + + /** Last four digits of the bank account number. */ + @SerializedName("last4") + String last4; + + /** Sort code of the bank account. (e.g., {@code 10-20-30}) */ + @SerializedName("sort_code") + String sortCode; + } + + /** + * For more details about Bancontact, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Bancontact extends StripeObject {} + + /** + * For more details about Billie, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Billie extends StripeObject {} + + /** + * For more details about BillingDetails, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class BillingDetails extends StripeObject { + /** Billing address. */ + @SerializedName("address") + Address address; + + /** Email address. */ + @SerializedName("email") + String email; + + /** Full name. */ + @SerializedName("name") + String name; + + /** Billing phone number (including extension). */ + @SerializedName("phone") + String phone; + + /** + * Taxpayer identification number. Used only for transactions between LATAM buyers and + * non-LATAM sellers. + */ + @SerializedName("tax_id") + String taxId; + } + + /** + * For more details about Blik, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Blik extends StripeObject {} + + /** + * For more details about Boleto, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Boleto extends StripeObject { + /** Uniquely identifies the customer tax id (CNPJ or CPF). */ + @SerializedName("tax_id") + String taxId; + } + + /** + * For more details about Card, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Card extends StripeObject { + /** + * Card brand. Can be {@code amex}, {@code cartes_bancaires}, {@code diners}, {@code + * discover}, {@code eftpos_au}, {@code jcb}, {@code link}, {@code mastercard}, {@code + * unionpay}, {@code visa} or {@code unknown}. + */ + @SerializedName("brand") + String brand; + + /** Checks on Card address and CVC if provided. */ + @SerializedName("checks") + Checks checks; + + /** + * Two-letter ISO code representing the country of the card. You could use this attribute to + * get a sense of the international breakdown of cards you've collected. + */ + @SerializedName("country") + String country; + + /** + * A high-level description of the type of cards issued in this range. (For internal use only + * and not typically available in standard API requests.) + */ + @SerializedName("description") + String description; + + /** + * The brand to use when displaying the card, this accounts for customer's brand choice on + * dual-branded cards. Can be {@code american_express}, {@code cartes_bancaires}, {@code + * diners_club}, {@code discover}, {@code eftpos_australia}, {@code interac}, {@code jcb}, + * {@code mastercard}, {@code union_pay}, {@code visa}, or {@code other} and may contain more + * values in the future. + */ + @SerializedName("display_brand") + String displayBrand; + + /** Two-digit number representing the card's expiration month. */ + @SerializedName("exp_month") + Long expMonth; + + /** Four-digit number representing the card's expiration year. */ + @SerializedName("exp_year") + Long expYear; + + /** + * Uniquely identifies this particular card number. You can use this attribute to check + * whether two customers who’ve signed up with you are using the same card number, for + * example. For payment methods that tokenize card information (Apple Pay, Google Pay), the + * tokenized number might be provided instead of the underlying card number. + * + *

As of May 1, 2021, card fingerprint in India for Connect changed to allow two + * fingerprints for the same card---one for India and one for the rest of the world. + */ + @SerializedName("fingerprint") + String fingerprint; + + /** + * Card funding type. Can be {@code credit}, {@code debit}, {@code prepaid}, or {@code + * unknown}. + */ + @SerializedName("funding") + String funding; + + /** + * Issuer identification number of the card. (For internal use only and not typically + * available in standard API requests.) + */ + @SerializedName("iin") + String iin; + + /** + * The name of the card's issuing bank. (For internal use only and not typically available in + * standard API requests.) + */ + @SerializedName("issuer") + String issuer; + + /** The last four digits of the card. */ + @SerializedName("last4") + String last4; + + /** Contains information about card networks that can be used to process the payment. */ + @SerializedName("networks") + Networks networks; + + /** If this Card is part of a card wallet, this contains the details of the card wallet. */ + @SerializedName("wallet") + Wallet wallet; + + /** + * For more details about Checks, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Checks extends StripeObject { + /** + * If a address line1 was provided, results of the check, one of {@code pass}, {@code fail}, + * {@code unavailable}, or {@code unchecked}. + */ + @SerializedName("address_line1_check") + String addressLine1Check; + + /** + * If a address postal code was provided, results of the check, one of {@code pass}, {@code + * fail}, {@code unavailable}, or {@code unchecked}. + */ + @SerializedName("address_postal_code_check") + String addressPostalCodeCheck; + + /** + * If a CVC was provided, results of the check, one of {@code pass}, {@code fail}, {@code + * unavailable}, or {@code unchecked}. + */ + @SerializedName("cvc_check") + String cvcCheck; + } + + /** + * For more details about Networks, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Networks extends StripeObject { + /** + * All networks available for selection via payment_method_options.card.network. + */ + @SerializedName("available") + List available; + + /** + * The preferred network for co-branded cards. Can be {@code cartes_bancaires}, {@code + * mastercard}, {@code visa} or {@code invalid_preference} if requested network is not valid + * for the card. + */ + @SerializedName("preferred") + String preferred; + } + + /** + * For more details about Wallet, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Wallet extends StripeObject { + @SerializedName("amex_express_checkout") + AmexExpressCheckout amexExpressCheckout; + + @SerializedName("apple_pay") + ApplePay applePay; + + /** (For tokenized numbers only.) The last four digits of the device account number. */ + @SerializedName("dynamic_last4") + String dynamicLast4; + + @SerializedName("google_pay") + GooglePay googlePay; + + @SerializedName("link") + Link link; + + @SerializedName("masterpass") + Masterpass masterpass; + + @SerializedName("samsung_pay") + SamsungPay samsungPay; + + /** + * The type of the card wallet, one of {@code amex_express_checkout}, {@code apple_pay}, + * {@code google_pay}, {@code masterpass}, {@code samsung_pay}, {@code visa_checkout}, or + * {@code link}. An additional hash is included on the Wallet subhash with a name matching + * this value. It contains additional information specific to the card wallet type. + */ + @SerializedName("type") + String type; + + @SerializedName("visa_checkout") + VisaCheckout visaCheckout; + + /** + * For more details about AmexExpressCheckout, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class AmexExpressCheckout extends StripeObject {} + + /** + * For more details about ApplePay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class ApplePay extends StripeObject {} + + /** + * For more details about GooglePay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class GooglePay extends StripeObject {} + + /** + * For more details about Link, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Link extends StripeObject {} + + /** + * For more details about Masterpass, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Masterpass extends StripeObject { + /** + * Owner's verified billing address. Values are verified or provided by the wallet + * directly (if supported) at the time of authorization or settlement. They cannot be set + * or mutated. + */ + @SerializedName("billing_address") + Address billingAddress; + + /** + * Owner's verified email. Values are verified or provided by the wallet directly (if + * supported) at the time of authorization or settlement. They cannot be set or mutated. + */ + @SerializedName("email") + String email; + + /** + * Owner's verified full name. Values are verified or provided by the wallet directly (if + * supported) at the time of authorization or settlement. They cannot be set or mutated. + */ + @SerializedName("name") + String name; + + /** + * Owner's verified shipping address. Values are verified or provided by the wallet + * directly (if supported) at the time of authorization or settlement. They cannot be set + * or mutated. + */ + @SerializedName("shipping_address") + Address shippingAddress; + } + + /** + * For more details about SamsungPay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class SamsungPay extends StripeObject {} + + /** + * For more details about VisaCheckout, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class VisaCheckout extends StripeObject { + /** + * Owner's verified billing address. Values are verified or provided by the wallet + * directly (if supported) at the time of authorization or settlement. They cannot be set + * or mutated. + */ + @SerializedName("billing_address") + Address billingAddress; + + /** + * Owner's verified email. Values are verified or provided by the wallet directly (if + * supported) at the time of authorization or settlement. They cannot be set or mutated. + */ + @SerializedName("email") + String email; + + /** + * Owner's verified full name. Values are verified or provided by the wallet directly (if + * supported) at the time of authorization or settlement. They cannot be set or mutated. + */ + @SerializedName("name") + String name; + + /** + * Owner's verified shipping address. Values are verified or provided by the wallet + * directly (if supported) at the time of authorization or settlement. They cannot be set + * or mutated. + */ + @SerializedName("shipping_address") + Address shippingAddress; + } + } + } + + /** + * For more details about CardPresent, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CardPresent extends StripeObject { + /** + * Card brand. Can be {@code amex}, {@code cartes_bancaires}, {@code diners}, {@code + * discover}, {@code eftpos_au}, {@code jcb}, {@code link}, {@code mastercard}, {@code + * unionpay}, {@code visa} or {@code unknown}. + */ + @SerializedName("brand") + String brand; + + /** + * The product code that identifies + * the specific program or product associated with a card. + */ + @SerializedName("brand_product") + String brandProduct; + + /** + * The cardholder name as read from the card, in ISO 7813 format. May include + * alphanumeric characters, special characters and first/last name separator ({@code /}). In + * some cases, the cardholder name may not be available depending on how the issuer has + * configured the card. Cardholder name is typically not available on swipe or contactless + * payments, such as those made with Apple Pay and Google Pay. + */ + @SerializedName("cardholder_name") + String cardholderName; + + /** + * Two-letter ISO code representing the country of the card. You could use this attribute to + * get a sense of the international breakdown of cards you've collected. + */ + @SerializedName("country") + String country; + + /** + * A high-level description of the type of cards issued in this range. (For internal use only + * and not typically available in standard API requests.) + */ + @SerializedName("description") + String description; + + /** Two-digit number representing the card's expiration month. */ + @SerializedName("exp_month") + Long expMonth; + + /** Four-digit number representing the card's expiration year. */ + @SerializedName("exp_year") + Long expYear; + + /** + * Uniquely identifies this particular card number. You can use this attribute to check + * whether two customers who’ve signed up with you are using the same card number, for + * example. For payment methods that tokenize card information (Apple Pay, Google Pay), the + * tokenized number might be provided instead of the underlying card number. + * + *

As of May 1, 2021, card fingerprint in India for Connect changed to allow two + * fingerprints for the same card---one for India and one for the rest of the world. + */ + @SerializedName("fingerprint") + String fingerprint; + + /** + * Card funding type. Can be {@code credit}, {@code debit}, {@code prepaid}, or {@code + * unknown}. + */ + @SerializedName("funding") + String funding; + + /** + * Issuer identification number of the card. (For internal use only and not typically + * available in standard API requests.) + */ + @SerializedName("iin") + String iin; + + /** + * The name of the card's issuing bank. (For internal use only and not typically available in + * standard API requests.) + */ + @SerializedName("issuer") + String issuer; + + /** The last four digits of the card. */ + @SerializedName("last4") + String last4; + + /** Contains information about card networks that can be used to process the payment. */ + @SerializedName("networks") + Networks networks; + + /** Details about payment methods collected offline. */ + @SerializedName("offline") + Offline offline; + + /** + * The languages that the issuing bank recommends using for localizing any customer-facing + * text, as read from the card. Referenced from EMV tag 5F2D, data encoded on the card's chip. + */ + @SerializedName("preferred_locales") + List preferredLocales; + + /** + * How card details were read in this transaction. + * + *

One of {@code contact_emv}, {@code contactless_emv}, {@code contactless_magstripe_mode}, + * {@code magnetic_stripe_fallback}, or {@code magnetic_stripe_track2}. + */ + @SerializedName("read_method") + String readMethod; + + @SerializedName("wallet") + Wallet wallet; + + /** + * For more details about Networks, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Networks extends StripeObject { + /** + * All networks available for selection via payment_method_options.card.network. + */ + @SerializedName("available") + List available; + + /** The preferred network for the card. */ + @SerializedName("preferred") + String preferred; + } + + /** + * For more details about Offline, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Offline extends StripeObject { + /** Time at which the payment was collected while offline. */ + @SerializedName("stored_at") + Long storedAt; + + /** + * The method used to process this payment method offline. Only deferred is allowed. + * + *

Equal to {@code deferred}. + */ + @SerializedName("type") + String type; + } + + /** + * For more details about Wallet, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Wallet extends StripeObject { + /** + * The type of mobile wallet, one of {@code apple_pay}, {@code google_pay}, {@code + * samsung_pay}, or {@code unknown}. + */ + @SerializedName("type") + String type; + } + } + + /** + * For more details about Cashapp, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Cashapp extends StripeObject { + /** A unique and immutable identifier assigned by Cash App to every buyer. */ + @SerializedName("buyer_id") + String buyerId; + + /** A public identifier for buyers using Cash App. */ + @SerializedName("cashtag") + String cashtag; + } + + /** + * For more details about Crypto, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Crypto extends StripeObject {} + + /** + * For more details about CustomerBalance, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class CustomerBalance extends StripeObject {} + + /** + * For more details about Eps, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Eps extends StripeObject { + /** + * The customer's bank. Should be one of {@code arzte_und_apotheker_bank}, {@code + * austrian_anadi_bank_ag}, {@code bank_austria}, {@code bankhaus_carl_spangler}, {@code + * bankhaus_schelhammer_und_schattera_ag}, {@code bawag_psk_ag}, {@code bks_bank_ag}, {@code + * brull_kallmus_bank_ag}, {@code btv_vier_lander_bank}, {@code capital_bank_grawe_gruppe_ag}, + * {@code deutsche_bank_ag}, {@code dolomitenbank}, {@code easybank_ag}, {@code + * erste_bank_und_sparkassen}, {@code hypo_alpeadriabank_international_ag}, {@code + * hypo_noe_lb_fur_niederosterreich_u_wien}, {@code hypo_oberosterreich_salzburg_steiermark}, + * {@code hypo_tirol_bank_ag}, {@code hypo_vorarlberg_bank_ag}, {@code + * hypo_bank_burgenland_aktiengesellschaft}, {@code marchfelder_bank}, {@code oberbank_ag}, + * {@code raiffeisen_bankengruppe_osterreich}, {@code schoellerbank_ag}, {@code + * sparda_bank_wien}, {@code volksbank_gruppe}, {@code volkskreditbank_ag}, or {@code + * vr_bank_braunau}. + */ + @SerializedName("bank") + String bank; + } + + /** + * For more details about Fpx, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Fpx extends StripeObject { + /** Account holder type, if provided. Can be one of {@code individual} or {@code company}. */ + @SerializedName("account_holder_type") + String accountHolderType; + + /** + * The customer's bank, if provided. Can be one of {@code affin_bank}, {@code agrobank}, + * {@code alliance_bank}, {@code ambank}, {@code bank_islam}, {@code bank_muamalat}, {@code + * bank_rakyat}, {@code bsn}, {@code cimb}, {@code hong_leong_bank}, {@code hsbc}, {@code + * kfh}, {@code maybank2u}, {@code ocbc}, {@code public_bank}, {@code rhb}, {@code + * standard_chartered}, {@code uob}, {@code deutsche_bank}, {@code maybank2e}, {@code + * pb_enterprise}, or {@code bank_of_china}. + */ + @SerializedName("bank") + String bank; + } + + /** + * For more details about Giropay, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Giropay extends StripeObject {} + + /** + * For more details about Gopay, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Gopay extends StripeObject {} + + /** + * For more details about Grabpay, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Grabpay extends StripeObject {} + + /** + * For more details about IdBankTransfer, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class IdBankTransfer extends StripeObject { + @SerializedName("bank") + String bank; + + @SerializedName("bank_code") + String bankCode; + + @SerializedName("bank_name") + String bankName; + + @SerializedName("display_name") + String displayName; + } + + /** + * For more details about Ideal, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Ideal extends StripeObject { + /** + * The customer's bank, if provided. Can be one of {@code abn_amro}, {@code adyen}, {@code + * asn_bank}, {@code bunq}, {@code buut}, {@code finom}, {@code handelsbanken}, {@code ing}, + * {@code knab}, {@code mollie}, {@code moneyou}, {@code n26}, {@code nn}, {@code rabobank}, + * {@code regiobank}, {@code revolut}, {@code sns_bank}, {@code triodos_bank}, {@code + * van_lanschot}, or {@code yoursafe}. + */ + @SerializedName("bank") + String bank; + + /** + * The Bank Identifier Code of the customer's bank, if the bank was provided. + * + *

One of {@code ABNANL2A}, {@code ADYBNL2A}, {@code ASNBNL21}, {@code BITSNL2A}, {@code + * BUNQNL2A}, {@code BUUTNL2A}, {@code FNOMNL22}, {@code FVLBNL22}, {@code HANDNL2A}, {@code + * INGBNL2A}, {@code KNABNL2H}, {@code MLLENL2A}, {@code MOYONL21}, {@code NNBANL2G}, {@code + * NTSBDEB1}, {@code RABONL2U}, {@code RBRBNL21}, {@code REVOIE23}, {@code REVOLT21}, {@code + * SNSBNL2A}, or {@code TRIONL2U}. + */ + @SerializedName("bic") + String bic; + } + + /** + * For more details about InteracPresent, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class InteracPresent extends StripeObject { + /** Card brand. Can be {@code interac}, {@code mastercard} or {@code visa}. */ + @SerializedName("brand") + String brand; + + /** + * The cardholder name as read from the card, in ISO 7813 format. May include + * alphanumeric characters, special characters and first/last name separator ({@code /}). In + * some cases, the cardholder name may not be available depending on how the issuer has + * configured the card. Cardholder name is typically not available on swipe or contactless + * payments, such as those made with Apple Pay and Google Pay. + */ + @SerializedName("cardholder_name") + String cardholderName; + + /** + * Two-letter ISO code representing the country of the card. You could use this attribute to + * get a sense of the international breakdown of cards you've collected. + */ + @SerializedName("country") + String country; + + /** + * A high-level description of the type of cards issued in this range. (For internal use only + * and not typically available in standard API requests.) + */ + @SerializedName("description") + String description; + + /** Two-digit number representing the card's expiration month. */ + @SerializedName("exp_month") + Long expMonth; + + /** Four-digit number representing the card's expiration year. */ + @SerializedName("exp_year") + Long expYear; + + /** + * Uniquely identifies this particular card number. You can use this attribute to check + * whether two customers who’ve signed up with you are using the same card number, for + * example. For payment methods that tokenize card information (Apple Pay, Google Pay), the + * tokenized number might be provided instead of the underlying card number. + * + *

As of May 1, 2021, card fingerprint in India for Connect changed to allow two + * fingerprints for the same card---one for India and one for the rest of the world. + */ + @SerializedName("fingerprint") + String fingerprint; + + /** + * Card funding type. Can be {@code credit}, {@code debit}, {@code prepaid}, or {@code + * unknown}. + */ + @SerializedName("funding") + String funding; + + /** + * Issuer identification number of the card. (For internal use only and not typically + * available in standard API requests.) + */ + @SerializedName("iin") + String iin; + + /** + * The name of the card's issuing bank. (For internal use only and not typically available in + * standard API requests.) + */ + @SerializedName("issuer") + String issuer; + + /** The last four digits of the card. */ + @SerializedName("last4") + String last4; + + /** Contains information about card networks that can be used to process the payment. */ + @SerializedName("networks") + Networks networks; + + /** + * The languages that the issuing bank recommends using for localizing any customer-facing + * text, as read from the card. Referenced from EMV tag 5F2D, data encoded on the card's chip. + */ + @SerializedName("preferred_locales") + List preferredLocales; + + /** + * How card details were read in this transaction. + * + *

One of {@code contact_emv}, {@code contactless_emv}, {@code contactless_magstripe_mode}, + * {@code magnetic_stripe_fallback}, or {@code magnetic_stripe_track2}. + */ + @SerializedName("read_method") + String readMethod; + + /** + * For more details about Networks, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Networks extends StripeObject { + /** + * All networks available for selection via payment_method_options.card.network. + */ + @SerializedName("available") + List available; + + /** The preferred network for the card. */ + @SerializedName("preferred") + String preferred; + } + } + + /** + * For more details about KakaoPay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class KakaoPay extends StripeObject {} + + /** + * For more details about Klarna, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Klarna extends StripeObject { + /** The customer's date of birth, if provided. */ + @SerializedName("dob") + Dob dob; + + /** + * For more details about Dob, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Dob extends StripeObject { + /** The day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; + + /** The month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; + + /** The four-digit year of birth. */ + @SerializedName("year") + Long year; + } + } + + /** + * For more details about Konbini, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Konbini extends StripeObject {} + + /** + * For more details about KrCard, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class KrCard extends StripeObject { + /** + * The local credit or debit card brand. + * + *

One of {@code bc}, {@code citi}, {@code hana}, {@code hyundai}, {@code jeju}, {@code + * jeonbuk}, {@code kakaobank}, {@code kbank}, {@code kdbbank}, {@code kookmin}, {@code + * kwangju}, {@code lotte}, {@code mg}, {@code nh}, {@code post}, {@code samsung}, {@code + * savingsbank}, {@code shinhan}, {@code shinhyup}, {@code suhyup}, {@code tossbank}, or + * {@code woori}. + */ + @SerializedName("brand") + String brand; + + /** The last four digits of the card. This may not be present for American Express cards. */ + @SerializedName("last4") + String last4; + } + + /** + * For more details about Link, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Link extends StripeObject { + /** Account owner's email address. */ + @SerializedName("email") + String email; + + /** [Deprecated] This is a legacy parameter that no longer has any function. */ + @SerializedName("persistent_token") + @Deprecated + String persistentToken; + } + + /** + * For more details about MbWay, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class MbWay extends StripeObject {} + + /** + * For more details about Mobilepay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Mobilepay extends StripeObject {} + + /** + * For more details about Multibanco, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Multibanco extends StripeObject {} + + /** + * For more details about NaverPay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class NaverPay extends StripeObject { + /** + * Uniquely identifies this particular Naver Pay account. You can use this attribute to check + * whether two Naver Pay accounts are the same. + */ + @SerializedName("buyer_id") + String buyerId; + + /** + * Whether to fund this transaction with Naver Pay points or a card. + * + *

One of {@code card}, or {@code points}. + */ + @SerializedName("funding") + String funding; + } + + /** + * For more details about NzBankAccount, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class NzBankAccount extends StripeObject { + /** + * The name on the bank account. Only present if the account holder name is different from the + * name of the authorized signatory collected in the PaymentMethod’s billing details. + */ + @SerializedName("account_holder_name") + String accountHolderName; + + /** The numeric code for the bank account's bank. */ + @SerializedName("bank_code") + String bankCode; + + /** The name of the bank. */ + @SerializedName("bank_name") + String bankName; + + /** The numeric code for the bank account's bank branch. */ + @SerializedName("branch_code") + String branchCode; + + /** Last four digits of the bank account number. */ + @SerializedName("last4") + String last4; + + /** The suffix of the bank account number. */ + @SerializedName("suffix") + String suffix; + } + + /** + * For more details about Oxxo, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Oxxo extends StripeObject {} + + /** + * For more details about P24, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class P24 extends StripeObject { + /** + * The customer's bank, if provided. + * + *

One of {@code alior_bank}, {@code bank_millennium}, {@code bank_nowy_bfg_sa}, {@code + * bank_pekao_sa}, {@code banki_spbdzielcze}, {@code blik}, {@code bnp_paribas}, {@code boz}, + * {@code citi_handlowy}, {@code credit_agricole}, {@code envelobank}, {@code + * etransfer_pocztowy24}, {@code getin_bank}, {@code ideabank}, {@code ing}, {@code inteligo}, + * {@code mbank_mtransfer}, {@code nest_przelew}, {@code noble_pay}, {@code pbac_z_ipko}, + * {@code plus_bank}, {@code santander_przelew24}, {@code tmobile_usbugi_bankowe}, {@code + * toyota_bank}, {@code velobank}, or {@code volkswagen_bank}. + */ + @SerializedName("bank") + String bank; + } + + /** + * For more details about PayByBank, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class PayByBank extends StripeObject {} + + /** + * For more details about Payco, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Payco extends StripeObject {} + + /** + * For more details about Paynow, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Paynow extends StripeObject {} + + /** + * For more details about Paypal, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Paypal extends StripeObject { + /** + * Two-letter ISO code representing the buyer's country. Values are provided by PayPal + * directly (if supported) at the time of authorization or settlement. They cannot be set or + * mutated. + */ + @SerializedName("country") + String country; + + /** + * Uniquely identifies this particular PayPal account. You can use this attribute to check + * whether two PayPal accounts are the same. + */ + @SerializedName("fingerprint") + String fingerprint; + + /** + * Owner's email. Values are provided by PayPal directly (if supported) at the time of + * authorization or settlement. They cannot be set or mutated. + */ + @SerializedName("payer_email") + String payerEmail; + + /** PayPal account PayerID. This identifier uniquely identifies the PayPal customer. */ + @SerializedName("payer_id") + String payerId; + + /** + * Owner's verified email. Values are verified or provided by PayPal directly (if supported) + * at the time of authorization or settlement. They cannot be set or mutated. + */ + @SerializedName("verified_email") + String verifiedEmail; + } + + /** + * For more details about Paypay, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Paypay extends StripeObject {} + + /** + * For more details about Payto, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Payto extends StripeObject { + /** Bank-State-Branch number of the bank account. */ + @SerializedName("bsb_number") + String bsbNumber; + + /** Last four digits of the bank account number. */ + @SerializedName("last4") + String last4; + + /** The PayID alias for the bank account. */ + @SerializedName("pay_id") + String payId; + } + + /** + * For more details about Pix, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Pix extends StripeObject {} + + /** + * For more details about Promptpay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Promptpay extends StripeObject {} + + /** + * For more details about Qris, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Qris extends StripeObject {} + + /** + * For more details about Rechnung, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Rechnung extends StripeObject { + @SerializedName("dob") + Dob dob; + + /** + * For more details about Dob, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Dob extends StripeObject { + /** The day of birth, between 1 and 31. */ + @SerializedName("day") + Long day; + + /** The month of birth, between 1 and 12. */ + @SerializedName("month") + Long month; + + /** The four-digit year of birth. */ + @SerializedName("year") + Long year; + } + } + + /** + * For more details about RevolutPay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class RevolutPay extends StripeObject {} + + /** + * For more details about SamsungPay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class SamsungPay extends StripeObject {} + + /** + * For more details about Satispay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Satispay extends StripeObject {} + + /** + * For more details about SepaDebit, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class SepaDebit extends StripeObject { + /** Bank code of bank associated with the bank account. */ + @SerializedName("bank_code") + String bankCode; + + /** Branch code of bank associated with the bank account. */ + @SerializedName("branch_code") + String branchCode; + + /** Two-letter ISO code representing the country the bank account is located in. */ + @SerializedName("country") + String country; + + /** + * Uniquely identifies this particular bank account. You can use this attribute to check + * whether two bank accounts are the same. + */ + @SerializedName("fingerprint") + String fingerprint; + + /** Information about the object that generated this PaymentMethod. */ + @SerializedName("generated_from") + GeneratedFrom generatedFrom; + + /** Last four characters of the IBAN. */ + @SerializedName("last4") + String last4; + + /** + * For more details about GeneratedFrom, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class GeneratedFrom extends StripeObject { + /** The ID of the Charge that generated this PaymentMethod, if any. */ + @SerializedName("charge") + @Getter(lombok.AccessLevel.NONE) + @Setter(lombok.AccessLevel.NONE) + ExpandableField charge; + + /** The ID of the SetupAttempt that generated this PaymentMethod, if any. */ + @SerializedName("setup_attempt") + @Getter(lombok.AccessLevel.NONE) + @Setter(lombok.AccessLevel.NONE) + ExpandableField setupAttempt; + + /** Get ID of expandable {@code charge} object. */ + public String getCharge() { + return (this.charge != null) ? this.charge.getId() : null; + } + + public void setCharge(String id) { + this.charge = ApiResource.setExpandableFieldId(id, this.charge); + } + + /** Get expanded {@code charge}. */ + public Charge getChargeObject() { + return (this.charge != null) ? this.charge.getExpanded() : null; + } + + public void setChargeObject(Charge expandableObject) { + this.charge = new ExpandableField(expandableObject.getId(), expandableObject); + } + + /** Get ID of expandable {@code setupAttempt} object. */ + public String getSetupAttempt() { + return (this.setupAttempt != null) ? this.setupAttempt.getId() : null; + } + + public void setSetupAttempt(String id) { + this.setupAttempt = ApiResource.setExpandableFieldId(id, this.setupAttempt); + } + + /** Get expanded {@code setupAttempt}. */ + public SetupAttempt getSetupAttemptObject() { + return (this.setupAttempt != null) ? this.setupAttempt.getExpanded() : null; + } + + public void setSetupAttemptObject(SetupAttempt expandableObject) { + this.setupAttempt = + new ExpandableField(expandableObject.getId(), expandableObject); + } + } + } + + /** + * For more details about Shopeepay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Shopeepay extends StripeObject {} + + /** + * For more details about Sofort, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Sofort extends StripeObject { + /** Two-letter ISO code representing the country the bank account is located in. */ + @SerializedName("country") + String country; + } + + /** + * For more details about StripeBalance, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class StripeBalance extends StripeObject { + /** The connected account ID whose Stripe balance to use as the source of payment. */ + @SerializedName("account") + String account; + } + + /** + * For more details about Swish, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Swish extends StripeObject {} + + /** + * For more details about Twint, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Twint extends StripeObject {} + + /** + * For more details about Upi, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Upi extends StripeObject { + /** Customer's unique Virtual Payment Address. */ + @SerializedName("vpa") + String vpa; + } + + /** + * For more details about UsBankAccount, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class UsBankAccount extends StripeObject { + /** + * Account holder type: individual or company. + * + *

One of {@code company}, or {@code individual}. + */ + @SerializedName("account_holder_type") + String accountHolderType; + + /** Account number of the bank account. */ + @SerializedName("account_number") + String accountNumber; + + /** + * Account type: checkings or savings. Defaults to checking if omitted. + * + *

One of {@code checking}, or {@code savings}. + */ + @SerializedName("account_type") + String accountType; + + /** The name of the bank. */ + @SerializedName("bank_name") + String bankName; + + /** The ID of the Financial Connections Account used to create the payment method. */ + @SerializedName("financial_connections_account") + String financialConnectionsAccount; + + /** + * Uniquely identifies this particular bank account. You can use this attribute to check + * whether two bank accounts are the same. + */ + @SerializedName("fingerprint") + String fingerprint; + + /** Last four digits of the bank account number. */ + @SerializedName("last4") + String last4; + + /** Contains information about US bank account networks that can be used. */ + @SerializedName("networks") + Networks networks; + + /** Routing number of the bank account. */ + @SerializedName("routing_number") + String routingNumber; + + /** Contains information about the future reusability of this PaymentMethod. */ + @SerializedName("status_details") + StatusDetails statusDetails; + + /** + * For more details about Networks, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Networks extends StripeObject { + /** The preferred network. */ + @SerializedName("preferred") + String preferred; + + /** All supported networks. */ + @SerializedName("supported") + List supported; + } + + /** + * For more details about StatusDetails, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class StatusDetails extends StripeObject { + @SerializedName("blocked") + Blocked blocked; + + /** + * For more details about Blocked, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Blocked extends StripeObject { + /** + * The ACH network code that resulted in this block. + * + *

One of {@code R02}, {@code R03}, {@code R04}, {@code R05}, {@code R07}, {@code R08}, + * {@code R10}, {@code R11}, {@code R16}, {@code R20}, {@code R29}, or {@code R31}. + */ + @SerializedName("network_code") + String networkCode; + + /** + * The reason why this PaymentMethod's fingerprint has been blocked + * + *

One of {@code bank_account_closed}, {@code bank_account_frozen}, {@code + * bank_account_invalid_details}, {@code bank_account_restricted}, {@code + * bank_account_unusable}, {@code debit_not_authorized}, or {@code + * tokenized_account_number_deactivated}. + */ + @SerializedName("reason") + String reason; + } + } + } + + /** + * For more details about WechatPay, please refer to the API Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class WechatPay extends StripeObject {} + + /** + * For more details about Zip, please refer to the API + * Reference. + */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Zip extends StripeObject {} + } + /** Risk details of the SharedPaymentGrantedToken. */ @Getter @Setter @@ -446,6 +2350,7 @@ public GrantedToken revoke(GrantedTokenRevokeParams params, RequestOptions optio public void setResponseGetter(StripeResponseGetter responseGetter) { super.setResponseGetter(responseGetter); trySetResponseGetter(agentDetails, responseGetter); + trySetResponseGetter(paymentMethodDetails, responseGetter); trySetResponseGetter(riskDetails, responseGetter); trySetResponseGetter(usageDetails, responseGetter); trySetResponseGetter(usageLimits, responseGetter); From f5c51304739718bb779f2f439db13bb0dc025563 Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 31 Mar 2026 21:38:44 +0000 Subject: [PATCH 08/11] Update generated code for v2214 and --- CODEGEN_VERSION | 2 +- OPENAPI_VERSION | 2 +- .../billing/MeterEventSummariesParams.java | 113 ++++++++++++++++++ .../billing/MeterEventSummaryListParams.java | 113 ++++++++++++++++++ 4 files changed, 228 insertions(+), 2 deletions(-) diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index ffc4d55dce5..77246263926 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -3276ebff880bc62a0bcd63e41d8570598398a6c1 \ No newline at end of file +87c1ac7f6f36c29a3f3fe64a4cb46bafbfce59b0 \ No newline at end of file diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index bbda295f557..0ec6d10cc3c 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2213 \ No newline at end of file +v2214 \ No newline at end of file diff --git a/src/main/java/com/stripe/param/billing/MeterEventSummariesParams.java b/src/main/java/com/stripe/param/billing/MeterEventSummariesParams.java index c6028960f01..e3d8f87d99d 100644 --- a/src/main/java/com/stripe/param/billing/MeterEventSummariesParams.java +++ b/src/main/java/com/stripe/param/billing/MeterEventSummariesParams.java @@ -83,6 +83,28 @@ public class MeterEventSummariesParams extends ApiRequestParams { @SerializedName("starting_after") String startingAfter; + /** + * List of tenant payload keys to filter on. Must be used together with tenant_operator and + * tenant_values. Cannot be used with tenant_filters. + */ + @SerializedName("tenant_keys") + List tenantKeys; + + /** + * The operator to apply when filtering by tenant values. Must be used together with tenant_keys + * and tenant_values. Cannot be used with tenant_filters. + */ + @SerializedName("tenant_operator") + TenantOperator tenantOperator; + + /** + * List of value lists corresponding to each key in tenant_keys. Each element contains the values + * to filter on for the corresponding tenant key. Must be used together with tenant_operator and + * tenant_keys. Cannot be used with tenant_filters. + */ + @SerializedName("tenant_values") + List> tenantValues; + /** * Specifies what granularity to use when generating event summaries. If not specified, a single * event summary would be returned for the specified time range. For hourly granularity, start and @@ -103,6 +125,9 @@ private MeterEventSummariesParams( Long limit, Long startTime, String startingAfter, + List tenantKeys, + TenantOperator tenantOperator, + List> tenantValues, ValueGroupingWindow valueGroupingWindow) { this.customer = customer; this.dimensionFilters = dimensionFilters; @@ -114,6 +139,9 @@ private MeterEventSummariesParams( this.limit = limit; this.startTime = startTime; this.startingAfter = startingAfter; + this.tenantKeys = tenantKeys; + this.tenantOperator = tenantOperator; + this.tenantValues = tenantValues; this.valueGroupingWindow = valueGroupingWindow; } @@ -142,6 +170,12 @@ public static class Builder { private String startingAfter; + private List tenantKeys; + + private TenantOperator tenantOperator; + + private List> tenantValues; + private ValueGroupingWindow valueGroupingWindow; /** Finalize and obtain parameter instance from this builder. */ @@ -157,6 +191,9 @@ public MeterEventSummariesParams build() { this.limit, this.startTime, this.startingAfter, + this.tenantKeys, + this.tenantOperator, + this.tenantValues, this.valueGroupingWindow); } @@ -319,6 +356,67 @@ public Builder setStartingAfter(String startingAfter) { return this; } + /** + * Add an element to `tenantKeys` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * MeterEventSummariesParams#tenantKeys} for the field documentation. + */ + public Builder addTenantKey(String element) { + if (this.tenantKeys == null) { + this.tenantKeys = new ArrayList<>(); + } + this.tenantKeys.add(element); + return this; + } + + /** + * Add all elements to `tenantKeys` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * MeterEventSummariesParams#tenantKeys} for the field documentation. + */ + public Builder addAllTenantKey(List elements) { + if (this.tenantKeys == null) { + this.tenantKeys = new ArrayList<>(); + } + this.tenantKeys.addAll(elements); + return this; + } + + /** + * The operator to apply when filtering by tenant values. Must be used together with tenant_keys + * and tenant_values. Cannot be used with tenant_filters. + */ + public Builder setTenantOperator(MeterEventSummariesParams.TenantOperator tenantOperator) { + this.tenantOperator = tenantOperator; + return this; + } + + /** + * Add an element to `tenantValues` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * MeterEventSummariesParams#tenantValues} for the field documentation. + */ + public Builder addTenantValue(List element) { + if (this.tenantValues == null) { + this.tenantValues = new ArrayList<>(); + } + this.tenantValues.add(element); + return this; + } + + /** + * Add all elements to `tenantValues` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * MeterEventSummariesParams#tenantValues} for the field documentation. + */ + public Builder addAllTenantValue(List> elements) { + if (this.tenantValues == null) { + this.tenantValues = new ArrayList<>(); + } + this.tenantValues.addAll(elements); + return this; + } + /** * Specifies what granularity to use when generating event summaries. If not specified, a single * event summary would be returned for the specified time range. For hourly granularity, start @@ -332,6 +430,21 @@ public Builder setValueGroupingWindow( } } + public enum TenantOperator implements ApiRequestParams.EnumParam { + @SerializedName("excludes") + EXCLUDES("excludes"), + + @SerializedName("includes") + INCLUDES("includes"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TenantOperator(String value) { + this.value = value; + } + } + public enum ValueGroupingWindow implements ApiRequestParams.EnumParam { @SerializedName("day") DAY("day"), diff --git a/src/main/java/com/stripe/param/billing/MeterEventSummaryListParams.java b/src/main/java/com/stripe/param/billing/MeterEventSummaryListParams.java index 9e1dd4a6784..abd871f7617 100644 --- a/src/main/java/com/stripe/param/billing/MeterEventSummaryListParams.java +++ b/src/main/java/com/stripe/param/billing/MeterEventSummaryListParams.java @@ -83,6 +83,28 @@ public class MeterEventSummaryListParams extends ApiRequestParams { @SerializedName("starting_after") String startingAfter; + /** + * List of tenant payload keys to filter on. Must be used together with tenant_operator and + * tenant_values. Cannot be used with tenant_filters. + */ + @SerializedName("tenant_keys") + List tenantKeys; + + /** + * The operator to apply when filtering by tenant values. Must be used together with tenant_keys + * and tenant_values. Cannot be used with tenant_filters. + */ + @SerializedName("tenant_operator") + TenantOperator tenantOperator; + + /** + * List of value lists corresponding to each key in tenant_keys. Each element contains the values + * to filter on for the corresponding tenant key. Must be used together with tenant_operator and + * tenant_keys. Cannot be used with tenant_filters. + */ + @SerializedName("tenant_values") + List> tenantValues; + /** * Specifies what granularity to use when generating event summaries. If not specified, a single * event summary would be returned for the specified time range. For hourly granularity, start and @@ -103,6 +125,9 @@ private MeterEventSummaryListParams( Long limit, Long startTime, String startingAfter, + List tenantKeys, + TenantOperator tenantOperator, + List> tenantValues, ValueGroupingWindow valueGroupingWindow) { this.customer = customer; this.dimensionFilters = dimensionFilters; @@ -114,6 +139,9 @@ private MeterEventSummaryListParams( this.limit = limit; this.startTime = startTime; this.startingAfter = startingAfter; + this.tenantKeys = tenantKeys; + this.tenantOperator = tenantOperator; + this.tenantValues = tenantValues; this.valueGroupingWindow = valueGroupingWindow; } @@ -142,6 +170,12 @@ public static class Builder { private String startingAfter; + private List tenantKeys; + + private TenantOperator tenantOperator; + + private List> tenantValues; + private ValueGroupingWindow valueGroupingWindow; /** Finalize and obtain parameter instance from this builder. */ @@ -157,6 +191,9 @@ public MeterEventSummaryListParams build() { this.limit, this.startTime, this.startingAfter, + this.tenantKeys, + this.tenantOperator, + this.tenantValues, this.valueGroupingWindow); } @@ -319,6 +356,67 @@ public Builder setStartingAfter(String startingAfter) { return this; } + /** + * Add an element to `tenantKeys` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * MeterEventSummaryListParams#tenantKeys} for the field documentation. + */ + public Builder addTenantKey(String element) { + if (this.tenantKeys == null) { + this.tenantKeys = new ArrayList<>(); + } + this.tenantKeys.add(element); + return this; + } + + /** + * Add all elements to `tenantKeys` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * MeterEventSummaryListParams#tenantKeys} for the field documentation. + */ + public Builder addAllTenantKey(List elements) { + if (this.tenantKeys == null) { + this.tenantKeys = new ArrayList<>(); + } + this.tenantKeys.addAll(elements); + return this; + } + + /** + * The operator to apply when filtering by tenant values. Must be used together with tenant_keys + * and tenant_values. Cannot be used with tenant_filters. + */ + public Builder setTenantOperator(MeterEventSummaryListParams.TenantOperator tenantOperator) { + this.tenantOperator = tenantOperator; + return this; + } + + /** + * Add an element to `tenantValues` list. A list is initialized for the first `add/addAll` call, + * and subsequent calls adds additional elements to the original list. See {@link + * MeterEventSummaryListParams#tenantValues} for the field documentation. + */ + public Builder addTenantValue(List element) { + if (this.tenantValues == null) { + this.tenantValues = new ArrayList<>(); + } + this.tenantValues.add(element); + return this; + } + + /** + * Add all elements to `tenantValues` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * MeterEventSummaryListParams#tenantValues} for the field documentation. + */ + public Builder addAllTenantValue(List> elements) { + if (this.tenantValues == null) { + this.tenantValues = new ArrayList<>(); + } + this.tenantValues.addAll(elements); + return this; + } + /** * Specifies what granularity to use when generating event summaries. If not specified, a single * event summary would be returned for the specified time range. For hourly granularity, start @@ -332,6 +430,21 @@ public Builder setValueGroupingWindow( } } + public enum TenantOperator implements ApiRequestParams.EnumParam { + @SerializedName("excludes") + EXCLUDES("excludes"), + + @SerializedName("includes") + INCLUDES("includes"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + TenantOperator(String value) { + this.value = value; + } + } + public enum ValueGroupingWindow implements ApiRequestParams.EnumParam { @SerializedName("day") DAY("day"), From 9bd73a36ae7791969750e90c8e5e32cfbb6500ca Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Tue, 31 Mar 2026 22:21:13 +0000 Subject: [PATCH 09/11] Update generated code for v2215 and --- CODEGEN_VERSION | 2 +- OPENAPI_VERSION | 2 +- .../com/stripe/model/sharedpayment/IssuedToken.java | 12 ------------ 3 files changed, 2 insertions(+), 14 deletions(-) diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index 77246263926..ea151ffae5a 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -87c1ac7f6f36c29a3f3fe64a4cb46bafbfce59b0 \ No newline at end of file +fe06273fa0f51dfa4ebc3a79dd02a23cb072d810 \ No newline at end of file diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 0ec6d10cc3c..9495f71df76 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2214 \ No newline at end of file +v2215 \ No newline at end of file diff --git a/src/main/java/com/stripe/model/sharedpayment/IssuedToken.java b/src/main/java/com/stripe/model/sharedpayment/IssuedToken.java index 8d72ffbf18f..3cc785ce2b7 100644 --- a/src/main/java/com/stripe/model/sharedpayment/IssuedToken.java +++ b/src/main/java/com/stripe/model/sharedpayment/IssuedToken.java @@ -5,7 +5,6 @@ import com.stripe.model.HasId; import com.stripe.model.StripeObject; import java.math.BigDecimal; -import java.util.List; import java.util.Map; import lombok.EqualsAndHashCode; import lombok.Getter; @@ -42,10 +41,6 @@ public class IssuedToken extends StripeObject implements HasId { @SerializedName("deactivated_reason") String deactivatedReason; - /** Which requested uses have been enabled for this SharedPaymentIssuedToken. */ - @SerializedName("enabled_uses") - List enabledUses; - /** Unique identifier for the object. */ @Getter(onMethod_ = {@Override}) @SerializedName("id") @@ -70,13 +65,6 @@ public class IssuedToken extends StripeObject implements HasId { @SerializedName("payment_method") String paymentMethod; - /** - * Requested uses for this SharedPaymentIssuedToken, which controls which Stripe APIs it can be - * used with. - */ - @SerializedName("requested_uses") - List requestedUses; - /** * If the customer does not exit their browser while authenticating, they will be redirected to * this specified URL after completion. From 6ff305341946bdef6827fdf092ceb2a52e7eb68d Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Wed, 1 Apr 2026 17:16:31 +0000 Subject: [PATCH 10/11] Update generated code for v2217 and --- CODEGEN_VERSION | 2 +- OPENAPI_VERSION | 2 +- .../RequestedSessionCreateParams.java | 266 ++++++++++++++++++ .../RequestedSessionUpdateParams.java | 266 ++++++++++++++++++ 4 files changed, 534 insertions(+), 2 deletions(-) diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index ea151ffae5a..b964824ef6d 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -fe06273fa0f51dfa4ebc3a79dd02a23cb072d810 \ No newline at end of file +70d7443c72304ad3165194e362954948b9744def \ No newline at end of file diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 9495f71df76..7073706edf3 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v2215 \ No newline at end of file +v2217 \ No newline at end of file diff --git a/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionCreateParams.java b/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionCreateParams.java index f73b846ace3..9689f534fe8 100644 --- a/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionCreateParams.java +++ b/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionCreateParams.java @@ -54,6 +54,10 @@ public class RequestedSessionCreateParams extends ApiRequestParams { @SerializedName("payment_method") String paymentMethod; + /** The payment method options for this requested session. */ + @SerializedName("payment_method_options") + PaymentMethodOptions paymentMethodOptions; + /** Required. The details of the seller. */ @SerializedName("seller_details") SellerDetails sellerDetails; @@ -76,6 +80,7 @@ private RequestedSessionCreateParams( List lineItemDetails, Map metadata, String paymentMethod, + PaymentMethodOptions paymentMethodOptions, SellerDetails sellerDetails, SetupFutureUsage setupFutureUsage, Map sharedMetadata) { @@ -88,6 +93,7 @@ private RequestedSessionCreateParams( this.lineItemDetails = lineItemDetails; this.metadata = metadata; this.paymentMethod = paymentMethod; + this.paymentMethodOptions = paymentMethodOptions; this.sellerDetails = sellerDetails; this.setupFutureUsage = setupFutureUsage; this.sharedMetadata = sharedMetadata; @@ -116,6 +122,8 @@ public static class Builder { private String paymentMethod; + private PaymentMethodOptions paymentMethodOptions; + private SellerDetails sellerDetails; private SetupFutureUsage setupFutureUsage; @@ -134,6 +142,7 @@ public RequestedSessionCreateParams build() { this.lineItemDetails, this.metadata, this.paymentMethod, + this.paymentMethodOptions, this.sellerDetails, this.setupFutureUsage, this.sharedMetadata); @@ -276,6 +285,13 @@ public Builder setPaymentMethod(String paymentMethod) { return this; } + /** The payment method options for this requested session. */ + public Builder setPaymentMethodOptions( + RequestedSessionCreateParams.PaymentMethodOptions paymentMethodOptions) { + this.paymentMethodOptions = paymentMethodOptions; + return this; + } + /** Required. The details of the seller. */ public Builder setSellerDetails(RequestedSessionCreateParams.SellerDetails sellerDetails) { this.sellerDetails = sellerDetails; @@ -1060,6 +1076,256 @@ public Builder setSkuId(String skuId) { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaymentMethodOptions { + /** Card-specific payment method options. */ + @SerializedName("card") + Card card; + + /** The payment method types to exclude from the session. */ + @SerializedName("excluded_payment_method_types") + List + excludedPaymentMethodTypes; + + /** + * 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 PaymentMethodOptions( + Card card, + List + excludedPaymentMethodTypes, + Map extraParams) { + this.card = card; + this.excludedPaymentMethodTypes = excludedPaymentMethodTypes; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Card card; + + private List + excludedPaymentMethodTypes; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public RequestedSessionCreateParams.PaymentMethodOptions build() { + return new RequestedSessionCreateParams.PaymentMethodOptions( + this.card, this.excludedPaymentMethodTypes, this.extraParams); + } + + /** Card-specific payment method options. */ + public Builder setCard(RequestedSessionCreateParams.PaymentMethodOptions.Card card) { + this.card = card; + return this; + } + + /** + * Add an element to `excludedPaymentMethodTypes` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. See + * {@link RequestedSessionCreateParams.PaymentMethodOptions#excludedPaymentMethodTypes} for + * the field documentation. + */ + public Builder addExcludedPaymentMethodType( + RequestedSessionCreateParams.PaymentMethodOptions.ExcludedPaymentMethodType element) { + if (this.excludedPaymentMethodTypes == null) { + this.excludedPaymentMethodTypes = new ArrayList<>(); + } + this.excludedPaymentMethodTypes.add(element); + return this; + } + + /** + * Add all elements to `excludedPaymentMethodTypes` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. See + * {@link RequestedSessionCreateParams.PaymentMethodOptions#excludedPaymentMethodTypes} for + * the field documentation. + */ + public Builder addAllExcludedPaymentMethodType( + List + elements) { + if (this.excludedPaymentMethodTypes == null) { + this.excludedPaymentMethodTypes = new ArrayList<>(); + } + this.excludedPaymentMethodTypes.addAll(elements); + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first `put/putAll` + * call, and subsequent calls add additional key/value pairs to the original map. See {@link + * RequestedSessionCreateParams.PaymentMethodOptions#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 RequestedSessionCreateParams.PaymentMethodOptions#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 + @EqualsAndHashCode(callSuper = false) + public static class Card { + /** The card brands to exclude from the session. */ + @SerializedName("brands_blocked") + List brandsBlocked; + + /** + * 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 Card( + List brandsBlocked, + Map extraParams) { + this.brandsBlocked = brandsBlocked; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private List + brandsBlocked; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public RequestedSessionCreateParams.PaymentMethodOptions.Card build() { + return new RequestedSessionCreateParams.PaymentMethodOptions.Card( + this.brandsBlocked, this.extraParams); + } + + /** + * Add an element to `brandsBlocked` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * RequestedSessionCreateParams.PaymentMethodOptions.Card#brandsBlocked} for the field + * documentation. + */ + public Builder addBrandsBlocked( + RequestedSessionCreateParams.PaymentMethodOptions.Card.BrandsBlocked element) { + if (this.brandsBlocked == null) { + this.brandsBlocked = new ArrayList<>(); + } + this.brandsBlocked.add(element); + return this; + } + + /** + * Add all elements to `brandsBlocked` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link RequestedSessionCreateParams.PaymentMethodOptions.Card#brandsBlocked} for the + * field documentation. + */ + public Builder addAllBrandsBlocked( + List elements) { + if (this.brandsBlocked == null) { + this.brandsBlocked = new ArrayList<>(); + } + this.brandsBlocked.addAll(elements); + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link RequestedSessionCreateParams.PaymentMethodOptions.Card#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 RequestedSessionCreateParams.PaymentMethodOptions.Card#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + + public enum BrandsBlocked implements ApiRequestParams.EnumParam { + @SerializedName("american_express") + AMERICAN_EXPRESS("american_express"), + + @SerializedName("mastercard") + MASTERCARD("mastercard"), + + @SerializedName("visa") + VISA("visa"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + BrandsBlocked(String value) { + this.value = value; + } + } + } + + public enum ExcludedPaymentMethodType implements ApiRequestParams.EnumParam { + @SerializedName("affirm") + AFFIRM("affirm"), + + @SerializedName("card") + CARD("card"), + + @SerializedName("klarna") + KLARNA("klarna"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ExcludedPaymentMethodType(String value) { + this.value = value; + } + } + } + @Getter @EqualsAndHashCode(callSuper = false) public static class SellerDetails { diff --git a/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionUpdateParams.java b/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionUpdateParams.java index 1dd81b734dc..c8e06bc7f85 100644 --- a/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionUpdateParams.java +++ b/src/main/java/com/stripe/param/delegatedcheckout/RequestedSessionUpdateParams.java @@ -43,6 +43,10 @@ public class RequestedSessionUpdateParams extends ApiRequestParams { @SerializedName("payment_method") Object paymentMethod; + /** The payment method options for this requested session. */ + @SerializedName("payment_method_options") + PaymentMethodOptions paymentMethodOptions; + /** The shared metadata for this requested session. */ @SerializedName("shared_metadata") Object sharedMetadata; @@ -54,6 +58,7 @@ private RequestedSessionUpdateParams( List lineItemDetails, Object metadata, Object paymentMethod, + PaymentMethodOptions paymentMethodOptions, Object sharedMetadata) { this.expand = expand; this.extraParams = extraParams; @@ -61,6 +66,7 @@ private RequestedSessionUpdateParams( this.lineItemDetails = lineItemDetails; this.metadata = metadata; this.paymentMethod = paymentMethod; + this.paymentMethodOptions = paymentMethodOptions; this.sharedMetadata = sharedMetadata; } @@ -81,6 +87,8 @@ public static class Builder { private Object paymentMethod; + private PaymentMethodOptions paymentMethodOptions; + private Object sharedMetadata; /** Finalize and obtain parameter instance from this builder. */ @@ -92,6 +100,7 @@ public RequestedSessionUpdateParams build() { this.lineItemDetails, this.metadata, this.paymentMethod, + this.paymentMethodOptions, this.sharedMetadata); } @@ -233,6 +242,13 @@ public Builder setPaymentMethod(EmptyParam paymentMethod) { return this; } + /** The payment method options for this requested session. */ + public Builder setPaymentMethodOptions( + RequestedSessionUpdateParams.PaymentMethodOptions paymentMethodOptions) { + this.paymentMethodOptions = paymentMethodOptions; + return this; + } + /** * Add a key/value pair to `sharedMetadata` 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 @@ -1366,4 +1382,254 @@ public Builder setQuantity(Long quantity) { } } } + + @Getter + @EqualsAndHashCode(callSuper = false) + public static class PaymentMethodOptions { + /** Card-specific payment method options. */ + @SerializedName("card") + Card card; + + /** The payment method types to exclude from the session. */ + @SerializedName("excluded_payment_method_types") + List + excludedPaymentMethodTypes; + + /** + * 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 PaymentMethodOptions( + Card card, + List + excludedPaymentMethodTypes, + Map extraParams) { + this.card = card; + this.excludedPaymentMethodTypes = excludedPaymentMethodTypes; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private Card card; + + private List + excludedPaymentMethodTypes; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public RequestedSessionUpdateParams.PaymentMethodOptions build() { + return new RequestedSessionUpdateParams.PaymentMethodOptions( + this.card, this.excludedPaymentMethodTypes, this.extraParams); + } + + /** Card-specific payment method options. */ + public Builder setCard(RequestedSessionUpdateParams.PaymentMethodOptions.Card card) { + this.card = card; + return this; + } + + /** + * Add an element to `excludedPaymentMethodTypes` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. See + * {@link RequestedSessionUpdateParams.PaymentMethodOptions#excludedPaymentMethodTypes} for + * the field documentation. + */ + public Builder addExcludedPaymentMethodType( + RequestedSessionUpdateParams.PaymentMethodOptions.ExcludedPaymentMethodType element) { + if (this.excludedPaymentMethodTypes == null) { + this.excludedPaymentMethodTypes = new ArrayList<>(); + } + this.excludedPaymentMethodTypes.add(element); + return this; + } + + /** + * Add all elements to `excludedPaymentMethodTypes` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. See + * {@link RequestedSessionUpdateParams.PaymentMethodOptions#excludedPaymentMethodTypes} for + * the field documentation. + */ + public Builder addAllExcludedPaymentMethodType( + List + elements) { + if (this.excludedPaymentMethodTypes == null) { + this.excludedPaymentMethodTypes = new ArrayList<>(); + } + this.excludedPaymentMethodTypes.addAll(elements); + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first `put/putAll` + * call, and subsequent calls add additional key/value pairs to the original map. See {@link + * RequestedSessionUpdateParams.PaymentMethodOptions#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 RequestedSessionUpdateParams.PaymentMethodOptions#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 + @EqualsAndHashCode(callSuper = false) + public static class Card { + /** The card brands to exclude from the session. */ + @SerializedName("brands_blocked") + List brandsBlocked; + + /** + * 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 Card( + List brandsBlocked, + Map extraParams) { + this.brandsBlocked = brandsBlocked; + this.extraParams = extraParams; + } + + public static Builder builder() { + return new Builder(); + } + + public static class Builder { + private List + brandsBlocked; + + private Map extraParams; + + /** Finalize and obtain parameter instance from this builder. */ + public RequestedSessionUpdateParams.PaymentMethodOptions.Card build() { + return new RequestedSessionUpdateParams.PaymentMethodOptions.Card( + this.brandsBlocked, this.extraParams); + } + + /** + * Add an element to `brandsBlocked` list. A list is initialized for the first `add/addAll` + * call, and subsequent calls adds additional elements to the original list. See {@link + * RequestedSessionUpdateParams.PaymentMethodOptions.Card#brandsBlocked} for the field + * documentation. + */ + public Builder addBrandsBlocked( + RequestedSessionUpdateParams.PaymentMethodOptions.Card.BrandsBlocked element) { + if (this.brandsBlocked == null) { + this.brandsBlocked = new ArrayList<>(); + } + this.brandsBlocked.add(element); + return this; + } + + /** + * Add all elements to `brandsBlocked` list. A list is initialized for the first + * `add/addAll` call, and subsequent calls adds additional elements to the original list. + * See {@link RequestedSessionUpdateParams.PaymentMethodOptions.Card#brandsBlocked} for the + * field documentation. + */ + public Builder addAllBrandsBlocked( + List elements) { + if (this.brandsBlocked == null) { + this.brandsBlocked = new ArrayList<>(); + } + this.brandsBlocked.addAll(elements); + return this; + } + + /** + * Add a key/value pair to `extraParams` map. A map is initialized for the first + * `put/putAll` call, and subsequent calls add additional key/value pairs to the original + * map. See {@link RequestedSessionUpdateParams.PaymentMethodOptions.Card#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 RequestedSessionUpdateParams.PaymentMethodOptions.Card#extraParams} for + * the field documentation. + */ + public Builder putAllExtraParam(Map map) { + if (this.extraParams == null) { + this.extraParams = new HashMap<>(); + } + this.extraParams.putAll(map); + return this; + } + } + + public enum BrandsBlocked implements ApiRequestParams.EnumParam { + @SerializedName("american_express") + AMERICAN_EXPRESS("american_express"), + + @SerializedName("mastercard") + MASTERCARD("mastercard"), + + @SerializedName("visa") + VISA("visa"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + BrandsBlocked(String value) { + this.value = value; + } + } + } + + public enum ExcludedPaymentMethodType implements ApiRequestParams.EnumParam { + @SerializedName("affirm") + AFFIRM("affirm"), + + @SerializedName("card") + CARD("card"), + + @SerializedName("klarna") + KLARNA("klarna"); + + @Getter(onMethod_ = {@Override}) + private final String value; + + ExcludedPaymentMethodType(String value) { + this.value = value; + } + } + } } From 3a42b576e27414fba94a4f372e178097cdb0400a Mon Sep 17 00:00:00 2001 From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Wed, 1 Apr 2026 20:19:20 +0000 Subject: [PATCH 11/11] Update generated code for v2217 and --- CODEGEN_VERSION | 2 +- .../com/stripe/model/v2/billing/Cadence.java | 16 +- .../v2/billing/CadenceSpendModifier.java | 7 +- .../model/v2/billing/CollectionSetting.java | 17 +- .../v2/billing/CollectionSettingVersion.java | 17 +- .../stripe/model/v2/billing/IntentAction.java | 7 +- .../com/stripe/model/v2/core/Account.java | 71 ++++--- .../stripe/model/v2/core/AccountPerson.java | 29 +-- .../java/com/stripe/model/v2/core/Event.java | 8 +- .../v2/moneymanagement/InboundTransfer.java | 25 ++- .../v2/moneymanagement/OutboundTransfer.java | 7 +- .../model/v2/payments/OffSessionPayment.java | 4 + .../CollectionSettingCreateParams.java | 184 +++++++++++++----- .../CollectionSettingUpdateParams.java | 184 +++++++++++++----- .../param/v2/billing/IntentCreateParams.java | 17 +- .../param/v2/core/AccountCreateParams.java | 137 ++++++++++++- .../v2/core/AccountTokenCreateParams.java | 137 ++++++++++++- .../param/v2/core/AccountUpdateParams.java | 137 ++++++++++++- .../v2/core/accounts/PersonCreateParams.java | 60 ++++++ .../accounts/PersonTokenCreateParams.java | 60 ++++++ .../v2/core/accounts/PersonUpdateParams.java | 60 ++++++ .../OffSessionPaymentCaptureParams.java | 16 ++ .../OffSessionPaymentCreateParams.java | 21 ++ .../stripe/functional/GeneratedExamples.java | 3 +- 24 files changed, 1049 insertions(+), 177 deletions(-) diff --git a/CODEGEN_VERSION b/CODEGEN_VERSION index b964824ef6d..7e6e244735c 100644 --- a/CODEGEN_VERSION +++ b/CODEGEN_VERSION @@ -1 +1 @@ -70d7443c72304ad3165194e362954948b9744def \ No newline at end of file +16e50491e9d896cb53da4a46080b4333741b76cb \ No newline at end of file diff --git a/src/main/java/com/stripe/model/v2/billing/Cadence.java b/src/main/java/com/stripe/model/v2/billing/Cadence.java index b4fda734733..7cb9a543f51 100644 --- a/src/main/java/com/stripe/model/v2/billing/Cadence.java +++ b/src/main/java/com/stripe/model/v2/billing/Cadence.java @@ -627,11 +627,11 @@ public static class PaymentMethodOptions extends StripeObject { /** This sub-hash contains details about the Konbini payment method options. */ @SerializedName("konbini") - Map konbini; + Konbini konbini; /** This sub-hash contains details about the SEPA Direct Debit payment method options. */ @SerializedName("sepa_debit") - Map sepaDebit; + SepaDebit sepaDebit; /** This sub-hash contains details about the ACH direct debit payment method options. */ @SerializedName("us_bank_account") @@ -803,6 +803,18 @@ public static class EuBankTransfer extends StripeObject { } } + /** This sub-hash contains details about the Konbini payment method options. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Konbini extends StripeObject {} + + /** This sub-hash contains details about the SEPA Direct Debit payment method options. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class SepaDebit extends StripeObject {} + /** This sub-hash contains details about the ACH direct debit payment method options. */ @Getter @Setter diff --git a/src/main/java/com/stripe/model/v2/billing/CadenceSpendModifier.java b/src/main/java/com/stripe/model/v2/billing/CadenceSpendModifier.java index 989a740ad4f..1be03b8b92e 100644 --- a/src/main/java/com/stripe/model/v2/billing/CadenceSpendModifier.java +++ b/src/main/java/com/stripe/model/v2/billing/CadenceSpendModifier.java @@ -104,7 +104,12 @@ public static class Amount extends StripeObject { @Getter @Setter @EqualsAndHashCode(callSuper = false) - public static class CustomPricingUnit extends StripeObject { + public static class CustomPricingUnit extends StripeObject implements HasId { + /** The id of the custom pricing unit. */ + @Getter(onMethod_ = {@Override}) + @SerializedName("id") + String id; + /** The decimal value of custom pricing units, represented as a string. */ @SerializedName("value") String value; diff --git a/src/main/java/com/stripe/model/v2/billing/CollectionSetting.java b/src/main/java/com/stripe/model/v2/billing/CollectionSetting.java index 146ebdd6e6c..4a48b87b845 100644 --- a/src/main/java/com/stripe/model/v2/billing/CollectionSetting.java +++ b/src/main/java/com/stripe/model/v2/billing/CollectionSetting.java @@ -8,7 +8,6 @@ import com.stripe.model.StripeObject; import java.time.Instant; import java.util.List; -import java.util.Map; import lombok.EqualsAndHashCode; import lombok.Getter; import lombok.Setter; @@ -153,11 +152,11 @@ public static class PaymentMethodOptions extends StripeObject { /** This sub-hash contains details about the Konbini payment method options. */ @SerializedName("konbini") - Map konbini; + Konbini konbini; /** This sub-hash contains details about the SEPA Direct Debit payment method options. */ @SerializedName("sepa_debit") - Map sepaDebit; + SepaDebit sepaDebit; /** This sub-hash contains details about the ACH direct debit payment method options. */ @SerializedName("us_bank_account") @@ -326,6 +325,18 @@ public static class EuBankTransfer extends StripeObject { } } + /** This sub-hash contains details about the Konbini payment method options. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Konbini extends StripeObject {} + + /** This sub-hash contains details about the SEPA Direct Debit payment method options. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class SepaDebit extends StripeObject {} + /** This sub-hash contains details about the ACH direct debit payment method options. */ @Getter @Setter diff --git a/src/main/java/com/stripe/model/v2/billing/CollectionSettingVersion.java b/src/main/java/com/stripe/model/v2/billing/CollectionSettingVersion.java index 2035073002d..4bc0fda27bb 100644 --- a/src/main/java/com/stripe/model/v2/billing/CollectionSettingVersion.java +++ b/src/main/java/com/stripe/model/v2/billing/CollectionSettingVersion.java @@ -8,7 +8,6 @@ import com.stripe.model.StripeObject; import java.time.Instant; import java.util.List; -import java.util.Map; import lombok.EqualsAndHashCode; import lombok.Getter; import lombok.Setter; @@ -132,11 +131,11 @@ public static class PaymentMethodOptions extends StripeObject { /** This sub-hash contains details about the Konbini payment method options. */ @SerializedName("konbini") - Map konbini; + Konbini konbini; /** This sub-hash contains details about the SEPA Direct Debit payment method options. */ @SerializedName("sepa_debit") - Map sepaDebit; + SepaDebit sepaDebit; /** This sub-hash contains details about the ACH direct debit payment method options. */ @SerializedName("us_bank_account") @@ -305,6 +304,18 @@ public static class EuBankTransfer extends StripeObject { } } + /** This sub-hash contains details about the Konbini payment method options. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class Konbini extends StripeObject {} + + /** This sub-hash contains details about the SEPA Direct Debit payment method options. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class SepaDebit extends StripeObject {} + /** This sub-hash contains details about the ACH direct debit payment method options. */ @Getter @Setter diff --git a/src/main/java/com/stripe/model/v2/billing/IntentAction.java b/src/main/java/com/stripe/model/v2/billing/IntentAction.java index a453915c764..a862625f414 100644 --- a/src/main/java/com/stripe/model/v2/billing/IntentAction.java +++ b/src/main/java/com/stripe/model/v2/billing/IntentAction.java @@ -287,7 +287,12 @@ public static class Amount extends StripeObject { @Getter @Setter @EqualsAndHashCode(callSuper = false) - public static class CustomPricingUnit extends StripeObject { + public static class CustomPricingUnit extends StripeObject implements HasId { + /** The id of the custom pricing unit. */ + @Getter(onMethod_ = {@Override}) + @SerializedName("id") + String id; + /** The value of the custom pricing unit. */ @SerializedName("value") String value; diff --git a/src/main/java/com/stripe/model/v2/core/Account.java b/src/main/java/com/stripe/model/v2/core/Account.java index 22e69eed313..0f5c3dd7de1 100644 --- a/src/main/java/com/stripe/model/v2/core/Account.java +++ b/src/main/java/com/stripe/model/v2/core/Account.java @@ -8874,25 +8874,30 @@ public static class IdNumber extends StripeObject { *

One of {@code ae_crn}, {@code ae_vat}, {@code ao_nif}, {@code ar_cuit}, {@code at_fn}, * {@code at_stn}, {@code at_vat}, {@code au_abn}, {@code au_acn}, {@code au_in}, {@code * az_tin}, {@code bd_etin}, {@code be_cbe}, {@code be_vat}, {@code bg_uic}, {@code bg_vat}, - * {@code br_cnpj}, {@code ca_cn}, {@code ca_crarr}, {@code ca_gst_hst}, {@code ca_neq}, - * {@code ca_rid}, {@code ch_chid}, {@code ch_uid}, {@code cr_cpj}, {@code cr_nite}, {@code - * cy_he}, {@code cy_tic}, {@code cy_vat}, {@code cz_ico}, {@code cz_vat}, {@code de_hrn}, - * {@code de_stn}, {@code de_vat}, {@code dk_cvr}, {@code dk_vat}, {@code do_rcn}, {@code - * ee_rk}, {@code ee_vat}, {@code es_cif}, {@code es_vat}, {@code fi_vat}, {@code fi_yt}, - * {@code fr_rna}, {@code fr_siren}, {@code fr_vat}, {@code gb_crn}, {@code gb_vat}, {@code - * gi_crn}, {@code gr_afm}, {@code gr_gemi}, {@code gr_vat}, {@code gt_nit}, {@code hk_br}, - * {@code hk_cr}, {@code hr_mbs}, {@code hr_oib}, {@code hr_vat}, {@code hu_cjs}, {@code - * hu_tin}, {@code hu_vat}, {@code ie_crn}, {@code ie_trn}, {@code ie_vat}, {@code it_rea}, - * {@code it_vat}, {@code jp_cn}, {@code kz_bin}, {@code li_uid}, {@code lt_ccrn}, {@code - * lt_vat}, {@code lu_nif}, {@code lu_rcs}, {@code lu_vat}, {@code lv_urn}, {@code lv_vat}, - * {@code mt_crn}, {@code mt_tin}, {@code mt_vat}, {@code mx_rfc}, {@code my_brn}, {@code - * my_coid}, {@code my_itn}, {@code my_sst}, {@code mz_nuit}, {@code nl_kvk}, {@code + * {@code bm_crn}, {@code bo_tin}, {@code br_cnpj}, {@code bt_tpn}, {@code ca_cn}, {@code + * ca_crarr}, {@code ca_gst_hst}, {@code ca_neq}, {@code ca_rid}, {@code ch_chid}, {@code + * ch_uid}, {@code co_nit}, {@code cr_cpj}, {@code cr_nite}, {@code cy_he}, {@code cy_tic}, + * {@code cy_vat}, {@code cz_ico}, {@code cz_vat}, {@code de_hrn}, {@code de_stn}, {@code + * de_vat}, {@code dk_cvr}, {@code dk_vat}, {@code do_rcn}, {@code ec_ruc}, {@code ee_rk}, + * {@code ee_vat}, {@code eg_tin}, {@code es_cif}, {@code es_vat}, {@code fi_vat}, {@code + * fi_yt}, {@code fr_rna}, {@code fr_siren}, {@code fr_vat}, {@code gb_crn}, {@code gb_vat}, + * {@code gh_tin}, {@code gi_crn}, {@code gr_afm}, {@code gr_gemi}, {@code gr_vat}, {@code + * gt_nit}, {@code gy_tin}, {@code hk_br}, {@code hk_cr}, {@code hn_rtn}, {@code hr_mbs}, + * {@code hr_oib}, {@code hr_vat}, {@code hu_cjs}, {@code hu_tin}, {@code hu_vat}, {@code + * ie_crn}, {@code ie_trn}, {@code ie_vat}, {@code it_rea}, {@code it_vat}, {@code jm_trn}, + * {@code jo_crn}, {@code jp_cn}, {@code ke_pin}, {@code ky_crn}, {@code kz_bin}, {@code + * li_uid}, {@code lk_tin}, {@code lt_ccrn}, {@code lt_vat}, {@code lu_nif}, {@code lu_rcs}, + * {@code lu_vat}, {@code lv_urn}, {@code lv_vat}, {@code mo_tin}, {@code mt_crn}, {@code + * mt_tin}, {@code mt_vat}, {@code mv_tin}, {@code mx_rfc}, {@code my_brn}, {@code my_coid}, + * {@code my_itn}, {@code my_sst}, {@code mz_nuit}, {@code ng_tin}, {@code nl_kvk}, {@code * nl_rsin}, {@code nl_vat}, {@code no_orgnr}, {@code nz_bn}, {@code nz_ird}, {@code - * pe_ruc}, {@code pk_ntn}, {@code pl_nip}, {@code pl_regon}, {@code pl_vat}, {@code - * pt_vat}, {@code ro_cui}, {@code ro_orc}, {@code ro_vat}, {@code sa_crn}, {@code sa_tin}, - * {@code se_orgnr}, {@code se_vat}, {@code sg_uen}, {@code si_msp}, {@code si_tin}, {@code - * si_vat}, {@code sk_dic}, {@code sk_ico}, {@code sk_vat}, {@code th_crn}, {@code th_prn}, - * {@code th_tin}, or {@code us_ein}. + * pa_ruc}, {@code pe_ruc}, {@code ph_tin}, {@code pk_ntn}, {@code pl_nip}, {@code + * pl_regon}, {@code pl_vat}, {@code pt_vat}, {@code py_ruc}, {@code ro_cui}, {@code + * ro_orc}, {@code ro_vat}, {@code sa_crn}, {@code sa_tin}, {@code se_orgnr}, {@code + * se_vat}, {@code sg_uen}, {@code si_msp}, {@code si_tin}, {@code si_vat}, {@code sk_dic}, + * {@code sk_ico}, {@code sk_vat}, {@code sl_tin}, {@code sv_nit}, {@code th_crn}, {@code + * th_prn}, {@code th_tin}, {@code us_ein}, {@code uy_ruc}, {@code vg_cn}, or {@code + * za_tin}. */ @SerializedName("type") String type; @@ -9576,19 +9581,23 @@ public static class IdNumber extends StripeObject { * *

One of {@code ae_eid}, {@code ao_nif}, {@code ar_cuil}, {@code ar_dni}, {@code * at_stn}, {@code az_tin}, {@code bd_brc}, {@code bd_etin}, {@code bd_nid}, {@code be_nrn}, - * {@code bg_ucn}, {@code bn_nric}, {@code br_cpf}, {@code ca_sin}, {@code ch_oasi}, {@code - * cl_rut}, {@code cn_pp}, {@code co_nuip}, {@code cr_ci}, {@code cr_cpf}, {@code cr_dimex}, - * {@code cr_nite}, {@code cy_tic}, {@code cz_rc}, {@code de_stn}, {@code dk_cpr}, {@code - * do_cie}, {@code do_rcn}, {@code ec_ci}, {@code ee_ik}, {@code es_nif}, {@code fi_hetu}, - * {@code fr_nir}, {@code gb_nino}, {@code gr_afm}, {@code gt_nit}, {@code hk_id}, {@code - * hr_oib}, {@code hu_ad}, {@code id_nik}, {@code ie_ppsn}, {@code is_kt}, {@code it_cf}, - * {@code jp_inc}, {@code ke_pin}, {@code kz_iin}, {@code li_peid}, {@code lt_ak}, {@code - * lu_nif}, {@code lv_pk}, {@code mx_rfc}, {@code my_nric}, {@code mz_nuit}, {@code ng_nin}, - * {@code nl_bsn}, {@code no_nin}, {@code nz_ird}, {@code pe_dni}, {@code pk_cnic}, {@code - * pk_snic}, {@code pl_pesel}, {@code pt_nif}, {@code ro_cnp}, {@code sa_tin}, {@code - * se_pin}, {@code sg_fin}, {@code sg_nric}, {@code sk_dic}, {@code th_lc}, {@code th_pin}, - * {@code tr_tin}, {@code us_itin}, {@code us_itin_last_4}, {@code us_ssn}, {@code - * us_ssn_last_4}, {@code uy_dni}, or {@code za_id}. + * {@code bg_ucn}, {@code bm_pp}, {@code bn_nric}, {@code bo_ci}, {@code br_cpf}, {@code + * bt_cid}, {@code ca_sin}, {@code ch_oasi}, {@code cl_rut}, {@code cn_pp}, {@code co_nuip}, + * {@code cr_ci}, {@code cr_cpf}, {@code cr_dimex}, {@code cr_nite}, {@code cy_tic}, {@code + * cz_rc}, {@code de_stn}, {@code dk_cpr}, {@code do_cie}, {@code do_rcn}, {@code ec_ci}, + * {@code ee_ik}, {@code eg_tin}, {@code es_nif}, {@code fi_hetu}, {@code fr_nir}, {@code + * gb_nino}, {@code gh_pin}, {@code gr_afm}, {@code gt_nit}, {@code gy_tin}, {@code hk_id}, + * {@code hn_rtn}, {@code hr_oib}, {@code hu_ad}, {@code id_nik}, {@code ie_ppsn}, {@code + * is_kt}, {@code it_cf}, {@code jm_trn}, {@code jo_pin}, {@code jp_inc}, {@code ke_pin}, + * {@code ky_pp}, {@code kz_iin}, {@code li_peid}, {@code lk_nic}, {@code lt_ak}, {@code + * lu_nif}, {@code lv_pk}, {@code mo_bir}, {@code mt_nic}, {@code mv_tin}, {@code mx_rfc}, + * {@code my_nric}, {@code mz_nuit}, {@code ng_nin}, {@code nl_bsn}, {@code no_nin}, {@code + * nz_ird}, {@code pa_ruc}, {@code pe_dni}, {@code ph_tin}, {@code pk_cnic}, {@code + * pk_snic}, {@code pl_pesel}, {@code pt_nif}, {@code py_ruc}, {@code ro_cnp}, {@code + * sa_tin}, {@code se_pin}, {@code sg_fin}, {@code sg_nric}, {@code si_pin}, {@code sk_dic}, + * {@code sv_nit}, {@code th_lc}, {@code th_pin}, {@code tr_tin}, {@code us_itin}, {@code + * us_itin_last_4}, {@code us_ssn}, {@code us_ssn_last_4}, {@code uy_dni}, {@code vg_pp}, or + * {@code za_id}. */ @SerializedName("type") String type; diff --git a/src/main/java/com/stripe/model/v2/core/AccountPerson.java b/src/main/java/com/stripe/model/v2/core/AccountPerson.java index 25eed6ceaab..71fc2a61202 100644 --- a/src/main/java/com/stripe/model/v2/core/AccountPerson.java +++ b/src/main/java/com/stripe/model/v2/core/AccountPerson.java @@ -533,19 +533,22 @@ public static class IdNumber extends StripeObject { * *

One of {@code ae_eid}, {@code ao_nif}, {@code ar_cuil}, {@code ar_dni}, {@code at_stn}, * {@code az_tin}, {@code bd_brc}, {@code bd_etin}, {@code bd_nid}, {@code be_nrn}, {@code - * bg_ucn}, {@code bn_nric}, {@code br_cpf}, {@code ca_sin}, {@code ch_oasi}, {@code cl_rut}, - * {@code cn_pp}, {@code co_nuip}, {@code cr_ci}, {@code cr_cpf}, {@code cr_dimex}, {@code - * cr_nite}, {@code cy_tic}, {@code cz_rc}, {@code de_stn}, {@code dk_cpr}, {@code do_cie}, - * {@code do_rcn}, {@code ec_ci}, {@code ee_ik}, {@code es_nif}, {@code fi_hetu}, {@code - * fr_nir}, {@code gb_nino}, {@code gr_afm}, {@code gt_nit}, {@code hk_id}, {@code hr_oib}, - * {@code hu_ad}, {@code id_nik}, {@code ie_ppsn}, {@code is_kt}, {@code it_cf}, {@code jp_inc}, - * {@code ke_pin}, {@code kz_iin}, {@code li_peid}, {@code lt_ak}, {@code lu_nif}, {@code - * lv_pk}, {@code mx_rfc}, {@code my_nric}, {@code mz_nuit}, {@code ng_nin}, {@code nl_bsn}, - * {@code no_nin}, {@code nz_ird}, {@code pe_dni}, {@code pk_cnic}, {@code pk_snic}, {@code - * pl_pesel}, {@code pt_nif}, {@code ro_cnp}, {@code sa_tin}, {@code se_pin}, {@code sg_fin}, - * {@code sg_nric}, {@code sk_dic}, {@code th_lc}, {@code th_pin}, {@code tr_tin}, {@code - * us_itin}, {@code us_itin_last_4}, {@code us_ssn}, {@code us_ssn_last_4}, {@code uy_dni}, or - * {@code za_id}. + * bg_ucn}, {@code bm_pp}, {@code bn_nric}, {@code bo_ci}, {@code br_cpf}, {@code bt_cid}, + * {@code ca_sin}, {@code ch_oasi}, {@code cl_rut}, {@code cn_pp}, {@code co_nuip}, {@code + * cr_ci}, {@code cr_cpf}, {@code cr_dimex}, {@code cr_nite}, {@code cy_tic}, {@code cz_rc}, + * {@code de_stn}, {@code dk_cpr}, {@code do_cie}, {@code do_rcn}, {@code ec_ci}, {@code ee_ik}, + * {@code eg_tin}, {@code es_nif}, {@code fi_hetu}, {@code fr_nir}, {@code gb_nino}, {@code + * gh_pin}, {@code gr_afm}, {@code gt_nit}, {@code gy_tin}, {@code hk_id}, {@code hn_rtn}, + * {@code hr_oib}, {@code hu_ad}, {@code id_nik}, {@code ie_ppsn}, {@code is_kt}, {@code it_cf}, + * {@code jm_trn}, {@code jo_pin}, {@code jp_inc}, {@code ke_pin}, {@code ky_pp}, {@code + * kz_iin}, {@code li_peid}, {@code lk_nic}, {@code lt_ak}, {@code lu_nif}, {@code lv_pk}, + * {@code mo_bir}, {@code mt_nic}, {@code mv_tin}, {@code mx_rfc}, {@code my_nric}, {@code + * mz_nuit}, {@code ng_nin}, {@code nl_bsn}, {@code no_nin}, {@code nz_ird}, {@code pa_ruc}, + * {@code pe_dni}, {@code ph_tin}, {@code pk_cnic}, {@code pk_snic}, {@code pl_pesel}, {@code + * pt_nif}, {@code py_ruc}, {@code ro_cnp}, {@code sa_tin}, {@code se_pin}, {@code sg_fin}, + * {@code sg_nric}, {@code si_pin}, {@code sk_dic}, {@code sv_nit}, {@code th_lc}, {@code + * th_pin}, {@code tr_tin}, {@code us_itin}, {@code us_itin_last_4}, {@code us_ssn}, {@code + * us_ssn_last_4}, {@code uy_dni}, {@code vg_pp}, or {@code za_id}. */ @SerializedName("type") String type; diff --git a/src/main/java/com/stripe/model/v2/core/Event.java b/src/main/java/com/stripe/model/v2/core/Event.java index 12e9d42477e..d13703a4b0d 100644 --- a/src/main/java/com/stripe/model/v2/core/Event.java +++ b/src/main/java/com/stripe/model/v2/core/Event.java @@ -192,7 +192,7 @@ public static class Client extends StripeObject { /** Stripe action that triggered the event. */ @SerializedName("stripe_action") - Map stripeAction; + StripeAction stripeAction; /** * The type of the client. @@ -230,6 +230,12 @@ public static class DashboardUser extends StripeObject { @SerializedName("machine_identifier") String machineIdentifier; } + + /** Stripe action that triggered the event. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class StripeAction extends StripeObject {} } } } diff --git a/src/main/java/com/stripe/model/v2/moneymanagement/InboundTransfer.java b/src/main/java/com/stripe/model/v2/moneymanagement/InboundTransfer.java index 4816f0ba479..6a48397ee62 100644 --- a/src/main/java/com/stripe/model/v2/moneymanagement/InboundTransfer.java +++ b/src/main/java/com/stripe/model/v2/moneymanagement/InboundTransfer.java @@ -7,7 +7,6 @@ import com.stripe.v2.Amount; import java.time.Instant; import java.util.List; -import java.util.Map; import lombok.EqualsAndHashCode; import lombok.Getter; import lombok.Setter; @@ -134,11 +133,11 @@ public static class TransferHistory extends StripeObject implements HasId { /** The history entry for a processing InboundTransfer. */ @SerializedName("bank_debit_processing") - Map bankDebitProcessing; + BankDebitProcessing bankDebitProcessing; /** The history entry for a queued InboundTransfer. */ @SerializedName("bank_debit_queued") - Map bankDebitQueued; + BankDebitQueued bankDebitQueued; /** The history entry for a returned InboundTransfer. */ @SerializedName("bank_debit_returned") @@ -146,7 +145,7 @@ public static class TransferHistory extends StripeObject implements HasId { /** The history entry for a succeeded InboundTransfer. */ @SerializedName("bank_debit_succeeded") - Map bankDebitSucceeded; + BankDebitSucceeded bankDebitSucceeded; /** Creation time of the HistoryEntry in RFC 3339 format and UTC. */ @SerializedName("created") @@ -194,6 +193,18 @@ public static class BankDebitFailed extends StripeObject { String failureReason; } + /** The history entry for a processing InboundTransfer. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class BankDebitProcessing extends StripeObject {} + + /** The history entry for a queued InboundTransfer. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class BankDebitQueued extends StripeObject {} + /** The history entry for a returned InboundTransfer. */ @Getter @Setter @@ -209,5 +220,11 @@ public static class BankDebitReturned extends StripeObject { @SerializedName("return_reason") String returnReason; } + + /** The history entry for a succeeded InboundTransfer. */ + @Getter + @Setter + @EqualsAndHashCode(callSuper = false) + public static class BankDebitSucceeded extends StripeObject {} } } diff --git a/src/main/java/com/stripe/model/v2/moneymanagement/OutboundTransfer.java b/src/main/java/com/stripe/model/v2/moneymanagement/OutboundTransfer.java index 8f9db4c7129..908e794a752 100644 --- a/src/main/java/com/stripe/model/v2/moneymanagement/OutboundTransfer.java +++ b/src/main/java/com/stripe/model/v2/moneymanagement/OutboundTransfer.java @@ -188,9 +188,10 @@ public static class Failed extends StripeObject { /** * Open Enum. The {@code failed} status reason. * - *

One of {@code payout_method_declined}, {@code payout_method_does_not_exist}, {@code - * payout_method_expired}, {@code payout_method_unsupported}, {@code - * payout_method_usage_frequency_limit_exceeded}, or {@code unknown_failure}. + *

One of {@code payout_method_amount_limit_exceeded}, {@code payout_method_declined}, + * {@code payout_method_does_not_exist}, {@code payout_method_expired}, {@code + * payout_method_unsupported}, {@code payout_method_usage_frequency_limit_exceeded}, or {@code + * unknown_failure}. */ @SerializedName("reason") String reason; diff --git a/src/main/java/com/stripe/model/v2/payments/OffSessionPayment.java b/src/main/java/com/stripe/model/v2/payments/OffSessionPayment.java index 2475d12d953..728a948f61d 100644 --- a/src/main/java/com/stripe/model/v2/payments/OffSessionPayment.java +++ b/src/main/java/com/stripe/model/v2/payments/OffSessionPayment.java @@ -33,6 +33,10 @@ public class OffSessionPayment extends StripeObject implements HasId { @SerializedName("amount_requested") Amount amountRequested; + /** The amount of the application fee requested to be applied to the payment. */ + @SerializedName("application_fee_amount_requested") + Amount applicationFeeAmountRequested; + /** * The frequency of the underlying payment. * diff --git a/src/main/java/com/stripe/param/v2/billing/CollectionSettingCreateParams.java b/src/main/java/com/stripe/param/v2/billing/CollectionSettingCreateParams.java index 6eab345b23f..0ffa91e4a36 100644 --- a/src/main/java/com/stripe/param/v2/billing/CollectionSettingCreateParams.java +++ b/src/main/java/com/stripe/param/v2/billing/CollectionSettingCreateParams.java @@ -397,11 +397,11 @@ public static class PaymentMethodOptions { /** This sub-hash contains details about the Konbini payment method options. */ @SerializedName("konbini") - Map konbini; + Konbini konbini; /** This sub-hash contains details about the SEPA Direct Debit payment method options. */ @SerializedName("sepa_debit") - Map sepaDebit; + SepaDebit sepaDebit; /** This sub-hash contains details about the ACH direct debit payment method options. */ @SerializedName("us_bank_account") @@ -413,8 +413,8 @@ private PaymentMethodOptions( Card card, CustomerBalance customerBalance, Map extraParams, - Map konbini, - Map sepaDebit, + Konbini konbini, + SepaDebit sepaDebit, UsBankAccount usBankAccount) { this.acssDebit = acssDebit; this.bancontact = bancontact; @@ -441,9 +441,9 @@ public static class Builder { private Map extraParams; - private Map konbini; + private Konbini konbini; - private Map sepaDebit; + private SepaDebit sepaDebit; private UsBankAccount usBankAccount; @@ -518,57 +518,17 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Add a key/value pair to `konbini` 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 - * CollectionSettingCreateParams.PaymentMethodOptions#konbini} for the field documentation. - */ - public Builder putKonbini(String key, Object value) { - if (this.konbini == null) { - this.konbini = new HashMap<>(); - } - this.konbini.put(key, value); - return this; - } - - /** - * Add all map key/value pairs to `konbini` 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 CollectionSettingCreateParams.PaymentMethodOptions#konbini} for the field - * documentation. - */ - public Builder putAllKonbini(Map map) { - if (this.konbini == null) { - this.konbini = new HashMap<>(); - } - this.konbini.putAll(map); - return this; - } - - /** - * Add a key/value pair to `sepaDebit` 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 - * CollectionSettingCreateParams.PaymentMethodOptions#sepaDebit} for the field documentation. - */ - public Builder putSepaDebit(String key, Object value) { - if (this.sepaDebit == null) { - this.sepaDebit = new HashMap<>(); - } - this.sepaDebit.put(key, value); + /** This sub-hash contains details about the Konbini payment method options. */ + public Builder setKonbini( + CollectionSettingCreateParams.PaymentMethodOptions.Konbini konbini) { + this.konbini = konbini; return this; } - /** - * Add all map key/value pairs to `sepaDebit` 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 CollectionSettingCreateParams.PaymentMethodOptions#sepaDebit} for the field - * documentation. - */ - public Builder putAllSepaDebit(Map map) { - if (this.sepaDebit == null) { - this.sepaDebit = new HashMap<>(); - } - this.sepaDebit.putAll(map); + /** This sub-hash contains details about the SEPA Direct Debit payment method options. */ + public Builder setSepaDebit( + CollectionSettingCreateParams.PaymentMethodOptions.SepaDebit sepaDebit) { + this.sepaDebit = sepaDebit; return this; } @@ -1507,6 +1467,122 @@ public enum FundingType implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Konbini { + /** + * 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 Konbini(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 CollectionSettingCreateParams.PaymentMethodOptions.Konbini build() { + return new CollectionSettingCreateParams.PaymentMethodOptions.Konbini(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 CollectionSettingCreateParams.PaymentMethodOptions.Konbini#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 CollectionSettingCreateParams.PaymentMethodOptions.Konbini#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 + @EqualsAndHashCode(callSuper = false) + public static class SepaDebit { + /** + * 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 SepaDebit(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 CollectionSettingCreateParams.PaymentMethodOptions.SepaDebit build() { + return new CollectionSettingCreateParams.PaymentMethodOptions.SepaDebit(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 CollectionSettingCreateParams.PaymentMethodOptions.SepaDebit#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 CollectionSettingCreateParams.PaymentMethodOptions.SepaDebit#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 @EqualsAndHashCode(callSuper = false) public static class UsBankAccount { diff --git a/src/main/java/com/stripe/param/v2/billing/CollectionSettingUpdateParams.java b/src/main/java/com/stripe/param/v2/billing/CollectionSettingUpdateParams.java index 95fb6832134..12c0d568e2f 100644 --- a/src/main/java/com/stripe/param/v2/billing/CollectionSettingUpdateParams.java +++ b/src/main/java/com/stripe/param/v2/billing/CollectionSettingUpdateParams.java @@ -460,11 +460,11 @@ public static class PaymentMethodOptions { /** This sub-hash contains details about the Konbini payment method options. */ @SerializedName("konbini") - Map konbini; + Konbini konbini; /** This sub-hash contains details about the SEPA Direct Debit payment method options. */ @SerializedName("sepa_debit") - Map sepaDebit; + SepaDebit sepaDebit; /** This sub-hash contains details about the ACH direct debit payment method options. */ @SerializedName("us_bank_account") @@ -476,8 +476,8 @@ private PaymentMethodOptions( Card card, CustomerBalance customerBalance, Map extraParams, - Map konbini, - Map sepaDebit, + Konbini konbini, + SepaDebit sepaDebit, UsBankAccount usBankAccount) { this.acssDebit = acssDebit; this.bancontact = bancontact; @@ -504,9 +504,9 @@ public static class Builder { private Map extraParams; - private Map konbini; + private Konbini konbini; - private Map sepaDebit; + private SepaDebit sepaDebit; private UsBankAccount usBankAccount; @@ -581,57 +581,17 @@ public Builder putAllExtraParam(Map map) { return this; } - /** - * Add a key/value pair to `konbini` 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 - * CollectionSettingUpdateParams.PaymentMethodOptions#konbini} for the field documentation. - */ - public Builder putKonbini(String key, Object value) { - if (this.konbini == null) { - this.konbini = new HashMap<>(); - } - this.konbini.put(key, value); - return this; - } - - /** - * Add all map key/value pairs to `konbini` 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 CollectionSettingUpdateParams.PaymentMethodOptions#konbini} for the field - * documentation. - */ - public Builder putAllKonbini(Map map) { - if (this.konbini == null) { - this.konbini = new HashMap<>(); - } - this.konbini.putAll(map); - return this; - } - - /** - * Add a key/value pair to `sepaDebit` 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 - * CollectionSettingUpdateParams.PaymentMethodOptions#sepaDebit} for the field documentation. - */ - public Builder putSepaDebit(String key, Object value) { - if (this.sepaDebit == null) { - this.sepaDebit = new HashMap<>(); - } - this.sepaDebit.put(key, value); + /** This sub-hash contains details about the Konbini payment method options. */ + public Builder setKonbini( + CollectionSettingUpdateParams.PaymentMethodOptions.Konbini konbini) { + this.konbini = konbini; return this; } - /** - * Add all map key/value pairs to `sepaDebit` 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 CollectionSettingUpdateParams.PaymentMethodOptions#sepaDebit} for the field - * documentation. - */ - public Builder putAllSepaDebit(Map map) { - if (this.sepaDebit == null) { - this.sepaDebit = new HashMap<>(); - } - this.sepaDebit.putAll(map); + /** This sub-hash contains details about the SEPA Direct Debit payment method options. */ + public Builder setSepaDebit( + CollectionSettingUpdateParams.PaymentMethodOptions.SepaDebit sepaDebit) { + this.sepaDebit = sepaDebit; return this; } @@ -1585,6 +1545,122 @@ public enum FundingType implements ApiRequestParams.EnumParam { } } + @Getter + @EqualsAndHashCode(callSuper = false) + public static class Konbini { + /** + * 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 Konbini(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 CollectionSettingUpdateParams.PaymentMethodOptions.Konbini build() { + return new CollectionSettingUpdateParams.PaymentMethodOptions.Konbini(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 CollectionSettingUpdateParams.PaymentMethodOptions.Konbini#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 CollectionSettingUpdateParams.PaymentMethodOptions.Konbini#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 + @EqualsAndHashCode(callSuper = false) + public static class SepaDebit { + /** + * 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 SepaDebit(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 CollectionSettingUpdateParams.PaymentMethodOptions.SepaDebit build() { + return new CollectionSettingUpdateParams.PaymentMethodOptions.SepaDebit(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 CollectionSettingUpdateParams.PaymentMethodOptions.SepaDebit#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 CollectionSettingUpdateParams.PaymentMethodOptions.SepaDebit#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 @EqualsAndHashCode(callSuper = false) public static class UsBankAccount { diff --git a/src/main/java/com/stripe/param/v2/billing/IntentCreateParams.java b/src/main/java/com/stripe/param/v2/billing/IntentCreateParams.java index c6807424046..083cc344ed7 100644 --- a/src/main/java/com/stripe/param/v2/billing/IntentCreateParams.java +++ b/src/main/java/com/stripe/param/v2/billing/IntentCreateParams.java @@ -1319,12 +1319,17 @@ public static class CustomPricingUnit { @SerializedName(ApiRequestParams.EXTRA_PARAMS_KEY) Map extraParams; + /** The id of the custom pricing unit. */ + @SerializedName("id") + String id; + /** Required. The value of the custom pricing unit. */ @SerializedName("value") String value; - private CustomPricingUnit(Map extraParams, String value) { + private CustomPricingUnit(Map extraParams, String id, String value) { this.extraParams = extraParams; + this.id = id; this.value = value; } @@ -1335,6 +1340,8 @@ public static Builder builder() { public static class Builder { private Map extraParams; + private String id; + private String value; /** Finalize and obtain parameter instance from this builder. */ @@ -1342,7 +1349,7 @@ public static class Builder { .Amount.CustomPricingUnit build() { return new IntentCreateParams.Action.Apply.SpendModifierRule.MaxBillingPeriodSpend - .Amount.CustomPricingUnit(this.extraParams, this.value); + .Amount.CustomPricingUnit(this.extraParams, this.id, this.value); } /** @@ -1375,6 +1382,12 @@ public Builder putAllExtraParam(Map map) { return this; } + /** The id of the custom pricing unit. */ + public Builder setId(String id) { + this.id = id; + return this; + } + /** Required. The value of the custom pricing unit. */ public Builder setValue(String value) { this.value = value; diff --git a/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java b/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java index 3a445207e0b..0cd6fcf0b2f 100644 --- a/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java +++ b/src/main/java/com/stripe/param/v2/core/AccountCreateParams.java @@ -25434,9 +25434,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_vat") BG_VAT("bg_vat"), + @SerializedName("bm_crn") + BM_CRN("bm_crn"), + + @SerializedName("bo_tin") + BO_TIN("bo_tin"), + @SerializedName("br_cnpj") BR_CNPJ("br_cnpj"), + @SerializedName("bt_tpn") + BT_TPN("bt_tpn"), + @SerializedName("ca_cn") CA_CN("ca_cn"), @@ -25458,6 +25467,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ch_uid") CH_UID("ch_uid"), + @SerializedName("co_nit") + CO_NIT("co_nit"), + @SerializedName("cr_cpj") CR_CPJ("cr_cpj"), @@ -25497,12 +25509,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("do_rcn") DO_RCN("do_rcn"), + @SerializedName("ec_ruc") + EC_RUC("ec_ruc"), + @SerializedName("ee_rk") EE_RK("ee_rk"), @SerializedName("ee_vat") EE_VAT("ee_vat"), + @SerializedName("eg_tin") + EG_TIN("eg_tin"), + @SerializedName("es_cif") ES_CIF("es_cif"), @@ -25530,6 +25548,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_vat") GB_VAT("gb_vat"), + @SerializedName("gh_tin") + GH_TIN("gh_tin"), + @SerializedName("gi_crn") GI_CRN("gi_crn"), @@ -25545,12 +25566,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gt_nit") GT_NIT("gt_nit"), + @SerializedName("gy_tin") + GY_TIN("gy_tin"), + @SerializedName("hk_br") HK_BR("hk_br"), @SerializedName("hk_cr") HK_CR("hk_cr"), + @SerializedName("hn_rtn") + HN_RTN("hn_rtn"), + @SerializedName("hr_mbs") HR_MBS("hr_mbs"), @@ -25584,15 +25611,30 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_vat") IT_VAT("it_vat"), + @SerializedName("jm_trn") + JM_TRN("jm_trn"), + + @SerializedName("jo_crn") + JO_CRN("jo_crn"), + @SerializedName("jp_cn") JP_CN("jp_cn"), + @SerializedName("ke_pin") + KE_PIN("ke_pin"), + + @SerializedName("ky_crn") + KY_CRN("ky_crn"), + @SerializedName("kz_bin") KZ_BIN("kz_bin"), @SerializedName("li_uid") LI_UID("li_uid"), + @SerializedName("lk_tin") + LK_TIN("lk_tin"), + @SerializedName("lt_ccrn") LT_CCRN("lt_ccrn"), @@ -25614,6 +25656,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_vat") LV_VAT("lv_vat"), + @SerializedName("mo_tin") + MO_TIN("mo_tin"), + @SerializedName("mt_crn") MT_CRN("mt_crn"), @@ -25623,6 +25668,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mt_vat") MT_VAT("mt_vat"), + @SerializedName("mv_tin") + MV_TIN("mv_tin"), + @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -25641,6 +25689,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mz_nuit") MZ_NUIT("mz_nuit"), + @SerializedName("ng_tin") + NG_TIN("ng_tin"), + @SerializedName("nl_kvk") NL_KVK("nl_kvk"), @@ -25659,9 +25710,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), + @SerializedName("pa_ruc") + PA_RUC("pa_ruc"), + @SerializedName("pe_ruc") PE_RUC("pe_ruc"), + @SerializedName("ph_tin") + PH_TIN("ph_tin"), + @SerializedName("pk_ntn") PK_NTN("pk_ntn"), @@ -25677,6 +25734,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_vat") PT_VAT("pt_vat"), + @SerializedName("py_ruc") + PY_RUC("py_ruc"), + @SerializedName("ro_cui") RO_CUI("ro_cui"), @@ -25719,6 +25779,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sk_vat") SK_VAT("sk_vat"), + @SerializedName("sl_tin") + SL_TIN("sl_tin"), + + @SerializedName("sv_nit") + SV_NIT("sv_nit"), + @SerializedName("th_crn") TH_CRN("th_crn"), @@ -25729,7 +25795,16 @@ public enum Type implements ApiRequestParams.EnumParam { TH_TIN("th_tin"), @SerializedName("us_ein") - US_EIN("us_ein"); + US_EIN("us_ein"), + + @SerializedName("uy_ruc") + UY_RUC("uy_ruc"), + + @SerializedName("vg_cn") + VG_CN("vg_cn"), + + @SerializedName("za_tin") + ZA_TIN("za_tin"); @Getter(onMethod_ = {@Override}) private final String value; @@ -28883,12 +28958,21 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), + @SerializedName("bm_pp") + BM_PP("bm_pp"), + @SerializedName("bn_nric") BN_NRIC("bn_nric"), + @SerializedName("bo_ci") + BO_CI("bo_ci"), + @SerializedName("br_cpf") BR_CPF("br_cpf"), + @SerializedName("bt_cid") + BT_CID("bt_cid"), + @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -28940,6 +29024,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), + @SerializedName("eg_tin") + EG_TIN("eg_tin"), + @SerializedName("es_nif") ES_NIF("es_nif"), @@ -28952,15 +29039,24 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), + @SerializedName("gh_pin") + GH_PIN("gh_pin"), + @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), + @SerializedName("gy_tin") + GY_TIN("gy_tin"), + @SerializedName("hk_id") HK_ID("hk_id"), + @SerializedName("hn_rtn") + HN_RTN("hn_rtn"), + @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -28979,18 +29075,30 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), + @SerializedName("jm_trn") + JM_TRN("jm_trn"), + + @SerializedName("jo_pin") + JO_PIN("jo_pin"), + @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), + @SerializedName("ky_pp") + KY_PP("ky_pp"), + @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), + @SerializedName("lk_nic") + LK_NIC("lk_nic"), + @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -29000,6 +29108,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), + @SerializedName("mo_bir") + MO_BIR("mo_bir"), + + @SerializedName("mt_nic") + MT_NIC("mt_nic"), + + @SerializedName("mv_tin") + MV_TIN("mv_tin"), + @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -29021,9 +29138,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), + @SerializedName("pa_ruc") + PA_RUC("pa_ruc"), + @SerializedName("pe_dni") PE_DNI("pe_dni"), + @SerializedName("ph_tin") + PH_TIN("ph_tin"), + @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -29036,6 +29159,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), + @SerializedName("py_ruc") + PY_RUC("py_ruc"), + @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -29051,9 +29177,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), + @SerializedName("si_pin") + SI_PIN("si_pin"), + @SerializedName("sk_dic") SK_DIC("sk_dic"), + @SerializedName("sv_nit") + SV_NIT("sv_nit"), + @SerializedName("th_lc") TH_LC("th_lc"), @@ -29078,6 +29210,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), + @SerializedName("vg_pp") + VG_PP("vg_pp"), + @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/core/AccountTokenCreateParams.java b/src/main/java/com/stripe/param/v2/core/AccountTokenCreateParams.java index ee37187eb92..406a28dfa91 100644 --- a/src/main/java/com/stripe/param/v2/core/AccountTokenCreateParams.java +++ b/src/main/java/com/stripe/param/v2/core/AccountTokenCreateParams.java @@ -5619,9 +5619,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_vat") BG_VAT("bg_vat"), + @SerializedName("bm_crn") + BM_CRN("bm_crn"), + + @SerializedName("bo_tin") + BO_TIN("bo_tin"), + @SerializedName("br_cnpj") BR_CNPJ("br_cnpj"), + @SerializedName("bt_tpn") + BT_TPN("bt_tpn"), + @SerializedName("ca_cn") CA_CN("ca_cn"), @@ -5643,6 +5652,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ch_uid") CH_UID("ch_uid"), + @SerializedName("co_nit") + CO_NIT("co_nit"), + @SerializedName("cr_cpj") CR_CPJ("cr_cpj"), @@ -5682,12 +5694,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("do_rcn") DO_RCN("do_rcn"), + @SerializedName("ec_ruc") + EC_RUC("ec_ruc"), + @SerializedName("ee_rk") EE_RK("ee_rk"), @SerializedName("ee_vat") EE_VAT("ee_vat"), + @SerializedName("eg_tin") + EG_TIN("eg_tin"), + @SerializedName("es_cif") ES_CIF("es_cif"), @@ -5715,6 +5733,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_vat") GB_VAT("gb_vat"), + @SerializedName("gh_tin") + GH_TIN("gh_tin"), + @SerializedName("gi_crn") GI_CRN("gi_crn"), @@ -5730,12 +5751,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gt_nit") GT_NIT("gt_nit"), + @SerializedName("gy_tin") + GY_TIN("gy_tin"), + @SerializedName("hk_br") HK_BR("hk_br"), @SerializedName("hk_cr") HK_CR("hk_cr"), + @SerializedName("hn_rtn") + HN_RTN("hn_rtn"), + @SerializedName("hr_mbs") HR_MBS("hr_mbs"), @@ -5769,15 +5796,30 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_vat") IT_VAT("it_vat"), + @SerializedName("jm_trn") + JM_TRN("jm_trn"), + + @SerializedName("jo_crn") + JO_CRN("jo_crn"), + @SerializedName("jp_cn") JP_CN("jp_cn"), + @SerializedName("ke_pin") + KE_PIN("ke_pin"), + + @SerializedName("ky_crn") + KY_CRN("ky_crn"), + @SerializedName("kz_bin") KZ_BIN("kz_bin"), @SerializedName("li_uid") LI_UID("li_uid"), + @SerializedName("lk_tin") + LK_TIN("lk_tin"), + @SerializedName("lt_ccrn") LT_CCRN("lt_ccrn"), @@ -5799,6 +5841,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_vat") LV_VAT("lv_vat"), + @SerializedName("mo_tin") + MO_TIN("mo_tin"), + @SerializedName("mt_crn") MT_CRN("mt_crn"), @@ -5808,6 +5853,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mt_vat") MT_VAT("mt_vat"), + @SerializedName("mv_tin") + MV_TIN("mv_tin"), + @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -5826,6 +5874,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mz_nuit") MZ_NUIT("mz_nuit"), + @SerializedName("ng_tin") + NG_TIN("ng_tin"), + @SerializedName("nl_kvk") NL_KVK("nl_kvk"), @@ -5844,9 +5895,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), + @SerializedName("pa_ruc") + PA_RUC("pa_ruc"), + @SerializedName("pe_ruc") PE_RUC("pe_ruc"), + @SerializedName("ph_tin") + PH_TIN("ph_tin"), + @SerializedName("pk_ntn") PK_NTN("pk_ntn"), @@ -5862,6 +5919,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_vat") PT_VAT("pt_vat"), + @SerializedName("py_ruc") + PY_RUC("py_ruc"), + @SerializedName("ro_cui") RO_CUI("ro_cui"), @@ -5904,6 +5964,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sk_vat") SK_VAT("sk_vat"), + @SerializedName("sl_tin") + SL_TIN("sl_tin"), + + @SerializedName("sv_nit") + SV_NIT("sv_nit"), + @SerializedName("th_crn") TH_CRN("th_crn"), @@ -5914,7 +5980,16 @@ public enum Type implements ApiRequestParams.EnumParam { TH_TIN("th_tin"), @SerializedName("us_ein") - US_EIN("us_ein"); + US_EIN("us_ein"), + + @SerializedName("uy_ruc") + UY_RUC("uy_ruc"), + + @SerializedName("vg_cn") + VG_CN("vg_cn"), + + @SerializedName("za_tin") + ZA_TIN("za_tin"); @Getter(onMethod_ = {@Override}) private final String value; @@ -9101,12 +9176,21 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), + @SerializedName("bm_pp") + BM_PP("bm_pp"), + @SerializedName("bn_nric") BN_NRIC("bn_nric"), + @SerializedName("bo_ci") + BO_CI("bo_ci"), + @SerializedName("br_cpf") BR_CPF("br_cpf"), + @SerializedName("bt_cid") + BT_CID("bt_cid"), + @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -9158,6 +9242,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), + @SerializedName("eg_tin") + EG_TIN("eg_tin"), + @SerializedName("es_nif") ES_NIF("es_nif"), @@ -9170,15 +9257,24 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), + @SerializedName("gh_pin") + GH_PIN("gh_pin"), + @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), + @SerializedName("gy_tin") + GY_TIN("gy_tin"), + @SerializedName("hk_id") HK_ID("hk_id"), + @SerializedName("hn_rtn") + HN_RTN("hn_rtn"), + @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -9197,18 +9293,30 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), + @SerializedName("jm_trn") + JM_TRN("jm_trn"), + + @SerializedName("jo_pin") + JO_PIN("jo_pin"), + @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), + @SerializedName("ky_pp") + KY_PP("ky_pp"), + @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), + @SerializedName("lk_nic") + LK_NIC("lk_nic"), + @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -9218,6 +9326,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), + @SerializedName("mo_bir") + MO_BIR("mo_bir"), + + @SerializedName("mt_nic") + MT_NIC("mt_nic"), + + @SerializedName("mv_tin") + MV_TIN("mv_tin"), + @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -9239,9 +9356,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), + @SerializedName("pa_ruc") + PA_RUC("pa_ruc"), + @SerializedName("pe_dni") PE_DNI("pe_dni"), + @SerializedName("ph_tin") + PH_TIN("ph_tin"), + @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -9254,6 +9377,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), + @SerializedName("py_ruc") + PY_RUC("py_ruc"), + @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -9269,9 +9395,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), + @SerializedName("si_pin") + SI_PIN("si_pin"), + @SerializedName("sk_dic") SK_DIC("sk_dic"), + @SerializedName("sv_nit") + SV_NIT("sv_nit"), + @SerializedName("th_lc") TH_LC("th_lc"), @@ -9296,6 +9428,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), + @SerializedName("vg_pp") + VG_PP("vg_pp"), + @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java b/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java index 97443bedc14..0496cd0ad75 100644 --- a/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java +++ b/src/main/java/com/stripe/param/v2/core/AccountUpdateParams.java @@ -26995,9 +26995,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_vat") BG_VAT("bg_vat"), + @SerializedName("bm_crn") + BM_CRN("bm_crn"), + + @SerializedName("bo_tin") + BO_TIN("bo_tin"), + @SerializedName("br_cnpj") BR_CNPJ("br_cnpj"), + @SerializedName("bt_tpn") + BT_TPN("bt_tpn"), + @SerializedName("ca_cn") CA_CN("ca_cn"), @@ -27019,6 +27028,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ch_uid") CH_UID("ch_uid"), + @SerializedName("co_nit") + CO_NIT("co_nit"), + @SerializedName("cr_cpj") CR_CPJ("cr_cpj"), @@ -27058,12 +27070,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("do_rcn") DO_RCN("do_rcn"), + @SerializedName("ec_ruc") + EC_RUC("ec_ruc"), + @SerializedName("ee_rk") EE_RK("ee_rk"), @SerializedName("ee_vat") EE_VAT("ee_vat"), + @SerializedName("eg_tin") + EG_TIN("eg_tin"), + @SerializedName("es_cif") ES_CIF("es_cif"), @@ -27091,6 +27109,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_vat") GB_VAT("gb_vat"), + @SerializedName("gh_tin") + GH_TIN("gh_tin"), + @SerializedName("gi_crn") GI_CRN("gi_crn"), @@ -27106,12 +27127,18 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gt_nit") GT_NIT("gt_nit"), + @SerializedName("gy_tin") + GY_TIN("gy_tin"), + @SerializedName("hk_br") HK_BR("hk_br"), @SerializedName("hk_cr") HK_CR("hk_cr"), + @SerializedName("hn_rtn") + HN_RTN("hn_rtn"), + @SerializedName("hr_mbs") HR_MBS("hr_mbs"), @@ -27145,15 +27172,30 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_vat") IT_VAT("it_vat"), + @SerializedName("jm_trn") + JM_TRN("jm_trn"), + + @SerializedName("jo_crn") + JO_CRN("jo_crn"), + @SerializedName("jp_cn") JP_CN("jp_cn"), + @SerializedName("ke_pin") + KE_PIN("ke_pin"), + + @SerializedName("ky_crn") + KY_CRN("ky_crn"), + @SerializedName("kz_bin") KZ_BIN("kz_bin"), @SerializedName("li_uid") LI_UID("li_uid"), + @SerializedName("lk_tin") + LK_TIN("lk_tin"), + @SerializedName("lt_ccrn") LT_CCRN("lt_ccrn"), @@ -27175,6 +27217,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_vat") LV_VAT("lv_vat"), + @SerializedName("mo_tin") + MO_TIN("mo_tin"), + @SerializedName("mt_crn") MT_CRN("mt_crn"), @@ -27184,6 +27229,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mt_vat") MT_VAT("mt_vat"), + @SerializedName("mv_tin") + MV_TIN("mv_tin"), + @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -27202,6 +27250,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("mz_nuit") MZ_NUIT("mz_nuit"), + @SerializedName("ng_tin") + NG_TIN("ng_tin"), + @SerializedName("nl_kvk") NL_KVK("nl_kvk"), @@ -27220,9 +27271,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), + @SerializedName("pa_ruc") + PA_RUC("pa_ruc"), + @SerializedName("pe_ruc") PE_RUC("pe_ruc"), + @SerializedName("ph_tin") + PH_TIN("ph_tin"), + @SerializedName("pk_ntn") PK_NTN("pk_ntn"), @@ -27238,6 +27295,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_vat") PT_VAT("pt_vat"), + @SerializedName("py_ruc") + PY_RUC("py_ruc"), + @SerializedName("ro_cui") RO_CUI("ro_cui"), @@ -27280,6 +27340,12 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sk_vat") SK_VAT("sk_vat"), + @SerializedName("sl_tin") + SL_TIN("sl_tin"), + + @SerializedName("sv_nit") + SV_NIT("sv_nit"), + @SerializedName("th_crn") TH_CRN("th_crn"), @@ -27290,7 +27356,16 @@ public enum Type implements ApiRequestParams.EnumParam { TH_TIN("th_tin"), @SerializedName("us_ein") - US_EIN("us_ein"); + US_EIN("us_ein"), + + @SerializedName("uy_ruc") + UY_RUC("uy_ruc"), + + @SerializedName("vg_cn") + VG_CN("vg_cn"), + + @SerializedName("za_tin") + ZA_TIN("za_tin"); @Getter(onMethod_ = {@Override}) private final String value; @@ -30748,12 +30823,21 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), + @SerializedName("bm_pp") + BM_PP("bm_pp"), + @SerializedName("bn_nric") BN_NRIC("bn_nric"), + @SerializedName("bo_ci") + BO_CI("bo_ci"), + @SerializedName("br_cpf") BR_CPF("br_cpf"), + @SerializedName("bt_cid") + BT_CID("bt_cid"), + @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -30805,6 +30889,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), + @SerializedName("eg_tin") + EG_TIN("eg_tin"), + @SerializedName("es_nif") ES_NIF("es_nif"), @@ -30817,15 +30904,24 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), + @SerializedName("gh_pin") + GH_PIN("gh_pin"), + @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), + @SerializedName("gy_tin") + GY_TIN("gy_tin"), + @SerializedName("hk_id") HK_ID("hk_id"), + @SerializedName("hn_rtn") + HN_RTN("hn_rtn"), + @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -30844,18 +30940,30 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), + @SerializedName("jm_trn") + JM_TRN("jm_trn"), + + @SerializedName("jo_pin") + JO_PIN("jo_pin"), + @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), + @SerializedName("ky_pp") + KY_PP("ky_pp"), + @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), + @SerializedName("lk_nic") + LK_NIC("lk_nic"), + @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -30865,6 +30973,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), + @SerializedName("mo_bir") + MO_BIR("mo_bir"), + + @SerializedName("mt_nic") + MT_NIC("mt_nic"), + + @SerializedName("mv_tin") + MV_TIN("mv_tin"), + @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -30886,9 +31003,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), + @SerializedName("pa_ruc") + PA_RUC("pa_ruc"), + @SerializedName("pe_dni") PE_DNI("pe_dni"), + @SerializedName("ph_tin") + PH_TIN("ph_tin"), + @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -30901,6 +31024,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), + @SerializedName("py_ruc") + PY_RUC("py_ruc"), + @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -30916,9 +31042,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), + @SerializedName("si_pin") + SI_PIN("si_pin"), + @SerializedName("sk_dic") SK_DIC("sk_dic"), + @SerializedName("sv_nit") + SV_NIT("sv_nit"), + @SerializedName("th_lc") TH_LC("th_lc"), @@ -30943,6 +31075,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), + @SerializedName("vg_pp") + VG_PP("vg_pp"), + @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/core/accounts/PersonCreateParams.java b/src/main/java/com/stripe/param/v2/core/accounts/PersonCreateParams.java index 23964e137e1..2c10a824029 100644 --- a/src/main/java/com/stripe/param/v2/core/accounts/PersonCreateParams.java +++ b/src/main/java/com/stripe/param/v2/core/accounts/PersonCreateParams.java @@ -2335,12 +2335,21 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), + @SerializedName("bm_pp") + BM_PP("bm_pp"), + @SerializedName("bn_nric") BN_NRIC("bn_nric"), + @SerializedName("bo_ci") + BO_CI("bo_ci"), + @SerializedName("br_cpf") BR_CPF("br_cpf"), + @SerializedName("bt_cid") + BT_CID("bt_cid"), + @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -2392,6 +2401,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), + @SerializedName("eg_tin") + EG_TIN("eg_tin"), + @SerializedName("es_nif") ES_NIF("es_nif"), @@ -2404,15 +2416,24 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), + @SerializedName("gh_pin") + GH_PIN("gh_pin"), + @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), + @SerializedName("gy_tin") + GY_TIN("gy_tin"), + @SerializedName("hk_id") HK_ID("hk_id"), + @SerializedName("hn_rtn") + HN_RTN("hn_rtn"), + @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -2431,18 +2452,30 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), + @SerializedName("jm_trn") + JM_TRN("jm_trn"), + + @SerializedName("jo_pin") + JO_PIN("jo_pin"), + @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), + @SerializedName("ky_pp") + KY_PP("ky_pp"), + @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), + @SerializedName("lk_nic") + LK_NIC("lk_nic"), + @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -2452,6 +2485,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), + @SerializedName("mo_bir") + MO_BIR("mo_bir"), + + @SerializedName("mt_nic") + MT_NIC("mt_nic"), + + @SerializedName("mv_tin") + MV_TIN("mv_tin"), + @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -2473,9 +2515,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), + @SerializedName("pa_ruc") + PA_RUC("pa_ruc"), + @SerializedName("pe_dni") PE_DNI("pe_dni"), + @SerializedName("ph_tin") + PH_TIN("ph_tin"), + @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -2488,6 +2536,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), + @SerializedName("py_ruc") + PY_RUC("py_ruc"), + @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -2503,9 +2554,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), + @SerializedName("si_pin") + SI_PIN("si_pin"), + @SerializedName("sk_dic") SK_DIC("sk_dic"), + @SerializedName("sv_nit") + SV_NIT("sv_nit"), + @SerializedName("th_lc") TH_LC("th_lc"), @@ -2530,6 +2587,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), + @SerializedName("vg_pp") + VG_PP("vg_pp"), + @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/core/accounts/PersonTokenCreateParams.java b/src/main/java/com/stripe/param/v2/core/accounts/PersonTokenCreateParams.java index 47d2c7f0f15..f63fa28f248 100644 --- a/src/main/java/com/stripe/param/v2/core/accounts/PersonTokenCreateParams.java +++ b/src/main/java/com/stripe/param/v2/core/accounts/PersonTokenCreateParams.java @@ -2305,12 +2305,21 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), + @SerializedName("bm_pp") + BM_PP("bm_pp"), + @SerializedName("bn_nric") BN_NRIC("bn_nric"), + @SerializedName("bo_ci") + BO_CI("bo_ci"), + @SerializedName("br_cpf") BR_CPF("br_cpf"), + @SerializedName("bt_cid") + BT_CID("bt_cid"), + @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -2362,6 +2371,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), + @SerializedName("eg_tin") + EG_TIN("eg_tin"), + @SerializedName("es_nif") ES_NIF("es_nif"), @@ -2374,15 +2386,24 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), + @SerializedName("gh_pin") + GH_PIN("gh_pin"), + @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), + @SerializedName("gy_tin") + GY_TIN("gy_tin"), + @SerializedName("hk_id") HK_ID("hk_id"), + @SerializedName("hn_rtn") + HN_RTN("hn_rtn"), + @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -2401,18 +2422,30 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), + @SerializedName("jm_trn") + JM_TRN("jm_trn"), + + @SerializedName("jo_pin") + JO_PIN("jo_pin"), + @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), + @SerializedName("ky_pp") + KY_PP("ky_pp"), + @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), + @SerializedName("lk_nic") + LK_NIC("lk_nic"), + @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -2422,6 +2455,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), + @SerializedName("mo_bir") + MO_BIR("mo_bir"), + + @SerializedName("mt_nic") + MT_NIC("mt_nic"), + + @SerializedName("mv_tin") + MV_TIN("mv_tin"), + @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -2443,9 +2485,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), + @SerializedName("pa_ruc") + PA_RUC("pa_ruc"), + @SerializedName("pe_dni") PE_DNI("pe_dni"), + @SerializedName("ph_tin") + PH_TIN("ph_tin"), + @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -2458,6 +2506,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), + @SerializedName("py_ruc") + PY_RUC("py_ruc"), + @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -2473,9 +2524,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), + @SerializedName("si_pin") + SI_PIN("si_pin"), + @SerializedName("sk_dic") SK_DIC("sk_dic"), + @SerializedName("sv_nit") + SV_NIT("sv_nit"), + @SerializedName("th_lc") TH_LC("th_lc"), @@ -2500,6 +2557,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), + @SerializedName("vg_pp") + VG_PP("vg_pp"), + @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/core/accounts/PersonUpdateParams.java b/src/main/java/com/stripe/param/v2/core/accounts/PersonUpdateParams.java index 001c826555a..f0a7b7f98a6 100644 --- a/src/main/java/com/stripe/param/v2/core/accounts/PersonUpdateParams.java +++ b/src/main/java/com/stripe/param/v2/core/accounts/PersonUpdateParams.java @@ -2553,12 +2553,21 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("bg_ucn") BG_UCN("bg_ucn"), + @SerializedName("bm_pp") + BM_PP("bm_pp"), + @SerializedName("bn_nric") BN_NRIC("bn_nric"), + @SerializedName("bo_ci") + BO_CI("bo_ci"), + @SerializedName("br_cpf") BR_CPF("br_cpf"), + @SerializedName("bt_cid") + BT_CID("bt_cid"), + @SerializedName("ca_sin") CA_SIN("ca_sin"), @@ -2610,6 +2619,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("ee_ik") EE_IK("ee_ik"), + @SerializedName("eg_tin") + EG_TIN("eg_tin"), + @SerializedName("es_nif") ES_NIF("es_nif"), @@ -2622,15 +2634,24 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("gb_nino") GB_NINO("gb_nino"), + @SerializedName("gh_pin") + GH_PIN("gh_pin"), + @SerializedName("gr_afm") GR_AFM("gr_afm"), @SerializedName("gt_nit") GT_NIT("gt_nit"), + @SerializedName("gy_tin") + GY_TIN("gy_tin"), + @SerializedName("hk_id") HK_ID("hk_id"), + @SerializedName("hn_rtn") + HN_RTN("hn_rtn"), + @SerializedName("hr_oib") HR_OIB("hr_oib"), @@ -2649,18 +2670,30 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("it_cf") IT_CF("it_cf"), + @SerializedName("jm_trn") + JM_TRN("jm_trn"), + + @SerializedName("jo_pin") + JO_PIN("jo_pin"), + @SerializedName("jp_inc") JP_INC("jp_inc"), @SerializedName("ke_pin") KE_PIN("ke_pin"), + @SerializedName("ky_pp") + KY_PP("ky_pp"), + @SerializedName("kz_iin") KZ_IIN("kz_iin"), @SerializedName("li_peid") LI_PEID("li_peid"), + @SerializedName("lk_nic") + LK_NIC("lk_nic"), + @SerializedName("lt_ak") LT_AK("lt_ak"), @@ -2670,6 +2703,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("lv_pk") LV_PK("lv_pk"), + @SerializedName("mo_bir") + MO_BIR("mo_bir"), + + @SerializedName("mt_nic") + MT_NIC("mt_nic"), + + @SerializedName("mv_tin") + MV_TIN("mv_tin"), + @SerializedName("mx_rfc") MX_RFC("mx_rfc"), @@ -2691,9 +2733,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("nz_ird") NZ_IRD("nz_ird"), + @SerializedName("pa_ruc") + PA_RUC("pa_ruc"), + @SerializedName("pe_dni") PE_DNI("pe_dni"), + @SerializedName("ph_tin") + PH_TIN("ph_tin"), + @SerializedName("pk_cnic") PK_CNIC("pk_cnic"), @@ -2706,6 +2754,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("pt_nif") PT_NIF("pt_nif"), + @SerializedName("py_ruc") + PY_RUC("py_ruc"), + @SerializedName("ro_cnp") RO_CNP("ro_cnp"), @@ -2721,9 +2772,15 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("sg_nric") SG_NRIC("sg_nric"), + @SerializedName("si_pin") + SI_PIN("si_pin"), + @SerializedName("sk_dic") SK_DIC("sk_dic"), + @SerializedName("sv_nit") + SV_NIT("sv_nit"), + @SerializedName("th_lc") TH_LC("th_lc"), @@ -2748,6 +2805,9 @@ public enum Type implements ApiRequestParams.EnumParam { @SerializedName("uy_dni") UY_DNI("uy_dni"), + @SerializedName("vg_pp") + VG_PP("vg_pp"), + @SerializedName("za_id") ZA_ID("za_id"); diff --git a/src/main/java/com/stripe/param/v2/payments/OffSessionPaymentCaptureParams.java b/src/main/java/com/stripe/param/v2/payments/OffSessionPaymentCaptureParams.java index 119fd11a1f9..bd8b24b3190 100644 --- a/src/main/java/com/stripe/param/v2/payments/OffSessionPaymentCaptureParams.java +++ b/src/main/java/com/stripe/param/v2/payments/OffSessionPaymentCaptureParams.java @@ -3,6 +3,7 @@ import com.google.gson.annotations.SerializedName; import com.stripe.net.ApiRequestParams; +import com.stripe.v2.Amount; import java.util.HashMap; import java.util.Map; import lombok.EqualsAndHashCode; @@ -15,6 +16,10 @@ public class OffSessionPaymentCaptureParams extends ApiRequestParams { @SerializedName("amount_to_capture") Long amountToCapture; + /** The amount of the application fee for this capture. */ + @SerializedName("application_fee_amount") + Amount applicationFeeAmount; + /** * 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 @@ -63,12 +68,14 @@ public class OffSessionPaymentCaptureParams extends ApiRequestParams { private OffSessionPaymentCaptureParams( Long amountToCapture, + Amount applicationFeeAmount, Map extraParams, Map metadata, String statementDescriptor, String statementDescriptorSuffix, TransferData transferData) { this.amountToCapture = amountToCapture; + this.applicationFeeAmount = applicationFeeAmount; this.extraParams = extraParams; this.metadata = metadata; this.statementDescriptor = statementDescriptor; @@ -83,6 +90,8 @@ public static Builder builder() { public static class Builder { private Long amountToCapture; + private Amount applicationFeeAmount; + private Map extraParams; private Map metadata; @@ -97,6 +106,7 @@ public static class Builder { public OffSessionPaymentCaptureParams build() { return new OffSessionPaymentCaptureParams( this.amountToCapture, + this.applicationFeeAmount, this.extraParams, this.metadata, this.statementDescriptor, @@ -110,6 +120,12 @@ public Builder setAmountToCapture(Long amountToCapture) { return this; } + /** The amount of the application fee for this capture. */ + public Builder setApplicationFeeAmount(Amount applicationFeeAmount) { + this.applicationFeeAmount = applicationFeeAmount; + 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 diff --git a/src/main/java/com/stripe/param/v2/payments/OffSessionPaymentCreateParams.java b/src/main/java/com/stripe/param/v2/payments/OffSessionPaymentCreateParams.java index e256020de47..19ab90145bc 100644 --- a/src/main/java/com/stripe/param/v2/payments/OffSessionPaymentCreateParams.java +++ b/src/main/java/com/stripe/param/v2/payments/OffSessionPaymentCreateParams.java @@ -16,6 +16,13 @@ public class OffSessionPaymentCreateParams extends ApiRequestParams { @SerializedName("amount") Amount amount; + /** + * The amount of the application fee (if any) that will be requested to be applied to the payment + * and transferred to the application owner's Stripe account. + */ + @SerializedName("application_fee_amount") + Amount applicationFeeAmount; + /** Required. The frequency of the underlying payment. */ @SerializedName("cadence") Cadence cadence; @@ -107,6 +114,7 @@ public class OffSessionPaymentCreateParams extends ApiRequestParams { private OffSessionPaymentCreateParams( Amount amount, + Amount applicationFeeAmount, Cadence cadence, Capture capture, String customer, @@ -123,6 +131,7 @@ private OffSessionPaymentCreateParams( String testClock, TransferData transferData) { this.amount = amount; + this.applicationFeeAmount = applicationFeeAmount; this.cadence = cadence; this.capture = capture; this.customer = customer; @@ -147,6 +156,8 @@ public static Builder builder() { public static class Builder { private Amount amount; + private Amount applicationFeeAmount; + private Cadence cadence; private Capture capture; @@ -181,6 +192,7 @@ public static class Builder { public OffSessionPaymentCreateParams build() { return new OffSessionPaymentCreateParams( this.amount, + this.applicationFeeAmount, this.cadence, this.capture, this.customer, @@ -204,6 +216,15 @@ public Builder setAmount(Amount amount) { return this; } + /** + * The amount of the application fee (if any) that will be requested to be applied to the + * payment and transferred to the application owner's Stripe account. + */ + public Builder setApplicationFeeAmount(Amount applicationFeeAmount) { + this.applicationFeeAmount = applicationFeeAmount; + return this; + } + /** Required. The frequency of the underlying payment. */ public Builder setCadence(OffSessionPaymentCreateParams.Cadence cadence) { this.cadence = cadence; diff --git a/src/test/java/com/stripe/functional/GeneratedExamples.java b/src/test/java/com/stripe/functional/GeneratedExamples.java index 3b09ce6beda..b0f72d93a01 100644 --- a/src/test/java/com/stripe/functional/GeneratedExamples.java +++ b/src/test/java/com/stripe/functional/GeneratedExamples.java @@ -3211,7 +3211,7 @@ public void testCoreEventsGetServices() throws StripeException { null, null, com.stripe.model.v2.core.Event.class, - "{\"changes\":{\"int_key\":123,\"string_key\":\"value\",\"boolean_key\":true,\"object_key\":{\"object_int_key\":123,\"object_string_key\":\"value\",\"object_boolean_key\":true},\"array_key\":[1,2,3]},\"context\":\"context\",\"created\":\"1970-01-12T21:42:34.472Z\",\"id\":\"obj_123\",\"livemode\":true,\"object\":\"v2.core.event\",\"reason\":{\"type\":\"request\",\"request\":{\"client\":{\"type\":\"api_key\",\"api_key\":{\"id\":\"obj_123\"},\"dashboard_user\":{\"email\":\"email\",\"ip_address\":\"ip_address\",\"machine_identifier\":\"machine_identifier\"},\"stripe_action\":{\"int_key\":123,\"string_key\":\"value\",\"boolean_key\":true,\"object_key\":{\"object_int_key\":123,\"object_string_key\":\"value\",\"object_boolean_key\":true},\"array_key\":[1,2,3]}},\"id\":\"obj_123\",\"idempotency_key\":\"idempotency_key\"}},\"type\":\"type\"}"); + "{\"changes\":{\"int_key\":123,\"string_key\":\"value\",\"boolean_key\":true,\"object_key\":{\"object_int_key\":123,\"object_string_key\":\"value\",\"object_boolean_key\":true},\"array_key\":[1,2,3]},\"context\":\"context\",\"created\":\"1970-01-12T21:42:34.472Z\",\"id\":\"obj_123\",\"livemode\":true,\"object\":\"v2.core.event\",\"reason\":{\"type\":\"request\",\"request\":{\"client\":{\"type\":\"api_key\",\"api_key\":{\"id\":\"obj_123\"},\"dashboard_user\":{\"email\":\"email\",\"ip_address\":\"ip_address\",\"machine_identifier\":\"machine_identifier\"},\"stripe_action\":{}},\"id\":\"obj_123\",\"idempotency_key\":\"idempotency_key\"}},\"type\":\"type\"}"); StripeClient client = new StripeClient(networkSpy); com.stripe.param.v2.core.EventRetrieveParams params = @@ -25163,6 +25163,7 @@ public void testV2BillingIntentPostServices() throws StripeException { .IntentCreateParams.Action.Apply .SpendModifierRule.MaxBillingPeriodSpend .Amount.CustomPricingUnit.builder() + .setId("obj_123") .setValue("value") .build()) .build())