@habloapp/passport-unicauth

1.0.4 • Public • Published

Unic Auth Strategy for Passport

Unic Auth Strategy for Passport using Unic Auth API

Unic Auth allows you to quickly implement userless/passwordless login and 2FA (no more paying for SMS to have 2FA)

Installation

First make sure to get your credentials on Unic Auth, if you want to test first, use Unic Auth - Demo

For Node.js

npm

Install it via:

npm install @habloapp/passport-unicauth --save

Example

const UnicAuthStrategy = require('@habloapp/passport-unicauth').Strategy

const strategy = new UnicAuthStrategy({
    appKey: APPLICATION_APPKEY,
    readKey: APPLICATION_READKEY,
    writeKey: APPLICATION_WRITEKEY,
    passReqToCallback: true
  },
  function(req, profile, done) {
    // ...
  }
)

At Passport docs you can find more examples on how Passport works with strategies.

Package Sidebar

Install

npm i @habloapp/passport-unicauth

Weekly Downloads

0

Version

1.0.4

License

ISC

Unpacked Size

7.3 kB

Total Files

6

Last publish

Collaborators

  • unicauth