npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

react-native-masterpass-kit

v1.0.0

Published

TODO

Downloads

3

Readme

react-native-masterpass-kit

Getting started

$ yarn add react-native-masterpass-kit

iOS setup

Copy framework

You need to copy corresponding MasterPassKit.framework to node_modules/react-native-masterpass-kit/ios/Frameworks

Methods

  1. checkout
    • code: string (required) This is the code created by calling the Masterpass API representing the transaction.
    • apiKey: string (required) This is the API key provided by Masterpass that will enable the library to be used. This can be found on the Masterpass Portal under the Lib Lite Tokens menu item.
    • system: 'test' | 'live' (required) Representing the Masterpass backend system to connect to.
    • preMsisdn: string (optional) This is an optional field if you know the client’s mobile number.
    • hash: string (optional) [Android only] This allows capability for the app to read the SMS for registration. Details on how to generate the HASH key can be String found here https://developers.google.com/identity/sms-retriever/verify#computing_your_apps_hash_string
  2. preRegister
    • apiKey: string (required)
    • system: 'test' | 'live' (required)
    • preMsisdn: string (optional)
  3. manageCardList
    • apiKey: string (required)
    • system: 'test' | 'live' (required)
    • preMsisdn: string (optional)

Events

  1. registerUserDidCancelEvent Call when user aborted the process
  2. registerPaymentSucceededEvent Call when payment success
    • transaction: string This is the reference for the transaction. This reference will be used to tie up the transaction on the 3rd party backend system
  3. registerErrorEvent Call when an error has occurred before the payment
    • code: string Error code. Prefer below
    • location: number [Android only] This is the location of the error. This can be used to debug the error when requesting support from Oltio.
  4. registerPaymentFailedEvent Call when the payment failed
    • transaction: string This is the reference for the failed transaction in the event the 3rd party needs to request more information regarding the failure
  5. registerInvalidCodeEvent Call when the code param invalid
  6. registerUserRegisterEvent Call when the user has registered with Masterpass
  7. registerUserCompletedWalletEvent Call when user done with wallet

Error codes

- OTPError
- NetworkError
- ExceptionOccored
- PaymentError
- InvalidApiKeyParameter
- InvalidCodeParameter
- SecureCodeNotSupported
- Unknown

Usage

import RNMasterpassKit from 'react-native-masterpass-kit';

RNMasterpassKit.checkout({
    code: '6799782555',
    apiKey: '1234567890',
    system: 'test',
});

const subcription = RNMasterpassKit.registerUserDidCancelEvent(() => {
    console.warn('User cancelled');
});
// And later on
subcription.remove();