upleb.uk

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

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--C1.md54
1 files changed, 9 insertions, 45 deletions
diff --git a/C1.md b/C1.md
index 8137b8e..2b9ffab 100644
--- a/C1.md
+++ b/C1.md
@@ -46,7 +46,7 @@ An addressable event kind `39382` serves as a pointer to collaboratively-owned c
46| `k` | Yes | Target event kind (any kind) | 46| `k` | Yes | Target event kind (any kind) |
47| `p` | Yes | Owner pubkeys (one or more) | 47| `p` | Yes | Owner pubkeys (one or more) |
48 48
49The creator's pubkey is implicitly an owner and SHOULD NOT appear in `p` tags. 49The creator's pubkey is implicitly an owner.
50 50
51### Target Events 51### Target Events
52 52
@@ -67,21 +67,13 @@ Any event kind MAY be a target of collaborative ownership. All target events:
67} 67}
68``` 68```
69 69
70The `d` tag is required regardless of whether the target kind is normally addressable. For addressable event kinds (30000-39999), the `d` tag serves its usual role. For all other kinds, the `d` tag enables grouping and correlation with the pointer.
71
72### Resolution Algorithm 70### Resolution Algorithm
73 71
74To resolve the current state of collaboratively-owned content: 72To resolve the current state of collaboratively-owned content:
75 73
761. Parse the `39382` pointer event to extract owners (`p` tags) and target kind (`k` tag) 741. Collect owners from the `39382` pointer's `p` tags (plus the pointer's pubkey)
772. Extract the identifier from the `d` tag 752. Query: `{"kinds": [<target-kind>], "authors": [<all-owners>], "#d": ["<identifier>"], "limit": 1}`
783. Query: `{"kinds": [<target-kind>], "authors": [<all-owners>], "#d": ["<identifier>"]}` 763. Return the most recent event
794. For addressable target kinds: return the event with the highest `created_at`
805. For non-addressable target kinds: return all matching events that contain a valid `a` tag backlinking to the pointer
81
82### Initial Discovery
83
84Clients that do not yet have any version of the event MUST query by `#d` tag alone or by known owner pubkeys.
85 77
86## Client Behavior 78## Client Behavior
87 79
@@ -94,13 +86,7 @@ Clients SHOULD NOT display co-author attribution for a target event unless:
94 86
95An event without a verifiable `a` tag backlink to a `39382` pointer MUST NOT be presented as collaboratively authored. This prevents spoofed co-authorship claims. 87An event without a verifiable `a` tag backlink to a `39382` pointer MUST NOT be presented as collaboratively authored. This prevents spoofed co-authorship claims.
96 88
97### Display Recommendations 89## Example
98
99- Clients SHOULD display which pubkey signed each version
100- Clients SHOULD indicate when an event is part of a collaborative set
101- Clients MAY show the full owner set from the pointer event alongside the signing pubkey
102
103## Examples
104 90
105### Pointer Event 91### Pointer Event
106 92
@@ -118,7 +104,7 @@ An event without a verifiable `a` tag backlink to a `39382` pointer MUST NOT be
118} 104}
119``` 105```
120 106
121### Addressable Target (kind 30023) 107### Target Event (by any owner)
122 108
123```jsonc 109```jsonc
124{ 110{
@@ -133,30 +119,8 @@ An event without a verifiable `a` tag backlink to a `39382` pointer MUST NOT be
133} 119}
134``` 120```
135 121
136### Non-Addressable Target (kind 4199)
137
138```jsonc
139{
140 "kind": 4199,
141 "pubkey": "carol-pubkey",
142 "tags": [
143 ["d", "collaborative-guide"],
144 ["a", "39382:alice-pubkey:collaborative-guide"]
145 ],
146 "content": "..."
147}
148```
149
150### Client Resolution 122### Client Resolution
151 123
1521. Client receives `naddr` for the `39382` pointer 1241. Client receives the `39382` pointer
1532. Parses owners: `[alice, bob, carol]`, target kind: `30023` 1252. Owners: `[alice, bob, carol]`, target kind: `30023`
1543. Queries: `{"kinds": [30023], "authors": ["alice", "bob", "carol"], "#d": ["collaborative-guide"]}` 1263. Queries: `{"kinds": [30023], "authors": ["alice", "bob", "carol"], "#d": ["collaborative-guide"], "limit": 1}`
1554. Filters results: only events with `["a", "39382:alice-pubkey:collaborative-guide"]` are considered collaborative
1565. Returns most recent version (for addressable kinds) or full set (for non-addressable kinds)
157
158## Security Considerations
159
160- Owners can unilaterally modify content
161- An `a` tag backlink alone is insufficient — clients MUST verify the referenced pointer event includes the author in its `p` tags
162- Owner changes on the pointer event take effect immediately; old target events from removed owners are no longer authoritative