Configuration options for Apple Pay payment integration
Apple Pay enables customers to pay using payment methods saved to their Apple Wallet. The SDK provides configuration options for button styling and contact information capture.
Apple Pay requires currencyCode and order.countryCode in the client session.
order.countryCode is the merchant’s country (ISO 3166-1 alpha-2) — where the transaction is processed, not the buyer’s country. This maps to Apple Pay’s PKPaymentRequest.countryCode: “the two-letter ISO 3166 code for the country or region of the merchant’s principle place of business.”
Customize the appearance of the Apple Pay button through the buttonOptions configuration.
Option
Type
Default
Description
buttonOptions.type
string
'plain'
Button label text (see values below). Automatically localized.
buttonOptions.buttonStyle
string
—
'black' for black with white text, 'white' for white with black text, 'white-outline' for white with black outline. If not set, Apple Pay uses its default styling.
Set requireShippingMethod to true to display available shipping methods in the Apple Pay sheet. This requires a shipping module to be configured in your Primer dashboard.
The SDK filters networks based on your Primer configuration. If orderedAllowedCardNetworks is set in your client session, only those networks are available.
Apple Pay only works on supported devices with Safari or WebKit-based browsers. The button appears only when the device supports Apple Pay and the user has payment methods configured.