Skip to content

Generate key-pair

Important

Before the implementation please ensure you have generated a credential. Set a seed phrase as an environment variable which consists a cluster of 12 or 24 random words along with the issuer DID.

Generate a key-pair using the generateBls12381G2KeyPair method by seeding in a seed phrase.

const seed = Buffer.from(process.env.IDP_BLS_SIGN_SEED_PHRASE, "hex");
const keyPair = await generateBls12381G2KeyPair(new Uint8Array(seed));

Next Up: Construct credential →