@openvtc/trust-tasks 0.20.6 → 0.20.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (152) hide show
  1. package/CHANGELOG.md +138 -0
  2. package/dist/_shared/components.d.ts +55 -6
  3. package/dist/_shared/components.d.ts.map +1 -1
  4. package/dist/auth/step-up/approve-request/0.3/payload.d.ts +613 -0
  5. package/dist/auth/step-up/approve-request/0.3/payload.d.ts.map +1 -0
  6. package/dist/auth/step-up/approve-request/0.3/payload.js +345 -0
  7. package/dist/auth/step-up/approve-request/0.3/payload.js.map +1 -0
  8. package/dist/auth/step-up/approve-response/0.4/payload.d.ts +887 -0
  9. package/dist/auth/step-up/approve-response/0.4/payload.d.ts.map +1 -0
  10. package/dist/auth/step-up/approve-response/0.4/payload.js +504 -0
  11. package/dist/auth/step-up/approve-response/0.4/payload.js.map +1 -0
  12. package/dist/backup/abort/0.1/payload.d.ts +262 -0
  13. package/dist/backup/abort/0.1/payload.d.ts.map +1 -0
  14. package/dist/backup/abort/0.1/payload.js +146 -0
  15. package/dist/backup/abort/0.1/payload.js.map +1 -0
  16. package/dist/backup/complete-export/0.1/payload.d.ts +262 -0
  17. package/dist/backup/complete-export/0.1/payload.d.ts.map +1 -0
  18. package/dist/backup/complete-export/0.1/payload.js +146 -0
  19. package/dist/backup/complete-export/0.1/payload.js.map +1 -0
  20. package/dist/backup/finalize-import/0.1/payload.d.ts +395 -0
  21. package/dist/backup/finalize-import/0.1/payload.d.ts.map +1 -0
  22. package/dist/backup/finalize-import/0.1/payload.js +209 -0
  23. package/dist/backup/finalize-import/0.1/payload.js.map +1 -0
  24. package/dist/backup/get-chunk/0.1/payload.d.ts +461 -0
  25. package/dist/backup/get-chunk/0.1/payload.d.ts.map +1 -0
  26. package/dist/backup/get-chunk/0.1/payload.js +250 -0
  27. package/dist/backup/get-chunk/0.1/payload.js.map +1 -0
  28. package/dist/backup/initiate-export/0.1/payload.d.ts +896 -0
  29. package/dist/backup/initiate-export/0.1/payload.d.ts.map +1 -0
  30. package/dist/backup/initiate-export/0.1/payload.js +507 -0
  31. package/dist/backup/initiate-export/0.1/payload.js.map +1 -0
  32. package/dist/backup/initiate-import/0.1/payload.d.ts +888 -0
  33. package/dist/backup/initiate-import/0.1/payload.d.ts.map +1 -0
  34. package/dist/backup/initiate-import/0.1/payload.js +504 -0
  35. package/dist/backup/initiate-import/0.1/payload.js.map +1 -0
  36. package/dist/backup/put-chunk/0.1/payload.d.ts +495 -0
  37. package/dist/backup/put-chunk/0.1/payload.d.ts.map +1 -0
  38. package/dist/backup/put-chunk/0.1/payload.js +265 -0
  39. package/dist/backup/put-chunk/0.1/payload.js.map +1 -0
  40. package/dist/git-ns/_shared/0.1/git-ns.d.ts +1 -1
  41. package/dist/git-ns/_shared/0.1/git-ns.d.ts.map +1 -1
  42. package/dist/git-ns/_shared/0.2/git-ns.d.ts +1 -1
  43. package/dist/git-ns/_shared/0.2/git-ns.d.ts.map +1 -1
  44. package/dist/git-ns/_shared/0.3/git-ns.d.ts +16 -0
  45. package/dist/git-ns/_shared/0.3/git-ns.d.ts.map +1 -0
  46. package/dist/git-ns/_shared/0.3/git-ns.js +6 -0
  47. package/dist/git-ns/_shared/0.3/git-ns.js.map +1 -0
  48. package/dist/git-ns/bridge/job/0.1/payload.d.ts +1 -1
  49. package/dist/git-ns/bridge/job/0.1/payload.d.ts.map +1 -1
  50. package/dist/git-ns/bridge/job/0.2/payload.d.ts +1 -1
  51. package/dist/git-ns/bridge/job/0.2/payload.d.ts.map +1 -1
  52. package/dist/git-ns/bridge/job/0.3/payload.d.ts +1068 -0
  53. package/dist/git-ns/bridge/job/0.3/payload.d.ts.map +1 -0
  54. package/dist/git-ns/bridge/job/0.3/payload.js +573 -0
  55. package/dist/git-ns/bridge/job/0.3/payload.js.map +1 -0
  56. package/dist/git-ns/drift/resolve/0.1/payload.d.ts +1 -1
  57. package/dist/git-ns/drift/resolve/0.1/payload.d.ts.map +1 -1
  58. package/dist/git-ns/drift/resolve/0.2/payload.d.ts +1060 -0
  59. package/dist/git-ns/drift/resolve/0.2/payload.d.ts.map +1 -0
  60. package/dist/git-ns/drift/resolve/0.2/payload.js +630 -0
  61. package/dist/git-ns/drift/resolve/0.2/payload.js.map +1 -0
  62. package/dist/git-ns/namespace/reseat/0.1/payload.d.ts +1 -1
  63. package/dist/git-ns/namespace/reseat/0.1/payload.d.ts.map +1 -1
  64. package/dist/git-ns/namespace/reseat/0.2/payload.d.ts +515 -0
  65. package/dist/git-ns/namespace/reseat/0.2/payload.d.ts.map +1 -0
  66. package/dist/git-ns/namespace/reseat/0.2/payload.js +296 -0
  67. package/dist/git-ns/namespace/reseat/0.2/payload.js.map +1 -0
  68. package/dist/git-ns/repo/adopt/0.1/payload.d.ts +1 -1
  69. package/dist/git-ns/repo/adopt/0.1/payload.d.ts.map +1 -1
  70. package/dist/git-ns/repo/adopt/0.2/payload.d.ts +962 -0
  71. package/dist/git-ns/repo/adopt/0.2/payload.d.ts.map +1 -0
  72. package/dist/git-ns/repo/adopt/0.2/payload.js +583 -0
  73. package/dist/git-ns/repo/adopt/0.2/payload.js.map +1 -0
  74. package/dist/git-ns/repo/archive/0.1/payload.d.ts +1 -1
  75. package/dist/git-ns/repo/archive/0.1/payload.d.ts.map +1 -1
  76. package/dist/git-ns/repo/archive/0.2/payload.d.ts +959 -0
  77. package/dist/git-ns/repo/archive/0.2/payload.d.ts.map +1 -0
  78. package/dist/git-ns/repo/archive/0.2/payload.js +584 -0
  79. package/dist/git-ns/repo/archive/0.2/payload.js.map +1 -0
  80. package/dist/git-ns/repo/create/0.1/payload.d.ts +1 -1
  81. package/dist/git-ns/repo/create/0.1/payload.d.ts.map +1 -1
  82. package/dist/git-ns/repo/create/0.2/payload.d.ts +1074 -0
  83. package/dist/git-ns/repo/create/0.2/payload.d.ts.map +1 -0
  84. package/dist/git-ns/repo/create/0.2/payload.js +636 -0
  85. package/dist/git-ns/repo/create/0.2/payload.js.map +1 -0
  86. package/dist/git-ns/repo/transfer/0.1/payload.d.ts +1 -1
  87. package/dist/git-ns/repo/transfer/0.1/payload.d.ts.map +1 -1
  88. package/dist/git-ns/repo/transfer/0.2/payload.d.ts +947 -0
  89. package/dist/git-ns/repo/transfer/0.2/payload.d.ts.map +1 -0
  90. package/dist/git-ns/repo/transfer/0.2/payload.js +577 -0
  91. package/dist/git-ns/repo/transfer/0.2/payload.js.map +1 -0
  92. package/dist/git-ns/right/grant/0.1/payload.d.ts +1 -1
  93. package/dist/git-ns/right/grant/0.1/payload.d.ts.map +1 -1
  94. package/dist/git-ns/right/grant/0.2/payload.d.ts +506 -0
  95. package/dist/git-ns/right/grant/0.2/payload.d.ts.map +1 -0
  96. package/dist/git-ns/right/grant/0.2/payload.js +289 -0
  97. package/dist/git-ns/right/grant/0.2/payload.js.map +1 -0
  98. package/dist/git-ns/right/revoke/0.1/payload.d.ts +1 -1
  99. package/dist/git-ns/right/revoke/0.1/payload.d.ts.map +1 -1
  100. package/dist/git-ns/right/revoke/0.2/payload.d.ts +492 -0
  101. package/dist/git-ns/right/revoke/0.2/payload.d.ts.map +1 -0
  102. package/dist/git-ns/right/revoke/0.2/payload.js +284 -0
  103. package/dist/git-ns/right/revoke/0.2/payload.js.map +1 -0
  104. package/dist/git-ns/view/0.1/payload.d.ts +1 -1
  105. package/dist/git-ns/view/0.1/payload.d.ts.map +1 -1
  106. package/dist/git-ns/view/0.2/payload.d.ts +1 -1
  107. package/dist/git-ns/view/0.2/payload.d.ts.map +1 -1
  108. package/dist/git-ns/view/0.3/payload.d.ts +1524 -0
  109. package/dist/git-ns/view/0.3/payload.d.ts.map +1 -0
  110. package/dist/git-ns/view/0.3/payload.js +918 -0
  111. package/dist/git-ns/view/0.3/payload.js.map +1 -0
  112. package/dist/index.d.ts +20 -0
  113. package/dist/index.d.ts.map +1 -1
  114. package/dist/index.js +20 -0
  115. package/dist/index.js.map +1 -1
  116. package/package.json +1 -1
  117. package/src/_shared/components.ts +55 -6
  118. package/src/auth/step-up/approve-request/0.3/payload.ts +421 -0
  119. package/src/auth/step-up/approve-response/0.4/payload.ts +593 -0
  120. package/src/backup/abort/0.1/payload.ts +191 -0
  121. package/src/backup/complete-export/0.1/payload.ts +191 -0
  122. package/src/backup/finalize-import/0.1/payload.ts +279 -0
  123. package/src/backup/get-chunk/0.1/payload.ts +308 -0
  124. package/src/backup/initiate-export/0.1/payload.ts +564 -0
  125. package/src/backup/initiate-import/0.1/payload.ts +561 -0
  126. package/src/backup/put-chunk/0.1/payload.ts +331 -0
  127. package/src/git-ns/_shared/0.1/git-ns.ts +1 -1
  128. package/src/git-ns/_shared/0.2/git-ns.ts +1 -1
  129. package/src/git-ns/_shared/0.3/git-ns.ts +17 -0
  130. package/src/git-ns/bridge/job/0.1/payload.ts +1 -1
  131. package/src/git-ns/bridge/job/0.2/payload.ts +1 -1
  132. package/src/git-ns/bridge/job/0.3/payload.ts +691 -0
  133. package/src/git-ns/drift/resolve/0.1/payload.ts +1 -1
  134. package/src/git-ns/drift/resolve/0.2/payload.ts +699 -0
  135. package/src/git-ns/namespace/reseat/0.1/payload.ts +1 -1
  136. package/src/git-ns/namespace/reseat/0.2/payload.ts +342 -0
  137. package/src/git-ns/repo/adopt/0.1/payload.ts +1 -1
  138. package/src/git-ns/repo/adopt/0.2/payload.ts +628 -0
  139. package/src/git-ns/repo/archive/0.1/payload.ts +1 -1
  140. package/src/git-ns/repo/archive/0.2/payload.ts +626 -0
  141. package/src/git-ns/repo/create/0.1/payload.ts +1 -1
  142. package/src/git-ns/repo/create/0.2/payload.ts +689 -0
  143. package/src/git-ns/repo/transfer/0.1/payload.ts +1 -1
  144. package/src/git-ns/repo/transfer/0.2/payload.ts +619 -0
  145. package/src/git-ns/right/grant/0.1/payload.ts +1 -1
  146. package/src/git-ns/right/grant/0.2/payload.ts +340 -0
  147. package/src/git-ns/right/revoke/0.1/payload.ts +1 -1
  148. package/src/git-ns/right/revoke/0.2/payload.ts +331 -0
  149. package/src/git-ns/view/0.1/payload.ts +1 -1
  150. package/src/git-ns/view/0.2/payload.ts +1 -1
  151. package/src/git-ns/view/0.3/payload.ts +981 -0
  152. package/src/index.ts +20 -0
