@tat-protocol/signers
v1.1.1
Published
Signer implementations for TAT Protocol
Maintainers
Readme
@tat-protocol/signers
Signer implementations for server and browser runtimes.
Install
npm install @tat-protocol/signersExports
KeySigner(server/key-managed signing)NIP07Signer(browser extension signing)isNIP07AvailablewaitForNIP07
Quick Start
Server / backend
import { KeySigner } from "@tat-protocol/signers";
const signer = new KeySigner(process.env.SECRET_KEY_HEX!);
const pubkey = await signer.getPublicKey();Browser with NIP-07
import { NIP07Signer, waitForNIP07 } from "@tat-protocol/signers";
if (await waitForNIP07(5000)) {
const signer = new NIP07Signer();
console.log(await signer.getPublicKey());
}Choosing a Signer
- Use
KeySignerfor CI, servers, and controlled key custody. - Use
NIP07Signerfor user-controlled browser wallets.
