• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

stripe / stripe-php / 9308533534

30 May 2024 08:07PM UTC coverage: 65.24% (-0.9%) from 66.176%
9308533534

push

github

web-flow
Added PHPDocs for `create`, `update`, `delete`, `all`, `retrieve` methods after moving them out of traits.  (#1701)

* Demagiced crudl operation

* Improvements from codegen#1452

* Updated override to fix indents

1080 of 1682 new or added lines in 106 files covered. (64.21%)

15 existing lines in 3 files now uncovered.

3444 of 5279 relevant lines covered (65.24%)

2.29 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/lib/ConfirmationToken.php
1
<?php
2

3
// File generated from our OpenAPI spec
4

5
namespace Stripe;
6

7
/**
8
 * ConfirmationTokens help transport client side data collected by Stripe JS over
9
 * to your server for confirming a PaymentIntent or SetupIntent. If the confirmation
10
 * is successful, values present on the ConfirmationToken are written onto the Intent.
11
 *
12
 * To learn more about how to use ConfirmationToken, visit the related guides:
13
 * - <a href="https://stripe.com/docs/payments/finalize-payments-on-the-server">Finalize payments on the server</a>
14
 * - <a href="https://stripe.com/docs/payments/build-a-two-step-confirmation">Build two-step confirmation</a>.
15
 *
16
 * @property string $id Unique identifier for the object.
17
 * @property string $object String representing the object's type. Objects of the same type share the same value.
18
 * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
19
 * @property null|int $expires_at Time at which this ConfirmationToken expires and can no longer be used to confirm a PaymentIntent or SetupIntent.
20
 * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
21
 * @property null|\Stripe\StripeObject $mandate_data Data used for generating a Mandate.
22
 * @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.
23
 * @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.
24
 * @property null|string $return_url Return URL used to confirm the Intent.
25
 * @property null|string $setup_future_usage <p>Indicates that you intend to make future payments with this ConfirmationToken's payment method.</p><p>The presence of this property will <a href="https://stripe.com/docs/payments/save-during-payment">attach the payment method</a> to the PaymentIntent's Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete.</p>
26
 * @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.
27
 * @property null|\Stripe\StripeObject $shipping Shipping information collected on this ConfirmationToken.
28
 * @property bool $use_stripe_sdk Indicates whether the Stripe SDK is used to handle confirmation flow. Defaults to <code>true</code> on ConfirmationToken.
29
 */
30
class ConfirmationToken extends ApiResource
31
{
32
    const OBJECT_NAME = 'confirmation_token';
33

34
    const SETUP_FUTURE_USAGE_OFF_SESSION = 'off_session';
35
    const SETUP_FUTURE_USAGE_ON_SESSION = 'on_session';
36

37
    /**
38
     * Retrieves an existing ConfirmationToken object.
39
     *
40
     * @param array|string $id the ID of the API resource to retrieve, or an options array containing an `id` key
41
     * @param null|array|string $opts
42
     *
43
     * @throws \Stripe\Exception\ApiErrorException if the request fails
44
     *
45
     * @return \Stripe\ConfirmationToken
46
     */
NEW
47
    public static function retrieve($id, $opts = null)
×
48
    {
NEW
49
        $opts = \Stripe\Util\RequestOptions::parse($opts);
×
NEW
50
        $instance = new static($id, $opts);
×
NEW
51
        $instance->refresh();
×
52

NEW
53
        return $instance;
×
54
    }
55
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc