@openvtc/trust-tasks 0.21.3 → 0.21.5

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 (212) hide show
  1. package/CHANGELOG.md +72 -0
  2. package/dist/_shared/components.d.ts +210 -2
  3. package/dist/_shared/components.d.ts.map +1 -1
  4. package/dist/auth/_shared/0.1/passkey-invite.d.ts +16 -0
  5. package/dist/auth/_shared/0.1/passkey-invite.d.ts.map +1 -0
  6. package/dist/auth/_shared/0.1/passkey-invite.js +6 -0
  7. package/dist/auth/_shared/0.1/passkey-invite.js.map +1 -0
  8. package/dist/auth/passkey/admin-list/0.1/payload.d.ts +484 -0
  9. package/dist/auth/passkey/admin-list/0.1/payload.d.ts.map +1 -0
  10. package/dist/auth/passkey/admin-list/0.1/payload.js +257 -0
  11. package/dist/auth/passkey/admin-list/0.1/payload.js.map +1 -0
  12. package/dist/auth/passkey/enroll/invite/list/0.1/payload.d.ts +393 -0
  13. package/dist/auth/passkey/enroll/invite/list/0.1/payload.d.ts.map +1 -0
  14. package/dist/auth/passkey/enroll/invite/list/0.1/payload.js +234 -0
  15. package/dist/auth/passkey/enroll/invite/list/0.1/payload.js.map +1 -0
  16. package/dist/auth/passkey/enroll/invite/revoke/0.1/payload.d.ts +228 -0
  17. package/dist/auth/passkey/enroll/invite/revoke/0.1/payload.d.ts.map +1 -0
  18. package/dist/auth/passkey/enroll/invite/revoke/0.1/payload.js +138 -0
  19. package/dist/auth/passkey/enroll/invite/revoke/0.1/payload.js.map +1 -0
  20. package/dist/auth/passkey/enroll/invite/update/0.1/payload.d.ts +459 -0
  21. package/dist/auth/passkey/enroll/invite/update/0.1/payload.d.ts.map +1 -0
  22. package/dist/auth/passkey/enroll/invite/update/0.1/payload.js +286 -0
  23. package/dist/auth/passkey/enroll/invite/update/0.1/payload.js.map +1 -0
  24. package/dist/auth/step-up/start/0.1/payload.d.ts +420 -0
  25. package/dist/auth/step-up/start/0.1/payload.d.ts.map +1 -0
  26. package/dist/auth/step-up/start/0.1/payload.js +232 -0
  27. package/dist/auth/step-up/start/0.1/payload.js.map +1 -0
  28. package/dist/did-management/_shared/0.1/service-instance.d.ts +1 -1
  29. package/dist/did-management/_shared/0.1/service-instance.d.ts.map +1 -1
  30. package/dist/did-management/_shared/0.2/metrics-snapshot.d.ts +16 -0
  31. package/dist/did-management/_shared/0.2/metrics-snapshot.d.ts.map +1 -0
  32. package/dist/did-management/_shared/0.2/metrics-snapshot.js +6 -0
  33. package/dist/did-management/_shared/0.2/metrics-snapshot.js.map +1 -0
  34. package/dist/did-management/_shared/0.2/service-instance.d.ts +16 -0
  35. package/dist/did-management/_shared/0.2/service-instance.d.ts.map +1 -0
  36. package/dist/did-management/_shared/0.2/service-instance.js +6 -0
  37. package/dist/did-management/_shared/0.2/service-instance.js.map +1 -0
  38. package/dist/did-management/agent-name/resolve/0.1/payload.d.ts +318 -0
  39. package/dist/did-management/agent-name/resolve/0.1/payload.d.ts.map +1 -0
  40. package/dist/did-management/agent-name/resolve/0.1/payload.js +179 -0
  41. package/dist/did-management/agent-name/resolve/0.1/payload.js.map +1 -0
  42. package/dist/did-management/did/log/0.1/payload.d.ts +436 -0
  43. package/dist/did-management/did/log/0.1/payload.d.ts.map +1 -0
  44. package/dist/did-management/did/log/0.1/payload.js +228 -0
  45. package/dist/did-management/did/log/0.1/payload.js.map +1 -0
  46. package/dist/did-management/domain/list/0.1/payload.d.ts +423 -0
  47. package/dist/did-management/domain/list/0.1/payload.d.ts.map +1 -0
  48. package/dist/did-management/domain/list/0.1/payload.js +244 -0
  49. package/dist/did-management/domain/list/0.1/payload.js.map +1 -0
  50. package/dist/did-management/identity/list/0.1/payload.d.ts +494 -0
  51. package/dist/did-management/identity/list/0.1/payload.d.ts.map +1 -0
  52. package/dist/did-management/identity/list/0.1/payload.js +274 -0
  53. package/dist/did-management/identity/list/0.1/payload.js.map +1 -0
  54. package/dist/did-management/identity/retire/0.1/payload.d.ts +242 -0
  55. package/dist/did-management/identity/retire/0.1/payload.d.ts.map +1 -0
  56. package/dist/did-management/identity/retire/0.1/payload.js +142 -0
  57. package/dist/did-management/identity/retire/0.1/payload.js.map +1 -0
  58. package/dist/did-management/registry/admin-register/0.1/payload.d.ts +1 -1
  59. package/dist/did-management/registry/admin-register/0.1/payload.d.ts.map +1 -1
  60. package/dist/did-management/registry/check/0.1/payload.d.ts +639 -0
  61. package/dist/did-management/registry/check/0.1/payload.d.ts.map +1 -0
  62. package/dist/did-management/registry/check/0.1/payload.js +383 -0
  63. package/dist/did-management/registry/check/0.1/payload.js.map +1 -0
  64. package/dist/did-management/registry/get/0.1/payload.d.ts +632 -0
  65. package/dist/did-management/registry/get/0.1/payload.d.ts.map +1 -0
  66. package/dist/did-management/registry/get/0.1/payload.js +381 -0
  67. package/dist/did-management/registry/get/0.1/payload.js.map +1 -0
  68. package/dist/did-management/registry/list/0.1/payload.d.ts +661 -0
  69. package/dist/did-management/registry/list/0.1/payload.d.ts.map +1 -0
  70. package/dist/did-management/registry/list/0.1/payload.js +398 -0
  71. package/dist/did-management/registry/list/0.1/payload.js.map +1 -0
  72. package/dist/did-management/registry/purge-domain/0.1/payload.d.ts +269 -0
  73. package/dist/did-management/registry/purge-domain/0.1/payload.d.ts.map +1 -0
  74. package/dist/did-management/registry/purge-domain/0.1/payload.js +160 -0
  75. package/dist/did-management/registry/purge-domain/0.1/payload.js.map +1 -0
  76. package/dist/did-management/replica/domain/assign/0.1/payload.d.ts +233 -0
  77. package/dist/did-management/replica/domain/assign/0.1/payload.d.ts.map +1 -0
  78. package/dist/did-management/replica/domain/assign/0.1/payload.js +143 -0
  79. package/dist/did-management/replica/domain/assign/0.1/payload.js.map +1 -0
  80. package/dist/did-management/replica/domain/purge/0.1/payload.d.ts +257 -0
  81. package/dist/did-management/replica/domain/purge/0.1/payload.d.ts.map +1 -0
  82. package/dist/did-management/replica/domain/purge/0.1/payload.js +155 -0
  83. package/dist/did-management/replica/domain/purge/0.1/payload.js.map +1 -0
  84. package/dist/did-management/replica/domain/unassign/0.1/payload.d.ts +257 -0
  85. package/dist/did-management/replica/domain/unassign/0.1/payload.d.ts.map +1 -0
  86. package/dist/did-management/replica/domain/unassign/0.1/payload.js +155 -0
  87. package/dist/did-management/replica/domain/unassign/0.1/payload.js.map +1 -0
  88. package/dist/did-management/replica/domain/upsert/0.1/payload.d.ts +401 -0
  89. package/dist/did-management/replica/domain/upsert/0.1/payload.d.ts.map +1 -0
  90. package/dist/did-management/replica/domain/upsert/0.1/payload.js +241 -0
  91. package/dist/did-management/replica/domain/upsert/0.1/payload.js.map +1 -0
  92. package/dist/did-management/server/config/0.1/payload.d.ts +838 -0
  93. package/dist/did-management/server/config/0.1/payload.d.ts.map +1 -0
  94. package/dist/did-management/server/config/0.1/payload.js +444 -0
  95. package/dist/did-management/server/config/0.1/payload.js.map +1 -0
  96. package/dist/did-management/server/info/0.1/payload.d.ts +285 -0
  97. package/dist/did-management/server/info/0.1/payload.d.ts.map +1 -0
  98. package/dist/did-management/server/info/0.1/payload.js +160 -0
  99. package/dist/did-management/server/info/0.1/payload.js.map +1 -0
  100. package/dist/did-management/server/metrics/0.1/payload.d.ts +674 -0
  101. package/dist/did-management/server/metrics/0.1/payload.d.ts.map +1 -0
  102. package/dist/did-management/server/metrics/0.1/payload.js +387 -0
  103. package/dist/did-management/server/metrics/0.1/payload.js.map +1 -0
  104. package/dist/did-management/stats/get/0.1/payload.d.ts +349 -0
  105. package/dist/did-management/stats/get/0.1/payload.d.ts.map +1 -0
  106. package/dist/did-management/stats/get/0.1/payload.js +187 -0
  107. package/dist/did-management/stats/get/0.1/payload.js.map +1 -0
  108. package/dist/did-management/stats/timeseries/0.1/payload.d.ts +381 -0
  109. package/dist/did-management/stats/timeseries/0.1/payload.d.ts.map +1 -0
  110. package/dist/did-management/stats/timeseries/0.1/payload.js +227 -0
  111. package/dist/did-management/stats/timeseries/0.1/payload.js.map +1 -0
  112. package/dist/git-ns/namespace/list/0.1/payload.d.ts +1343 -0
  113. package/dist/git-ns/namespace/list/0.1/payload.d.ts.map +1 -0
  114. package/dist/git-ns/namespace/list/0.1/payload.js +704 -0
  115. package/dist/git-ns/namespace/list/0.1/payload.js.map +1 -0
  116. package/dist/git-ns/repo/list/0.1/payload.d.ts +1377 -0
  117. package/dist/git-ns/repo/list/0.1/payload.d.ts.map +1 -0
  118. package/dist/git-ns/repo/list/0.1/payload.js +744 -0
  119. package/dist/git-ns/repo/list/0.1/payload.js.map +1 -0
  120. package/dist/git-ns/view/0.5/payload.d.ts +1722 -0
  121. package/dist/git-ns/view/0.5/payload.d.ts.map +1 -0
  122. package/dist/git-ns/view/0.5/payload.js +1024 -0
  123. package/dist/git-ns/view/0.5/payload.js.map +1 -0
  124. package/dist/index.d.ts +38 -0
  125. package/dist/index.d.ts.map +1 -1
  126. package/dist/index.js +38 -0
  127. package/dist/index.js.map +1 -1
  128. package/dist/vtc/_shared/0.1/invite.d.ts +1 -1
  129. package/dist/vtc/_shared/0.1/invite.d.ts.map +1 -1
  130. package/dist/vtc/admin/invites/list/0.1/payload.d.ts +1 -1
  131. package/dist/vtc/admin/invites/list/0.1/payload.d.ts.map +1 -1
  132. package/dist/webvh/_shared/0.1/sync-update.d.ts +16 -0
  133. package/dist/webvh/_shared/0.1/sync-update.d.ts.map +1 -0
  134. package/dist/webvh/_shared/0.1/sync-update.js +6 -0
  135. package/dist/webvh/_shared/0.1/sync-update.js.map +1 -0
  136. package/dist/webvh/_shared/0.1/witness-key.d.ts +16 -0
  137. package/dist/webvh/_shared/0.1/witness-key.d.ts.map +1 -0
  138. package/dist/webvh/_shared/0.1/witness-key.js +6 -0
  139. package/dist/webvh/_shared/0.1/witness-key.js.map +1 -0
  140. package/dist/webvh/sync/batch/0.1/payload.d.ts +503 -0
  141. package/dist/webvh/sync/batch/0.1/payload.d.ts.map +1 -0
  142. package/dist/webvh/sync/batch/0.1/payload.js +290 -0
  143. package/dist/webvh/sync/batch/0.1/payload.js.map +1 -0
  144. package/dist/webvh/sync/delete/0.2/payload.d.ts +242 -0
  145. package/dist/webvh/sync/delete/0.2/payload.d.ts.map +1 -0
  146. package/dist/webvh/sync/delete/0.2/payload.js +148 -0
  147. package/dist/webvh/sync/delete/0.2/payload.js.map +1 -0
  148. package/dist/webvh/sync/update/0.2/payload.d.ts +315 -0
  149. package/dist/webvh/sync/update/0.2/payload.d.ts.map +1 -0
  150. package/dist/webvh/sync/update/0.2/payload.js +177 -0
  151. package/dist/webvh/sync/update/0.2/payload.js.map +1 -0
  152. package/dist/webvh/witness/key/create/0.1/payload.d.ts +346 -0
  153. package/dist/webvh/witness/key/create/0.1/payload.d.ts.map +1 -0
  154. package/dist/webvh/witness/key/create/0.1/payload.js +202 -0
  155. package/dist/webvh/witness/key/create/0.1/payload.js.map +1 -0
  156. package/dist/webvh/witness/key/delete/0.1/payload.d.ts +237 -0
  157. package/dist/webvh/witness/key/delete/0.1/payload.d.ts.map +1 -0
  158. package/dist/webvh/witness/key/delete/0.1/payload.js +141 -0
  159. package/dist/webvh/witness/key/delete/0.1/payload.js.map +1 -0
  160. package/dist/webvh/witness/key/list/0.1/payload.d.ts +349 -0
  161. package/dist/webvh/witness/key/list/0.1/payload.d.ts.map +1 -0
  162. package/dist/webvh/witness/key/list/0.1/payload.js +204 -0
  163. package/dist/webvh/witness/key/list/0.1/payload.js.map +1 -0
  164. package/dist/webvh/witness/sign/0.1/payload.d.ts +401 -0
  165. package/dist/webvh/witness/sign/0.1/payload.d.ts.map +1 -0
  166. package/dist/webvh/witness/sign/0.1/payload.js +229 -0
  167. package/dist/webvh/witness/sign/0.1/payload.js.map +1 -0
  168. package/package.json +1 -1
  169. package/src/_shared/components.ts +210 -2
  170. package/src/auth/_shared/0.1/passkey-invite.ts +17 -0
  171. package/src/auth/passkey/admin-list/0.1/payload.ts +338 -0
  172. package/src/auth/passkey/enroll/invite/list/0.1/payload.ts +266 -0
  173. package/src/auth/passkey/enroll/invite/revoke/0.1/payload.ts +165 -0
  174. package/src/auth/passkey/enroll/invite/update/0.1/payload.ts +327 -0
  175. package/src/auth/step-up/start/0.1/payload.ts +287 -0
  176. package/src/did-management/_shared/0.1/service-instance.ts +1 -1
  177. package/src/did-management/_shared/0.2/metrics-snapshot.ts +17 -0
  178. package/src/did-management/_shared/0.2/service-instance.ts +17 -0
  179. package/src/did-management/agent-name/resolve/0.1/payload.ts +222 -0
  180. package/src/did-management/did/log/0.1/payload.ts +295 -0
  181. package/src/did-management/domain/list/0.1/payload.ts +280 -0
  182. package/src/did-management/identity/list/0.1/payload.ts +335 -0
  183. package/src/did-management/identity/retire/0.1/payload.ts +175 -0
  184. package/src/did-management/registry/admin-register/0.1/payload.ts +1 -1
  185. package/src/did-management/registry/check/0.1/payload.ts +415 -0
  186. package/src/did-management/registry/get/0.1/payload.ts +410 -0
  187. package/src/did-management/registry/list/0.1/payload.ts +434 -0
  188. package/src/did-management/registry/purge-domain/0.1/payload.ts +198 -0
  189. package/src/did-management/replica/domain/assign/0.1/payload.ts +173 -0
  190. package/src/did-management/replica/domain/purge/0.1/payload.ts +189 -0
  191. package/src/did-management/replica/domain/unassign/0.1/payload.ts +189 -0
  192. package/src/did-management/replica/domain/upsert/0.1/payload.ts +271 -0
  193. package/src/did-management/server/config/0.1/payload.ts +545 -0
  194. package/src/did-management/server/info/0.1/payload.ts +200 -0
  195. package/src/did-management/server/metrics/0.1/payload.ts +418 -0
  196. package/src/did-management/stats/get/0.1/payload.ts +237 -0
  197. package/src/did-management/stats/timeseries/0.1/payload.ts +279 -0
  198. package/src/git-ns/namespace/list/0.1/payload.ts +883 -0
  199. package/src/git-ns/repo/list/0.1/payload.ts +909 -0
  200. package/src/git-ns/view/0.5/payload.ts +1095 -0
  201. package/src/index.ts +38 -0
  202. package/src/vtc/_shared/0.1/invite.ts +1 -1
  203. package/src/vtc/admin/invites/list/0.1/payload.ts +1 -1
  204. package/src/webvh/_shared/0.1/sync-update.ts +17 -0
  205. package/src/webvh/_shared/0.1/witness-key.ts +17 -0
  206. package/src/webvh/sync/batch/0.1/payload.ts +336 -0
  207. package/src/webvh/sync/delete/0.2/payload.ts +181 -0
  208. package/src/webvh/sync/update/0.2/payload.ts +233 -0
  209. package/src/webvh/witness/key/create/0.1/payload.ts +231 -0
  210. package/src/webvh/witness/key/delete/0.1/payload.ts +171 -0
  211. package/src/webvh/witness/key/list/0.1/payload.ts +232 -0
  212. package/src/webvh/witness/sign/0.1/payload.ts +279 -0
