1.29.0 • Published 3 years ago

verify-once v1.29.0

Weekly downloads
113
License
MIT
Repository
github
Last release
3 years ago

VerifyOnce

Downloads

Version

License

VerifyOnce verification service integration library and example.

Provides helpers for simple VerifyOnce service integration and example how to use it.

  • Works with express server.
  • Written in TypeScript, no need for extra typings.

Installation

This package is distributed via npm

npm install verify-once
yarn add verify-once

Usage

Credentials should be stored in projects config file. BaseUrl is optional param, for testing use dev or test prefix, defaults to https://app.verifyonce.com/api/verify

...

"verifyOnce": {
   "password": "integratorPassword",
   "username": "integratorUserName",
   "baseUrl":  "https://test-app.verifyonce.com/api/verify"
  },

...

Initiating Verify Once transaction

import { VerifyOnce } from "verify-once";

...

// all optional, are used for autofill
const userData : InitiateRequest = {
	country: CountryCode.BLR,
	firstName: "John",
	lastName: "Wick",
	email: "john@wick.com",
}

// initiate verification
const verifyOnce = new VerifyOnce(config.verifyOnce);

// passing userData object is optional
const verifyOnceInitiateResponse : InitiateResponse = await verifyOnce.initiate(userData);

...

Example

The example is located in the /example directory.

Running the example

  • Copy the example configuration file _.env to .env.
  • Make changes in the .env as needed.
  • Start the example by executing yarn start (npm start etc works as well).

Commands

  • yarn start to start the example application.
  • yarn build to build the production version.
  • yarn lint to lint the codebase.
  • yarn prettier to run prettier.
1.29.0

3 years ago

1.28.1

3 years ago

1.28.2

3 years ago

1.28.0

3 years ago

1.28.0-beta.0

3 years ago

1.27.0

3 years ago

1.27.0-beta.1

3 years ago

1.27.0-beta.0

3 years ago

1.26.0

3 years ago

1.25.0

3 years ago

1.24.1

3 years ago

1.24.0

4 years ago

1.24.0-beta.2

4 years ago

1.24.0-beta.1

4 years ago

1.24.0-beta.0

4 years ago

1.23.1

4 years ago

1.22.0

5 years ago

1.21.0

5 years ago

1.19.0

5 years ago

1.18.0

5 years ago

1.17.0

5 years ago

1.16.0

5 years ago

1.15.0

5 years ago

1.13.0

5 years ago

1.2.1

5 years ago

1.2.0

5 years ago

1.1.0

5 years ago