event-kinds.ts raw
1 /**
2 * Nostr Event Kinds Database
3 * Auto-generated from https://git.mleku.dev/mleku/nostr/raw/branch/main/encoders/kind/kinds.json
4 * Version: 2025-12-21
5 * Source: https://github.com/nostr-protocol/nips
6 *
7 * DO NOT EDIT - This file is auto-generated by scripts/fetch-kinds.js
8 */
9
10 export interface KindInfo {
11 kind: number;
12 name: string;
13 description: string;
14 nip: string | null;
15 classification: 'regular' | 'replaceable' | 'ephemeral' | 'parameterized';
16 deprecated: boolean;
17 spec: string | null;
18 }
19
20 export interface KindRanges {
21 regular: { start: number; end: number; description: string };
22 replaceable: { start: number; end: number; description: string };
23 ephemeral: { start: number; end: number; description: string };
24 parameterized: { start: number; end: number; description: string };
25 }
26
27 export const EVENT_KINDS: KindInfo[] = [
28 {
29 "kind": 0,
30 "name": "Metadata",
31 "description": "User profile information (name, about, picture, nip05, etc.)",
32 "nip": "01",
33 "classification": "replaceable",
34 "deprecated": false,
35 "spec": null
36 },
37 {
38 "kind": 1,
39 "name": "Short Text Note",
40 "description": "Short-form text post (like a tweet)",
41 "nip": "01",
42 "classification": "regular",
43 "deprecated": false,
44 "spec": null
45 },
46 {
47 "kind": 2,
48 "name": "Recommend Relay",
49 "description": "Relay recommendation",
50 "nip": "01",
51 "classification": "regular",
52 "deprecated": true,
53 "spec": null
54 },
55 {
56 "kind": 3,
57 "name": "Follows",
58 "description": "Following list with optional relay hints",
59 "nip": "02",
60 "classification": "replaceable",
61 "deprecated": false,
62 "spec": null
63 },
64 {
65 "kind": 4,
66 "name": "Encrypted Direct Message",
67 "description": "Private message using NIP-04 encryption",
68 "nip": "04",
69 "classification": "regular",
70 "deprecated": true,
71 "spec": null
72 },
73 {
74 "kind": 5,
75 "name": "Event Deletion Request",
76 "description": "Request to delete events",
77 "nip": "09",
78 "classification": "regular",
79 "deprecated": false,
80 "spec": null
81 },
82 {
83 "kind": 6,
84 "name": "Repost",
85 "description": "Share/repost another text note",
86 "nip": "18",
87 "classification": "regular",
88 "deprecated": false,
89 "spec": null
90 },
91 {
92 "kind": 7,
93 "name": "Reaction",
94 "description": "Like, emoji reaction to an event",
95 "nip": "25",
96 "classification": "regular",
97 "deprecated": false,
98 "spec": null
99 },
100 {
101 "kind": 8,
102 "name": "Badge Award",
103 "description": "Award a badge to someone",
104 "nip": "58",
105 "classification": "regular",
106 "deprecated": false,
107 "spec": null
108 },
109 {
110 "kind": 9,
111 "name": "Chat Message",
112 "description": "Chat message",
113 "nip": "C7",
114 "classification": "regular",
115 "deprecated": false,
116 "spec": null
117 },
118 {
119 "kind": 10,
120 "name": "Group Chat Threaded Reply",
121 "description": "Threaded reply in group chat",
122 "nip": "29",
123 "classification": "regular",
124 "deprecated": true,
125 "spec": null
126 },
127 {
128 "kind": 11,
129 "name": "Thread",
130 "description": "Thread event",
131 "nip": "7D",
132 "classification": "regular",
133 "deprecated": false,
134 "spec": null
135 },
136 {
137 "kind": 12,
138 "name": "Group Thread Reply",
139 "description": "Reply in group thread",
140 "nip": "29",
141 "classification": "regular",
142 "deprecated": true,
143 "spec": null
144 },
145 {
146 "kind": 13,
147 "name": "Seal",
148 "description": "Sealed/encrypted event wrapper",
149 "nip": "59",
150 "classification": "regular",
151 "deprecated": false,
152 "spec": null
153 },
154 {
155 "kind": 14,
156 "name": "Direct Message",
157 "description": "Private direct message using NIP-17",
158 "nip": "17",
159 "classification": "regular",
160 "deprecated": false,
161 "spec": null
162 },
163 {
164 "kind": 15,
165 "name": "File Message",
166 "description": "File message in DMs",
167 "nip": "17",
168 "classification": "regular",
169 "deprecated": false,
170 "spec": null
171 },
172 {
173 "kind": 16,
174 "name": "Generic Repost",
175 "description": "Repost any event kind",
176 "nip": "18",
177 "classification": "regular",
178 "deprecated": false,
179 "spec": null
180 },
181 {
182 "kind": 17,
183 "name": "Reaction to Website",
184 "description": "Reaction to a website URL",
185 "nip": "25",
186 "classification": "regular",
187 "deprecated": false,
188 "spec": null
189 },
190 {
191 "kind": 20,
192 "name": "Picture",
193 "description": "Picture-first feed post",
194 "nip": "68",
195 "classification": "regular",
196 "deprecated": false,
197 "spec": null
198 },
199 {
200 "kind": 21,
201 "name": "Video Event",
202 "description": "Horizontal video event",
203 "nip": "71",
204 "classification": "regular",
205 "deprecated": false,
206 "spec": null
207 },
208 {
209 "kind": 22,
210 "name": "Short-form Video",
211 "description": "Short-form portrait video (like TikTok)",
212 "nip": "71",
213 "classification": "regular",
214 "deprecated": false,
215 "spec": null
216 },
217 {
218 "kind": 40,
219 "name": "Channel Creation",
220 "description": "Create a public chat channel",
221 "nip": "28",
222 "classification": "regular",
223 "deprecated": false,
224 "spec": null
225 },
226 {
227 "kind": 41,
228 "name": "Channel Metadata",
229 "description": "Set channel name, about, picture",
230 "nip": "28",
231 "classification": "regular",
232 "deprecated": false,
233 "spec": null
234 },
235 {
236 "kind": 42,
237 "name": "Channel Message",
238 "description": "Post message in channel",
239 "nip": "28",
240 "classification": "regular",
241 "deprecated": false,
242 "spec": null
243 },
244 {
245 "kind": 43,
246 "name": "Channel Hide Message",
247 "description": "Hide a message in channel",
248 "nip": "28",
249 "classification": "regular",
250 "deprecated": false,
251 "spec": null
252 },
253 {
254 "kind": 44,
255 "name": "Channel Mute User",
256 "description": "Mute a user in channel",
257 "nip": "28",
258 "classification": "regular",
259 "deprecated": false,
260 "spec": null
261 },
262 {
263 "kind": 62,
264 "name": "Request to Vanish",
265 "description": "Request permanent deletion of all user data",
266 "nip": "62",
267 "classification": "regular",
268 "deprecated": false,
269 "spec": null
270 },
271 {
272 "kind": 64,
273 "name": "Chess (PGN)",
274 "description": "Chess game in PGN format",
275 "nip": "64",
276 "classification": "regular",
277 "deprecated": false,
278 "spec": null
279 },
280 {
281 "kind": 443,
282 "name": "KeyPackage",
283 "description": "Marmot protocol key package",
284 "nip": null,
285 "classification": "regular",
286 "deprecated": false,
287 "spec": "Marmot"
288 },
289 {
290 "kind": 444,
291 "name": "Welcome Message",
292 "description": "Marmot protocol welcome message",
293 "nip": null,
294 "classification": "regular",
295 "deprecated": false,
296 "spec": "Marmot"
297 },
298 {
299 "kind": 445,
300 "name": "Group Event",
301 "description": "Marmot protocol group event",
302 "nip": null,
303 "classification": "regular",
304 "deprecated": false,
305 "spec": "Marmot"
306 },
307 {
308 "kind": 818,
309 "name": "Merge Requests",
310 "description": "Git merge request",
311 "nip": "54",
312 "classification": "regular",
313 "deprecated": false,
314 "spec": null
315 },
316 {
317 "kind": 1018,
318 "name": "Poll Response",
319 "description": "Response to a poll",
320 "nip": "88",
321 "classification": "regular",
322 "deprecated": false,
323 "spec": null
324 },
325 {
326 "kind": 1021,
327 "name": "Bid",
328 "description": "Auction bid",
329 "nip": "15",
330 "classification": "regular",
331 "deprecated": false,
332 "spec": null
333 },
334 {
335 "kind": 1022,
336 "name": "Bid Confirmation",
337 "description": "Confirmation of auction bid",
338 "nip": "15",
339 "classification": "regular",
340 "deprecated": false,
341 "spec": null
342 },
343 {
344 "kind": 1040,
345 "name": "OpenTimestamps",
346 "description": "OpenTimestamps attestation",
347 "nip": "03",
348 "classification": "regular",
349 "deprecated": false,
350 "spec": null
351 },
352 {
353 "kind": 1059,
354 "name": "Gift Wrap",
355 "description": "Encrypted gift-wrapped event",
356 "nip": "59",
357 "classification": "regular",
358 "deprecated": false,
359 "spec": null
360 },
361 {
362 "kind": 1060,
363 "name": "Gift Wrap (Kind 4)",
364 "description": "Gift wrap variant for NIP-04 compatibility",
365 "nip": "59",
366 "classification": "regular",
367 "deprecated": false,
368 "spec": null
369 },
370 {
371 "kind": 1063,
372 "name": "File Metadata",
373 "description": "Metadata for shared files",
374 "nip": "94",
375 "classification": "regular",
376 "deprecated": false,
377 "spec": null
378 },
379 {
380 "kind": 1068,
381 "name": "Poll",
382 "description": "Create a poll",
383 "nip": "88",
384 "classification": "regular",
385 "deprecated": false,
386 "spec": null
387 },
388 {
389 "kind": 1111,
390 "name": "Comment",
391 "description": "Comment on events or external content",
392 "nip": "22",
393 "classification": "regular",
394 "deprecated": false,
395 "spec": null
396 },
397 {
398 "kind": 1222,
399 "name": "Voice Message",
400 "description": "Voice message",
401 "nip": "A0",
402 "classification": "regular",
403 "deprecated": false,
404 "spec": null
405 },
406 {
407 "kind": 1244,
408 "name": "Voice Message Comment",
409 "description": "Comment on voice message",
410 "nip": "A0",
411 "classification": "regular",
412 "deprecated": false,
413 "spec": null
414 },
415 {
416 "kind": 1311,
417 "name": "Live Chat Message",
418 "description": "Message in live stream chat",
419 "nip": "53",
420 "classification": "regular",
421 "deprecated": false,
422 "spec": null
423 },
424 {
425 "kind": 1337,
426 "name": "Code Snippet",
427 "description": "Code snippet post",
428 "nip": "C0",
429 "classification": "regular",
430 "deprecated": false,
431 "spec": null
432 },
433 {
434 "kind": 1517,
435 "name": "Bitcoin Block",
436 "description": "Bitcoin block data",
437 "nip": null,
438 "classification": "regular",
439 "deprecated": false,
440 "spec": "Nostrocket"
441 },
442 {
443 "kind": 1617,
444 "name": "Patches",
445 "description": "Git patches",
446 "nip": "34",
447 "classification": "regular",
448 "deprecated": false,
449 "spec": null
450 },
451 {
452 "kind": 1618,
453 "name": "Pull Requests",
454 "description": "Git pull request",
455 "nip": "34",
456 "classification": "regular",
457 "deprecated": false,
458 "spec": null
459 },
460 {
461 "kind": 1619,
462 "name": "Pull Request Updates",
463 "description": "Updates to git pull request",
464 "nip": "34",
465 "classification": "regular",
466 "deprecated": false,
467 "spec": null
468 },
469 {
470 "kind": 1621,
471 "name": "Issues",
472 "description": "Git issues",
473 "nip": "34",
474 "classification": "regular",
475 "deprecated": false,
476 "spec": null
477 },
478 {
479 "kind": 1622,
480 "name": "Git Replies",
481 "description": "Replies on git objects",
482 "nip": "34",
483 "classification": "regular",
484 "deprecated": true,
485 "spec": null
486 },
487 {
488 "kind": 1630,
489 "name": "Status",
490 "description": "Git status",
491 "nip": "34",
492 "classification": "regular",
493 "deprecated": false,
494 "spec": null
495 },
496 {
497 "kind": 1631,
498 "name": "Status",
499 "description": "Git status",
500 "nip": "34",
501 "classification": "regular",
502 "deprecated": false,
503 "spec": null
504 },
505 {
506 "kind": 1632,
507 "name": "Status",
508 "description": "Git status",
509 "nip": "34",
510 "classification": "regular",
511 "deprecated": false,
512 "spec": null
513 },
514 {
515 "kind": 1633,
516 "name": "Status",
517 "description": "Git status",
518 "nip": "34",
519 "classification": "regular",
520 "deprecated": false,
521 "spec": null
522 },
523 {
524 "kind": 1808,
525 "name": "Live Stream",
526 "description": "Live streaming event",
527 "nip": null,
528 "classification": "regular",
529 "deprecated": false,
530 "spec": "zap.stream"
531 },
532 {
533 "kind": 1971,
534 "name": "Problem Tracker",
535 "description": "Problem tracking",
536 "nip": null,
537 "classification": "regular",
538 "deprecated": false,
539 "spec": "Nostrocket"
540 },
541 {
542 "kind": 1984,
543 "name": "Reporting",
544 "description": "Report content or users",
545 "nip": "56",
546 "classification": "regular",
547 "deprecated": false,
548 "spec": null
549 },
550 {
551 "kind": 1985,
552 "name": "Label",
553 "description": "Label/tag content with namespace",
554 "nip": "32",
555 "classification": "regular",
556 "deprecated": false,
557 "spec": null
558 },
559 {
560 "kind": 1986,
561 "name": "Relay Reviews",
562 "description": "Reviews of relays",
563 "nip": null,
564 "classification": "regular",
565 "deprecated": false,
566 "spec": null
567 },
568 {
569 "kind": 1987,
570 "name": "AI Embeddings",
571 "description": "AI embeddings/vector lists",
572 "nip": null,
573 "classification": "regular",
574 "deprecated": false,
575 "spec": "NKBIP-02"
576 },
577 {
578 "kind": 2003,
579 "name": "Torrent",
580 "description": "Torrent magnet link",
581 "nip": "35",
582 "classification": "regular",
583 "deprecated": false,
584 "spec": null
585 },
586 {
587 "kind": 2004,
588 "name": "Torrent Comment",
589 "description": "Comment on torrent",
590 "nip": "35",
591 "classification": "regular",
592 "deprecated": false,
593 "spec": null
594 },
595 {
596 "kind": 2022,
597 "name": "Coinjoin Pool",
598 "description": "Coinjoin coordination",
599 "nip": null,
600 "classification": "regular",
601 "deprecated": false,
602 "spec": "joinstr"
603 },
604 {
605 "kind": 4550,
606 "name": "Community Post Approval",
607 "description": "Approve post in community",
608 "nip": "72",
609 "classification": "regular",
610 "deprecated": false,
611 "spec": null
612 },
613 {
614 "kind": 5000,
615 "name": "Job Request",
616 "description": "Data vending machine job request (start of range)",
617 "nip": "90",
618 "classification": "regular",
619 "deprecated": false,
620 "spec": null
621 },
622 {
623 "kind": 6000,
624 "name": "Job Result",
625 "description": "Data vending machine job result (start of range)",
626 "nip": "90",
627 "classification": "regular",
628 "deprecated": false,
629 "spec": null
630 },
631 {
632 "kind": 7000,
633 "name": "Job Feedback",
634 "description": "Feedback on job request/result",
635 "nip": "90",
636 "classification": "regular",
637 "deprecated": false,
638 "spec": null
639 },
640 {
641 "kind": 7374,
642 "name": "Reserved Cashu Wallet Tokens",
643 "description": "Reserved Cashu wallet tokens",
644 "nip": "60",
645 "classification": "regular",
646 "deprecated": false,
647 "spec": null
648 },
649 {
650 "kind": 7375,
651 "name": "Cashu Wallet Tokens",
652 "description": "Cashu wallet tokens",
653 "nip": "60",
654 "classification": "regular",
655 "deprecated": false,
656 "spec": null
657 },
658 {
659 "kind": 7376,
660 "name": "Cashu Wallet History",
661 "description": "Cashu wallet transaction history",
662 "nip": "60",
663 "classification": "regular",
664 "deprecated": false,
665 "spec": null
666 },
667 {
668 "kind": 7516,
669 "name": "Geocache Log",
670 "description": "Geocaching log entry",
671 "nip": null,
672 "classification": "regular",
673 "deprecated": false,
674 "spec": "geocaching"
675 },
676 {
677 "kind": 7517,
678 "name": "Geocache Proof of Find",
679 "description": "Proof of geocache find",
680 "nip": null,
681 "classification": "regular",
682 "deprecated": false,
683 "spec": "geocaching"
684 },
685 {
686 "kind": 8000,
687 "name": "Add User",
688 "description": "Add user to group",
689 "nip": "43",
690 "classification": "regular",
691 "deprecated": false,
692 "spec": null
693 },
694 {
695 "kind": 8001,
696 "name": "Remove User",
697 "description": "Remove user from group",
698 "nip": "43",
699 "classification": "regular",
700 "deprecated": false,
701 "spec": null
702 },
703 {
704 "kind": 9000,
705 "name": "Group Control Events",
706 "description": "Group control events (start of range)",
707 "nip": "29",
708 "classification": "regular",
709 "deprecated": false,
710 "spec": null
711 },
712 {
713 "kind": 9041,
714 "name": "Zap Goal",
715 "description": "Fundraising goal for zaps",
716 "nip": "75",
717 "classification": "regular",
718 "deprecated": false,
719 "spec": null
720 },
721 {
722 "kind": 9321,
723 "name": "Nutzap",
724 "description": "Cashu nutzap",
725 "nip": "61",
726 "classification": "regular",
727 "deprecated": false,
728 "spec": null
729 },
730 {
731 "kind": 9467,
732 "name": "Tidal Login",
733 "description": "Tidal streaming login",
734 "nip": null,
735 "classification": "regular",
736 "deprecated": false,
737 "spec": "Tidal-nostr"
738 },
739 {
740 "kind": 9734,
741 "name": "Zap Request",
742 "description": "Request Lightning payment",
743 "nip": "57",
744 "classification": "regular",
745 "deprecated": false,
746 "spec": null
747 },
748 {
749 "kind": 9735,
750 "name": "Zap",
751 "description": "Lightning payment receipt",
752 "nip": "57",
753 "classification": "regular",
754 "deprecated": false,
755 "spec": null
756 },
757 {
758 "kind": 9802,
759 "name": "Highlights",
760 "description": "Highlighted text selection",
761 "nip": "84",
762 "classification": "regular",
763 "deprecated": false,
764 "spec": null
765 },
766 {
767 "kind": 10000,
768 "name": "Mute List",
769 "description": "List of muted users/content",
770 "nip": "51",
771 "classification": "replaceable",
772 "deprecated": false,
773 "spec": null
774 },
775 {
776 "kind": 10001,
777 "name": "Pin List",
778 "description": "Pinned events",
779 "nip": "51",
780 "classification": "replaceable",
781 "deprecated": false,
782 "spec": null
783 },
784 {
785 "kind": 10002,
786 "name": "Relay List Metadata",
787 "description": "User's preferred relays for read/write",
788 "nip": "65",
789 "classification": "replaceable",
790 "deprecated": false,
791 "spec": null
792 },
793 {
794 "kind": 10003,
795 "name": "Bookmark List",
796 "description": "Bookmarked events",
797 "nip": "51",
798 "classification": "replaceable",
799 "deprecated": false,
800 "spec": null
801 },
802 {
803 "kind": 10004,
804 "name": "Communities List",
805 "description": "Communities user belongs to",
806 "nip": "51",
807 "classification": "replaceable",
808 "deprecated": false,
809 "spec": null
810 },
811 {
812 "kind": 10005,
813 "name": "Public Chats List",
814 "description": "Public chats user is in",
815 "nip": "51",
816 "classification": "replaceable",
817 "deprecated": false,
818 "spec": null
819 },
820 {
821 "kind": 10006,
822 "name": "Blocked Relays List",
823 "description": "Relays user has blocked",
824 "nip": "51",
825 "classification": "replaceable",
826 "deprecated": false,
827 "spec": null
828 },
829 {
830 "kind": 10007,
831 "name": "Search Relays List",
832 "description": "Preferred search relays",
833 "nip": "51",
834 "classification": "replaceable",
835 "deprecated": false,
836 "spec": null
837 },
838 {
839 "kind": 10008,
840 "name": "Relay Group Configuration",
841 "description": "Relay group configuration",
842 "nip": null,
843 "classification": "replaceable",
844 "deprecated": false,
845 "spec": null
846 },
847 {
848 "kind": 10009,
849 "name": "User Groups",
850 "description": "Groups user belongs to",
851 "nip": "29",
852 "classification": "replaceable",
853 "deprecated": false,
854 "spec": null
855 },
856 {
857 "kind": 10012,
858 "name": "Favorite Relays List",
859 "description": "User's favorite relays",
860 "nip": "51",
861 "classification": "replaceable",
862 "deprecated": false,
863 "spec": null
864 },
865 {
866 "kind": 10013,
867 "name": "Private Event Relay List",
868 "description": "Relays for private events",
869 "nip": "37",
870 "classification": "replaceable",
871 "deprecated": false,
872 "spec": null
873 },
874 {
875 "kind": 10015,
876 "name": "Interests List",
877 "description": "User interests/topics",
878 "nip": "51",
879 "classification": "replaceable",
880 "deprecated": false,
881 "spec": null
882 },
883 {
884 "kind": 10019,
885 "name": "Nutzap Mint Recommendation",
886 "description": "Recommended Cashu mints for nutzaps",
887 "nip": "61",
888 "classification": "replaceable",
889 "deprecated": false,
890 "spec": null
891 },
892 {
893 "kind": 10020,
894 "name": "Media Follows",
895 "description": "Followed media accounts",
896 "nip": "51",
897 "classification": "replaceable",
898 "deprecated": false,
899 "spec": null
900 },
901 {
902 "kind": 10030,
903 "name": "User Emoji List",
904 "description": "Custom emoji list",
905 "nip": "51",
906 "classification": "replaceable",
907 "deprecated": false,
908 "spec": null
909 },
910 {
911 "kind": 10050,
912 "name": "DM Relays List",
913 "description": "Relays to receive DMs on",
914 "nip": "17",
915 "classification": "replaceable",
916 "deprecated": false,
917 "spec": null
918 },
919 {
920 "kind": 10051,
921 "name": "KeyPackage Relays List",
922 "description": "Marmot key package relays",
923 "nip": null,
924 "classification": "replaceable",
925 "deprecated": false,
926 "spec": "Marmot"
927 },
928 {
929 "kind": 10063,
930 "name": "User Server List",
931 "description": "Blossom server list",
932 "nip": null,
933 "classification": "replaceable",
934 "deprecated": false,
935 "spec": "Blossom"
936 },
937 {
938 "kind": 10096,
939 "name": "File Storage Server List",
940 "description": "File storage servers",
941 "nip": "96",
942 "classification": "replaceable",
943 "deprecated": true,
944 "spec": null
945 },
946 {
947 "kind": 10166,
948 "name": "Relay Monitor Announcement",
949 "description": "Relay monitoring announcement",
950 "nip": "66",
951 "classification": "replaceable",
952 "deprecated": false,
953 "spec": null
954 },
955 {
956 "kind": 10312,
957 "name": "Room Presence",
958 "description": "Presence in live room",
959 "nip": "53",
960 "classification": "replaceable",
961 "deprecated": false,
962 "spec": null
963 },
964 {
965 "kind": 10377,
966 "name": "Proxy Announcement",
967 "description": "Nostr proxy announcement",
968 "nip": null,
969 "classification": "replaceable",
970 "deprecated": false,
971 "spec": "Nostr Epoxy"
972 },
973 {
974 "kind": 11111,
975 "name": "Transport Method Announcement",
976 "description": "Transport method announcement",
977 "nip": null,
978 "classification": "replaceable",
979 "deprecated": false,
980 "spec": "Nostr Epoxy"
981 },
982 {
983 "kind": 12345,
984 "name": "Relay Policy Configuration",
985 "description": "Relay-internal policy configuration (admin only)",
986 "nip": null,
987 "classification": "replaceable",
988 "deprecated": false,
989 "spec": "orly"
990 },
991 {
992 "kind": 13004,
993 "name": "JWT Binding",
994 "description": "Link between JWT certificate and pubkey",
995 "nip": null,
996 "classification": "replaceable",
997 "deprecated": false,
998 "spec": null
999 },
1000 {
1001 "kind": 13194,
1002 "name": "Wallet Service Info",
1003 "description": "NWC wallet service information",
1004 "nip": "47",
1005 "classification": "replaceable",
1006 "deprecated": false,
1007 "spec": null
1008 },
1009 {
1010 "kind": 13534,
1011 "name": "Membership Lists",
1012 "description": "Group membership lists",
1013 "nip": "43",
1014 "classification": "replaceable",
1015 "deprecated": false,
1016 "spec": null
1017 },
1018 {
1019 "kind": 14388,
1020 "name": "User Sound Effect Lists",
1021 "description": "Sound effect lists",
1022 "nip": null,
1023 "classification": "replaceable",
1024 "deprecated": false,
1025 "spec": "Corny Chat"
1026 },
1027 {
1028 "kind": 17375,
1029 "name": "Cashu Wallet Event",
1030 "description": "Cashu wallet event",
1031 "nip": "60",
1032 "classification": "replaceable",
1033 "deprecated": false,
1034 "spec": null
1035 },
1036 {
1037 "kind": 21000,
1038 "name": "Lightning Pub RPC",
1039 "description": "Lightning.Pub RPC",
1040 "nip": null,
1041 "classification": "ephemeral",
1042 "deprecated": false,
1043 "spec": "Lightning.Pub"
1044 },
1045 {
1046 "kind": 22242,
1047 "name": "Client Authentication",
1048 "description": "Authenticate to relay",
1049 "nip": "42",
1050 "classification": "ephemeral",
1051 "deprecated": false,
1052 "spec": null
1053 },
1054 {
1055 "kind": 23194,
1056 "name": "Wallet Request",
1057 "description": "NWC wallet request",
1058 "nip": "47",
1059 "classification": "ephemeral",
1060 "deprecated": false,
1061 "spec": null
1062 },
1063 {
1064 "kind": 23195,
1065 "name": "Wallet Response",
1066 "description": "NWC wallet response",
1067 "nip": "47",
1068 "classification": "ephemeral",
1069 "deprecated": false,
1070 "spec": null
1071 },
1072 {
1073 "kind": 23196,
1074 "name": "Wallet Notification (NIP-04)",
1075 "description": "NWC wallet notification (NIP-04 encrypted)",
1076 "nip": "47",
1077 "classification": "ephemeral",
1078 "deprecated": false,
1079 "spec": null
1080 },
1081 {
1082 "kind": 23197,
1083 "name": "Wallet Notification",
1084 "description": "NWC wallet notification",
1085 "nip": "47",
1086 "classification": "ephemeral",
1087 "deprecated": false,
1088 "spec": null
1089 },
1090 {
1091 "kind": 24133,
1092 "name": "Nostr Connect",
1093 "description": "Remote signer connection",
1094 "nip": "46",
1095 "classification": "ephemeral",
1096 "deprecated": false,
1097 "spec": null
1098 },
1099 {
1100 "kind": 24242,
1101 "name": "Blobs Stored on Mediaservers",
1102 "description": "Blossom blob storage",
1103 "nip": null,
1104 "classification": "ephemeral",
1105 "deprecated": false,
1106 "spec": "Blossom"
1107 },
1108 {
1109 "kind": 27235,
1110 "name": "HTTP Auth",
1111 "description": "Authenticate HTTP requests",
1112 "nip": "98",
1113 "classification": "ephemeral",
1114 "deprecated": false,
1115 "spec": null
1116 },
1117 {
1118 "kind": 28934,
1119 "name": "Join Request",
1120 "description": "Request to join group",
1121 "nip": "43",
1122 "classification": "ephemeral",
1123 "deprecated": false,
1124 "spec": null
1125 },
1126 {
1127 "kind": 28935,
1128 "name": "Invite Request",
1129 "description": "Invite to group",
1130 "nip": "43",
1131 "classification": "ephemeral",
1132 "deprecated": false,
1133 "spec": null
1134 },
1135 {
1136 "kind": 28936,
1137 "name": "Leave Request",
1138 "description": "Leave group request",
1139 "nip": "43",
1140 "classification": "ephemeral",
1141 "deprecated": false,
1142 "spec": null
1143 },
1144 {
1145 "kind": 30000,
1146 "name": "Follow Sets",
1147 "description": "Categorized people lists",
1148 "nip": "51",
1149 "classification": "parameterized",
1150 "deprecated": false,
1151 "spec": null
1152 },
1153 {
1154 "kind": 30001,
1155 "name": "Generic Lists",
1156 "description": "Generic categorized lists",
1157 "nip": "51",
1158 "classification": "parameterized",
1159 "deprecated": true,
1160 "spec": null
1161 },
1162 {
1163 "kind": 30002,
1164 "name": "Relay Sets",
1165 "description": "Categorized relay lists",
1166 "nip": "51",
1167 "classification": "parameterized",
1168 "deprecated": false,
1169 "spec": null
1170 },
1171 {
1172 "kind": 30003,
1173 "name": "Bookmark Sets",
1174 "description": "Categorized bookmark lists",
1175 "nip": "51",
1176 "classification": "parameterized",
1177 "deprecated": false,
1178 "spec": null
1179 },
1180 {
1181 "kind": 30004,
1182 "name": "Curation Sets",
1183 "description": "Curated content sets",
1184 "nip": "51",
1185 "classification": "parameterized",
1186 "deprecated": false,
1187 "spec": null
1188 },
1189 {
1190 "kind": 30005,
1191 "name": "Video Sets",
1192 "description": "Video playlists",
1193 "nip": "51",
1194 "classification": "parameterized",
1195 "deprecated": false,
1196 "spec": null
1197 },
1198 {
1199 "kind": 30007,
1200 "name": "Kind Mute Sets",
1201 "description": "Muted event kinds",
1202 "nip": "51",
1203 "classification": "parameterized",
1204 "deprecated": false,
1205 "spec": null
1206 },
1207 {
1208 "kind": 30008,
1209 "name": "Profile Badges",
1210 "description": "Badges displayed on profile",
1211 "nip": "58",
1212 "classification": "parameterized",
1213 "deprecated": false,
1214 "spec": null
1215 },
1216 {
1217 "kind": 30009,
1218 "name": "Badge Definition",
1219 "description": "Define a badge/achievement",
1220 "nip": "58",
1221 "classification": "parameterized",
1222 "deprecated": false,
1223 "spec": null
1224 },
1225 {
1226 "kind": 30015,
1227 "name": "Interest Sets",
1228 "description": "Interest/topic sets",
1229 "nip": "51",
1230 "classification": "parameterized",
1231 "deprecated": false,
1232 "spec": null
1233 },
1234 {
1235 "kind": 30017,
1236 "name": "Stall",
1237 "description": "Marketplace stall definition",
1238 "nip": "15",
1239 "classification": "parameterized",
1240 "deprecated": false,
1241 "spec": null
1242 },
1243 {
1244 "kind": 30018,
1245 "name": "Product",
1246 "description": "Marketplace product listing",
1247 "nip": "15",
1248 "classification": "parameterized",
1249 "deprecated": false,
1250 "spec": null
1251 },
1252 {
1253 "kind": 30019,
1254 "name": "Marketplace UI/UX",
1255 "description": "Marketplace interface settings",
1256 "nip": "15",
1257 "classification": "parameterized",
1258 "deprecated": false,
1259 "spec": null
1260 },
1261 {
1262 "kind": 30020,
1263 "name": "Product Sold as Auction",
1264 "description": "Auction product listing",
1265 "nip": "15",
1266 "classification": "parameterized",
1267 "deprecated": false,
1268 "spec": null
1269 },
1270 {
1271 "kind": 30023,
1272 "name": "Long-form Content",
1273 "description": "Blog post, article in markdown",
1274 "nip": "23",
1275 "classification": "parameterized",
1276 "deprecated": false,
1277 "spec": null
1278 },
1279 {
1280 "kind": 30024,
1281 "name": "Draft Long-form Content",
1282 "description": "Draft article",
1283 "nip": "23",
1284 "classification": "parameterized",
1285 "deprecated": false,
1286 "spec": null
1287 },
1288 {
1289 "kind": 30030,
1290 "name": "Emoji Sets",
1291 "description": "Custom emoji sets",
1292 "nip": "51",
1293 "classification": "parameterized",
1294 "deprecated": false,
1295 "spec": null
1296 },
1297 {
1298 "kind": 30040,
1299 "name": "Curated Publication Index",
1300 "description": "Publication index",
1301 "nip": null,
1302 "classification": "parameterized",
1303 "deprecated": false,
1304 "spec": "NKBIP-01"
1305 },
1306 {
1307 "kind": 30041,
1308 "name": "Curated Publication Content",
1309 "description": "Publication content",
1310 "nip": null,
1311 "classification": "parameterized",
1312 "deprecated": false,
1313 "spec": "NKBIP-01"
1314 },
1315 {
1316 "kind": 30063,
1317 "name": "Release Artifact Sets",
1318 "description": "Software release artifacts",
1319 "nip": "51",
1320 "classification": "parameterized",
1321 "deprecated": false,
1322 "spec": null
1323 },
1324 {
1325 "kind": 30078,
1326 "name": "Application-specific Data",
1327 "description": "App-specific key-value storage",
1328 "nip": "78",
1329 "classification": "parameterized",
1330 "deprecated": false,
1331 "spec": null
1332 },
1333 {
1334 "kind": 30166,
1335 "name": "Relay Discovery",
1336 "description": "Relay discovery/monitoring",
1337 "nip": "66",
1338 "classification": "parameterized",
1339 "deprecated": false,
1340 "spec": null
1341 },
1342 {
1343 "kind": 30267,
1344 "name": "App Curation Sets",
1345 "description": "Curated app sets",
1346 "nip": "51",
1347 "classification": "parameterized",
1348 "deprecated": false,
1349 "spec": null
1350 },
1351 {
1352 "kind": 30311,
1353 "name": "Live Event",
1354 "description": "Live streaming event",
1355 "nip": "53",
1356 "classification": "parameterized",
1357 "deprecated": false,
1358 "spec": null
1359 },
1360 {
1361 "kind": 30312,
1362 "name": "Interactive Room",
1363 "description": "Interactive live room",
1364 "nip": "53",
1365 "classification": "parameterized",
1366 "deprecated": false,
1367 "spec": null
1368 },
1369 {
1370 "kind": 30313,
1371 "name": "Conference Event",
1372 "description": "Conference/meetup event",
1373 "nip": "53",
1374 "classification": "parameterized",
1375 "deprecated": false,
1376 "spec": null
1377 },
1378 {
1379 "kind": 30315,
1380 "name": "User Statuses",
1381 "description": "User status updates",
1382 "nip": "38",
1383 "classification": "parameterized",
1384 "deprecated": false,
1385 "spec": null
1386 },
1387 {
1388 "kind": 30388,
1389 "name": "Slide Set",
1390 "description": "Presentation slides",
1391 "nip": null,
1392 "classification": "parameterized",
1393 "deprecated": false,
1394 "spec": "Corny Chat"
1395 },
1396 {
1397 "kind": 30402,
1398 "name": "Classified Listing",
1399 "description": "Classified ad listing",
1400 "nip": "99",
1401 "classification": "parameterized",
1402 "deprecated": false,
1403 "spec": null
1404 },
1405 {
1406 "kind": 30403,
1407 "name": "Draft Classified Listing",
1408 "description": "Draft classified ad",
1409 "nip": "99",
1410 "classification": "parameterized",
1411 "deprecated": false,
1412 "spec": null
1413 },
1414 {
1415 "kind": 30617,
1416 "name": "Repository Announcements",
1417 "description": "Git repository announcement",
1418 "nip": "34",
1419 "classification": "parameterized",
1420 "deprecated": false,
1421 "spec": null
1422 },
1423 {
1424 "kind": 30618,
1425 "name": "Repository State Announcements",
1426 "description": "Git repository state",
1427 "nip": "34",
1428 "classification": "parameterized",
1429 "deprecated": false,
1430 "spec": null
1431 },
1432 {
1433 "kind": 30818,
1434 "name": "Wiki Article",
1435 "description": "Wiki article",
1436 "nip": "54",
1437 "classification": "parameterized",
1438 "deprecated": false,
1439 "spec": null
1440 },
1441 {
1442 "kind": 30819,
1443 "name": "Redirects",
1444 "description": "URL redirects",
1445 "nip": "54",
1446 "classification": "parameterized",
1447 "deprecated": false,
1448 "spec": null
1449 },
1450 {
1451 "kind": 31234,
1452 "name": "Draft Event",
1453 "description": "Draft of any event",
1454 "nip": "37",
1455 "classification": "parameterized",
1456 "deprecated": false,
1457 "spec": null
1458 },
1459 {
1460 "kind": 31388,
1461 "name": "Link Set",
1462 "description": "Link collection",
1463 "nip": null,
1464 "classification": "parameterized",
1465 "deprecated": false,
1466 "spec": "Corny Chat"
1467 },
1468 {
1469 "kind": 31890,
1470 "name": "Feed",
1471 "description": "Custom feed definition",
1472 "nip": null,
1473 "classification": "parameterized",
1474 "deprecated": false,
1475 "spec": "NUD: Custom Feeds"
1476 },
1477 {
1478 "kind": 31922,
1479 "name": "Date-Based Calendar Event",
1480 "description": "All-day calendar event",
1481 "nip": "52",
1482 "classification": "parameterized",
1483 "deprecated": false,
1484 "spec": null
1485 },
1486 {
1487 "kind": 31923,
1488 "name": "Time-Based Calendar Event",
1489 "description": "Calendar event with time",
1490 "nip": "52",
1491 "classification": "parameterized",
1492 "deprecated": false,
1493 "spec": null
1494 },
1495 {
1496 "kind": 31924,
1497 "name": "Calendar",
1498 "description": "Calendar definition",
1499 "nip": "52",
1500 "classification": "parameterized",
1501 "deprecated": false,
1502 "spec": null
1503 },
1504 {
1505 "kind": 31925,
1506 "name": "Calendar Event RSVP",
1507 "description": "RSVP to calendar event",
1508 "nip": "52",
1509 "classification": "parameterized",
1510 "deprecated": false,
1511 "spec": null
1512 },
1513 {
1514 "kind": 31989,
1515 "name": "Handler Recommendation",
1516 "description": "Recommended app for event kind",
1517 "nip": "89",
1518 "classification": "parameterized",
1519 "deprecated": false,
1520 "spec": null
1521 },
1522 {
1523 "kind": 31990,
1524 "name": "Handler Information",
1525 "description": "App handler declaration",
1526 "nip": "89",
1527 "classification": "parameterized",
1528 "deprecated": false,
1529 "spec": null
1530 },
1531 {
1532 "kind": 32123,
1533 "name": "WaveLake Track",
1534 "description": "WaveLake music track",
1535 "nip": null,
1536 "classification": "parameterized",
1537 "deprecated": false,
1538 "spec": "WaveLake"
1539 },
1540 {
1541 "kind": 32267,
1542 "name": "Software Application",
1543 "description": "Software application listing",
1544 "nip": null,
1545 "classification": "parameterized",
1546 "deprecated": false,
1547 "spec": null
1548 },
1549 {
1550 "kind": 32388,
1551 "name": "User Room Favorites",
1552 "description": "Favorite rooms",
1553 "nip": null,
1554 "classification": "parameterized",
1555 "deprecated": false,
1556 "spec": "Corny Chat"
1557 },
1558 {
1559 "kind": 33388,
1560 "name": "High Scores",
1561 "description": "Game high scores",
1562 "nip": null,
1563 "classification": "parameterized",
1564 "deprecated": false,
1565 "spec": "Corny Chat"
1566 },
1567 {
1568 "kind": 34235,
1569 "name": "Video Event Horizontal",
1570 "description": "Horizontal video event",
1571 "nip": "71",
1572 "classification": "parameterized",
1573 "deprecated": false,
1574 "spec": null
1575 },
1576 {
1577 "kind": 34236,
1578 "name": "Video Event Vertical",
1579 "description": "Vertical video event",
1580 "nip": "71",
1581 "classification": "parameterized",
1582 "deprecated": false,
1583 "spec": null
1584 },
1585 {
1586 "kind": 34388,
1587 "name": "Sound Effects",
1588 "description": "Sound effect definitions",
1589 "nip": null,
1590 "classification": "parameterized",
1591 "deprecated": false,
1592 "spec": "Corny Chat"
1593 },
1594 {
1595 "kind": 34550,
1596 "name": "Community Definition",
1597 "description": "Define a community",
1598 "nip": "72",
1599 "classification": "parameterized",
1600 "deprecated": false,
1601 "spec": null
1602 },
1603 {
1604 "kind": 37516,
1605 "name": "Geocache Listing",
1606 "description": "Geocache location listing",
1607 "nip": null,
1608 "classification": "parameterized",
1609 "deprecated": false,
1610 "spec": "geocaching"
1611 },
1612 {
1613 "kind": 38172,
1614 "name": "Cashu Mint Announcement",
1615 "description": "Cashu mint announcement",
1616 "nip": "87",
1617 "classification": "parameterized",
1618 "deprecated": false,
1619 "spec": null
1620 },
1621 {
1622 "kind": 38173,
1623 "name": "Fedimint Announcement",
1624 "description": "Fedimint announcement",
1625 "nip": "87",
1626 "classification": "parameterized",
1627 "deprecated": false,
1628 "spec": null
1629 },
1630 {
1631 "kind": 38383,
1632 "name": "Peer-to-peer Order Events",
1633 "description": "P2P trading orders",
1634 "nip": "69",
1635 "classification": "parameterized",
1636 "deprecated": false,
1637 "spec": null
1638 },
1639 {
1640 "kind": 39000,
1641 "name": "Group Metadata Events",
1642 "description": "Group metadata (start of range)",
1643 "nip": "29",
1644 "classification": "parameterized",
1645 "deprecated": false,
1646 "spec": null
1647 },
1648 {
1649 "kind": 39089,
1650 "name": "Starter Packs",
1651 "description": "Starter pack lists",
1652 "nip": "51",
1653 "classification": "parameterized",
1654 "deprecated": false,
1655 "spec": null
1656 },
1657 {
1658 "kind": 39092,
1659 "name": "Media Starter Packs",
1660 "description": "Media starter packs",
1661 "nip": "51",
1662 "classification": "parameterized",
1663 "deprecated": false,
1664 "spec": null
1665 },
1666 {
1667 "kind": 39701,
1668 "name": "Web Bookmarks",
1669 "description": "Web URL bookmarks",
1670 "nip": "B0",
1671 "classification": "parameterized",
1672 "deprecated": false,
1673 "spec": null
1674 },
1675 {
1676 "kind": 39998,
1677 "name": "ACL Event",
1678 "description": "Access control list event",
1679 "nip": null,
1680 "classification": "parameterized",
1681 "deprecated": false,
1682 "spec": null
1683 }
1684 ];
1685
1686 export const KIND_RANGES: KindRanges = {
1687 "regular": {
1688 "start": 1000,
1689 "end": 9999,
1690 "description": "Regular events - all versions kept, never replaced"
1691 },
1692 "replaceable": {
1693 "start": 10000,
1694 "end": 19999,
1695 "description": "Replaceable events - only latest per pubkey kept"
1696 },
1697 "ephemeral": {
1698 "start": 20000,
1699 "end": 29999,
1700 "description": "Ephemeral events - forwarded but not stored"
1701 },
1702 "parameterized": {
1703 "start": 30000,
1704 "end": 39999,
1705 "description": "Parameterized replaceable - replaced by d tag value"
1706 }
1707 };
1708
1709 export const PRIVILEGED_KINDS: number[] = [4,13,14,15,1059,1060,30078];
1710
1711 export const DIRECTORY_KINDS: number[] = [0,3,5,1984,10002,10000,10050];
1712
1713 export const KIND_ALIASES: Record<string, number> = {
1714 "SetMetadata": 0,
1715 "Follows": 3,
1716 "Contacts": 3,
1717 "Deletion": 5,
1718 "MemoryHole": 1984,
1719 "BlockList": 10000,
1720 "Article": 30023,
1721 "CategorizedPeopleList": 30000,
1722 "CategorizedBookmarksList": 30001
1723 };
1724
1725 // Lookup map for fast access
1726 const kindMap = new Map<number, KindInfo>(EVENT_KINDS.map(k => [k.kind, k]));
1727
1728 export function getKindInfo(kind: number): KindInfo | undefined {
1729 return kindMap.get(kind);
1730 }
1731
1732 export function getKindName(kind: number): string {
1733 const info = kindMap.get(kind);
1734 return info ? info.name : `Kind ${kind}`;
1735 }
1736
1737 export function isReplaceable(kind: number): boolean {
1738 if (kind === 0 || kind === 3) return true;
1739 return kind >= KIND_RANGES.replaceable.start && kind < KIND_RANGES.replaceable.end;
1740 }
1741
1742 export function isEphemeral(kind: number): boolean {
1743 return kind >= KIND_RANGES.ephemeral.start && kind < KIND_RANGES.ephemeral.end;
1744 }
1745
1746 export function isParameterized(kind: number): boolean {
1747 return kind >= KIND_RANGES.parameterized.start && kind <= KIND_RANGES.parameterized.end;
1748 }
1749
1750 export function isPrivileged(kind: number): boolean {
1751 return PRIVILEGED_KINDS.includes(kind);
1752 }
1753
1754 export function isDirectoryKind(kind: number): boolean {
1755 return DIRECTORY_KINDS.includes(kind);
1756 }
1757