Bump stripe-php from 16.4.0 to 17.2.1

This commit is contained in:
johnnyq
2025-05-22 12:37:35 -04:00
parent 5361391b3b
commit 6a368840fa
332 changed files with 4978 additions and 4624 deletions

View File

@@ -1,8 +1,137 @@
# Changelog
## 17.2.1 - 2025-05-19
* [#1869](https://github.com/stripe/stripe-php/pull/1869) Fixed type of map parameters(eg. metadata, currency_options) from `StripeObject` to `array<KType, VType>` in all methods.
* [#1866](https://github.com/stripe/stripe-php/pull/1866) Adds CONTRIBUTING.md
## 17.2.0 - 2025-04-30
This release changes the pinned API version to `2025-04-30.basil`.
* [#1839](https://github.com/stripe/stripe-php/pull/1839) Update generated code
* Add support for new value `tax_id_prohibited` on enums `Invoice.last_finalization_error.code`, `PaymentIntent.last_payment_error.code`, `SetupAttempt.setup_error.code`, `SetupIntent.last_setup_error.code`, and `StripeError.code`
* Add support for `wallet_options` on `Checkout.Session`
* Add support for `context` on `Event`
* Add support for new values `aw_tin`, `az_tin`, `bd_bin`, `bf_ifu`, `bj_ifu`, `cm_niu`, `cv_nif`, `et_tin`, `kg_tin`, and `la_tin` on enums `Invoice.customer_tax_ids[].type` and `TaxId.type`
* Add support for new value `affirm` on enums `Invoice.payment_settings.payment_method_types` and `Subscription.payment_settings.payment_method_types`
* Add support for `pix` on `PaymentMethodConfiguration`
* Add support for `klarna` on `PaymentMethodDomain`
* Add support for `us_cfpb_data` on `Person`
* Add support for `pending_reason` on `Refund`
* Change type of `Tax.CalculationLineItem.reference` from `nullable(string)` to `string`
* [#1857](https://github.com/stripe/stripe-php/pull/1857) Include new PHP 8.3 and 8.4 in CI
* [#1856](https://github.com/stripe/stripe-php/pull/1856) Faster parallel runner for PHP formatter
## 17.1.1 - 2025-04-04
* [#1847](https://github.com/stripe/stripe-php/pull/1847) Remove stdClass from object shapes
* Remove intersection with `stdClass` in resource properties and fixed `instanceof` checks.
## 17.1.0 - 2025-04-02
* [#1843](https://github.com/stripe/stripe-php/pull/1843) Add null type in resource fields to non required objects
* Fixes nullable resource properties that were incorrectly set as required in PHPDocs
## 17.0.0 - 2025-04-01
* [#1837](https://github.com/stripe/stripe-php/pull/1837) Better type hints in your editor!!
* Added type hints for method parameters
* <img width="417" alt="PHPStorm IDE with array type hints" src="https://github.com/user-attachments/assets/e914dcda-354f-4df2-b82e-217ad931e71d">
* Improved type hints for resource properties that are not primitive types. Take for example, the invoice settings in Customer resource. Previously, you could not reference inner fields like `custom_fields` on `customer->invoice_settings` without PHPStan complaining. This is now fixed.
* [#1818](https://github.com/stripe/stripe-php/pull/1818) Support for APIs in the new API version 2025-03-31.basil
This release changes the pinned API version to `2025-03-31.basil`.
### ⚠️ Breaking changes due to changes in the Stripe API
Please review details for the breaking changes and alternatives in the [Stripe API changelog](https://docs.stripe.com/changelog/acacia) before upgrading.
* Remove support for resources `UsageRecordSummary` and `UsageRecord`
* Remove support for `create` method on resource `UsageRecord`
* Remove support for `all` method on resource `UsageRecordSummary`
* Remove support for `upcomingLines` and `upcoming` methods on resource `Invoice`
* Remove support for `invoice` on `Charge` and `PaymentIntent`
* Remove support for `shipping_details` on `Checkout.Session`
* Remove support for `refund` on `CreditNote`
* Remove support for `tax_amounts` on `CreditNoteLineItem`, `CreditNote`, and `InvoiceLineItem`
* Remove support for `amount_excluding_tax` and `unit_amount_excluding_tax` on `CreditNoteLineItem` and `InvoiceLineItem`
* Remove support for `application_fee_amount`, `charge`, `paid_out_of_band`, `paid`, `payment_intent`, `quote`, `subscription`, `subscription_details`, `subscription_proration_date`, `tax`, `total_tax_amounts`, and `transfer_data` on `Invoice`
* Remove support for `discount` on `Invoice` and `Subscription`
* Remove support for `invoice_item`, `proration_details`, `proration`, `tax_rates`, and `type` on `InvoiceLineItem`
* Remove support for `plan`, `price`, and `subscription_item` on `InvoiceItem` and `InvoiceLineItem`
* Remove support for `subscription`, `unit_amount_decimal`, and `unit_amount` on `InvoiceItem`
* Remove support for `aggregate_usage` on `Plan`
* Remove support for `billing_thresholds` on `SubscriptionItem` and `Subscription`
* Remove support for `current_period_end` and `current_period_start` on `Subscription`
### ⚠️ Other Breaking changes in the SDK
* [#1826](https://github.com/stripe/stripe-php/pull/1826) configure max_nextwork_retries at the client level
* Allow setting `maxNetworkRetries` at the `StripeClient` level via a new argument to the `RequestOptions` constructor
* ⚠️ (potentially breaking) a client's configuration for `maxNetworkRetries` is set during client initialization. Subsequent calls to `Stripe::setMaxNetworkRetries()` after client creation **won't** affect that client.
* Allow setting `maxNetworkRetries` per-request via the `max_network_retries` config argument. This works for both the service and resource based patterns. In both cases, an explicitly passed value takes precedence over the global (or client) value.
* [#1835](https://github.com/stripe/stripe-php/pull/1835) Removed the protected method _searchResource as it is no longer used
* ⚠️ Removed `_searchResource` method and `Search` trait. Use the public `search` method on `Charge`, `Customer`, `Invoice`, `PaymentIntent`, `Price`, `Product`, and `Subscription` resource.
* [#1832](https://github.com/stripe/stripe-php/pull/1832) Added requestCollection and requestSearchResult to StripeClientInterface
* ⚠️ Added `requestSearchResult`, `requestCollection` to `StripeClientInterface`. Developers building custom StripeClient will now have to implement these new methods.
* Refer to our implementation in [BaseStripeClient](https://github.com/stripe/stripe-php/blob/f65c497d0bc175aaa04538602fd49645f44f9384/lib/BaseStripeClient.php#L259-L315) for guidance.
### Additions
* Add support for new resource `InvoicePayment`
* Add support for `all` and `retrieve` methods on resource `InvoicePayment`
* Add support for new values `forwarding_api_retryable_upstream_error` and `setup_intent_mobile_wallet_unsupported` on enums `Invoice.last_finalization_error.code`, `PaymentIntent.last_payment_error.code`, `SetupAttempt.setup_error.code`, `SetupIntent.last_setup_error.code`, and `StripeError.code`
* Add support for new values `stripe_balance_payment_debit_reversal` and `stripe_balance_payment_debit` on enum `BalanceTransaction.type`
* Add support for new value `last` on enum `Billing.Meter.default_aggregation.formula`
* Add support for `presentment_details` on `Charge`, `Checkout.Session`, `PaymentIntent`, and `Refund`
* Add support for `optional_items` on `Checkout.Session` and `PaymentLink`
* Add support for `permissions` on `Checkout.Session`
* Add support for new value `custom` on enum `Checkout.Session.ui_mode`
* Add support for new values `billie`, `nz_bank_account`, and `satispay` on enums `ConfirmationToken.payment_method_preview.type` and `PaymentMethod.type`
* Add support for `refunds` on `CreditNote`
* Add support for `total_taxes` on `CreditNote` and `Invoice`
* Add support for `taxes` on `CreditNoteLineItem` and `InvoiceLineItem`
* Add support for `checkout_session` on `CustomerBalanceTransaction`
* Add support for new values `checkout_session_subscription_payment_canceled` and `checkout_session_subscription_payment` on enum `CustomerBalanceTransaction.type`
* Add support for new value `invoice.overpaid` on enum `Event.type`
* Add support for `amount_overpaid`, `confirmation_secret`, and `payments` on `Invoice`
* Add support for `parent` on `InvoiceItem`, `InvoiceLineItem`, and `Invoice`
* Add support for new values `klarna` and `nz_bank_account` on enums `Invoice.payment_settings.payment_method_types` and `Subscription.payment_settings.payment_method_types`
* Add support for `pricing` on `InvoiceItem` and `InvoiceLineItem`
* Add support for new value `network_fallback` on enum `Issuing.Authorization.request_history[].reason`
* Add support for new value `expired` on enum `Issuing.Authorization.status`
* Add support for new value `expired` on enum `PaymentIntent.cancellation_reason`
* Add support for new values `billie` and `satispay` on enum `PaymentLink.payment_method_types`
* Add support for `billie`, `nz_bank_account`, and `satispay` on `PaymentMethodConfiguration` and `PaymentMethod`
* Add support for new value `canceled` on enum `Review.closed_reason`
* Add support for `current_period_end` and `current_period_start` on `SubscriptionItem`
* Add support for `wifi` on `Terminal.Configuration`
## 16.6.0 - 2025-02-24
* [#1809](https://github.com/stripe/stripe-php/pull/1809) Update generated code
* Add support for `priority` on `Billing.CreditGrant`
* Add support for `collected_information` on `Checkout.Session`
* [#1816](https://github.com/stripe/stripe-php/pull/1816) add codeowners file
## 16.5.1 - 2025-02-07
* [#1811](https://github.com/stripe/stripe-php/pull/1811) Include a useful error message when a null byte is found in the URL path
* [#1810](https://github.com/stripe/stripe-php/pull/1810) Make `httpClient()` a public, static method
## 16.5.0 - 2025-01-27
* [#1804](https://github.com/stripe/stripe-php/pull/1804) Update generated code
* Add support for `close` method on resource `Treasury.FinancialAccount`
* Add support for `discounts` on `Checkout.Session`
* Add support for new value `pay_by_bank` on enum `PaymentLink.payment_method_types[]`
* Add support for `pay_by_bank` on `PaymentMethodConfiguration` and `PaymentMethod`
* Add support for new value `pay_by_bank` on enum `PaymentMethod.type`
* Add support for `is_default` and `nickname` on `Treasury.FinancialAccount`
* [#1805](https://github.com/stripe/stripe-php/pull/1805) Restore testCoreEventsGet generated test
* [#1807](https://github.com/stripe/stripe-php/pull/1807) minor justfile fixes
* [#1806](https://github.com/stripe/stripe-php/pull/1806) Added CONTRIBUTING.md file
* [#1802](https://github.com/stripe/stripe-php/pull/1802) ensure dependencies are installed for format and test recipes
* [#1801](https://github.com/stripe/stripe-php/pull/1801) Add justfile, remove coveralls, and fix AUTOLOAD in CI
* [#1797](https://github.com/stripe/stripe-php/pull/1797) Added pull request template
## 16.4.0 - 2024-12-18
* [#1793](https://github.com/stripe/stripe-php/pull/1793) This release changes the pinned API version to `2024-12-18.acacia`.
* Add support for `network_advice_code` and `network_decline_code` on `StripeError`
* Add support for new values `payout_minimum_balance_hold` and `payout_minimum_balance_release` on enum `BalanceTransaction.type`
* Add support for `allow_redisplay` on `Card` and `Source`
* Add support for `regulated_status` on `Card`