soapbox/src/types/nostr.ts

12 wiersze
342 B
TypeScript
Czysty Zwykły widok Historia

2023-04-03 00:54:08 +00:00
import type { Event, EventTemplate } from 'nostr-tools';
interface Nostr {
getPublicKey(): Promise<string>;
signEvent(event: EventTemplate): Promise<Event>;
2023-08-27 04:24:18 +00:00
nip04?: {
encrypt: (pubkey: string, plaintext: string) => Promise<string>;
decrypt: (pubkey: string, ciphertext: string) => Promise<string>;
};
2023-04-03 00:54:08 +00:00
}
export default Nostr;