PaymentIntent constructor
- @JsonSerializable(explicitToJson: true)
const
PaymentIntent(
{ - required String id,
- required num amount,
- required String created,
- required String currency,
- required PaymentIntentsStatus status,
- required String clientSecret,
- required bool livemode,
- required CaptureMethod captureMethod,
- required ConfirmationMethod confirmationMethod,
- String? paymentMethodId,
- String? description,
- String? receiptEmail,
- String? canceledAt,
- NextAction? nextAction,
- ShippingDetails? shipping,
- MandateData? mandateData,
- String? latestCharge,
})
Implementation
@JsonSerializable(explicitToJson: true)
const factory PaymentIntent({
/// Unique identifier.
required String id,
/// Amount that will be collected in the payment intent.
required num amount,
/// Timestamp since epoch that represents the time the intent is created.
required String created,
/// The three letter ISO 4217 code for the currency.
required String currency,
/// Current status of the intent.
required PaymentIntentsStatus status,
/// The client is secret is used for handling the payment from the Client side.
required String clientSecret,
/// Determines whether the intent is in live mode or in test mode.
required bool livemode,
/// How the funds will be caputure from the customer's account.
required CaptureMethod captureMethod,
/// Method of how the payment will be confirmed.
required ConfirmationMethod confirmationMethod,
/// Id of the payment method used in this intent.
String? paymentMethodId,
/// Localized description that provides additional context to users.
String? description,
/// Email address where the receipt will be send to.
String? receiptEmail,
/// Timestamp since epoch when the intent is cancelled.
String? canceledAt,
/// Additional action that needs to be taken in order to complete a payment
/// using the provided resource.
NextAction? nextAction,
/// Shipping information of the payment intent.
ShippingDetails? shipping,
/// Mandata data for this paymentintent.
MandateData? mandateData,
/// The latest charge created by this payment intent.
///
/// This field is only available on stripe web.
String? latestCharge,
}) = _PaymentIntent;