Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions .hark/changes/2026-10-14_stripe-openapi_4faf44cc.change.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
---
title: Update generated code
pr_url: https://github.com/stripe/stripe-php/pull/2177
semver_level: major
is_stripe_api_change: true
---

* ⚠️ Remove support for `capture` method on resource `V2.Payments.OffSessionPayment`
* ⚠️ Remove support for `acknowledge_confirmation_of_payee` and `initiate_confirmation_of_payee` methods on resource `V2.Core.Vault.GbBankAccount`
* Add support for `wechat_pay_mobile_web_payments` on `Account.create().$params.setting`, `Account.settings`, and `Account.update().$params.setting`
* ⚠️ Remove support for `wechat_pay_payments` on `Account.create().$params.setting`, `Account.settings`, and `Account.update().$params.setting`
* Add support for `settlement_reserved` on `Balance`
* Change type of `BalanceSettings.payments.default_settlement_currency` from `nullable(string)` to `string`
* Add support for new value `settlement_reserved` on enum `BalanceTransaction.balance_type`
* Add support for `carecredit`, `getflex`, and `sezzle` on `Charge.payment_method_details`, `ConfirmationToken.create().$params.payment_method_datum`, `ConfirmationToken.payment_method_preview`, `PaymentAttemptRecord.payment_method_details`, `PaymentIntent.confirm().$params.payment_method_datum`, `PaymentIntent.confirm().$params.payment_method_option`, `PaymentIntent.create().$params.payment_method_datum`, `PaymentIntent.create().$params.payment_method_option`, `PaymentIntent.payment_method_options`, `PaymentIntent.update().$params.payment_method_datum`, `PaymentIntent.update().$params.payment_method_option`, `PaymentMethod.create().$params`, `PaymentMethod`, `PaymentRecord.payment_method_details`, `SetupIntent.confirm().$params.payment_method_datum`, `SetupIntent.create().$params.payment_method_datum`, and `SetupIntent.update().$params.payment_method_datum`
* Add support for `rakuten_pay` on `Charge.payment_method_details`, `ConfirmationToken.create().$params.payment_method_datum`, `ConfirmationToken.payment_method_preview`, `PaymentAttemptRecord.payment_method_details`, `PaymentIntent.confirm().$params.payment_method_datum`, `PaymentIntent.create().$params.payment_method_datum`, `PaymentIntent.update().$params.payment_method_datum`, `PaymentMethod.create().$params`, `PaymentMethod`, `PaymentRecord.payment_method_details`, `SetupIntent.confirm().$params.payment_method_datum`, `SetupIntent.create().$params.payment_method_datum`, and `SetupIntent.update().$params.payment_method_datum`
* Add support for `mandate_options` on `Checkout\Session.create().$params.payment_method_option.card`
* Add support for new value `auto` on enum `Checkout.Session.payment_method_collection`
* Change `Checkout.Session.items[].subscription.backdate_start_date` to be required
* Add support for new values `carecredit`, `getflex`, `rakuten_pay`, and `sezzle` on enums `ConfirmationToken.payment_method_preview.type` and `PaymentMethod.type`
* Add support for new values `three_d_secure.authentication.canceled`, `three_d_secure.authentication.challenge_started`, `three_d_secure.authentication.errored`, `three_d_secure.authentication.failed`, `three_d_secure.authentication.requires_challenge`, `three_d_secure.authentication.requires_submission`, and `three_d_secure.authentication.succeeded` on enum `Event.type`
* Add support for `fraudulent_document` on `Identity.VerificationReport.signals`
* Add support for new values `carecredit`, `getflex`, `rakuten_pay`, and `sezzle` on enums `PaymentIntent.allowed_payment_method_types` and `SetupIntent.allowed_payment_method_types`
* Add support for new values `carecredit`, `getflex`, `rakuten_pay`, and `sezzle` on enums `PaymentIntent.excluded_payment_method_types` and `SetupIntent.excluded_payment_method_types`
* Add support for `contact_email` on `V2.Core.AccountEvaluation.account_data`, `V2.Signals.AccountActivity.account_details.data`, `V2.Signals.AccountEvaluation.account_details.data`, `V2\Core\AccountEvaluation.create().$params.account_datum`, `V2\Signals\AccountActivity.create().$params.account_detail.datum`, and `V2\Signals\AccountEvaluation.create().$params.account_detail.datum`
* Add support for new value `user_merchant_fit` on enum `V2.Core.AccountEvaluation.evaluations_triggered`
* ⚠️ Change type of `V2.Core.Account.identity.individual.additional_addresses[].purpose` and `V2.Core.AccountPerson.additional_addresses[].purpose` from `literal('registered')` to `enum('birthplace'|'registered')`
* Add support for `bre_b`, `nip`, and `pix` on `V2.MoneyManagement.FinancialAddress.bank_account` and `V2.MoneyManagement.ReceivedCredit.bank_transfer.originating_bank_account`
* Add support for new value `ousd` on enum `V2.MoneyManagement.FinancialAddress.crypto_wallet.supported_network_details.value.supported_token_currencies`
* Add support for new values `bre_b`, `nip`, and `pix` on enum `V2.MoneyManagement.ReceivedCredit.bank_transfer.originating_bank_account.type`
* ⚠️ Remove support for `amount_capturable` on `V2.Payments.OffSessionPayment`
* ⚠️ Remove support for `capture` on `V2.Payments.OffSessionPayment` and `V2\Payments\OffSessionPayment.create().$params`
* Add support for `user_merchant_fit` on `V2.Signals.AccountEvaluation.evaluated_signals` and `V2.Signals.AccountSignal`
* Add support for new value `user_merchant_fit` on enum `V2.Signals.AccountEvaluation.pending_signals`
* Add support for new value `user_merchant_fit` on enum `V2.Signals.AccountEvaluation.requested_signals`
* Add support for new value `user_merchant_fit` on enum `V2.Signals.AccountSignal.type`
* Change type of `V2\Core\Account.create().$params.identity.individual.additional_address.purpose`, `V2\Core\Account.update().$params.identity.individual.additional_address.purpose`, `V2\Core\AccountPerson.create().$params.additional_address.purpose`, `V2\Core\AccountPerson.update().$params.additional_address.purpose`, `V2\Core\AccountPersonToken.create().$params.additional_address.purpose`, and `V2\Core\AccountToken.create().$params.identity.individual.additional_address.purpose` from `literal('registered')` to `enum('birthplace'|'registered')`
* Add support for snapshot events `THREE_D_SECURE_AUTHENTICATION_CANCELED`, `THREE_D_SECURE_AUTHENTICATION_CHALLENGE_STARTED`, `THREE_D_SECURE_AUTHENTICATION_ERRORED`, `THREE_D_SECURE_AUTHENTICATION_FAILED`, `THREE_D_SECURE_AUTHENTICATION_REQUIRES_CHALLENGE`, `THREE_D_SECURE_AUTHENTICATION_REQUIRES_SUBMISSION`, and `THREE_D_SECURE_AUTHENTICATION_SUCCEEDED` with resource `ThreeDSecure.Authentication`
* ⚠️ Remove support for event notification `V2PaymentsOffSessionPaymentRequiresCaptureEvent` with related object `V2.Payments.OffSessionPayment`
2 changes: 1 addition & 1 deletion CODEGEN_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
43649cb7390f9257ffa04232dc7ed9ea8359c77f
ee856c792d5b7bc7c9a55588bd92531c2774e744
2 changes: 1 addition & 1 deletion OPENAPI_VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v2544
v2562
2 changes: 0 additions & 2 deletions init.php
Original file line number Diff line number Diff line change
Expand Up @@ -1158,8 +1158,6 @@
require __DIR__ . '/lib/Events/V2PaymentsOffSessionPaymentFailedEventNotification.php';
require __DIR__ . '/lib/Events/V2PaymentsOffSessionPaymentPausedEvent.php';
require __DIR__ . '/lib/Events/V2PaymentsOffSessionPaymentPausedEventNotification.php';
require __DIR__ . '/lib/Events/V2PaymentsOffSessionPaymentRequiresCaptureEvent.php';
require __DIR__ . '/lib/Events/V2PaymentsOffSessionPaymentRequiresCaptureEventNotification.php';
require __DIR__ . '/lib/Events/V2PaymentsOffSessionPaymentResumedEvent.php';
require __DIR__ . '/lib/Events/V2PaymentsOffSessionPaymentResumedEventNotification.php';
require __DIR__ . '/lib/Events/V2PaymentsOffSessionPaymentSucceededEvent.php';
Expand Down
16 changes: 0 additions & 16 deletions lib/AbstractEventNotificationHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -6306,22 +6306,6 @@ public function onV2PaymentsOffSessionPaymentPaused($handler)
$this->register('v2.payments.off_session_payment.paused', $handler);
}

/**
* Registers a handler for the "v2.payments.off_session_payment.requires_capture" event.
*
* @param callable(Events\V2PaymentsOffSessionPaymentRequiresCaptureEventNotification, StripeClient): void $handler Handles v2.payments.off_session_payment.requires_capture events
*
* @throws Exception\InvalidArgumentException if this event type is already registered
* @throws Exception\BadMethodCallException if the `.handle()` method has already been called on this handler.
*/
public function onV2PaymentsOffSessionPaymentRequiresCapture($handler)
{
$this->register(
'v2.payments.off_session_payment.requires_capture',
$handler
);
}

/**
* Registers a handler for the "v2.payments.off_session_payment.resumed" event.
*
Expand Down
6 changes: 3 additions & 3 deletions lib/Account.php

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion lib/ApiRequestor.php
Original file line number Diff line number Diff line change
Expand Up @@ -958,7 +958,7 @@ private function _requestRaw($method, $url, $params, $headers, $apiMode, $usage,
* @param string[] $usage
* @param callable $readBodyChunkCallable
* @param 'v1'|'v2' $apiMode
* @param int $maxNetworkRetries
* @param null|int $maxNetworkRetries
*
* @return array
*
Expand All @@ -978,6 +978,7 @@ private function _requestRawStreaming($method, $url, $params, $headers, $apiMode
$params,
$hasFile,
$readBodyChunkCallable,
$apiMode,
$maxNetworkRetries
);

Expand Down
1 change: 1 addition & 0 deletions lib/Balance.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
* @property (object{amount: int, currency: string, source_types?: (object{bank_account?: int, card?: int, fpx?: int}&StripeObject)}&StripeObject)[] $pending Funds that aren't available in the balance yet. You can find the pending balance for each currency and each payment type in the <code>source_types</code> property.
* @property null|(object{available: (object{amount: int, currency: string, source_types?: (object{bank_account?: int, card?: int, fpx?: int}&StripeObject)}&StripeObject)[], pending: (object{amount: int, currency: string, source_types?: (object{bank_account?: int, card?: int, fpx?: int}&StripeObject)}&StripeObject)[]}&StripeObject) $refund_and_dispute_prefunding
* @property null|(object{available: (object{amount: int, currency: string, source_types?: (object{bank_account?: int, card?: int, fpx?: int}&StripeObject)}&StripeObject)[], pending: (object{amount: int, currency: string, source_types?: (object{bank_account?: int, card?: int, fpx?: int}&StripeObject)}&StripeObject)[]}&StripeObject) $risk_reserved
* @property null|(object{available: (object{amount: int, currency: string, source_types?: (object{bank_account?: int, card?: int, fpx?: int}&StripeObject)}&StripeObject)[], pending: (object{amount: int, currency: string, source_types?: (object{bank_account?: int, card?: int, fpx?: int}&StripeObject)}&StripeObject)[]}&StripeObject) $settlement_reserved
* @property null|(object{available: (object{amount: int, currency: string, source_types?: (object{bank_account?: int, card?: int, fpx?: int}&StripeObject)}&StripeObject)[], pending: (object{amount: int, currency: string, source_types?: (object{bank_account?: int, card?: int, fpx?: int}&StripeObject)}&StripeObject)[]}&StripeObject) $transit_balances_total
*/
class Balance extends SingletonApiResource
Expand Down
2 changes: 1 addition & 1 deletion lib/BalanceSettings.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
* Options for customizing account balances and payout settings for a Stripe platform’s connected accounts.
*
* @property string $object String representing the object's type. Objects of the same type share the same value.
* @property (object{debit_negative_balances: null|bool, default_settlement_currency?: null|string, payouts: null|(object{automatic_transfer_rules_by_currency: null|StripeObject, minimum_balance_by_currency: null|StripeObject, schedule: null|(object{interval: null|string, monthly_payout_days?: int[], weekly_payout_days?: string[]}&StripeObject), statement_descriptor: null|string, status: string}&StripeObject), settlement_currencies?: null|StripeObject, settlement_timing: (object{delay_days: int, delay_days_override?: int, start_of_day: null|(object{hour: int, minutes: int, timezone: string}&StripeObject)}&StripeObject)}&StripeObject) $payments
* @property (object{debit_negative_balances: null|bool, default_settlement_currency?: string, payouts: null|(object{automatic_transfer_rules_by_currency: null|StripeObject, minimum_balance_by_currency: null|StripeObject, schedule: null|(object{interval: null|string, monthly_payout_days?: int[], weekly_payout_days?: string[]}&StripeObject), statement_descriptor: null|string, status: string}&StripeObject), settlement_currencies?: null|StripeObject, settlement_timing: (object{delay_days: int, delay_days_override?: int, start_of_day: null|(object{hour: int, minutes: int, timezone: string}&StripeObject)}&StripeObject)}&StripeObject) $payments
*/
class BalanceSettings extends SingletonApiResource
{
Expand Down
1 change: 1 addition & 0 deletions lib/BalanceTransaction.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ class BalanceTransaction extends ApiResource
const BALANCE_TYPE_PAYMENTS = 'payments';
const BALANCE_TYPE_REFUND_AND_DISPUTE_PREFUNDING = 'refund_and_dispute_prefunding';
const BALANCE_TYPE_RISK_RESERVED = 'risk_reserved';
const BALANCE_TYPE_SETTLEMENT_RESERVED = 'settlement_reserved';
const BALANCE_TYPE_TRANSIT = 'transit';

const TYPE_ADJUSTMENT = 'adjustment';
Expand Down
2 changes: 1 addition & 1 deletion lib/BaseStripeClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -323,7 +323,7 @@ public function requestStream($method, $path, $readBodyChunkCallable, $params, $
$baseUrl = $opts->apiBase ?: $this->getApiBase();
$requestor = new ApiRequestor($this->apiKeyForRequest($opts), $baseUrl, $this->getAppInfo());
$apiMode = Util::getApiMode($path);
list($response, $opts->apiKey) = $requestor->requestStream($method, $path, $readBodyChunkCallable, $params, $opts->headers, $apiMode, ['stripe_client']);
list($response, $opts->apiKey) = $requestor->requestStream($method, $path, $readBodyChunkCallable, $params, $opts->headers, $apiMode, ['stripe_client'], $opts->maxNetworkRetries);
}

/**
Expand Down
2 changes: 1 addition & 1 deletion lib/Card.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
*
* @property string $id Unique identifier for the object.
* @property string $object String representing the object's type. Objects of the same type share the same value.
* @property null|Account|string $account
* @property null|Account|string $account The account this card belongs to. Only applicable on Accounts (not customers or recipients) This property is only available when returned as an <a href="/api/external_account_cards/object">External Account</a> where <a href="/api/accounts/object#account_object-controller-is_controller">controller.is_controller</a> is <code>true</code>.
* @property null|string $address_city City/District/Suburb/Town/Village.
* @property null|string $address_country Billing address country, if provided when creating card.
* @property null|string $address_line1 Address line 1 (Street address/PO Box/Company name).
Expand Down
Loading
Loading