@@ -3,7 +3,7 @@
3
3
  * Source: specs/git-ns/namespace/reseat/0.1/payload.schema.json
4
4
  */
5
5
 
6
- import type { Did, Ext, NamespaceId, Resource, Right, RightRecord } from "../../../../_shared/components.js";
6
+ import type { Did_GitNsV0_1 as Did, Ext, NamespaceId, Resource, Right, RightRecord_GitNsV0_1 as RightRecord } from "../../../../_shared/components.js";
7
7
 
8
8
 
9
9
  /**
@@ -0,0 +1,342 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/git-ns/namespace/reseat/0.2/payload.schema.json
4
+ */
5
+
6
+ import type { Did_GitNsV0_3 as Did, Ext, NamespaceId, Resource, Right, RightRecord_GitNsV0_3 as RightRecord } from "../../../../_shared/components.js";
7
+
8
+
9
+ /**
10
+ * A community administrator recovers a headless bound namespace — one with no live git.ns.admin — by granting git.ns.admin on it to a current member. Refused unless the namespace is headless.
11
+ */
12
+ export interface GitNamespacesReseatNamespacePayload {
13
+ /**
14
+ * The headless namespace.
15
+ */
16
+ namespace: NamespaceId;
17
+ /**
18
+ * The current member who receives git.ns.admin on the namespace. May be the administrator themselves.
19
+ */
20
+ subject: Did;
21
+ /**
22
+ * Why the namespace is being reseated and why to this member, in the administrator's words. Kept in the audit record, recorded as the new right's `reason`, and shown to the namespace's repository owners.
23
+ */
24
+ statement: string;
25
+ ext?: Ext;
26
+ }
27
+ /**
28
+ * The recorded git.ns.admin right.
29
+ */
30
+ export interface GitNamespacesReseatNamespaceResponsePayload {
31
+ /**
32
+ * The git.ns.admin record the reseat created. It never carries `expiresAt`.
33
+ */
34
+ right: RightRecord;
35
+ ext?: Ext;
36
+ }
37
+
38
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
39
+ export type { Did, Ext, NamespaceId, Resource, Right, RightRecord };
40
+
41
+ /** Trust Task type URI. */
42
+ export const TYPE_URI = "https://trusttasks.org/spec/git-ns/namespace/reseat/0.2" as const;
43
+
44
+ /** Stable alias for this specification's request payload shape. */
45
+ export type Payload = GitNamespacesReseatNamespacePayload;
46
+
47
+ /** Trust Task response type URI (request type URI + "#response"). */
48
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/git-ns/namespace/reseat/0.2#response" as const;
49
+
50
+ /** Stable alias for this specification's success-response payload shape. */
51
+ export type Response = GitNamespacesReseatNamespaceResponsePayload;
52
+
53
+ /**
54
+ * This specification's payload schema, as a value.
55
+ *
56
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
57
+ * rather than only as a `.json` file because TypeScript types are erased
58
+ * at runtime: without a schema a consumer has nothing to validate, and
59
+ * every REQUIRED payload member is optional in practice. Cross-file
60
+ * `$ref`s are already inlined, so it needs no resolver.
61
+ */
62
+ export const PAYLOAD_SCHEMA = {
63
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
64
+ "$id": "https://trusttasks.org/spec/git-ns/namespace/reseat/0.2",
65
+ "title": "Git Namespaces — Reseat Namespace — payload",
66
+ "description": "A community administrator recovers a headless bound namespace — one with no live git.ns.admin — by granting git.ns.admin on it to a current member. Refused unless the namespace is headless.",
67
+ "type": "object",
68
+ "additionalProperties": false,
69
+ "required": [
70
+ "namespace",
71
+ "subject",
72
+ "statement"
73
+ ],
74
+ "properties": {
75
+ "namespace": {
76
+ "$ref": "#/$defs/NamespaceId",
77
+ "description": "The headless namespace."
78
+ },
79
+ "subject": {
80
+ "$ref": "#/$defs/Did",
81
+ "description": "The current member who receives git.ns.admin on the namespace. May be the administrator themselves."
82
+ },
83
+ "statement": {
84
+ "type": "string",
85
+ "minLength": 1,
86
+ "maxLength": 1024,
87
+ "description": "Why the namespace is being reseated and why to this member, in the administrator's words. Kept in the audit record, recorded as the new right's `reason`, and shown to the namespace's repository owners."
88
+ },
89
+ "ext": {
90
+ "$ref": "#/$defs/Ext"
91
+ }
92
+ },
93
+ "$defs": {
94
+ "Response": {
95
+ "$anchor": "response",
96
+ "title": "Git Namespaces — Reseat Namespace — response payload",
97
+ "description": "The recorded git.ns.admin right.",
98
+ "type": "object",
99
+ "additionalProperties": false,
100
+ "required": [
101
+ "right"
102
+ ],
103
+ "properties": {
104
+ "right": {
105
+ "$ref": "#/$defs/RightRecord",
106
+ "description": "The git.ns.admin record the reseat created. It never carries `expiresAt`."
107
+ },
108
+ "ext": {
109
+ "$ref": "#/$defs/Ext"
110
+ }
111
+ }
112
+ },
113
+ "Ext": {
114
+ "title": "Ext",
115
+ "description": "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.",
116
+ "type": "object",
117
+ "minProperties": 1,
118
+ "additionalProperties": true,
119
+ "propertyNames": {
120
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
121
+ }
122
+ },
123
+ "RightRecord": {
124
+ "title": "RightRecord",
125
+ "description": "One recorded right. Implied rights (§4.2 of the rights model: `own` implies `maintain` implies `commit.sign` on the same resource; `ns.admin` implies `repo.create` and `own` across its namespace) are not records and never appear as RightRecords.",
126
+ "type": "object",
127
+ "additionalProperties": false,
128
+ "required": [
129
+ "subject",
130
+ "right",
131
+ "resource",
132
+ "grantedBy",
133
+ "grantedAt"
134
+ ],
135
+ "properties": {
136
+ "subject": {
137
+ "$ref": "#/$defs/Did",
138
+ "description": "Who holds the right. For `git.commit.sign` this is the DID whose commit signatures the CI check accepts."
139
+ },
140
+ "right": {
141
+ "$ref": "#/$defs/Right"
142
+ },
143
+ "resource": {
144
+ "$ref": "#/$defs/Resource"
145
+ },
146
+ "grantedBy": {
147
+ "$ref": "#/$defs/Did",
148
+ "description": "The actor whose task caused the right: the granter, the creator of a repository (for its first `own`), the adopting admin, the transferring owner, or the binding admin (for the first `git.ns.admin`). The VTC's own DID for a right it derives from its configuration."
149
+ },
150
+ "grantedAt": {
151
+ "type": "string",
152
+ "format": "date-time"
153
+ },
154
+ "expiresAt": {
155
+ "type": "string",
156
+ "format": "date-time",
157
+ "description": "When the right lapses. Absent: no expiry."
158
+ },
159
+ "reason": {
160
+ "type": "string",
161
+ "maxLength": 1024,
162
+ "description": "The granter's free-text reason. Disclosed only to holders of `git.repo.own` on the resource and of `git.ns.admin` over it."
163
+ }
164
+ }
165
+ },
166
+ "Did": {
167
+ "title": "Did",
168
+ "description": "A bare DID in the W3C DID Core syntax (§3.1): `did:`, a method name of lowercase letters and digits, `:`, and a method-specific id of colon-separated segments drawn from `A-Z a-z 0-9 . - _` and percent-encoded octets, the last segment non-empty. A DID URL is not a DID: no path, query or fragment (`/`, `?`, `#`), so a verification-method id such as `did:key:z6Mk…#z6Mk…` is refused. Compared by exact string equality — no case folding or percent-decoding. A consumer MUST still treat the value as data: the pattern keeps shell metacharacters, whitespace and quotes out of the wire form, but it does not make a DID safe to splice into a command or markup.",
169
+ "type": "string",
170
+ "maxLength": 2048,
171
+ "pattern": "^did:[a-z0-9]+:(?:(?:[A-Za-z0-9._-]|%[0-9A-Fa-f]{2})*:)*(?:[A-Za-z0-9._-]|%[0-9A-Fa-f]{2})+$"
172
+ },
173
+ "Resource": {
174
+ "title": "Resource",
175
+ "description": "A forge-qualified resource: `<forge-host>/<owner>` for a namespace, or `<forge-host>/<owner>/<repo>` for one repository, all lowercase — `github.com/acme`, `github.com/acme/widgets`, `codeberg.org/acme`. The forge is never implied: `acme/widgets` alone is not a resource. Containment is by whole segment: `github.com/acme` contains `github.com/acme/widgets` and does not contain `github.com/acme-labs/x` or `codeberg.org/acme/widgets`.",
176
+ "type": "string",
177
+ "maxLength": 455,
178
+ "pattern": "^[a-z0-9](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]*[a-z0-9])?)+(?:/[a-z0-9_-][a-z0-9._-]{0,99}){1,2}$"
179
+ },
180
+ "Right": {
181
+ "title": "Right",
182
+ "description": "One of the five git rights. Each string is also the TRQP `action` the VTC publishes the right under in its Trust Registry, so it is carried verbatim. `git.ns.admin` and `git.repo.create` apply to a namespace resource; `git.repo.own` and `git.repo.maintain` to a repository resource; `git.commit.sign` to either.",
183
+ "type": "string",
184
+ "enum": [
185
+ "git.ns.admin",
186
+ "git.repo.create",
187
+ "git.repo.own",
188
+ "git.repo.maintain",
189
+ "git.commit.sign"
190
+ ]
191
+ },
192
+ "NamespaceId": {
193
+ "title": "NamespaceId",
194
+ "description": "The VTC's opaque identifier for a namespace, assigned when it is bound. Stable for the life of the binding; never reused for another binding.",
195
+ "type": "string",
196
+ "minLength": 1,
197
+ "maxLength": 128
198
+ }
199
+ }
200
+ } as const;
201
+
202
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
203
+ export const RESPONSE_PAYLOAD_SCHEMA = {
204
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
205
+ "$ref": "#/$defs/Response",
206
+ "$defs": {
207
+ "Response": {
208
+ "$anchor": "response",
209
+ "title": "Git Namespaces — Reseat Namespace — response payload",
210
+ "description": "The recorded git.ns.admin right.",
211
+ "type": "object",
212
+ "additionalProperties": false,
213
+ "required": [
214
+ "right"
215
+ ],
216
+ "properties": {
217
+ "right": {
218
+ "$ref": "#/$defs/RightRecord",
219
+ "description": "The git.ns.admin record the reseat created. It never carries `expiresAt`."
220
+ },
221
+ "ext": {
222
+ "$ref": "#/$defs/Ext"
223
+ }
224
+ }
225
+ },
226
+ "Ext": {
227
+ "title": "Ext",
228
+ "description": "Vendor-namespaced extension object per SPEC.md §4.5.1. Each immediate key MUST be a reverse-DNS namespace; structure under each namespace is opaque to the framework.",
229
+ "type": "object",
230
+ "minProperties": 1,
231
+ "additionalProperties": true,
232
+ "propertyNames": {
233
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
234
+ }
235
+ },
236
+ "RightRecord": {
237
+ "title": "RightRecord",
238
+ "description": "One recorded right. Implied rights (§4.2 of the rights model: `own` implies `maintain` implies `commit.sign` on the same resource; `ns.admin` implies `repo.create` and `own` across its namespace) are not records and never appear as RightRecords.",
239
+ "type": "object",
240
+ "additionalProperties": false,
241
+ "required": [
242
+ "subject",
243
+ "right",
244
+ "resource",
245
+ "grantedBy",
246
+ "grantedAt"
247
+ ],
248
+ "properties": {
249
+ "subject": {
250
+ "$ref": "#/$defs/Did",
251
+ "description": "Who holds the right. For `git.commit.sign` this is the DID whose commit signatures the CI check accepts."
252
+ },
253
+ "right": {
254
+ "$ref": "#/$defs/Right"
255
+ },
256
+ "resource": {
257
+ "$ref": "#/$defs/Resource"
258
+ },
259
+ "grantedBy": {
260
+ "$ref": "#/$defs/Did",
261
+ "description": "The actor whose task caused the right: the granter, the creator of a repository (for its first `own`), the adopting admin, the transferring owner, or the binding admin (for the first `git.ns.admin`). The VTC's own DID for a right it derives from its configuration."
262
+ },
263
+ "grantedAt": {
264
+ "type": "string",
265
+ "format": "date-time"
266
+ },
267
+ "expiresAt": {
268
+ "type": "string",
269
+ "format": "date-time",
270
+ "description": "When the right lapses. Absent: no expiry."
271
+ },
272
+ "reason": {
273
+ "type": "string",
274
+ "maxLength": 1024,
275
+ "description": "The granter's free-text reason. Disclosed only to holders of `git.repo.own` on the resource and of `git.ns.admin` over it."
276
+ }
277
+ }
278
+ },
279
+ "Did": {
280
+ "title": "Did",
281
+ "description": "A bare DID in the W3C DID Core syntax (§3.1): `did:`, a method name of lowercase letters and digits, `:`, and a method-specific id of colon-separated segments drawn from `A-Z a-z 0-9 . - _` and percent-encoded octets, the last segment non-empty. A DID URL is not a DID: no path, query or fragment (`/`, `?`, `#`), so a verification-method id such as `did:key:z6Mk…#z6Mk…` is refused. Compared by exact string equality — no case folding or percent-decoding. A consumer MUST still treat the value as data: the pattern keeps shell metacharacters, whitespace and quotes out of the wire form, but it does not make a DID safe to splice into a command or markup.",
282
+ "type": "string",
283
+ "maxLength": 2048,
284
+ "pattern": "^did:[a-z0-9]+:(?:(?:[A-Za-z0-9._-]|%[0-9A-Fa-f]{2})*:)*(?:[A-Za-z0-9._-]|%[0-9A-Fa-f]{2})+$"
285
+ },
286
+ "Resource": {
287
+ "title": "Resource",
288
+ "description": "A forge-qualified resource: `<forge-host>/<owner>` for a namespace, or `<forge-host>/<owner>/<repo>` for one repository, all lowercase — `github.com/acme`, `github.com/acme/widgets`, `codeberg.org/acme`. The forge is never implied: `acme/widgets` alone is not a resource. Containment is by whole segment: `github.com/acme` contains `github.com/acme/widgets` and does not contain `github.com/acme-labs/x` or `codeberg.org/acme/widgets`.",
289
+ "type": "string",
290
+ "maxLength": 455,
291
+ "pattern": "^[a-z0-9](?:[a-z0-9-]*[a-z0-9])?(?:\\.[a-z0-9](?:[a-z0-9-]*[a-z0-9])?)+(?:/[a-z0-9_-][a-z0-9._-]{0,99}){1,2}$"
292
+ },
293
+ "Right": {
294
+ "title": "Right",
295
+ "description": "One of the five git rights. Each string is also the TRQP `action` the VTC publishes the right under in its Trust Registry, so it is carried verbatim. `git.ns.admin` and `git.repo.create` apply to a namespace resource; `git.repo.own` and `git.repo.maintain` to a repository resource; `git.commit.sign` to either.",
296
+ "type": "string",
297
+ "enum": [
298
+ "git.ns.admin",
299
+ "git.repo.create",
300
+ "git.repo.own",
301
+ "git.repo.maintain",
302
+ "git.commit.sign"
303
+ ]
304
+ },
305
+ "NamespaceId": {
306
+ "title": "NamespaceId",
307
+ "description": "The VTC's opaque identifier for a namespace, assigned when it is bound. Stable for the life of the binding; never reused for another binding.",
308
+ "type": "string",
309
+ "minLength": 1,
310
+ "maxLength": 128
311
+ }
312
+ }
313
+ } as const;
314
+
315
+ /**
316
+ * SPEC.md §7.2 policy for the request variant, from this specification's
317
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
318
+ * per-specification and cannot be derived from the document alone, and
319
+ * item 2 needs the schema this carries.
320
+ */
321
+ export const SPEC = {
322
+ typeUri: TYPE_URI,
323
+ isBearer: false,
324
+ isProofRequired: true,
325
+ isRecipientRequired: true,
326
+ isIssuedAtRequired: true,
327
+ payloadSchema: PAYLOAD_SCHEMA,
328
+ } as const;
329
+
330
+ /**
331
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
332
+ * tracks the *issuer* party's requirement because a response swaps the
333
+ * parties (§7.3 item 5).
334
+ */
335
+ export const RESPONSE_SPEC = {
336
+ typeUri: RESPONSE_TYPE_URI,
337
+ isBearer: false,
338
+ isProofRequired: true,
339
+ isRecipientRequired: true,
340
+ isIssuedAtRequired: true,
341
+ payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
342
+ } as const;
@@ -3,7 +3,7 @@
3
3
  * Source: specs/git-ns/repo/adopt/0.1/payload.schema.json
4
4
  */
5
5
 
6
- import type { Bootstrap, Did, DriftItem, Ext, ForgeAccount, ForgeHost, ForgeId, RepoResource, RepoSummary, RepoVisibility, Sync } from "../../../../_shared/components.js";
6
+ import type { Bootstrap, Did_GitNsV0_1 as Did, DriftItem, Ext, ForgeAccount, ForgeHost, ForgeId, RepoResource, RepoSummary_GitNsV0_1 as RepoSummary, RepoVisibility, Sync } from "../../../../_shared/components.js";
7
7
 
8
8
 
9
9
  /**