Documentation
    Preparing search index...

    Interface Signer

    NIP-07 compatible signer interface — minimal methods the runtime needs.

    interface Signer {
        nip04?: {
            decrypt(pubkey: string, ciphertext: string): Promise<string>;
            encrypt(pubkey: string, plaintext: string): Promise<string>;
        };
        nip44?: {
            decrypt(pubkey: string, ciphertext: string): Promise<string>;
            encrypt(pubkey: string, plaintext: string): Promise<string>;
        };
        getPublicKey?(): string | Promise<string>;
        getRelays?(): | Record<string, { read: boolean; write: boolean }>
        | Promise<Record<string, { read: boolean; write: boolean }>>;
        signEvent?(event: NostrEvent | EventTemplate): Promise<NostrEvent>;
    }
    Index

    Properties

    nip04?: {
        decrypt(pubkey: string, ciphertext: string): Promise<string>;
        encrypt(pubkey: string, plaintext: string): Promise<string>;
    }
    nip44?: {
        decrypt(pubkey: string, ciphertext: string): Promise<string>;
        encrypt(pubkey: string, plaintext: string): Promise<string>;
    }

    Methods

    • Returns
          | Record<string, { read: boolean; write: boolean }>
          | Promise<Record<string, { read: boolean; write: boolean }>>