diff --git a/OPENAPI_VERSION b/OPENAPI_VERSION
index ca2b1285d..8fc461e62 100644
--- a/OPENAPI_VERSION
+++ b/OPENAPI_VERSION
@@ -1 +1 @@
-v525
\ No newline at end of file
+v526
\ No newline at end of file
diff --git a/init.php b/init.php
index 648fa776f..d67b7d407 100644
--- a/init.php
+++ b/init.php
@@ -99,6 +99,7 @@
require __DIR__ . '/lib/Charge.php';
require __DIR__ . '/lib/Checkout/Session.php';
require __DIR__ . '/lib/Collection.php';
+require __DIR__ . '/lib/ConfirmationToken.php';
require __DIR__ . '/lib/CountrySpec.php';
require __DIR__ . '/lib/Coupon.php';
require __DIR__ . '/lib/CreditNote.php';
@@ -184,6 +185,7 @@
require __DIR__ . '/lib/Service/ChargeService.php';
require __DIR__ . '/lib/Service/Checkout/CheckoutServiceFactory.php';
require __DIR__ . '/lib/Service/Checkout/SessionService.php';
+require __DIR__ . '/lib/Service/ConfirmationTokenService.php';
require __DIR__ . '/lib/Service/CoreServiceFactory.php';
require __DIR__ . '/lib/Service/CountrySpecService.php';
require __DIR__ . '/lib/Service/CouponService.php';
diff --git a/lib/ConfirmationToken.php b/lib/ConfirmationToken.php
new file mode 100644
index 000000000..5d6a43b91
--- /dev/null
+++ b/lib/ConfirmationToken.php
@@ -0,0 +1,35 @@
+true if the object exists in live mode or the value false
if the object exists in test mode.
+ * @property null|\Stripe\StripeObject $mandate_data Data used for generating a Mandate.
+ * @property null|string $payment_intent ID of the PaymentIntent that this ConfirmationToken was used to confirm, or null if this ConfirmationToken has not yet been used.
+ * @property null|string|\Stripe\PaymentMethod $payment_method ID of an existing PaymentMethod.
+ * @property null|\Stripe\StripeObject $payment_method_preview Payment details collected by the Payment Element, used to create a PaymentMethod when a PaymentIntent or SetupIntent is confirmed with this ConfirmationToken.
+ * @property null|string $return_url Return URL used to confirm the Intent.
+ * @property null|string $setup_future_usage
Indicates that you intend to make future payments with this ConfirmationToken's payment method.
The presence of this property will attach the payment method to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.
+ * @property null|string $setup_intent ID of the SetupIntent that this ConfirmationToken was used to confirm, or null if this ConfirmationToken has not yet been used. + * @property null|\Stripe\StripeObject $shipping Shipping information collected on this ConfirmationToken. + */ +class ConfirmationToken extends ApiResource +{ + const OBJECT_NAME = 'confirmation_token'; + + use ApiOperations\Retrieve; + + const SETUP_FUTURE_USAGE_OFF_SESSION = 'off_session'; + const SETUP_FUTURE_USAGE_ON_SESSION = 'on_session'; +} diff --git a/lib/Service/ConfirmationTokenService.php b/lib/Service/ConfirmationTokenService.php new file mode 100644 index 000000000..2f40acc71 --- /dev/null +++ b/lib/Service/ConfirmationTokenService.php @@ -0,0 +1,24 @@ +request('get', $this->buildPath('/v1/confirmation_tokens/%s', $id), $params, $opts); + } +} diff --git a/lib/Service/CoreServiceFactory.php b/lib/Service/CoreServiceFactory.php index 277d56537..ca21a5463 100644 --- a/lib/Service/CoreServiceFactory.php +++ b/lib/Service/CoreServiceFactory.php @@ -19,6 +19,7 @@ * @property Capital\CapitalServiceFactory $capital * @property ChargeService $charges * @property Checkout\CheckoutServiceFactory $checkout + * @property ConfirmationTokenService $confirmationTokens * @property CountrySpecService $countrySpecs * @property CouponService $coupons * @property CreditNoteService $creditNotes @@ -92,6 +93,7 @@ class CoreServiceFactory extends \Stripe\Service\AbstractServiceFactory 'capital' => Capital\CapitalServiceFactory::class, 'charges' => ChargeService::class, 'checkout' => Checkout\CheckoutServiceFactory::class, + 'confirmationTokens' => ConfirmationTokenService::class, 'countrySpecs' => CountrySpecService::class, 'coupons' => CouponService::class, 'creditNotes' => CreditNoteService::class, diff --git a/lib/StripeClient.php b/lib/StripeClient.php index 1d408d843..fee8bd0d8 100644 --- a/lib/StripeClient.php +++ b/lib/StripeClient.php @@ -19,6 +19,7 @@ * @property \Stripe\Service\Capital\CapitalServiceFactory $capital * @property \Stripe\Service\ChargeService $charges * @property \Stripe\Service\Checkout\CheckoutServiceFactory $checkout + * @property \Stripe\Service\ConfirmationTokenService $confirmationTokens * @property \Stripe\Service\CountrySpecService $countrySpecs * @property \Stripe\Service\CouponService $coupons * @property \Stripe\Service\CreditNoteService $creditNotes diff --git a/lib/Util/ObjectTypes.php b/lib/Util/ObjectTypes.php index 6657a61ce..6eca475a3 100644 --- a/lib/Util/ObjectTypes.php +++ b/lib/Util/ObjectTypes.php @@ -31,6 +31,7 @@ class ObjectTypes \Stripe\Charge::OBJECT_NAME => \Stripe\Charge::class, \Stripe\Checkout\Session::OBJECT_NAME => \Stripe\Checkout\Session::class, \Stripe\Collection::OBJECT_NAME => \Stripe\Collection::class, + \Stripe\ConfirmationToken::OBJECT_NAME => \Stripe\ConfirmationToken::class, \Stripe\CountrySpec::OBJECT_NAME => \Stripe\CountrySpec::class, \Stripe\Coupon::OBJECT_NAME => \Stripe\Coupon::class, \Stripe\CreditNote::OBJECT_NAME => \Stripe\CreditNote::class,