From 8801110a87b3eefe6410435d36bfe2cd01cf4a18 Mon Sep 17 00:00:00 2001 From: "stripe-openapi[bot]" <105521251+stripe-openapi[bot]@users.noreply.github.com> Date: Thu, 11 Apr 2024 15:52:35 -0700 Subject: [PATCH] Update generated code (#1677) * Update generated code for v942 * Update generated code for v944 * Update generated code for v945 * Update generated code for v947 * Update generated code for v949 --------- Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> --- OPENAPI_VERSION | 2 +- lib/Billing/Meter.php | 2 +- lib/Billing/MeterEventAdjustment.php | 6 +++--- lib/BillingPortal/Session.php | 2 +- lib/Charge.php | 4 ++-- lib/ErrorObject.php | 4 ++++ lib/PaymentMethod.php | 2 ++ lib/PaymentMethodConfiguration.php | 1 + lib/TaxId.php | 6 +++++- lib/TransferReversal.php | 2 +- lib/UsageRecord.php | 2 ++ 11 files changed, 23 insertions(+), 10 deletions(-) diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION index 33b0af258..a41158a2f 100644 --- a/OPENAPI_VERSION +++ b/OPENAPI_VERSION @@ -1 +1 @@ -v940 +v949 \ No newline at end of file diff --git a/lib/Billing/Meter.php b/lib/Billing/Meter.php index 96704707a..5200fba13 100644 --- a/lib/Billing/Meter.php +++ b/lib/Billing/Meter.php @@ -5,7 +5,7 @@ namespace Stripe\Billing; /** - * A billing meter is a resource that allows you to track usage of a particular event. For example, you might create a billing meter to track the number of API calls made by a particular user. You can then use the billing meter to charge the user for the number of API calls they make. + * A billing meter is a resource that allows you to track usage of a particular event. For example, you might create a billing meter to track the number of API calls made by a particular user. You can then attach the billing meter to a price and attach the price to a subscription to charge the user for the number of API calls they make. * * @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. diff --git a/lib/Billing/MeterEventAdjustment.php b/lib/Billing/MeterEventAdjustment.php index 4b308f8be..f603887fe 100644 --- a/lib/Billing/MeterEventAdjustment.php +++ b/lib/Billing/MeterEventAdjustment.php @@ -5,14 +5,14 @@ namespace Stripe\Billing; /** - * A billing meter event adjustment represents the status of a meter event adjustment. + * A billing meter event adjustment is a resource that allows you to cancel a meter event. For example, you might create a billing meter event adjustment to cancel a meter event that was created in error or attached to the wrong customer. * * @property string $object String representing the object's type. Objects of the same type share the same value. - * @property \Stripe\StripeObject $cancel + * @property null|\Stripe\StripeObject $cancel Specifies which event to cancel. * @property string $event_name The name of the meter event. Corresponds with the event_name field on a meter. * @property bool $livemode Has the value true if the object exists in live mode or the value false if the object exists in test mode. * @property string $status The meter event adjustment's status. - * @property string $type Specifies whether to cancel a single event or a range of events for a time period. + * @property string $type Specifies whether to cancel a single event or a range of events for a time period. Time period cancellation is not supported yet. */ class MeterEventAdjustment extends \Stripe\ApiResource { diff --git a/lib/BillingPortal/Session.php b/lib/BillingPortal/Session.php index d47fe602f..1ca3fb8f0 100644 --- a/lib/BillingPortal/Session.php +++ b/lib/BillingPortal/Session.php @@ -28,7 +28,7 @@ * @property null|\Stripe\StripeObject $flow Information about a specific flow for the customer to go through. See the docs to learn more about using customer portal deep links and flows. * @property bool $livemode Has the value true if the object exists in live mode or the value false if the object exists in test mode. * @property null|string $locale The IETF language tag of the locale Customer Portal is displayed in. If blank or auto, the customer’s preferred_locales or browser’s locale is used. - * @property null|string $on_behalf_of The account for which the session was created on behalf of. When specified, only subscriptions and invoices with this on_behalf_of account appear in the portal. For more information, see the docs. Use the Accounts API to modify the on_behalf_of account's branding settings, which the portal displays. + * @property null|string $on_behalf_of The account for which the session was created on behalf of. When specified, only subscriptions and invoices with this on_behalf_of account appear in the portal. For more information, see the docs. Use the Accounts API to modify the on_behalf_of account's branding settings, which the portal displays. * @property null|string $return_url The URL to redirect customers to when they click on the portal's link to return to your website. * @property string $url The short-lived URL of the session that gives customers access to the customer portal. */ diff --git a/lib/Charge.php b/lib/Charge.php index 5457371bb..52a4c9a94 100644 --- a/lib/Charge.php +++ b/lib/Charge.php @@ -16,8 +16,8 @@ * @property int $amount_captured Amount in cents (or local equivalent) captured (can be less than the amount attribute on the charge if a partial capture was made). * @property int $amount_refunded Amount in cents (or local equivalent) refunded (can be less than the amount attribute on the charge if a partial refund was issued). * @property null|string|\Stripe\Application $application ID of the Connect application that created the charge. - * @property null|string|\Stripe\ApplicationFee $application_fee The application fee (if any) for the charge. See the Connect documentation for details. - * @property null|int $application_fee_amount The amount of the application fee (if any) requested for the charge. See the Connect documentation for details. + * @property null|string|\Stripe\ApplicationFee $application_fee The application fee (if any) for the charge. See the Connect documentation for details. + * @property null|int $application_fee_amount The amount of the application fee (if any) requested for the charge. See the Connect documentation for details. * @property null|string $authorization_code Authorization code on the charge. * @property null|string|\Stripe\BalanceTransaction $balance_transaction ID of the balance transaction that describes the impact of this charge on your account balance (not including refunds or disputes). * @property \Stripe\StripeObject $billing_details diff --git a/lib/ErrorObject.php b/lib/ErrorObject.php index 0883e5eaa..86c5c4182 100644 --- a/lib/ErrorObject.php +++ b/lib/ErrorObject.php @@ -66,6 +66,10 @@ class ErrorObject extends StripeObject const CODE_BANK_ACCOUNT_UNVERIFIED = 'bank_account_unverified'; const CODE_BANK_ACCOUNT_VERIFICATION_FAILED = 'bank_account_verification_failed'; const CODE_BILLING_INVALID_MANDATE = 'billing_invalid_mandate'; + const CODE_BILLING_POLICY_REMOTE_FUNCTION_RESPONSE_INVALID = 'billing_policy_remote_function_response_invalid'; + const CODE_BILLING_POLICY_REMOTE_FUNCTION_TIMEOUT = 'billing_policy_remote_function_timeout'; + const CODE_BILLING_POLICY_REMOTE_FUNCTION_UNEXPECTED_STATUS_CODE = 'billing_policy_remote_function_unexpected_status_code'; + const CODE_BILLING_POLICY_REMOTE_FUNCTION_UNREACHABLE = 'billing_policy_remote_function_unreachable'; const CODE_BITCOIN_UPGRADE_REQUIRED = 'bitcoin_upgrade_required'; const CODE_CAPTURE_CHARGE_AUTHORIZATION_EXPIRED = 'capture_charge_authorization_expired'; const CODE_CAPTURE_UNAUTHORIZED_PAYMENT = 'capture_unauthorized_payment'; diff --git a/lib/PaymentMethod.php b/lib/PaymentMethod.php index fe2d82226..5ea0f76ef 100644 --- a/lib/PaymentMethod.php +++ b/lib/PaymentMethod.php @@ -17,6 +17,7 @@ * @property null|\Stripe\StripeObject $affirm * @property null|\Stripe\StripeObject $afterpay_clearpay * @property null|\Stripe\StripeObject $alipay + * @property null|\Stripe\StripeObject $amazon_pay * @property null|\Stripe\StripeObject $au_becs_debit * @property null|\Stripe\StripeObject $bacs_debit * @property null|\Stripe\StripeObject $bancontact @@ -70,6 +71,7 @@ class PaymentMethod extends ApiResource const TYPE_AFFIRM = 'affirm'; const TYPE_AFTERPAY_CLEARPAY = 'afterpay_clearpay'; const TYPE_ALIPAY = 'alipay'; + const TYPE_AMAZON_PAY = 'amazon_pay'; const TYPE_AU_BECS_DEBIT = 'au_becs_debit'; const TYPE_BACS_DEBIT = 'bacs_debit'; const TYPE_BANCONTACT = 'bancontact'; diff --git a/lib/PaymentMethodConfiguration.php b/lib/PaymentMethodConfiguration.php index 214027c3f..f8dc59fa8 100644 --- a/lib/PaymentMethodConfiguration.php +++ b/lib/PaymentMethodConfiguration.php @@ -27,6 +27,7 @@ * @property null|\Stripe\StripeObject $affirm * @property null|\Stripe\StripeObject $afterpay_clearpay * @property null|\Stripe\StripeObject $alipay + * @property null|\Stripe\StripeObject $amazon_pay * @property null|\Stripe\StripeObject $apple_pay * @property null|string $application For child configs, the Connect application associated with the configuration. * @property null|\Stripe\StripeObject $au_becs_debit diff --git a/lib/TaxId.php b/lib/TaxId.php index 2827d9c2a..3f039ae01 100644 --- a/lib/TaxId.php +++ b/lib/TaxId.php @@ -17,7 +17,7 @@ * @property null|string|\Stripe\Customer $customer ID of the customer. * @property bool $livemode Has the value true if the object exists in live mode or the value false if the object exists in test mode. * @property null|\Stripe\StripeObject $owner The account or customer the tax ID belongs to. - * @property string $type Type of the tax ID, one of ad_nrt, ae_trn, ar_cuit, au_abn, au_arn, bg_uic, bo_tin, br_cnpj, br_cpf, ca_bn, ca_gst_hst, ca_pst_bc, ca_pst_mb, ca_pst_sk, ca_qst, ch_vat, cl_tin, cn_tin, co_nit, cr_tin, do_rcn, ec_ruc, eg_tin, es_cif, eu_oss_vat, eu_vat, gb_vat, ge_vat, hk_br, hu_tin, id_npwp, il_vat, in_gst, is_vat, jp_cn, jp_rn, jp_trn, ke_pin, kr_brn, li_uid, mx_rfc, my_frp, my_itn, my_sst, no_vat, no_voec, nz_gst, pe_ruc, ph_tin, ro_tin, rs_pib, ru_inn, ru_kpp, sa_vat, sg_gst, sg_uen, si_tin, sv_nit, th_vat, tr_tin, tw_vat, ua_vat, us_ein, uy_ruc, ve_rif, vn_tin, or za_vat. Note that some legacy tax IDs have type unknown + * @property string $type Type of the tax ID, one of ad_nrt, ae_trn, ar_cuit, au_abn, au_arn, bg_uic, bh_vat, bo_tin, br_cnpj, br_cpf, ca_bn, ca_gst_hst, ca_pst_bc, ca_pst_mb, ca_pst_sk, ca_qst, ch_vat, cl_tin, cn_tin, co_nit, cr_tin, do_rcn, ec_ruc, eg_tin, es_cif, eu_oss_vat, eu_vat, gb_vat, ge_vat, hk_br, hu_tin, id_npwp, il_vat, in_gst, is_vat, jp_cn, jp_rn, jp_trn, ke_pin, kr_brn, kz_bin, li_uid, mx_rfc, my_frp, my_itn, my_sst, ng_tin, no_vat, no_voec, nz_gst, om_vat, pe_ruc, ph_tin, ro_tin, rs_pib, ru_inn, ru_kpp, sa_vat, sg_gst, sg_uen, si_tin, sv_nit, th_vat, tr_tin, tw_vat, ua_vat, us_ein, uy_ruc, ve_rif, vn_tin, or za_vat. Note that some legacy tax IDs have type unknown * @property string $value Value of the tax ID. * @property null|\Stripe\StripeObject $verification Tax ID verification information. */ @@ -36,6 +36,7 @@ class TaxId extends ApiResource const TYPE_AU_ABN = 'au_abn'; const TYPE_AU_ARN = 'au_arn'; const TYPE_BG_UIC = 'bg_uic'; + const TYPE_BH_VAT = 'bh_vat'; const TYPE_BO_TIN = 'bo_tin'; const TYPE_BR_CNPJ = 'br_cnpj'; const TYPE_BR_CPF = 'br_cpf'; @@ -69,14 +70,17 @@ class TaxId extends ApiResource const TYPE_JP_TRN = 'jp_trn'; const TYPE_KE_PIN = 'ke_pin'; const TYPE_KR_BRN = 'kr_brn'; + const TYPE_KZ_BIN = 'kz_bin'; const TYPE_LI_UID = 'li_uid'; const TYPE_MX_RFC = 'mx_rfc'; const TYPE_MY_FRP = 'my_frp'; const TYPE_MY_ITN = 'my_itn'; const TYPE_MY_SST = 'my_sst'; + const TYPE_NG_TIN = 'ng_tin'; const TYPE_NO_VAT = 'no_vat'; const TYPE_NO_VOEC = 'no_voec'; const TYPE_NZ_GST = 'nz_gst'; + const TYPE_OM_VAT = 'om_vat'; const TYPE_PE_RUC = 'pe_ruc'; const TYPE_PH_TIN = 'ph_tin'; const TYPE_RO_TIN = 'ro_tin'; diff --git a/lib/TransferReversal.php b/lib/TransferReversal.php index f48c68f68..36e8ebe47 100644 --- a/lib/TransferReversal.php +++ b/lib/TransferReversal.php @@ -17,7 +17,7 @@ * transfer only if the destination account has enough balance to cover the * reversal. * - * Related guide: Reversing transfers + * Related guide: Reverse transfers * * @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. diff --git a/lib/UsageRecord.php b/lib/UsageRecord.php index b3746617d..13dd1ccf4 100644 --- a/lib/UsageRecord.php +++ b/lib/UsageRecord.php @@ -10,6 +10,8 @@ * * Related guide: Metered billing * + * This is our legacy usage-based billing API. See the updated usage-based billing docs. + * * @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 bool $livemode Has the value true if the object exists in live mode or the value false if the object exists in test mode.