Node SDK for Passkey authentication, Social Login using Apple, Google and more...
Project website »
GitHub
·
Demo
·
Documentation
·
Tutorial
For frontend usage please see the accompanying @passlock/client package
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)