ApplePayConfiguration
public struct ApplePayConfiguration
Configuration related to Apple Pay
-
The Apple Merchant Identifier to use during Apple Pay transactions. To obtain one, see https://stripe.com/docs/apple-pay#native
Declaration
Swift
public let merchantId: String
-
The two-letter ISO 3166 code of the country of your business, e.g. “US” See your account’s country value here https://dashboard.stripe.com/settings/account
Declaration
Swift
public let merchantCountryCode: String
-
Defines the label that will be displayed in the Apple Pay button. See https://developer.apple.com/design/human-interface-guidelines/technologies/apple-pay/buttons-and-marks/ for all available options.
Declaration
Swift
public let buttonType: PKPaymentButtonType
-
An array of payment summary item objects that summarize the amount of the payment. This property is identical to
PKPaymentRequest.paymentSummaryItems
. Ifnil
, we display a single line item with the amount on the PaymentIntent or “Amount pending” for SetupIntents. If you’re using a SetupIntent for a recurring payment, you should set this to display the amount you intend to charge, in accordance with https://developer.apple.com/design/human-interface-guidelines/technologies/apple-pay/subscriptions-and-donations Follow Apple’s documentation to set this property: https://developer.apple.com/documentation/passkit/pkpaymentrequest/1619231-paymentsummaryitemsDeclaration
Swift
public let paymentSummaryItems: [PKPaymentSummaryItem]?
-
Optional handler blocks for Apple Pay
Declaration
Swift
public let customHandlers: Handlers?
-
Custom handler blocks for Apple Pay
See moreDeclaration
Swift
public struct Handlers
-
Initializes a ApplePayConfiguration
Declaration
Swift
public init( merchantId: String, merchantCountryCode: String, buttonType: PKPaymentButtonType = .plain, paymentSummaryItems: [PKPaymentSummaryItem]? = nil, customHandlers: Handlers? = nil )