collana pay JS Docs / MollieApplePayOptions
Interface: MollieApplePayOptions
Defined in: types.ts:553
SDK-level options for the Mollie Apple Pay provider (Mollie:ApplePay).
Remarks
Uses the W3C Payment Request API with a pre-fetched Apple Pay session from Mollie. totalAmount and currencyCode are required.
Your onClick callback must return checkoutData containing:
data: base64-encoded Apple Pay session from the Mollie/wallets/applepay/sessionsendpoint.returnUrl: backend endpoint that receives the serialisedPaymentResponseand completes the Mollie payment.merchantIdentifier: the human-readable Apple Pay merchant identifier (e.g.'merchant.com.example').
Example
const mollieApplePay: ProviderButtonConfig<'Mollie:ApplePay'> = {
providerProtocolType: 'Mollie',
paymentMethodType: 'ApplePay',
container: '#mollie-applepay-container',
style: { buttonstyle: 'black', type: 'buy' },
options: {
totalAmount: 1000,
currencyCode: 'EUR',
countryCode: 'DE',
},
};Properties
countryCode?
optionalcountryCode?:string
Defined in: types.ts:561
ISO 3166-1 alpha-2 country code for the merchant (e.g. 'US', 'DE'). Defaults to 'DE'.
currencyCode
currencyCode:
string
Defined in: types.ts:559
ISO 4217 currency code (e.g. 'EUR', 'USD').
requiredBillingContactFields?
optionalrequiredBillingContactFields?:string[]
Defined in: types.ts:572
Apple Pay contact fields required for billing (e.g. ['postalAddress', 'phone', 'email']).
requiredShippingContactFields?
optionalrequiredShippingContactFields?:string[]
Defined in: types.ts:570
Apple Pay contact fields required for shipping (e.g. ['postalAddress', 'phone', 'email']).
Remarks
Only relevant when the merchant needs shipping information.
supportedCountries?
optionalsupportedCountries?:string[]
Defined in: types.ts:580
ISO 3166-1 alpha-2 country codes that are valid for shipping.
Remarks
When provided, onshippingcontactselected will reject addresses from countries not in this list with an Apple Pay error.
supportedNetworks?
optionalsupportedNetworks?:string[]
Defined in: types.ts:563
Card networks accepted by the merchant.
Default Value
['amex', 'discover', 'masterCard', 'visa']
totalAmount
totalAmount:
number
Defined in: types.ts:557
Transaction amount in minor units (e.g. 1000 = €10.00).
