Yup. All gift wrapped NIP-17, NIP-59, NIP-44. I do one better as I transmit as ephemeral events so that the relays delete after 10 minutes. If a message comes in via a lightning address, the service fires up the receiving wallet to receive the message and store it accordingly.

Reply to this note

Please Login to reply.

Discussion

relays are not supposed to store ephemerals at all, they either go out if someone is listening, or go into the void, the point of them is precisely ...

makes me think of something... there is overlap between post office protocol and publish-subscribe pattern, in that you can publish to an inbox, which can then be read by an eligible user. ephemeral events are kinda more like a one-to-many rendezvous relay pattern. almost, actually, the most specific element of the protocol that makes the name "relay" valid at all, because relay doesn't imply storage. that's a post office.

NIP-17 uses kind 1059, which are regular events and stay around forever. I switched to ephemeral events because I don’t want them stay around forever- just 10 minutes so the receiver can get them. I also want a relay to have the ability to carry out request deletes of NIP-59 events addressed to a pubkey, versus only the author of the event.

yeah, you can put an expiration tag on any event kind and have it disappear if the relay allows it, so for this case you don't use ephemeral type, which are specified to not be stored

the actual implementation of expirations though, the "lazy" method that i have applied is simply that when it fetches an event from the db, if it reads an expiration that is passed, it doesn't include it and deletes it, but if nobody asks for it, it is just left there. to implement it dynamically so the event is deleted properly requires a scheduler and a worker thread that performs the action on a timer. this can be a lot more costly in terms of memory and processing if the relay does this a lot. there is probably a third approach that just does a routine scan every hour or so that would be a bit more of an in-between in terms of memory and processing cost.