blend icon indicating copy to clipboard operation
blend copied to clipboard

Some recommendations

Open Semisol opened this issue 3 years ago • 1 comments

  • If you want to be fully nostr compatible, you will need to do some changes
    • time should be replaced by created_at, and uses unix seconds instead of ms
    • public_key must be a 64 character public key according to BIP 340, and should be renamed to pubkey
    • signature must be a 128 character hex signature of the event, how it is generated is defined in NIP-01
    • message should be replaced by content
    • You cannot have properties like contact on the event itself, you can make content a stringified JSON object though.
    • You need to add a tags array, that may be empty or contain additional metadata. The current standard is one letter tags will get indexed, so you can look up any event with a specific tag value.
    • Kinds must be numbers, not strings.
  • Optional recommendations if you want to use nostr
    • CANCEL_REQUEST can be replaced by kind 5 events that will mark an event as "deleted" and may stop returning it in queries in some relays implementations, currently only nostr-rs-relay from my knowledge.

Semisol avatar Oct 14 '22 08:10 Semisol

thank you for this, agreed we should make all these changes

dannydeezy avatar Oct 14 '22 08:10 dannydeezy