add nipB0, social bookmarking.

This commit is contained in:
fiatjaf 2025-03-19 08:54:45 -03:00
parent 0619f370bc
commit f6b203ab42

31
b0.md Normal file
View File

@ -0,0 +1,31 @@
NIP-B0
======
Web Bookmarking
---------------
`draft` `optional`
This NIP defines `kind:39701` as website bookmarks.
```jsonc
{
"kind": 39701,
"id": "d7a92714f81d0f712e715556aee69ea6da6bfb287e6baf794a095d301d603ec7",
"pubkey": "2729620da105979b22acfdfe9585274a78c282869b493abfa4120d3af2061298",
"created_at": 1738869705,
"tags": [
["d", "alice.blog/post"],
["t", "post"],
["t", "insight"]
],
"content": "A marvelous insight by Alice about the nature of blogs and posts.",
"sig": "36d34e6448fe0223e9999361c39c492a208bc423d2fcdfc2a3404e04df7c22dc65bbbd62dbe8a4373c62e4d29aac285b5aa4bb9b4b8053bd6207a8b45fbd0c98"
}
```
Bookmarks can be queried by the `d` tag, which is just their URL without the scheme, which is always and everywhere assumed to be `https://`.
The querystring and the hash must be removed entirely, unless their requirement is explicitly stated either by the user or by some hardcoded list of URLs that rely on querystrings for basic routing provided by the client (I've searched the internet extensively and could only find 3 websites that do this: YouTube, Hacker News and a random guy's sad old blog).
Bookmarks can be commented on with [NIP-22](22.md).