@libsem/identity
v1.0.22
Published
Library for managing identites for Semaphore and Rln protocols.
Readme
🛠 Install
npm or yarn
Install the @libsem/identity package with npm:
npm i @libsem/identityor yarn:
yarn add @libsem/identity📜 Usage
Import
import { ZkIdentity, Identity } from "@libsem/identity"const { ZkIdentity } = require("@libsem/identity")Mainpulation
const identity: ZkIdentity = new ZkIdentity();
const identityCommitment: bigint = identity.genIdentityCommitment();Serialization
const identity: ZkIdentity = new ZkIdentity();
const serialized: string = identity.serializeIdentity()
const unserialized: ZkIdentity = ZkIdentity.genFromSerialized(serialized);