6.2.0 • Published 5 months ago

capacitor-google-pay v6.2.0

Weekly downloads
-
License
MIT
Repository
github
Last release
5 months ago

capacitor-google-pay

Google Pay In-App Provisioning

Install

npm install capacitor-google-pay
npx cap sync

Prepare Lib

  1. Get access to Android Push Provisioning API
  2. Set up your environment and Integrate the SDK
  3. Unzip downloaded m2repository to <path to sdk.dir>/extras/google/m2repository,

    For example: ~/Library/Android/sdk/extras/google/m2repository

  4. Request Push Provisioning API Access

  5. Here we go

API

addListener('registerDataChangedListener', ...)

addListener(eventName: 'registerDataChangedListener', listenerFunc: (response: any) => void) => any

Event called when an action is performed on a pusn notification.

ParamTypeDescription
eventName'registerDataChangedListener'pushNotificationActionPerformed.
listenerFunc(response: any) => voidcallback with the notification action.

Returns: any

Since: 1.0.0


removeAllListeners()

removeAllListeners() => void

getEnvironment()

getEnvironment() => any

returns the environment (e.g. production or sandbox)

Returns: any

Since: 1.0.0


getStableHardwareId()

getStableHardwareId() => any

returns the stable hardware ID of the device

Returns: any

Since: 1.0.0


getActiveWalletID()

getActiveWalletID() => any

returns the ID of the active wallet

Returns: any

Since: 1.0.0


createWallet()

createWallet() => any

Initializes create wallet

Returns: any

Since: 4.0.1


getTokenStatus(...)

getTokenStatus(options: GooglePayTokenOptions) => any

returns the status of a token with a given token ID

ParamTypeDescription
optionsGooglePayTokenOptionsToken Options

Returns: any

Since: 1.0.0


listTokens()

listTokens() => any

returns a list of tokens registered to the active wallet

Returns: any

Since: 1.0.0


isTokenized(...)

isTokenized(options: GooglePayIsTokenizedOptions) => any

Starts the push tokenization flow

ParamType
optionsGooglePayIsTokenizedOptions

Returns: any

Since: 1.0.0


pushProvision(...)

pushProvision(options: GooglePayProvisionOptions) => any

Starts the push tokenization flow

ParamType
optionsGooglePayProvisionOptions

Returns: any

Since: 1.0.0


requestSelectToken(...)

requestSelectToken(options: GooglePayTokenOptions) => any

Requests setting token as default in Google Pay

ParamTypeDescription
optionsGooglePayTokenOptionsToken Options

Returns: any

Since: 1.0.0


requestDeleteToken(...)

requestDeleteToken(options: GooglePayTokenOptions) => any

Requests deleting token from Google Pay

ParamTypeDescription
optionsGooglePayTokenOptionsToken Options

Returns: any

Since: 4.0.13


isGPayDefaultNFCApp()

isGPayDefaultNFCApp() => any

Check if Google Pay is Default NFC payment App

Returns: any

Since: 4.0.4


setGPayAsDefaultNFCApp()

setGPayAsDefaultNFCApp() => any

Sets Google Pay as Default NFC payment App

Returns: any

Since: 4.0.4


registerDataChangedListener()

registerDataChangedListener() => any

returns the status of a token with a given token ID

Returns: any

Since: 1.0.0


Interfaces

PluginListenerHandle

PropType
remove() => any

GooglePayTokenOptions

PropTypeDescriptionSince
tspstringSets the TSP that should be used for the tokenization attempt (see TokenServiceProvider).1.0.0
tokenReferenceIdstringtoken registered to the active wallet1.0.0

GooglePayIsTokenizedOptions

PropTypeDescriptionSince
tspstringSets the TSP that should be used for the tokenization attempt (see TokenServiceProvider).1.0.0
lastDigitsstringSets the lastDigits that should be used for the tokenization attempt (see TokenServiceProvider).1.0.0

GooglePayProvisionOptions

PropTypeDescriptionSince
opcstringSets Opaque Payment Card binary data.1.0.0
tspstringSets the TSP that should be used for the tokenization attempt (see TokenServiceProvider).1.0.0
clientNamestringSets the clientName that should be used for the tokenization attempt (see TokenServiceProvider).1.0.0
lastDigitsstringSets the lastDigits that should be used for the tokenization attempt (see TokenServiceProvider).1.0.0
addressGooglePayAddressSets the address that should be used for the tokenization attempt (see TokenServiceProvider).1.0.0

GooglePayAddress

PropTypeDescriptionSince
namestringAddress name1.0.0
address1stringFull address1.0.0
address2stringApartment/Office1.0.0
localitystringLocality1.0.0
administrativeAreastringAdministrative area1.0.0
countryCodestringCountry code1.0.0
postalCodestringPostal code1.0.0
phoneNumberstringPhone number1.0.0

Enums

TokenStatusReference

MembersValue
TOKEN_STATE_UNTOKENIZED1
TOKEN_STATE_PENDING2
TOKEN_STATE_NEEDS_IDENTITY_VERIFICATION3
TOKEN_STATE_SUSPENDED4
TOKEN_STATE_ACTIVE5
TOKEN_STATE_FELICA_PENDING_PROVISIONING6
TOKEN_STATE_NOT_FOUND-1
6.2.0

5 months ago

5.0.1-0

2 years ago

5.0.3

2 years ago

5.0.2

2 years ago

5.0.1

2 years ago

5.0.0

2 years ago

4.0.9

3 years ago

4.0.8

3 years ago

4.0.5

3 years ago

4.0.4

3 years ago

4.0.10

3 years ago

4.0.7

3 years ago

4.0.6

3 years ago

4.0.3

3 years ago

4.0.12

3 years ago

4.0.11

3 years ago

4.0.13

3 years ago

4.0.1

3 years ago

4.0.0

3 years ago

4.0.2

3 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago