Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for APIs in the new API version 2024-09-30.acacia #1880

Merged
merged 8 commits into from
Oct 1, 2024

Conversation

ramya-stripe
Copy link
Contributor

@ramya-stripe ramya-stripe commented Sep 27, 2024

Changelog

This release changes the pinned API version to 2024-09-30.acacia. Please read the API Upgrade Guide and carefully review the API changes before upgrading.

⚠️ Breaking changes due to changes in the API

  • Rename usage_threshold_config to usage_threshold on Billing.Alert and billing.AlertCreateParams
  • Remove support for filter on Billing.Alert and billing.AlertCreateParams. Use the filters on the usage_threshold instead
  • Remove support for customer_consent_collected on terminal.ReaderProcessSetupIntentParams

⚠️ Other Breaking changes in the SDK

  • Adjusted default values for HTTP requests. You can use the old defaults by setting them explicitly. New values are:
    • max retries: 0 -> 2
  • Add method parseThinEvent() on the StripeClient class to parse thin events. Rename constructEvent() method on the same class to parseSnapshotEvent() to clearly distinguish between the two kinds of events.
  • Breaking changes to public classes that are meant for internal use only and should not affect you
    • Renamed setStripeResponseGetter on ApiResource to `setGlobalResponseGetter
    • Added another parameter to FormEncoder.flattenParams()
    • Removed the deprecated constructor overload on APIRequest
    • Removed GlobalStripeResponseGetterOptions.getAPiKey & StripeResponseGetterOptions.getApiKey. We now use a higher abstraction called Authenticator instead of passing around api keys
    • Changed return type of RequestOptions.RequestOptionsBuilder.getConnectTimeout from int to java.lang.Integer.
    • Removed the public constructor on StripeRequest in favor of a static StripeRequest.create()
    • The unused field partnerId on class Stripe is removed

Additions

  • Add support for usage_threshold on Billing.Alert and billing.AlertCreateParams
  • Add support for custom_unit_amount on ProductCreateParams.default_price_data
  • Add support for allow_redisplay on terminal.ReaderProcessPaymentIntentParams.process_config and terminal.ReaderProcessSetupIntentParams
  • Add support for new value 2024-09-30.acacia on enum WebhookEndpointCreateParams.api_version
  • Add support for new Usage Billing APIs Billing.MeterEvent, Billing.MeterEventAdjustments, Billing.MeterEventSession, Billing.MeterEventStream and the new Events API Core.Events under the v2 namespace
  • Add methods rawRequest() on the StripeClient class that takes a HTTP method type, url and relevant parameters to make requests to the Stripe API that are not yet supported in the SDK.

Changes

  • Change billingportal.ConfigurationCreateParams.features.subscription_update.default_allowed_updates and billingportal.ConfigurationCreateParams.features.subscription_update.products to be optional

stripe-openapi bot and others added 2 commits September 26, 2024 11:35
* Update generated code for v1268

* Update generated code for v1268

---------

Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
}

/** Constructs a {@link StripeClient} with the specified configuration. */
/** Constructs a {@link StripeResponseGetterOptions} with the specified values. */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

randomly found this, but I think this comment needs to be fixed

@ramya-stripe ramya-stripe changed the title Support for APIs in the new API version 2024-09-30 Support for APIs in the new API version 2024-09-30.acacia Oct 1, 2024
* Fixed raw request deserialization for v1 and v2 Api endpoints

* Generated from codegen

* Added ApiMode import
@ramya-stripe ramya-stripe merged commit 81feaf1 into master Oct 1, 2024
21 of 22 checks passed
@ramya-stripe ramya-stripe deleted the sdk-release/next-major branch October 1, 2024 16:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants