diff --git a/CHANGELOG.md b/CHANGELOG.md
index b67792cb0..0389423cb 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,8 +1,24 @@
# Changelog
+## 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 `advice_code` on `StripeError`
+ * 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.5.0-beta.3 - 2025-01-23
* [#1803](https://github.com/stripe/stripe-php/pull/1803) Update generated code for beta
- * V2 Events now are subclass of `\Stripe\V2\Event`.
+ * V2 Events now are subclass of `\Stripe\V2\Event`.
## 16.5.0-beta.2 - 2025-01-09
* [#1796](https://github.com/stripe/stripe-php/pull/1796) Update generated code for beta
diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION
index 5454d94e1..130232bf3 100644
--- a/OPENAPI_VERSION
+++ b/OPENAPI_VERSION
@@ -1 +1 @@
-v1460
\ No newline at end of file
+v1472
\ No newline at end of file
diff --git a/lib/Account.php b/lib/Account.php
index 7b813a5fc..9e59214a5 100644
--- a/lib/Account.php
+++ b/lib/Account.php
@@ -38,7 +38,7 @@
* @property null|\Stripe\StripeObject $metadata Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
* @property null|bool $payouts_enabled Whether the funds in this account can be paid out.
* @property (object{alternatives: null|(object{alternative_fields_due: string[], original_fields_due: string[]}&\Stripe\StripeObject&\stdClass)[], current_deadline: null|int, currently_due: null|string[], disabled_reason: null|string, errors: null|(object{code: string, reason: string, requirement: string}&\Stripe\StripeObject&\stdClass)[], eventually_due: null|string[], past_due: null|string[], pending_verification: null|string[]}&\Stripe\StripeObject&\stdClass) $requirements
- * @property null|(object{charges: (object{pause_requested: bool}&\Stripe\StripeObject&\stdClass), payouts: (object{pause_requested: bool}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass) $risk_controls
+ * @property null|(object{charges: (object{pause_requested: bool}&\Stripe\StripeObject&\stdClass), payouts: (object{pause_requested: bool}&\Stripe\StripeObject&\stdClass), rejected_reason?: string}&\Stripe\StripeObject&\stdClass) $risk_controls
* @property null|(object{bacs_debit_payments?: (object{display_name: null|string, service_user_number: null|string}&\Stripe\StripeObject&\stdClass), bank_bca_onboarding?: (object{account_holder_name?: string, business_account_number?: string}&\Stripe\StripeObject&\stdClass), branding: (object{icon: null|string|\Stripe\File, logo: null|string|\Stripe\File, primary_color: null|string, secondary_color: null|string}&\Stripe\StripeObject&\stdClass), capital?: (object{payout_destination?: \Stripe\StripeObject, payout_destination_selector?: \Stripe\StripeObject}&\Stripe\StripeObject&\stdClass), card_issuing?: (object{tos_acceptance?: (object{date: null|int, ip: null|string, user_agent?: string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), card_payments: (object{decline_on?: (object{avs_failure: bool, cvc_failure: bool}&\Stripe\StripeObject&\stdClass), statement_descriptor_prefix: null|string, statement_descriptor_prefix_kana: null|string, statement_descriptor_prefix_kanji: null|string}&\Stripe\StripeObject&\stdClass), dashboard: (object{display_name: null|string, timezone: null|string}&\Stripe\StripeObject&\stdClass), invoices?: (object{default_account_tax_ids: null|(string|\Stripe\TaxId)[]}&\Stripe\StripeObject&\stdClass), payments: (object{statement_descriptor: null|string, statement_descriptor_kana: null|string, statement_descriptor_kanji: null|string, statement_descriptor_prefix_kana: null|string, statement_descriptor_prefix_kanji: null|string}&\Stripe\StripeObject&\stdClass), payouts?: (object{debit_negative_balances: bool, schedule: (object{delay_days: int, interval: string, monthly_anchor?: int, weekly_anchor?: string}&\Stripe\StripeObject&\stdClass), statement_descriptor: null|string}&\Stripe\StripeObject&\stdClass), sepa_debit_payments?: (object{creditor_id?: string}&\Stripe\StripeObject&\stdClass), tax_forms?: (object{consented_to_paperless_delivery: bool}&\Stripe\StripeObject&\stdClass), treasury?: (object{tos_acceptance?: (object{date: null|int, ip: null|string, user_agent?: string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass) $settings Options for customizing how the account functions within Stripe.
* @property (object{date?: null|int, ip?: null|string, service_agreement?: string, user_agent?: null|string}&\Stripe\StripeObject&\stdClass) $tos_acceptance
* @property null|string $type The Stripe account type. Can be standard
, express
, custom
, or none
.
diff --git a/lib/AccountSession.php b/lib/AccountSession.php
index 731d25e98..9a71d0b7d 100644
--- a/lib/AccountSession.php
+++ b/lib/AccountSession.php
@@ -28,7 +28,7 @@ class AccountSession extends ApiResource
* Creates a AccountSession object that includes a single-use token that the
* platform can use on their front-end to grant client-side API access.
*
- * @param null|array{account: string, components: array{account_management?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, external_account_collection?: bool}}, account_onboarding?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, external_account_collection?: bool}}, app_install?: array{enabled: bool, features?: array{allowed_apps?: null|string[]}}, app_viewport?: array{enabled: bool, features?: array{allowed_apps?: null|string[]}}, balances?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, edit_payout_schedule?: bool, external_account_collection?: bool, instant_payouts?: bool, standard_payouts?: bool}}, capital_financing?: array{enabled: bool, features?: array{}}, capital_financing_application?: array{enabled: bool, features?: array{}}, capital_financing_promotion?: array{enabled: bool, features?: array{}}, capital_overview?: array{enabled: bool, features?: array{}}, documents?: array{enabled: bool, features?: array{}}, financial_account?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, external_account_collection?: bool, send_money?: bool, transfer_balance?: bool}}, financial_account_transactions?: array{enabled: bool, features?: array{card_spend_dispute_management?: bool}}, issuing_card?: array{enabled: bool, features?: array{card_management?: bool, card_spend_dispute_management?: bool, cardholder_management?: bool, spend_control_management?: bool}}, issuing_cards_list?: array{enabled: bool, features?: array{card_management?: bool, card_spend_dispute_management?: bool, cardholder_management?: bool, disable_stripe_user_authentication?: bool, spend_control_management?: bool}}, notification_banner?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, external_account_collection?: bool}}, payment_details?: array{enabled: bool, features?: array{capture_payments?: bool, destination_on_behalf_of_charge_management?: bool, dispute_management?: bool, refund_management?: bool}}, payment_method_settings?: array{enabled: bool, features?: array{}}, payments?: array{enabled: bool, features?: array{capture_payments?: bool, destination_on_behalf_of_charge_management?: bool, dispute_management?: bool, refund_management?: bool}}, payouts?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, edit_payout_schedule?: bool, external_account_collection?: bool, instant_payouts?: bool, standard_payouts?: bool}}, payouts_list?: array{enabled: bool, features?: array{}}, recipients?: array{enabled: bool, features?: array{send_money?: bool}}, reporting_chart?: array{enabled: bool, features?: array{}}, tax_registrations?: array{enabled: bool, features?: array{}}, tax_settings?: array{enabled: bool, features?: array{}}, tax_threshold_monitoring?: array{enabled: bool, features?: array{}}}, expand?: string[]} $params
+ * @param null|array{account: string, components: array{account_management?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, external_account_collection?: bool}}, account_onboarding?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, external_account_collection?: bool}}, app_install?: array{enabled: bool, features?: array{allowed_apps?: null|string[]}}, app_viewport?: array{enabled: bool, features?: array{allowed_apps?: null|string[]}}, balances?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, edit_payout_schedule?: bool, external_account_collection?: bool, instant_payouts?: bool, standard_payouts?: bool}}, capital_financing?: array{enabled: bool, features?: array{}}, capital_financing_application?: array{enabled: bool, features?: array{}}, capital_financing_promotion?: array{enabled: bool, features?: array{}}, capital_overview?: array{enabled: bool, features?: array{}}, documents?: array{enabled: bool, features?: array{}}, financial_account?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, external_account_collection?: bool, send_money?: bool, transfer_balance?: bool}}, financial_account_transactions?: array{enabled: bool, features?: array{card_spend_dispute_management?: bool}}, issuing_card?: array{enabled: bool, features?: array{card_management?: bool, card_spend_dispute_management?: bool, cardholder_management?: bool, spend_control_management?: bool}}, issuing_cards_list?: array{enabled: bool, features?: array{card_management?: bool, card_spend_dispute_management?: bool, cardholder_management?: bool, disable_stripe_user_authentication?: bool, spend_control_management?: bool}}, notification_banner?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, external_account_collection?: bool}}, payment_details?: array{enabled: bool, features?: array{capture_payments?: bool, destination_on_behalf_of_charge_management?: bool, dispute_management?: bool, refund_management?: bool}}, payment_method_settings?: array{enabled: bool, features?: array{}}, payments?: array{enabled: bool, features?: array{capture_payments?: bool, destination_on_behalf_of_charge_management?: bool, dispute_management?: bool, refund_management?: bool}}, payouts?: array{enabled: bool, features?: array{disable_stripe_user_authentication?: bool, edit_payout_schedule?: bool, external_account_collection?: bool, instant_payouts?: bool, standard_payouts?: bool}}, payouts_list?: array{enabled: bool, features?: array{}}, product_tax_code_selector?: array{enabled: bool, features?: array{}}, recipients?: array{enabled: bool, features?: array{send_money?: bool}}, reporting_chart?: array{enabled: bool, features?: array{}}, tax_registrations?: array{enabled: bool, features?: array{}}, tax_settings?: array{enabled: bool, features?: array{}}, tax_threshold_monitoring?: array{enabled: bool, features?: array{}}}, expand?: string[]} $params
* @param null|array|string $options
*
* @throws \Stripe\Exception\ApiErrorException if the request fails
diff --git a/lib/ApiRequestor.php b/lib/ApiRequestor.php
index f2bbde6ef..52edc4fbe 100644
--- a/lib/ApiRequestor.php
+++ b/lib/ApiRequestor.php
@@ -436,8 +436,8 @@ private function _prepareRequest($method, $url, $params, $headers, $apiMode)
// X-Stripe-Client-User-Agent header via the optional getUserAgentInfo()
// method
$clientUAInfo = null;
- if (\method_exists($this->httpClient(), 'getUserAgentInfo')) {
- $clientUAInfo = $this->httpClient()->getUserAgentInfo();
+ if (\method_exists(self::httpClient(), 'getUserAgentInfo')) {
+ $clientUAInfo = self::httpClient()->getUserAgentInfo();
}
if ($params && \is_array($params)) {
@@ -516,9 +516,15 @@ private function _requestRaw($method, $url, $params, $headers, $apiMode, $usage)
{
list($absUrl, $rawHeaders, $params, $hasFile, $myApiKey) = $this->_prepareRequest($method, $url, $params, $headers, $apiMode);
+ // for some reason, PHP users will sometimes include null bytes in their paths, which leads to cryptic server 400s.
+ // we'll be louder about this to help catch issues earlier.
+ if (false !== \strpos($absUrl, "\0") || false !== \strpos($absUrl, '%00')) {
+ throw new Exception\InvalidRequestException("URLs may not contain null bytes ('\\0'); double check any IDs you're including with the request.");
+ }
+
$requestStartMs = Util\Util::currentTimeMillis();
- list($rbody, $rcode, $rheaders) = $this->httpClient()->request(
+ list($rbody, $rcode, $rheaders) = self::httpClient()->request(
$method,
$absUrl,
$rawHeaders,
@@ -562,7 +568,7 @@ private function _requestRawStreaming($method, $url, $params, $headers, $apiMode
$requestStartMs = Util\Util::currentTimeMillis();
- list($rbody, $rcode, $rheaders) = $this->streamingHttpClient()->requestStream(
+ list($rbody, $rcode, $rheaders) = self::streamingHttpClient()->requestStream(
$method,
$absUrl,
$rawHeaders,
@@ -673,7 +679,7 @@ public static function resetTelemetry()
/**
* @return HttpClient\ClientInterface
*/
- private function httpClient()
+ public static function httpClient()
{
if (!self::$_httpClient) {
self::$_httpClient = HttpClient\CurlClient::instance();
@@ -685,7 +691,7 @@ private function httpClient()
/**
* @return HttpClient\StreamingClientInterface
*/
- private function streamingHttpClient()
+ public static function streamingHttpClient()
{
if (!self::$_streamingHttpClient) {
self::$_streamingHttpClient = HttpClient\CurlClient::instance();
diff --git a/lib/Billing/CreditGrant.php b/lib/Billing/CreditGrant.php
index 2f4c2b67c..2814d2439 100644
--- a/lib/Billing/CreditGrant.php
+++ b/lib/Billing/CreditGrant.php
@@ -12,7 +12,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 (object{monetary: null|(object{currency: string, value: int}&\Stripe\StripeObject&\stdClass), type: string}&\Stripe\StripeObject&\stdClass) $amount
- * @property (object{scope: (object{price_type: string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass) $applicability_config
+ * @property (object{scope: (object{price_type?: string, prices?: ((object{id: null|string}&\Stripe\StripeObject&\stdClass))[]}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass) $applicability_config
* @property string $category The category of this credit grant. This is for tracking purposes and isn't displayed to the customer.
* @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
* @property string|\Stripe\Customer $customer ID of the customer receiving the billing credits.
@@ -37,7 +37,7 @@ class CreditGrant extends \Stripe\ApiResource
/**
* Creates a credit grant.
*
- * @param null|array{amount: array{monetary?: array{currency: string, value: int}, type: string}, applicability_config: array{scope: array{price_type: string}}, category: string, customer: string, effective_at?: int, expand?: string[], expires_at?: int, metadata?: \Stripe\StripeObject, name?: string} $params
+ * @param null|array{amount: array{monetary?: array{currency: string, value: int}, type: string}, applicability_config: array{scope: array{price_type: string, prices?: array{id: string}[]}}, category: string, customer: string, effective_at?: int, expand?: string[], expires_at?: int, metadata?: \Stripe\StripeObject, name?: string} $params
* @param null|array|string $options
*
* @throws \Stripe\Exception\ApiErrorException if the request fails
diff --git a/lib/Billing/MeterEventSummary.php b/lib/Billing/MeterEventSummary.php
index e56ada7fd..008525a66 100644
--- a/lib/Billing/MeterEventSummary.php
+++ b/lib/Billing/MeterEventSummary.php
@@ -8,6 +8,8 @@
* A billing meter event summary represents an aggregated view of a customer's billing meter events within a specified timeframe. It indicates how much
* usage was accrued by a customer for that period.
*
+ * Note: Meters events are aggregated asynchronously so the meter event summaries provide an eventually consistent view of the reported usage.
+ *
* @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 float $aggregated_value Aggregated value of all the events within start_time
(inclusive) and end_time
(inclusive). The aggregation strategy is defined on meter via default_aggregation
.
diff --git a/lib/Charge.php b/lib/Charge.php
index 1a867cfc7..bd0437208 100644
--- a/lib/Charge.php
+++ b/lib/Charge.php
@@ -41,7 +41,7 @@
* @property bool $paid true
if the charge succeeded, or was successfully authorized for later capture.
* @property null|string|\Stripe\PaymentIntent $payment_intent ID of the PaymentIntent associated with this charge, if one exists.
* @property null|string $payment_method ID of the payment method used in this charge.
- * @property null|(object{ach_credit_transfer?: (object{account_number: null|string, bank_name: null|string, routing_number: null|string, swift_code: null|string}&\Stripe\StripeObject&\stdClass), ach_debit?: (object{account_holder_type: null|string, bank_name: null|string, country: null|string, fingerprint: null|string, last4: null|string, routing_number: null|string}&\Stripe\StripeObject&\stdClass), acss_debit?: (object{bank_name: null|string, fingerprint: null|string, institution_number: null|string, last4: null|string, mandate?: string, transit_number: null|string}&\Stripe\StripeObject&\stdClass), affirm?: (object{transaction_id: null|string}&\Stripe\StripeObject&\stdClass), afterpay_clearpay?: (object{order_id: null|string, reference: null|string}&\Stripe\StripeObject&\stdClass), alipay?: (object{buyer_id?: string, fingerprint: null|string, transaction_id: null|string}&\Stripe\StripeObject&\stdClass), alma?: (object{}&\Stripe\StripeObject&\stdClass), amazon_pay?: (object{funding?: (object{card?: (object{brand: null|string, country: null|string, exp_month: null|int, exp_year: null|int, funding: null|string, last4: null|string}&\Stripe\StripeObject&\stdClass), type: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), au_becs_debit?: (object{bsb_number: null|string, fingerprint: null|string, last4: null|string, mandate?: string}&\Stripe\StripeObject&\stdClass), bacs_debit?: (object{fingerprint: null|string, last4: null|string, mandate: null|string, sort_code: null|string}&\Stripe\StripeObject&\stdClass), bancontact?: (object{bank_code: null|string, bank_name: null|string, bic: null|string, generated_sepa_debit: null|string|\Stripe\PaymentMethod, generated_sepa_debit_mandate: null|string|\Stripe\Mandate, iban_last4: null|string, preferred_language: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), blik?: (object{buyer_id: null|string}&\Stripe\StripeObject&\stdClass), boleto?: (object{tax_id: string}&\Stripe\StripeObject&\stdClass), card?: (object{amount_authorized: null|int, amount_requested?: null|int, authorization_code: null|string, brand: null|string, capture_before?: int, checks: null|(object{address_line1_check: null|string, address_postal_code_check: null|string, cvc_check: null|string}&\Stripe\StripeObject&\stdClass), country: null|string, decremental_authorization?: (object{status: string}&\Stripe\StripeObject&\stdClass), description?: null|string, exp_month: int, exp_year: int, extended_authorization?: (object{status: string}&\Stripe\StripeObject&\stdClass), fingerprint?: null|string, funding: null|string, iin?: null|string, incremental_authorization?: (object{status: string}&\Stripe\StripeObject&\stdClass), installments: null|(object{plan: null|(object{count: null|int, interval: null|string, type: string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), issuer?: null|string, last4: null|string, mandate: null|string, moto?: null|bool, multicapture?: (object{status: string}&\Stripe\StripeObject&\stdClass), network: null|string, network_token?: null|(object{used: bool}&\Stripe\StripeObject&\stdClass), network_transaction_id: null|string, overcapture?: (object{maximum_amount_capturable: int, status: string}&\Stripe\StripeObject&\stdClass), partial_authorization?: (object{status: string}&\Stripe\StripeObject&\stdClass), regulated_status: null|string, three_d_secure: null|(object{authentication_flow: null|string, electronic_commerce_indicator: null|string, exemption_indicator: null|string, exemption_indicator_applied?: bool, result: null|string, result_reason: null|string, transaction_id: null|string, version: null|string}&\Stripe\StripeObject&\stdClass), wallet: null|(object{amex_express_checkout?: (object{}&\Stripe\StripeObject&\stdClass), apple_pay?: (object{}&\Stripe\StripeObject&\stdClass), dynamic_last4: null|string, google_pay?: (object{}&\Stripe\StripeObject&\stdClass), link?: (object{}&\Stripe\StripeObject&\stdClass), masterpass?: (object{billing_address: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass), email: null|string, name: null|string, shipping_address: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), samsung_pay?: (object{}&\Stripe\StripeObject&\stdClass), type: string, visa_checkout?: (object{billing_address: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass), email: null|string, name: null|string, shipping_address: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), card_present?: (object{amount_authorized: null|int, brand: null|string, brand_product: null|string, capture_before?: int, cardholder_name: null|string, country: null|string, description?: null|string, emv_auth_data: null|string, exp_month: int, exp_year: int, fingerprint: null|string, funding: null|string, generated_card: null|string, iin?: null|string, incremental_authorization_supported: bool, issuer?: null|string, last4: null|string, network: null|string, network_transaction_id: null|string, offline: null|(object{stored_at: null|int, type: null|string}&\Stripe\StripeObject&\stdClass), overcapture_supported: bool, preferred_locales: null|string[], read_method: null|string, receipt: null|(object{account_type?: string, application_cryptogram: null|string, application_preferred_name: null|string, authorization_code: null|string, authorization_response_code: null|string, cardholder_verification_method: null|string, dedicated_file_name: null|string, terminal_verification_results: null|string, transaction_status_information: null|string}&\Stripe\StripeObject&\stdClass), wallet?: (object{type: string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), cashapp?: (object{buyer_id: null|string, cashtag: null|string}&\Stripe\StripeObject&\stdClass), customer_balance?: (object{}&\Stripe\StripeObject&\stdClass), eps?: (object{bank: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), fpx?: (object{account_holder_type: null|string, bank: string, transaction_id: null|string}&\Stripe\StripeObject&\stdClass), giropay?: (object{bank_code: null|string, bank_name: null|string, bic: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), gopay?: (object{}&\Stripe\StripeObject&\stdClass), grabpay?: (object{transaction_id: null|string}&\Stripe\StripeObject&\stdClass), id_bank_transfer?: (object{account_number: string, bank: string, bank_code?: string, bank_name?: string, display_name?: string}&\Stripe\StripeObject&\stdClass), ideal?: (object{bank: null|string, bic: null|string, generated_sepa_debit: null|string|\Stripe\PaymentMethod, generated_sepa_debit_mandate: null|string|\Stripe\Mandate, iban_last4: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), interac_present?: (object{brand: null|string, cardholder_name: null|string, country: null|string, description?: null|string, emv_auth_data: null|string, exp_month: int, exp_year: int, fingerprint: null|string, funding: null|string, generated_card: null|string, iin?: null|string, issuer?: null|string, last4: null|string, network: null|string, network_transaction_id: null|string, preferred_locales: null|string[], read_method: null|string, receipt: null|(object{account_type?: string, application_cryptogram: null|string, application_preferred_name: null|string, authorization_code: null|string, authorization_response_code: null|string, cardholder_verification_method: null|string, dedicated_file_name: null|string, terminal_verification_results: null|string, transaction_status_information: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), kakao_pay?: (object{buyer_id: null|string}&\Stripe\StripeObject&\stdClass), klarna?: (object{payer_details: null|(object{address: null|(object{country: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), payment_method_category: null|string, preferred_locale: null|string}&\Stripe\StripeObject&\stdClass), konbini?: (object{store: null|(object{chain: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), kr_card?: (object{brand: null|string, buyer_id: null|string, last4: null|string}&\Stripe\StripeObject&\stdClass), link?: (object{country: null|string}&\Stripe\StripeObject&\stdClass), mb_way?: (object{}&\Stripe\StripeObject&\stdClass), mobilepay?: (object{card: null|(object{brand: null|string, country: null|string, exp_month: null|int, exp_year: null|int, last4: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), multibanco?: (object{entity: null|string, reference: null|string}&\Stripe\StripeObject&\stdClass), naver_pay?: (object{buyer_id: null|string}&\Stripe\StripeObject&\stdClass), oxxo?: (object{number: null|string}&\Stripe\StripeObject&\stdClass), p24?: (object{bank: null|string, reference: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), pay_by_bank?: (object{}&\Stripe\StripeObject&\stdClass), payco?: (object{buyer_id: null|string}&\Stripe\StripeObject&\stdClass), paynow?: (object{reference: null|string}&\Stripe\StripeObject&\stdClass), paypal?: (object{country: null|string, payer_email: null|string, payer_id: null|string, payer_name: null|string, seller_protection: null|(object{dispute_categories: null|string[], status: string}&\Stripe\StripeObject&\stdClass), shipping?: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass), transaction_id: null|string, verified_address?: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass), verified_email?: null|string, verified_name?: null|string}&\Stripe\StripeObject&\stdClass), payto?: (object{bsb_number: null|string, last4: null|string, mandate?: string, pay_id: null|string}&\Stripe\StripeObject&\stdClass), pix?: (object{bank_transaction_id?: null|string}&\Stripe\StripeObject&\stdClass), promptpay?: (object{reference: null|string}&\Stripe\StripeObject&\stdClass), qris?: (object{}&\Stripe\StripeObject&\stdClass), rechnung?: (object{}&\Stripe\StripeObject&\stdClass), revolut_pay?: (object{funding?: (object{card?: (object{brand: null|string, country: null|string, exp_month: null|int, exp_year: null|int, funding: null|string, last4: null|string}&\Stripe\StripeObject&\stdClass), type: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), samsung_pay?: (object{buyer_id: null|string}&\Stripe\StripeObject&\stdClass), sepa_credit_transfer?: (object{bank_name: null|string, bic: null|string, iban: null|string}&\Stripe\StripeObject&\stdClass), sepa_debit?: (object{bank_code: null|string, branch_code: null|string, country: null|string, fingerprint: null|string, last4: null|string, mandate: null|string}&\Stripe\StripeObject&\stdClass), shopeepay?: (object{}&\Stripe\StripeObject&\stdClass), sofort?: (object{bank_code: null|string, bank_name: null|string, bic: null|string, country: null|string, generated_sepa_debit: null|string|\Stripe\PaymentMethod, generated_sepa_debit_mandate: null|string|\Stripe\Mandate, iban_last4: null|string, preferred_language: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), stripe_account?: (object{}&\Stripe\StripeObject&\stdClass), swish?: (object{fingerprint: null|string, payment_reference: null|string, verified_phone_last4: null|string}&\Stripe\StripeObject&\stdClass), twint?: (object{}&\Stripe\StripeObject&\stdClass), type: string, us_bank_account?: (object{account_holder_type: null|string, account_type: null|string, bank_name: null|string, fingerprint: null|string, last4: null|string, mandate?: string|\Stripe\Mandate, payment_reference: null|string, routing_number: null|string}&\Stripe\StripeObject&\stdClass), wechat?: (object{}&\Stripe\StripeObject&\stdClass), wechat_pay?: (object{fingerprint: null|string, transaction_id: null|string}&\Stripe\StripeObject&\stdClass), zip?: (object{}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass) $payment_method_details Details about the payment method at the time of the transaction.
+ * @property null|(object{ach_credit_transfer?: (object{account_number: null|string, bank_name: null|string, routing_number: null|string, swift_code: null|string}&\Stripe\StripeObject&\stdClass), ach_debit?: (object{account_holder_type: null|string, bank_name: null|string, country: null|string, fingerprint: null|string, last4: null|string, routing_number: null|string}&\Stripe\StripeObject&\stdClass), acss_debit?: (object{bank_name: null|string, fingerprint: null|string, institution_number: null|string, last4: null|string, mandate?: string, transit_number: null|string}&\Stripe\StripeObject&\stdClass), affirm?: (object{transaction_id: null|string}&\Stripe\StripeObject&\stdClass), afterpay_clearpay?: (object{order_id: null|string, reference: null|string}&\Stripe\StripeObject&\stdClass), alipay?: (object{buyer_id?: string, fingerprint: null|string, transaction_id: null|string}&\Stripe\StripeObject&\stdClass), alma?: (object{}&\Stripe\StripeObject&\stdClass), amazon_pay?: (object{funding?: (object{card?: (object{brand: null|string, brand_product?: null|string, country: null|string, exp_month: null|int, exp_year: null|int, funding: null|string, last4: null|string}&\Stripe\StripeObject&\stdClass), type: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), au_becs_debit?: (object{bsb_number: null|string, fingerprint: null|string, last4: null|string, mandate?: string}&\Stripe\StripeObject&\stdClass), bacs_debit?: (object{fingerprint: null|string, last4: null|string, mandate: null|string, sort_code: null|string}&\Stripe\StripeObject&\stdClass), bancontact?: (object{bank_code: null|string, bank_name: null|string, bic: null|string, generated_sepa_debit: null|string|\Stripe\PaymentMethod, generated_sepa_debit_mandate: null|string|\Stripe\Mandate, iban_last4: null|string, preferred_language: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), blik?: (object{buyer_id: null|string}&\Stripe\StripeObject&\stdClass), boleto?: (object{tax_id: string}&\Stripe\StripeObject&\stdClass), card?: (object{amount_authorized: null|int, amount_requested?: null|int, authorization_code: null|string, brand: null|string, capture_before?: int, checks: null|(object{address_line1_check: null|string, address_postal_code_check: null|string, cvc_check: null|string}&\Stripe\StripeObject&\stdClass), country: null|string, decremental_authorization?: (object{status: string}&\Stripe\StripeObject&\stdClass), description?: null|string, exp_month: int, exp_year: int, extended_authorization?: (object{status: string}&\Stripe\StripeObject&\stdClass), fingerprint?: null|string, funding: null|string, iin?: null|string, incremental_authorization?: (object{status: string}&\Stripe\StripeObject&\stdClass), installments: null|(object{plan: null|(object{count: null|int, interval: null|string, type: string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), issuer?: null|string, last4: null|string, mandate: null|string, moto?: null|bool, multicapture?: (object{status: string}&\Stripe\StripeObject&\stdClass), network: null|string, network_token?: null|(object{used: bool}&\Stripe\StripeObject&\stdClass), network_transaction_id: null|string, overcapture?: (object{maximum_amount_capturable: int, status: string}&\Stripe\StripeObject&\stdClass), partial_authorization?: (object{status: string}&\Stripe\StripeObject&\stdClass), regulated_status: null|string, three_d_secure: null|(object{authentication_flow: null|string, electronic_commerce_indicator: null|string, exemption_indicator: null|string, exemption_indicator_applied?: bool, result: null|string, result_reason: null|string, transaction_id: null|string, version: null|string}&\Stripe\StripeObject&\stdClass), wallet: null|(object{amex_express_checkout?: (object{}&\Stripe\StripeObject&\stdClass), apple_pay?: (object{}&\Stripe\StripeObject&\stdClass), dynamic_last4: null|string, google_pay?: (object{}&\Stripe\StripeObject&\stdClass), link?: (object{}&\Stripe\StripeObject&\stdClass), masterpass?: (object{billing_address: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass), email: null|string, name: null|string, shipping_address: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), samsung_pay?: (object{}&\Stripe\StripeObject&\stdClass), type: string, visa_checkout?: (object{billing_address: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass), email: null|string, name: null|string, shipping_address: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), card_present?: (object{amount_authorized: null|int, brand: null|string, brand_product: null|string, capture_before?: int, cardholder_name: null|string, country: null|string, description?: null|string, emv_auth_data: null|string, exp_month: int, exp_year: int, fingerprint: null|string, funding: null|string, generated_card: null|string, iin?: null|string, incremental_authorization_supported: bool, issuer?: null|string, last4: null|string, network: null|string, network_transaction_id: null|string, offline: null|(object{stored_at: null|int, type: null|string}&\Stripe\StripeObject&\stdClass), overcapture_supported: bool, preferred_locales: null|string[], read_method: null|string, receipt: null|(object{account_type?: string, application_cryptogram: null|string, application_preferred_name: null|string, authorization_code: null|string, authorization_response_code: null|string, cardholder_verification_method: null|string, dedicated_file_name: null|string, terminal_verification_results: null|string, transaction_status_information: null|string}&\Stripe\StripeObject&\stdClass), wallet?: (object{type: string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), cashapp?: (object{buyer_id: null|string, cashtag: null|string}&\Stripe\StripeObject&\stdClass), customer_balance?: (object{}&\Stripe\StripeObject&\stdClass), eps?: (object{bank: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), fpx?: (object{account_holder_type: null|string, bank: string, transaction_id: null|string}&\Stripe\StripeObject&\stdClass), giropay?: (object{bank_code: null|string, bank_name: null|string, bic: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), gopay?: (object{}&\Stripe\StripeObject&\stdClass), grabpay?: (object{transaction_id: null|string}&\Stripe\StripeObject&\stdClass), id_bank_transfer?: (object{account_number: string, bank: string, bank_code?: string, bank_name?: string, display_name?: string}&\Stripe\StripeObject&\stdClass), ideal?: (object{bank: null|string, bic: null|string, generated_sepa_debit: null|string|\Stripe\PaymentMethod, generated_sepa_debit_mandate: null|string|\Stripe\Mandate, iban_last4: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), interac_present?: (object{brand: null|string, cardholder_name: null|string, country: null|string, description?: null|string, emv_auth_data: null|string, exp_month: int, exp_year: int, fingerprint: null|string, funding: null|string, generated_card: null|string, iin?: null|string, issuer?: null|string, last4: null|string, network: null|string, network_transaction_id: null|string, preferred_locales: null|string[], read_method: null|string, receipt: null|(object{account_type?: string, application_cryptogram: null|string, application_preferred_name: null|string, authorization_code: null|string, authorization_response_code: null|string, cardholder_verification_method: null|string, dedicated_file_name: null|string, terminal_verification_results: null|string, transaction_status_information: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), kakao_pay?: (object{buyer_id: null|string}&\Stripe\StripeObject&\stdClass), klarna?: (object{payer_details: null|(object{address: null|(object{country: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), payment_method_category: null|string, preferred_locale: null|string}&\Stripe\StripeObject&\stdClass), konbini?: (object{store: null|(object{chain: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), kr_card?: (object{brand: null|string, buyer_id: null|string, last4: null|string}&\Stripe\StripeObject&\stdClass), link?: (object{country: null|string}&\Stripe\StripeObject&\stdClass), mb_way?: (object{}&\Stripe\StripeObject&\stdClass), mobilepay?: (object{card: null|(object{brand: null|string, country: null|string, exp_month: null|int, exp_year: null|int, last4: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), multibanco?: (object{entity: null|string, reference: null|string}&\Stripe\StripeObject&\stdClass), naver_pay?: (object{buyer_id: null|string}&\Stripe\StripeObject&\stdClass), oxxo?: (object{number: null|string}&\Stripe\StripeObject&\stdClass), p24?: (object{bank: null|string, reference: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), pay_by_bank?: (object{}&\Stripe\StripeObject&\stdClass), payco?: (object{buyer_id: null|string}&\Stripe\StripeObject&\stdClass), paynow?: (object{reference: null|string}&\Stripe\StripeObject&\stdClass), paypal?: (object{country: null|string, payer_email: null|string, payer_id: null|string, payer_name: null|string, seller_protection: null|(object{dispute_categories: null|string[], status: string}&\Stripe\StripeObject&\stdClass), shipping?: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass), transaction_id: null|string, verified_address?: null|(object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass), verified_email?: null|string, verified_name?: null|string}&\Stripe\StripeObject&\stdClass), payto?: (object{bsb_number: null|string, last4: null|string, mandate?: string, pay_id: null|string}&\Stripe\StripeObject&\stdClass), pix?: (object{bank_transaction_id?: null|string}&\Stripe\StripeObject&\stdClass), promptpay?: (object{reference: null|string}&\Stripe\StripeObject&\stdClass), qris?: (object{}&\Stripe\StripeObject&\stdClass), rechnung?: (object{}&\Stripe\StripeObject&\stdClass), revolut_pay?: (object{funding?: (object{card?: (object{brand: null|string, brand_product?: null|string, country: null|string, exp_month: null|int, exp_year: null|int, funding: null|string, last4: null|string}&\Stripe\StripeObject&\stdClass), type: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass), samsung_pay?: (object{buyer_id: null|string}&\Stripe\StripeObject&\stdClass), sepa_credit_transfer?: (object{bank_name: null|string, bic: null|string, iban: null|string}&\Stripe\StripeObject&\stdClass), sepa_debit?: (object{bank_code: null|string, branch_code: null|string, country: null|string, fingerprint: null|string, last4: null|string, mandate: null|string}&\Stripe\StripeObject&\stdClass), shopeepay?: (object{}&\Stripe\StripeObject&\stdClass), sofort?: (object{bank_code: null|string, bank_name: null|string, bic: null|string, country: null|string, generated_sepa_debit: null|string|\Stripe\PaymentMethod, generated_sepa_debit_mandate: null|string|\Stripe\Mandate, iban_last4: null|string, preferred_language: null|string, verified_name: null|string}&\Stripe\StripeObject&\stdClass), stripe_account?: (object{}&\Stripe\StripeObject&\stdClass), swish?: (object{fingerprint: null|string, payment_reference: null|string, verified_phone_last4: null|string}&\Stripe\StripeObject&\stdClass), twint?: (object{}&\Stripe\StripeObject&\stdClass), type: string, us_bank_account?: (object{account_holder_type: null|string, account_type: null|string, bank_name: null|string, fingerprint: null|string, last4: null|string, mandate?: string|\Stripe\Mandate, payment_reference: null|string, routing_number: null|string}&\Stripe\StripeObject&\stdClass), wechat?: (object{}&\Stripe\StripeObject&\stdClass), wechat_pay?: (object{fingerprint: null|string, transaction_id: null|string}&\Stripe\StripeObject&\stdClass), zip?: (object{}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass) $payment_method_details Details about the payment method at the time of the transaction.
* @property null|(object{session?: string}&\Stripe\StripeObject&\stdClass) $radar_options Options to configure Radar. See Radar Session for more information.
* @property null|string $receipt_email This is the email address that the receipt for this charge was sent to.
* @property null|string $receipt_number This is the transaction number that appears on email receipts sent for this charge. This attribute will be null
until a receipt has been sent.
diff --git a/lib/Checkout/Session.php b/lib/Checkout/Session.php
index 1dc5cadb8..3adc00893 100644
--- a/lib/Checkout/Session.php
+++ b/lib/Checkout/Session.php
@@ -32,7 +32,7 @@
* @property null|string $cancel_url If set, Checkout displays a back button and customers will be directed to this URL if they decide to cancel payment and return to your website.
* @property null|string $client_reference_id A unique string to reference the Checkout Session. This can be a customer ID, a cart ID, or similar, and can be used to reconcile the Session with your internal systems.
* @property null|string $client_secret The client secret of the Session. Use this with initCheckout on your front end.
- * @property null|(object{business_name: null|string, email: null|string, phone: null|string, shipping_details: null|(object{address?: (object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass), carrier?: null|string, name?: string, phone?: null|string, tracking_number?: null|string}&\Stripe\StripeObject&\stdClass), tax_ids: null|((object{type: string, value: null|string}&\Stripe\StripeObject&\stdClass))[]}&\Stripe\StripeObject&\stdClass) $collected_information Information about the customer collected within the Checkout Session.
+ * @property null|(object{business_name?: null|string, email?: null|string, phone?: null|string, shipping_details?: null|(object{address?: (object{city: null|string, country: null|string, line1: null|string, line2: null|string, postal_code: null|string, state: null|string}&\Stripe\StripeObject&\stdClass), carrier?: null|string, name?: string, phone?: null|string, tracking_number?: null|string}&\Stripe\StripeObject&\stdClass), tax_ids?: null|((object{type: string, value: null|string}&\Stripe\StripeObject&\stdClass))[]}&\Stripe\StripeObject&\stdClass) $collected_information Information about the customer collected within the Checkout Session.
* @property null|(object{promotions: null|string, terms_of_service: null|string}&\Stripe\StripeObject&\stdClass) $consent Results of consent_collection
for this session.
* @property null|(object{payment_method_reuse_agreement: null|(object{position: string}&\Stripe\StripeObject&\stdClass), promotions: null|string, terms_of_service: null|string}&\Stripe\StripeObject&\stdClass) $consent_collection When set, provides configuration for the Checkout Session to gather active consent from customers.
* @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
@@ -57,7 +57,7 @@
* @property null|string|\Stripe\PaymentLink $payment_link The ID of the Payment Link that created this Session.
* @property null|string $payment_method_collection Configure whether a Checkout Session should collect a payment method. Defaults to always
.
* @property null|(object{id: string, parent: null|string}&\Stripe\StripeObject&\stdClass) $payment_method_configuration_details Information about the payment method configuration used for this Checkout session if using dynamic payment methods.
- * @property null|(object{acss_debit?: (object{currency?: string, mandate_options?: (object{custom_mandate_url?: string, default_for?: string[], interval_description: null|string, payment_schedule: null|string, transaction_type: null|string}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string, verification_method?: string}&\Stripe\StripeObject&\stdClass), affirm?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), afterpay_clearpay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), alipay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), amazon_pay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), au_becs_debit?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), bacs_debit?: (object{mandate_options?: (object{reference_prefix?: string}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), bancontact?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), boleto?: (object{expires_after_days: int, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), card?: (object{installments?: (object{enabled?: bool}&\Stripe\StripeObject&\stdClass), request_decremental_authorization?: string, request_extended_authorization?: string, request_incremental_authorization?: string, request_multicapture?: string, request_overcapture?: string, request_three_d_secure: string, setup_future_usage?: string, statement_descriptor_suffix_kana?: string, statement_descriptor_suffix_kanji?: string}&\Stripe\StripeObject&\stdClass), cashapp?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), customer_balance?: (object{bank_transfer?: (object{eu_bank_transfer?: (object{country: string}&\Stripe\StripeObject&\stdClass), requested_address_types?: string[], type: null|string}&\Stripe\StripeObject&\stdClass), funding_type: null|string, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), eps?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), fpx?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), giropay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), grabpay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), ideal?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), kakao_pay?: (object{capture_method?: string, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), klarna?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), konbini?: (object{expires_after_days: null|int, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), kr_card?: (object{capture_method?: string, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), link?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), mobilepay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), multibanco?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), naver_pay?: (object{capture_method?: string}&\Stripe\StripeObject&\stdClass), oxxo?: (object{expires_after_days: int, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), p24?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), payco?: (object{capture_method?: string}&\Stripe\StripeObject&\stdClass), paynow?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), paypal?: (object{capture_method?: string, preferred_locale: null|string, reference: null|string, setup_future_usage?: string, subsellers?: string[]}&\Stripe\StripeObject&\stdClass), payto?: (object{mandate_options?: (object{amount: null|int, amount_type: null|string, end_date: null|string, payment_schedule: null|string, payments_per_period: null|int, purpose: null|string, start_date: null|string}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), pix?: (object{expires_after_seconds: null|int}&\Stripe\StripeObject&\stdClass), revolut_pay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), samsung_pay?: (object{capture_method?: string}&\Stripe\StripeObject&\stdClass), sepa_debit?: (object{mandate_options?: (object{reference_prefix?: string}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), sofort?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), swish?: (object{reference: null|string}&\Stripe\StripeObject&\stdClass), us_bank_account?: (object{financial_connections?: (object{filters?: (object{account_subcategories?: string[], institution?: string}&\Stripe\StripeObject&\stdClass), manual_entry?: (object{mode?: string}&\Stripe\StripeObject&\stdClass), permissions?: string[], prefetch: null|string[], return_url?: string}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string, verification_method?: string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass) $payment_method_options Payment-method-specific configuration for the PaymentIntent or SetupIntent of this CheckoutSession.
+ * @property null|(object{acss_debit?: (object{currency?: string, mandate_options?: (object{custom_mandate_url?: string, default_for?: string[], interval_description: null|string, payment_schedule: null|string, transaction_type: null|string}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string, verification_method?: string}&\Stripe\StripeObject&\stdClass), affirm?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), afterpay_clearpay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), alipay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), amazon_pay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), au_becs_debit?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), bacs_debit?: (object{mandate_options?: (object{reference_prefix?: string}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), bancontact?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), boleto?: (object{expires_after_days: int, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), card?: (object{installments?: (object{enabled?: bool}&\Stripe\StripeObject&\stdClass), request_decremental_authorization?: string, request_extended_authorization?: string, request_incremental_authorization?: string, request_multicapture?: string, request_overcapture?: string, request_three_d_secure: string, restrictions?: (object{brands_blocked?: string[]}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string, statement_descriptor_suffix_kana?: string, statement_descriptor_suffix_kanji?: string}&\Stripe\StripeObject&\stdClass), cashapp?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), customer_balance?: (object{bank_transfer?: (object{eu_bank_transfer?: (object{country: string}&\Stripe\StripeObject&\stdClass), requested_address_types?: string[], type: null|string}&\Stripe\StripeObject&\stdClass), funding_type: null|string, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), eps?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), fpx?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), giropay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), grabpay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), ideal?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), kakao_pay?: (object{capture_method?: string, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), klarna?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), konbini?: (object{expires_after_days: null|int, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), kr_card?: (object{capture_method?: string, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), link?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), mobilepay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), multibanco?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), naver_pay?: (object{capture_method?: string}&\Stripe\StripeObject&\stdClass), oxxo?: (object{expires_after_days: int, setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), p24?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), payco?: (object{capture_method?: string}&\Stripe\StripeObject&\stdClass), paynow?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), paypal?: (object{capture_method?: string, preferred_locale: null|string, reference: null|string, setup_future_usage?: string, subsellers?: string[]}&\Stripe\StripeObject&\stdClass), payto?: (object{mandate_options?: (object{amount: null|int, amount_type: null|string, end_date: null|string, payment_schedule: null|string, payments_per_period: null|int, purpose: null|string, start_date: null|string}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), pix?: (object{expires_after_seconds: null|int}&\Stripe\StripeObject&\stdClass), revolut_pay?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), samsung_pay?: (object{capture_method?: string}&\Stripe\StripeObject&\stdClass), sepa_debit?: (object{mandate_options?: (object{reference_prefix?: string}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), sofort?: (object{setup_future_usage?: string}&\Stripe\StripeObject&\stdClass), swish?: (object{reference: null|string}&\Stripe\StripeObject&\stdClass), us_bank_account?: (object{financial_connections?: (object{filters?: (object{account_subcategories?: string[], institution?: string}&\Stripe\StripeObject&\stdClass), manual_entry?: (object{mode?: string}&\Stripe\StripeObject&\stdClass), permissions?: string[], prefetch: null|string[], return_url?: string}&\Stripe\StripeObject&\stdClass), setup_future_usage?: string, verification_method?: string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass) $payment_method_options Payment-method-specific configuration for the PaymentIntent or SetupIntent of this CheckoutSession.
* @property string[] $payment_method_types A list of the types of payment methods (e.g. card) this Checkout Session is allowed to accept.
* @property string $payment_status The payment status of the Checkout Session, one of paid
, unpaid
, or no_payment_required
. You can use this value to decide when to fulfill your customer's order.
* @property null|(object{update: null|(object{line_items?: null|string, shipping_details: null|string}&\Stripe\StripeObject&\stdClass)}&\Stripe\StripeObject&\stdClass) $permissions
This property is used to set up permissions for various actions (e.g., update) on the CheckoutSession object.
For specific permissions, please refer to their dedicated subsections, such as permissions.update.shipping_details
.
null
when no tax applies to the location.
- * @property null|string $state ISO 3166-2 subdivision code, without country prefix. For example, "NY" for New York, United States.
+ * @property null|string $state ISO 3166-2 subdivision code, without country prefix. For example, "NY" for New York, United States.
* @property null|string $tax_type The high-level tax type, such as vat
or sales_tax
.
*/
class TaxRate extends ApiResource
diff --git a/tests/Stripe/ApiRequestorTest.php b/tests/Stripe/ApiRequestorTest.php
index 62f406ca6..c4a2d92fc 100644
--- a/tests/Stripe/ApiRequestorTest.php
+++ b/tests/Stripe/ApiRequestorTest.php
@@ -726,4 +726,23 @@ public function testIsDisabled()
$result = $method->invoke(null, 'procopen, php_uname, exec', 'php_uname');
static::assertTrue($result);
}
+
+ public function testRaisesForNullBytesInResourceMethod()
+ {
+ $this->expectException(\Stripe\Exception\InvalidRequestException::class);
+ $this->compatExpectExceptionMessageMatches('#null byte#');
+
+ Charge::retrieve("abc_123\0");
+ }
+
+ public function testRaisesForNullBytesInRawRequest()
+ {
+ $this->expectException(\Stripe\Exception\InvalidRequestException::class);
+ $this->compatExpectExceptionMessageMatches('#null byte#');
+
+ $client = new BaseStripeClient([
+ 'api_key' => 'sk_test_client',
+ ]);
+ $client->rawRequest('get', "/v1/xyz\0");
+ }
}