Alby Developer Guide
Alby Browser Extension APIs
Ask or search…
⌃K
Links
Comment on page

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 modified 4mo ago