nip04.decrypt

Method

async function nip04.decrypt(pubkey: string, message: string): string;

Response

Returns decrypted message

Code Example

const message = "Secret message";
const encrypted = await window.nostr.nip04.encrypt(pubkey, message);
const decrypted = await window.nostr.nip04.decrypt(pubkey, encrypted); // Secret message

Last updated

Logo

Your bitcoin & nostr companion / from ๐Ÿ with ๐Ÿงก