🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

fia-react

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fia-react

FIA React Native by Fazpass.

0.1.5
latest
Source
npm
Version published
Weekly downloads
6
-25%
Maintainers
1
Weekly downloads
 
Created
Source

fia-react

FIA React Native by Fazpass. Visit official website for more information about the product and see documentation at github documentation for more technical details.

Installation

npm install fia-react

Usage

import FIA, { OtpPromise, OtpAuthType } from 'fia-react';

// initialize
FIA.initialize("MERCHANT_KEY", "MERCHANT_APP_ID");

// request OTP with login purpose
var otpPromise: OtpPromise
FIA.otp().login("PHONE", (promise) => {
    if (promise.hasException) {
        let exception = promise.exception
        // handle exception here
        return
    }
    otpPromise = promise
});

// check OTP authentication type
switch (otpPromise.authType) {
    case OtpAuthType.Message:
        // on message...
        break
    case OtpAuthType.Miscall:
        // on miscall...
        break
    case OtpAuthType.He:
        // on He...
        break
    case OtpAuthType.FIA:
        // on FIA...
        break
};

// validate Message or Miscall OTP
otpPromise.validate(
    "OTP", 
    (err) => {
        // on error
    },
    () => {
        // on validated
    }
);

// validate HE
otpPromise.validateHe(
    (err) => {
        // on error
    },
    () => {
        // on validated
    }
);

License

MIT

Keywords

react-native

FAQs

Package last updated on 09 May 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts