@bcts/frost-hubert 1.0.0-beta.0 → 1.0.0-beta.1

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 (149) hide show
  1. package/README.md +1 -1
  2. package/dist/bin/frost.cjs +17 -19
  3. package/dist/bin/frost.cjs.map +1 -1
  4. package/dist/bin/frost.mjs +16 -17
  5. package/dist/bin/frost.mjs.map +1 -1
  6. package/dist/{busy-EZU7EKr6.cjs → busy-B_h0bNAJ.cjs} +1 -1
  7. package/dist/{busy-DkM2jAIZ.mjs.map → busy-B_h0bNAJ.cjs.map} +1 -1
  8. package/dist/{busy-DkM2jAIZ.mjs → busy-BlU8_pS2.mjs} +1 -1
  9. package/dist/{busy-EZU7EKr6.cjs.map → busy-BlU8_pS2.mjs.map} +1 -1
  10. package/dist/cmd/index.cjs +6 -7
  11. package/dist/cmd/index.d.cts +1 -1
  12. package/dist/cmd/index.d.mts +1 -1
  13. package/dist/cmd/index.mjs +5 -6
  14. package/dist/{cmd-Bw9_i2_f.cjs → cmd-CCVhHzG7.cjs} +20 -21
  15. package/dist/{cmd-Bw9_i2_f.cjs.map → cmd-CCVhHzG7.cjs.map} +1 -1
  16. package/dist/{cmd-CS1uJtuD.mjs → cmd-DNsHd19v.mjs} +20 -21
  17. package/dist/{cmd-CS1uJtuD.mjs.map → cmd-DNsHd19v.mjs.map} +1 -1
  18. package/dist/{common-lThIvJmZ.cjs → common-7-BOgaTt.cjs} +2 -3
  19. package/dist/{common-lThIvJmZ.cjs.map → common-7-BOgaTt.cjs.map} +1 -1
  20. package/dist/{common-CvH6dFvQ.mjs → common-Cf1UvJaP.mjs} +3 -3
  21. package/dist/{common-CvH6dFvQ.mjs.map → common-Cf1UvJaP.mjs.map} +1 -1
  22. package/dist/{common-lKP5EzHy.cjs → common-CnvAUC2b.cjs} +3 -3
  23. package/dist/{common-lKP5EzHy.cjs.map → common-CnvAUC2b.cjs.map} +1 -1
  24. package/dist/{common-DUWvtc08.mjs → common-DNrD_-EI.mjs} +2 -2
  25. package/dist/{common-DUWvtc08.mjs.map → common-DNrD_-EI.mjs.map} +1 -1
  26. package/dist/dkg/index.cjs +1 -2
  27. package/dist/dkg/index.cjs.map +1 -1
  28. package/dist/dkg/index.d.cts +1 -1
  29. package/dist/dkg/index.d.mts +1 -1
  30. package/dist/dkg/index.mjs +1 -1
  31. package/dist/dkg/index.mjs.map +1 -1
  32. package/dist/{finalize-CNTDj6aS.mjs → finalize-BpC0rz93.mjs} +6 -6
  33. package/dist/{finalize-CNTDj6aS.mjs.map → finalize-BpC0rz93.mjs.map} +1 -1
  34. package/dist/{finalize-BRgJK-Xv.cjs → finalize-Cb0obTSo.cjs} +6 -6
  35. package/dist/{finalize-BRgJK-Xv.cjs.map → finalize-Cb0obTSo.cjs.map} +1 -1
  36. package/dist/{finalize-BfLgzn8f.cjs → finalize-DHEnKobp.cjs} +5 -5
  37. package/dist/{finalize-BfLgzn8f.cjs.map → finalize-DHEnKobp.cjs.map} +1 -1
  38. package/dist/{finalize-UPyI1yb1.cjs → finalize-DQ0VGUHO.cjs} +7 -7
  39. package/dist/{finalize-UPyI1yb1.cjs.map → finalize-DQ0VGUHO.cjs.map} +1 -1
  40. package/dist/{finalize-IA01t_Qq.mjs → finalize-DtRxHZ7H.mjs} +5 -5
  41. package/dist/{finalize-IA01t_Qq.mjs.map → finalize-DtRxHZ7H.mjs.map} +1 -1
  42. package/dist/{finalize-EC3ikHQq.mjs → finalize-T83Ko8nG.mjs} +6 -6
  43. package/dist/{finalize-EC3ikHQq.mjs.map → finalize-T83Ko8nG.mjs.map} +1 -1
  44. package/dist/frost/index.cjs +1 -1
  45. package/dist/frost/index.cjs.map +1 -1
  46. package/dist/frost/index.d.cts.map +1 -1
  47. package/dist/frost/index.d.mts.map +1 -1
  48. package/dist/frost/index.mjs +1 -1
  49. package/dist/frost/index.mjs.map +1 -1
  50. package/dist/{index-F1iNEAJR.d.cts → index-BErX9AZF.d.cts} +3 -3
  51. package/dist/index-BErX9AZF.d.cts.map +1 -0
  52. package/dist/{index-B3c-80VS.d.cts → index-BaUVw4b1.d.mts} +2 -2
  53. package/dist/index-BaUVw4b1.d.mts.map +1 -0
  54. package/dist/{index-C8QeHNwa.d.cts → index-CD50Qtgw.d.cts} +1 -1
  55. package/dist/index-CD50Qtgw.d.cts.map +1 -0
  56. package/dist/{index-DVbWyOs7.d.mts → index-CD50Qtgw.d.mts} +1 -1
  57. package/dist/index-CD50Qtgw.d.mts.map +1 -0
  58. package/dist/{index-BgbSGpxn.d.mts → index-Drklne-Y.d.mts} +3 -3
  59. package/dist/index-Drklne-Y.d.mts.map +1 -0
  60. package/dist/{index-D3QTWkEm.d.mts → index-gkmZzEuD.d.cts} +2 -2
  61. package/dist/index-gkmZzEuD.d.cts.map +1 -0
  62. package/dist/index.cjs +7 -8
  63. package/dist/index.cjs.map +1 -1
  64. package/dist/index.d.cts +3 -3
  65. package/dist/index.d.cts.map +1 -1
  66. package/dist/index.d.mts +3 -3
  67. package/dist/index.d.mts.map +1 -1
  68. package/dist/index.mjs +6 -7
  69. package/dist/index.mjs.map +1 -1
  70. package/dist/{invite-5277FQVT.cjs → invite-1tzg0B0P.cjs} +5 -5
  71. package/dist/{invite-5277FQVT.cjs.map → invite-1tzg0B0P.cjs.map} +1 -1
  72. package/dist/{invite-DUTcfTgX.cjs → invite-BLwtexAu.cjs} +4 -4
  73. package/dist/{invite-DUTcfTgX.cjs.map → invite-BLwtexAu.cjs.map} +1 -1
  74. package/dist/{invite-IU4n0dq2.mjs → invite-Be2v2SVc.mjs} +4 -4
  75. package/dist/{invite-IU4n0dq2.mjs.map → invite-Be2v2SVc.mjs.map} +1 -1
  76. package/dist/{invite-RU-OXTNS.mjs → invite-D8mQSnFz.mjs} +5 -5
  77. package/dist/{invite-RU-OXTNS.mjs.map → invite-D8mQSnFz.mjs.map} +1 -1
  78. package/dist/{parallel-D6zc6VW4.mjs → parallel-PZiwHZT8.mjs} +1 -1
  79. package/dist/{parallel-D1R6ZGlY.cjs.map → parallel-PZiwHZT8.mjs.map} +1 -1
  80. package/dist/{parallel-D1R6ZGlY.cjs → parallel-szwYx-bi.cjs} +1 -1
  81. package/dist/{parallel-D6zc6VW4.mjs.map → parallel-szwYx-bi.cjs.map} +1 -1
  82. package/dist/{proposed-participant-Dm1Eq6mX.cjs → proposed-participant-BvHNnpcZ.cjs} +1 -2
  83. package/dist/{proposed-participant-Dm1Eq6mX.cjs.map → proposed-participant-BvHNnpcZ.cjs.map} +1 -1
  84. package/dist/{proposed-participant-cWM7iUrO.mjs → proposed-participant-Detb823_.mjs} +1 -1
  85. package/dist/{proposed-participant-cWM7iUrO.mjs.map → proposed-participant-Detb823_.mjs.map} +1 -1
  86. package/dist/{receive-CAI-x4II.cjs → receive-BR-knnGv.cjs} +6 -6
  87. package/dist/{receive-CAI-x4II.cjs.map → receive-BR-knnGv.cjs.map} +1 -1
  88. package/dist/{receive-kZMsXhbK.cjs → receive-D_r4Mryr.cjs} +6 -6
  89. package/dist/{receive-kZMsXhbK.cjs.map → receive-D_r4Mryr.cjs.map} +1 -1
  90. package/dist/{receive-D2Nn68L7.mjs → receive-dkSCSGpl.mjs} +5 -5
  91. package/dist/{receive-D2Nn68L7.mjs.map → receive-dkSCSGpl.mjs.map} +1 -1
  92. package/dist/{receive-DA_KQEgk.mjs → receive-g8EhZF2Y.mjs} +6 -6
  93. package/dist/{receive-DA_KQEgk.mjs.map → receive-g8EhZF2Y.mjs.map} +1 -1
  94. package/dist/registry/index.cjs +1 -1
  95. package/dist/registry/index.cjs.map +1 -1
  96. package/dist/registry/index.d.cts +1 -1
  97. package/dist/registry/index.d.mts +1 -1
  98. package/dist/registry/index.mjs.map +1 -1
  99. package/dist/{registry-9puTaRrD.cjs → registry-CkIbA7nt.cjs} +79 -2
  100. package/dist/registry-CkIbA7nt.cjs.map +1 -0
  101. package/dist/{registry-BpCwtrRt.mjs → registry-DGjs4qDK.mjs} +74 -3
  102. package/dist/registry-DGjs4qDK.mjs.map +1 -0
  103. package/dist/{round1-BHBjru1m.cjs → round1-9FAqFvL5.cjs} +5 -5
  104. package/dist/{round1-BHBjru1m.cjs.map → round1-9FAqFvL5.cjs.map} +1 -1
  105. package/dist/{round1-CcQCGlIT.mjs → round1-B8haiMM8.mjs} +6 -6
  106. package/dist/{round1-CcQCGlIT.mjs.map → round1-B8haiMM8.mjs.map} +1 -1
  107. package/dist/{round1-Cgm7j1kI.mjs → round1-BOIE1E4O.mjs} +5 -5
  108. package/dist/{round1-Cgm7j1kI.mjs.map → round1-BOIE1E4O.mjs.map} +1 -1
  109. package/dist/{round1-4Hyx8w0x.cjs → round1-Bq0vweyQ.cjs} +5 -5
  110. package/dist/{round1-4Hyx8w0x.cjs.map → round1-Bq0vweyQ.cjs.map} +1 -1
  111. package/dist/{round1-CWSXZx5R.cjs → round1-CXkXoVQU.cjs} +9 -9
  112. package/dist/{round1-CWSXZx5R.cjs.map → round1-CXkXoVQU.cjs.map} +1 -1
  113. package/dist/{round1-7v9LlE11.mjs → round1-D8t7EzIo.mjs} +5 -5
  114. package/dist/{round1-7v9LlE11.mjs.map → round1-D8t7EzIo.mjs.map} +1 -1
  115. package/dist/{round1-DQ0fnc1H.cjs → round1-DriPu15x.cjs} +7 -7
  116. package/dist/{round1-DQ0fnc1H.cjs.map → round1-DriPu15x.cjs.map} +1 -1
  117. package/dist/{round1-CMLKN2RR.mjs → round1-Y2kcVwnR.mjs} +7 -7
  118. package/dist/{round1-CMLKN2RR.mjs.map → round1-Y2kcVwnR.mjs.map} +1 -1
  119. package/dist/{round2-BWz9SQIi.cjs → round2-AMDYMUIg.cjs} +5 -5
  120. package/dist/{round2-BWz9SQIi.cjs.map → round2-AMDYMUIg.cjs.map} +1 -1
  121. package/dist/{round2-o2Q-GMbX.cjs → round2-BHQKVJFo.cjs} +7 -7
  122. package/dist/{round2-o2Q-GMbX.cjs.map → round2-BHQKVJFo.cjs.map} +1 -1
  123. package/dist/{round2-Bl2uK93U.mjs → round2-BfetYacV.mjs} +5 -5
  124. package/dist/{round2-Bl2uK93U.mjs.map → round2-BfetYacV.mjs.map} +1 -1
  125. package/dist/{round2-Dg24w-TU.mjs → round2-Cf5CJc_8.mjs} +7 -7
  126. package/dist/{round2-Dg24w-TU.mjs.map → round2-Cf5CJc_8.mjs.map} +1 -1
  127. package/dist/{round2-LylCa84n.cjs → round2-CvrmylN1.cjs} +7 -7
  128. package/dist/{round2-LylCa84n.cjs.map → round2-CvrmylN1.cjs.map} +1 -1
  129. package/dist/{round2-CdUT-AhH.cjs → round2-Dk_w97nl.cjs} +5 -5
  130. package/dist/{round2-CdUT-AhH.cjs.map → round2-Dk_w97nl.cjs.map} +1 -1
  131. package/dist/{round2-BkNRCXgS.mjs → round2-Z2JhMwxc.mjs} +5 -5
  132. package/dist/{round2-BkNRCXgS.mjs.map → round2-Z2JhMwxc.mjs.map} +1 -1
  133. package/dist/{round2-DOA3rnV-.mjs → round2-mF6UlkT-.mjs} +6 -6
  134. package/dist/{round2-DOA3rnV-.mjs.map → round2-mF6UlkT-.mjs.map} +1 -1
  135. package/package.json +14 -14
  136. package/dist/index-B3c-80VS.d.cts.map +0 -1
  137. package/dist/index-BgbSGpxn.d.mts.map +0 -1
  138. package/dist/index-C8QeHNwa.d.cts.map +0 -1
  139. package/dist/index-D3QTWkEm.d.mts.map +0 -1
  140. package/dist/index-DVbWyOs7.d.mts.map +0 -1
  141. package/dist/index-F1iNEAJR.d.cts.map +0 -1
  142. package/dist/registry-9puTaRrD.cjs.map +0 -1
  143. package/dist/registry-BpCwtrRt.mjs.map +0 -1
  144. package/dist/storage-B-Gu68-O.cjs +0 -79
  145. package/dist/storage-B-Gu68-O.cjs.map +0 -1
  146. package/dist/storage-Bkkliz0K.mjs +0 -74
  147. package/dist/storage-Bkkliz0K.mjs.map +0 -1
  148. /package/dist/{chunk-CZWwpsFl.cjs → chunk-DakpK96I.cjs} +0 -0
  149. /package/dist/{chunk-CjcI7cDX.mjs → chunk-z9aeyW2b.mjs}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: string): string;
438
438
  //#endregion
439
439
  export { resolveRegistryPath as a, ContributionPaths as c, PendingRequests as d, Registry as i, GroupParticipant as l, GroupOutcome as n, ParticipantRecord as o, OwnerOutcome as r, OwnerRecord as s, AddOutcome as t, GroupRecord as u };
