@openvtc/trust-tasks 0.20.7 → 0.21.0

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 (253) hide show
  1. package/CHANGELOG.md +320 -0
  2. package/dist/_shared/components.d.ts +299 -2
  3. package/dist/_shared/components.d.ts.map +1 -1
  4. package/dist/auth/passkey/enroll/invite/0.2/payload.d.ts +456 -0
  5. package/dist/auth/passkey/enroll/invite/0.2/payload.d.ts.map +1 -0
  6. package/dist/auth/passkey/enroll/invite/0.2/payload.js +248 -0
  7. package/dist/auth/passkey/enroll/invite/0.2/payload.js.map +1 -0
  8. package/dist/auth/passkey/enroll/redeem/finish/0.1/payload.d.ts +728 -0
  9. package/dist/auth/passkey/enroll/redeem/finish/0.1/payload.d.ts.map +1 -0
  10. package/dist/auth/passkey/enroll/redeem/finish/0.1/payload.js +430 -0
  11. package/dist/auth/passkey/enroll/redeem/finish/0.1/payload.js.map +1 -0
  12. package/dist/auth/passkey/enroll/redeem/start/0.1/payload.d.ts +1043 -0
  13. package/dist/auth/passkey/enroll/redeem/start/0.1/payload.d.ts.map +1 -0
  14. package/dist/auth/passkey/enroll/redeem/start/0.1/payload.js +628 -0
  15. package/dist/auth/passkey/enroll/redeem/start/0.1/payload.js.map +1 -0
  16. package/dist/auth/passkey/revoke/finish/0.2/payload.d.ts +533 -0
  17. package/dist/auth/passkey/revoke/finish/0.2/payload.d.ts.map +1 -0
  18. package/dist/auth/passkey/revoke/finish/0.2/payload.js +315 -0
  19. package/dist/auth/passkey/revoke/finish/0.2/payload.js.map +1 -0
  20. package/dist/auth/passkey/revoke/start/0.2/payload.d.ts +511 -0
  21. package/dist/auth/passkey/revoke/start/0.2/payload.d.ts.map +1 -0
  22. package/dist/auth/passkey/revoke/start/0.2/payload.js +297 -0
  23. package/dist/auth/passkey/revoke/start/0.2/payload.js.map +1 -0
  24. package/dist/auth/step-up/approve-request/0.3/payload.d.ts +613 -0
  25. package/dist/auth/step-up/approve-request/0.3/payload.d.ts.map +1 -0
  26. package/dist/auth/step-up/approve-request/0.3/payload.js +345 -0
  27. package/dist/auth/step-up/approve-request/0.3/payload.js.map +1 -0
  28. package/dist/auth/step-up/approve-response/0.4/payload.d.ts +887 -0
  29. package/dist/auth/step-up/approve-response/0.4/payload.d.ts.map +1 -0
  30. package/dist/auth/step-up/approve-response/0.4/payload.js +504 -0
  31. package/dist/auth/step-up/approve-response/0.4/payload.js.map +1 -0
  32. package/dist/auth/step-up/approve-response/0.5/payload.d.ts +887 -0
  33. package/dist/auth/step-up/approve-response/0.5/payload.d.ts.map +1 -0
  34. package/dist/auth/step-up/approve-response/0.5/payload.js +504 -0
  35. package/dist/auth/step-up/approve-response/0.5/payload.js.map +1 -0
  36. package/dist/backup/abort/0.1/payload.d.ts +262 -0
  37. package/dist/backup/abort/0.1/payload.d.ts.map +1 -0
  38. package/dist/backup/abort/0.1/payload.js +146 -0
  39. package/dist/backup/abort/0.1/payload.js.map +1 -0
  40. package/dist/backup/complete-export/0.1/payload.d.ts +262 -0
  41. package/dist/backup/complete-export/0.1/payload.d.ts.map +1 -0
  42. package/dist/backup/complete-export/0.1/payload.js +146 -0
  43. package/dist/backup/complete-export/0.1/payload.js.map +1 -0
  44. package/dist/backup/finalize-import/0.1/payload.d.ts +395 -0
  45. package/dist/backup/finalize-import/0.1/payload.d.ts.map +1 -0
  46. package/dist/backup/finalize-import/0.1/payload.js +209 -0
  47. package/dist/backup/finalize-import/0.1/payload.js.map +1 -0
  48. package/dist/backup/get-chunk/0.1/payload.d.ts +461 -0
  49. package/dist/backup/get-chunk/0.1/payload.d.ts.map +1 -0
  50. package/dist/backup/get-chunk/0.1/payload.js +250 -0
  51. package/dist/backup/get-chunk/0.1/payload.js.map +1 -0
  52. package/dist/backup/initiate-export/0.1/payload.d.ts +896 -0
  53. package/dist/backup/initiate-export/0.1/payload.d.ts.map +1 -0
  54. package/dist/backup/initiate-export/0.1/payload.js +507 -0
  55. package/dist/backup/initiate-export/0.1/payload.js.map +1 -0
  56. package/dist/backup/initiate-import/0.1/payload.d.ts +888 -0
  57. package/dist/backup/initiate-import/0.1/payload.d.ts.map +1 -0
  58. package/dist/backup/initiate-import/0.1/payload.js +504 -0
  59. package/dist/backup/initiate-import/0.1/payload.js.map +1 -0
  60. package/dist/backup/put-chunk/0.1/payload.d.ts +495 -0
  61. package/dist/backup/put-chunk/0.1/payload.d.ts.map +1 -0
  62. package/dist/backup/put-chunk/0.1/payload.js +265 -0
  63. package/dist/backup/put-chunk/0.1/payload.js.map +1 -0
  64. package/dist/device/list/0.1/payload.d.ts +4 -4
  65. package/dist/device/list/0.1/payload.d.ts.map +1 -1
  66. package/dist/device/list/0.1/payload.js +4 -2
  67. package/dist/device/list/0.1/payload.js.map +1 -1
  68. package/dist/device/list/0.2/payload.d.ts +4 -4
  69. package/dist/device/list/0.2/payload.d.ts.map +1 -1
  70. package/dist/device/list/0.2/payload.js +4 -2
  71. package/dist/device/list/0.2/payload.js.map +1 -1
  72. package/dist/device/register/0.1/payload.d.ts +4 -4
  73. package/dist/device/register/0.1/payload.d.ts.map +1 -1
  74. package/dist/device/register/0.1/payload.js +4 -2
  75. package/dist/device/register/0.1/payload.js.map +1 -1
  76. package/dist/device/register/0.2/payload.d.ts +4 -4
  77. package/dist/device/register/0.2/payload.d.ts.map +1 -1
  78. package/dist/device/register/0.2/payload.js +4 -2
  79. package/dist/device/register/0.2/payload.js.map +1 -1
  80. package/dist/git-ns/_shared/0.4/git-ns.d.ts +16 -0
  81. package/dist/git-ns/_shared/0.4/git-ns.d.ts.map +1 -0
  82. package/dist/git-ns/_shared/0.4/git-ns.js +6 -0
  83. package/dist/git-ns/_shared/0.4/git-ns.js.map +1 -0
  84. package/dist/git-ns/account/link-status/0.1/payload.d.ts +2 -2
  85. package/dist/git-ns/account/link-status/0.1/payload.js +2 -2
  86. package/dist/git-ns/account/link-status/0.1/payload.js.map +1 -1
  87. package/dist/git-ns/account/unlink/0.1/payload.d.ts +411 -0
  88. package/dist/git-ns/account/unlink/0.1/payload.d.ts.map +1 -0
  89. package/dist/git-ns/account/unlink/0.1/payload.js +228 -0
  90. package/dist/git-ns/account/unlink/0.1/payload.js.map +1 -0
  91. package/dist/git-ns/bridge/event/0.3/payload.d.ts +1682 -0
  92. package/dist/git-ns/bridge/event/0.3/payload.d.ts.map +1 -0
  93. package/dist/git-ns/bridge/event/0.3/payload.js +971 -0
  94. package/dist/git-ns/bridge/event/0.3/payload.js.map +1 -0
  95. package/dist/git-ns/bridge/job/0.4/payload.d.ts +1068 -0
  96. package/dist/git-ns/bridge/job/0.4/payload.d.ts.map +1 -0
  97. package/dist/git-ns/bridge/job/0.4/payload.js +573 -0
  98. package/dist/git-ns/bridge/job/0.4/payload.js.map +1 -0
  99. package/dist/git-ns/drift/resolve/0.3/payload.d.ts +1072 -0
  100. package/dist/git-ns/drift/resolve/0.3/payload.d.ts.map +1 -0
  101. package/dist/git-ns/drift/resolve/0.3/payload.js +634 -0
  102. package/dist/git-ns/drift/resolve/0.3/payload.js.map +1 -0
  103. package/dist/git-ns/namespace/reseat/0.3/payload.d.ts +515 -0
  104. package/dist/git-ns/namespace/reseat/0.3/payload.d.ts.map +1 -0
  105. package/dist/git-ns/namespace/reseat/0.3/payload.js +296 -0
  106. package/dist/git-ns/namespace/reseat/0.3/payload.js.map +1 -0
  107. package/dist/git-ns/repo/create/0.3/payload.d.ts +1101 -0
  108. package/dist/git-ns/repo/create/0.3/payload.d.ts.map +1 -0
  109. package/dist/git-ns/repo/create/0.3/payload.js +646 -0
  110. package/dist/git-ns/repo/create/0.3/payload.js.map +1 -0
  111. package/dist/git-ns/right/break-glass/0.1/payload.d.ts +685 -0
  112. package/dist/git-ns/right/break-glass/0.1/payload.d.ts.map +1 -0
  113. package/dist/git-ns/right/break-glass/0.1/payload.js +397 -0
  114. package/dist/git-ns/right/break-glass/0.1/payload.js.map +1 -0
  115. package/dist/git-ns/right/break-glass-notice/0.1/payload.d.ts +384 -0
  116. package/dist/git-ns/right/break-glass-notice/0.1/payload.d.ts.map +1 -0
  117. package/dist/git-ns/right/break-glass-notice/0.1/payload.js +216 -0
  118. package/dist/git-ns/right/break-glass-notice/0.1/payload.js.map +1 -0
  119. package/dist/git-ns/right/grant/0.3/payload.d.ts +678 -0
  120. package/dist/git-ns/right/grant/0.3/payload.d.ts.map +1 -0
  121. package/dist/git-ns/right/grant/0.3/payload.js +383 -0
  122. package/dist/git-ns/right/grant/0.3/payload.js.map +1 -0
  123. package/dist/git-ns/right/ratify/0.1/payload.d.ts +702 -0
  124. package/dist/git-ns/right/ratify/0.1/payload.d.ts.map +1 -0
  125. package/dist/git-ns/right/ratify/0.1/payload.js +404 -0
  126. package/dist/git-ns/right/ratify/0.1/payload.js.map +1 -0
  127. package/dist/git-ns/right/revoke/0.3/payload.d.ts +664 -0
  128. package/dist/git-ns/right/revoke/0.3/payload.d.ts.map +1 -0
  129. package/dist/git-ns/right/revoke/0.3/payload.js +378 -0
  130. package/dist/git-ns/right/revoke/0.3/payload.js.map +1 -0
  131. package/dist/git-ns/roles/reproject/0.1/payload.d.ts +325 -0
  132. package/dist/git-ns/roles/reproject/0.1/payload.d.ts.map +1 -0
  133. package/dist/git-ns/roles/reproject/0.1/payload.js +176 -0
  134. package/dist/git-ns/roles/reproject/0.1/payload.js.map +1 -0
  135. package/dist/git-ns/view/0.1/payload.d.ts +2 -2
  136. package/dist/git-ns/view/0.1/payload.js +2 -2
  137. package/dist/git-ns/view/0.1/payload.js.map +1 -1
  138. package/dist/git-ns/view/0.2/payload.d.ts +2 -2
  139. package/dist/git-ns/view/0.2/payload.js +2 -2
  140. package/dist/git-ns/view/0.2/payload.js.map +1 -1
  141. package/dist/git-ns/view/0.3/payload.d.ts +2 -2
  142. package/dist/git-ns/view/0.3/payload.js +2 -2
  143. package/dist/git-ns/view/0.3/payload.js.map +1 -1
  144. package/dist/git-ns/view/0.4/payload.d.ts +1696 -0
  145. package/dist/git-ns/view/0.4/payload.d.ts.map +1 -0
  146. package/dist/git-ns/view/0.4/payload.js +1012 -0
  147. package/dist/git-ns/view/0.4/payload.js.map +1 -0
  148. package/dist/index.d.ts +39 -0
  149. package/dist/index.d.ts.map +1 -1
  150. package/dist/index.js +39 -0
  151. package/dist/index.js.map +1 -1
  152. package/dist/messaging/message/status/0.1/payload.d.ts +372 -0
  153. package/dist/messaging/message/status/0.1/payload.d.ts.map +1 -0
  154. package/dist/messaging/message/status/0.1/payload.js +214 -0
  155. package/dist/messaging/message/status/0.1/payload.js.map +1 -0
  156. package/dist/vta/_shared/0.3/did-key-roles.d.ts +16 -0
  157. package/dist/vta/_shared/0.3/did-key-roles.d.ts.map +1 -0
  158. package/dist/vta/_shared/0.3/did-key-roles.js +6 -0
  159. package/dist/vta/_shared/0.3/did-key-roles.js.map +1 -0
  160. package/dist/vta/attestation/mnemonic-export/1.0/payload.d.ts +326 -0
  161. package/dist/vta/attestation/mnemonic-export/1.0/payload.d.ts.map +1 -0
  162. package/dist/vta/attestation/mnemonic-export/1.0/payload.js +175 -0
  163. package/dist/vta/attestation/mnemonic-export/1.0/payload.js.map +1 -0
  164. package/dist/vta/webvh/dids/keys/add/1.0/payload.d.ts +1914 -0
  165. package/dist/vta/webvh/dids/keys/add/1.0/payload.d.ts.map +1 -0
  166. package/dist/vta/webvh/dids/keys/add/1.0/payload.js +1128 -0
  167. package/dist/vta/webvh/dids/keys/add/1.0/payload.js.map +1 -0
  168. package/dist/vta/webvh/dids/keys/list/1.0/payload.d.ts +1603 -0
  169. package/dist/vta/webvh/dids/keys/list/1.0/payload.d.ts.map +1 -0
  170. package/dist/vta/webvh/dids/keys/list/1.0/payload.js +942 -0
  171. package/dist/vta/webvh/dids/keys/list/1.0/payload.js.map +1 -0
  172. package/dist/vta/webvh/dids/keys/retire/1.0/payload.d.ts +1914 -0
  173. package/dist/vta/webvh/dids/keys/retire/1.0/payload.d.ts.map +1 -0
  174. package/dist/vta/webvh/dids/keys/retire/1.0/payload.js +1123 -0
  175. package/dist/vta/webvh/dids/keys/retire/1.0/payload.js.map +1 -0
  176. package/dist/vta/webvh/dids/keys/revoke/1.0/payload.d.ts +2021 -0
  177. package/dist/vta/webvh/dids/keys/revoke/1.0/payload.d.ts.map +1 -0
  178. package/dist/vta/webvh/dids/keys/revoke/1.0/payload.js +1168 -0
  179. package/dist/vta/webvh/dids/keys/revoke/1.0/payload.js.map +1 -0
  180. package/dist/vta/webvh/dids/rotate-keys/2.0/payload.d.ts +1992 -0
  181. package/dist/vta/webvh/dids/rotate-keys/2.0/payload.d.ts.map +1 -0
  182. package/dist/vta/webvh/dids/rotate-keys/2.0/payload.js +1151 -0
  183. package/dist/vta/webvh/dids/rotate-keys/2.0/payload.js.map +1 -0
  184. package/dist/vta/webvh/dids/update/2.0/payload.d.ts +1062 -0
  185. package/dist/vta/webvh/dids/update/2.0/payload.d.ts.map +1 -0
  186. package/dist/vta/webvh/dids/update/2.0/payload.js +616 -0
  187. package/dist/vta/webvh/dids/update/2.0/payload.js.map +1 -0
  188. package/dist/vtc/credentials/reissue/0.1/payload.d.ts +502 -0
  189. package/dist/vtc/credentials/reissue/0.1/payload.d.ts.map +1 -0
  190. package/dist/vtc/credentials/reissue/0.1/payload.js +282 -0
  191. package/dist/vtc/credentials/reissue/0.1/payload.js.map +1 -0
  192. package/dist/vtc/members/personhood/challenge/0.1/payload.d.ts +2 -2
  193. package/dist/vtc/members/personhood/challenge/0.1/payload.js +2 -2
  194. package/dist/vtc/members/personhood/challenge/0.1/payload.js.map +1 -1
  195. package/dist/vtc/vetting/vetters/profile/0.1/payload.d.ts +2 -2
  196. package/dist/vtc/vetting/vetters/profile/0.1/payload.js +2 -2
  197. package/dist/vtc/vetting/vetters/profile/0.1/payload.js.map +1 -1
  198. package/dist/vtc/vetting/vetters/resend/0.1/payload.d.ts +2 -2
  199. package/dist/vtc/vetting/vetters/resend/0.1/payload.js +2 -2
  200. package/dist/vtc/vetting/vetters/resend/0.1/payload.js.map +1 -1
  201. package/package.json +1 -1
  202. package/src/_shared/components.ts +313 -2
  203. package/src/auth/passkey/enroll/invite/0.2/payload.ts +325 -0
  204. package/src/auth/passkey/enroll/redeem/finish/0.1/payload.ts +499 -0
  205. package/src/auth/passkey/enroll/redeem/start/0.1/payload.ts +700 -0
  206. package/src/auth/passkey/revoke/finish/0.2/payload.ts +379 -0
  207. package/src/auth/passkey/revoke/start/0.2/payload.ts +349 -0
  208. package/src/auth/step-up/approve-request/0.3/payload.ts +421 -0
  209. package/src/auth/step-up/approve-response/0.4/payload.ts +593 -0
  210. package/src/auth/step-up/approve-response/0.5/payload.ts +593 -0
  211. package/src/backup/abort/0.1/payload.ts +191 -0
  212. package/src/backup/complete-export/0.1/payload.ts +191 -0
  213. package/src/backup/finalize-import/0.1/payload.ts +279 -0
  214. package/src/backup/get-chunk/0.1/payload.ts +308 -0
  215. package/src/backup/initiate-export/0.1/payload.ts +564 -0
  216. package/src/backup/initiate-import/0.1/payload.ts +561 -0
  217. package/src/backup/put-chunk/0.1/payload.ts +331 -0
  218. package/src/device/list/0.1/payload.ts +4 -2
  219. package/src/device/list/0.2/payload.ts +4 -2
  220. package/src/device/register/0.1/payload.ts +4 -2
  221. package/src/device/register/0.2/payload.ts +4 -2
  222. package/src/git-ns/_shared/0.4/git-ns.ts +17 -0
  223. package/src/git-ns/account/link-status/0.1/payload.ts +2 -2
  224. package/src/git-ns/account/unlink/0.1/payload.ts +274 -0
  225. package/src/git-ns/bridge/event/0.3/payload.ts +1132 -0
  226. package/src/git-ns/bridge/job/0.4/payload.ts +691 -0
  227. package/src/git-ns/drift/resolve/0.3/payload.ts +707 -0
  228. package/src/git-ns/namespace/reseat/0.3/payload.ts +342 -0
  229. package/src/git-ns/repo/create/0.3/payload.ts +706 -0
  230. package/src/git-ns/right/break-glass/0.1/payload.ts +443 -0
  231. package/src/git-ns/right/break-glass-notice/0.1/payload.ts +258 -0
  232. package/src/git-ns/right/grant/0.3/payload.ts +434 -0
  233. package/src/git-ns/right/ratify/0.1/payload.ts +455 -0
  234. package/src/git-ns/right/revoke/0.3/payload.ts +425 -0
  235. package/src/git-ns/roles/reproject/0.1/payload.ts +220 -0
  236. package/src/git-ns/view/0.1/payload.ts +2 -2
  237. package/src/git-ns/view/0.2/payload.ts +2 -2
  238. package/src/git-ns/view/0.3/payload.ts +2 -2
  239. package/src/git-ns/view/0.4/payload.ts +1075 -0
  240. package/src/index.ts +39 -0
  241. package/src/messaging/message/status/0.1/payload.ts +270 -0
  242. package/src/vta/_shared/0.3/did-key-roles.ts +17 -0
  243. package/src/vta/attestation/mnemonic-export/1.0/payload.ts +232 -0
  244. package/src/vta/webvh/dids/keys/add/1.0/payload.ts +1217 -0
  245. package/src/vta/webvh/dids/keys/list/1.0/payload.ts +1004 -0
  246. package/src/vta/webvh/dids/keys/retire/1.0/payload.ts +1212 -0
  247. package/src/vta/webvh/dids/keys/revoke/1.0/payload.ts +1276 -0
  248. package/src/vta/webvh/dids/rotate-keys/2.0/payload.ts +1262 -0
  249. package/src/vta/webvh/dids/update/2.0/payload.ts +713 -0
  250. package/src/vtc/credentials/reissue/0.1/payload.ts +357 -0
  251. package/src/vtc/members/personhood/challenge/0.1/payload.ts +2 -2
  252. package/src/vtc/vetting/vetters/profile/0.1/payload.ts +2 -2
  253. package/src/vtc/vetting/vetters/resend/0.1/payload.ts +2 -2
