Skip to content

Commit 922d825

Browse files
committed
Bump version to 30.0.0
1 parent 9bce680 commit 922d825

File tree

5 files changed

+81
-8
lines changed

5 files changed

+81
-8
lines changed

CHANGELOG.md

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,78 @@
11
# Changelog
22

3+
## 30.0.0 - 2025-09-30
4+
This release changes the pinned API version to `2025-09-30.clover` and contains breaking changes (prefixed with ⚠️ below)
5+
6+
* [#2036](https://github.com/stripe/stripe-java/pull/2036) ⚠️ Add strongly typed EventNotifications
7+
We've overhauled how V2 Events are handled in the SDK! This approach should provide a lot more information at authoring and compile time, leading to more robust integrations. As part of this process, there are a number of changes to be aware of.
8+
- Added matching `EventNotification` classes to every v2 `Event`. For example, there's now a `V1BillingMeterErrorReportTriggeredEventNotification` to match the existing `V1BillingMeterErrorReportTriggeredEvent`. Each notification class defines a `fetchEvent()` method to retrieve its corresponding event. For events with related objects, there's a `fetchRelatedObject()` method that performs the API call and casts the response to the correct type.
9+
- ⚠️ Rename function `StripeClient.parseThinEvent` to `StripeClient.parseEventNotification` and remove the `Stripe.ThinEvent` class.
10+
- This function now returns a `Stripe.V2.Core.EventNotification` (which is the shared base class that all of the more specific `Stripe.Events.*EventNotification` classes share) instead of `Stripe.ThinEvent`. When applicable, these event notifications will have the `relatedObject` property and a `fetchRelatedObject()` function. They also have a `fetchEvent()` method to retrieve their corresponding `Stripe.Event.*Event` instance.
11+
- If you parse an event the SDK doesn't have types for (e.g. it's newer than the SDK you're using), you'll get an instance of `Stripe.Events.UnknownEventNotification` instead of a more specific type. It has both the `relatedObject` property and the `fetchRelatedObject()` function (but they may be/return `null`)
12+
* [#2069](https://github.com/stripe/stripe-java/pull/2069) Move `V2.Event` API resources to `V2.Core.Events`
13+
- ⚠️ Move the below event related classes from `com.stripe.model.v2` to `com.stripe.model.v2.core`. This enables us to correctly match the API path to the namespace
14+
- `com.stripe.model.v2.Event` -> `com.stripe.model.v2.core.Event`
15+
- `com.stripe.model.v2.EventDestination` -> `com.stripe.model.v2.core.EventDestination`
16+
* [#2057](https://github.com/stripe/stripe-java/pull/2057) Add `StripeContext` object
17+
- Add the `StripeContext` class. Previously, you could set the stripe context only as a string via `StripeClientBuilder .setStripeContext()`. The same method can now take an instance of the `StripeContext` class as well
18+
- ⚠️ Change `EventNotification` (formerly known as `ThinEvent`)'s `context` property from `string` to `StripeContext`
19+
* [#2041](https://github.com/stripe/stripe-java/pull/2041) Throw `ApiKeyMissingException` instead of `IllegalArgumentException` for unset API keys
20+
- ⚠️ throw `ApiKeyMissingException` instead of `IllegalArgumentException` when making a request before setting an API key initializing a client without an API key. Tweak the wording of that message to better indicate how to fix.
21+
* [#2039](https://github.com/stripe/stripe-java/pull/2039) ⚠️ Build SDK w/ V2 OpenAPI spec
22+
- ⚠️ The delete methods for v2 APIs (the ones in the `StripeClient.v2` namespace) now return a `V2DeletedObject` which has the id of the object that has been deleted and a string representing the type of the object that has been deleted.
23+
- ⚠️ Query params on v2 APIs (like `limit`) are now `Long` instead of `Integer` (to match v1 APIs)
24+
- ⚠️ Deeply nested param hashes with no properties no longer have classes generated for them. Instead, they're typed as `Map<String, Object>`. Because there were no params, it's unlikely you were using these classes.
25+
* ⚠️ Deprecated the V1 service accessors living directly under StripeClient(e.g. customers, products) as they were copied under the new V1 service in our [last release](https://github.com/stripe/stripe-java/releases/tag/v29.5.0). Service accessors living directly under StripeClient(e.g. customers, products) will be removed from StripeClient in a future release. E.g.
26+
```diff
27+
StripeClient client = new StripeClient("sk_test...")
28+
29+
# Accessing V1 Stripe services on a StripeClient should be through the V1 namespace
30+
- client.customers().list()
31+
+ client.v1().customers().list()
32+
```
33+
Refer to the [migration guide](https://github.com/stripe/stripe-java/wiki/v1-namespace-in-StripeClient) for help upgrading.
34+
* [#2046](https://github.com/stripe/stripe-java/pull/2046) Adds v2 support to RateLimitException
35+
* ⚠️ The base class of `RateLimitException` has been changed from `InvalidRequestException` to `ApiException`. There is no change to the public interface for the `RateLimitException` class.
36+
* [#2037](https://github.com/stripe/stripe-java/pull/2037) Fix type bounds on request
37+
* ⚠️ Changes the signature of `LiveResponseGetter#request`, `ApiService#request`, and `StripeResponseGetter#request` to return `<T extends StripeObject>` instead of `<T extends StripeObjectInterface>`. This only affects advanced use cases where users are extending `StripeObjectInterface` with their own objects to deserialize Stripe responses. Those objects will now need to extend `StripeObject`.
38+
39+
* [#2040](https://github.com/stripe/stripe-java/pull/2040), [#2058](https://github.com/stripe/stripe-java/pull/2058), [#2059](https://github.com/stripe/stripe-java/pull/2059), [#2073](https://github.com/stripe/stripe-java/pull/2073) Update generated code based on incoming API changes in the `2025-09-30.clover` API version.
40+
* ⚠️ Remove support for `balanceReport` and `payoutReconciliationReport` on `AccountSession.components` and `AccountSessionCreateParams.components`
41+
* ⚠️ Change type of `InvoiceCreatePreviewParams.subscription_details.cancelAt`, `SubscriptionCreateParams.cancelAt` and `SubscriptionUpdateParams.cancelAt` from `DateTime` to `DateTime | enum('max_period_end'|'min_period_end')`
42+
* ⚠️ Remove support for values `saturday` and `sunday` from enums `AccountCreateParams.settings.payouts.schedule.weeklyPayoutDays` and `AccountUpdateParams.settings.payouts.schedule.weeklyPayoutDays`
43+
* ⚠️ Remove support for `iterations` on `InvoiceCreatePreviewParams.schedule_details.phases[]`, `SubscriptionScheduleCreateParams.phases[]`, and `SubscriptionScheduleUpdateParams.phases[]`
44+
* ⚠️ Remove support for `link` and `payByBank` on `PaymentMethodUpdateParams`
45+
* ⚠️ Remove support for `coupon` on `Discount`, `PromotionCodeCreateParams`, and `PromotionCode`. Use `Discount.source.coupon`, `PromotionCodeCreateParams.promotion.coupon`, and `PromotionCode.promotion.coupon` instead
46+
* Add support for new resource `BalanceSettings`
47+
* Add support for `retrieve` and `update` methods on resource `BalanceSettings`
48+
* Add support for `source` on `Discount`
49+
* Add support for `mbWayPayments` on `Account.capabilities`, `AccountCreateParams.capabilities`, and `AccountUpdateParams.capabilities`
50+
* Add support for `trialUpdateBehavior` on `billingportal.Configuration.features.subscription_update`, `billingportal.ConfigurationCreateParams.features.subscription_update`, and `billingportal.ConfigurationUpdateParams.features.subscription_update`
51+
* Add support for `mbWay` on `Charge.payment_method_details`, `ConfirmationToken.payment_method_preview`, `ConfirmationTokenCreateParams.payment_method_data`, `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`, `PaymentMethodCreateParams`, `PaymentMethod`, `SetupIntentConfirmParams.payment_method_data`, `SetupIntentCreateParams.payment_method_data`, and `SetupIntentUpdateParams.payment_method_data`
52+
* Add support for `brandingSettings` and `nameCollection` on `checkout.SessionCreateParams` and `checkout.Session`
53+
* Add support for `excludedPaymentMethodTypes` on `PaymentIntentConfirmParams`, `PaymentIntentUpdateParams`, `checkout.SessionCreateParams`, and `checkout.Session`
54+
* Add support for `unitLabel` on `InvoiceAddLinesParams.lines[].price_data.product_data`, `InvoiceLineItemUpdateParams.price_data.product_data`, `InvoiceUpdateLinesParams.lines[].price_data.product_data`, `PaymentLinkCreateParams.line_items[].price_data.product_data`, and `checkout.SessionCreateParams.line_items[].price_data.product_data`
55+
* Add support for `alma`, `billie`, and `satispay` on `checkout.Session.payment_method_options` and `checkout.SessionCreateParams.payment_method_options`
56+
* Add support for `demoPay` on `checkout.SessionCreateParams.payment_method_options`
57+
* Add support for `captureMethod` on `checkout.Session.payment_method_options.affirm`, `checkout.Session.payment_method_options.afterpay_clearpay`, `checkout.Session.payment_method_options.amazon_pay`, `checkout.Session.payment_method_options.card`, `checkout.Session.payment_method_options.cashapp`, `checkout.Session.payment_method_options.klarna`, `checkout.Session.payment_method_options.link`, `checkout.Session.payment_method_options.mobilepay`, `checkout.Session.payment_method_options.revolut_pay`, `checkout.SessionCreateParams.payment_method_options.affirm`, `checkout.SessionCreateParams.payment_method_options.afterpay_clearpay`, `checkout.SessionCreateParams.payment_method_options.amazon_pay`, `checkout.SessionCreateParams.payment_method_options.card`, `checkout.SessionCreateParams.payment_method_options.cashapp`, `checkout.SessionCreateParams.payment_method_options.klarna`, `checkout.SessionCreateParams.payment_method_options.link`, `checkout.SessionCreateParams.payment_method_options.mobilepay`, and `checkout.SessionCreateParams.payment_method_options.revolut_pay`
58+
* Add support for `flexible` on `InvoiceCreatePreviewParams.schedule_details.billing_mode`, `InvoiceCreatePreviewParams.subscription_details.billing_mode`, `Quote.subscription_data.billing_mode`, `QuoteCreateParams.subscription_data.billing_mode`, `Subscription.billing_mode`, `SubscriptionCreateParams.billing_mode`, `SubscriptionMigrateParams.billing_mode`, `SubscriptionSchedule.billing_mode`, `SubscriptionScheduleCreateParams.billing_mode`, and `checkout.SessionCreateParams.subscription_data.billing_mode`
59+
* Add support for `businessName` and `individualName` on `CustomerCreateParams`, `CustomerUpdateParams`, `Customer`, `checkout.Session.collected_information`, and `checkout.Session.customer_details`
60+
* Add support for new values `mb_way`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`
61+
* Add support for new values `mb_way`on enums `CustomerListPaymentMethodsParams.type`, `PaymentMethodCreateParams.type`, and `PaymentMethodListParams.type`
62+
* Add support for `chargebackLossReasonCode` on `Dispute.payment_method_details.klarna`
63+
* Add support for `netAmount` and `prorationDetails` on `InvoiceItem`
64+
* Add support for `fraudDisputabilityLikelihood` and `riskAssessment` on `issuing.AuthorizationCreateParams`
65+
* Add support for `secondLine` on `issuing.Card`
66+
* Add support for new values `mb_way`on enum `PaymentIntentCreateParams.excludedPaymentMethodTypes`
67+
* Add support for `frMealVoucherConecs` on `PaymentMethodConfigurationCreateParams` and `PaymentMethodConfigurationUpdateParams`
68+
* Add support for `promotion` on `PromotionCodeCreateParams` and `PromotionCode`
69+
* Add support for `provider` on `tax.Settings.defaults`
70+
* Add support for `bbposWisepad3` on `terminal.ConfigurationCreateParams`, `terminal.ConfigurationUpdateParams`, and `terminal.Configuration`
71+
* Add support for `addressKana`, `addressKanji`, `displayNameKana`, `displayNameKanji`, and `phone` on `terminal.LocationCreateParams`, `terminal.LocationUpdateParams`, and `terminal.Location`
72+
* Change `terminal.LocationCreateParams.address` to be optional
73+
* Change `terminal.LocationCreateParams.displayName` to be optional
74+
* Add support for new value `2025-09-30.clover` on enum `WebhookEndpointCreateParams.apiVersion`
75+
376
## 29.5.0 - 2025-08-27
477
* [#2034](https://github.com/stripe/stripe-java/pull/2034) Add section on private preview SDKs in readme
578
* [#2030](https://github.com/stripe/stripe-java/pull/2030) Update generated code. This release changes the pinned API version to `2025-08-27.basil`.

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Stripe Java client library
22

3-
[![Maven Central](https://img.shields.io/badge/maven--central-v29.5.0-blue)](https://mvnrepository.com/artifact/com.stripe/stripe-java)
3+
[![Maven Central](https://img.shields.io/badge/maven--central-v30.0.0-blue)](https://mvnrepository.com/artifact/com.stripe/stripe-java)
44
[![JavaDoc](http://img.shields.io/badge/javadoc-reference-blue.svg)](https://stripe.dev/stripe-java)
55
[![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)
66

@@ -23,7 +23,7 @@ We support LTS versions of the JDK. Currently, that's Java versions:
2323
Add this dependency to your project's build file:
2424

2525
```groovy
26-
implementation "com.stripe:stripe-java:29.5.0"
26+
implementation "com.stripe:stripe-java:30.0.0"
2727
```
2828

2929
### Maven users
@@ -34,7 +34,7 @@ Add this dependency to your project's POM:
3434
<dependency>
3535
<groupId>com.stripe</groupId>
3636
<artifactId>stripe-java</artifactId>
37-
<version>29.5.0</version>
37+
<version>30.0.0</version>
3838
</dependency>
3939
```
4040

@@ -43,8 +43,8 @@ Add this dependency to your project's POM:
4343
If you are not using Gradle or Maven, you will need to manually install the following JARs:
4444

4545
1. The Stripe JAR:
46-
- Download the latest release version from [Maven Central](https://repo1.maven.org/maven2/com/stripe/stripe-java/29.5.0/stripe-java-29.5.0.jar)
47-
- Current release version: 29.5.0
46+
- Download the latest release version from [Maven Central](https://repo1.maven.org/maven2/com/stripe/stripe-java/30.0.0/stripe-java-30.0.0.jar)
47+
- Current release version: 30.0.0
4848

4949
2. Google Gson:
5050
- The Stripe JAR builds and tests with Gson version 2.10.1

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
29.5.0
1+
30.0.0

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
GROUP=com.stripe
2-
VERSION_NAME=29.5.0
2+
VERSION_NAME=30.0.0
33

44
POM_URL=https://github.com/stripe/stripe-java
55
POM_SCM_URL=[email protected]:stripe/stripe-java.git

src/main/java/com/stripe/Stripe.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ public abstract class Stripe {
1414
public static final String LIVE_API_BASE = "https://api.stripe.com";
1515
public static final String UPLOAD_API_BASE = "https://files.stripe.com";
1616
public static final String METER_EVENTS_API_BASE = "https://meter-events.stripe.com";
17-
public static final String VERSION = "29.5.0";
17+
public static final String VERSION = "30.0.0";
1818

1919
public static volatile String apiKey;
2020
public static volatile String clientId;

0 commit comments

Comments
 (0)