Handle a NIP-5D envelope from a napplet.
The requesting napplet's window identifier
NappletMessage JSON envelope (e.g., { type: 'signer.signEvent', id, event })
Callback to send NappletMessage responses back to the napplet
OptionalonCalled when a napplet window is destroyed. Services should clean up any state associated with the window.
The destroyed napplet's window identifier
Handler for service-specific messages from napplets. Services receive NIP-5D NappletMessage envelopes and respond via the
sendcallback. The same interface is used for all services regardless of what NAP domain they handle.Example