diff options
| author | Semisol <45574030+Semisol@users.noreply.github.com> | 2023-01-27 20:49:43 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-01-27 14:49:43 -0300 |
| commit | 524ff9b8052d7e8c0515f63baae218dc40c6f696 (patch) | |
| tree | 3ee58d895749cfbd0e00b9783d27ff4ac4ebdfc6 | |
| parent | f89187a2581aceb99c436d5919391622a82b0713 (diff) | |
Bech32 encoded relay entities (#196)
| -rw-r--r-- | 19.md | 5 |
1 files changed, 4 insertions, 1 deletions
| @@ -34,6 +34,7 @@ These are the possible bech32 prefixes with `TLV`: | |||
| 34 | 34 | ||
| 35 | - `nprofile`: a nostr profile | 35 | - `nprofile`: a nostr profile |
| 36 | - `nevent`: a nostr event | 36 | - `nevent`: a nostr event |
| 37 | - `nrelay`: a nostr relay | ||
| 37 | 38 | ||
| 38 | These possible standardized `TLV` types are indicated here: | 39 | These possible standardized `TLV` types are indicated here: |
| 39 | 40 | ||
| @@ -41,9 +42,11 @@ These possible standardized `TLV` types are indicated here: | |||
| 41 | - depends on the bech32 prefix: | 42 | - depends on the bech32 prefix: |
| 42 | - for `nprofile` it will be the 32 bytes of the profile public key | 43 | - for `nprofile` it will be the 32 bytes of the profile public key |
| 43 | - for `nevent` it will be the 32 bytes of the event id | 44 | - for `nevent` it will be the 32 bytes of the event id |
| 45 | - for `nrelay`, this is the relay URL. | ||
| 46 | - for `nprofile`, `nevent` and `nrelay` this may be included only once. | ||
| 44 | - `1`: `relay` | 47 | - `1`: `relay` |
| 45 | - A relay in which the entity (profile or event) is more likely to be found, encoded as UTF-8. This may be included multiple times. | 48 | - A relay in which the entity (profile or event) is more likely to be found, encoded as UTF-8. This may be included multiple times. |
| 46 | 49 | - not applicable to `nrelay`. | |
| 47 | ## Examples | 50 | ## Examples |
| 48 | 51 | ||
| 49 | - `npub180cvv07tjdrrgpa0j7j7tmnyl2yr6yr7l8j4s3evf6u64th6gkwsyjh6w6` should decode into the public key hex `3bf0c63fcb93463407af97a5e5ee64fa883d107ef9e558472c4eb9aaaefa459d` and vice-versa | 52 | - `npub180cvv07tjdrrgpa0j7j7tmnyl2yr6yr7l8j4s3evf6u64th6gkwsyjh6w6` should decode into the public key hex `3bf0c63fcb93463407af97a5e5ee64fa883d107ef9e558472c4eb9aaaefa459d` and vice-versa |