@@ -0,0 +1,700 @@
1
+ /**
2
+ * Generated by scripts/build-ts-bindings.mjs — DO NOT EDIT BY HAND.
3
+ * Source: specs/auth/passkey/enroll/redeem/start/0.1/payload.schema.json
4
+ */
5
+
6
+ import type { Ext, PublicKeyCredentialCreationOptions, PublicKeyCredentialDescriptor, PublicKeyCredentialRequestOptions } from "../../../../../../_shared/components.js";
7
+
8
+
9
+ /**
10
+ * The invitee presents an auth/passkey/enroll/invite token and its claim code, and the auth service begins the WebAuthn registration ceremony the invite authorises.
11
+ */
12
+ export interface AuthPasskeyEnrollRedeemStart {
13
+ /**
14
+ * The invite token, as carried in the invite URL.
15
+ */
16
+ token: string;
17
+ /**
18
+ * The claim code the administrator delivered separately.
19
+ */
20
+ claimCode: string;
21
+ /**
22
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
23
+ */
24
+ ext?: Ext;
25
+ }
26
+ /**
27
+ * The registration ceremony the invite authorises.
28
+ */
29
+ export interface AuthPasskeyEnrollRedeemStartResponsePayload {
30
+ /**
31
+ * Opaque handle correlating this start with the matching auth/passkey/enroll/redeem/finish. Echoed verbatim.
32
+ */
33
+ enrollmentId: string;
34
+ /**
35
+ * The VID the invite binds the credential to, so the invitee can see whose passkey they are enrolling before they create it.
36
+ */
37
+ subject: string;
38
+ /**
39
+ * What the credential will authenticate, from the invite.
40
+ */
41
+ purpose: "session" | "stepUp";
42
+ /**
43
+ * The inviter's suggested label, if any. The invitee MAY override it at finish.
44
+ */
45
+ deviceLabel?: string;
46
+ /**
47
+ * PublicKeyCredentialCreationOptions for navigator.credentials.create.
48
+ */
49
+ options: PublicKeyCredentialCreationOptions;
50
+ /**
51
+ * PublicKeyCredentialRequestOptions over the subject's existing credentials of the same purpose, present exactly when the subject already has one. The invitee MUST run both ceremonies and return both results to finish.
52
+ */
53
+ uvOptions?: PublicKeyCredentialRequestOptions;
54
+ /**
55
+ * When this ceremony lapses (not the invite).
56
+ */
57
+ expiresAt: string;
58
+ /**
59
+ * Ecosystem-defined extension members per SPEC.md §4.5.1.
60
+ */
61
+ ext?: Ext;
62
+ }
63
+
64
+ /** Shared definitions this specification references, re-exported under the names it used to declare them with. */
65
+ export type { Ext, PublicKeyCredentialCreationOptions, PublicKeyCredentialDescriptor, PublicKeyCredentialRequestOptions };
66
+
67
+ /** Trust Task type URI. */
68
+ export const TYPE_URI = "https://trusttasks.org/spec/auth/passkey/enroll/redeem/start/0.1" as const;
69
+
70
+ /** Stable alias for this specification's request payload shape. */
71
+ export type Payload = AuthPasskeyEnrollRedeemStart;
72
+
73
+ /** Trust Task response type URI (request type URI + "#response"). */
74
+ export const RESPONSE_TYPE_URI = "https://trusttasks.org/spec/auth/passkey/enroll/redeem/start/0.1#response" as const;
75
+
76
+ /** Stable alias for this specification's success-response payload shape. */
77
+ export type Response = AuthPasskeyEnrollRedeemStartResponsePayload;
78
+
79
+ /**
80
+ * This specification's payload schema, as a value.
81
+ *
82
+ * SPEC.md §7.2 item 2 is performed against this. It is shipped as data
83
+ * rather than only as a `.json` file because TypeScript types are erased
84
+ * at runtime: without a schema a consumer has nothing to validate, and
85
+ * every REQUIRED payload member is optional in practice. Cross-file
86
+ * `$ref`s are already inlined, so it needs no resolver.
87
+ */
88
+ export const PAYLOAD_SCHEMA = {
89
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
90
+ "$id": "https://trusttasks.org/spec/auth/passkey/enroll/redeem/start/0.1",
91
+ "title": "Auth — Passkey Enroll (redeem, start)",
92
+ "description": "The invitee presents an auth/passkey/enroll/invite token and its claim code, and the auth service begins the WebAuthn registration ceremony the invite authorises.",
93
+ "type": "object",
94
+ "additionalProperties": false,
95
+ "required": [
96
+ "token",
97
+ "claimCode"
98
+ ],
99
+ "properties": {
100
+ "token": {
101
+ "type": "string",
102
+ "minLength": 16,
103
+ "maxLength": 512,
104
+ "description": "The invite token, as carried in the invite URL."
105
+ },
106
+ "claimCode": {
107
+ "type": "string",
108
+ "minLength": 1,
109
+ "maxLength": 64,
110
+ "description": "The claim code the administrator delivered separately."
111
+ },
112
+ "ext": {
113
+ "$ref": "#/$defs/Ext",
114
+ "description": "Ecosystem-defined extension members per SPEC.md §4.5.1."
115
+ }
116
+ },
117
+ "$defs": {
118
+ "Response": {
119
+ "$anchor": "response",
120
+ "title": "Auth Passkey Enroll Redeem Start — response payload",
121
+ "description": "The registration ceremony the invite authorises.",
122
+ "type": "object",
123
+ "additionalProperties": false,
124
+ "required": [
125
+ "enrollmentId",
126
+ "subject",
127
+ "purpose",
128
+ "options",
129
+ "expiresAt"
130
+ ],
131
+ "properties": {
132
+ "enrollmentId": {
133
+ "type": "string",
134
+ "minLength": 1,
135
+ "description": "Opaque handle correlating this start with the matching auth/passkey/enroll/redeem/finish. Echoed verbatim."
136
+ },
137
+ "subject": {
138
+ "type": "string",
139
+ "minLength": 1,
140
+ "description": "The VID the invite binds the credential to, so the invitee can see whose passkey they are enrolling before they create it."
141
+ },
142
+ "purpose": {
143
+ "type": "string",
144
+ "enum": [
145
+ "session",
146
+ "stepUp"
147
+ ],
148
+ "description": "What the credential will authenticate, from the invite."
149
+ },
150
+ "deviceLabel": {
151
+ "type": "string",
152
+ "maxLength": 256,
153
+ "description": "The inviter's suggested label, if any. The invitee MAY override it at finish."
154
+ },
155
+ "options": {
156
+ "$ref": "#/$defs/CredentialCreationOptions",
157
+ "description": "PublicKeyCredentialCreationOptions for navigator.credentials.create."
158
+ },
159
+ "uvOptions": {
160
+ "$ref": "#/$defs/CredentialRequestOptions",
161
+ "description": "PublicKeyCredentialRequestOptions over the subject's existing credentials of the same purpose, present exactly when the subject already has one. The invitee MUST run both ceremonies and return both results to finish."
162
+ },
163
+ "expiresAt": {
164
+ "type": "string",
165
+ "format": "date-time",
166
+ "description": "When this ceremony lapses (not the invite)."
167
+ },
168
+ "ext": {
169
+ "$ref": "#/$defs/Ext",
170
+ "description": "Ecosystem-defined extension members per SPEC.md §4.5.1."
171
+ }
172
+ }
173
+ },
174
+ "Ext": {
175
+ "title": "Ext",
176
+ "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.",
177
+ "type": "object",
178
+ "minProperties": 1,
179
+ "additionalProperties": true,
180
+ "propertyNames": {
181
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
182
+ }
183
+ },
184
+ "CredentialRequestOptions": {
185
+ "$anchor": "credentialRequestOptions",
186
+ "title": "PublicKeyCredentialRequestOptions",
187
+ "description": "Server-issued options for `navigator.credentials.get({ publicKey: ... })`.",
188
+ "type": "object",
189
+ "additionalProperties": false,
190
+ "required": [
191
+ "challenge"
192
+ ],
193
+ "properties": {
194
+ "extensions": {
195
+ "type": "object",
196
+ "description": "Client extension inputs, per the WebAuthn Level 2 `AuthenticationExtensionsClientInputs` dictionary.\n\nThis component states that it mirrors the W3C dictionary, and that dictionary defines `extensions`. Omitting it while closing the object with `additionalProperties: false` made the two claims contradict each other: a server emitting standard WebAuthn options could not conform, and the widely-used server libraries emit this member by default.\n\nStructure is deliberately unconstrained. The set of extensions is open and registered outside this framework, so enumerating them here would date the schema against a registry it does not own — and a closed list would reproduce the original defect one revision later."
197
+ },
198
+ "challenge": {
199
+ "type": "string",
200
+ "description": "base64url-encoded one-time nonce."
201
+ },
202
+ "timeout": {
203
+ "type": "integer",
204
+ "minimum": 1
205
+ },
206
+ "rpId": {
207
+ "type": "string",
208
+ "minLength": 1
209
+ },
210
+ "allowCredentials": {
211
+ "type": "array",
212
+ "items": {
213
+ "$ref": "#/$defs/CredentialDescriptor"
214
+ }
215
+ },
216
+ "userVerification": {
217
+ "enum": [
218
+ "discouraged",
219
+ "preferred",
220
+ "required"
221
+ ]
222
+ }
223
+ }
224
+ },
225
+ "CredentialDescriptor": {
226
+ "$anchor": "credentialDescriptor",
227
+ "title": "PublicKeyCredentialDescriptor",
228
+ "type": "object",
229
+ "additionalProperties": false,
230
+ "required": [
231
+ "type",
232
+ "id"
233
+ ],
234
+ "properties": {
235
+ "type": {
236
+ "const": "public-key"
237
+ },
238
+ "id": {
239
+ "type": "string",
240
+ "description": "base64url-encoded credential id."
241
+ },
242
+ "transports": {
243
+ "type": "array",
244
+ "items": {
245
+ "enum": [
246
+ "usb",
247
+ "nfc",
248
+ "ble",
249
+ "internal",
250
+ "hybrid"
251
+ ]
252
+ }
253
+ }
254
+ }
255
+ },
256
+ "CredentialCreationOptions": {
257
+ "$anchor": "credentialCreationOptions",
258
+ "title": "PublicKeyCredentialCreationOptions",
259
+ "description": "Server-issued options for `navigator.credentials.create({ publicKey: ... })`. Mirrors the WebAuthn Level 2 `PublicKeyCredentialCreationOptions` dictionary; binary fields are base64url-encoded strings (rather than ArrayBuffers) so the value is JSON-safe over the wire.",
260
+ "type": "object",
261
+ "additionalProperties": false,
262
+ "required": [
263
+ "challenge",
264
+ "rp",
265
+ "user",
266
+ "pubKeyCredParams"
267
+ ],
268
+ "properties": {
269
+ "extensions": {
270
+ "type": "object",
271
+ "description": "Client extension inputs, per the WebAuthn Level 2 `AuthenticationExtensionsClientInputs` dictionary.\n\nThis component states that it mirrors the W3C dictionary, and that dictionary defines `extensions`. Omitting it while closing the object with `additionalProperties: false` made the two claims contradict each other: a server emitting standard WebAuthn options could not conform, and the widely-used server libraries emit this member by default.\n\nStructure is deliberately unconstrained. The set of extensions is open and registered outside this framework, so enumerating them here would date the schema against a registry it does not own — and a closed list would reproduce the original defect one revision later."
272
+ },
273
+ "challenge": {
274
+ "type": "string",
275
+ "description": "base64url-encoded one-time nonce."
276
+ },
277
+ "rp": {
278
+ "type": "object",
279
+ "additionalProperties": false,
280
+ "required": [
281
+ "id",
282
+ "name"
283
+ ],
284
+ "properties": {
285
+ "id": {
286
+ "type": "string",
287
+ "minLength": 1
288
+ },
289
+ "name": {
290
+ "type": "string",
291
+ "minLength": 1,
292
+ "maxLength": 64
293
+ }
294
+ }
295
+ },
296
+ "user": {
297
+ "type": "object",
298
+ "additionalProperties": false,
299
+ "required": [
300
+ "id",
301
+ "name",
302
+ "displayName"
303
+ ],
304
+ "properties": {
305
+ "id": {
306
+ "type": "string",
307
+ "description": "base64url-encoded user handle. SHOULD be a stable opaque identifier — never reuse a human-readable username here."
308
+ },
309
+ "name": {
310
+ "type": "string",
311
+ "minLength": 1,
312
+ "maxLength": 64
313
+ },
314
+ "displayName": {
315
+ "type": "string",
316
+ "maxLength": 64
317
+ }
318
+ }
319
+ },
320
+ "pubKeyCredParams": {
321
+ "type": "array",
322
+ "minItems": 1,
323
+ "items": {
324
+ "type": "object",
325
+ "additionalProperties": false,
326
+ "required": [
327
+ "type",
328
+ "alg"
329
+ ],
330
+ "properties": {
331
+ "type": {
332
+ "const": "public-key"
333
+ },
334
+ "alg": {
335
+ "type": "integer",
336
+ "description": "COSE algorithm identifier (e.g. -8 Ed25519, -7 ES256, -257 RS256)."
337
+ }
338
+ }
339
+ }
340
+ },
341
+ "timeout": {
342
+ "type": "integer",
343
+ "minimum": 1
344
+ },
345
+ "excludeCredentials": {
346
+ "type": "array",
347
+ "items": {
348
+ "$ref": "#/$defs/CredentialDescriptor"
349
+ }
350
+ },
351
+ "authenticatorSelection": {
352
+ "type": "object",
353
+ "additionalProperties": false,
354
+ "properties": {
355
+ "authenticatorAttachment": {
356
+ "enum": [
357
+ "platform",
358
+ "cross-platform"
359
+ ]
360
+ },
361
+ "requireResidentKey": {
362
+ "type": "boolean"
363
+ },
364
+ "residentKey": {
365
+ "enum": [
366
+ "discouraged",
367
+ "preferred",
368
+ "required"
369
+ ]
370
+ },
371
+ "userVerification": {
372
+ "enum": [
373
+ "discouraged",
374
+ "preferred",
375
+ "required"
376
+ ]
377
+ }
378
+ }
379
+ },
380
+ "attestation": {
381
+ "enum": [
382
+ "none",
383
+ "indirect",
384
+ "direct",
385
+ "enterprise"
386
+ ]
387
+ }
388
+ }
389
+ }
390
+ }
391
+ } as const;
392
+
393
+ /** As {@link PAYLOAD_SCHEMA}, for the success-response variant. */
394
+ export const RESPONSE_PAYLOAD_SCHEMA = {
395
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
396
+ "$ref": "#/$defs/Response",
397
+ "$defs": {
398
+ "Response": {
399
+ "$anchor": "response",
400
+ "title": "Auth Passkey Enroll Redeem Start — response payload",
401
+ "description": "The registration ceremony the invite authorises.",
402
+ "type": "object",
403
+ "additionalProperties": false,
404
+ "required": [
405
+ "enrollmentId",
406
+ "subject",
407
+ "purpose",
408
+ "options",
409
+ "expiresAt"
410
+ ],
411
+ "properties": {
412
+ "enrollmentId": {
413
+ "type": "string",
414
+ "minLength": 1,
415
+ "description": "Opaque handle correlating this start with the matching auth/passkey/enroll/redeem/finish. Echoed verbatim."
416
+ },
417
+ "subject": {
418
+ "type": "string",
419
+ "minLength": 1,
420
+ "description": "The VID the invite binds the credential to, so the invitee can see whose passkey they are enrolling before they create it."
421
+ },
422
+ "purpose": {
423
+ "type": "string",
424
+ "enum": [
425
+ "session",
426
+ "stepUp"
427
+ ],
428
+ "description": "What the credential will authenticate, from the invite."
429
+ },
430
+ "deviceLabel": {
431
+ "type": "string",
432
+ "maxLength": 256,
433
+ "description": "The inviter's suggested label, if any. The invitee MAY override it at finish."
434
+ },
435
+ "options": {
436
+ "$ref": "#/$defs/CredentialCreationOptions",
437
+ "description": "PublicKeyCredentialCreationOptions for navigator.credentials.create."
438
+ },
439
+ "uvOptions": {
440
+ "$ref": "#/$defs/CredentialRequestOptions",
441
+ "description": "PublicKeyCredentialRequestOptions over the subject's existing credentials of the same purpose, present exactly when the subject already has one. The invitee MUST run both ceremonies and return both results to finish."
442
+ },
443
+ "expiresAt": {
444
+ "type": "string",
445
+ "format": "date-time",
446
+ "description": "When this ceremony lapses (not the invite)."
447
+ },
448
+ "ext": {
449
+ "$ref": "#/$defs/Ext",
450
+ "description": "Ecosystem-defined extension members per SPEC.md §4.5.1."
451
+ }
452
+ }
453
+ },
454
+ "Ext": {
455
+ "title": "Ext",
456
+ "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.",
457
+ "type": "object",
458
+ "minProperties": 1,
459
+ "additionalProperties": true,
460
+ "propertyNames": {
461
+ "pattern": "^[a-z][a-z0-9-]*(\\.[a-z0-9-]+)+$"
462
+ }
463
+ },
464
+ "CredentialRequestOptions": {
465
+ "$anchor": "credentialRequestOptions",
466
+ "title": "PublicKeyCredentialRequestOptions",
467
+ "description": "Server-issued options for `navigator.credentials.get({ publicKey: ... })`.",
468
+ "type": "object",
469
+ "additionalProperties": false,
470
+ "required": [
471
+ "challenge"
472
+ ],
473
+ "properties": {
474
+ "extensions": {
475
+ "type": "object",
476
+ "description": "Client extension inputs, per the WebAuthn Level 2 `AuthenticationExtensionsClientInputs` dictionary.\n\nThis component states that it mirrors the W3C dictionary, and that dictionary defines `extensions`. Omitting it while closing the object with `additionalProperties: false` made the two claims contradict each other: a server emitting standard WebAuthn options could not conform, and the widely-used server libraries emit this member by default.\n\nStructure is deliberately unconstrained. The set of extensions is open and registered outside this framework, so enumerating them here would date the schema against a registry it does not own — and a closed list would reproduce the original defect one revision later."
477
+ },
478
+ "challenge": {
479
+ "type": "string",
480
+ "description": "base64url-encoded one-time nonce."
481
+ },
482
+ "timeout": {
483
+ "type": "integer",
484
+ "minimum": 1
485
+ },
486
+ "rpId": {
487
+ "type": "string",
488
+ "minLength": 1
489
+ },
490
+ "allowCredentials": {
491
+ "type": "array",
492
+ "items": {
493
+ "$ref": "#/$defs/CredentialDescriptor"
494
+ }
495
+ },
496
+ "userVerification": {
497
+ "enum": [
498
+ "discouraged",
499
+ "preferred",
500
+ "required"
501
+ ]
502
+ }
503
+ }
504
+ },
505
+ "CredentialDescriptor": {
506
+ "$anchor": "credentialDescriptor",
507
+ "title": "PublicKeyCredentialDescriptor",
508
+ "type": "object",
509
+ "additionalProperties": false,
510
+ "required": [
511
+ "type",
512
+ "id"
513
+ ],
514
+ "properties": {
515
+ "type": {
516
+ "const": "public-key"
517
+ },
518
+ "id": {
519
+ "type": "string",
520
+ "description": "base64url-encoded credential id."
521
+ },
522
+ "transports": {
523
+ "type": "array",
524
+ "items": {
525
+ "enum": [
526
+ "usb",
527
+ "nfc",
528
+ "ble",
529
+ "internal",
530
+ "hybrid"
531
+ ]
532
+ }
533
+ }
534
+ }
535
+ },
536
+ "CredentialCreationOptions": {
537
+ "$anchor": "credentialCreationOptions",
538
+ "title": "PublicKeyCredentialCreationOptions",
539
+ "description": "Server-issued options for `navigator.credentials.create({ publicKey: ... })`. Mirrors the WebAuthn Level 2 `PublicKeyCredentialCreationOptions` dictionary; binary fields are base64url-encoded strings (rather than ArrayBuffers) so the value is JSON-safe over the wire.",
540
+ "type": "object",
541
+ "additionalProperties": false,
542
+ "required": [
543
+ "challenge",
544
+ "rp",
545
+ "user",
546
+ "pubKeyCredParams"
547
+ ],
548
+ "properties": {
549
+ "extensions": {
550
+ "type": "object",
551
+ "description": "Client extension inputs, per the WebAuthn Level 2 `AuthenticationExtensionsClientInputs` dictionary.\n\nThis component states that it mirrors the W3C dictionary, and that dictionary defines `extensions`. Omitting it while closing the object with `additionalProperties: false` made the two claims contradict each other: a server emitting standard WebAuthn options could not conform, and the widely-used server libraries emit this member by default.\n\nStructure is deliberately unconstrained. The set of extensions is open and registered outside this framework, so enumerating them here would date the schema against a registry it does not own — and a closed list would reproduce the original defect one revision later."
552
+ },
553
+ "challenge": {
554
+ "type": "string",
555
+ "description": "base64url-encoded one-time nonce."
556
+ },
557
+ "rp": {
558
+ "type": "object",
559
+ "additionalProperties": false,
560
+ "required": [
561
+ "id",
562
+ "name"
563
+ ],
564
+ "properties": {
565
+ "id": {
566
+ "type": "string",
567
+ "minLength": 1
568
+ },
569
+ "name": {
570
+ "type": "string",
571
+ "minLength": 1,
572
+ "maxLength": 64
573
+ }
574
+ }
575
+ },
576
+ "user": {
577
+ "type": "object",
578
+ "additionalProperties": false,
579
+ "required": [
580
+ "id",
581
+ "name",
582
+ "displayName"
583
+ ],
584
+ "properties": {
585
+ "id": {
586
+ "type": "string",
587
+ "description": "base64url-encoded user handle. SHOULD be a stable opaque identifier — never reuse a human-readable username here."
588
+ },
589
+ "name": {
590
+ "type": "string",
591
+ "minLength": 1,
592
+ "maxLength": 64
593
+ },
594
+ "displayName": {
595
+ "type": "string",
596
+ "maxLength": 64
597
+ }
598
+ }
599
+ },
600
+ "pubKeyCredParams": {
601
+ "type": "array",
602
+ "minItems": 1,
603
+ "items": {
604
+ "type": "object",
605
+ "additionalProperties": false,
606
+ "required": [
607
+ "type",
608
+ "alg"
609
+ ],
610
+ "properties": {
611
+ "type": {
612
+ "const": "public-key"
613
+ },
614
+ "alg": {
615
+ "type": "integer",
616
+ "description": "COSE algorithm identifier (e.g. -8 Ed25519, -7 ES256, -257 RS256)."
617
+ }
618
+ }
619
+ }
620
+ },
621
+ "timeout": {
622
+ "type": "integer",
623
+ "minimum": 1
624
+ },
625
+ "excludeCredentials": {
626
+ "type": "array",
627
+ "items": {
628
+ "$ref": "#/$defs/CredentialDescriptor"
629
+ }
630
+ },
631
+ "authenticatorSelection": {
632
+ "type": "object",
633
+ "additionalProperties": false,
634
+ "properties": {
635
+ "authenticatorAttachment": {
636
+ "enum": [
637
+ "platform",
638
+ "cross-platform"
639
+ ]
640
+ },
641
+ "requireResidentKey": {
642
+ "type": "boolean"
643
+ },
644
+ "residentKey": {
645
+ "enum": [
646
+ "discouraged",
647
+ "preferred",
648
+ "required"
649
+ ]
650
+ },
651
+ "userVerification": {
652
+ "enum": [
653
+ "discouraged",
654
+ "preferred",
655
+ "required"
656
+ ]
657
+ }
658
+ }
659
+ },
660
+ "attestation": {
661
+ "enum": [
662
+ "none",
663
+ "indirect",
664
+ "direct",
665
+ "enterprise"
666
+ ]
667
+ }
668
+ }
669
+ }
670
+ }
671
+ } as const;
672
+
673
+ /**
674
+ * SPEC.md §7.2 policy for the request variant, from this specification's
675
+ * front matter. Pass to `consumeInbound` — items 5b, 7 and 8 are
676
+ * per-specification and cannot be derived from the document alone, and
677
+ * item 2 needs the schema this carries.
678
+ */
679
+ export const SPEC = {
680
+ typeUri: TYPE_URI,
681
+ isBearer: false,
682
+ isProofRequired: false,
683
+ isRecipientRequired: true,
684
+ isIssuedAtRequired: true,
685
+ payloadSchema: PAYLOAD_SCHEMA,
686
+ } as const;
687
+
688
+ /**
689
+ * SPEC.md §7.2 policy for the success-response variant. `isRecipientRequired`
690
+ * tracks the *issuer* party's requirement because a response swaps the
691
+ * parties (§7.3 item 5).
692
+ */
693
+ export const RESPONSE_SPEC = {
694
+ typeUri: RESPONSE_TYPE_URI,
695
+ isBearer: false,
696
+ isProofRequired: false,
697
+ isRecipientRequired: true,
698
+ isIssuedAtRequired: true,
699
+ payloadSchema: RESPONSE_PAYLOAD_SCHEMA,
700
+ } as const;