signEvent

Method

async function signEvent(event: UnsignedEvent) : Event;

Response

Takes an event object, adds id, pubkey and sig and returns it

Code Example

const event = {
  created_at: 1673347337,
  kind: 1,
  content: "Alby ๐Ÿš€",
  tags: [],
};
const signedEvent = await window.nostr.signEvent(event);

Last updated

Logo

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