PaymentIntent
class PaymentIntent extends Resource implements PaymentIntentInterface
A PaymentIntent tracks the process of collecting a payment from your customer.
We recommend that you create exactly one PaymentIntent for each order or customer session in your system. You can reference the PaymentIntent later to see the history of payment attempts for a particular session.
Traits
Properties
string | $id | A unique identifier for the resource. | from Resource |
protected mixed | $response | A response from Stripe. | from Resource |
Methods
Creates a PaymentIntent object.
Confirm that your customer intends to pay with current or provided source.
Capture the funds of an existing uncaptured PaymentIntent where required_action="requires_capture".
A PaymentIntent object can be canceled when it is in one of these statues: requires_source, requires_capture, requires_confirmation, or requires_source_action.
No description
Details
in Resource at line 29
string
getId()
Returns the unique identifier for this resource.
in Resource at line 39
mixed
getResponse()
Returns the raw Stripe response.
in Resource at line 47
protected void
setProperties()
Set the response data as properties on the class.
in ListAll at line 21
ListAll
listAll(array $arguments = [])
List all the resources.
This will list all of the resources from which this trait belongs to. It will then return itself, so you can method chain it, or reuse the same instantiation.
at line 36
PaymentIntentInterface
create(array $allowedSourceTypes, int $amount, array $arguments = [], string $key = null, string $currency = 'usd')
Creates a PaymentIntent object.
at line 58
PaymentIntentInterface
confirm(string $id, array $arguments = [])
Confirm that your customer intends to pay with current or provided source.
Upon confirmation, the PaymentIntent will attempt to initiate a payment.
at line 77
PaymentIntentInterface
capture(string $id, array $arguments = [])
Capture the funds of an existing uncaptured PaymentIntent where required_action="requires_capture".
at line 97
PaymentIntentInterface
cancel(string $id, array $arguments = [])
A PaymentIntent object can be canceled when it is in one of these statues: requires_source, requires_capture, requires_confirmation, or requires_source_action.