PaymentRequestType.recurring constructor

  1. @JsonSerializable(explicitToJson: true)
  2. @FreezedUnionValue('Recurring')
const PaymentRequestType.recurring({
  1. required String description,
  2. required String managementUrl,
  3. required ImmediateCartSummaryItem billing,
  4. ImmediateCartSummaryItem? trialBilling,
  5. String? billingAgreement,
  6. String? tokenNotificationURL,
})

Use this for a recurring payment

For example a subscription

Implementation

@JsonSerializable(explicitToJson: true)
@FreezedUnionValue('Recurring')

/// Use this for a recurring payment
///
/// For example a subscription
const factory PaymentRequestType.recurring({
  /// Description that you provide to the recurring payment.
  ///
  /// Apple will display this in the sheet
  required String description,

  /// A URL to web page where the user can update or delete the payment method for recurring
  required String managementUrl,

  /// The regular billing cycle for the payment, including start end dates, interval and count.
  required ImmediateCartSummaryItem billing,

  /// Same as the billing property but related to trial period.
  ImmediateCartSummaryItem? trialBilling,

  /// A localized billing agreement that Apple displays to user before authorizing the payment
  String? billingAgreement,

  /// A URL you provide to receive life cycle notifications from Apple pay servers about the merchant token for recurring payment.
  ///
  /// For more info see receiving and handling merchant token notifications
  String? tokenNotificationURL,
}) = _PaymentRequestTypeRecurring;