Node SDK for passkey authentication
Project website »
Demo
·
Documentation
·
Tutorial
For frontend usage please see the accompanying @passlock/client package
Passkeys and the WebAuthn API are quite complex. We've taken an opinionated approach to the implementation and feature set to simplify things for you. Following the 80/20 principle we've tried to focus on the features most valuable to developers and users. We welcome feature requests so do get in touch.
-
🔐 Primary or secondary authentication - Replace password based logins with passkeys, or use passkeys alongside passwords for secondary authentication.
-
☝🏻 Biometrics - We've made it really easy to implement facial or fingerprint recognition in your webapps.
-
🔐 Step up authentication - Require biometric or PIN verification for some actions e.g. changing account details, whilst allowing frictionless authentication for others.
-
🖥️ Full management console - Manage all security related aspects of your userbase through a web based console.
-
🕵️ Audit trail - View a full audit trail for each user: when they add a new passkey, when they login, verify their email address and much more.
Viewing a user's authentication activity on their profile page
Node 16+
Generate a secure token in your frontend then use this API to obtain the passkey registration or authentication details:
import { Passlock } from '@passlock/node'
const passlock = new Passlock({ tenancyId, apiKey })
// token comes from your frontend
const principal = await passlock.fetchPrincipal({ token })
// get the user id
console.log(principal.user.id)