From 0cfa628ca9dce400b063478e911c995f6bbf579e Mon Sep 17 00:00:00 2001
From: "stripe-openapi[bot]"
<105521251+stripe-openapi[bot]@users.noreply.github.com>
Date: Thu, 29 Feb 2024 19:23:27 +0000
Subject: [PATCH 01/10] Update generated code (#1654)
* Update generated code for v840
* Update generated code for v841
* Update generated code for v849
* Update generated code for v851
* Update generated code for v852
* Update generated code for v853
* Update generated code for v855
---------
Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
Co-authored-by: anniel-stripe <97691964+anniel-stripe@users.noreply.github.com>
---
OPENAPI_VERSION | 2 +-
init.php | 6 +++++
lib/Application.php | 15 ++++++++++++
lib/ApplicationFee.php | 2 +-
lib/BalanceTransaction.php | 2 +-
lib/BankAccount.php | 2 +-
lib/BillingPortal/Configuration.php | 2 +-
lib/Capability.php | 4 ++--
lib/Charge.php | 34 +++++++++++++++++++++++++++-
lib/Checkout/Session.php | 10 ++++----
lib/ConnectCollectionTransfer.php | 18 +++++++++++++++
lib/Identity/VerificationReport.php | 2 +-
lib/Identity/VerificationSession.php | 2 +-
lib/Invoice.php | 2 +-
lib/PaymentIntent.php | 2 +-
lib/PaymentLink.php | 6 ++---
lib/Person.php | 6 ++---
lib/PlatformTaxFee.php | 17 ++++++++++++++
lib/Quote.php | 2 +-
lib/ReserveTransaction.php | 17 ++++++++++++++
lib/SetupAttempt.php | 2 +-
lib/SetupIntent.php | 2 +-
lib/SourceMandateNotification.php | 28 +++++++++++++++++++++++
lib/Subscription.php | 2 +-
lib/SubscriptionSchedule.php | 2 +-
lib/TaxDeductedAtSource.php | 17 ++++++++++++++
lib/Util/ObjectTypes.php | 6 +++++
27 files changed, 184 insertions(+), 28 deletions(-)
create mode 100644 lib/Application.php
create mode 100644 lib/ConnectCollectionTransfer.php
create mode 100644 lib/PlatformTaxFee.php
create mode 100644 lib/ReserveTransaction.php
create mode 100644 lib/SourceMandateNotification.php
create mode 100644 lib/TaxDeductedAtSource.php
diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION
index e3b365910..adddc73de 100644
--- a/OPENAPI_VERSION
+++ b/OPENAPI_VERSION
@@ -1 +1 @@
-v840
\ No newline at end of file
+v855
\ No newline at end of file
diff --git a/init.php b/init.php
index 2500ca394..bbe7551c8 100644
--- a/init.php
+++ b/init.php
@@ -85,6 +85,7 @@
require __DIR__ . '/lib/AccountLink.php';
require __DIR__ . '/lib/AccountSession.php';
require __DIR__ . '/lib/ApplePayDomain.php';
+require __DIR__ . '/lib/Application.php';
require __DIR__ . '/lib/ApplicationFee.php';
require __DIR__ . '/lib/ApplicationFeeRefund.php';
require __DIR__ . '/lib/Apps/Secret.php';
@@ -101,6 +102,7 @@
require __DIR__ . '/lib/Climate/Order.php';
require __DIR__ . '/lib/Climate/Product.php';
require __DIR__ . '/lib/Climate/Supplier.php';
+require __DIR__ . '/lib/ConnectCollectionTransfer.php';
require __DIR__ . '/lib/CountrySpec.php';
require __DIR__ . '/lib/Coupon.php';
require __DIR__ . '/lib/CreditNote.php';
@@ -144,6 +146,7 @@
require __DIR__ . '/lib/Payout.php';
require __DIR__ . '/lib/Person.php';
require __DIR__ . '/lib/Plan.php';
+require __DIR__ . '/lib/PlatformTaxFee.php';
require __DIR__ . '/lib/Price.php';
require __DIR__ . '/lib/Product.php';
require __DIR__ . '/lib/PromotionCode.php';
@@ -154,6 +157,7 @@
require __DIR__ . '/lib/Refund.php';
require __DIR__ . '/lib/Reporting/ReportRun.php';
require __DIR__ . '/lib/Reporting/ReportType.php';
+require __DIR__ . '/lib/ReserveTransaction.php';
require __DIR__ . '/lib/Review.php';
require __DIR__ . '/lib/Service/AccountLinkService.php';
require __DIR__ . '/lib/Service/AccountService.php';
@@ -281,6 +285,7 @@
require __DIR__ . '/lib/ShippingRate.php';
require __DIR__ . '/lib/Sigma/ScheduledQueryRun.php';
require __DIR__ . '/lib/Source.php';
+require __DIR__ . '/lib/SourceMandateNotification.php';
require __DIR__ . '/lib/SourceTransaction.php';
require __DIR__ . '/lib/Subscription.php';
require __DIR__ . '/lib/SubscriptionItem.php';
@@ -292,6 +297,7 @@
require __DIR__ . '/lib/Tax/Transaction.php';
require __DIR__ . '/lib/Tax/TransactionLineItem.php';
require __DIR__ . '/lib/TaxCode.php';
+require __DIR__ . '/lib/TaxDeductedAtSource.php';
require __DIR__ . '/lib/TaxId.php';
require __DIR__ . '/lib/TaxRate.php';
require __DIR__ . '/lib/Terminal/Configuration.php';
diff --git a/lib/Application.php b/lib/Application.php
new file mode 100644
index 000000000..e74ef025b
--- /dev/null
+++ b/lib/Application.php
@@ -0,0 +1,15 @@
+amount - fee
* @property string $reporting_category Learn more about how reporting categories can help you understand balance transactions from an accounting perspective.
- * @property null|string|\Stripe\ApplicationFee|\Stripe\ApplicationFeeRefund|\Stripe\Charge|\Stripe\CustomerCashBalanceTransaction|\Stripe\Dispute|\Stripe\Issuing\Authorization|\Stripe\Issuing\Dispute|\Stripe\Issuing\Transaction|\Stripe\Payout|\Stripe\Refund|\Stripe\StripeObject|\Stripe\Topup|\Stripe\Transfer|\Stripe\TransferReversal $source This transaction relates to the Stripe object.
+ * @property null|string|\Stripe\ApplicationFee|\Stripe\ApplicationFeeRefund|\Stripe\Charge|\Stripe\ConnectCollectionTransfer|\Stripe\CustomerCashBalanceTransaction|\Stripe\Dispute|\Stripe\Issuing\Authorization|\Stripe\Issuing\Dispute|\Stripe\Issuing\Transaction|\Stripe\Payout|\Stripe\PlatformTaxFee|\Stripe\Refund|\Stripe\ReserveTransaction|\Stripe\TaxDeductedAtSource|\Stripe\Topup|\Stripe\Transfer|\Stripe\TransferReversal $source This transaction relates to the Stripe object.
* @property string $status The transaction's net funds status in the Stripe balance, which are either available
or pending
.
* @property string $type Transaction type: adjustment
, advance
, advance_funding
, anticipation_repayment
, application_fee
, application_fee_refund
, charge
, climate_order_purchase
, climate_order_refund
, connect_collection_transfer
, contribution
, issuing_authorization_hold
, issuing_authorization_release
, issuing_dispute
, issuing_transaction
, obligation_outbound
, obligation_reversal_inbound
, payment
, payment_failure_refund
, payment_network_reserve_hold
, payment_network_reserve_release
, payment_refund
, payment_reversal
, payment_unreconciled
, payout
, payout_cancel
, payout_failure
, refund
, refund_failure
, reserve_transaction
, reserved_funds
, stripe_fee
, stripe_fx_fee
, tax_fee
, topup
, topup_reversal
, transfer
, transfer_cancel
, transfer_failure
, or transfer_refund
. Learn more about balance transaction types and what they represent. To classify transactions for accounting purposes, consider reporting_category
instead.
*/
diff --git a/lib/BankAccount.php b/lib/BankAccount.php
index 31bbadea4..93e8f38e8 100644
--- a/lib/BankAccount.php
+++ b/lib/BankAccount.php
@@ -31,7 +31,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|\Stripe\StripeObject $requirements Information about the requirements for the bank account, including what information needs to be collected.
* @property null|string $routing_number The routing transit number for the bank account.
- * @property string $status
For bank accounts, possible values are new
, validated
, verified
, verification_failed
, or errored
. A bank account that hasn't had any activity or validation performed is new
. If Stripe can determine that the bank account exists, its status will be validated
. Note that there often isn’t enough information to know (e.g., for smaller credit unions), and the validation is not always run. If customer bank account verification has succeeded, the bank account status will be verified
. If the verification failed for any reason, such as microdeposit failure, the status will be verification_failed
. If a payout sent to this bank account fails, we'll set the status to errored
and will not continue to send scheduled payouts until the bank details are updated.
For external accounts, possible values are new
, errored
and verification_failed
. If a payouts fails, the status is set to errored
and scheduled payouts are stopped until account details are updated. In India, if we can't verify the owner of the bank account, we'll set the status to verification_failed
. Other validations aren't run against external accounts because they're only used for payouts. This means the other statuses don't apply.
For bank accounts, possible values are new
, validated
, verified
, verification_failed
, or errored
. A bank account that hasn't had any activity or validation performed is new
. If Stripe can determine that the bank account exists, its status will be validated
. Note that there often isn’t enough information to know (e.g., for smaller credit unions), and the validation is not always run. If customer bank account verification has succeeded, the bank account status will be verified
. If the verification failed for any reason, such as microdeposit failure, the status will be verification_failed
. If a payout sent to this bank account fails, we'll set the status to errored
and will not continue to send scheduled payouts until the bank details are updated.
For external accounts, possible values are new
, errored
and verification_failed
. If a payout fails, the status is set to errored
and scheduled payouts are stopped until account details are updated. In the US and India, if we can't verify the owner of the bank account, we'll set the status to verification_failed
. Other validations aren't run against external accounts because they're only used for payouts. This means the other statuses don't apply.
auto
.
* @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 Client secret to be used when initializing Stripe.js embedded checkout.
@@ -40,7 +40,7 @@
* @property \Stripe\StripeObject $custom_text
* @property null|string|\Stripe\Customer $customer The ID of the customer for this Session. For Checkout Sessions in subscription
mode or Checkout Sessions with customer_creation
set as always
in payment
mode, Checkout will create a new customer object based on information provided during the payment flow unless an existing customer was provided when the Session was created.
* @property null|string $customer_creation Configure whether a Checkout Session creates a Customer when the Checkout Session completes.
- * @property null|\Stripe\StripeObject $customer_details The customer details including the customer's tax exempt status and the customer's tax IDs. Only the customer's email is present on Sessions in setup
mode.
+ * @property null|\Stripe\StripeObject $customer_details The customer details including the customer's tax exempt status and the customer's tax IDs. Customer's address details are not present on Sessions in setup
mode.
* @property null|string $customer_email If provided, this value will be used when the Customer object is created. If not provided, customers will be asked to enter their email address. Use this parameter to prefill customer data if you already have an email on file. To access information about the customer once the payment flow is complete, use the customer
attribute.
* @property int $expires_at The timestamp at which the Checkout Session will expire.
* @property null|string|\Stripe\Invoice $invoice ID of the invoice created by the Checkout Session, if it exists.
@@ -52,14 +52,14 @@
* @property string $mode The mode of the Checkout Session.
* @property null|string|\Stripe\PaymentIntent $payment_intent The ID of the PaymentIntent for Checkout Sessions in payment
mode.
* @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.
+ * @property null|string $payment_method_collection Configure whether a Checkout Session should collect a payment method. Defaults to always
.
* @property null|\Stripe\StripeObject $payment_method_configuration_details Information about the payment method configuration used for this Checkout session if using dynamic payment methods.
* @property null|\Stripe\StripeObject $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|\Stripe\StripeObject $phone_number_collection
* @property null|string $recovered_from The ID of the original expired Checkout Session that triggered the recovery flow.
- * @property null|string $redirect_on_completion Applies to Checkout Sessions with ui_mode: embedded
. By default, Stripe will always redirect to your return_url after a successful confirmation. If you set redirect_on_completion: 'if_required'
, then we will only redirect if your user chooses a redirect-based payment method.
+ * @property null|string $redirect_on_completion This parameter applies to ui_mode: embedded
. Learn more about the redirect behavior of embedded sessions. Defaults to always
.
* @property null|string $return_url Applies to Checkout Sessions with ui_mode: embedded
. The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method's app or site.
* @property null|string|\Stripe\SetupIntent $setup_intent The ID of the SetupIntent for Checkout Sessions in setup
mode.
* @property null|\Stripe\StripeObject $shipping_address_collection When set, provides configuration for Checkout to collect a shipping address from a customer.
@@ -72,7 +72,7 @@
* @property null|string $success_url The URL the customer will be directed to after the payment or subscription creation is successful.
* @property null|\Stripe\StripeObject $tax_id_collection
* @property null|\Stripe\StripeObject $total_details Tax and discount details for the computed total amount.
- * @property null|string $ui_mode The UI mode of the Session. Can be hosted
(default) or embedded
.
+ * @property null|string $ui_mode The UI mode of the Session. Defaults to hosted
.
* @property null|string $url The URL to the Checkout Session. Redirect customers to this URL to take them to Checkout. If you’re using Custom Domains, the URL will use your subdomain. Otherwise, it’ll use checkout.stripe.com.
This value is only present when the session is active.
*/
class Session extends \Stripe\ApiResource
diff --git a/lib/ConnectCollectionTransfer.php b/lib/ConnectCollectionTransfer.php
new file mode 100644
index 000000000..69f961d0a
--- /dev/null
+++ b/lib/ConnectCollectionTransfer.php
@@ -0,0 +1,18 @@
+ISO currency code, in lowercase. Must be a supported currency.
+ * @property string|\Stripe\Account $destination ID of the account that funds are being collected for.
+ * @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.
+ */
+class ConnectCollectionTransfer extends ApiResource
+{
+ const OBJECT_NAME = 'connect_collection_transfer';
+}
diff --git a/lib/Identity/VerificationReport.php b/lib/Identity/VerificationReport.php
index 2b23299b7..8bf4333d0 100644
--- a/lib/Identity/VerificationReport.php
+++ b/lib/Identity/VerificationReport.php
@@ -26,7 +26,7 @@
* @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 $options
* @property null|\Stripe\StripeObject $selfie Result from a selfie check
- * @property null|string $type Type of report.
+ * @property string $type Type of report.
* @property null|string $verification_session ID of the VerificationSession that created this report.
*/
class VerificationReport extends \Stripe\ApiResource
diff --git a/lib/Identity/VerificationSession.php b/lib/Identity/VerificationSession.php
index 2539c27ad..0de0d7583 100644
--- a/lib/Identity/VerificationSession.php
+++ b/lib/Identity/VerificationSession.php
@@ -29,7 +29,7 @@
* @property null|\Stripe\StripeObject $options A set of options for the session’s verification checks.
* @property null|\Stripe\StripeObject $redaction Redaction status of this VerificationSession. If the VerificationSession is not redacted, this field will be null.
* @property string $status Status of this VerificationSession. Learn more about the lifecycle of sessions.
- * @property null|string $type The type of verification check to be performed.
+ * @property string $type The type of verification check to be performed.
* @property null|string $url The short-lived URL that you use to redirect a user to Stripe to submit their identity information. This URL expires after 48 hours and can only be used once. Don’t store it, log it, send it in emails or expose it to anyone other than the user. Refer to our docs on verifying identity documents to learn how to redirect users to Stripe.
* @property null|\Stripe\StripeObject $verified_outputs The user’s verified data.
*/
diff --git a/lib/Invoice.php b/lib/Invoice.php
index a6895df9b..cf26c76ff 100644
--- a/lib/Invoice.php
+++ b/lib/Invoice.php
@@ -47,7 +47,7 @@
* @property int $amount_paid The amount, in cents (or local equivalent), that was paid.
* @property int $amount_remaining The difference between amount_due and amount_paid, in cents (or local equivalent).
* @property int $amount_shipping This is the sum of all the shipping amounts.
- * @property null|string|\Stripe\StripeObject $application ID of the Connect Application that created the invoice.
+ * @property null|string|\Stripe\Application $application ID of the Connect Application that created the invoice.
* @property null|int $application_fee_amount The fee in cents (or local equivalent) that will be applied to the invoice and transferred to the application owner's Stripe account when the invoice is paid.
* @property int $attempt_count Number of payment attempts made for this invoice, from the perspective of the payment retry schedule. Any payment attempt counts as the first attempt, and subsequently only automatic retries increment the attempt count. In other words, manual payment attempts after the first attempt do not affect the retry schedule.
* @property bool $attempted Whether an attempt has been made to pay the invoice. An invoice is not attempted until 1 hour after the invoice.created
webhook, for example, so you might not want to display that invoice as unpaid to your users.
diff --git a/lib/PaymentIntent.php b/lib/PaymentIntent.php
index 417d710d5..82ac54f9c 100644
--- a/lib/PaymentIntent.php
+++ b/lib/PaymentIntent.php
@@ -23,7 +23,7 @@
* @property int $amount_capturable Amount that can be captured from this PaymentIntent.
* @property null|\Stripe\StripeObject $amount_details
* @property int $amount_received Amount that this PaymentIntent collects.
- * @property null|string|\Stripe\StripeObject $application ID of the Connect application that created the PaymentIntent.
+ * @property null|string|\Stripe\Application $application ID of the Connect application that created the PaymentIntent.
* @property null|int $application_fee_amount The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents use case for connected accounts.
* @property null|\Stripe\StripeObject $automatic_payment_methods Settings to configure compatible payment methods from the Stripe Dashboard
* @property null|int $canceled_at Populated when status
is canceled
, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch.
diff --git a/lib/PaymentLink.php b/lib/PaymentLink.php
index 89763d69d..2c162773a 100644
--- a/lib/PaymentLink.php
+++ b/lib/PaymentLink.php
@@ -16,11 +16,11 @@
* @property bool $active Whether the payment link's url
is active. If false
, customers visiting the URL will be shown a page saying that the link has been deactivated.
* @property \Stripe\StripeObject $after_completion
* @property bool $allow_promotion_codes Whether user redeemable promotion codes are enabled.
- * @property null|string|\Stripe\StripeObject $application The ID of the Connect application that created the Payment Link.
+ * @property null|string|\Stripe\Application $application The ID of the Connect application that created the Payment Link.
* @property null|int $application_fee_amount The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account.
* @property null|float $application_fee_percent This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account.
* @property \Stripe\StripeObject $automatic_tax
- * @property string $billing_address_collection Configuration for collecting the customer's billing address.
+ * @property string $billing_address_collection Configuration for collecting the customer's billing address. Defaults to auto
.
* @property null|\Stripe\StripeObject $consent_collection When set, provides configuration to gather active consent from customers.
* @property string $currency Three-letter ISO currency code, in lowercase. Must be a supported currency.
* @property \Stripe\StripeObject[] $custom_fields Collect additional information from your customer using custom fields. Up to 3 fields are supported.
@@ -33,7 +33,7 @@
* @property \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|string|\Stripe\Account $on_behalf_of The account on behalf of which to charge. See the Connect documentation for details.
* @property null|\Stripe\StripeObject $payment_intent_data Indicates the parameters to be passed to PaymentIntent creation during checkout.
- * @property string $payment_method_collection Configuration for collecting a payment method during checkout.
+ * @property string $payment_method_collection Configuration for collecting a payment method during checkout. Defaults to always
.
* @property null|string[] $payment_method_types The list of payment method types that customers can use. When null
, Stripe will dynamically show relevant payment methods you've enabled in your payment method settings.
* @property \Stripe\StripeObject $phone_number_collection
* @property null|\Stripe\StripeObject $restrictions Settings that restrict the usage of a payment link.
diff --git a/lib/Person.php b/lib/Person.php
index 7df0f2f34..bb5380f7b 100644
--- a/lib/Person.php
+++ b/lib/Person.php
@@ -48,9 +48,6 @@ class Person extends ApiResource
{
const OBJECT_NAME = 'person';
- use ApiOperations\Delete;
- use ApiOperations\Update;
-
const GENDER_FEMALE = 'female';
const GENDER_MALE = 'male';
@@ -61,6 +58,9 @@ class Person extends ApiResource
const VERIFICATION_STATUS_UNVERIFIED = 'unverified';
const VERIFICATION_STATUS_VERIFIED = 'verified';
+ use ApiOperations\Delete;
+ use ApiOperations\Update;
+
/**
* @return string the API URL for this Stripe account reversal
*/
diff --git a/lib/PlatformTaxFee.php b/lib/PlatformTaxFee.php
new file mode 100644
index 000000000..cb9fea7db
--- /dev/null
+++ b/lib/PlatformTaxFee.php
@@ -0,0 +1,17 @@
+ISO currency code, in lowercase. Must be a supported currency.
+ * @property null|string $description An arbitrary string attached to the object. Often useful for displaying to users.
+ */
+class ReserveTransaction extends ApiResource
+{
+ const OBJECT_NAME = 'reserve_transaction';
+}
diff --git a/lib/SetupAttempt.php b/lib/SetupAttempt.php
index 5c20047be..e755171dc 100644
--- a/lib/SetupAttempt.php
+++ b/lib/SetupAttempt.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 null|string|\Stripe\StripeObject $application The value of application on the SetupIntent at the time of this confirmation.
+ * @property null|string|\Stripe\Application $application The value of application on the SetupIntent at the time of this confirmation.
* @property null|bool $attach_to_self If present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
It can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
* @property int $created Time at which the object was created. Measured in seconds since the Unix epoch. * @property null|string|\Stripe\Customer $customer The value of customer on the SetupIntent at the time of this confirmation. diff --git a/lib/SetupIntent.php b/lib/SetupIntent.php index 5bcfa9827..a9762bbe7 100644 --- a/lib/SetupIntent.php +++ b/lib/SetupIntent.php @@ -29,7 +29,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|string|\Stripe\StripeObject $application ID of the Connect application that created the SetupIntent. + * @property null|string|\Stripe\Application $application ID of the Connect application that created the SetupIntent. * @property null|bool $attach_to_selfIf present, the SetupIntent's payment method will be attached to the in-context Stripe Account.
It can only be used for this Stripe Account’s own money movement flows like InboundTransfer and OutboundTransfers. It cannot be set to true when setting up a PaymentMethod for a Customer, and defaults to false when attaching a PaymentMethod to a Customer.
* @property null|\Stripe\StripeObject $automatic_payment_methods Settings for dynamic payment methods compatible with this Setup Intent * @property null|string $cancellation_reason Reason for cancellation of this SetupIntent, one ofabandoned
, requested_by_customer
, or duplicate
.
diff --git a/lib/SourceMandateNotification.php b/lib/SourceMandateNotification.php
new file mode 100644
index 000000000..11960527a
--- /dev/null
+++ b/lib/SourceMandateNotification.php
@@ -0,0 +1,28 @@
+debit_initiated.
+ * @property null|\Stripe\StripeObject $bacs_debit
+ * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
+ * @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 $reason The reason of the mandate notification. Valid reasons are mandate_confirmed
or debit_initiated
.
+ * @property null|\Stripe\StripeObject $sepa_debit
+ * @property \Stripe\Source $source Source
objects allow you to accept a variety of payment methods. They represent a customer's payment instrument, and can be used with the Stripe API just like a Card
object: once chargeable, they can be charged, or can be attached to customers.
Stripe doesn't recommend using the deprecated Sources API. We recommend that you adopt the PaymentMethods API. This newer API provides access to our latest features and payment method types.
Related guides: Sources API and Sources & Customers.
+ * @property string $status The status of the mandate notification. Valid statuses arepending
or submitted
.
+ * @property string $type The type of source this mandate notification is attached to. Should be the source type identifier code for the payment method, such as three_d_secure
.
+ */
+class SourceMandateNotification extends ApiResource
+{
+ const OBJECT_NAME = 'source_mandate_notification';
+}
diff --git a/lib/Subscription.php b/lib/Subscription.php
index fd7df0c7a..61d421e5b 100644
--- a/lib/Subscription.php
+++ b/lib/Subscription.php
@@ -11,7 +11,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|string|\Stripe\StripeObject $application ID of the Connect Application that created the subscription.
+ * @property null|string|\Stripe\Application $application ID of the Connect Application that created the subscription.
* @property null|float $application_fee_percent A non-negative decimal between 0 and 100, with at most two decimal places. This represents the percentage of the subscription invoice total that will be transferred to the application owner's Stripe account.
* @property \Stripe\StripeObject $automatic_tax
* @property int $billing_cycle_anchor The reference point that aligns future billing cycle dates. It sets the day of week for week
intervals, the day of month for month
and year
intervals, and the month of year for year
intervals. The timestamp is in UTC format.
diff --git a/lib/SubscriptionSchedule.php b/lib/SubscriptionSchedule.php
index 7e7877b55..7434abf73 100644
--- a/lib/SubscriptionSchedule.php
+++ b/lib/SubscriptionSchedule.php
@@ -11,7 +11,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|string|\Stripe\StripeObject $application ID of the Connect Application that created the schedule.
+ * @property null|string|\Stripe\Application $application ID of the Connect Application that created the schedule.
* @property null|int $canceled_at Time at which the subscription schedule was canceled. Measured in seconds since the Unix epoch.
* @property null|int $completed_at Time at which the subscription schedule was completed. Measured in seconds since the Unix epoch.
* @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
diff --git a/lib/TaxDeductedAtSource.php b/lib/TaxDeductedAtSource.php
new file mode 100644
index 000000000..93bb8a341
--- /dev/null
+++ b/lib/TaxDeductedAtSource.php
@@ -0,0 +1,17 @@
+ \Stripe\AccountLink::class,
\Stripe\AccountSession::OBJECT_NAME => \Stripe\AccountSession::class,
\Stripe\ApplePayDomain::OBJECT_NAME => \Stripe\ApplePayDomain::class,
+ \Stripe\Application::OBJECT_NAME => \Stripe\Application::class,
\Stripe\ApplicationFee::OBJECT_NAME => \Stripe\ApplicationFee::class,
\Stripe\ApplicationFeeRefund::OBJECT_NAME => \Stripe\ApplicationFeeRefund::class,
\Stripe\Apps\Secret::OBJECT_NAME => \Stripe\Apps\Secret::class,
@@ -34,6 +35,7 @@ class ObjectTypes
\Stripe\Climate\Order::OBJECT_NAME => \Stripe\Climate\Order::class,
\Stripe\Climate\Product::OBJECT_NAME => \Stripe\Climate\Product::class,
\Stripe\Climate\Supplier::OBJECT_NAME => \Stripe\Climate\Supplier::class,
+ \Stripe\ConnectCollectionTransfer::OBJECT_NAME => \Stripe\ConnectCollectionTransfer::class,
\Stripe\CountrySpec::OBJECT_NAME => \Stripe\CountrySpec::class,
\Stripe\Coupon::OBJECT_NAME => \Stripe\Coupon::class,
\Stripe\CreditNote::OBJECT_NAME => \Stripe\CreditNote::class,
@@ -77,6 +79,7 @@ class ObjectTypes
\Stripe\Payout::OBJECT_NAME => \Stripe\Payout::class,
\Stripe\Person::OBJECT_NAME => \Stripe\Person::class,
\Stripe\Plan::OBJECT_NAME => \Stripe\Plan::class,
+ \Stripe\PlatformTaxFee::OBJECT_NAME => \Stripe\PlatformTaxFee::class,
\Stripe\Price::OBJECT_NAME => \Stripe\Price::class,
\Stripe\Product::OBJECT_NAME => \Stripe\Product::class,
\Stripe\PromotionCode::OBJECT_NAME => \Stripe\PromotionCode::class,
@@ -87,12 +90,14 @@ class ObjectTypes
\Stripe\Refund::OBJECT_NAME => \Stripe\Refund::class,
\Stripe\Reporting\ReportRun::OBJECT_NAME => \Stripe\Reporting\ReportRun::class,
\Stripe\Reporting\ReportType::OBJECT_NAME => \Stripe\Reporting\ReportType::class,
+ \Stripe\ReserveTransaction::OBJECT_NAME => \Stripe\ReserveTransaction::class,
\Stripe\Review::OBJECT_NAME => \Stripe\Review::class,
\Stripe\SetupAttempt::OBJECT_NAME => \Stripe\SetupAttempt::class,
\Stripe\SetupIntent::OBJECT_NAME => \Stripe\SetupIntent::class,
\Stripe\ShippingRate::OBJECT_NAME => \Stripe\ShippingRate::class,
\Stripe\Sigma\ScheduledQueryRun::OBJECT_NAME => \Stripe\Sigma\ScheduledQueryRun::class,
\Stripe\Source::OBJECT_NAME => \Stripe\Source::class,
+ \Stripe\SourceMandateNotification::OBJECT_NAME => \Stripe\SourceMandateNotification::class,
\Stripe\SourceTransaction::OBJECT_NAME => \Stripe\SourceTransaction::class,
\Stripe\Subscription::OBJECT_NAME => \Stripe\Subscription::class,
\Stripe\SubscriptionItem::OBJECT_NAME => \Stripe\SubscriptionItem::class,
@@ -104,6 +109,7 @@ class ObjectTypes
\Stripe\Tax\Transaction::OBJECT_NAME => \Stripe\Tax\Transaction::class,
\Stripe\Tax\TransactionLineItem::OBJECT_NAME => \Stripe\Tax\TransactionLineItem::class,
\Stripe\TaxCode::OBJECT_NAME => \Stripe\TaxCode::class,
+ \Stripe\TaxDeductedAtSource::OBJECT_NAME => \Stripe\TaxDeductedAtSource::class,
\Stripe\TaxId::OBJECT_NAME => \Stripe\TaxId::class,
\Stripe\TaxRate::OBJECT_NAME => \Stripe\TaxRate::class,
\Stripe\Terminal\Configuration::OBJECT_NAME => \Stripe\Terminal\Configuration::class,
From 8dc58bab25f222a74d1157d4ca9e9e48451dd0c1 Mon Sep 17 00:00:00 2001
From: Annie Li true
if the object exists in live mode or the value false
if the object exists in test mode.
* @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|\Stripe\StripeObject $multibanco
* @property null|\Stripe\StripeObject $oxxo
* @property null|\Stripe\StripeObject $p24
* @property null|\Stripe\StripeObject $paynow
@@ -89,6 +90,7 @@ class PaymentMethod extends ApiResource
const TYPE_KLARNA = 'klarna';
const TYPE_KONBINI = 'konbini';
const TYPE_LINK = 'link';
+ const TYPE_MULTIBANCO = 'multibanco';
const TYPE_OXXO = 'oxxo';
const TYPE_P24 = 'p24';
const TYPE_PAYNOW = 'paynow';
From ab71ed587856410015e61347b6786b43caddf1b8 Mon Sep 17 00:00:00 2001
From: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
Date: Thu, 14 Mar 2024 18:34:43 +0000
Subject: [PATCH 08/10] Update generated code for v878
---
tests/Stripe/GeneratedExamplesTest.php | 100 +++++++++++++++++++++++++
1 file changed, 100 insertions(+)
diff --git a/tests/Stripe/GeneratedExamplesTest.php b/tests/Stripe/GeneratedExamplesTest.php
index db2afbbb4..59c17b245 100644
--- a/tests/Stripe/GeneratedExamplesTest.php
+++ b/tests/Stripe/GeneratedExamplesTest.php
@@ -1710,6 +1710,67 @@ public function testIssuingDisputesSubmitPost()
static::assertInstanceOf(\Stripe\Issuing\Dispute::class, $result);
}
+ public function testIssuingPersonalizationDesignsGet()
+ {
+ $this->expectsRequest('get', '/v1/issuing/personalization_designs');
+ $result = $this->client->issuing->personalizationDesigns->all([]);
+ static::assertInstanceOf(\Stripe\Collection::class, $result);
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result->data[0]);
+ }
+
+ public function testIssuingPersonalizationDesignsGet2()
+ {
+ $this->expectsRequest(
+ 'get',
+ '/v1/issuing/personalization_designs/pd_xyz'
+ );
+ $result = $this->client->issuing->personalizationDesigns->retrieve(
+ 'pd_xyz',
+ []
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
+ public function testIssuingPersonalizationDesignsPost()
+ {
+ $this->expectsRequest('post', '/v1/issuing/personalization_designs');
+ $result = $this->client->issuing->personalizationDesigns->create([
+ 'physical_bundle' => 'pb_xyz',
+ ]);
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
+ public function testIssuingPersonalizationDesignsPost2()
+ {
+ $this->expectsRequest(
+ 'post',
+ '/v1/issuing/personalization_designs/pd_xyz'
+ );
+ $result = $this->client->issuing->personalizationDesigns->update(
+ 'pd_xyz',
+ []
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
+ public function testIssuingPhysicalBundlesGet()
+ {
+ $this->expectsRequest('get', '/v1/issuing/physical_bundles');
+ $result = $this->client->issuing->physicalBundles->all([]);
+ static::assertInstanceOf(\Stripe\Collection::class, $result);
+ static::assertInstanceOf(\Stripe\Issuing\PhysicalBundle::class, $result->data[0]);
+ }
+
+ public function testIssuingPhysicalBundlesGet2()
+ {
+ $this->expectsRequest('get', '/v1/issuing/physical_bundles/pb_xyz');
+ $result = $this->client->issuing->physicalBundles->retrieve(
+ 'pb_xyz',
+ []
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PhysicalBundle::class, $result);
+ }
+
public function testIssuingTransactionsGet()
{
$this->expectsRequest('get', '/v1/issuing/transactions');
@@ -3766,6 +3827,45 @@ public function testTestHelpersIssuingCardsShippingShipPost()
static::assertInstanceOf(\Stripe\Issuing\Card::class, $result);
}
+ public function testTestHelpersIssuingPersonalizationDesignsActivatePost()
+ {
+ $this->expectsRequest(
+ 'post',
+ '/v1/test_helpers/issuing/personalization_designs/pd_xyz/activate'
+ );
+ $result = $this->client->testHelpers->issuing->personalizationDesigns->activate(
+ 'pd_xyz',
+ []
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
+ public function testTestHelpersIssuingPersonalizationDesignsDeactivatePost()
+ {
+ $this->expectsRequest(
+ 'post',
+ '/v1/test_helpers/issuing/personalization_designs/pd_xyz/deactivate'
+ );
+ $result = $this->client->testHelpers->issuing->personalizationDesigns->deactivate(
+ 'pd_xyz',
+ []
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
+ public function testTestHelpersIssuingPersonalizationDesignsRejectPost()
+ {
+ $this->expectsRequest(
+ 'post',
+ '/v1/test_helpers/issuing/personalization_designs/pd_xyz/reject'
+ );
+ $result = $this->client->testHelpers->issuing->personalizationDesigns->reject(
+ 'pd_xyz',
+ ['rejection_reasons' => ['card_logo' => ['geographic_location']]]
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
public function testTestHelpersIssuingTransactionsCreateForceCapturePost()
{
$this->expectsRequest(
From dcecc0efe1f7a1f4245ed00c3f1e6a5c4bafd4b7 Mon Sep 17 00:00:00 2001
From: "stripe-openapi[bot]"
<105521251+stripe-openapi[bot]@users.noreply.github.com>
Date: Thu, 14 Mar 2024 12:09:50 -0700
Subject: [PATCH 09/10] Update generated code (#1660)
* Update generated code for v878
---------
Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com>
---
OPENAPI_VERSION | 2 +-
init.php | 5 +
lib/Issuing/Card.php | 1 +
lib/Issuing/PersonalizationDesign.php | 37 +++++
lib/Issuing/PhysicalBundle.php | 31 ++++
lib/Service/Issuing/IssuingServiceFactory.php | 4 +
.../Issuing/PersonalizationDesignService.php | 78 ++++++++++
lib/Service/Issuing/PhysicalBundleService.php | 46 ++++++
.../Issuing/IssuingServiceFactory.php | 2 +
.../Issuing/PersonalizationDesignService.php | 65 ++++++++
lib/Util/ObjectTypes.php | 2 +
tests/Stripe/GeneratedExamplesTest.php | 146 ++++++++++++++++++
12 files changed, 418 insertions(+), 1 deletion(-)
create mode 100644 lib/Issuing/PersonalizationDesign.php
create mode 100644 lib/Issuing/PhysicalBundle.php
create mode 100644 lib/Service/Issuing/PersonalizationDesignService.php
create mode 100644 lib/Service/Issuing/PhysicalBundleService.php
create mode 100644 lib/Service/TestHelpers/Issuing/PersonalizationDesignService.php
diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION
index adddc73de..0963e32fc 100644
--- a/OPENAPI_VERSION
+++ b/OPENAPI_VERSION
@@ -1 +1 @@
-v855
\ No newline at end of file
+v878
\ No newline at end of file
diff --git a/init.php b/init.php
index bbe7551c8..8413ea0d2 100644
--- a/init.php
+++ b/init.php
@@ -133,6 +133,8 @@
require __DIR__ . '/lib/Issuing/Card.php';
require __DIR__ . '/lib/Issuing/Cardholder.php';
require __DIR__ . '/lib/Issuing/Dispute.php';
+require __DIR__ . '/lib/Issuing/PersonalizationDesign.php';
+require __DIR__ . '/lib/Issuing/PhysicalBundle.php';
require __DIR__ . '/lib/Issuing/Token.php';
require __DIR__ . '/lib/Issuing/Transaction.php';
require __DIR__ . '/lib/LineItem.php';
@@ -204,6 +206,8 @@
require __DIR__ . '/lib/Service/Issuing/CardholderService.php';
require __DIR__ . '/lib/Service/Issuing/DisputeService.php';
require __DIR__ . '/lib/Service/Issuing/IssuingServiceFactory.php';
+require __DIR__ . '/lib/Service/Issuing/PersonalizationDesignService.php';
+require __DIR__ . '/lib/Service/Issuing/PhysicalBundleService.php';
require __DIR__ . '/lib/Service/Issuing/TokenService.php';
require __DIR__ . '/lib/Service/Issuing/TransactionService.php';
require __DIR__ . '/lib/Service/MandateService.php';
@@ -253,6 +257,7 @@
require __DIR__ . '/lib/Service/TestHelpers/Issuing/AuthorizationService.php';
require __DIR__ . '/lib/Service/TestHelpers/Issuing/CardService.php';
require __DIR__ . '/lib/Service/TestHelpers/Issuing/IssuingServiceFactory.php';
+require __DIR__ . '/lib/Service/TestHelpers/Issuing/PersonalizationDesignService.php';
require __DIR__ . '/lib/Service/TestHelpers/Issuing/TransactionService.php';
require __DIR__ . '/lib/Service/TestHelpers/RefundService.php';
require __DIR__ . '/lib/Service/TestHelpers/Terminal/ReaderService.php';
diff --git a/lib/Issuing/Card.php b/lib/Issuing/Card.php
index 62c8ef995..d18a07539 100644
--- a/lib/Issuing/Card.php
+++ b/lib/Issuing/Card.php
@@ -22,6 +22,7 @@
* @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 \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|string $number The full unredacted card number. For security reasons, this is only available for virtual cards, and will be omitted unless you explicitly request it with the expand
parameter. Additionally, it's only available via the "Retrieve a card" endpoint, not via "List all cards" or any other endpoint.
+ * @property null|string|\Stripe\Issuing\PersonalizationDesign $personalization_design The personalization design object belonging to this card.
* @property null|string|\Stripe\Issuing\Card $replaced_by The latest card that replaces this card, if any.
* @property null|string|\Stripe\Issuing\Card $replacement_for The card this card replaces, if any.
* @property null|string $replacement_reason The reason why the previous card needed to be replaced.
diff --git a/lib/Issuing/PersonalizationDesign.php b/lib/Issuing/PersonalizationDesign.php
new file mode 100644
index 000000000..74af892aa
--- /dev/null
+++ b/lib/Issuing/PersonalizationDesign.php
@@ -0,0 +1,37 @@
+purpose value of issuing_logo
.
+ * @property null|\Stripe\StripeObject $carrier_text Hash containing carrier text, for use with physical bundles that support carrier text.
+ * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
+ * @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 $lookup_key A lookup key used to retrieve personalization designs dynamically from a static string. This may be up to 200 characters.
+ * @property \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|string $name Friendly display name.
+ * @property string|\Stripe\Issuing\PhysicalBundle $physical_bundle The physical bundle object belonging to this personalization design.
+ * @property \Stripe\StripeObject $preferences
+ * @property \Stripe\StripeObject $rejection_reasons
+ * @property string $status Whether this personalization design can be used to create cards.
+ */
+class PersonalizationDesign extends \Stripe\ApiResource
+{
+ const OBJECT_NAME = 'issuing.personalization_design';
+
+ use \Stripe\ApiOperations\All;
+ use \Stripe\ApiOperations\Create;
+ use \Stripe\ApiOperations\Retrieve;
+ use \Stripe\ApiOperations\Update;
+
+ const STATUS_ACTIVE = 'active';
+ const STATUS_INACTIVE = 'inactive';
+ const STATUS_REJECTED = 'rejected';
+ const STATUS_REVIEW = 'review';
+}
diff --git a/lib/Issuing/PhysicalBundle.php b/lib/Issuing/PhysicalBundle.php
new file mode 100644
index 000000000..3a978cba1
--- /dev/null
+++ b/lib/Issuing/PhysicalBundle.php
@@ -0,0 +1,31 @@
+true if the object exists in live mode or the value false
if the object exists in test mode.
+ * @property string $name Friendly display name.
+ * @property string $status Whether this physical bundle can be used to create cards.
+ * @property string $type Whether this physical bundle is a standard Stripe offering or custom-made for you.
+ */
+class PhysicalBundle extends \Stripe\ApiResource
+{
+ const OBJECT_NAME = 'issuing.physical_bundle';
+
+ use \Stripe\ApiOperations\All;
+ use \Stripe\ApiOperations\Retrieve;
+
+ const STATUS_ACTIVE = 'active';
+ const STATUS_INACTIVE = 'inactive';
+ const STATUS_REVIEW = 'review';
+
+ const TYPE_CUSTOM = 'custom';
+ const TYPE_STANDARD = 'standard';
+}
diff --git a/lib/Service/Issuing/IssuingServiceFactory.php b/lib/Service/Issuing/IssuingServiceFactory.php
index b87566c07..852351d2b 100644
--- a/lib/Service/Issuing/IssuingServiceFactory.php
+++ b/lib/Service/Issuing/IssuingServiceFactory.php
@@ -11,6 +11,8 @@
* @property CardholderService $cardholders
* @property CardService $cards
* @property DisputeService $disputes
+ * @property PersonalizationDesignService $personalizationDesigns
+ * @property PhysicalBundleService $physicalBundles
* @property TokenService $tokens
* @property TransactionService $transactions
*/
@@ -24,6 +26,8 @@ class IssuingServiceFactory extends \Stripe\Service\AbstractServiceFactory
'cardholders' => CardholderService::class,
'cards' => CardService::class,
'disputes' => DisputeService::class,
+ 'personalizationDesigns' => PersonalizationDesignService::class,
+ 'physicalBundles' => PhysicalBundleService::class,
'tokens' => TokenService::class,
'transactions' => TransactionService::class,
];
diff --git a/lib/Service/Issuing/PersonalizationDesignService.php b/lib/Service/Issuing/PersonalizationDesignService.php
new file mode 100644
index 000000000..7c35f6478
--- /dev/null
+++ b/lib/Service/Issuing/PersonalizationDesignService.php
@@ -0,0 +1,78 @@
+
+ */
+ public function all($params = null, $opts = null)
+ {
+ return $this->requestCollection('get', '/v1/issuing/personalization_designs', $params, $opts);
+ }
+
+ /**
+ * Creates a personalization design object.
+ *
+ * @param null|array $params
+ * @param null|RequestOptionsArray|\Stripe\Util\RequestOptions $opts
+ *
+ * @throws \Stripe\Exception\ApiErrorException if the request fails
+ *
+ * @return \Stripe\Issuing\PersonalizationDesign
+ */
+ public function create($params = null, $opts = null)
+ {
+ return $this->request('post', '/v1/issuing/personalization_designs', $params, $opts);
+ }
+
+ /**
+ * Retrieves a personalization design object.
+ *
+ * @param string $id
+ * @param null|array $params
+ * @param null|RequestOptionsArray|\Stripe\Util\RequestOptions $opts
+ *
+ * @throws \Stripe\Exception\ApiErrorException if the request fails
+ *
+ * @return \Stripe\Issuing\PersonalizationDesign
+ */
+ public function retrieve($id, $params = null, $opts = null)
+ {
+ return $this->request('get', $this->buildPath('/v1/issuing/personalization_designs/%s', $id), $params, $opts);
+ }
+
+ /**
+ * Updates a card personalization object.
+ *
+ * @param string $id
+ * @param null|array $params
+ * @param null|RequestOptionsArray|\Stripe\Util\RequestOptions $opts
+ *
+ * @throws \Stripe\Exception\ApiErrorException if the request fails
+ *
+ * @return \Stripe\Issuing\PersonalizationDesign
+ */
+ public function update($id, $params = null, $opts = null)
+ {
+ return $this->request('post', $this->buildPath('/v1/issuing/personalization_designs/%s', $id), $params, $opts);
+ }
+}
diff --git a/lib/Service/Issuing/PhysicalBundleService.php b/lib/Service/Issuing/PhysicalBundleService.php
new file mode 100644
index 000000000..558abffdd
--- /dev/null
+++ b/lib/Service/Issuing/PhysicalBundleService.php
@@ -0,0 +1,46 @@
+
+ */
+ public function all($params = null, $opts = null)
+ {
+ return $this->requestCollection('get', '/v1/issuing/physical_bundles', $params, $opts);
+ }
+
+ /**
+ * Retrieves a physical bundle object.
+ *
+ * @param string $id
+ * @param null|array $params
+ * @param null|RequestOptionsArray|\Stripe\Util\RequestOptions $opts
+ *
+ * @throws \Stripe\Exception\ApiErrorException if the request fails
+ *
+ * @return \Stripe\Issuing\PhysicalBundle
+ */
+ public function retrieve($id, $params = null, $opts = null)
+ {
+ return $this->request('get', $this->buildPath('/v1/issuing/physical_bundles/%s', $id), $params, $opts);
+ }
+}
diff --git a/lib/Service/TestHelpers/Issuing/IssuingServiceFactory.php b/lib/Service/TestHelpers/Issuing/IssuingServiceFactory.php
index e15a7c87c..c6224144a 100644
--- a/lib/Service/TestHelpers/Issuing/IssuingServiceFactory.php
+++ b/lib/Service/TestHelpers/Issuing/IssuingServiceFactory.php
@@ -9,6 +9,7 @@
*
* @property AuthorizationService $authorizations
* @property CardService $cards
+ * @property PersonalizationDesignService $personalizationDesigns
* @property TransactionService $transactions
*/
class IssuingServiceFactory extends \Stripe\Service\AbstractServiceFactory
@@ -19,6 +20,7 @@ class IssuingServiceFactory extends \Stripe\Service\AbstractServiceFactory
private static $classMap = [
'authorizations' => AuthorizationService::class,
'cards' => CardService::class,
+ 'personalizationDesigns' => PersonalizationDesignService::class,
'transactions' => TransactionService::class,
];
diff --git a/lib/Service/TestHelpers/Issuing/PersonalizationDesignService.php b/lib/Service/TestHelpers/Issuing/PersonalizationDesignService.php
new file mode 100644
index 000000000..e9051d729
--- /dev/null
+++ b/lib/Service/TestHelpers/Issuing/PersonalizationDesignService.php
@@ -0,0 +1,65 @@
+status of the specified testmode personalization design
+ * object to active
.
+ *
+ * @param string $id
+ * @param null|array $params
+ * @param null|RequestOptionsArray|\Stripe\Util\RequestOptions $opts
+ *
+ * @throws \Stripe\Exception\ApiErrorException if the request fails
+ *
+ * @return \Stripe\Issuing\PersonalizationDesign
+ */
+ public function activate($id, $params = null, $opts = null)
+ {
+ return $this->request('post', $this->buildPath('/v1/test_helpers/issuing/personalization_designs/%s/activate', $id), $params, $opts);
+ }
+
+ /**
+ * Updates the status
of the specified testmode personalization design
+ * object to inactive
.
+ *
+ * @param string $id
+ * @param null|array $params
+ * @param null|RequestOptionsArray|\Stripe\Util\RequestOptions $opts
+ *
+ * @throws \Stripe\Exception\ApiErrorException if the request fails
+ *
+ * @return \Stripe\Issuing\PersonalizationDesign
+ */
+ public function deactivate($id, $params = null, $opts = null)
+ {
+ return $this->request('post', $this->buildPath('/v1/test_helpers/issuing/personalization_designs/%s/deactivate', $id), $params, $opts);
+ }
+
+ /**
+ * Updates the status
of the specified testmode personalization design
+ * object to rejected
.
+ *
+ * @param string $id
+ * @param null|array $params
+ * @param null|RequestOptionsArray|\Stripe\Util\RequestOptions $opts
+ *
+ * @throws \Stripe\Exception\ApiErrorException if the request fails
+ *
+ * @return \Stripe\Issuing\PersonalizationDesign
+ */
+ public function reject($id, $params = null, $opts = null)
+ {
+ return $this->request('post', $this->buildPath('/v1/test_helpers/issuing/personalization_designs/%s/reject', $id), $params, $opts);
+ }
+}
diff --git a/lib/Util/ObjectTypes.php b/lib/Util/ObjectTypes.php
index 82dfd2580..953430d0a 100644
--- a/lib/Util/ObjectTypes.php
+++ b/lib/Util/ObjectTypes.php
@@ -66,6 +66,8 @@ class ObjectTypes
\Stripe\Issuing\Card::OBJECT_NAME => \Stripe\Issuing\Card::class,
\Stripe\Issuing\Cardholder::OBJECT_NAME => \Stripe\Issuing\Cardholder::class,
\Stripe\Issuing\Dispute::OBJECT_NAME => \Stripe\Issuing\Dispute::class,
+ \Stripe\Issuing\PersonalizationDesign::OBJECT_NAME => \Stripe\Issuing\PersonalizationDesign::class,
+ \Stripe\Issuing\PhysicalBundle::OBJECT_NAME => \Stripe\Issuing\PhysicalBundle::class,
\Stripe\Issuing\Token::OBJECT_NAME => \Stripe\Issuing\Token::class,
\Stripe\Issuing\Transaction::OBJECT_NAME => \Stripe\Issuing\Transaction::class,
\Stripe\LineItem::OBJECT_NAME => \Stripe\LineItem::class,
diff --git a/tests/Stripe/GeneratedExamplesTest.php b/tests/Stripe/GeneratedExamplesTest.php
index 60bc02bb1..de9c2ef01 100644
--- a/tests/Stripe/GeneratedExamplesTest.php
+++ b/tests/Stripe/GeneratedExamplesTest.php
@@ -792,6 +792,20 @@ public function testCustomersCashBalancePost()
static::assertInstanceOf(\Stripe\CashBalance::class, $result);
}
+ public function testCustomersCashBalanceTransactionsGet()
+ {
+ $this->expectsRequest(
+ 'get',
+ '/v1/customers/cus_123/cash_balance_transactions'
+ );
+ $result = $this->client->customers->allCashBalanceTransactions(
+ 'cus_123',
+ ['limit' => 3]
+ );
+ static::assertInstanceOf(\Stripe\Collection::class, $result);
+ static::assertInstanceOf(\Stripe\CustomerCashBalanceTransaction::class, $result->data[0]);
+ }
+
public function testCustomersDelete()
{
$this->expectsRequest('delete', '/v1/customers/cus_xxxxxxxxxxxxx');
@@ -1696,6 +1710,67 @@ public function testIssuingDisputesSubmitPost()
static::assertInstanceOf(\Stripe\Issuing\Dispute::class, $result);
}
+ public function testIssuingPersonalizationDesignsGet()
+ {
+ $this->expectsRequest('get', '/v1/issuing/personalization_designs');
+ $result = $this->client->issuing->personalizationDesigns->all([]);
+ static::assertInstanceOf(\Stripe\Collection::class, $result);
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result->data[0]);
+ }
+
+ public function testIssuingPersonalizationDesignsGet2()
+ {
+ $this->expectsRequest(
+ 'get',
+ '/v1/issuing/personalization_designs/pd_xyz'
+ );
+ $result = $this->client->issuing->personalizationDesigns->retrieve(
+ 'pd_xyz',
+ []
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
+ public function testIssuingPersonalizationDesignsPost()
+ {
+ $this->expectsRequest('post', '/v1/issuing/personalization_designs');
+ $result = $this->client->issuing->personalizationDesigns->create([
+ 'physical_bundle' => 'pb_xyz',
+ ]);
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
+ public function testIssuingPersonalizationDesignsPost2()
+ {
+ $this->expectsRequest(
+ 'post',
+ '/v1/issuing/personalization_designs/pd_xyz'
+ );
+ $result = $this->client->issuing->personalizationDesigns->update(
+ 'pd_xyz',
+ []
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
+ public function testIssuingPhysicalBundlesGet()
+ {
+ $this->expectsRequest('get', '/v1/issuing/physical_bundles');
+ $result = $this->client->issuing->physicalBundles->all([]);
+ static::assertInstanceOf(\Stripe\Collection::class, $result);
+ static::assertInstanceOf(\Stripe\Issuing\PhysicalBundle::class, $result->data[0]);
+ }
+
+ public function testIssuingPhysicalBundlesGet2()
+ {
+ $this->expectsRequest('get', '/v1/issuing/physical_bundles/pb_xyz');
+ $result = $this->client->issuing->physicalBundles->retrieve(
+ 'pb_xyz',
+ []
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PhysicalBundle::class, $result);
+ }
+
public function testIssuingTransactionsGet()
{
$this->expectsRequest('get', '/v1/issuing/transactions');
@@ -3145,6 +3220,38 @@ public function testTaxCodesGet2()
static::assertInstanceOf(\Stripe\TaxCode::class, $result);
}
+ public function testTaxIdsDelete()
+ {
+ $this->expectsRequest('delete', '/v1/tax_ids/taxid_123');
+ $result = $this->client->taxIds->delete('taxid_123', []);
+ static::assertInstanceOf(\Stripe\TaxId::class, $result);
+ }
+
+ public function testTaxIdsGet()
+ {
+ $this->expectsRequest('get', '/v1/tax_ids');
+ $result = $this->client->taxIds->all([]);
+ static::assertInstanceOf(\Stripe\Collection::class, $result);
+ static::assertInstanceOf(\Stripe\TaxId::class, $result->data[0]);
+ }
+
+ public function testTaxIdsGet2()
+ {
+ $this->expectsRequest('get', '/v1/tax_ids/taxid_123');
+ $result = $this->client->taxIds->retrieve('taxid_123', []);
+ static::assertInstanceOf(\Stripe\TaxId::class, $result);
+ }
+
+ public function testTaxIdsPost()
+ {
+ $this->expectsRequest('post', '/v1/tax_ids');
+ $result = $this->client->taxIds->create([
+ 'type' => 'eu_vat',
+ 'value' => '123',
+ ]);
+ static::assertInstanceOf(\Stripe\TaxId::class, $result);
+ }
+
public function testTaxRatesGet()
{
$this->expectsRequest('get', '/v1/tax_rates');
@@ -3691,6 +3798,45 @@ public function testTestHelpersIssuingCardsShippingShipPost()
static::assertInstanceOf(\Stripe\Issuing\Card::class, $result);
}
+ public function testTestHelpersIssuingPersonalizationDesignsActivatePost()
+ {
+ $this->expectsRequest(
+ 'post',
+ '/v1/test_helpers/issuing/personalization_designs/pd_xyz/activate'
+ );
+ $result = $this->client->testHelpers->issuing->personalizationDesigns->activate(
+ 'pd_xyz',
+ []
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
+ public function testTestHelpersIssuingPersonalizationDesignsDeactivatePost()
+ {
+ $this->expectsRequest(
+ 'post',
+ '/v1/test_helpers/issuing/personalization_designs/pd_xyz/deactivate'
+ );
+ $result = $this->client->testHelpers->issuing->personalizationDesigns->deactivate(
+ 'pd_xyz',
+ []
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
+ public function testTestHelpersIssuingPersonalizationDesignsRejectPost()
+ {
+ $this->expectsRequest(
+ 'post',
+ '/v1/test_helpers/issuing/personalization_designs/pd_xyz/reject'
+ );
+ $result = $this->client->testHelpers->issuing->personalizationDesigns->reject(
+ 'pd_xyz',
+ ['rejection_reasons' => ['card_logo' => ['geographic_location']]]
+ );
+ static::assertInstanceOf(\Stripe\Issuing\PersonalizationDesign::class, $result);
+ }
+
public function testTestHelpersIssuingTransactionsCreateForceCapturePost()
{
$this->expectsRequest(
From d569265e79dc82329dadea1b1088a0a29c7a8a76 Mon Sep 17 00:00:00 2001
From: Ramya Rao