@@ -0,0 +1,909 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/git-ns/repo/list/0.1/payload.schema.json
4
+ */
5
+
6
+ import type { Bootstrap, Did_GitNsV0_3 as Did, Ext, ForgeId, NamespaceId, RepoResource, RepoVisibility } from "../../../../_shared/components.js";
7
+
8
+
9
+ /**
10
+ * A level of the bridge's forge-neutral role ladder, lowest first: the vocabulary role drift's `observed` and `expected` are reported in. `none` is no direct role on the repository.
11
+ */
12
+ export type MappedRole = "none" | "read" | "triage" | "write" | "maintain" | "admin";
13
+
14
+ /**
15
+ * An administrator lists the repositories recorded in the namespaces they administer — every one, for a holder of the community-administrator capability — with owners, right counts, bootstrap, sync and forge status.
16
+ */
17
+ export interface GitNamespacesListRepositoriesPayload {
18
+ /**
19
+ * Only the repositories in this namespace. It must be one the caller administers; a namespace they do not administer, or one this VTC does not have, is refused with `notAdministrator` alike.
20
+ */
21
+ namespace?: NamespaceId;
22
+ ext?: Ext;
23
+ }
24
+ /**
25
+ * The repositories in the namespaces the caller administers, or in the one asked for.
26
+ */
27
+ export interface GitNamespacesListRepositoriesResponsePayload {
28
+ /**
29
+ * Every repository recorded in an administered namespace, in any state, ordered by `resource`; for a holder of the community-administrator capability without `namespace`, also every repository whose namespace is no longer bound.
30
+ */
31
+ repos: RepoStatus[];
32
+ ext?: Ext;
33
+ }
34
+ /**
35
+ * One repository as its administrators govern it: who owns it, how many hold rights on it, how far commit trust is set up, and how its forge compares with the VTC's projection.
36
+ */
37
+ export interface RepoStatus {
38
+ /**
39
+ * The VTC's identifier for the repository record.
40
+ */
41
+ id: string;
42
+ /**
43
+ * The namespace it was recorded in. For a `detached` repository, possibly one no longer bound.
44
+ */
45
+ namespace: NamespaceId;
46
+ resource: RepoResource;
47
+ /**
48
+ * The forge's repository id, once confirmed.
49
+ */
50
+ forgeId?: ForgeId;
51
+ visibility: RepoVisibility;
52
+ /**
53
+ * As `RepoSummary.state` in the shared schema.
54
+ */
55
+ state: "pendingCreate" | "active" | "archived" | "detached" | "orphaned" | "unmanaged";
56
+ /**
57
+ * The DIDs holding a live, explicitly recorded `git.repo.own` on it.
58
+ */
59
+ owners: Did[];
60
+ /**
61
+ * How many live records of `git.repo.maintain` it has. Implied rights are not counted.
62
+ */
63
+ maintainers: number;
64
+ /**
65
+ * How many live records of `git.commit.sign` it has. Implied rights are not counted.
66
+ */
67
+ committers: number;
68
+ bootstrap: Bootstrap;
69
+ /**
70
+ * As `Sync.state` in the shared schema.
71
+ */
72
+ syncState: "inSync" | "drift" | "pending" | "unchecked";
73
+ /**
74
+ * When the forge was last compared. Absent if never.
75
+ */
76
+ checkedAt?: string;
77
+ /**
78
+ * How many drift items are outstanding. The items themselves are in `git-ns/view`.
79
+ */
80
+ driftCount: number;
81
+ /**
82
+ * The step that failed on the last create or bootstrap.
83
+ */
84
+ failedStep?: string;
85
+ /**
86
+ * What the bridge said when that step failed.
87
+ */
88
+ lastError?: string;
89
+ /**
90
+ * Who created it through the VTC. Absent for an adopted or unmanaged repository.
91
+ */
92
+ createdBy?: Did;
93
+ /**
94
+ * When the VTC first recorded it.
95
+ */
96
+ createdAt: string;
97
+ /**
98
+ * The guard in force against a pull request satisfying its own check, as the bridge last reported it: `requiredWorkflow`, `codeOwnerReview`, `bridgePostedCheck`, `protectedFiles` or `none`. A client treats any other value as `none`.
99
+ */
100
+ guard?: string;
101
+ /**
102
+ * Per-step outcomes of the last create, bootstrap or inspect job. Empty until one has been reported.
103
+ *
104
+ * @maxItems 64
105
+ */
106
+ steps: StepOutcome[];
107
+ lastCheck?: LastCheck;
108
+ roleMap?: RoleMap;
109
+ /**
110
+ * The bridge last projected this repository's roles under an earlier role map, and the re-projection queued for it has not yet succeeded.
111
+ */
112
+ roleMapStale: boolean;
113
+ }
114
+ /**
115
+ * One step of the last create, bootstrap or inspect job on the repository, as the bridge reported it.
116
+ */
117
+ export interface StepOutcome {
118
+ /**
119
+ * The step, in the bridge's words (`workflow`, `keyring`, `variables`, `requiredCheck`).
120
+ */
121
+ step: string;
122
+ /**
123
+ * `applied`, `unchanged`, `failed` or `skipped`. A client shows any other value as reported.
124
+ */
125
+ outcome: string;
126
+ /**
127
+ * What the bridge said about it — an error, or why it was skipped.
128
+ */
129
+ detail?: string;
130
+ }
131
+ /**
132
+ * The last verify-trust check run the bridge saw on the repository.
133
+ */
134
+ export interface LastCheck {
135
+ /**
136
+ * The check's conclusion, in the forge's words (`success`, `failure`).
137
+ */
138
+ conclusion: string;
139
+ /**
140
+ * When the check concluded.
141
+ */
142
+ at: string;
143
+ /**
144
+ * The commit it ran on.
145
+ */
146
+ sha?: string;
147
+ }
148
+ /**
149
+ * The forge role each right projects to on this repository under the serving bridge's reported map. Absent while the namespace's map is unknown.
150
+ */
151
+ export interface RoleMap {
152
+ own: MappedRole;
153
+ maintain: MappedRole;
154
+ commit: MappedRole;
155
+ }
156
+
157
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
158
+ export type { Bootstrap, Did, Ext, ForgeId, NamespaceId, RepoResource, RepoVisibility };
159
+
160
+ /** Trust Task type URI. */
161
+ export const TYPE_URI = "https://trusttasks.org/spec/git-ns/repo/list/0.1" as const;
162
+
163
+ /** Stable alias for this specification's request payload shape. */
164
+ export type Payload = GitNamespacesListRepositoriesPayload;
165
+
166
+ /** Trust Task response type URI (request type URI + "#response"). */
167
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/git-ns/repo/list/0.1#response" as const;
168
+
169
+ /** Stable alias for this specification's success-response payload shape. */
170
+ export type Response = GitNamespacesListRepositoriesResponsePayload;
171
+
172
+ /**
173
+ * This specification's payload schema, as a value.
174
+ *
175
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
176
+ * rather than only as a `.json` file because TypeScript types are erased
177
+ * at runtime: without a schema a consumer has nothing to validate, and
178
+ * every REQUIRED payload member is optional in practice. Cross-file
179
+ * `$ref`s are already inlined, so it needs no resolver.
180
+ */
181
+ export const PAYLOAD_SCHEMA = {
182
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
183
+ "$id": "https://trusttasks.org/spec/git-ns/repo/list/0.1",
184
+ "title": "Git Namespaces — List Repositories — payload",
185
+ "description": "An administrator lists the repositories recorded in the namespaces they administer — every one, for a holder of the community-administrator capability — with owners, right counts, bootstrap, sync and forge status.",
186
+ "type": "object",
187
+ "additionalProperties": false,
188
+ "required": [],
189
+ "properties": {
190
+ "namespace": {
191
+ "$ref": "#/$defs/NamespaceId",
192
+ "description": "Only the repositories in this namespace. It must be one the caller administers; a namespace they do not administer, or one this VTC does not have, is refused with `notAdministrator` alike."
193
+ },
194
+ "ext": {
195
+ "$ref": "#/$defs/Ext"
196
+ }
197
+ },
198
+ "$defs": {
199
+ "MappedRole": {
200
+ "title": "MappedRole",
201
+ "type": "string",
202
+ "enum": [
203
+ "none",
204
+ "read",
205
+ "triage",
206
+ "write",
207
+ "maintain",
208
+ "admin"
209
+ ],
210
+ "description": "A level of the bridge's forge-neutral role ladder, lowest first: the vocabulary role drift's `observed` and `expected` are reported in. `none` is no direct role on the repository."
211
+ },
212
+ "RoleMap": {
213
+ "title": "RoleMap",
214
+ "description": "The forge role each repository right is given, as the forge applies it: after the forge's own ladder has rounded it down. `own` is the role `git.repo.own` projects to, `maintain` that of `git.repo.maintain`, `commit` that of `git.commit.sign` (`none` is fork-based contribution). There is no member for `git.ns.admin` or `git.repo.create`, which project to no forge role whatever a bridge is configured with. Ordered: `own` is at least `maintain`, which is at least `commit`, and `commit` is at most `write`.",
215
+ "type": "object",
216
+ "additionalProperties": false,
217
+ "required": [
218
+ "own",
219
+ "maintain",
220
+ "commit"
221
+ ],
222
+ "properties": {
223
+ "own": {
224
+ "$ref": "#/$defs/MappedRole"
225
+ },
226
+ "maintain": {
227
+ "$ref": "#/$defs/MappedRole"
228
+ },
229
+ "commit": {
230
+ "$ref": "#/$defs/MappedRole"
231
+ }
232
+ }
233
+ },
234
+ "StepOutcome": {
235
+ "title": "StepOutcome",
236
+ "description": "One step of the last create, bootstrap or inspect job on the repository, as the bridge reported it.",
237
+ "type": "object",
238
+ "additionalProperties": false,
239
+ "required": [
240
+ "step",
241
+ "outcome"
242
+ ],
243
+ "properties": {
244
+ "step": {
245
+ "type": "string",
246
+ "minLength": 1,
247
+ "maxLength": 64,
248
+ "description": "The step, in the bridge's words (`workflow`, `keyring`, `variables`, `requiredCheck`)."
249
+ },
250
+ "outcome": {
251
+ "type": "string",
252
+ "minLength": 1,
253
+ "maxLength": 32,
254
+ "description": "`applied`, `unchanged`, `failed` or `skipped`. A client shows any other value as reported."
255
+ },
256
+ "detail": {
257
+ "type": "string",
258
+ "minLength": 1,
259
+ "maxLength": 4096,
260
+ "description": "What the bridge said about it — an error, or why it was skipped."
261
+ }
262
+ }
263
+ },
264
+ "LastCheck": {
265
+ "title": "LastCheck",
266
+ "description": "The last verify-trust check run the bridge saw on the repository.",
267
+ "type": "object",
268
+ "additionalProperties": false,
269
+ "required": [
270
+ "conclusion",
271
+ "at"
272
+ ],
273
+ "properties": {
274
+ "conclusion": {
275
+ "type": "string",
276
+ "minLength": 1,
277
+ "maxLength": 64,
278
+ "description": "The check's conclusion, in the forge's words (`success`, `failure`)."
279
+ },
280
+ "at": {
281
+ "type": "string",
282
+ "format": "date-time",
283
+ "description": "When the check concluded."
284
+ },
285
+ "sha": {
286
+ "type": "string",
287
+ "minLength": 1,
288
+ "maxLength": 64,
289
+ "description": "The commit it ran on."
290
+ }
291
+ }
292
+ },
293
+ "RepoStatus": {
294
+ "title": "RepoStatus",
295
+ "description": "One repository as its administrators govern it: who owns it, how many hold rights on it, how far commit trust is set up, and how its forge compares with the VTC's projection.",
296
+ "type": "object",
297
+ "additionalProperties": false,
298
+ "required": [
299
+ "id",
300
+ "namespace",
301
+ "resource",
302
+ "visibility",
303
+ "state",
304
+ "owners",
305
+ "maintainers",
306
+ "committers",
307
+ "bootstrap",
308
+ "syncState",
309
+ "driftCount",
310
+ "createdAt",
311
+ "steps",
312
+ "roleMapStale"
313
+ ],
314
+ "properties": {
315
+ "id": {
316
+ "type": "string",
317
+ "minLength": 1,
318
+ "maxLength": 128,
319
+ "description": "The VTC's identifier for the repository record."
320
+ },
321
+ "namespace": {
322
+ "$ref": "#/$defs/NamespaceId",
323
+ "description": "The namespace it was recorded in. For a `detached` repository, possibly one no longer bound."
324
+ },
325
+ "resource": {
326
+ "$ref": "#/$defs/RepoResource"
327
+ },
328
+ "forgeId": {
329
+ "$ref": "#/$defs/ForgeId",
330
+ "description": "The forge's repository id, once confirmed."
331
+ },
332
+ "visibility": {
333
+ "$ref": "#/$defs/RepoVisibility"
334
+ },
335
+ "state": {
336
+ "type": "string",
337
+ "enum": [
338
+ "pendingCreate",
339
+ "active",
340
+ "archived",
341
+ "detached",
342
+ "orphaned",
343
+ "unmanaged"
344
+ ],
345
+ "description": "As `RepoSummary.state` in the shared schema."
346
+ },
347
+ "owners": {
348
+ "type": "array",
349
+ "uniqueItems": true,
350
+ "items": {
351
+ "$ref": "#/$defs/Did"
352
+ },
353
+ "description": "The DIDs holding a live, explicitly recorded `git.repo.own` on it."
354
+ },
355
+ "maintainers": {
356
+ "type": "integer",
357
+ "minimum": 0,
358
+ "description": "How many live records of `git.repo.maintain` it has. Implied rights are not counted."
359
+ },
360
+ "committers": {
361
+ "type": "integer",
362
+ "minimum": 0,
363
+ "description": "How many live records of `git.commit.sign` it has. Implied rights are not counted."
364
+ },
365
+ "bootstrap": {
366
+ "$ref": "#/$defs/Bootstrap"
367
+ },
368
+ "syncState": {
369
+ "type": "string",
370
+ "enum": [
371
+ "inSync",
372
+ "drift",
373
+ "pending",
374
+ "unchecked"
375
+ ],
376
+ "description": "As `Sync.state` in the shared schema."
377
+ },
378
+ "checkedAt": {
379
+ "type": "string",
380
+ "format": "date-time",
381
+ "description": "When the forge was last compared. Absent if never."
382
+ },
383
+ "driftCount": {
384
+ "type": "integer",
385
+ "minimum": 0,
386
+ "description": "How many drift items are outstanding. The items themselves are in `git-ns/view`."
387
+ },
388
+ "failedStep": {
389
+ "type": "string",
390
+ "minLength": 1,
391
+ "maxLength": 64,
392
+ "description": "The step that failed on the last create or bootstrap."
393
+ },
394
+ "lastError": {
395
+ "type": "string",
396
+ "minLength": 1,
397
+ "maxLength": 4096,
398
+ "description": "What the bridge said when that step failed."
399
+ },
400
+ "createdBy": {
401
+ "$ref": "#/$defs/Did",
402
+ "description": "Who created it through the VTC. Absent for an adopted or unmanaged repository."
403
+ },
404
+ "createdAt": {
405
+ "type": "string",
406
+ "format": "date-time",
407
+ "description": "When the VTC first recorded it."
408
+ },
409
+ "guard": {
410
+ "type": "string",
411
+ "minLength": 1,
412
+ "maxLength": 64,
413
+ "description": "The guard in force against a pull request satisfying its own check, as the bridge last reported it: `requiredWorkflow`, `codeOwnerReview`, `bridgePostedCheck`, `protectedFiles` or `none`. A client treats any other value as `none`."
414
+ },
415
+ "steps": {
416
+ "type": "array",
417
+ "maxItems": 64,
418
+ "items": {
419
+ "$ref": "#/$defs/StepOutcome"
420
+ },
421
+ "description": "Per-step outcomes of the last create, bootstrap or inspect job. Empty until one has been reported."
422
+ },
423
+ "lastCheck": {
424
+ "$ref": "#/$defs/LastCheck"
425
+ },
426
+ "roleMap": {
427
+ "$ref": "#/$defs/RoleMap",
428
+ "description": "The forge role each right projects to on this repository under the serving bridge's reported map. Absent while the namespace's map is unknown."
429
+ },
430
+ "roleMapStale": {
431
+ "type": "boolean",
432
+ "description": "The bridge last projected this repository's roles under an earlier role map, and the re-projection queued for it has not yet succeeded."
433
+ }
434
+ }
435
+ },
436
+ "Response": {
437
+ "$anchor": "response",
438
+ "title": "Git Namespaces — List Repositories — response payload",
439
+ "description": "The repositories in the namespaces the caller administers, or in the one asked for.",
440
+ "type": "object",
441
+ "additionalProperties": false,
442
+ "required": [
443
+ "repos"
444
+ ],
445
+ "properties": {
446
+ "repos": {
447
+ "type": "array",
448
+ "items": {
449
+ "$ref": "#/$defs/RepoStatus"
450
+ },
451
+ "description": "Every repository recorded in an administered namespace, in any state, ordered by `resource`; for a holder of the community-administrator capability without `namespace`, also every repository whose namespace is no longer bound."
452
+ },
453
+ "ext": {
454
+ "$ref": "#/$defs/Ext"
455
+ }
456
+ }
457
+ },
458
+ "Ext": {
459
+ "title": "Ext",
460
+ "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.",
461
+ "type": "object",
462
+ "minProperties": 1,
463
+ "additionalProperties": true,
464
+ "propertyNames": {
465
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
466
+ }
467
+ },
468
+ "Did": {
469
+ "title": "Did",
470
+ "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.",
471
+ "type": "string",
472
+ "maxLength": 2048,
473
+ "pattern": "^did:[a-z0-9]+:(?:(?:[A-Za-z0-9._-]|%[0-9A-Fa-f]{2})*:)*(?:[A-Za-z0-9._-]|%[0-9A-Fa-f]{2})+$"
474
+ },
475
+ "Bootstrap": {
476
+ "title": "Bootstrap",
477
+ "description": "Whether each step that turns commit trust on for a repository is in place, as last reported. A step that this forge's plan does not need reads `true`.",
478
+ "type": "object",
479
+ "additionalProperties": false,
480
+ "required": [
481
+ "workflow",
482
+ "keyring",
483
+ "variables",
484
+ "requiredCheck"
485
+ ],
486
+ "properties": {
487
+ "workflow": {
488
+ "type": "boolean",
489
+ "description": "The verify-trust check runs on the repository's pull requests — from a workflow committed to it, or, where the forge supports it, required on it from the namespace's own bridge-managed workflow repository at a pinned commit."
490
+ },
491
+ "keyring": {
492
+ "type": "boolean",
493
+ "description": "The exempt platform keyring for forge-signed merge commits is committed, or the forge's plan does not need one."
494
+ },
495
+ "variables": {
496
+ "type": "boolean",
497
+ "description": "The repository names the Trust Registry and this VTC as its trust anchors."
498
+ },
499
+ "requiredCheck": {
500
+ "type": "boolean",
501
+ "description": "The forge refuses to merge into the default branch unless the verify-trust check passes, with no bypass, and a pull request cannot change what that check runs: an organisation-required workflow, code-owner review of workflow files, or protected workflow paths, as the forge allows."
502
+ }
503
+ }
504
+ },
505
+ "RepoVisibility": {
506
+ "title": "RepoVisibility",
507
+ "type": "string",
508
+ "enum": [
509
+ "public",
510
+ "private"
511
+ ],
512
+ "description": "Repository visibility on the forge."
513
+ },
514
+ "ForgeId": {
515
+ "title": "ForgeId",
516
+ "description": "An identifier the forge itself assigns — a repository id, a user or organisation id — carried as a string so a forge whose ids are not numbers needs no new version. GitHub and Forgejo ids are decimal integers written as strings (`\"812736451\"`). Unlike a name, it survives renames and transfers, which is why rights and bindings are keyed by it.",
517
+ "type": "string",
518
+ "minLength": 1,
519
+ "maxLength": 64
520
+ },
521
+ "RepoResource": {
522
+ "title": "RepoResource",
523
+ "description": "A forge-qualified resource naming exactly one repository: `<forge-host>/<owner>/<repo>`, lowercase.",
524
+ "type": "string",
525
+ "maxLength": 455,
526
+ "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}/[a-z0-9_-][a-z0-9._-]{0,99}$"
527
+ },
528
+ "NamespaceId": {
529
+ "title": "NamespaceId",
530
+ "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.",
531
+ "type": "string",
532
+ "minLength": 1,
533
+ "maxLength": 128
534
+ }
535
+ }
536
+ } as const;
537
+
538
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
539
+ export const RESPONSE_PAYLOAD_SCHEMA = {
540
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
541
+ "$ref": "#/$defs/Response",
542
+ "$defs": {
543
+ "MappedRole": {
544
+ "title": "MappedRole",
545
+ "type": "string",
546
+ "enum": [
547
+ "none",
548
+ "read",
549
+ "triage",
550
+ "write",
551
+ "maintain",
552
+ "admin"
553
+ ],
554
+ "description": "A level of the bridge's forge-neutral role ladder, lowest first: the vocabulary role drift's `observed` and `expected` are reported in. `none` is no direct role on the repository."
555
+ },
556
+ "RoleMap": {
557
+ "title": "RoleMap",
558
+ "description": "The forge role each repository right is given, as the forge applies it: after the forge's own ladder has rounded it down. `own` is the role `git.repo.own` projects to, `maintain` that of `git.repo.maintain`, `commit` that of `git.commit.sign` (`none` is fork-based contribution). There is no member for `git.ns.admin` or `git.repo.create`, which project to no forge role whatever a bridge is configured with. Ordered: `own` is at least `maintain`, which is at least `commit`, and `commit` is at most `write`.",
559
+ "type": "object",
560
+ "additionalProperties": false,
561
+ "required": [
562
+ "own",
563
+ "maintain",
564
+ "commit"
565
+ ],
566
+ "properties": {
567
+ "own": {
568
+ "$ref": "#/$defs/MappedRole"
569
+ },
570
+ "maintain": {
571
+ "$ref": "#/$defs/MappedRole"
572
+ },
573
+ "commit": {
574
+ "$ref": "#/$defs/MappedRole"
575
+ }
576
+ }
577
+ },
578
+ "StepOutcome": {
579
+ "title": "StepOutcome",
580
+ "description": "One step of the last create, bootstrap or inspect job on the repository, as the bridge reported it.",
581
+ "type": "object",
582
+ "additionalProperties": false,
583
+ "required": [
584
+ "step",
585
+ "outcome"
586
+ ],
587
+ "properties": {
588
+ "step": {
589
+ "type": "string",
590
+ "minLength": 1,
591
+ "maxLength": 64,
592
+ "description": "The step, in the bridge's words (`workflow`, `keyring`, `variables`, `requiredCheck`)."
593
+ },
594
+ "outcome": {
595
+ "type": "string",
596
+ "minLength": 1,
597
+ "maxLength": 32,
598
+ "description": "`applied`, `unchanged`, `failed` or `skipped`. A client shows any other value as reported."
599
+ },
600
+ "detail": {
601
+ "type": "string",
602
+ "minLength": 1,
603
+ "maxLength": 4096,
604
+ "description": "What the bridge said about it — an error, or why it was skipped."
605
+ }
606
+ }
607
+ },
608
+ "LastCheck": {
609
+ "title": "LastCheck",
610
+ "description": "The last verify-trust check run the bridge saw on the repository.",
611
+ "type": "object",
612
+ "additionalProperties": false,
613
+ "required": [
614
+ "conclusion",
615
+ "at"
616
+ ],
617
+ "properties": {
618
+ "conclusion": {
619
+ "type": "string",
620
+ "minLength": 1,
621
+ "maxLength": 64,
622
+ "description": "The check's conclusion, in the forge's words (`success`, `failure`)."
623
+ },
624
+ "at": {
625
+ "type": "string",
626
+ "format": "date-time",
627
+ "description": "When the check concluded."
628
+ },
629
+ "sha": {
630
+ "type": "string",
631
+ "minLength": 1,
632
+ "maxLength": 64,
633
+ "description": "The commit it ran on."
634
+ }
635
+ }
636
+ },
637
+ "RepoStatus": {
638
+ "title": "RepoStatus",
639
+ "description": "One repository as its administrators govern it: who owns it, how many hold rights on it, how far commit trust is set up, and how its forge compares with the VTC's projection.",
640
+ "type": "object",
641
+ "additionalProperties": false,
642
+ "required": [
643
+ "id",
644
+ "namespace",
645
+ "resource",
646
+ "visibility",
647
+ "state",
648
+ "owners",
649
+ "maintainers",
650
+ "committers",
651
+ "bootstrap",
652
+ "syncState",
653
+ "driftCount",
654
+ "createdAt",
655
+ "steps",
656
+ "roleMapStale"
657
+ ],
658
+ "properties": {
659
+ "id": {
660
+ "type": "string",
661
+ "minLength": 1,
662
+ "maxLength": 128,
663
+ "description": "The VTC's identifier for the repository record."
664
+ },
665
+ "namespace": {
666
+ "$ref": "#/$defs/NamespaceId",
667
+ "description": "The namespace it was recorded in. For a `detached` repository, possibly one no longer bound."
668
+ },
669
+ "resource": {
670
+ "$ref": "#/$defs/RepoResource"
671
+ },
672
+ "forgeId": {
673
+ "$ref": "#/$defs/ForgeId",
674
+ "description": "The forge's repository id, once confirmed."
675
+ },
676
+ "visibility": {
677
+ "$ref": "#/$defs/RepoVisibility"
678
+ },
679
+ "state": {
680
+ "type": "string",
681
+ "enum": [
682
+ "pendingCreate",
683
+ "active",
684
+ "archived",
685
+ "detached",
686
+ "orphaned",
687
+ "unmanaged"
688
+ ],
689
+ "description": "As `RepoSummary.state` in the shared schema."
690
+ },
691
+ "owners": {
692
+ "type": "array",
693
+ "uniqueItems": true,
694
+ "items": {
695
+ "$ref": "#/$defs/Did"
696
+ },
697
+ "description": "The DIDs holding a live, explicitly recorded `git.repo.own` on it."
698
+ },
699
+ "maintainers": {
700
+ "type": "integer",
701
+ "minimum": 0,
702
+ "description": "How many live records of `git.repo.maintain` it has. Implied rights are not counted."
703
+ },
704
+ "committers": {
705
+ "type": "integer",
706
+ "minimum": 0,
707
+ "description": "How many live records of `git.commit.sign` it has. Implied rights are not counted."
708
+ },
709
+ "bootstrap": {
710
+ "$ref": "#/$defs/Bootstrap"
711
+ },
712
+ "syncState": {
713
+ "type": "string",
714
+ "enum": [
715
+ "inSync",
716
+ "drift",
717
+ "pending",
718
+ "unchecked"
719
+ ],
720
+ "description": "As `Sync.state` in the shared schema."
721
+ },
722
+ "checkedAt": {
723
+ "type": "string",
724
+ "format": "date-time",
725
+ "description": "When the forge was last compared. Absent if never."
726
+ },
727
+ "driftCount": {
728
+ "type": "integer",
729
+ "minimum": 0,
730
+ "description": "How many drift items are outstanding. The items themselves are in `git-ns/view`."
731
+ },
732
+ "failedStep": {
733
+ "type": "string",
734
+ "minLength": 1,
735
+ "maxLength": 64,
736
+ "description": "The step that failed on the last create or bootstrap."
737
+ },
738
+ "lastError": {
739
+ "type": "string",
740
+ "minLength": 1,
741
+ "maxLength": 4096,
742
+ "description": "What the bridge said when that step failed."
743
+ },
744
+ "createdBy": {
745
+ "$ref": "#/$defs/Did",
746
+ "description": "Who created it through the VTC. Absent for an adopted or unmanaged repository."
747
+ },
748
+ "createdAt": {
749
+ "type": "string",
750
+ "format": "date-time",
751
+ "description": "When the VTC first recorded it."
752
+ },
753
+ "guard": {
754
+ "type": "string",
755
+ "minLength": 1,
756
+ "maxLength": 64,
757
+ "description": "The guard in force against a pull request satisfying its own check, as the bridge last reported it: `requiredWorkflow`, `codeOwnerReview`, `bridgePostedCheck`, `protectedFiles` or `none`. A client treats any other value as `none`."
758
+ },
759
+ "steps": {
760
+ "type": "array",
761
+ "maxItems": 64,
762
+ "items": {
763
+ "$ref": "#/$defs/StepOutcome"
764
+ },
765
+ "description": "Per-step outcomes of the last create, bootstrap or inspect job. Empty until one has been reported."
766
+ },
767
+ "lastCheck": {
768
+ "$ref": "#/$defs/LastCheck"
769
+ },
770
+ "roleMap": {
771
+ "$ref": "#/$defs/RoleMap",
772
+ "description": "The forge role each right projects to on this repository under the serving bridge's reported map. Absent while the namespace's map is unknown."
773
+ },
774
+ "roleMapStale": {
775
+ "type": "boolean",
776
+ "description": "The bridge last projected this repository's roles under an earlier role map, and the re-projection queued for it has not yet succeeded."
777
+ }
778
+ }
779
+ },
780
+ "Response": {
781
+ "$anchor": "response",
782
+ "title": "Git Namespaces — List Repositories — response payload",
783
+ "description": "The repositories in the namespaces the caller administers, or in the one asked for.",
784
+ "type": "object",
785
+ "additionalProperties": false,
786
+ "required": [
787
+ "repos"
788
+ ],
789
+ "properties": {
790
+ "repos": {
791
+ "type": "array",
792
+ "items": {
793
+ "$ref": "#/$defs/RepoStatus"
794
+ },
795
+ "description": "Every repository recorded in an administered namespace, in any state, ordered by `resource`; for a holder of the community-administrator capability without `namespace`, also every repository whose namespace is no longer bound."
796
+ },
797
+ "ext": {
798
+ "$ref": "#/$defs/Ext"
799
+ }
800
+ }
801
+ },
802
+ "Ext": {
803
+ "title": "Ext",
804
+ "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.",
805
+ "type": "object",
806
+ "minProperties": 1,
807
+ "additionalProperties": true,
808
+ "propertyNames": {
809
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
810
+ }
811
+ },
812
+ "Did": {
813
+ "title": "Did",
814
+ "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.",
815
+ "type": "string",
816
+ "maxLength": 2048,
817
+ "pattern": "^did:[a-z0-9]+:(?:(?:[A-Za-z0-9._-]|%[0-9A-Fa-f]{2})*:)*(?:[A-Za-z0-9._-]|%[0-9A-Fa-f]{2})+$"
818
+ },
819
+ "Bootstrap": {
820
+ "title": "Bootstrap",
821
+ "description": "Whether each step that turns commit trust on for a repository is in place, as last reported. A step that this forge's plan does not need reads `true`.",
822
+ "type": "object",
823
+ "additionalProperties": false,
824
+ "required": [
825
+ "workflow",
826
+ "keyring",
827
+ "variables",
828
+ "requiredCheck"
829
+ ],
830
+ "properties": {
831
+ "workflow": {
832
+ "type": "boolean",
833
+ "description": "The verify-trust check runs on the repository's pull requests — from a workflow committed to it, or, where the forge supports it, required on it from the namespace's own bridge-managed workflow repository at a pinned commit."
834
+ },
835
+ "keyring": {
836
+ "type": "boolean",
837
+ "description": "The exempt platform keyring for forge-signed merge commits is committed, or the forge's plan does not need one."
838
+ },
839
+ "variables": {
840
+ "type": "boolean",
841
+ "description": "The repository names the Trust Registry and this VTC as its trust anchors."
842
+ },
843
+ "requiredCheck": {
844
+ "type": "boolean",
845
+ "description": "The forge refuses to merge into the default branch unless the verify-trust check passes, with no bypass, and a pull request cannot change what that check runs: an organisation-required workflow, code-owner review of workflow files, or protected workflow paths, as the forge allows."
846
+ }
847
+ }
848
+ },
849
+ "RepoVisibility": {
850
+ "title": "RepoVisibility",
851
+ "type": "string",
852
+ "enum": [
853
+ "public",
854
+ "private"
855
+ ],
856
+ "description": "Repository visibility on the forge."
857
+ },
858
+ "ForgeId": {
859
+ "title": "ForgeId",
860
+ "description": "An identifier the forge itself assigns — a repository id, a user or organisation id — carried as a string so a forge whose ids are not numbers needs no new version. GitHub and Forgejo ids are decimal integers written as strings (`\"812736451\"`). Unlike a name, it survives renames and transfers, which is why rights and bindings are keyed by it.",
861
+ "type": "string",
862
+ "minLength": 1,
863
+ "maxLength": 64
864
+ },
865
+ "RepoResource": {
866
+ "title": "RepoResource",
867
+ "description": "A forge-qualified resource naming exactly one repository: `<forge-host>/<owner>/<repo>`, lowercase.",
868
+ "type": "string",
869
+ "maxLength": 455,
870
+ "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}/[a-z0-9_-][a-z0-9._-]{0,99}$"
871
+ },
872
+ "NamespaceId": {
873
+ "title": "NamespaceId",
874
+ "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.",
875
+ "type": "string",
876
+ "minLength": 1,
877
+ "maxLength": 128
878
+ }
879
+ }
880
+ } as const;
881
+
882
+ /**
883
+ * SPEC.md §7.2 policy for the request variant, from this specification's
884
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
885
+ * per-specification and cannot be derived from the document alone, and
886
+ * item 2 needs the schema this carries.
887
+ */
888
+ export const SPEC = {
889
+ typeUri: TYPE_URI,
890
+ isBearer: false,
891
+ isProofRequired: true,
892
+ isRecipientRequired: true,
893
+ isIssuedAtRequired: false,
894
+ payloadSchema: PAYLOAD_SCHEMA,
895
+ } as const;
896
+
897
+ /**
898
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
899
+ * tracks the *issuer* party's requirement because a response swaps the
900
+ * parties (§7.3 item 5).
901
+ */
902
+ export const RESPONSE_SPEC = {
903
+ typeUri: RESPONSE_TYPE_URI,
904
+ isBearer: false,
905
+ isProofRequired: true,
906
+ isRecipientRequired: true,
907
+ isIssuedAtRequired: false,
908
+ payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
909
+ } as const;