capacitor-apple-pay-plugin
TypeScript icon, indicating that this package has built-in type declarations

0.0.3 • Public • Published

capacitor-apple-pay-plugin

A Capacitor plugin for Apple Pay

Install

npm install capacitor-apple-pay-plugin
npx cap sync

API

canMakePayments()

canMakePayments() => Promise<{ isPayment: boolean; }>

Returns: Promise<{ isPayment: boolean; }>


canMakePayments(...)

canMakePayments(options: CanMakePaymentsNetworks) => Promise<{ isPayment: boolean; }>
Param Type
options CanMakePaymentsNetworks

Returns: Promise<{ isPayment: boolean; }>


makePaymentRequest(...)

makePaymentRequest(request: PaymentRequest) => Promise<PaymentResponse>
Param Type
request PaymentRequest

Returns: Promise<PaymentResponse>


completeLastTransaction(...)

completeLastTransaction(options: { status: string; }) => Promise<void>
Param Type
options { status: string; }

Interfaces

CanMakePaymentsNetworks

Prop Type
usingNetworks PaymentNetwork[]
capabilities MerchantCapability[]

PaymentResponse

Prop Type
token { paymentData?: string; transactionIdentifier: string; paymentMethod: { displayName?: string; secureElementPass?: { deviceAccountNumberSuffix: string; deviceAccountIdentifier: string; primaryAccountIdentifier: string; primaryAccountNumberSuffix: string; devicePassIdentifier?: string; pairedTerminalIdentifier?: string; }; }; }

PaymentRequest

Prop Type
merchantIdentifier string
countryCode string
currencyCode string
supportedCountries string[]
supportedNetworks PaymentNetwork[]
paymentSummaryItems PaymentSummaryItem[]
requiredShippingContactFields ContactField[]
requiredBillingContactFields ContactField[]
merchantCapabilities MerchantCapability[]
billingContact PaymentContact
shippingContact PaymentContact

PaymentSummaryItem

Prop Type
label string
amount number
type PaymentSummaryItemType

PaymentContact

Prop Type
emailAddress string
phoneNumber string
name PersonNameComponents
postalAddress { street?: string; city?: string; postalCode?: string; country?: string; isoCountryCode?: string; subAdministrativeArea?: string; subLocality?: string; }

PersonNameComponents

Prop Type
familyName string
givenName string
namePrefix string
middleName string
nameSuffix string
nickname string
phoneticRepresentation PersonNameComponents

Type Aliases

PaymentNetwork

'masterCard' | 'visa' | 'amex' | 'quicPay' | 'chinaUnionPay' | 'discover' | 'interac' | 'privateLabel'

MerchantCapability

'capability3DS' | 'capabilityCredit' | 'capabilityDebit' | 'capabilityEMV'

PaymentSummaryItemType

'pending' | 'final'

ContactField

'emailAddress' | 'name' | 'phoneNumber' | 'phoneticName' | 'postalAddress'

Readme

Keywords

Package Sidebar

Install

npm i capacitor-apple-pay-plugin

Weekly Downloads

1

Version

0.0.3

License

MIT

Unpacked Size

57.9 kB

Total Files

28

Last publish

Collaborators

  • neilliner