upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/71.md
diff options
context:
space:
mode:
authorrabble <evan@protest.net>2026-01-08 05:48:48 +1300
committerGitHub <noreply@github.com>2026-01-07 08:48:48 -0800
commitf34e98c73f47fed6778e2fc62b256f925bead065 (patch)
treea1c8296e5c09c6cb82ee0a11a182198b0275e68c /71.md
parentd7db75fc691a5b182d133d72fb3692b57cf2aeca (diff)
NIP-71: Add addressable video events (kinds 34235, 34236) (#2072)
Co-authored-by: hodlbod <jstaab@protonmail.com>
Diffstat (limited to '71.md')
-rw-r--r--71.md73
1 files changed, 73 insertions, 0 deletions
diff --git a/71.md b/71.md
index 3068e7a..0124edd 100644
--- a/71.md
+++ b/71.md
@@ -20,6 +20,20 @@ Nothing except cavaliership and common sense prevents a _short_ video from being
20 20
21The format uses a _regular event_ kind `21` for _normal_ videos and `22` for _short_ videos. 21The format uses a _regular event_ kind `21` for _normal_ videos and `22` for _short_ videos.
22 22
23## Addressable Video Events
24
25For content that may need updates after publication (such as correcting metadata, descriptions, or handling URL migrations), addressable versions are available:
26
27- Kind `34235` for _addressable normal videos_
28- Kind `34236` for _addressable short videos_
29
30These addressable events follow the same format as their regular counterparts but include a `d` tag as a unique identifier and can be updated while maintaining the same addressable reference. This is particularly useful for:
31
32- Metadata corrections (descriptions, titles, tags) without republishing
33- Preservation of imported content IDs from legacy platforms
34- URL migration when hosting changes
35- Platform migration tracking
36
23The `.content` of these events is a summary or description on the video content. 37The `.content` of these events is a summary or description on the video content.
24 38
25The primary source of video information is the `imeta` tags which is defined in [NIP-92](92.md) 39The primary source of video information is the `imeta` tags which is defined in [NIP-92](92.md)
@@ -81,6 +95,9 @@ The `image` tag contains a preview image (at the same resolution). Multiple `ima
81 95
82Additionally `service nip96` may be included to allow clients to search the authors NIP-96 server list to find the file using the hash. 96Additionally `service nip96` may be included to allow clients to search the authors NIP-96 server list to find the file using the hash.
83 97
98### Required tags for addressable events:
99* `d` - Unique identifier for this video (user-chosen string, required for kinds 34235, 34236)
100
84### Other tags: 101### Other tags:
85* `title` (required) title of the video 102* `title` (required) title of the video
86* `published_at`, for the timestamp in unix seconds (stringified) of the first time the video was published 103* `published_at`, for the timestamp in unix seconds (stringified) of the first time the video was published
@@ -92,6 +109,9 @@ Additionally `service nip96` may be included to allow clients to search the auth
92* `p` (optional, repeated) 32-bytes hex pubkey of a participant in the video, optional recommended relay URL 109* `p` (optional, repeated) 32-bytes hex pubkey of a participant in the video, optional recommended relay URL
93* `r` (optional, repeated) references / links to web pages 110* `r` (optional, repeated) references / links to web pages
94 111
112### Optional tags for imported content:
113* `origin` - Track original platform and ID: `["origin", "<platform>", "<external-id>", "<original-url>", "<optional-metadata>"]`
114
95```jsonc 115```jsonc
96{ 116{
97 "id": "<32-bytes lowercase hex-encoded SHA-256 of the the serialized event data>", 117 "id": "<32-bytes lowercase hex-encoded SHA-256 of the the serialized event data>",
@@ -135,3 +155,56 @@ Additionally `service nip96` may be included to allow clients to search the auth
135 ] 155 ]
136} 156}
137``` 157```
158
159## Addressable Event Example
160
161```jsonc
162{
163 "id": <32-bytes lowercase hex-encoded SHA-256 of the the serialized event data>,
164 "pubkey": <32-bytes lowercase hex-encoded public key of the event creator>,
165 "created_at": <Unix timestamp in seconds>,
166 "kind": 34235 | 34236,
167 "content": "<summary / description of video>",
168 "tags": [
169 ["d", "<unique-identifier>"],
170 ["title", "<title of video>"],
171 ["published_at", "<unix timestamp>"],
172 ["alt", "<description for accessibility>"],
173
174 // video data
175 ["imeta",
176 "url https://example.com/media.mp4",
177 "m video/mp4",
178 "dim 480x480",
179 "blurhash eVF$^OI:${M{%LRjWBoLoLaeR*",
180 "image https://example.com/thumb.jpg",
181 "x 3093509d1e0bc604ff60cb9286f4cd7c781553bc8991937befaacfdc28ec5cdc"
182 ],
183
184 ["duration", <duration in seconds>],
185 ["content-warning", "<reason>"],
186
187 // origin tracking for imported content
188 ["origin", "<platform>", "<external-id>", "<original-url>", "<optional-metadata>"],
189
190 // participants
191 ["p", "<32-bytes hex of a pubkey>", "<optional recommended relay URL>"],
192
193 // hashtags
194 ["t", "<tag>"],
195 ["t", "<tag>"],
196
197 // reference links
198 ["r", "<url>"]
199 ]
200}
201```
202
203## Referencing Addressable Events
204
205To reference an addressable video:
206
207```
208["a", "34235:<pubkey>:<d-tag-value>", "<relay-url>"] // for normal videos
209["a", "34236:<pubkey>:<d-tag-value>", "<relay-url>"] // for short videos
210```