440
- //# sourceMappingURL=index-C8QeHNwa.d.cts.map
440
+ //# sourceMappingURL=index-CD50Qtgw.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-CD50Qtgw.d.cts","names":[],"sources":["../src/registry/group-record.ts","../src/registry/owner-record.ts","../src/registry/participant-record.ts","../src/registry/registry-impl.ts"],"mappings":";;;;;;;;;cAmBa,gBAAA;EAAA,iBACM,IAAA;cAEL,GAAA,EAAK,GAAA;EAIjB,GAAA,CAAA,GAAO,GAAA;EAIP,MAAA,CAAA;EAAA,OAIO,QAAA,CAAS,KAAA,WAAgB,gBAAA;AAAA;AAWlC;;;;;AAAA,cAAa,iBAAA;EACX,YAAA;EACA,aAAA;EACA,YAAA;EACA,UAAA;cAEY,IAAA,GAAO,OAAA,CAAQ,iBAAA;EAL3B;;;;;EAmBA,YAAA,CAAa,KAAA,EAAO,iBAAA;EAdO;;;;;EA0B3B,OAAA,CAAA;EASA,MAAA,CAAA,GAAU,MAAA;EAAA,OASH,QAAA,CAAS,IAAA,EAAM,MAAA,mBAAyB,iBAAA;AAAA;;;;;AAAiB;cAwBrD,eAAA;EAAA,iBACM,QAAA;;;;;;EAOjB,cAAA,CAAe,WAAA,EAAa,GAAA,EAAK,eAAA,EAAiB,IAAA;EA0BzB;;;;;EAbzB,iBAAA,CAAkB,WAAA,EAAa,GAAA,EAAK,UAAA,EAAY,IAAA,EAAM,eAAA,EAAiB,IAAA;EAuD1C;;;;;EA1C7B,WAAA,CAAY,WAAA,EAAa,GAAA,EAAK,UAAA,EAAY,IAAA;EAsER;;;;;EAzDlC,OAAA,CAAA;EAvCe;;;;;EAgDf,GAAA,CAAA;EAnCgD;;;;;EA4C/C,WAAA,CAAA,GAAe,SAAA,EAA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AAA,CAAS,KAAA,EAAO,WAAA,GAAc,YAAA;EH4GjB;;;EGnEb,YAAA,CAAA,GAAgB,GAAA,SAAY,iBAAA;EHiFf;;;EG1Eb,WAAA,CAAY,GAAA,EAAK,GAAA,GAAM,iBAAA;EHfN;;;;;;;;;;;;;;;;;;;;;;;;;EG4CjB,cAAA,CAAe,GAAA,EAAK,GAAA,EAAK,MAAA,EAAQ,iBAAA,GAAoB,UAAA;EH+B7B;;;EGOxB,aAAA,CAAc,OAAA;EHOU;;;;;EGOxB,oBAAA,CAAqB,OAAA,YAAmB,GAAA,EAAK,iBAAA;EHOX;;AAAe;EGKjD,MAAA,CAAA,GAAU,GAAA,SAAY,WAAA;EHeA;;;EGRtB,KAAA,CAAM,IAAA,EAAM,IAAA,GAAO,WAAA;EHkCJ;;;EG3Bf,QAAA,CAAS,IAAA,EAAM,IAAA,GAAO,WAAA;EHmDI;;;;;;;;;;EGrC1B,WAAA,CAAY,OAAA,EAAS,IAAA,EAAM,MAAA,EAAQ,WAAA,GAAc,YAAA;EHgHU;;;;;EG1E3D,QAAA,CAAS,IAAA,EAAM,IAAA,EAAM,MAAA,EAAQ,WAAA;EH9CrB;;;EAAA,OGqDD,IAAA,CAAK,QAAA,WAAmB,QAAA;;;;EAa/B,IAAA,CAAK,QAAA;EH1DH;;;;;;;;;;;;EGgFF,MAAA,CAAA,GAAU,MAAA;EH/CO;;;EAAA,OGwEV,QAAA,CAAS,IAAA,EAAM,MAAA,oBAA0B,QAAA;AAAA;;;;;;iBAkClC,mBAAA,CAAoB,WAAA,sBAAiC,GAAW"}
@@ -437,4 +437,4 @@ declare class Registry {
437
437
  declare function resolveRegistryPath(registryArg: string | undefined, cwd: string): string;
438
438
  //#endregion
439
439
  export { resolveRegistryPath as a, ContributionPaths as c, PendingRequests as d, Registry as i, GroupParticipant as l, GroupOutcome as n, ParticipantRecord as o, OwnerOutcome as r, OwnerRecord as s, AddOutcome as t, GroupRecord as u };
440
- //# sourceMappingURL=index-DVbWyOs7.d.mts.map
440
+ //# sourceMappingURL=index-CD50Qtgw.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-CD50Qtgw.d.mts","names":[],"sources":["../src/registry/group-record.ts","../src/registry/owner-record.ts","../src/registry/participant-record.ts","../src/registry/registry-impl.ts"],"mappings":";;;;;;;;;cAmBa,gBAAA;EAAA,iBACM,IAAA;cAEL,GAAA,EAAK,GAAA;EAIjB,GAAA,CAAA,GAAO,GAAA;EAIP,MAAA,CAAA;EAAA,OAIO,QAAA,CAAS,KAAA,WAAgB,gBAAA;AAAA;AAWlC;;;;;AAAA,cAAa,iBAAA;EACX,YAAA;EACA,aAAA;EACA,YAAA;EACA,UAAA;cAEY,IAAA,GAAO,OAAA,CAAQ,iBAAA;EAL3B;;;;;EAmBA,YAAA,CAAa,KAAA,EAAO,iBAAA;EAdO;;;;;EA0B3B,OAAA,CAAA;EASA,MAAA,CAAA,GAAU,MAAA;EAAA,OASH,QAAA,CAAS,IAAA,EAAM,MAAA,mBAAyB,iBAAA;AAAA;;;;;AAAiB;cAwBrD,eAAA;EAAA,iBACM,QAAA;;;;;;EAOjB,cAAA,CAAe,WAAA,EAAa,GAAA,EAAK,eAAA,EAAiB,IAAA;EA0BzB;;;;;EAbzB,iBAAA,CAAkB,WAAA,EAAa,GAAA,EAAK,UAAA,EAAY,IAAA,EAAM,eAAA,EAAiB,IAAA;EAuD1C;;;;;EA1C7B,WAAA,CAAY,WAAA,EAAa,GAAA,EAAK,UAAA,EAAY,IAAA;EAsER;;;;;EAzDlC,OAAA,CAAA;EAvCe;;;;;EAgDf,GAAA,CAAA;EAnCgD;;;;;EA4C/C,WAAA,CAAA,GAAe,SAAA,EAAW,GAAA,EAAK,IAAA;EA/BpB;;;;;EA0CX,QAAA,CAAA,GAAY,SAAA,EAAW,GAAA,EAAK,IAAA;EAXb;;;;;EAyBf,QAAA,CAAA,GAAY,SAAA,EAAW,GAAA,EAAK,IAAA,cAAkB,IAAA;EAM/C,MAAA,CAA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;;;;;;;EG4CjB,cAAA,CAAe,GAAA,EAAK,GAAA,EAAK,MAAA,EAAQ,iBAAA,GAAoB,UAAA;EH+B7B;;;EGOxB,aAAA,CAAc,OAAA;EHOU;;;;;EGOxB,oBAAA,CAAqB,OAAA,YAAmB,GAAA,EAAK,iBAAA;EHOX;;AAAe;EGKjD,MAAA,CAAA,GAAU,GAAA,SAAY,WAAA;EHeA;;;EGRtB,KAAA,CAAM,IAAA,EAAM,IAAA,GAAO,WAAA;EHkCJ;;;EG3Bf,QAAA,CAAS,IAAA,EAAM,IAAA,GAAO,WAAA;EHmDI;;;;;;;;;;EGrC1B,WAAA,CAAY,OAAA,EAAS,IAAA,EAAM,MAAA,EAAQ,WAAA,GAAc,YAAA;EHgHU;;;;;EG1E3D,QAAA,CAAS,IAAA,EAAM,IAAA,EAAM,MAAA,EAAQ,WAAA;EH9CrB;;;EAAA,OGqDD,IAAA,CAAK,QAAA,WAAmB,QAAA;;;;EAa/B,IAAA,CAAK,QAAA;EH1DH;;;;;;;;;;;;EGgFF,MAAA,CAAA,GAAU,MAAA;EH/CO;;;EAAA,OGwEV,QAAA,CAAS,IAAA,EAAM,MAAA,oBAA0B,QAAA;AAAA;;;;;;iBAkClC,mBAAA,CAAoB,WAAA,sBAAiC,GAAW"}
@@ -1,5 +1,5 @@
1
- import { d as PendingRequests, i as Registry, l as GroupParticipant, o as ParticipantRecord, r as OwnerOutcome, s as OwnerRecord, t as AddOutcome, u as GroupRecord } from "./index-DVbWyOs7.mjs";
2
- import { t as DkgInvitation } from "./index-D3QTWkEm.mjs";
1
+ import { d as PendingRequests, i as Registry, l as GroupParticipant, o as ParticipantRecord, r as OwnerOutcome, s as OwnerRecord, t as AddOutcome, u as GroupRecord } from "./index-CD50Qtgw.mjs";
2
+ import { t as DkgInvitation } from "./index-BaUVw4b1.mjs";
3
3
  import { ARID, PrivateKeys, XID } from "@bcts/components";
4
4
  import { Envelope, EnvelopeEncodableValue } from "@bcts/envelope";
5
5
  import { SealedRequest } from "@bcts/gstp";
@@ -1121,4 +1121,4 @@ declare namespace index_d_exports {
1121
1121
  declare function participantsFilePath(registry: string | undefined, cwd: string): string;
1122
1122
  //#endregion
1123
1123
  export { signingKeyFromVerifying as A, StorageClient as C, isVerbose as D, groupStateDir as E, setVerbose as O, putWithIndicator as S, createStorageClient as T, fetchStatusTimeout as _, CollectionResult as a, parallelSend as b, FetchStatus as c, directionEmoji as d, emptyCollectionResult as f, fetchStatusSuccess as g, fetchStatusRejected as h, checkAridExists as i, parseAridUr as k, ParallelFetchConfig as l, fetchStatusPending as m, index_d_exports$1 as n, DEFAULT_TIMEOUT_SECONDS as o, fetchStatusError as p, index_d_exports$4 as r, Direction as s, index_d_exports as t, buildFetchRequests as u, parallelFetch as v, StorageSelection as w, getWithIndicator as x, parallelFetchConfigWithTimeout as y };
1124
- //# sourceMappingURL=index-BgbSGpxn.d.mts.map
1124
+ //# sourceMappingURL=index-Drklne-Y.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-Drklne-Y.d.mts","names":[],"sources":["../src/cmd/dkg/common.ts","../src/cmd/common.ts","../src/cmd/storage.ts","../src/cmd/busy.ts","../src/cmd/parallel.ts","../src/cmd/check.ts","../src/cmd/dkg/coordinator/invite.ts","../src/cmd/dkg/coordinator/round1.ts","../src/cmd/dkg/coordinator/round2.ts","../src/cmd/dkg/coordinator/finalize.ts","../src/cmd/dkg/coordinator/index.ts","../src/cmd/dkg/participant/receive.ts","../src/cmd/dkg/participant/round1.ts","../src/cmd/dkg/participant/round2.ts","../src/cmd/dkg/participant/finalize.ts","../src/cmd/dkg/participant/index.ts","../src/cmd/dkg/index.ts","../src/cmd/sign/common.ts","../src/cmd/sign/coordinator/invite.ts","../src/cmd/sign/coordinator/round1.ts","../src/cmd/sign/coordinator/round2.ts","../src/cmd/sign/coordinator/index.ts","../src/cmd/sign/participant/receive.ts","../src/cmd/sign/participant/round1.ts","../src/cmd/sign/participant/round2.ts","../src/cmd/sign/participant/finalize.ts","../src/cmd/sign/participant/index.ts","../src/cmd/sign/index.ts","../src/cmd/registry/owner/set.ts","../src/cmd/registry/participant/add.ts","../src/cmd/registry/index.ts"],"mappings":";;;;;;;;;;AA+E2D;AAsB3D;;;;;;;;AAAwE;AA4BxE;;;iBApFgB,WAAA,CAAY,QAAA,WAAmB,IAAI;;;;;;iBAkCnC,eAAA,CAAgB,QAAA,WAAmB,QAAQ;AA8F3D;;;;;;;;;AAAA,iBAxEgB,uBAAA,CAAwB,QAAA,EAAU,QAAA,GAAW,WAAW;;;;;AA2E9C;AAwD1B;;;;;;;;;AAAyE;AA6BzE;;;iBApIgB,aAAA,CAAc,QAAA,EAAU,QAAA,EAAU,KAAA,WAAgB,WAAW;;;;;;iBA4C7D,mBAAA,CACd,QAAA,EAAU,QAAA,EACV,MAAA,cACE,GAAA,EAAK,iBAAA;;;;;;iBAwDO,iBAAA,CAAkB,QAAA,EAAU,QAAA,EAAU,MAAA,EAAQ,WAAW;;AAiCtD;AASnB;;;iBAbgB,sBAAA,CACd,QAAA,EAAU,QAAA,EACV,KAAA,EAAO,WAAA,EACP,YAAA,EAAc,WAAA,KACb,gBAAA;;;;;;iBASa,4BAAA,CACd,QAAA,EAAU,QAAA,EACV,KAAA,EAAO,WAAA,EACP,QAAA,EAAU,WAAA,GACT,gBAAA;;;;;;iBAyBa,yBAAA,CAA0B,IAAA,UAAc,OAAgB;;AAzBrD;AAyBnB;;;iBASgB,4BAAA,CACd,QAAA,EAAU,QAAA,EACV,YAAA,EAAc,WAAA,IACd,QAAA,EAAU,GAAA,EACV,YAAA;AAbsE;AASxE;;;;AATwE,iBA+CxD,WAAA,CAAY,YAAA,UAAsB,UAAkB;;;;;;iBAUpD,uBAAA,CAAwB,iBAA6B,EAAV,UAAU;;;AAvOrE;;;;;AAAA,iBC5FgB,aAAA,CAAc,YAAA,UAAsB,UAAkB;;;;iBAatD,UAAA,CAAW,KAAc;AD2HzC;;;;;AAAA,iBClHgB,SAAA,CAAA;;;ADdmC;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,OAAA;AAAA;;;;UAMe,kBAAA;EACf,SAAA;EACA,cAAc;AAAA;;;;;;;;iBA4pBM,QAAA,CACpB,MAAA,EAAQ,aAAA,EACR,OAAA,EAAS,mBAAA,EACT,GAAA,WACC,OAAA,CAAQ,kBAAA;AAAA;;;;;;;;;AzBrrBwC;AAkCnD;U4B7DiB,eAAA;;EAEf,WAAA;E5B2DyD;E4BzDzD,OAAA;E5B+EqC;E4B7ErC,YAAA;AAAA;;;;UAMe,cAAA;EACf,OAAA,EAAS,YAAY;AAAA;;;;;;;;iBA0BP,QAAA,CAAS,OAAA,EAAS,eAAA,EAAiB,GAAA,WAAc,cAAc;;;;A5BZ5B;AAkCnD;U6B7DiB,qBAAA;;EAEf,WAAA;E7B2DyD;E6BzDzD,OAAA;E7B+EqC;E6B7ErC,YAAA;AAAA;;;;UAMe,oBAAA;EACf,OAAA,EAAS,UAAU;AAAA;;;;;;;;iBA0BL,cAAA,CAAe,OAAA,EAAS,qBAAA,EAAuB,GAAA,WAAc,oBAAoB;AAAA;;;A7BZ9C;AAkCnD;;;;AAA2D;AAlCR,iB8BnBnC,oBAAA,CAAqB,QAAA,sBAA8B,GAAW"}
@@ -1,7 +1,7 @@
1
1
  import { ARID, XID } from "@bcts/components";
2
2
  import { Envelope } from "@bcts/envelope";
3
- import { SealedRequest, SealedResponse } from "@bcts/gstp";
4
3
  import { XIDDocument } from "@bcts/xid";
4
+ import { SealedRequest, SealedResponse } from "@bcts/gstp";
5
5
 
6
6
  //#region src/dkg/proposed-participant.d.ts
7
7
  /**
@@ -192,4 +192,4 @@ declare class DkgInvitation {
192
192
  }
193
193
  //#endregion
194
194
  export { declined as a, accepted as i, DkgInvitationResult as n, DkgProposedParticipant as o, DkgInvite as r, compareXidBytes as s, DkgInvitation as t };
195
- //# sourceMappingURL=index-D3QTWkEm.d.mts.map
195
+ //# sourceMappingURL=index-gkmZzEuD.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-gkmZzEuD.d.cts","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kCH,SAAA,CAAA,GAAa,IAAA;EAIb,MAAA,CAAA,GAAU,WAAA;EAIV,OAAA,CAAA,GAAW,IAAA;EAIX,IAAA,CAAA,GAAQ,IAAA;EAIR,UAAA,CAAA,GAAc,IAAA;EAId,UAAA,CAAA;EAIA,OAAA,CAAA;EAIA,YAAA,CAAA,GAAgB,sBAAA;EA3HF;;;;AAA+B;EAoI7C,SAAA,CAAA,GAAa,aAAA;EA7HS;;;AAAqC;AAS7D;EAsJE,kBAAA,CAAA,GAAsB,QAAA;;;;;;EAqBtB,UAAA,CAAA,GAAc,QAAA;AAAA;;;;;;cAoBH,aAAA;EAAA,iBACM,aAAA;EAAA,iBACA,WAAA;EAAA,iBACA,OAAA;EAAA,iBACA,UAAA;EAAA,iBACA,iBAAA;EAAA,iBACA,WAAA;EAAA,iBACA,QAAA;EAAA,iBACA,QAAA;EAAA,QAEV,WAAA,CAAA;EAoBP,YAAA,CAAA,GAAgB,IAAA;EAIhB,UAAA,CAAA,GAAc,IAAA;EAId,MAAA,CAAA,GAAU,WAAA;EAIV,SAAA,CAAA,GAAa,IAAA;EAIb,gBAAA,CAAA,GAAoB,QAAA;EAIpB,UAAA,CAAA;EAIA,OAAA,CAAA;EAIA,OAAA,CAAA,GAAW,IAAA;EArNT;;;;;EA8NF,UAAA,CAAW,QAAA,EAAU,mBAAA,EAAqB,SAAA,EAAW,WAAA,GAAc,cAAA;EA3NjE;;;;;EA2OF,UAAA,CAAW,QAAA,EAAU,mBAAA,EAAqB,SAAA,EAAW,WAAA,GAAc,QAAA;EAtOlD;;;;;EAAA,OAwPV,UAAA,CACL,MAAA,EAAQ,QAAA,EACR,GAAA,EAAK,IAAA,EACL,cAAA,EAAgB,WAAA,cAChB,SAAA,EAAW,WAAA,GACV,aAAA;AAAA"}
package/dist/index.cjs CHANGED
@@ -1,14 +1,13 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_proposed_participant = require("./proposed-participant-Dm1Eq6mX.cjs");
2
+ const require_proposed_participant = require("./proposed-participant-BvHNnpcZ.cjs");
3
3
  const require_dkg_index = require("./dkg/index.cjs");
4
4
  const require_registry_index = require("./registry/index.cjs");
5
- const require_common = require("./common-lKP5EzHy.cjs");
6
- const require_busy = require("./busy-EZU7EKr6.cjs");
7
- const require_parallel = require("./parallel-D1R6ZGlY.cjs");
8
- const require_storage = require("./storage-B-Gu68-O.cjs");
9
- const require_cmd = require("./cmd-Bw9_i2_f.cjs");
5
+ const require_common = require("./common-CnvAUC2b.cjs");
6
+ const require_busy = require("./busy-B_h0bNAJ.cjs");
7
+ const require_parallel = require("./parallel-szwYx-bi.cjs");
8
+ const require_registry = require("./registry-CkIbA7nt.cjs");
9
+ const require_cmd = require("./cmd-CCVhHzG7.cjs");
10
10
  const require_frost_index = require("./frost/index.cjs");
11
- const require_registry = require("./registry-9puTaRrD.cjs");
12
11
  //#region src/index.ts
13
12
  /**
14
13
  * Initialize the library by registering all required CBOR tags.
@@ -44,7 +43,7 @@ exports.accepted = require_dkg_index.accepted;
44
43
  exports.buildFetchRequests = require_parallel.buildFetchRequests;
45
44
  exports.checkAridExists = require_cmd.checkAridExists;
46
45
  exports.compareXidBytes = require_proposed_participant.compareXidBytes;
47
- exports.createStorageClient = require_storage.createStorageClient;
46
+ exports.createStorageClient = require_registry.createStorageClient;
48
47
  exports.declined = require_dkg_index.declined;
49
48
  exports.directionEmoji = require_parallel.directionEmoji;
50
49
  Object.defineProperty(exports, "dkg", {
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs","names":[],"sources":["../src/index.ts"],"sourcesContent":["/**\n * Copyright © 2023-2026 Blockchain Commons, LLC\n * Copyright © 2025-2026 Parity Technologies\n *\n *\n * FROST DKG and signing using Hubert as the distributed substrate.\n *\n * Port of lib.rs from frost-hubert-rust.\n *\n * @module\n */\n\n// Re-export DKG module\nexport * from \"./dkg/index.js\";\n\n// Re-export Registry module\nexport * from \"./registry/index.js\";\n\n// Re-export command module\nexport * from \"./cmd/index.js\";\n\n// Re-export FROST cryptographic operations\nexport * as frost from \"./frost/index.js\";\n\n// Type for modules that may have registerTags\ninterface TagModule {\n registerTags?: () => void;\n}\n\n/**\n * Initialize the library by registering all required CBOR tags.\n *\n * Port of `run()` tag registration from lib.rs lines 14-16.\n */\nexport async function registerTags(): Promise<void> {\n const components = (await import(\"@bcts/components\")) as TagModule;\n const envelope = (await import(\"@bcts/envelope\")) as TagModule;\n const provenanceMark = (await import(\"@bcts/provenance-mark\")) as TagModule;\n\n if (typeof components.registerTags === \"function\") {\n components.registerTags();\n }\n if (typeof envelope.registerTags === \"function\") {\n envelope.registerTags();\n }\n if (typeof provenanceMark.registerTags === \"function\") {\n provenanceMark.registerTags();\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAkCA,eAAsB,eAA8B;CAClD,MAAM,aAAc,MAAM,OAAO;CACjC,MAAM,WAAY,MAAM,OAAO;CAC/B,MAAM,iBAAkB,MAAM,OAAO;AAErC,KAAI,OAAO,WAAW,iBAAiB,WACrC,YAAW,cAAc;AAE3B,KAAI,OAAO,SAAS,iBAAiB,WACnC,UAAS,cAAc;AAEzB,KAAI,OAAO,eAAe,iBAAiB,WACzC,gBAAe,cAAc"}
1
+ {"version":3,"file":"index.cjs","names":[],"sources":["../src/index.ts"],"sourcesContent":["/**\n * Copyright © 2023-2026 Blockchain Commons, LLC\n * Copyright © 2025-2026 Parity Technologies\n *\n *\n * FROST DKG and signing using Hubert as the distributed substrate.\n *\n * Port of lib.rs from frost-hubert-rust.\n *\n * @module\n */\n\n// Re-export DKG module\nexport * from \"./dkg/index.js\";\n\n// Re-export Registry module\nexport * from \"./registry/index.js\";\n\n// Re-export command module\nexport * from \"./cmd/index.js\";\n\n// Re-export FROST cryptographic operations\nexport * as frost from \"./frost/index.js\";\n\n// Type for modules that may have registerTags\ninterface TagModule {\n registerTags?: () => void;\n}\n\n/**\n * Initialize the library by registering all required CBOR tags.\n *\n * Port of `run()` tag registration from lib.rs lines 14-16.\n */\nexport async function registerTags(): Promise<void> {\n const components = (await import(\"@bcts/components\")) as TagModule;\n const envelope = (await import(\"@bcts/envelope\")) as TagModule;\n const provenanceMark = (await import(\"@bcts/provenance-mark\")) as TagModule;\n\n if (typeof components.registerTags === \"function\") {\n components.registerTags();\n }\n if (typeof envelope.registerTags === \"function\") {\n envelope.registerTags();\n }\n if (typeof provenanceMark.registerTags === \"function\") {\n provenanceMark.registerTags();\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAkCA,eAAsB,eAA8B;CAClD,MAAM,aAAc,MAAM,OAAO;CACjC,MAAM,WAAY,MAAM,OAAO;CAC/B,MAAM,iBAAkB,MAAM,OAAO;CAErC,IAAI,OAAO,WAAW,iBAAiB,YACrC,WAAW,aAAa;CAE1B,IAAI,OAAO,SAAS,iBAAiB,YACnC,SAAS,aAAa;CAExB,IAAI,OAAO,eAAe,iBAAiB,YACzC,eAAe,aAAa;AAEhC"}
package/dist/index.d.cts CHANGED
@@ -1,6 +1,6 @@
1
- import { a as resolveRegistryPath, c as ContributionPaths, d as PendingRequests, i as Registry, l as GroupParticipant, n as GroupOutcome, o as ParticipantRecord, r as OwnerOutcome, s as OwnerRecord, t as AddOutcome, u as GroupRecord } from "./index-C8QeHNwa.cjs";
2
- import { A as signingKeyFromVerifying, C as StorageClient, D as isVerbose, E as groupStateDir, O as setVerbose, S as putWithIndicator, T as createStorageClient, _ as fetchStatusTimeout, a as CollectionResult, b as parallelSend, c as FetchStatus, d as directionEmoji, f as emptyCollectionResult, g as fetchStatusSuccess, h as fetchStatusRejected, i as checkAridExists, k as parseAridUr, l as ParallelFetchConfig, m as fetchStatusPending, n as index_d_exports$3, o as DEFAULT_TIMEOUT_SECONDS, p as fetchStatusError, r as index_d_exports, s as Direction, t as index_d_exports$2, u as buildFetchRequests, v as parallelFetch, w as StorageSelection, x as getWithIndicator, y as parallelFetchConfigWithTimeout } from "./index-F1iNEAJR.cjs";
3
- import { a as declined, i as accepted, n as DkgInvitationResult, o as DkgProposedParticipant, r as DkgInvite, s as compareXidBytes, t as DkgInvitation } from "./index-B3c-80VS.cjs";
1
+ import { a as resolveRegistryPath, c as ContributionPaths, d as PendingRequests, i as Registry, l as GroupParticipant, n as GroupOutcome, o as ParticipantRecord, r as OwnerOutcome, s as OwnerRecord, t as AddOutcome, u as GroupRecord } from "./index-CD50Qtgw.cjs";
2
+ import { A as signingKeyFromVerifying, C as StorageClient, D as isVerbose, E as groupStateDir, O as setVerbose, S as putWithIndicator, T as createStorageClient, _ as fetchStatusTimeout, a as CollectionResult, b as parallelSend, c as FetchStatus, d as directionEmoji, f as emptyCollectionResult, g as fetchStatusSuccess, h as fetchStatusRejected, i as checkAridExists, k as parseAridUr, l as ParallelFetchConfig, m as fetchStatusPending, n as index_d_exports$3, o as DEFAULT_TIMEOUT_SECONDS, p as fetchStatusError, r as index_d_exports, s as Direction, t as index_d_exports$2, u as buildFetchRequests, v as parallelFetch, w as StorageSelection, x as getWithIndicator, y as parallelFetchConfigWithTimeout } from "./index-BErX9AZF.cjs";
3
+ import { a as declined, i as accepted, n as DkgInvitationResult, o as DkgProposedParticipant, r as DkgInvite, s as compareXidBytes, t as DkgInvitation } from "./index-gkmZzEuD.cjs";
4
4
  import { t as index_d_exports$1 } from "./frost/index.cjs";
5
5
 
6
6
  //#region src/index.d.ts
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;iBAkCsB,YAAA,CAAA,GAAgB,OAAA"}
1
+ {"version":3,"file":"index.d.cts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;iBAkCsB,YAAA,CAAA,GAAgB,OAAO"}
package/dist/index.d.mts CHANGED
@@ -1,6 +1,6 @@
1
- import { a as resolveRegistryPath, c as ContributionPaths, d as PendingRequests, i as Registry, l as GroupParticipant, n as GroupOutcome, o as ParticipantRecord, r as OwnerOutcome, s as OwnerRecord, t as AddOutcome, u as GroupRecord } from "./index-DVbWyOs7.mjs";
2
- import { A as signingKeyFromVerifying, C as StorageClient, D as isVerbose, E as groupStateDir, O as setVerbose, S as putWithIndicator, T as createStorageClient, _ as fetchStatusTimeout, a as CollectionResult, b as parallelSend, c as FetchStatus, d as directionEmoji, f as emptyCollectionResult, g as fetchStatusSuccess, h as fetchStatusRejected, i as checkAridExists, k as parseAridUr, l as ParallelFetchConfig, m as fetchStatusPending, n as index_d_exports$3, o as DEFAULT_TIMEOUT_SECONDS, p as fetchStatusError, r as index_d_exports, s as Direction, t as index_d_exports$2, u as buildFetchRequests, v as parallelFetch, w as StorageSelection, x as getWithIndicator, y as parallelFetchConfigWithTimeout } from "./index-BgbSGpxn.mjs";
3
- import { a as declined, i as accepted, n as DkgInvitationResult, o as DkgProposedParticipant, r as DkgInvite, s as compareXidBytes, t as DkgInvitation } from "./index-D3QTWkEm.mjs";
1
+ import { a as resolveRegistryPath, c as ContributionPaths, d as PendingRequests, i as Registry, l as GroupParticipant, n as GroupOutcome, o as ParticipantRecord, r as OwnerOutcome, s as OwnerRecord, t as AddOutcome, u as GroupRecord } from "./index-CD50Qtgw.mjs";
2
+ import { A as signingKeyFromVerifying, C as StorageClient, D as isVerbose, E as groupStateDir, O as setVerbose, S as putWithIndicator, T as createStorageClient, _ as fetchStatusTimeout, a as CollectionResult, b as parallelSend, c as FetchStatus, d as directionEmoji, f as emptyCollectionResult, g as fetchStatusSuccess, h as fetchStatusRejected, i as checkAridExists, k as parseAridUr, l as ParallelFetchConfig, m as fetchStatusPending, n as index_d_exports$3, o as DEFAULT_TIMEOUT_SECONDS, p as fetchStatusError, r as index_d_exports, s as Direction, t as index_d_exports$2, u as buildFetchRequests, v as parallelFetch, w as StorageSelection, x as getWithIndicator, y as parallelFetchConfigWithTimeout } from "./index-Drklne-Y.mjs";
3
+ import { a as declined, i as accepted, n as DkgInvitationResult, o as DkgProposedParticipant, r as DkgInvite, s as compareXidBytes, t as DkgInvitation } from "./index-BaUVw4b1.mjs";
4
4
  import { t as index_d_exports$1 } from "./frost/index.mjs";
5
5
 
6
6
  //#region src/index.d.ts
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;iBAkCsB,YAAA,CAAA,GAAgB,OAAA"}
1
+ {"version":3,"file":"index.d.mts","names":[],"sources":["../src/index.ts"],"mappings":";;;;;;;;;;;iBAkCsB,YAAA,CAAA,GAAgB,OAAO"}
package/dist/index.mjs CHANGED
@@ -1,13 +1,12 @@
1
- import { n as compareXidBytes, t as DkgProposedParticipant } from "./proposed-participant-cWM7iUrO.mjs";
1
+ import { n as compareXidBytes, t as DkgProposedParticipant } from "./proposed-participant-Detb823_.mjs";
2
2
  import { DkgInvitation, DkgInvite, accepted, declined } from "./dkg/index.mjs";
3
3
  import { AddOutcome, ContributionPaths, GroupOutcome, GroupParticipant, GroupRecord, OwnerOutcome, OwnerRecord, ParticipantRecord, PendingRequests, Registry, resolveRegistryPath } from "./registry/index.mjs";
4
- import { c as parseAridUr, h as signingKeyFromVerifying, n as isVerbose, r as setVerbose, t as groupStateDir } from "./common-CvH6dFvQ.mjs";
5
- import { n as putWithIndicator, t as getWithIndicator } from "./busy-DkM2jAIZ.mjs";
6
- import { a as directionEmoji, c as fetchStatusPending, d as fetchStatusTimeout, f as parallelFetch, i as buildFetchRequests, l as fetchStatusRejected, m as parallelSend, n as DEFAULT_TIMEOUT_SECONDS, o as emptyCollectionResult, p as parallelFetchConfigWithTimeout, r as Direction, s as fetchStatusError, t as CollectionResult, u as fetchStatusSuccess } from "./parallel-D6zc6VW4.mjs";
7
- import { t as createStorageClient } from "./storage-Bkkliz0K.mjs";
8
- import { n as dkg_exports, r as checkAridExists, t as sign_exports } from "./cmd-CS1uJtuD.mjs";
4
+ import { c as parseAridUr, h as signingKeyFromVerifying, n as isVerbose, r as setVerbose, t as groupStateDir } from "./common-Cf1UvJaP.mjs";
5
+ import { n as putWithIndicator, t as getWithIndicator } from "./busy-BlU8_pS2.mjs";
6
+ import { a as directionEmoji, c as fetchStatusPending, d as fetchStatusTimeout, f as parallelFetch, i as buildFetchRequests, l as fetchStatusRejected, m as parallelSend, n as DEFAULT_TIMEOUT_SECONDS, o as emptyCollectionResult, p as parallelFetchConfigWithTimeout, r as Direction, s as fetchStatusError, t as CollectionResult, u as fetchStatusSuccess } from "./parallel-PZiwHZT8.mjs";
7
+ import { i as createStorageClient, t as registry_exports } from "./registry-DGjs4qDK.mjs";
8
+ import { n as dkg_exports, r as checkAridExists, t as sign_exports } from "./cmd-DNsHd19v.mjs";
9
9
  import { t as frost_exports } from "./frost/index.mjs";
10
- import { t as registry_exports } from "./registry-BpCwtrRt.mjs";
11
10
  //#region src/index.ts
12
11
  /**
13
12
  * Initialize the library by registering all required CBOR tags.
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","names":[],"sources":["../src/index.ts"],"sourcesContent":["/**\n * Copyright © 2023-2026 Blockchain Commons, LLC\n * Copyright © 2025-2026 Parity Technologies\n *\n *\n * FROST DKG and signing using Hubert as the distributed substrate.\n *\n * Port of lib.rs from frost-hubert-rust.\n *\n * @module\n */\n\n// Re-export DKG module\nexport * from \"./dkg/index.js\";\n\n// Re-export Registry module\nexport * from \"./registry/index.js\";\n\n// Re-export command module\nexport * from \"./cmd/index.js\";\n\n// Re-export FROST cryptographic operations\nexport * as frost from \"./frost/index.js\";\n\n// Type for modules that may have registerTags\ninterface TagModule {\n registerTags?: () => void;\n}\n\n/**\n * Initialize the library by registering all required CBOR tags.\n *\n * Port of `run()` tag registration from lib.rs lines 14-16.\n */\nexport async function registerTags(): Promise<void> {\n const components = (await import(\"@bcts/components\")) as TagModule;\n const envelope = (await import(\"@bcts/envelope\")) as TagModule;\n const provenanceMark = (await import(\"@bcts/provenance-mark\")) as TagModule;\n\n if (typeof components.registerTags === \"function\") {\n components.registerTags();\n }\n if (typeof envelope.registerTags === \"function\") {\n envelope.registerTags();\n }\n if (typeof provenanceMark.registerTags === \"function\") {\n provenanceMark.registerTags();\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAkCA,eAAsB,eAA8B;CAClD,MAAM,aAAc,MAAM,OAAO;CACjC,MAAM,WAAY,MAAM,OAAO;CAC/B,MAAM,iBAAkB,MAAM,OAAO;AAErC,KAAI,OAAO,WAAW,iBAAiB,WACrC,YAAW,cAAc;AAE3B,KAAI,OAAO,SAAS,iBAAiB,WACnC,UAAS,cAAc;AAEzB,KAAI,OAAO,eAAe,iBAAiB,WACzC,gBAAe,cAAc"}
1
+ {"version":3,"file":"index.mjs","names":[],"sources":["../src/index.ts"],"sourcesContent":["/**\n * Copyright © 2023-2026 Blockchain Commons, LLC\n * Copyright © 2025-2026 Parity Technologies\n *\n *\n * FROST DKG and signing using Hubert as the distributed substrate.\n *\n * Port of lib.rs from frost-hubert-rust.\n *\n * @module\n */\n\n// Re-export DKG module\nexport * from \"./dkg/index.js\";\n\n// Re-export Registry module\nexport * from \"./registry/index.js\";\n\n// Re-export command module\nexport * from \"./cmd/index.js\";\n\n// Re-export FROST cryptographic operations\nexport * as frost from \"./frost/index.js\";\n\n// Type for modules that may have registerTags\ninterface TagModule {\n registerTags?: () => void;\n}\n\n/**\n * Initialize the library by registering all required CBOR tags.\n *\n * Port of `run()` tag registration from lib.rs lines 14-16.\n */\nexport async function registerTags(): Promise<void> {\n const components = (await import(\"@bcts/components\")) as TagModule;\n const envelope = (await import(\"@bcts/envelope\")) as TagModule;\n const provenanceMark = (await import(\"@bcts/provenance-mark\")) as TagModule;\n\n if (typeof components.registerTags === \"function\") {\n components.registerTags();\n }\n if (typeof envelope.registerTags === \"function\") {\n envelope.registerTags();\n }\n if (typeof provenanceMark.registerTags === \"function\") {\n provenanceMark.registerTags();\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;AAkCA,eAAsB,eAA8B;CAClD,MAAM,aAAc,MAAM,OAAO;CACjC,MAAM,WAAY,MAAM,OAAO;CAC/B,MAAM,iBAAkB,MAAM,OAAO;CAErC,IAAI,OAAO,WAAW,iBAAiB,YACrC,WAAW,aAAa;CAE1B,IAAI,OAAO,SAAS,iBAAiB,YACnC,SAAS,aAAa;CAExB,IAAI,OAAO,eAAe,iBAAiB,YACzC,eAAe,aAAa;AAEhC"}
@@ -1,8 +1,8 @@
1
- const require_chunk = require("./chunk-CZWwpsFl.cjs");
1
+ const require_chunk = require("./chunk-DakpK96I.cjs");
2
2
  const require_registry_index = require("./registry/index.cjs");
3
- const require_common = require("./common-lKP5EzHy.cjs");
4
- const require_busy = require("./busy-EZU7EKr6.cjs");
5
- const require_common$1 = require("./common-lThIvJmZ.cjs");
3
+ const require_common = require("./common-CnvAUC2b.cjs");
4
+ const require_busy = require("./busy-B_h0bNAJ.cjs");
5
+ const require_common$1 = require("./common-7-BOgaTt.cjs");
6
6
  let _bcts_components = require("@bcts/components");
7
7
  let _bcts_dcbor = require("@bcts/dcbor");
8
8
  let _bcts_envelope = require("@bcts/envelope");
@@ -271,4 +271,4 @@ Object.defineProperty(exports, "validateCoordinator", {
271
271
  }
272
272
  });
273
273
 
274
- //# sourceMappingURL=invite-5277FQVT.cjs.map
274
+ //# sourceMappingURL=invite-1tzg0B0P.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"invite-5277FQVT.cjs","names":["ARID","SealedRequest","CborDate","Envelope","path","fs","resolveRegistryPath","Registry","parseAridUr","signingStateDir","putWithIndicator"],"sources":["../src/cmd/sign/coordinator/invite.ts"],"sourcesContent":["/**\n * Copyright © 2023-2026 Blockchain Commons, LLC\n * Copyright © 2025-2026 Parity Technologies\n *\n *\n * Sign coordinator invite command.\n *\n * Port of cmd/sign/coordinator/invite.rs from frost-hubert-rust.\n *\n * @module\n */\n\n/* eslint-disable @typescript-eslint/no-unsafe-assignment */\n/* eslint-disable @typescript-eslint/no-unsafe-call */\n/* eslint-disable @typescript-eslint/no-unsafe-member-access */\n/* eslint-disable @typescript-eslint/no-unsafe-argument */\n\nimport * as fs from \"node:fs\";\nimport * as path from \"node:path\";\n\nimport { ARID } from \"@bcts/components\";\nimport { CborDate } from \"@bcts/dcbor\";\nimport { Envelope } from \"@bcts/envelope\";\nimport { SealedRequest } from \"@bcts/gstp\";\nimport { type XIDDocument } from \"@bcts/xid\";\n\nimport {\n Registry,\n resolveRegistryPath,\n type GroupRecord,\n type GroupParticipant,\n type OwnerRecord,\n} from \"../../../registry/index.js\";\nimport { putWithIndicator } from \"../../busy.js\";\nimport { type StorageClient } from \"../../storage.js\";\nimport { parseAridUr } from \"../../dkg/common.js\";\nimport { signingStateDir } from \"../common.js\";\n\n// -----------------------------------------------------------------------------\n// Session ARID management\n// -----------------------------------------------------------------------------\n\n/**\n * Session ARIDs for tracking the signing session.\n *\n * Port of `struct SessionArids` from cmd/sign/coordinator/invite.rs lines 151-156.\n */\nexport interface SessionArids {\n sessionId: ARID;\n startArid: ARID;\n commitArids: Map<string, ARID>; // Map<XID.urString(), ARID>\n shareArids: Map<string, ARID>; // Map<XID.urString(), ARID>\n}\n\n/**\n * Create new session ARIDs for all participants.\n *\n * Port of `SessionArids::new()` from cmd/sign/coordinator/invite.rs lines 158-173.\n */\nexport function createSessionArids(participants: GroupParticipant[]): SessionArids {\n const commitArids = new Map<string, ARID>();\n const shareArids = new Map<string, ARID>();\n\n for (const participant of participants) {\n const xidKey = participant.xid().urString();\n commitArids.set(xidKey, ARID.new());\n shareArids.set(xidKey, ARID.new());\n }\n\n return {\n sessionId: ARID.new(),\n startArid: ARID.new(),\n commitArids,\n shareArids,\n };\n}\n\n// -----------------------------------------------------------------------------\n// Validation\n// -----------------------------------------------------------------------------\n\n/**\n * Validate that the owner is the coordinator of the group.\n *\n * Port of `validate_coordinator()` from cmd/sign/coordinator/invite.rs lines 179-192.\n */\nexport function validateCoordinator(groupRecord: GroupRecord, owner: OwnerRecord): void {\n if (groupRecord.coordinator().xid().urString() !== owner.xid().urString()) {\n throw new Error(\n `Only the coordinator can start signing. Coordinator: ${groupRecord.coordinator().xid().urString()}, Owner: ${owner.xid().urString()}`,\n );\n }\n}\n\n// -----------------------------------------------------------------------------\n// Participant document gathering\n// -----------------------------------------------------------------------------\n\n/**\n * Gather XIDDocuments for all participants from the registry.\n *\n * Port of `gather_recipient_documents()` from cmd/sign/coordinator/invite.rs lines 198-222.\n */\nexport function gatherRecipientDocuments(\n participants: GroupParticipant[],\n owner: OwnerRecord,\n registry: Registry,\n): XIDDocument[] {\n const recipientDocs: XIDDocument[] = [];\n\n for (const participant of participants) {\n const xid = participant.xid();\n if (xid.urString() === owner.xid().urString()) {\n recipientDocs.push(owner.xidDocument());\n } else {\n const record = registry.participant(xid);\n if (record === undefined) {\n throw new Error(`Participant ${xid.urString()} not found in registry`);\n }\n recipientDocs.push(record.xidDocument());\n }\n }\n\n return recipientDocs;\n}\n\n// -----------------------------------------------------------------------------\n// Request building\n// -----------------------------------------------------------------------------\n\n/**\n * Context for building the sign invite request.\n *\n * Port of `struct SignInviteContext` from cmd/sign/coordinator/invite.rs lines 228-237.\n */\nexport interface SignInviteContext {\n arids: SessionArids;\n groupId: ARID;\n targetEnvelope: Envelope;\n groupRecord: GroupRecord;\n owner: OwnerRecord;\n registry: Registry;\n participants: GroupParticipant[];\n validUntil: Date;\n}\n\n/**\n * Build the sign invite request.\n *\n * Port of `build_sign_invite_request()` from cmd/sign/coordinator/invite.rs lines 239-284.\n */\nexport function buildSignInviteRequest(ctx: SignInviteContext): SealedRequest {\n let request = SealedRequest.new(\"signInvite\", ctx.arids.sessionId, ctx.owner.xidDocument())\n .withParameter(\"group\", ctx.groupId)\n .withParameter(\"session\", ctx.arids.sessionId)\n .withParameter(\"target\", ctx.targetEnvelope)\n .withParameter(\"minSigners\", ctx.groupRecord.minSigners())\n .withDate(new Date())\n .withParameter(\"validUntil\", CborDate.fromDatetime(ctx.validUntil));\n\n for (const participant of ctx.participants) {\n const xid = participant.xid();\n const xidKey = xid.urString();\n\n // Get participant document\n let participantDoc: XIDDocument;\n if (xidKey === ctx.owner.xid().urString()) {\n participantDoc = ctx.owner.xidDocument();\n } else {\n const record = ctx.registry.participant(xid);\n if (record === undefined) {\n throw new Error(\"Participant not found in registry\");\n }\n participantDoc = record.xidDocument();\n }\n\n // Get encryption key\n const encryptionKey = participantDoc.encryptionKey();\n if (encryptionKey === undefined) {\n throw new Error(\"Participant XID document has no encryption key\");\n }\n\n // Get commit ARID for this participant\n const responseArid = ctx.arids.commitArids.get(xidKey);\n if (responseArid === undefined) {\n throw new Error(\"commit ARID not found for participant\");\n }\n\n // Encrypt response ARID to participant\n // @ts-expect-error TS2339 - API mismatch: toEnvelope/encryptToRecipient methods\n const encryptedResponseArid = responseArid.toEnvelope().encryptToRecipient(encryptionKey);\n\n // Build participant entry envelope\n const participantEntry = Envelope.new(xid).addAssertion(\"response_arid\", encryptedResponseArid);\n\n request = request.withParameter(\"participant\", participantEntry);\n }\n\n return request;\n}\n\n// -----------------------------------------------------------------------------\n// State persistence\n// -----------------------------------------------------------------------------\n\n/**\n * Build the session state JSON for persistence.\n *\n * Port of `build_session_state_json()` from cmd/sign/coordinator/invite.rs lines 290-346.\n */\nexport function buildSessionStateJson(\n arids: SessionArids,\n groupId: ARID,\n groupRecord: GroupRecord,\n participants: GroupParticipant[],\n targetEnvelope: Envelope,\n): Record<string, unknown> {\n const participantsMap: Record<string, unknown> = {};\n\n for (const participant of participants) {\n const xid = participant.xid();\n const xidKey = xid.urString();\n\n const commitArid = arids.commitArids.get(xidKey);\n const shareArid = arids.shareArids.get(xidKey);\n\n if (commitArid === undefined || shareArid === undefined) {\n throw new Error(\"ARID not found for participant\");\n }\n\n participantsMap[xidKey] = {\n commit_arid: commitArid.urString(),\n share_arid: shareArid.urString(),\n };\n }\n\n return {\n session_id: arids.sessionId.urString(),\n start_arid: arids.startArid.urString(),\n group: groupId.urString(),\n min_signers: groupRecord.minSigners(),\n participants: participantsMap,\n target: targetEnvelope.urString(),\n };\n}\n\n/**\n * Persist the session state to disk.\n *\n * Port of `persist_session_state()` from cmd/sign/coordinator/invite.rs lines 348-356.\n */\nexport function persistSessionState(signingDir: string, stateJson: Record<string, unknown>): void {\n fs.mkdirSync(signingDir, { recursive: true });\n const startStatePath = path.join(signingDir, \"start.json\");\n fs.writeFileSync(startStatePath, JSON.stringify(stateJson, null, 2));\n}\n\n// -----------------------------------------------------------------------------\n// File loading\n// -----------------------------------------------------------------------------\n\n/**\n * Load an envelope from a file path.\n *\n * Port of `load_envelope_from_path()` from cmd/sign/coordinator/invite.rs lines 385-392.\n */\nexport function loadEnvelopeFromPath(filePath: string): Envelope {\n if (!fs.existsSync(filePath)) {\n throw new Error(`Failed to read target envelope from ${filePath}`);\n }\n\n const data = fs.readFileSync(filePath, \"utf-8\");\n const trimmed = data.trim();\n\n try {\n return Envelope.fromURString(trimmed);\n } catch (e) {\n throw new Error(`Failed to load target envelope from ${filePath}: ${String(e)}`, { cause: e });\n }\n}\n\n// -----------------------------------------------------------------------------\n// Options and Result types\n// -----------------------------------------------------------------------------\n\n/**\n * Options for the sign invite command.\n */\nexport interface SignInviteOptions {\n registryPath?: string;\n groupId: string;\n targetFile: string;\n validDays?: number;\n verbose?: boolean;\n preview?: boolean;\n}\n\n/**\n * Result of the sign invite command.\n */\nexport interface SignInviteResult {\n sessionId: string;\n startArid: string;\n}\n\n// -----------------------------------------------------------------------------\n// Main invite function\n// -----------------------------------------------------------------------------\n\n/**\n * Execute the sign coordinator invite command.\n *\n * Invites participants to sign a target envelope.\n *\n * Port of `CommandArgs::exec()` from cmd/sign/coordinator/invite.rs lines 44-144.\n */\nexport async function invite(\n client: StorageClient | undefined,\n options: SignInviteOptions,\n cwd: string,\n): Promise<SignInviteResult> {\n // Validate preview mode\n if (client !== undefined && options.preview === true) {\n throw new Error(\"--preview cannot be used with Hubert storage options\");\n }\n\n const registryPath = resolveRegistryPath(options.registryPath, cwd);\n const registry = Registry.load(registryPath);\n\n const owner = registry.owner();\n if (owner === undefined) {\n throw new Error(\"Registry owner is required\");\n }\n\n const groupId = parseAridUr(options.groupId);\n const groupRecord = registry.group(groupId);\n\n if (groupRecord === undefined) {\n throw new Error(`Group ${options.groupId} not found in registry`);\n }\n\n // Validate sender is coordinator\n validateCoordinator(groupRecord, owner);\n\n // Load target envelope\n const targetPath = path.resolve(cwd, options.targetFile);\n const targetEnvelope = loadEnvelopeFromPath(targetPath);\n\n // Get participants\n const participants = groupRecord.participants();\n\n // Gather recipient documents\n const recipientDocs = gatherRecipientDocuments(participants, owner, registry);\n\n // Get signer keys\n const signerKeys = owner.xidDocument().inceptionPrivateKeys();\n if (signerKeys === undefined) {\n throw new Error(\"Coordinator XID document has no signing keys\");\n }\n\n // Generate session ARIDs\n const sessionArids = createSessionArids(participants);\n\n // Calculate valid until date (default 1 hour)\n const validDays = options.validDays ?? 1 / 24; // 1 hour default\n const validUntil = new Date(Date.now() + validDays * 24 * 60 * 60 * 1000);\n\n // Build request context\n const ctx: SignInviteContext = {\n arids: sessionArids,\n groupId,\n targetEnvelope,\n groupRecord,\n owner,\n registry,\n participants,\n validUntil,\n };\n\n // Build request\n const request = buildSignInviteRequest(ctx);\n\n // Build state for persistence\n const stateJson = buildSessionStateJson(\n sessionArids,\n groupId,\n groupRecord,\n participants,\n targetEnvelope,\n );\n\n // Build envelope for recipients\n const recipientRefs = recipientDocs;\n const sealedEnvelope = request.toEnvelopeForRecipients(validUntil, signerKeys, recipientRefs);\n\n // Handle preview mode\n if (options.preview === true) {\n const unsealed = request.toEnvelope(undefined, signerKeys, undefined);\n console.log(unsealed.urString());\n return {\n sessionId: sessionArids.sessionId.urString(),\n startArid: sessionArids.startArid.urString(),\n };\n }\n\n // Persist state\n const signingDir = signingStateDir(registryPath, groupId.hex(), sessionArids.sessionId.hex());\n persistSessionState(signingDir, stateJson);\n\n // Post to Hubert storage\n if (client === undefined) {\n throw new Error(\"Hubert storage is required for sign start\");\n }\n\n await putWithIndicator(\n client,\n sessionArids.startArid,\n sealedEnvelope,\n \"Signing invite\",\n options.verbose ?? false,\n );\n\n if (options.verbose === true) {\n console.log(`Session ID: ${sessionArids.sessionId.urString()}`);\n console.log(`Start ARID: ${sessionArids.startArid.urString()}`);\n }\n\n // Output the start ARID\n console.log(sessionArids.startArid.urString());\n\n return {\n sessionId: sessionArids.sessionId.urString(),\n startArid: sessionArids.startArid.urString(),\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2DA,SAAgB,mBAAmB,cAAgD;CACjF,MAAM,8BAAc,IAAI,KAAmB;CAC3C,MAAM,6BAAa,IAAI,KAAmB;AAE1C,MAAK,MAAM,eAAe,cAAc;EACtC,MAAM,SAAS,YAAY,KAAK,CAAC,UAAU;AAC3C,cAAY,IAAI,QAAQA,iBAAAA,KAAK,KAAK,CAAC;AACnC,aAAW,IAAI,QAAQA,iBAAAA,KAAK,KAAK,CAAC;;AAGpC,QAAO;EACL,WAAWA,iBAAAA,KAAK,KAAK;EACrB,WAAWA,iBAAAA,KAAK,KAAK;EACrB;EACA;EACD;;;;;;;AAYH,SAAgB,oBAAoB,aAA0B,OAA0B;AACtF,KAAI,YAAY,aAAa,CAAC,KAAK,CAAC,UAAU,KAAK,MAAM,KAAK,CAAC,UAAU,CACvE,OAAM,IAAI,MACR,wDAAwD,YAAY,aAAa,CAAC,KAAK,CAAC,UAAU,CAAC,WAAW,MAAM,KAAK,CAAC,UAAU,GACrI;;;;;;;AAaL,SAAgB,yBACd,cACA,OACA,UACe;CACf,MAAM,gBAA+B,EAAE;AAEvC,MAAK,MAAM,eAAe,cAAc;EACtC,MAAM,MAAM,YAAY,KAAK;AAC7B,MAAI,IAAI,UAAU,KAAK,MAAM,KAAK,CAAC,UAAU,CAC3C,eAAc,KAAK,MAAM,aAAa,CAAC;OAClC;GACL,MAAM,SAAS,SAAS,YAAY,IAAI;AACxC,OAAI,WAAW,KAAA,EACb,OAAM,IAAI,MAAM,eAAe,IAAI,UAAU,CAAC,wBAAwB;AAExE,iBAAc,KAAK,OAAO,aAAa,CAAC;;;AAI5C,QAAO;;;;;;;AA4BT,SAAgB,uBAAuB,KAAuC;CAC5E,IAAI,UAAUC,WAAAA,cAAc,IAA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AAU,UAAU,GAAG;AAC/D,UAAQ,IAAI,eAAe,aAAa,UAAU,UAAU,GAAG;;AAIjE,SAAQ,IAAI,aAAa,UAAU,UAAU,CAAC;AAE9C,QAAO;EACL,WAAW,aAAa,UAAU,UAAU;EAC5C,WAAW,aAAa,UAAU,UAAU;EAC7C"}
1
+ {"version":3,"file":"invite-1tzg0B0P.cjs","names":["ARID","SealedRequest","CborDate","Envelope","path","fs","resolveRegistryPath","Registry","parseAridUr","signingStateDir","putWithIndicator"],"sources":["../src/cmd/sign/coordinator/invite.ts"],"sourcesContent":["/**\n * Copyright © 2023-2026 Blockchain Commons, LLC\n * Copyright © 2025-2026 Parity Technologies\n *\n *\n * Sign coordinator invite command.\n *\n * Port of cmd/sign/coordinator/invite.rs from frost-hubert-rust.\n *\n * @module\n */\n\n/* eslint-disable @typescript-eslint/no-unsafe-assignment */\n/* eslint-disable @typescript-eslint/no-unsafe-call */\n/* eslint-disable @typescript-eslint/no-unsafe-member-access */\n/* eslint-disable @typescript-eslint/no-unsafe-argument */\n\nimport * as fs from \"node:fs\";\nimport * as path from \"node:path\";\n\nimport { ARID } from \"@bcts/components\";\nimport { CborDate } from \"@bcts/dcbor\";\nimport { Envelope } from \"@bcts/envelope\";\nimport { SealedRequest } from \"@bcts/gstp\";\nimport { type XIDDocument } from \"@bcts/xid\";\n\nimport {\n Registry,\n resolveRegistryPath,\n type GroupRecord,\n type GroupParticipant,\n type OwnerRecord,\n} from \"../../../registry/index.js\";\nimport { putWithIndicator } from \"../../busy.js\";\nimport { type StorageClient } from \"../../storage.js\";\nimport { parseAridUr } from \"../../dkg/common.js\";\nimport { signingStateDir } from \"../common.js\";\n\n// -----------------------------------------------------------------------------\n// Session ARID management\n// -----------------------------------------------------------------------------\n\n/**\n * Session ARIDs for tracking the signing session.\n *\n * Port of `struct SessionArids` from cmd/sign/coordinator/invite.rs lines 151-156.\n */\nexport interface SessionArids {\n sessionId: ARID;\n startArid: ARID;\n commitArids: Map<string, ARID>; // Map<XID.urString(), ARID>\n shareArids: Map<string, ARID>; // Map<XID.urString(), ARID>\n}\n\n/**\n * Create new session ARIDs for all participants.\n *\n * Port of `SessionArids::new()` from cmd/sign/coordinator/invite.rs lines 158-173.\n */\nexport function createSessionArids(participants: GroupParticipant[]): SessionArids {\n const commitArids = new Map<string, ARID>();\n const shareArids = new Map<string, ARID>();\n\n for (const participant of participants) {\n const xidKey = participant.xid().urString();\n commitArids.set(xidKey, ARID.new());\n shareArids.set(xidKey, ARID.new());\n }\n\n return {\n sessionId: ARID.new(),\n startArid: ARID.new(),\n commitArids,\n shareArids,\n };\n}\n\n// -----------------------------------------------------------------------------\n// Validation\n// -----------------------------------------------------------------------------\n\n/**\n * Validate that the owner is the coordinator of the group.\n *\n * Port of `validate_coordinator()` from cmd/sign/coordinator/invite.rs lines 179-192.\n */\nexport function validateCoordinator(groupRecord: GroupRecord, owner: OwnerRecord): void {\n if (groupRecord.coordinator().xid().urString() !== owner.xid().urString()) {\n throw new Error(\n `Only the coordinator can start signing. Coordinator: ${groupRecord.coordinator().xid().urString()}, Owner: ${owner.xid().urString()}`,\n );\n }\n}\n\n// -----------------------------------------------------------------------------\n// Participant document gathering\n// -----------------------------------------------------------------------------\n\n/**\n * Gather XIDDocuments for all participants from the registry.\n *\n * Port of `gather_recipient_documents()` from cmd/sign/coordinator/invite.rs lines 198-222.\n */\nexport function gatherRecipientDocuments(\n participants: GroupParticipant[],\n owner: OwnerRecord,\n registry: Registry,\n): XIDDocument[] {\n const recipientDocs: XIDDocument[] = [];\n\n for (const participant of participants) {\n const xid = participant.xid();\n if (xid.urString() === owner.xid().urString()) {\n recipientDocs.push(owner.xidDocument());\n } else {\n const record = registry.participant(xid);\n if (record === undefined) {\n throw new Error(`Participant ${xid.urString()} not found in registry`);\n }\n recipientDocs.push(record.xidDocument());\n }\n }\n\n return recipientDocs;\n}\n\n// -----------------------------------------------------------------------------\n// Request building\n// -----------------------------------------------------------------------------\n\n/**\n * Context for building the sign invite request.\n *\n * Port of `struct SignInviteContext` from cmd/sign/coordinator/invite.rs lines 228-237.\n */\nexport interface SignInviteContext {\n arids: SessionArids;\n groupId: ARID;\n targetEnvelope: Envelope;\n groupRecord: GroupRecord;\n owner: OwnerRecord;\n registry: Registry;\n participants: GroupParticipant[];\n validUntil: Date;\n}\n\n/**\n * Build the sign invite request.\n *\n * Port of `build_sign_invite_request()` from cmd/sign/coordinator/invite.rs lines 239-284.\n */\nexport function buildSignInviteRequest(ctx: SignInviteContext): SealedRequest {\n let request = SealedRequest.new(\"signInvite\", ctx.arids.sessionId, ctx.owner.xidDocument())\n .withParameter(\"group\", ctx.groupId)\n .withParameter(\"session\", ctx.arids.sessionId)\n .withParameter(\"target\", ctx.targetEnvelope)\n .withParameter(\"minSigners\", ctx.groupRecord.minSigners())\n .withDate(new Date())\n .withParameter(\"validUntil\", CborDate.fromDatetime(ctx.validUntil));\n\n for (const participant of ctx.participants) {\n const xid = participant.xid();\n const xidKey = xid.urString();\n\n // Get participant document\n let participantDoc: XIDDocument;\n if (xidKey === ctx.owner.xid().urString()) {\n participantDoc = ctx.owner.xidDocument();\n } else {\n const record = ctx.registry.participant(xid);\n if (record === undefined) {\n throw new Error(\"Participant not found in registry\");\n }\n participantDoc = record.xidDocument();\n }\n\n // Get encryption key\n const encryptionKey = participantDoc.encryptionKey();\n if (encryptionKey === undefined) {\n throw new Error(\"Participant XID document has no encryption key\");\n }\n\n // Get commit ARID for this participant\n const responseArid = ctx.arids.commitArids.get(xidKey);\n if (responseArid === undefined) {\n throw new Error(\"commit ARID not found for participant\");\n }\n\n // Encrypt response ARID to participant\n // @ts-expect-error TS2339 - API mismatch: toEnvelope/encryptToRecipient methods\n const encryptedResponseArid = responseArid.toEnvelope().encryptToRecipient(encryptionKey);\n\n // Build participant entry envelope\n const participantEntry = Envelope.new(xid).addAssertion(\"response_arid\", encryptedResponseArid);\n\n request = request.withParameter(\"participant\", participantEntry);\n }\n\n return request;\n}\n\n// -----------------------------------------------------------------------------\n// State persistence\n// -----------------------------------------------------------------------------\n\n/**\n * Build the session state JSON for persistence.\n *\n * Port of `build_session_state_json()` from cmd/sign/coordinator/invite.rs lines 290-346.\n */\nexport function buildSessionStateJson(\n arids: SessionArids,\n groupId: ARID,\n groupRecord: GroupRecord,\n participants: GroupParticipant[],\n targetEnvelope: Envelope,\n): Record<string, unknown> {\n const participantsMap: Record<string, unknown> = {};\n\n for (const participant of participants) {\n const xid = participant.xid();\n const xidKey = xid.urString();\n\n const commitArid = arids.commitArids.get(xidKey);\n const shareArid = arids.shareArids.get(xidKey);\n\n if (commitArid === undefined || shareArid === undefined) {\n throw new Error(\"ARID not found for participant\");\n }\n\n participantsMap[xidKey] = {\n commit_arid: commitArid.urString(),\n share_arid: shareArid.urString(),\n };\n }\n\n return {\n session_id: arids.sessionId.urString(),\n start_arid: arids.startArid.urString(),\n group: groupId.urString(),\n min_signers: groupRecord.minSigners(),\n participants: participantsMap,\n target: targetEnvelope.urString(),\n };\n}\n\n/**\n * Persist the session state to disk.\n *\n * Port of `persist_session_state()` from cmd/sign/coordinator/invite.rs lines 348-356.\n */\nexport function persistSessionState(signingDir: string, stateJson: Record<string, unknown>): void {\n fs.mkdirSync(signingDir, { recursive: true });\n const startStatePath = path.join(signingDir, \"start.json\");\n fs.writeFileSync(startStatePath, JSON.stringify(stateJson, null, 2));\n}\n\n// -----------------------------------------------------------------------------\n// File loading\n// -----------------------------------------------------------------------------\n\n/**\n * Load an envelope from a file path.\n *\n * Port of `load_envelope_from_path()` from cmd/sign/coordinator/invite.rs lines 385-392.\n */\nexport function loadEnvelopeFromPath(filePath: string): Envelope {\n if (!fs.existsSync(filePath)) {\n throw new Error(`Failed to read target envelope from ${filePath}`);\n }\n\n const data = fs.readFileSync(filePath, \"utf-8\");\n const trimmed = data.trim();\n\n try {\n return Envelope.fromURString(trimmed);\n } catch (e) {\n throw new Error(`Failed to load target envelope from ${filePath}: ${String(e)}`, { cause: e });\n }\n}\n\n// -----------------------------------------------------------------------------\n// Options and Result types\n// -----------------------------------------------------------------------------\n\n/**\n * Options for the sign invite command.\n */\nexport interface SignInviteOptions {\n registryPath?: string;\n groupId: string;\n targetFile: string;\n validDays?: number;\n verbose?: boolean;\n preview?: boolean;\n}\n\n/**\n * Result of the sign invite command.\n */\nexport interface SignInviteResult {\n sessionId: string;\n startArid: string;\n}\n\n// -----------------------------------------------------------------------------\n// Main invite function\n// -----------------------------------------------------------------------------\n\n/**\n * Execute the sign coordinator invite command.\n *\n * Invites participants to sign a target envelope.\n *\n * Port of `CommandArgs::exec()` from cmd/sign/coordinator/invite.rs lines 44-144.\n */\nexport async function invite(\n client: StorageClient | undefined,\n options: SignInviteOptions,\n cwd: string,\n): Promise<SignInviteResult> {\n // Validate preview mode\n if (client !== undefined && options.preview === true) {\n throw new Error(\"--preview cannot be used with Hubert storage options\");\n }\n\n const registryPath = resolveRegistryPath(options.registryPath, cwd);\n const registry = Registry.load(registryPath);\n\n const owner = registry.owner();\n if (owner === undefined) {\n throw new Error(\"Registry owner is required\");\n }\n\n const groupId = parseAridUr(options.groupId);\n const groupRecord = registry.group(groupId);\n\n if (groupRecord === undefined) {\n throw new Error(`Group ${options.groupId} not found in registry`);\n }\n\n // Validate sender is coordinator\n validateCoordinator(groupRecord, owner);\n\n // Load target envelope\n const targetPath = path.resolve(cwd, options.targetFile);\n const targetEnvelope = loadEnvelopeFromPath(targetPath);\n\n // Get participants\n const participants = groupRecord.participants();\n\n // Gather recipient documents\n const recipientDocs = gatherRecipientDocuments(participants, owner, registry);\n\n // Get signer keys\n const signerKeys = owner.xidDocument().inceptionPrivateKeys();\n if (signerKeys === undefined) {\n throw new Error(\"Coordinator XID document has no signing keys\");\n }\n\n // Generate session ARIDs\n const sessionArids = createSessionArids(participants);\n\n // Calculate valid until date (default 1 hour)\n const validDays = options.validDays ?? 1 / 24; // 1 hour default\n const validUntil = new Date(Date.now() + validDays * 24 * 60 * 60 * 1000);\n\n // Build request context\n const ctx: SignInviteContext = {\n arids: sessionArids,\n groupId,\n targetEnvelope,\n groupRecord,\n owner,\n registry,\n participants,\n validUntil,\n };\n\n // Build request\n const request = buildSignInviteRequest(ctx);\n\n // Build state for persistence\n const stateJson = buildSessionStateJson(\n sessionArids,\n groupId,\n groupRecord,\n participants,\n targetEnvelope,\n );\n\n // Build envelope for recipients\n const recipientRefs = recipientDocs;\n const sealedEnvelope = request.toEnvelopeForRecipients(validUntil, signerKeys, recipientRefs);\n\n // Handle preview mode\n if (options.preview === true) {\n const unsealed = request.toEnvelope(undefined, signerKeys, undefined);\n console.log(unsealed.urString());\n return {\n sessionId: sessionArids.sessionId.urString(),\n startArid: sessionArids.startArid.urString(),\n };\n }\n\n // Persist state\n const signingDir = signingStateDir(registryPath, groupId.hex(), sessionArids.sessionId.hex());\n persistSessionState(signingDir, stateJson);\n\n // Post to Hubert storage\n if (client === undefined) {\n throw new Error(\"Hubert storage is required for sign start\");\n }\n\n await putWithIndicator(\n client,\n sessionArids.startArid,\n sealedEnvelope,\n \"Signing invite\",\n options.verbose ?? false,\n );\n\n if (options.verbose === true) {\n console.log(`Session ID: ${sessionArids.sessionId.urString()}`);\n console.log(`Start ARID: ${sessionArids.startArid.urString()}`);\n }\n\n // Output the start ARID\n console.log(sessionArids.startArid.urString());\n\n return {\n sessionId: sessionArids.sessionId.urString(),\n startArid: sessionArids.startArid.urString(),\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA2DA,SAAgB,mBAAmB,cAAgD;CACjF,MAAM,8BAAc,IAAI,IAAkB;CAC1C,MAAM,6BAAa,IAAI,IAAkB;CAEzC,KAAK,MAAM,eAAe,cAAc;EACtC,MAAM,SAAS,YAAY,IAAI,EAAE,SAAS;EAC1C,YAAY,IAAI,QAAQA,iBAAAA,KAAK,IAAI,CAAC;EAClC,WAAW,IAAI,QAAQA,iBAAAA,KAAK,IAAI,CAAC;CACnC;CAEA,OAAO;EACL,WAAWA,iBAAAA,KAAK,IAAI;EACpB,WAAWA,iBAA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M,aAAa,IAAI,KAAK,KAAK,IAAI,IAAI,YAAY,KAAK,KAAK,KAAK,GAAI;CAexE,MAAM,UAAU,uBAAuB;EAXrC,OAAO;EACP;EACA;EACA;EACA;EACA;EACA;EACA;CAIuC,CAAC;CAG1C,MAAM,YAAY,sBAChB,cACA,SACA,aACA,cACA,cACF;CAGA,MAAM,gBAAgB;CACtB,MAAM,iBAAiB,QAAQ,wBAAwB,YAAY,YAAY,aAAa;CAG5F,IAAI,QAAQ,YAAY,MAAM;EAC5B,MAAM,WAAW,QAAQ,WAAW,KAAA,GAAW,YAAY,KAAA,CAAS;EACpE,QAAQ,IAAI,SAAS,SAAS,CAAC;EAC/B,OAAO;GACL,WAAW,aAAa,UAAU,SAAS;GAC3C,WAAW,aAAa,UAAU,SAAS;EAC7C;CACF;CAIA,oBADmBK,iBAAAA,gBAAgB,cAAc,QAAQ,IAAI,GAAG,aAAa,UAAU,IAAI,CAC9D,GAAG,SAAS;CAGzC,IAAI,WAAW,KAAA,GACb,MAAM,IAAI,MAAM,2CAA2C;CAG7D,MAAMC,aAAAA,iBACJ,QACA,aAAa,WACb,gBACA,kBACA,QAAQ,WAAW,KACrB;CAEA,IAAI,QAAQ,YAAY,MAAM;EAC5B,QAAQ,IAAI,eAAe,aAAa,UAAU,SAAS,GAAG;EAC9D,QAAQ,IAAI,eAAe,aAAa,UAAU,SAAS,GAAG;CAChE;CAGA,QAAQ,IAAI,aAAa,UAAU,SAAS,CAAC;CAE7C,OAAO;EACL,WAAW,aAAa,UAAU,SAAS;EAC3C,WAAW,aAAa,UAAU,SAAS;CAC7C;AACF"}
@@ -1,8 +1,8 @@
1
- const require_chunk = require("./chunk-CZWwpsFl.cjs");
1
+ const require_chunk = require("./chunk-DakpK96I.cjs");
2
2
  const require_dkg_index = require("./dkg/index.cjs");
3
3
  const require_registry_index = require("./registry/index.cjs");
4
- const require_common = require("./common-lKP5EzHy.cjs");
5
- const require_busy = require("./busy-EZU7EKr6.cjs");
4
+ const require_common = require("./common-CnvAUC2b.cjs");
5
+ const require_busy = require("./busy-B_h0bNAJ.cjs");
6
6
  let _bcts_components = require("@bcts/components");
7
7
  let node_fs = require("node:fs");
8
8
  node_fs = require_chunk.__toESM(node_fs, 1);
@@ -106,4 +106,4 @@ Object.defineProperty(exports, "invite_exports", {
106
106
  }
107
107
  });
108
108
 
109
- //# sourceMappingURL=invite-DUTcfTgX.cjs.map
109
+ //# sourceMappingURL=invite-BLwtexAu.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"invite-DUTcfTgX.cjs","names":["resolveParticipants","ARID","PendingRequests","resolveOwnerXidDocument","DkgInvite","resolveRegistryPath","Registry","putWithIndicator","GroupParticipant","GroupRecord","dkgStateDir","path"],"sources":["../src/cmd/dkg/coordinator/invite.ts"],"sourcesContent":["/**\n * Copyright © 2023-2026 Blockchain Commons, LLC\n * Copyright © 2025-2026 Parity Technologies\n *\n *\n * DKG coordinator invite command.\n *\n * Port of cmd/dkg/coordinator/invite.rs from frost-hubert-rust.\n *\n * @module\n */\n\nimport * as fs from \"node:fs\";\nimport * as path from \"node:path\";\n\nimport { ARID, type XID } from \"@bcts/components\";\n\nimport { DkgInvite } from \"../../../dkg/index.js\";\nimport {\n GroupParticipant,\n GroupRecord,\n PendingRequests,\n Registry,\n resolveRegistryPath,\n} from \"../../../registry/index.js\";\nimport { putWithIndicator } from \"../../busy.js\";\nimport { type StorageClient } from \"../../storage.js\";\nimport { dkgStateDir, resolveOwnerXidDocument, resolveParticipants } from \"../common.js\";\n\n/**\n * Options for the DKG invite command.\n */\nexport interface DkgInviteOptions {\n registryPath?: string;\n minSigners?: number;\n charter: string;\n validDays: number;\n participantNames: string[];\n verbose?: boolean;\n}\n\n/**\n * Result of the DKG invite command.\n */\nexport interface DkgInviteResult {\n groupId: ARID;\n requestId: ARID;\n envelopeUr: string;\n}\n\n/**\n * Internal data structure for building an invite.\n *\n * Port of `InviteData` struct from cmd/dkg/coordinator/invite.rs lines 122-126.\n */\ninterface InviteData {\n invite: DkgInvite;\n participantXids: XID[];\n pendingRequests: PendingRequests;\n}\n\n/**\n * Build the DKG invite with validation.\n *\n * Port of `build_invite()` from cmd/dkg/coordinator/invite.rs lines 128-181.\n */\nfunction buildInvite(\n registry: Registry,\n minSignersArg: number | undefined,\n charter: string,\n participantNames: string[],\n validDays: number,\n): InviteData {\n // Resolve participants using the common utility\n const resolved = resolveParticipants(registry, participantNames);\n const participantDocs: string[] = resolved.map(([, record]) => record.xidDocumentUr());\n const participantXids: XID[] = resolved.map(([xid]) => xid);\n\n // These are the ARIDs where participants will post their invite responses\n const collectFromArids: ARID[] = participantDocs.map(() => ARID.new());\n\n // Build pending_requests: coordinator will collect invite responses from these ARIDs\n const pendingRequests = new PendingRequests();\n for (let i = 0; i < participantXids.length; i++) {\n pendingRequests.addCollectOnly(participantXids[i], collectFromArids[i]);\n }\n\n // Validate participant count\n const participantCount = participantDocs.length;\n if (participantCount < 2) {\n throw new Error(\"At least two participants are required for a DKG invite\");\n }\n\n // Validate and default minSigners\n const minSigners = minSignersArg ?? participantCount;\n if (minSigners < 2) {\n throw new Error(\"--min-signers must be at least 2\");\n }\n if (minSigners > participantCount) {\n throw new Error(\"--min-signers cannot exceed participant count\");\n }\n\n // Get sender (registry owner)\n // The coordinator's invite always identifies the registry owner as\n // the sender. (Rust reads `registry.owner()` directly here too —\n // see `cmd/dkg/coordinator/invite.rs:74-77`.)\n const sender = resolveOwnerXidDocument(registry);\n\n // Calculate dates\n const now = new Date();\n const validUntil = new Date(Date.now() + validDays * 24 * 60 * 60 * 1000);\n\n // Create the invite\n const invite = DkgInvite.create(\n ARID.new(), // requestId\n sender,\n ARID.new(), // groupId\n now,\n validUntil,\n minSigners,\n charter,\n participantDocs,\n collectFromArids,\n );\n\n return { invite, participantXids, pendingRequests };\n}\n\n/**\n * Execute the DKG invite command.\n *\n * Port of `invite()` from cmd/dkg/coordinator/invite.rs.\n */\nexport async function invite(\n client: StorageClient,\n options: DkgInviteOptions,\n cwd: string,\n): Promise<DkgInviteResult> {\n const registryPath = resolveRegistryPath(options.registryPath, cwd);\n const registry = Registry.load(registryPath);\n\n // Build the invite with validation\n const inviteData = buildInvite(\n registry,\n options.minSigners,\n options.charter,\n options.participantNames,\n options.validDays,\n );\n\n const { invite: dkgInvite, participantXids, pendingRequests } = inviteData;\n const groupId = dkgInvite.groupId();\n const requestId = dkgInvite.requestId();\n\n // Create sealed envelope\n const envelope = dkgInvite.toEnvelope();\n\n // Send to storage\n const startArid = ARID.new();\n await putWithIndicator(\n client,\n startArid,\n envelope,\n \"Sending DKG invite\",\n options.verbose ?? false,\n );\n\n // Save group record to registry\n const owner = registry.owner();\n if (!owner) {\n throw new Error(\"Registry owner is required to issue invites\");\n }\n\n const coordinator = new GroupParticipant(owner.xid());\n const groupParticipants = participantXids.map((xid) => new GroupParticipant(xid));\n\n const groupRecord = new GroupRecord(\n options.charter,\n dkgInvite.minSigners(),\n coordinator,\n groupParticipants,\n );\n\n // Track pending requests\n groupRecord.setPendingRequests(pendingRequests);\n\n // Use recordGroup() for proper merge behavior\n registry.recordGroup(groupId, groupRecord);\n registry.save(registryPath);\n\n // Save invite state\n const stateDir = dkgStateDir(registryPath, groupId.hex());\n fs.mkdirSync(stateDir, { recursive: true });\n\n const inviteState: {\n group: string;\n request_id: string;\n start_arid: string;\n valid_until: string;\n participants: { xid: string; response_arid: string }[];\n } = {\n group: groupId.urString(),\n request_id: requestId.urString(),\n start_arid: startArid.urString(),\n valid_until: dkgInvite.validUntil().toISOString(),\n participants: dkgInvite.participants().map((p) => ({\n xid: p.xid().urString(),\n response_arid: p.responseArid().urString(),\n })),\n };\n\n fs.writeFileSync(path.join(stateDir, \"invite.json\"), JSON.stringify(inviteState, null, 2));\n\n if (options.verbose === true) {\n console.log(`Group ID: ${groupId.urString()}`);\n console.log(`Start ARID: ${startArid.urString()}`);\n }\n\n return {\n groupId,\n requestId,\n envelopeUr: envelope.urString(),\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;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veParticipants","ARID","PendingRequests","resolveOwnerXidDocument","DkgInvite","resolveRegistryPath","Registry","putWithIndicator","GroupParticipant","GroupRecord","dkgStateDir","path"],"sources":["../src/cmd/dkg/coordinator/invite.ts"],"sourcesContent":["/**\n * Copyright © 2023-2026 Blockchain Commons, LLC\n * Copyright © 2025-2026 Parity Technologies\n *\n *\n * DKG coordinator invite command.\n *\n * Port of cmd/dkg/coordinator/invite.rs from frost-hubert-rust.\n *\n * @module\n */\n\nimport * as fs from \"node:fs\";\nimport * as path from \"node:path\";\n\nimport { ARID, type XID } from \"@bcts/components\";\n\nimport { DkgInvite } from \"../../../dkg/index.js\";\nimport {\n GroupParticipant,\n GroupRecord,\n PendingRequests,\n Registry,\n resolveRegistryPath,\n} from \"../../../registry/index.js\";\nimport { putWithIndicator } from \"../../busy.js\";\nimport { type StorageClient } from \"../../storage.js\";\nimport { dkgStateDir, resolveOwnerXidDocument, resolveParticipants } from \"../common.js\";\n\n/**\n * Options for the DKG invite command.\n */\nexport interface DkgInviteOptions {\n registryPath?: string;\n minSigners?: number;\n charter: string;\n validDays: number;\n participantNames: string[];\n verbose?: boolean;\n}\n\n/**\n * Result of the DKG invite command.\n */\nexport interface DkgInviteResult {\n groupId: ARID;\n requestId: ARID;\n envelopeUr: string;\n}\n\n/**\n * Internal data structure for building an invite.\n *\n * Port of `InviteData` struct from cmd/dkg/coordinator/invite.rs lines 122-126.\n */\ninterface InviteData {\n invite: DkgInvite;\n participantXids: XID[];\n pendingRequests: PendingRequests;\n}\n\n/**\n * Build the DKG invite with validation.\n *\n * Port of `build_invite()` from cmd/dkg/coordinator/invite.rs lines 128-181.\n */\nfunction buildInvite(\n registry: Registry,\n minSignersArg: number | undefined,\n charter: string,\n participantNames: string[],\n validDays: number,\n): InviteData {\n // Resolve participants using the common utility\n const resolved = resolveParticipants(registry, participantNames);\n const participantDocs: string[] = resolved.map(([, record]) => record.xidDocumentUr());\n const participantXids: XID[] = resolved.map(([xid]) => xid);\n\n // These are the ARIDs where participants will post their invite responses\n const collectFromArids: ARID[] = participantDocs.map(() => ARID.new());\n\n // Build pending_requests: coordinator will collect invite responses from these ARIDs\n const pendingRequests = new PendingRequests();\n for (let i = 0; i < participantXids.length; i++) {\n pendingRequests.addCollectOnly(participantXids[i], collectFromArids[i]);\n }\n\n // Validate participant count\n const participantCount = participantDocs.length;\n if (participantCount < 2) {\n throw new Error(\"At least two participants are required for a DKG invite\");\n }\n\n // Validate and default minSigners\n const minSigners = minSignersArg ?? participantCount;\n if (minSigners < 2) {\n throw new Error(\"--min-signers must be at least 2\");\n }\n if (minSigners > participantCount) {\n throw new Error(\"--min-signers cannot exceed participant count\");\n }\n\n // Get sender (registry owner)\n // The coordinator's invite always identifies the registry owner as\n // the sender. (Rust reads `registry.owner()` directly here too —\n // see `cmd/dkg/coordinator/invite.rs:74-77`.)\n const sender = resolveOwnerXidDocument(registry);\n\n // Calculate dates\n const now = new Date();\n const validUntil = new Date(Date.now() + validDays * 24 * 60 * 60 * 1000);\n\n // Create the invite\n const invite = DkgInvite.create(\n ARID.new(), // requestId\n sender,\n ARID.new(), // groupId\n now,\n validUntil,\n minSigners,\n charter,\n participantDocs,\n collectFromArids,\n );\n\n return { invite, participantXids, pendingRequests };\n}\n\n/**\n * Execute the DKG invite command.\n *\n * Port of `invite()` from cmd/dkg/coordinator/invite.rs.\n */\nexport async function invite(\n client: StorageClient,\n options: DkgInviteOptions,\n cwd: string,\n): Promise<DkgInviteResult> {\n const registryPath = resolveRegistryPath(options.registryPath, cwd);\n const registry = Registry.load(registryPath);\n\n // Build the invite with validation\n const inviteData = buildInvite(\n registry,\n options.minSigners,\n options.charter,\n options.participantNames,\n options.validDays,\n );\n\n const { invite: dkgInvite, participantXids, pendingRequests } = inviteData;\n const groupId = dkgInvite.groupId();\n const requestId = dkgInvite.requestId();\n\n // Create sealed envelope\n const envelope = dkgInvite.toEnvelope();\n\n // Send to storage\n const startArid = ARID.new();\n await putWithIndicator(\n client,\n startArid,\n envelope,\n \"Sending DKG invite\",\n options.verbose ?? false,\n );\n\n // Save group record to registry\n const owner = registry.owner();\n if (!owner) {\n throw new Error(\"Registry owner is required to issue invites\");\n }\n\n const coordinator = new GroupParticipant(owner.xid());\n const groupParticipants = participantXids.map((xid) => new GroupParticipant(xid));\n\n const groupRecord = new GroupRecord(\n options.charter,\n dkgInvite.minSigners(),\n coordinator,\n groupParticipants,\n );\n\n // Track pending requests\n groupRecord.setPendingRequests(pendingRequests);\n\n // Use recordGroup() for proper merge behavior\n registry.recordGroup(groupId, groupRecord);\n registry.save(registryPath);\n\n // Save invite state\n const stateDir = dkgStateDir(registryPath, groupId.hex());\n fs.mkdirSync(stateDir, { recursive: true });\n\n const inviteState: {\n group: string;\n request_id: string;\n start_arid: string;\n valid_until: string;\n participants: { xid: string; response_arid: string }[];\n } = {\n group: groupId.urString(),\n request_id: requestId.urString(),\n start_arid: startArid.urString(),\n valid_until: dkgInvite.validUntil().toISOString(),\n participants: dkgInvite.participants().map((p) => ({\n xid: p.xid().urString(),\n response_arid: p.responseArid().urString(),\n })),\n };\n\n fs.writeFileSync(path.join(stateDir, \"invite.json\"), JSON.stringify(inviteState, null, 2));\n\n if (options.verbose === true) {\n console.log(`Group ID: ${groupId.urString()}`);\n console.log(`Start ARID: ${startArid.urString()}`);\n }\n\n return {\n groupId,\n requestId,\n envelopeUr: envelope.urString(),\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAkEA,SAAS,YACP,UACA,eACA,SACA,kBACA,WACY;CAEZ,MAAM,WAAWA,eAAAA,oBAAoB,UAAU,gBAAgB;CAC/D,MAAM,kBAA4B,SAAS,KAAK,GAAG,YAAY,OAAO,cAAc,CAAC;CACrF,MAAM,kBAAyB,SAAS,KAAK,CAAC,SAAS,GAAG;CAG1D,MAAM,mBAA2B,gBAAgB,UAAUC,iBAAAA,KAAK,IAAI,CAAC;CAGrE,MAAM,kBAAkB,IAAIC,uBAAAA,gBAAgB;CAC5C,KAAK,IAAI,IA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AAgB,KAAK,QAAQ,IAAIA,uBAAAA,iBAAiB,GAAG,CAAC;CAEhF,MAAM,cAAc,IAAIC,uBAAAA,YACtB,QAAQ,SACR,UAAU,WAAW,GACrB,aACA,iBACF;CAGA,YAAY,mBAAmB,eAAe;CAG9C,SAAS,YAAY,SAAS,WAAW;CACzC,SAAS,KAAK,YAAY;CAG1B,MAAM,WAAWC,eAAAA,YAAY,cAAc,QAAQ,IAAI,CAAC;CACxD,QAAG,UAAU,UAAU,EAAE,WAAW,KAAK,CAAC;CAE1C,MAAM,cAMF;EACF,OAAO,QAAQ,SAAS;EACxB,YAAY,UAAU,SAAS;EAC/B,YAAY,UAAU,SAAS;EAC/B,aAAa,UAAU,WAAW,EAAE,YAAY;EAChD,cAAc,UAAU,aAAa,EAAE,KAAK,OAAO;GACjD,KAAK,EAAE,IAAI,EAAE,SAAS;GACtB,eAAe,EAAE,aAAa,EAAE,SAAS;EAC3C,EAAE;CACJ;CAEA,QAAG,cAAcC,UAAK,KAAK,UAAU,aAAa,GAAG,KAAK,UAAU,aAAa,MAAM,CAAC,CAAC;CAEzF,IAAI,QAAQ,YAAY,MAAM;EAC5B,QAAQ,IAAI,aAAa,QAAQ,SAAS,GAAG;EAC7C,QAAQ,IAAI,eAAe,UAAU,SAAS,GAAG;CACnD;CAEA,OAAO;EACL;EACA;EACA,YAAY,SAAS,SAAS;CAChC;AACF"}
@@ -1,8 +1,8 @@
1
- import { t as __exportAll } from "./chunk-CjcI7cDX.mjs";
1
+ import { t as __exportAll } from "./chunk-z9aeyW2b.mjs";
2
2
  import { DkgInvite } from "./dkg/index.mjs";
3
3
  import { GroupParticipant, GroupRecord, PendingRequests, Registry, resolveRegistryPath } from "./registry/index.mjs";
4
- import { a as dkgStateDir, d as resolveOwnerXidDocument, f as resolveParticipants } from "./common-CvH6dFvQ.mjs";
5
- import { n as putWithIndicator } from "./busy-DkM2jAIZ.mjs";
4
+ import { a as dkgStateDir, d as resolveOwnerXidDocument, f as resolveParticipants } from "./common-Cf1UvJaP.mjs";
5
+ import { n as putWithIndicator } from "./busy-BlU8_pS2.mjs";
6
6
  import { ARID } from "@bcts/components";
7
7
  import * as fs from "node:fs";
8
8
  import * as path from "node:path";
@@ -93,4 +93,4 @@ async function invite(client, options, cwd) {
93
93
  //#endregion
94
94
  export { invite_exports as n, invite as t };
95
95
 
96
- //# sourceMappingURL=invite-IU4n0dq2.mjs.map
96
+ //# sourceMappingURL=invite-Be2v2SVc.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"invite-IU4n0dq2.mjs","names":[],"sources":["../src/cmd/dkg/coordinator/invite.ts"],"sourcesContent":["/**\n * Copyright © 2023-2026 Blockchain Commons, LLC\n * Copyright © 2025-2026 Parity Technologies\n *\n *\n * DKG coordinator invite command.\n *\n * Port of cmd/dkg/coordinator/invite.rs from frost-hubert-rust.\n *\n * @module\n */\n\nimport * as fs from \"node:fs\";\nimport * as path from \"node:path\";\n\nimport { ARID, type XID } from \"@bcts/components\";\n\nimport { DkgInvite } from \"../../../dkg/index.js\";\nimport {\n GroupParticipant,\n GroupRecord,\n PendingRequests,\n Registry,\n resolveRegistryPath,\n} from \"../../../registry/index.js\";\nimport { putWithIndicator } from \"../../busy.js\";\nimport { type StorageClient } from \"../../storage.js\";\nimport { dkgStateDir, resolveOwnerXidDocument, resolveParticipants } from \"../common.js\";\n\n/**\n * Options for the DKG invite command.\n */\nexport interface DkgInviteOptions {\n registryPath?: string;\n minSigners?: number;\n charter: string;\n validDays: number;\n participantNames: string[];\n verbose?: boolean;\n}\n\n/**\n * Result of the DKG invite command.\n */\nexport interface DkgInviteResult {\n groupId: ARID;\n requestId: ARID;\n envelopeUr: string;\n}\n\n/**\n * Internal data structure for building an invite.\n *\n * Port of `InviteData` struct from cmd/dkg/coordinator/invite.rs lines 122-126.\n */\ninterface InviteData {\n invite: DkgInvite;\n participantXids: XID[];\n pendingRequests: PendingRequests;\n}\n\n/**\n * Build the DKG invite with validation.\n *\n * Port of `build_invite()` from cmd/dkg/coordinator/invite.rs lines 128-181.\n */\nfunction buildInvite(\n registry: Registry,\n minSignersArg: number | undefined,\n charter: string,\n participantNames: string[],\n validDays: number,\n): InviteData {\n // Resolve participants using the common utility\n const resolved = resolveParticipants(registry, participantNames);\n const participantDocs: string[] = resolved.map(([, record]) => record.xidDocumentUr());\n const participantXids: XID[] = resolved.map(([xid]) => xid);\n\n // These are the ARIDs where participants will post their invite responses\n const collectFromArids: ARID[] = participantDocs.map(() => ARID.new());\n\n // Build pending_requests: coordinator will collect invite responses from these ARIDs\n const pendingRequests = new PendingRequests();\n for (let i = 0; i < participantXids.length; i++) {\n pendingRequests.addCollectOnly(participantXids[i], collectFromArids[i]);\n }\n\n // Validate participant count\n const participantCount = participantDocs.length;\n if (participantCount < 2) {\n throw new Error(\"At least two participants are required for a DKG invite\");\n }\n\n // Validate and default minSigners\n const minSigners = minSignersArg ?? participantCount;\n if (minSigners < 2) {\n throw new Error(\"--min-signers must be at least 2\");\n }\n if (minSigners > participantCount) {\n throw new Error(\"--min-signers cannot exceed participant count\");\n }\n\n // Get sender (registry owner)\n // The coordinator's invite always identifies the registry owner as\n // the sender. (Rust reads `registry.owner()` directly here too —\n // see `cmd/dkg/coordinator/invite.rs:74-77`.)\n const sender = resolveOwnerXidDocument(registry);\n\n // Calculate dates\n const now = new Date();\n const validUntil = new Date(Date.now() + validDays * 24 * 60 * 60 * 1000);\n\n // Create the invite\n const invite = DkgInvite.create(\n ARID.new(), // requestId\n sender,\n ARID.new(), // groupId\n now,\n validUntil,\n minSigners,\n charter,\n participantDocs,\n collectFromArids,\n );\n\n return { invite, participantXids, pendingRequests };\n}\n\n/**\n * Execute the DKG invite command.\n *\n * Port of `invite()` from cmd/dkg/coordinator/invite.rs.\n */\nexport async function invite(\n client: StorageClient,\n options: DkgInviteOptions,\n cwd: string,\n): Promise<DkgInviteResult> {\n const registryPath = resolveRegistryPath(options.registryPath, cwd);\n const registry = Registry.load(registryPath);\n\n // Build the invite with validation\n const inviteData = buildInvite(\n registry,\n options.minSigners,\n options.charter,\n options.participantNames,\n options.validDays,\n );\n\n const { invite: dkgInvite, participantXids, pendingRequests } = inviteData;\n const groupId = dkgInvite.groupId();\n const requestId = dkgInvite.requestId();\n\n // Create sealed envelope\n const envelope = dkgInvite.toEnvelope();\n\n // Send to storage\n const startArid = ARID.new();\n await putWithIndicator(\n client,\n startArid,\n envelope,\n \"Sending DKG invite\",\n options.verbose ?? false,\n );\n\n // Save group record to registry\n const owner = registry.owner();\n if (!owner) {\n throw new Error(\"Registry owner is required to issue invites\");\n }\n\n const coordinator = new GroupParticipant(owner.xid());\n const groupParticipants = participantXids.map((xid) => new GroupParticipant(xid));\n\n const groupRecord = new GroupRecord(\n options.charter,\n dkgInvite.minSigners(),\n coordinator,\n groupParticipants,\n );\n\n // Track pending requests\n groupRecord.setPendingRequests(pendingRequests);\n\n // Use recordGroup() for proper merge behavior\n registry.recordGroup(groupId, groupRecord);\n registry.save(registryPath);\n\n // Save invite state\n const stateDir = dkgStateDir(registryPath, groupId.hex());\n fs.mkdirSync(stateDir, { recursive: true });\n\n const inviteState: {\n group: string;\n request_id: string;\n start_arid: string;\n valid_until: string;\n participants: { xid: string; response_arid: string }[];\n } = {\n group: groupId.urString(),\n request_id: requestId.urString(),\n start_arid: startArid.urString(),\n valid_until: dkgInvite.validUntil().toISOString(),\n participants: dkgInvite.participants().map((p) => ({\n xid: p.xid().urString(),\n response_arid: p.responseArid().urString(),\n })),\n };\n\n fs.writeFileSync(path.join(stateDir, \"invite.json\"), JSON.stringify(inviteState, null, 2));\n\n if (options.verbose === true) {\n console.log(`Group ID: ${groupId.urString()}`);\n console.log(`Start ARID: ${startArid.urString()}`);\n }\n\n return {\n groupId,\n requestId,\n envelopeUr: envelope.urString(),\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAkEA,SAAS,YACP,UACA,eACA,SACA,kBACA,WACY;CAEZ,MAAM,WAAW,oBAAoB,UAAU,iBAAiB;CAChE,MAAM,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AC9B,KAAI,CAAC,MACH,OAAM,IAAI,MAAM,8CAA8C;CAGhE,MAAM,cAAc,IAAI,iBAAiB,MAAM,KAAK,CAAC;CACrD,MAAM,oBAAoB,gBAAgB,KAAK,QAAQ,IAAI,iBAAiB,IAAI,CAAC;CAEjF,MAAM,cAAc,IAAI,YACtB,QAAQ,SACR,UAAU,YAAY,EACtB,aACA,kBACD;AAGD,aAAY,mBAAmB,gBAAgB;AAG/C,UAAS,YAAY,SAAS,YAAY;AAC1C,UAAS,KAAK,aAAa;CAG3B,MAAM,WAAW,YAAY,cAAc,QAAQ,KAAK,CAAC;AACzD,IAAG,UAAU,UAAU,EAAE,WAAW,MAAM,CAAC;CAE3C,MAAM,cAMF;EACF,OAAO,QAAQ,UAAU;EACzB,YAAY,UAAU,UAAU;EAChC,YAAY,UAAU,UAAU;EAChC,aAAa,UAAU,YAAY,CAAC,aAAa;EACjD,cAAc,UAAU,cAAc,CAAC,KAAK,OAAO;GACjD,KAAK,EAAE,KAAK,CAAC,UAAU;GACvB,eAAe,EAAE,cAAc,CAAC,UAAU;GAC3C,EAAE;EACJ;AAED,IAAG,cAAc,KAAK,KAAK,UAAU,cAAc,EAAE,KAAK,UAAU,aAAa,MAAM,EAAE,CAAC;AAE1F,KAAI,QAAQ,YAAY,MAAM;AAC5B,UAAQ,IAAI,aAAa,QAAQ,UAAU,GAAG;AAC9C,UAAQ,IAAI,eAAe,UAAU,UAAU,GAAG;;AAGpD,QAAO;EACL;EACA;EACA,YAAY,SAAS,UAAU;EAChC"}
1
+ {"version":3,"file":"invite-Be2v2SVc.mjs","names":[],"sources":["../src/cmd/dkg/coordinator/invite.ts"],"sourcesContent":["/**\n * Copyright © 2023-2026 Blockchain Commons, LLC\n * Copyright © 2025-2026 Parity Technologies\n *\n *\n * DKG coordinator invite command.\n *\n * Port of cmd/dkg/coordinator/invite.rs from frost-hubert-rust.\n *\n * @module\n */\n\nimport * as fs from \"node:fs\";\nimport * as path from \"node:path\";\n\nimport { ARID, type XID } from \"@bcts/components\";\n\nimport { DkgInvite } from \"../../../dkg/index.js\";\nimport {\n GroupParticipant,\n GroupRecord,\n PendingRequests,\n Registry,\n resolveRegistryPath,\n} from \"../../../registry/index.js\";\nimport { putWithIndicator } from \"../../busy.js\";\nimport { type StorageClient } from \"../../storage.js\";\nimport { dkgStateDir, resolveOwnerXidDocument, resolveParticipants } from \"../common.js\";\n\n/**\n * Options for the DKG invite command.\n */\nexport interface DkgInviteOptions {\n registryPath?: string;\n minSigners?: number;\n charter: string;\n validDays: number;\n participantNames: string[];\n verbose?: boolean;\n}\n\n/**\n * Result of the DKG invite command.\n */\nexport interface DkgInviteResult {\n groupId: ARID;\n requestId: ARID;\n envelopeUr: string;\n}\n\n/**\n * Internal data structure for building an invite.\n *\n * Port of `InviteData` struct from cmd/dkg/coordinator/invite.rs lines 122-126.\n */\ninterface InviteData {\n invite: DkgInvite;\n participantXids: XID[];\n pendingRequests: PendingRequests;\n}\n\n/**\n * Build the DKG invite with validation.\n *\n * Port of `build_invite()` from cmd/dkg/coordinator/invite.rs lines 128-181.\n */\nfunction buildInvite(\n registry: Registry,\n minSignersArg: number | undefined,\n charter: string,\n participantNames: string[],\n validDays: number,\n): InviteData {\n // Resolve participants using the common utility\n const resolved = resolveParticipants(registry, participantNames);\n const participantDocs: string[] = resolved.map(([, record]) => record.xidDocumentUr());\n const participantXids: XID[] = resolved.map(([xid]) => xid);\n\n // These are the ARIDs where participants will post their invite responses\n const collectFromArids: ARID[] = participantDocs.map(() => ARID.new());\n\n // Build pending_requests: coordinator will collect invite responses from these ARIDs\n const pendingRequests = new PendingRequests();\n for (let i = 0; i < participantXids.length; i++) {\n pendingRequests.addCollectOnly(participantXids[i], collectFromArids[i]);\n }\n\n // Validate participant count\n const participantCount = participantDocs.length;\n if (participantCount < 2) {\n throw new Error(\"At least two participants are required for a DKG invite\");\n }\n\n // Validate and default minSigners\n const minSigners = minSignersArg ?? participantCount;\n if (minSigners < 2) {\n throw new Error(\"--min-signers must be at least 2\");\n }\n if (minSigners > participantCount) {\n throw new Error(\"--min-signers cannot exceed participant count\");\n }\n\n // Get sender (registry owner)\n // The coordinator's invite always identifies the registry owner as\n // the sender. (Rust reads `registry.owner()` directly here too —\n // see `cmd/dkg/coordinator/invite.rs:74-77`.)\n const sender = resolveOwnerXidDocument(registry);\n\n // Calculate dates\n const now = new Date();\n const validUntil = new Date(Date.now() + validDays * 24 * 60 * 60 * 1000);\n\n // Create the invite\n const invite = DkgInvite.create(\n ARID.new(), // requestId\n sender,\n ARID.new(), // groupId\n now,\n validUntil,\n minSigners,\n charter,\n participantDocs,\n collectFromArids,\n );\n\n return { invite, participantXids, pendingRequests };\n}\n\n/**\n * Execute the DKG invite command.\n *\n * Port of `invite()` from cmd/dkg/coordinator/invite.rs.\n */\nexport async function invite(\n client: StorageClient,\n options: DkgInviteOptions,\n cwd: string,\n): Promise<DkgInviteResult> {\n const registryPath = resolveRegistryPath(options.registryPath, cwd);\n const registry = Registry.load(registryPath);\n\n // Build the invite with validation\n const inviteData = buildInvite(\n registry,\n options.minSigners,\n options.charter,\n options.participantNames,\n options.validDays,\n );\n\n const { invite: dkgInvite, participantXids, pendingRequests } = inviteData;\n const groupId = dkgInvite.groupId();\n const requestId = dkgInvite.requestId();\n\n // Create sealed envelope\n const envelope = dkgInvite.toEnvelope();\n\n // Send to storage\n const startArid = ARID.new();\n await putWithIndicator(\n client,\n startArid,\n envelope,\n \"Sending DKG invite\",\n options.verbose ?? false,\n );\n\n // Save group record to registry\n const owner = registry.owner();\n if (!owner) {\n throw new Error(\"Registry owner is required to issue invites\");\n }\n\n const coordinator = new GroupParticipant(owner.xid());\n const groupParticipants = participantXids.map((xid) => new GroupParticipant(xid));\n\n const groupRecord = new GroupRecord(\n options.charter,\n dkgInvite.minSigners(),\n coordinator,\n groupParticipants,\n );\n\n // Track pending requests\n groupRecord.setPendingRequests(pendingRequests);\n\n // Use recordGroup() for proper merge behavior\n registry.recordGroup(groupId, groupRecord);\n registry.save(registryPath);\n\n // Save invite state\n const stateDir = dkgStateDir(registryPath, groupId.hex());\n fs.mkdirSync(stateDir, { recursive: true });\n\n const inviteState: {\n group: string;\n request_id: string;\n start_arid: string;\n valid_until: string;\n participants: { xid: string; response_arid: string }[];\n } = {\n group: groupId.urString(),\n request_id: requestId.urString(),\n start_arid: startArid.urString(),\n valid_until: dkgInvite.validUntil().toISOString(),\n participants: dkgInvite.participants().map((p) => ({\n xid: p.xid().urString(),\n response_arid: p.responseArid().urString(),\n })),\n };\n\n fs.writeFileSync(path.join(stateDir, \"invite.json\"), JSON.stringify(inviteState, null, 2));\n\n if (options.verbose === true) {\n console.log(`Group ID: ${groupId.urString()}`);\n console.log(`Start ARID: ${startArid.urString()}`);\n }\n\n return {\n groupId,\n requestId,\n envelopeUr: envelope.urString(),\n };\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAkEA,SAAS,YACP,UACA,eACA,SACA,kBACA,WACY;CAEZ,MAAM,WAAW,oBAAoB,UAAU,gBAAgB;CAC/D,MAAM,kBAA4B,SAAS,KAAK,GAAG,YAAY,OAAO,cAAc,CAAC;CACrF,MAAM,kBAAyB,SAAS,KAAK,CAAC,SAAS,GAAG;CAG1D,MAAM,mBAA2B,gBAAgB,UAAU,KAAK,IAAI,CAAC;CAGrE,MAAM,kBAAkB,IAAI,gBAAgB;CAC5C,KAAK,IAAI,IAAI,GAAG,IAAI,gBAAgB,QAAQ,KAC1C,gBAAgB,eAAe,gBAAgB,IAAI,iBAAiB,EAAE;CAIxE,MAAM,mBAAmB,gBAAgB;CACzC,IAAI,mBAAmB,GACrB,MAAM,IAAI,MAAM,yDAAyD;CAI3E,MAAM,aAAa,iBAAiB;CACpC,IAAI,aAAa,GACf,MAAM,IAAI,MAAM,kCAAkC;CAEpD,IAAI,aAAa,kBACf,MAAM,IAAI,MAAM,+CAA+C;CAOjE,MAAM,SAAS,wBAAwB,QAAQ;CAG/C,MAAM,sBAAM,IAAI,KAAK;CACrB,MAAM,aA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KAAK,OAAO;GACjD,KAAK,EAAE,IAAI,EAAE,SAAS;GACtB,eAAe,EAAE,aAAa,EAAE,SAAS;EAC3C,EAAE;CACJ;CAEA,GAAG,cAAc,KAAK,KAAK,UAAU,aAAa,GAAG,KAAK,UAAU,aAAa,MAAM,CAAC,CAAC;CAEzF,IAAI,QAAQ,YAAY,MAAM;EAC5B,QAAQ,IAAI,aAAa,QAAQ,SAAS,GAAG;EAC7C,QAAQ,IAAI,eAAe,UAAU,SAAS,GAAG;CACnD;CAEA,OAAO;EACL;EACA;EACA,YAAY,SAAS,SAAS;CAChC;AACF"}
@@ -1,8 +1,8 @@
1
- import { t as __exportAll } from "./chunk-CjcI7cDX.mjs";
1
+ import { t as __exportAll } from "./chunk-z9aeyW2b.mjs";
2
2
  import { Registry, resolveRegistryPath } from "./registry/index.mjs";
3
- import { c as parseAridUr } from "./common-CvH6dFvQ.mjs";
4
- import { n as putWithIndicator } from "./busy-DkM2jAIZ.mjs";
5
- import { n as signingStateDir } from "./common-DUWvtc08.mjs";
3
+ import { c as parseAridUr } from "./common-Cf1UvJaP.mjs";
4
+ import { n as putWithIndicator } from "./busy-BlU8_pS2.mjs";
5
+ import { n as signingStateDir } from "./common-DNrD_-EI.mjs";
6
6
  import { ARID } from "@bcts/components";
7
7
  import { CborDate } from "@bcts/dcbor";
8
8
  import { Envelope } from "@bcts/envelope";
@@ -216,4 +216,4 @@ async function invite(client, options, cwd) {
216
216
  //#endregion
217
217
  export { invite as a, persistSessionState as c, gatherRecipientDocuments as i, validateCoordinator as l, buildSignInviteRequest as n, invite_exports as o, createSessionArids as r, loadEnvelopeFromPath as s, buildSessionStateJson as t };
218
218
 
219
- //# sourceMappingURL=invite-RU-OXTNS.mjs.map
219
+ //# sourceMappingURL=invite-D8mQSnFz.mjs.map