@noy-db/hub 0.6.0-pre.15 → 0.6.0-pre.16

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 (208) hide show
  1. package/dist/{api-VRTBOCY7.js → api-NAY63UIE.js} +5 -5
  2. package/dist/attestation/index.js +11 -11
  3. package/dist/{backup-BXS6GNCA.js → backup-M2VND2VS.js} +12 -14
  4. package/dist/backup-M2VND2VS.js.map +1 -0
  5. package/dist/blobs/index.js +3 -3
  6. package/dist/broker/index.js +5 -5
  7. package/dist/cargo/index.js +17 -17
  8. package/dist/{chunk-X24QHSG5.js → chunk-343FH4S5.js} +3 -3
  9. package/dist/{chunk-6R4QXE43.js → chunk-35RIRCGW.js} +2 -2
  10. package/dist/{chunk-ESABIXMQ.js → chunk-3JQVA527.js} +2 -2
  11. package/dist/{chunk-PF3E6ABL.js → chunk-3OEWD45V.js} +4 -4
  12. package/dist/{chunk-5AV6FENP.js → chunk-4CSG6KBX.js} +2 -2
  13. package/dist/{chunk-MMXMJXAE.js → chunk-4DJQU3PH.js} +4 -4
  14. package/dist/{chunk-KNAZGJFG.js → chunk-4JDTLWUZ.js} +9 -9
  15. package/dist/{chunk-GWJNBTZA.js → chunk-4XEUSZWN.js} +2 -2
  16. package/dist/{chunk-62KVBIBU.js → chunk-53PWELSC.js} +2 -2
  17. package/dist/{chunk-AIR3LSJH.js → chunk-56W3T5O2.js} +12 -18
  18. package/dist/chunk-56W3T5O2.js.map +1 -0
  19. package/dist/{chunk-DU27P4LO.js → chunk-5CH4DWQA.js} +2 -2
  20. package/dist/{chunk-RQ5G2YER.js → chunk-5TF5DUQ5.js} +3 -3
  21. package/dist/chunk-6E2JZRBD.js +60 -0
  22. package/dist/chunk-6E2JZRBD.js.map +1 -0
  23. package/dist/{chunk-A5BGC3GR.js → chunk-6EF3N2MH.js} +20 -18
  24. package/dist/chunk-6EF3N2MH.js.map +1 -0
  25. package/dist/{chunk-WVS62P45.js → chunk-76FBDG6M.js} +3 -3
  26. package/dist/{chunk-SZZEDEIU.js → chunk-7LLKPODL.js} +1 -1
  27. package/dist/chunk-7LLKPODL.js.map +1 -0
  28. package/dist/{chunk-FINIMZ55.js → chunk-A3WHDOWI.js} +2 -2
  29. package/dist/{chunk-TWSFSH32.js → chunk-AD2PJGSS.js} +2 -2
  30. package/dist/{chunk-SX7MAZ5U.js → chunk-B4G3JPH5.js} +2 -2
  31. package/dist/{chunk-CJ4KXDD4.js → chunk-CZV57HHC.js} +2 -2
  32. package/dist/{chunk-PJ5TGJ7U.js → chunk-FZ2SSI5R.js} +2 -2
  33. package/dist/{chunk-6N5PZ6G5.js → chunk-H5U4T6JK.js} +3 -3
  34. package/dist/{chunk-6O3PVUYJ.js → chunk-HNX47VTC.js} +5 -5
  35. package/dist/{chunk-LAVPHX2V.js → chunk-IGE6XWKK.js} +3 -3
  36. package/dist/{chunk-PE6R44GS.js → chunk-IQGIPRSE.js} +4 -4
  37. package/dist/chunk-IQGIPRSE.js.map +1 -0
  38. package/dist/{chunk-YZGKXIYY.js → chunk-KKRFL5E2.js} +66 -67
  39. package/dist/chunk-KKRFL5E2.js.map +1 -0
  40. package/dist/{chunk-RERAMZK5.js → chunk-LJDW6LQJ.js} +2 -2
  41. package/dist/{chunk-PWJSO7HH.js → chunk-LTVETWDH.js} +38 -36
  42. package/dist/{chunk-PWJSO7HH.js.map → chunk-LTVETWDH.js.map} +1 -1
  43. package/dist/{chunk-ELHNLDXB.js → chunk-MKSTUVMJ.js} +14 -16
  44. package/dist/chunk-MKSTUVMJ.js.map +1 -0
  45. package/dist/{chunk-7F4TMKXC.js → chunk-MKV2KYRV.js} +2 -2
  46. package/dist/{chunk-ELA2THEC.js → chunk-NBLLQOMR.js} +3 -3
  47. package/dist/{chunk-BPT4W6CI.js → chunk-NY6RQBUN.js} +2 -2
  48. package/dist/{chunk-QVDK5AR7.js → chunk-OJEDR25M.js} +3 -3
  49. package/dist/{chunk-5CK7VSSK.js → chunk-OPGKH5RD.js} +3 -3
  50. package/dist/chunk-OPGKH5RD.js.map +1 -0
  51. package/dist/{chunk-UZ2J7OKF.js → chunk-PJGMBELR.js} +3 -3
  52. package/dist/{chunk-PNEV2TBR.js → chunk-PZLIA5R3.js} +2 -2
  53. package/dist/{chunk-4FNR5YZI.js → chunk-RRMXMJUP.js} +10 -10
  54. package/dist/chunk-RRMXMJUP.js.map +1 -0
  55. package/dist/{chunk-FBG62BUQ.js → chunk-T6CCRXD3.js} +8 -14
  56. package/dist/chunk-T6CCRXD3.js.map +1 -0
  57. package/dist/{chunk-T7XUDZ7N.js → chunk-THUITYH7.js} +2 -2
  58. package/dist/{chunk-TEJILTMY.js → chunk-TTAND7MR.js} +4 -4
  59. package/dist/{chunk-HAN2PHLM.js → chunk-TWPTRJEU.js} +2 -2
  60. package/dist/{chunk-WVCOS4XA.js → chunk-TY6N3PAC.js} +2 -2
  61. package/dist/{chunk-5LKPMDBC.js → chunk-UVFO25FJ.js} +3 -3
  62. package/dist/{chunk-KIZOCPHS.js → chunk-VUUUIKRG.js} +2 -2
  63. package/dist/{chunk-U26JILS3.js → chunk-WMZQCXZ5.js} +4 -4
  64. package/dist/{chunk-RLK57SMS.js → chunk-YX6J3Z3Z.js} +2 -2
  65. package/dist/classified/index.js +1 -1
  66. package/dist/{classified-marker-BCYBGITH.js → classified-marker-L7LXKS6Q.js} +3 -3
  67. package/dist/{collection-facade-YCJHWX64.js → collection-facade-KN3UFKZ4.js} +9 -9
  68. package/dist/consent/index.js +3 -3
  69. package/dist/custody/index.js +5 -5
  70. package/dist/{dead-filter-5ROD2DCQ.js → dead-filter-6HG5FP3I.js} +2 -2
  71. package/dist/{delegation-IULC56LW.js → delegation-7EGBYBRN.js} +3 -3
  72. package/dist/derivations/index.js +2 -2
  73. package/dist/{derive-AP2NXZDC.js → derive-XKAYJ2OA.js} +3 -3
  74. package/dist/directory/index.js +4 -4
  75. package/dist/{dispatch-Z6C35BGM.js → dispatch-56T7VPGE.js} +5 -5
  76. package/dist/{dispatch-4KKOMKWJ.js → dispatch-BM5GNCE2.js} +9 -9
  77. package/dist/{enclave-KJID436X.js → enclave-KDLGVX5Z.js} +5 -3
  78. package/dist/{executor-GD32BQQK.js → executor-LFHRV6JH.js} +9 -9
  79. package/dist/{export-accessible-H4Y2RTTD.js → export-accessible-HFBJ4JJY.js} +5 -5
  80. package/dist/{extract-partition-PIJZX4G4.js → extract-partition-7ZRFN6QP.js} +8 -8
  81. package/dist/{fanout-sidecar-6QGMG5MA.js → fanout-sidecar-MT2OBMZB.js} +3 -3
  82. package/dist/forget/index.js +3 -3
  83. package/dist/history/index.js +5 -5
  84. package/dist/i18n/index.js +7 -7
  85. package/dist/index.js +48 -50
  86. package/dist/index.js.map +1 -1
  87. package/dist/introspection/index.js +4 -4
  88. package/dist/{issue-Q6STVPV5.js → issue-LCOOEH45.js} +5 -5
  89. package/dist/kernel/enclave/index.d.ts +2 -0
  90. package/dist/kernel/enclave/record-envelope.d.ts +29 -0
  91. package/dist/kernel/enclave/record-keys/tombstone.d.ts +3 -2
  92. package/dist/{ledger-HLINHILR.js → ledger-6IHXJHDD.js} +5 -5
  93. package/dist/{liberate-C3XBBLYM.js → liberate-UEYC4QLJ.js} +9 -9
  94. package/dist/{link-set-S47JZWHV.js → link-set-XRVHGYWC.js} +4 -4
  95. package/dist/materialized-views/index.js +9 -9
  96. package/dist/{noydb-HT56GCTQ.js → noydb-M5WII7RP.js} +21 -21
  97. package/dist/periods/index.js +5 -5
  98. package/dist/pod/index.js +23 -23
  99. package/dist/{pod-handle-N6HQMAAV.js → pod-handle-BYUSBXCT.js} +15 -10
  100. package/dist/pod-handle-BYUSBXCT.js.map +1 -0
  101. package/dist/port/with/i18n-strategy.d.ts +4 -1
  102. package/dist/port/with/lookup-strategy.d.ts +4 -1
  103. package/dist/portability/index.js +6 -6
  104. package/dist/{post-register-KW557BUZ.js → post-register-O3YW6CGS.js} +4 -4
  105. package/dist/reduce/index.js +2 -2
  106. package/dist/{register-OMH3WVVL.js → register-XHOOX37G.js} +8 -8
  107. package/dist/{registry-ZE2OG4TN.js → registry-CYAFB35H.js} +3 -3
  108. package/dist/{registry-SAEOPHFF.js → registry-OFMM4WAC.js} +3 -3
  109. package/dist/{request-withdrawal-HTSROWCL.js → request-withdrawal-GCE2SLNW.js} +7 -7
  110. package/dist/{reveal-T4N65GUG.js → reveal-UHBP5IH3.js} +2 -2
  111. package/dist/{revoke-NE4CU2T3.js → revoke-6KY4VGZY.js} +5 -5
  112. package/dist/sealed-record/index.js +5 -5
  113. package/dist/search/index.js +2 -2
  114. package/dist/{seed-TC42KFUK.js → seed-DGLQTCIO.js} +5 -5
  115. package/dist/sequence/index.js +3 -3
  116. package/dist/session/index.js +2 -2
  117. package/dist/{signer-W2LX2FPA.js → signer-SLOMB6HS.js} +4 -4
  118. package/dist/snapshots/index.js +3 -3
  119. package/dist/{stale-WSC6Z7SB.js → stale-26ZJLNLG.js} +4 -4
  120. package/dist/{storage-EWT5HIX5.js → storage-N3IMFNGS.js} +4 -4
  121. package/dist/sync/index.js +3 -3
  122. package/dist/team/index.js +6 -6
  123. package/dist/tiers/index.js +3 -3
  124. package/dist/via/lookup/handle.d.ts +4 -1
  125. package/dist/{walk-OLQC4JFV.js → walk-B4YFJJ7S.js} +5 -5
  126. package/dist/with-commit/numbering/index.d.ts +0 -5
  127. package/dist/with-pod/pod-handle.d.ts +10 -0
  128. package/dist/{withdraw-accessible-Y7OEPWXM.js → withdraw-accessible-OYG7YZUR.js} +6 -6
  129. package/package.json +3 -3
  130. package/dist/backup-BXS6GNCA.js.map +0 -1
  131. package/dist/chunk-4FNR5YZI.js.map +0 -1
  132. package/dist/chunk-5CK7VSSK.js.map +0 -1
  133. package/dist/chunk-A5BGC3GR.js.map +0 -1
  134. package/dist/chunk-AIR3LSJH.js.map +0 -1
  135. package/dist/chunk-ELHNLDXB.js.map +0 -1
  136. package/dist/chunk-FBG62BUQ.js.map +0 -1
  137. package/dist/chunk-P3AFV6EA.js +0 -45
  138. package/dist/chunk-P3AFV6EA.js.map +0 -1
  139. package/dist/chunk-PE6R44GS.js.map +0 -1
  140. package/dist/chunk-SZZEDEIU.js.map +0 -1
  141. package/dist/chunk-YZGKXIYY.js.map +0 -1
  142. package/dist/pod-handle-N6HQMAAV.js.map +0 -1
  143. /package/dist/{api-VRTBOCY7.js.map → api-NAY63UIE.js.map} +0 -0
  144. /package/dist/{chunk-X24QHSG5.js.map → chunk-343FH4S5.js.map} +0 -0
  145. /package/dist/{chunk-6R4QXE43.js.map → chunk-35RIRCGW.js.map} +0 -0
  146. /package/dist/{chunk-ESABIXMQ.js.map → chunk-3JQVA527.js.map} +0 -0
  147. /package/dist/{chunk-PF3E6ABL.js.map → chunk-3OEWD45V.js.map} +0 -0
  148. /package/dist/{chunk-5AV6FENP.js.map → chunk-4CSG6KBX.js.map} +0 -0
  149. /package/dist/{chunk-MMXMJXAE.js.map → chunk-4DJQU3PH.js.map} +0 -0
  150. /package/dist/{chunk-KNAZGJFG.js.map → chunk-4JDTLWUZ.js.map} +0 -0
  151. /package/dist/{chunk-GWJNBTZA.js.map → chunk-4XEUSZWN.js.map} +0 -0
  152. /package/dist/{chunk-62KVBIBU.js.map → chunk-53PWELSC.js.map} +0 -0
  153. /package/dist/{chunk-DU27P4LO.js.map → chunk-5CH4DWQA.js.map} +0 -0
  154. /package/dist/{chunk-RQ5G2YER.js.map → chunk-5TF5DUQ5.js.map} +0 -0
  155. /package/dist/{chunk-WVS62P45.js.map → chunk-76FBDG6M.js.map} +0 -0
  156. /package/dist/{chunk-FINIMZ55.js.map → chunk-A3WHDOWI.js.map} +0 -0
  157. /package/dist/{chunk-TWSFSH32.js.map → chunk-AD2PJGSS.js.map} +0 -0
  158. /package/dist/{chunk-SX7MAZ5U.js.map → chunk-B4G3JPH5.js.map} +0 -0
  159. /package/dist/{chunk-CJ4KXDD4.js.map → chunk-CZV57HHC.js.map} +0 -0
  160. /package/dist/{chunk-PJ5TGJ7U.js.map → chunk-FZ2SSI5R.js.map} +0 -0
  161. /package/dist/{chunk-6N5PZ6G5.js.map → chunk-H5U4T6JK.js.map} +0 -0
  162. /package/dist/{chunk-6O3PVUYJ.js.map → chunk-HNX47VTC.js.map} +0 -0
  163. /package/dist/{chunk-LAVPHX2V.js.map → chunk-IGE6XWKK.js.map} +0 -0
  164. /package/dist/{chunk-RERAMZK5.js.map → chunk-LJDW6LQJ.js.map} +0 -0
  165. /package/dist/{chunk-7F4TMKXC.js.map → chunk-MKV2KYRV.js.map} +0 -0
  166. /package/dist/{chunk-ELA2THEC.js.map → chunk-NBLLQOMR.js.map} +0 -0
  167. /package/dist/{chunk-BPT4W6CI.js.map → chunk-NY6RQBUN.js.map} +0 -0
  168. /package/dist/{chunk-QVDK5AR7.js.map → chunk-OJEDR25M.js.map} +0 -0
  169. /package/dist/{chunk-UZ2J7OKF.js.map → chunk-PJGMBELR.js.map} +0 -0
  170. /package/dist/{chunk-PNEV2TBR.js.map → chunk-PZLIA5R3.js.map} +0 -0
  171. /package/dist/{chunk-T7XUDZ7N.js.map → chunk-THUITYH7.js.map} +0 -0
  172. /package/dist/{chunk-TEJILTMY.js.map → chunk-TTAND7MR.js.map} +0 -0
  173. /package/dist/{chunk-HAN2PHLM.js.map → chunk-TWPTRJEU.js.map} +0 -0
  174. /package/dist/{chunk-WVCOS4XA.js.map → chunk-TY6N3PAC.js.map} +0 -0
  175. /package/dist/{chunk-5LKPMDBC.js.map → chunk-UVFO25FJ.js.map} +0 -0
  176. /package/dist/{chunk-KIZOCPHS.js.map → chunk-VUUUIKRG.js.map} +0 -0
  177. /package/dist/{chunk-U26JILS3.js.map → chunk-WMZQCXZ5.js.map} +0 -0
  178. /package/dist/{chunk-RLK57SMS.js.map → chunk-YX6J3Z3Z.js.map} +0 -0
  179. /package/dist/{classified-marker-BCYBGITH.js.map → classified-marker-L7LXKS6Q.js.map} +0 -0
  180. /package/dist/{collection-facade-YCJHWX64.js.map → collection-facade-KN3UFKZ4.js.map} +0 -0
  181. /package/dist/{dead-filter-5ROD2DCQ.js.map → dead-filter-6HG5FP3I.js.map} +0 -0
  182. /package/dist/{delegation-IULC56LW.js.map → delegation-7EGBYBRN.js.map} +0 -0
  183. /package/dist/{derive-AP2NXZDC.js.map → derive-XKAYJ2OA.js.map} +0 -0
  184. /package/dist/{dispatch-Z6C35BGM.js.map → dispatch-56T7VPGE.js.map} +0 -0
  185. /package/dist/{dispatch-4KKOMKWJ.js.map → dispatch-BM5GNCE2.js.map} +0 -0
  186. /package/dist/{enclave-KJID436X.js.map → enclave-KDLGVX5Z.js.map} +0 -0
  187. /package/dist/{executor-GD32BQQK.js.map → executor-LFHRV6JH.js.map} +0 -0
  188. /package/dist/{export-accessible-H4Y2RTTD.js.map → export-accessible-HFBJ4JJY.js.map} +0 -0
  189. /package/dist/{extract-partition-PIJZX4G4.js.map → extract-partition-7ZRFN6QP.js.map} +0 -0
  190. /package/dist/{fanout-sidecar-6QGMG5MA.js.map → fanout-sidecar-MT2OBMZB.js.map} +0 -0
  191. /package/dist/{issue-Q6STVPV5.js.map → issue-LCOOEH45.js.map} +0 -0
  192. /package/dist/{ledger-HLINHILR.js.map → ledger-6IHXJHDD.js.map} +0 -0
  193. /package/dist/{liberate-C3XBBLYM.js.map → liberate-UEYC4QLJ.js.map} +0 -0
  194. /package/dist/{link-set-S47JZWHV.js.map → link-set-XRVHGYWC.js.map} +0 -0
  195. /package/dist/{noydb-HT56GCTQ.js.map → noydb-M5WII7RP.js.map} +0 -0
  196. /package/dist/{post-register-KW557BUZ.js.map → post-register-O3YW6CGS.js.map} +0 -0
  197. /package/dist/{register-OMH3WVVL.js.map → register-XHOOX37G.js.map} +0 -0
  198. /package/dist/{registry-SAEOPHFF.js.map → registry-CYAFB35H.js.map} +0 -0
  199. /package/dist/{registry-ZE2OG4TN.js.map → registry-OFMM4WAC.js.map} +0 -0
  200. /package/dist/{request-withdrawal-HTSROWCL.js.map → request-withdrawal-GCE2SLNW.js.map} +0 -0
  201. /package/dist/{reveal-T4N65GUG.js.map → reveal-UHBP5IH3.js.map} +0 -0
  202. /package/dist/{revoke-NE4CU2T3.js.map → revoke-6KY4VGZY.js.map} +0 -0
  203. /package/dist/{seed-TC42KFUK.js.map → seed-DGLQTCIO.js.map} +0 -0
  204. /package/dist/{signer-W2LX2FPA.js.map → signer-SLOMB6HS.js.map} +0 -0
  205. /package/dist/{stale-WSC6Z7SB.js.map → stale-26ZJLNLG.js.map} +0 -0
  206. /package/dist/{storage-EWT5HIX5.js.map → storage-N3IMFNGS.js.map} +0 -0
  207. /package/dist/{walk-OLQC4JFV.js.map → walk-B4YFJJ7S.js.map} +0 -0
  208. /package/dist/{withdraw-accessible-Y7OEPWXM.js.map → withdraw-accessible-OYG7YZUR.js.map} +0 -0
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  UserApi,
3
3
  createUserApi
4
- } from "./chunk-GWJNBTZA.js";
5
- import "./chunk-PNEV2TBR.js";
6
- import "./chunk-PWJSO7HH.js";
7
- import "./chunk-P3AFV6EA.js";
4
+ } from "./chunk-4XEUSZWN.js";
5
+ import "./chunk-PZLIA5R3.js";
6
+ import "./chunk-LTVETWDH.js";
7
+ import "./chunk-6E2JZRBD.js";
8
8
  import "./chunk-FSZPQCDR.js";
9
9
  import "./chunk-HVR74IBG.js";
10
10
  import "./chunk-RBTZLXZJ.js";
@@ -17,4 +17,4 @@ export {
17
17
  UserApi,
18
18
  createUserApi
19
19
  };
20
- //# sourceMappingURL=api-VRTBOCY7.js.map
20
+ //# sourceMappingURL=api-NAY63UIE.js.map
@@ -1,21 +1,21 @@
1
1
  import {
2
2
  issueAttestationCore
3
- } from "../chunk-SX7MAZ5U.js";
3
+ } from "../chunk-B4G3JPH5.js";
4
4
  import {
5
5
  getRevokedDocIdsCore,
6
6
  publishRevocationListCore,
7
7
  revokeDocCore,
8
8
  unrevokeDocCore
9
- } from "../chunk-ELA2THEC.js";
9
+ } from "../chunk-NBLLQOMR.js";
10
10
  import {
11
11
  ATTESTATIONS_COLLECTION
12
- } from "../chunk-DU27P4LO.js";
12
+ } from "../chunk-5CH4DWQA.js";
13
13
  import {
14
14
  NO_ATTESTATION
15
15
  } from "../chunk-TQLYMYOK.js";
16
16
  import "../chunk-4AOERLTV.js";
17
- import "../chunk-PWJSO7HH.js";
18
- import "../chunk-P3AFV6EA.js";
17
+ import "../chunk-LTVETWDH.js";
18
+ import "../chunk-6E2JZRBD.js";
19
19
  import "../chunk-FSZPQCDR.js";
20
20
  import "../chunk-HVR74IBG.js";
21
21
  import "../chunk-RBTZLXZJ.js";
@@ -32,11 +32,11 @@ import "../chunk-PZ5AY32C.js";
32
32
  function withAttestation() {
33
33
  return {
34
34
  async issueAttestation(ctx, args) {
35
- const { issueAttestationCore: issueAttestationCore2 } = await import("../issue-Q6STVPV5.js");
35
+ const { issueAttestationCore: issueAttestationCore2 } = await import("../issue-LCOOEH45.js");
36
36
  return issueAttestationCore2(ctx, args);
37
37
  },
38
38
  async getDocumentSigningPublicKey(deps) {
39
- const { loadSigner, loadOrCreateSigner } = await import("../signer-W2LX2FPA.js");
39
+ const { loadSigner, loadOrCreateSigner } = await import("../signer-SLOMB6HS.js");
40
40
  const existing = await loadSigner(deps.adapter, deps.vault, deps.getDEK);
41
41
  if (existing) return { keyId: existing.keyId, publicKeyB64: existing.publicKeyB64 };
42
42
  if (deps.role !== "owner") {
@@ -46,19 +46,19 @@ function withAttestation() {
46
46
  return { keyId: signer.keyId, publicKeyB64: signer.publicKeyB64 };
47
47
  },
48
48
  async revokeAttestation(ctx, docId) {
49
- const { revokeDocCore: revokeDocCore2 } = await import("../revoke-NE4CU2T3.js");
49
+ const { revokeDocCore: revokeDocCore2 } = await import("../revoke-6KY4VGZY.js");
50
50
  return revokeDocCore2(ctx, docId);
51
51
  },
52
52
  async unrevokeAttestation(ctx, docId) {
53
- const { unrevokeDocCore: unrevokeDocCore2 } = await import("../revoke-NE4CU2T3.js");
53
+ const { unrevokeDocCore: unrevokeDocCore2 } = await import("../revoke-6KY4VGZY.js");
54
54
  return unrevokeDocCore2(ctx, docId);
55
55
  },
56
56
  async getRevokedDocIds(ctx) {
57
- const { getRevokedDocIdsCore: getRevokedDocIdsCore2 } = await import("../revoke-NE4CU2T3.js");
57
+ const { getRevokedDocIdsCore: getRevokedDocIdsCore2 } = await import("../revoke-6KY4VGZY.js");
58
58
  return getRevokedDocIdsCore2(ctx);
59
59
  },
60
60
  async publishRevocationList(ctx) {
61
- const { publishRevocationListCore: publishRevocationListCore2 } = await import("../revoke-NE4CU2T3.js");
61
+ const { publishRevocationListCore: publishRevocationListCore2 } = await import("../revoke-6KY4VGZY.js");
62
62
  return publishRevocationListCore2(ctx);
63
63
  }
64
64
  };
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-EPFF7LOX.js";
4
4
  import {
5
5
  SCHEMAS_COLLECTION
6
- } from "./chunk-FINIMZ55.js";
6
+ } from "./chunk-A3WHDOWI.js";
7
7
  import {
8
8
  PERIODS_COLLECTION,
9
9
  PERIOD_ARCHIVES_COLLECTION,
@@ -13,21 +13,22 @@ import {
13
13
  } from "./chunk-V4M4BZNW.js";
14
14
  import {
15
15
  SEQUENCE_COLLECTION
16
- } from "./chunk-4FNR5YZI.js";
16
+ } from "./chunk-RRMXMJUP.js";
17
17
  import {
18
18
  LEDGER_COLLECTION,
19
19
  LEDGER_DELTAS_COLLECTION
20
20
  } from "./chunk-I7FD46FF.js";
21
- import "./chunk-PWJSO7HH.js";
22
- import "./chunk-P3AFV6EA.js";
21
+ import "./chunk-LTVETWDH.js";
22
+ import {
23
+ buildRecordEnvelope
24
+ } from "./chunk-6E2JZRBD.js";
23
25
  import "./chunk-FSZPQCDR.js";
24
26
  import "./chunk-HVR74IBG.js";
25
27
  import "./chunk-RBTZLXZJ.js";
26
28
  import "./chunk-LP7BEXCT.js";
27
29
  import "./chunk-QTDAPDDV.js";
28
30
  import {
29
- NOYDB_BACKUP_VERSION,
30
- NOYDB_FORMAT_VERSION
31
+ NOYDB_BACKUP_VERSION
31
32
  } from "./chunk-SFY6NT7D.js";
32
33
  import {
33
34
  BackupCorruptedError,
@@ -124,13 +125,10 @@ async function loadVault(ctx, backupJson) {
124
125
  const backup = JSON.parse(backupJson);
125
126
  await ctx.adapter.saveAll(ctx.vault, backup.collections);
126
127
  for (const [userId, keyringFile] of Object.entries(backup.keyrings)) {
127
- const envelope = {
128
- _noydb: NOYDB_FORMAT_VERSION,
129
- _v: 1,
130
- _ts: (/* @__PURE__ */ new Date()).toISOString(),
131
- _iv: "",
132
- _data: JSON.stringify(keyringFile)
133
- };
128
+ const envelope = buildRecordEnvelope(
129
+ { collection: "_keyring", id: userId },
130
+ { version: 1, iv: "", data: JSON.stringify(keyringFile) }
131
+ );
134
132
  await ctx.adapter.put(ctx.vault, "_keyring", userId, envelope);
135
133
  }
136
134
  if (backup._internal) {
@@ -264,4 +262,4 @@ export {
264
262
  loadVault,
265
263
  verifyBackupIntegrity
266
264
  };
267
- //# sourceMappingURL=backup-BXS6GNCA.js.map
265
+ //# sourceMappingURL=backup-M2VND2VS.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/with-pod/backup.ts"],"sourcesContent":["/**\n * Vault backup / restore / integrity.\n *\n * Holds `dump()` (verifiable encrypted JSON backup, including the blob\n * collections so blob \"covers\" travel in the bundle), `load()` (restore +\n * post-load integrity gate), `verifyBackupIntegrity()` (chain + data-envelope\n * cross-check), and `exportJSON()` (plaintext per-collection export, built on\n * the vault's `exportStream`). Behaviour is byte-identical to the inline\n * `Vault` methods these functions replaced — every dependency the moving code\n * touched on `this.*` arrives via {@link BackupContext}. `Vault` keeps the\n * public methods as thin delegators.\n *\n * Internal — reached through `vault.dump()` / `vault.load()` / etc.\n */\nimport { NOYDB_BACKUP_VERSION } from '../kernel/types.js'\nimport { BackupLedgerError, BackupCorruptedError } from '../kernel/errors.js'\nimport { LEDGER_COLLECTION, LEDGER_DELTAS_COLLECTION } from '../with-commit/history/ledger/constants.js'\nimport { SCHEMAS_COLLECTION } from '../with-shape/persisted-schemas/storage.js'\nimport { SEQUENCE_COLLECTION } from '../with-commit/sequence/index.js'\nimport { MANIFEST_COLLECTION } from '../with-shape/manifest/reserved-collections.js'\n// #1025 — imported from the dependency-light `window.ts`, not `periods.ts`: that\n// module exists precisely so a consumer can name the period collections without\n// dragging the ledger hash-chain machinery (`sha256Hex`/`canonicalJson`) into a\n// bundle that opted out of the periods service. Same reason the sync engine's\n// period-scoped pull imports it.\nimport {\n PERIODS_COLLECTION,\n PERIOD_FREEZES_COLLECTION,\n PERIOD_ARCHIVES_COLLECTION,\n PERIOD_TARGET_PURGES_COLLECTION,\n PERIOD_REOPENS_COLLECTION,\n} from '../with-audit/periods/window.js'\nimport type {\n NoydbStore,\n EncryptedEnvelope,\n VaultBackup,\n VaultSnapshot,\n ExportStreamOptions,\n ExportChunk,\n} from '../kernel/types.js'\nimport type { LedgerStore } from '../with-commit/history/ledger/store.js'\nimport { buildRecordEnvelope } from '../kernel/enclave/index.js'\n\n/** Everything the moving backup methods touched on the vault's `this.*`. */\nexport interface BackupContext {\n /** The ciphertext store. */\n readonly adapter: NoydbStore\n /** Vault namespace name. */\n readonly vault: string\n /** The invoking keyring's user id (read fresh per call). */\n userId(): string\n /** The vault's ledger store, or null when history is off. */\n getLedgerOrNull(): LedgerStore | null\n /** Recompute an envelope's `payloadHash` (bound `historyStrategy.envelopePayloadHash`). */\n envelopePayloadHash(envelope: EncryptedEnvelope): Promise<string>\n /**\n * Refresh the in-memory keyring from the freshly-loaded keyring file and\n * rebuild the DEK resolver. No-op when the vault has no `reloadKeyring`\n * callback (plaintext vaults / test constructions).\n */\n reloadKeyringAndRebuildDEK(): Promise<void>\n /** Clear the vault's collection cache (post-load). */\n clearCollectionCache(): void\n /** Reset the ledger store so the next `ledger()` rebuilds its head cache. */\n resetLedgerStore(): void\n /** The vault's decrypt+ACL export stream (used by `exportJSON`). */\n exportStream(opts: ExportStreamOptions): AsyncIterableIterator<ExportChunk>\n}\n\n/** Result of {@link verifyBackupIntegrity}. */\nexport type VerifyBackupResult =\n | { readonly ok: true; readonly head: string; readonly length: number }\n | {\n readonly ok: false\n readonly kind: 'chain'\n readonly divergedAt: number\n readonly message: string\n }\n | {\n readonly ok: false\n readonly kind: 'data'\n readonly collection: string\n readonly id: string\n readonly message: string\n }\n\n/**\n * Dump vault as a verifiable encrypted JSON backup string.\n *\n * backups embed the current ledger head and the full `_ledger` +\n * `_ledger_deltas` internal collections so the receiver can run\n * `verifyBackupIntegrity()` after `load()` and detect any tampering between\n * dump and restore. Backups produced without a ledger skip the integrity check\n * with a warning — both modes round-trip cleanly.\n */\nexport async function dumpVault(ctx: BackupContext): Promise<string> {\n const snapshot = await ctx.adapter.loadAll(ctx.vault)\n\n // Load keyrings (separate path because loadAll filters them out\n // along with all other underscore-prefixed internal collections).\n const keyringIds = await ctx.adapter.list(ctx.vault, '_keyring')\n const keyrings: Record<string, unknown> = {}\n for (const keyringId of keyringIds) {\n const envelope = await ctx.adapter.get(ctx.vault, '_keyring', keyringId)\n if (envelope) {\n keyrings[keyringId] = JSON.parse(envelope._data)\n }\n }\n\n // Load the ledger entries + deltas so the receiver can replay\n // the chain after restore. Without this, `load()` would have an\n // empty ledger and `verifyBackupIntegrity()` would have nothing\n // to compare against.\n //\n // Also enumerate the blob collections so blob content (\"covers\")\n // travels in the bundle (the blob DEK already travels in `_keyring`).\n // Literals are inlined (not imported from blobs/blob-set.ts) to keep\n // the blob runtime out of this kernel hot path — they mirror\n // BLOB_INDEX/CHUNKS/EVICTION_AUDIT_COLLECTION and SLOTS/VERSIONS_PREFIX.\n // The collect-loop skips empty ids, so this no-ops without blobs.\n const internalSnapshot: VaultSnapshot = {}\n const internalNames = [\n LEDGER_COLLECTION, LEDGER_DELTAS_COLLECTION, SCHEMAS_COLLECTION, SEQUENCE_COLLECTION,\n MANIFEST_COLLECTION, // #941: the pod's manifest-set record(s) travel in the bundle too\n // #1025: the accounting-period close state + its companions. The bundle is\n // the backup/restore path, so without these a restore discarded the\n // hash-chained evidence that a month was ever closed — the artifact\n // `closePeriod` exists to produce — and dropped the write gate with it, so\n // the restored vault silently accepted back-dated writes into a sealed\n // month. The companions matter as much as the close: a bounded reopen\n // window (`reopenPeriod({ until })`) is state a restore must not lose.\n PERIODS_COLLECTION,\n PERIOD_REOPENS_COLLECTION,\n PERIOD_FREEZES_COLLECTION,\n PERIOD_ARCHIVES_COLLECTION,\n PERIOD_TARGET_PURGES_COLLECTION,\n '_history', // full-snapshot version history — so history()/getVersion()/diff() survive the bundle\n '_blob_index', '_blob_chunks', '_blob_eviction_audit',\n // #753 spec §7 Q3: `_blob_intent` markers travel too — restoring mid-op\n // state (a blob row without its marker) would reproduce the ambiguity\n // the journal exists to prevent. Note: `_mv_stale` does NOT travel\n // today (a pre-existing, separate gap) — observed here, tracked on\n // #761, not fixed in this pass.\n '_blob_intent',\n // #769: `_blob_slots_<c>` envelopes travel verbatim (raw ciphertext,\n // same DEK, same vault) — including any `SlotRecord.pendingRelease`\n // resume breadcrumb they carry. This is INTENTIONALLY the opposite of\n // `extract-partition`'s `reKeyBlobs`, which STRIPS `pendingRelease`:\n // a full-vault backup restores into the SAME vault it was taken from,\n // so a breadcrumb taken mid-rehome (together with its `_blob_intent`\n // marker, carried above) is resumable on restore — carry-and-resume is\n // correct here. A partition extraction crosses vaults: the breadcrumb's\n // old eTag may not exist in the destination, so it must be stripped\n // there instead. Asymmetry: backup = same-vault-resumable = carry;\n // partition = cross-vault = strip-breadcrumb-carry-marker.\n ...Object.keys(snapshot).flatMap((c) => [`_blob_slots_${c}`, `_blob_versions_${c}`]),\n ]\n for (const internalName of internalNames) {\n const ids = await ctx.adapter.list(ctx.vault, internalName)\n if (ids.length === 0) continue\n const records: Record<string, EncryptedEnvelope> = {}\n for (const id of ids) {\n const envelope = await ctx.adapter.get(ctx.vault, internalName, id)\n if (envelope) records[id] = envelope\n }\n internalSnapshot[internalName] = records\n }\n\n // Embed the ledger head if there's a chain. An empty ledger\n // (fresh vault) leaves `ledgerHead` undefined, which\n // load() treats the same as a legacy backup (no integrity\n // check, console warning). If history is not opted in,\n // `getLedgerOrNull` returns null and we skip embedding entirely\n // — the backup is still valid, just without the integrity head.\n const ledgerForHead = ctx.getLedgerOrNull()\n const head = ledgerForHead ? await ledgerForHead.head() : null\n const backup: VaultBackup = {\n _noydb_backup: NOYDB_BACKUP_VERSION,\n _compartment: ctx.vault,\n _exported_at: new Date().toISOString(),\n _exported_by: ctx.userId(),\n keyrings: keyrings as VaultBackup['keyrings'],\n collections: snapshot,\n ...(Object.keys(internalSnapshot).length > 0\n ? { _internal: internalSnapshot }\n : {}),\n ...(head\n ? {\n ledgerHead: {\n hash: head.hash,\n index: head.entry.index,\n ts: head.entry.ts,\n },\n }\n : {}),\n }\n\n return JSON.stringify(backup)\n}\n\n/**\n * Restore a vault from a verifiable backup. After loading, runs\n * `verifyBackupIntegrity()` to confirm the hash chain, the embedded head, and\n * every data envelope's payload hash. Legacy backups (no `ledgerHead`) load\n * with a console warning and skip the integrity check.\n */\nexport async function loadVault(ctx: BackupContext, backupJson: string): Promise<void> {\n const backup = JSON.parse(backupJson) as VaultBackup\n\n // 1. Restore data collections.\n await ctx.adapter.saveAll(ctx.vault, backup.collections)\n\n // 2. Restore keyrings.\n for (const [userId, keyringFile] of Object.entries(backup.keyrings)) {\n const envelope = buildRecordEnvelope({ collection: '_keyring', id: userId },\n { version: 1, iv: '', data: JSON.stringify(keyringFile) })\n await ctx.adapter.put(ctx.vault, '_keyring', userId, envelope)\n }\n\n // 3. Restore internal collections (`_ledger`, `_ledger_deltas`).\n // Required so verifyBackupIntegrity has the chain to walk.\n if (backup._internal) {\n for (const [internalName, records] of Object.entries(backup._internal)) {\n for (const [id, envelope] of Object.entries(records)) {\n await ctx.adapter.put(ctx.vault, internalName, id, envelope)\n }\n }\n }\n\n // 4. Refresh the in-memory keyring from the freshly-loaded\n // keyring file. Without this, the Vault's getDEK\n // closure still holds the OLD session's DEKs, and every\n // decrypt of a loaded ledger entry / data envelope fails\n // with TamperedError because the DEK doesn't match the\n // ciphertext that was encrypted with the SOURCE user's DEK.\n // Skipped for plaintext vaults and for tests that\n // construct Vault without a reloadKeyring callback.\n await ctx.reloadKeyringAndRebuildDEK()\n\n // 5. Clear collection cache + reset the ledger store so the\n // next ledger() call rebuilds its head cache from the\n // freshly-loaded entries.\n ctx.clearCollectionCache()\n ctx.resetLedgerStore()\n\n // 5. Run the verification gate. Legacy backups (no ledgerHead)\n // skip this with a one-line warning so existing consumers can\n // still read them while migrating.\n if (!backup.ledgerHead) {\n console.warn(\n `[noy-db] Loaded a legacy backup with no ledgerHead — ` +\n `verifiable-backup integrity check skipped. ` +\n `Re-export with a ledger-aware build to get tamper detection.`,\n )\n return\n }\n\n const result = await verifyBackupIntegrity(ctx)\n if (!result.ok) {\n // Surface the most specific error class we can. The result\n // shape carries enough info for callers to inspect.\n if (result.kind === 'data') {\n throw new BackupCorruptedError(\n result.collection,\n result.id,\n result.message,\n )\n }\n throw new BackupLedgerError(result.message, result.divergedAt)\n }\n\n // 6. Cross-check: the freshly-verified head must match the\n // value embedded at dump time. A mismatch means someone\n // truncated or extended the chain after dump.\n if (result.head !== backup.ledgerHead.hash) {\n throw new BackupLedgerError(\n `Backup ledger head mismatch: embedded \"${backup.ledgerHead.hash}\" ` +\n `but reconstructed \"${result.head}\".`,\n )\n }\n}\n\n/**\n * End-to-end backup integrity check: `ledger.verify()` (hash chain) plus a data\n * envelope cross-check (every current record's `_data` hash must match the\n * latest `put` entry's `payloadHash`). Returns a discriminated union so callers\n * can distinguish chain vs data failures.\n */\nexport async function verifyBackupIntegrity(ctx: BackupContext): Promise<VerifyBackupResult> {\n // Step 1: chain verification. Without the history strategy there\n // is no ledger; an unaudited backup verifies trivially as `ok`\n // because there's nothing to diverge from.\n const ledgerForVerify = ctx.getLedgerOrNull()\n if (!ledgerForVerify) {\n return { ok: true, head: '', length: 0 }\n }\n const chainResult = await ledgerForVerify.verify()\n if (!chainResult.ok) {\n return {\n ok: false,\n kind: 'chain',\n divergedAt: chainResult.divergedAt,\n message:\n `Ledger chain diverged at index ${chainResult.divergedAt}: ` +\n `expected prevHash \"${chainResult.expected}\" but found \"${chainResult.actual}\".`,\n }\n }\n\n // Step 2: data envelope cross-check. Walk every entry in the\n // ledger and, for the LATEST `put` per (collection, id), recompute\n // the data envelope's payloadHash and compare. Earlier puts of the\n // same id are skipped because the data collection only holds the\n // current version — historical envelopes live in the deltas\n // collection (which is itself protected by the chain).\n // Reuse the ledger we already resolved in step 1.\n const allEntries = await ledgerForVerify.loadAllEntries()\n\n // Find the latest non-delete entry per (collection, id). Walk\n // the entries in reverse so we hit the latest first; mark each\n // (collection, id) as seen and skip subsequent entries.\n const seen = new Set<string>()\n const latest = new Map<\n string,\n { collection: string; id: string; expectedHash: string }\n >()\n for (let i = allEntries.length - 1; i >= 0; i--) {\n const entry = allEntries[i]\n if (!entry) continue\n // Amendment entries are multi-record audit entries whose\n // `collection` and `id` are empty strings — building a `\"/\"`\n // key here would mark that synthetic slot as seen and falsely\n // trip the data check on a record that never existed. Skip\n // them BEFORE the key/seen bookkeeping so they neither\n // tombstone real entries nor enter the latest map.\n if (entry.op === 'amendment' || entry.op === 'lifecycle') continue\n const key = `${entry.collection}/${entry.id}`\n if (seen.has(key)) continue\n seen.add(key)\n // For deletes the data collection should NOT have the record,\n // so we skip — there's nothing to cross-check. Marking the key\n // as seen above ensures any earlier `put` of the same id is\n // also skipped (the record was subsequently deleted).\n if (entry.op === 'delete') continue\n latest.set(key, {\n collection: entry.collection,\n id: entry.id,\n expectedHash: entry.payloadHash,\n })\n }\n\n for (const { collection, id, expectedHash } of latest.values()) {\n const envelope = await ctx.adapter.get(ctx.vault, collection, id)\n if (!envelope) {\n return {\n ok: false,\n kind: 'data',\n collection,\n id,\n message:\n `Ledger expects data record \"${collection}/${id}\" to exist, ` +\n `but the adapter has no envelope for it.`,\n }\n }\n const actualHash = await ctx.envelopePayloadHash(envelope)\n if (actualHash !== expectedHash) {\n return {\n ok: false,\n kind: 'data',\n collection,\n id,\n message:\n `Data envelope \"${collection}/${id}\" has been tampered with: ` +\n `expected payloadHash \"${expectedHash}\", got \"${actualHash}\".`,\n }\n }\n }\n\n return {\n ok: true,\n head: chainResult.head,\n length: chainResult.length,\n }\n}\n\n/**\n * Plaintext per-collection export, built on the vault's `exportStream`. Forces\n * collection granularity (record-by-record output makes no sense in a single\n * string) and merges dictionary snapshots across collections.\n */\nexport async function exportVaultJSON(ctx: BackupContext, opts: ExportStreamOptions = {}): Promise<string> {\n // Force per-collection granularity regardless of caller setting:\n // record-by-record output doesn't make sense in a single string.\n const collections: Record<\n string,\n {\n schema: null\n refs: Record<string, { target: string; mode: 'strict' | 'warn' | 'cascade' }>\n records: unknown[]\n }\n > = {}\n let ledgerHead: ExportChunk['ledgerHead'] | undefined\n // Merged dictionary snapshot across all collections.\n // Only populated when `resolveLabels` is not set.\n const allDictionaries: Record<\n string, // collection name\n Record<string, Record<string, Record<string, string>>>\n > = {}\n\n for await (const chunk of ctx.exportStream({\n granularity: 'collection',\n withLedgerHead: opts.withLedgerHead === true,\n // Thread the export locale so records are read at the\n // `export` layer (i18nText collapsed + dictKey/staticDict labels resolved).\n ...(opts.resolveLabels !== undefined ? { resolveLabels: opts.resolveLabels } : {}),\n })) {\n collections[chunk.collection] = {\n schema: null, // Standard Schema validators are not JSON-serializable\n refs: chunk.refs,\n records: chunk.records,\n }\n if (chunk.ledgerHead) ledgerHead = chunk.ledgerHead\n // Collect dictionary snapshots unless resolveLabels is set\n if (!opts.resolveLabels && chunk.dictionaries) {\n allDictionaries[chunk.collection] = chunk.dictionaries\n }\n }\n\n const hasDictionaries = Object.keys(allDictionaries).length > 0\n return JSON.stringify({\n _noydb_export: 1,\n _compartment: ctx.vault,\n _exported_at: new Date().toISOString(),\n _exported_by: ctx.userId(),\n collections,\n ...(hasDictionaries ? { _dictionaries: allDictionaries } : {}),\n ...(ledgerHead ? { ledgerHead } : {}),\n })\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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IACjB;AACA,QAAI,MAAM,WAAY,cAAa,MAAM;AAEzC,QAAI,CAAC,KAAK,iBAAiB,MAAM,cAAc;AAC7C,sBAAgB,MAAM,UAAU,IAAI,MAAM;AAAA,IAC5C;AAAA,EACF;AAEA,QAAM,kBAAkB,OAAO,KAAK,eAAe,EAAE,SAAS;AAC9D,SAAO,KAAK,UAAU;AAAA,IACpB,eAAe;AAAA,IACf,cAAc,IAAI;AAAA,IAClB,eAAc,oBAAI,KAAK,GAAE,YAAY;AAAA,IACrC,cAAc,IAAI,OAAO;AAAA,IACzB;AAAA,IACA,GAAI,kBAAkB,EAAE,eAAe,gBAAgB,IAAI,CAAC;AAAA,IAC5D,GAAI,aAAa,EAAE,WAAW,IAAI,CAAC;AAAA,EACrC,CAAC;AACH;","names":[]}
@@ -16,7 +16,7 @@ import {
16
16
  detectMimeType,
17
17
  isPreCompressed,
18
18
  memoryBlobPinStore
19
- } from "../chunk-BPT4W6CI.js";
19
+ } from "../chunk-NY6RQBUN.js";
20
20
  import {
21
21
  BLOB_EVICTION_AUDIT_COLLECTION,
22
22
  EXPORT_AUDIT_COLLECTION,
@@ -28,8 +28,8 @@ import {
28
28
  import "../chunk-RVTOCAHQ.js";
29
29
  import "../chunk-YVOW35HH.js";
30
30
  import "../chunk-AMKCY454.js";
31
- import "../chunk-PWJSO7HH.js";
32
- import "../chunk-P3AFV6EA.js";
31
+ import "../chunk-LTVETWDH.js";
32
+ import "../chunk-6E2JZRBD.js";
33
33
  import "../chunk-FSZPQCDR.js";
34
34
  import "../chunk-HVR74IBG.js";
35
35
  import "../chunk-RBTZLXZJ.js";
@@ -4,8 +4,8 @@ import {
4
4
  import {
5
5
  issueChallenge,
6
6
  verifyBrokerProof
7
- } from "../chunk-PWJSO7HH.js";
8
- import "../chunk-P3AFV6EA.js";
7
+ } from "../chunk-LTVETWDH.js";
8
+ import "../chunk-6E2JZRBD.js";
9
9
  import "../chunk-FSZPQCDR.js";
10
10
  import "../chunk-HVR74IBG.js";
11
11
  import "../chunk-RBTZLXZJ.js";
@@ -30,7 +30,7 @@ function withBroker(config) {
30
30
  const cache = /* @__PURE__ */ new Map();
31
31
  return {
32
32
  async enroll(ctx) {
33
- const { enrollSeed } = await import("../seed-TC42KFUK.js");
33
+ const { enrollSeed } = await import("../seed-DGLQTCIO.js");
34
34
  return enrollSeed({ ...ctx, config });
35
35
  },
36
36
  async rotate(ctx) {
@@ -39,7 +39,7 @@ function withBroker(config) {
39
39
  const inFlight = scoped.map(([, e]) => e.inFlight).filter((p) => p !== void 0);
40
40
  await Promise.allSettled(inFlight);
41
41
  for (const [key] of scoped) cache.delete(key);
42
- const { rotateSeed } = await import("../seed-TC42KFUK.js");
42
+ const { rotateSeed } = await import("../seed-DGLQTCIO.js");
43
43
  return rotateSeed({ ...ctx, config });
44
44
  },
45
45
  credentialSource(ctx, profile) {
@@ -56,7 +56,7 @@ function withBroker(config) {
56
56
  const skewMs = config.skewMs ?? DEFAULT_SKEW_MS;
57
57
  const capturedEntry = entry;
58
58
  const inFlight = (async () => {
59
- const { mintStoreCredentials } = await import("../seed-TC42KFUK.js");
59
+ const { mintStoreCredentials } = await import("../seed-DGLQTCIO.js");
60
60
  const creds = await mintStoreCredentials({ ...ctx, config }, profile);
61
61
  capturedEntry.cached = { creds, validUntil: cacheFloor(creds, skewMs) };
62
62
  return creds;
@@ -6,35 +6,35 @@ import {
6
6
  diffVault,
7
7
  unsealDeks,
8
8
  withCargo
9
- } from "../chunk-A5BGC3GR.js";
9
+ } from "../chunk-6EF3N2MH.js";
10
10
  import {
11
11
  extractPartition,
12
12
  walkClosure
13
- } from "../chunk-ELHNLDXB.js";
13
+ } from "../chunk-MKSTUVMJ.js";
14
14
  import {
15
15
  createDeedOwner,
16
16
  isDeedVault,
17
17
  liberateVault,
18
18
  loadDeedMarker
19
- } from "../chunk-6N5PZ6G5.js";
20
- import "../chunk-WVCOS4XA.js";
21
- import "../chunk-HAN2PHLM.js";
22
- import "../chunk-BPT4W6CI.js";
19
+ } from "../chunk-H5U4T6JK.js";
20
+ import "../chunk-TY6N3PAC.js";
21
+ import "../chunk-TWPTRJEU.js";
22
+ import "../chunk-NY6RQBUN.js";
23
23
  import {
24
24
  groupAndReduce,
25
25
  reduceRecords
26
- } from "../chunk-ESABIXMQ.js";
26
+ } from "../chunk-3JQVA527.js";
27
27
  import {
28
28
  NO_CARGO,
29
29
  isQuorum,
30
30
  runDrainBarrier
31
31
  } from "../chunk-42IDLU5V.js";
32
32
  import "../chunk-55B3KHZW.js";
33
- import "../chunk-FINIMZ55.js";
33
+ import "../chunk-A3WHDOWI.js";
34
34
  import {
35
35
  CustodyApi
36
- } from "../chunk-LAVPHX2V.js";
37
- import "../chunk-T7XUDZ7N.js";
36
+ } from "../chunk-IGE6XWKK.js";
37
+ import "../chunk-THUITYH7.js";
38
38
  import "../chunk-I5OLA3H6.js";
39
39
  import {
40
40
  fuseRetrieval
@@ -44,21 +44,21 @@ import "../chunk-CADUYBQD.js";
44
44
  import {
45
45
  readPath
46
46
  } from "../chunk-IGJCYUT5.js";
47
- import "../chunk-SZZEDEIU.js";
47
+ import "../chunk-7LLKPODL.js";
48
48
  import "../chunk-RVTOCAHQ.js";
49
- import "../chunk-RERAMZK5.js";
50
- import "../chunk-PNEV2TBR.js";
49
+ import "../chunk-LJDW6LQJ.js";
50
+ import "../chunk-PZLIA5R3.js";
51
51
  import "../chunk-YVOW35HH.js";
52
52
  import {
53
53
  generateULID
54
54
  } from "../chunk-4AOERLTV.js";
55
55
  import "../chunk-SVLR4POP.js";
56
- import "../chunk-RQ5G2YER.js";
56
+ import "../chunk-5TF5DUQ5.js";
57
57
  import "../chunk-I7FD46FF.js";
58
58
  import "../chunk-AMKCY454.js";
59
- import "../chunk-62KVBIBU.js";
60
- import "../chunk-PWJSO7HH.js";
61
- import "../chunk-P3AFV6EA.js";
59
+ import "../chunk-53PWELSC.js";
60
+ import "../chunk-LTVETWDH.js";
61
+ import "../chunk-6E2JZRBD.js";
62
62
  import "../chunk-FSZPQCDR.js";
63
63
  import "../chunk-HVR74IBG.js";
64
64
  import "../chunk-RBTZLXZJ.js";
@@ -5,7 +5,7 @@ import {
5
5
  buildStringFieldEntries,
6
6
  extractSnippet,
7
7
  searchScan
8
- } from "./chunk-KNAZGJFG.js";
8
+ } from "./chunk-4JDTLWUZ.js";
9
9
  import {
10
10
  fuseRetrieval
11
11
  } from "./chunk-AURFOK3D.js";
@@ -13,7 +13,7 @@ import {
13
13
  getAtPath,
14
14
  isStaticDictDescriptor,
15
15
  stripI18nFilled
16
- } from "./chunk-SZZEDEIU.js";
16
+ } from "./chunk-7LLKPODL.js";
17
17
  import {
18
18
  liveRecordIsElevated
19
19
  } from "./chunk-AMKCY454.js";
@@ -394,4 +394,4 @@ export {
394
394
  rebuildEmbeddings,
395
395
  syncTierSearch
396
396
  };
397
- //# sourceMappingURL=chunk-X24QHSG5.js.map
397
+ //# sourceMappingURL=chunk-343FH4S5.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  openEnvelopeJson
3
- } from "./chunk-PWJSO7HH.js";
3
+ } from "./chunk-LTVETWDH.js";
4
4
  import {
5
5
  encrypt,
6
6
  hmacSha256Hex,
@@ -147,4 +147,4 @@ export {
147
147
  coerceSubjectId,
148
148
  readDottedPath
149
149
  };
150
- //# sourceMappingURL=chunk-6R4QXE43.js.map
150
+ //# sourceMappingURL=chunk-35RIRCGW.js.map
@@ -9,7 +9,7 @@ import {
9
9
  } from "./chunk-IGJCYUT5.js";
10
10
  import {
11
11
  applyI18nLocale
12
- } from "./chunk-SZZEDEIU.js";
12
+ } from "./chunk-7LLKPODL.js";
13
13
  import {
14
14
  viaBinder
15
15
  } from "./chunk-RVTOCAHQ.js";
@@ -361,4 +361,4 @@ export {
361
361
  groupAndReduce,
362
362
  GroupedReduction
363
363
  };
364
- //# sourceMappingURL=chunk-ESABIXMQ.js.map
364
+ //# sourceMappingURL=chunk-3JQVA527.js.map
@@ -7,7 +7,7 @@ import {
7
7
  deriveSchemaManifest,
8
8
  loadSchemaManifestEntry,
9
9
  saveSchemaManifest
10
- } from "./chunk-U26JILS3.js";
10
+ } from "./chunk-WMZQCXZ5.js";
11
11
  import {
12
12
  MANIFEST_COLLECTION
13
13
  } from "./chunk-EPFF7LOX.js";
@@ -21,10 +21,10 @@ import {
21
21
  import {
22
22
  loadPersistedSchemaEntry,
23
23
  savePersistedSchema
24
- } from "./chunk-FINIMZ55.js";
24
+ } from "./chunk-A3WHDOWI.js";
25
25
  import {
26
26
  envelopePayloadHash
27
- } from "./chunk-62KVBIBU.js";
27
+ } from "./chunk-53PWELSC.js";
28
28
  import {
29
29
  ManifestConflictError,
30
30
  isConflictError
@@ -257,4 +257,4 @@ export {
257
257
  persistClassifiedMarker,
258
258
  persistSatelliteMarker
259
259
  };
260
- //# sourceMappingURL=chunk-PF3E6ABL.js.map
260
+ //# sourceMappingURL=chunk-3OEWD45V.js.map
@@ -4,7 +4,7 @@ import {
4
4
  } from "./chunk-S6CP5FWF.js";
5
5
  import {
6
6
  openEnvelopeJson
7
- } from "./chunk-PWJSO7HH.js";
7
+ } from "./chunk-LTVETWDH.js";
8
8
  import {
9
9
  encrypt
10
10
  } from "./chunk-QTDAPDDV.js";
@@ -127,4 +127,4 @@ export {
127
127
  LinkSet,
128
128
  LinkEndpointError
129
129
  };
130
- //# sourceMappingURL=chunk-5AV6FENP.js.map
130
+ //# sourceMappingURL=chunk-4CSG6KBX.js.map
@@ -8,10 +8,10 @@ import {
8
8
  } from "./chunk-JU3JKOY5.js";
9
9
  import {
10
10
  groupAndReduce
11
- } from "./chunk-ESABIXMQ.js";
11
+ } from "./chunk-3JQVA527.js";
12
12
  import {
13
13
  putDerivedOutput
14
- } from "./chunk-5CK7VSSK.js";
14
+ } from "./chunk-OPGKH5RD.js";
15
15
  import {
16
16
  DEFAULT_JOIN_MAX_ROWS
17
17
  } from "./chunk-QI2KXQOM.js";
@@ -20,7 +20,7 @@ import {
20
20
  } from "./chunk-XZHEOSQ2.js";
21
21
  import {
22
22
  applyI18nLocale
23
- } from "./chunk-SZZEDEIU.js";
23
+ } from "./chunk-7LLKPODL.js";
24
24
  import {
25
25
  JoinTooLargeError,
26
26
  LocaleNotSpecifiedError,
@@ -307,4 +307,4 @@ async function listOutputIds(outputColl) {
307
307
  export {
308
308
  MaterializedViewExecutor
309
309
  };
310
- //# sourceMappingURL=chunk-MMXMJXAE.js.map
310
+ //# sourceMappingURL=chunk-4DJQU3PH.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  getAtPath
3
- } from "./chunk-SZZEDEIU.js";
3
+ } from "./chunk-7LLKPODL.js";
4
4
  import {
5
5
  SearchNotEnabledError
6
6
  } from "./chunk-I64WQSN3.js";
@@ -294,31 +294,31 @@ function buildBlobFieldEntries(filenamesByField) {
294
294
  function withSearch() {
295
295
  return {
296
296
  async search(ctx, field, query, opts) {
297
- const { search } = await import("./collection-facade-YCJHWX64.js");
297
+ const { search } = await import("./collection-facade-KN3UFKZ4.js");
298
298
  return search(ctx, field, query, opts);
299
299
  },
300
300
  async retrieve(ctx, query, opts) {
301
- const { retrieve } = await import("./collection-facade-YCJHWX64.js");
301
+ const { retrieve } = await import("./collection-facade-KN3UFKZ4.js");
302
302
  return retrieve(ctx, query, opts);
303
303
  },
304
304
  async similarTo(ctx, vector, opts) {
305
- const { similarTo } = await import("./collection-facade-YCJHWX64.js");
305
+ const { similarTo } = await import("./collection-facade-KN3UFKZ4.js");
306
306
  return similarTo(ctx, vector, opts);
307
307
  },
308
308
  async warmIndex(ctx) {
309
- const { warmIndex } = await import("./collection-facade-YCJHWX64.js");
309
+ const { warmIndex } = await import("./collection-facade-KN3UFKZ4.js");
310
310
  return warmIndex(ctx);
311
311
  },
312
312
  async flushIndex(ctx) {
313
- const { flushIndex } = await import("./collection-facade-YCJHWX64.js");
313
+ const { flushIndex } = await import("./collection-facade-KN3UFKZ4.js");
314
314
  return flushIndex(ctx);
315
315
  },
316
316
  async embedOnWrite(ctx, id, record, version) {
317
- const { embedOnWrite } = await import("./collection-facade-YCJHWX64.js");
317
+ const { embedOnWrite } = await import("./collection-facade-KN3UFKZ4.js");
318
318
  return embedOnWrite(ctx, id, record, version);
319
319
  },
320
320
  async rebuildEmbeddings(ctx) {
321
- const { rebuildEmbeddings } = await import("./collection-facade-YCJHWX64.js");
321
+ const { rebuildEmbeddings } = await import("./collection-facade-KN3UFKZ4.js");
322
322
  return rebuildEmbeddings(ctx);
323
323
  }
324
324
  };
@@ -364,4 +364,4 @@ export {
364
364
  buildBlobFieldEntries,
365
365
  withSearch
366
366
  };
367
- //# sourceMappingURL=chunk-KNAZGJFG.js.map
367
+ //# sourceMappingURL=chunk-4JDTLWUZ.js.map
@@ -4,7 +4,7 @@ import {
4
4
  persistUserVisibility,
5
5
  readUserVisibility,
6
6
  saveUserEnvelope
7
- } from "./chunk-PNEV2TBR.js";
7
+ } from "./chunk-PZLIA5R3.js";
8
8
  import {
9
9
  PolicyDeniedError
10
10
  } from "./chunk-I64WQSN3.js";
@@ -379,4 +379,4 @@ export {
379
379
  UserApi,
380
380
  createUserApi
381
381
  };
382
- //# sourceMappingURL=chunk-GWJNBTZA.js.map
382
+ //# sourceMappingURL=chunk-4XEUSZWN.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  envelopeBodyForHash
3
- } from "./chunk-PWJSO7HH.js";
3
+ } from "./chunk-LTVETWDH.js";
4
4
  import {
5
5
  sha256Hex
6
6
  } from "./chunk-QTDAPDDV.js";
@@ -67,4 +67,4 @@ export {
67
67
  parseIndex,
68
68
  envelopePayloadHash
69
69
  };
70
- //# sourceMappingURL=chunk-62KVBIBU.js.map
70
+ //# sourceMappingURL=chunk-53PWELSC.js.map
@@ -10,18 +10,18 @@ import {
10
10
  } from "./chunk-V4M4BZNW.js";
11
11
  import {
12
12
  envelopeBodySize
13
- } from "./chunk-PWJSO7HH.js";
13
+ } from "./chunk-LTVETWDH.js";
14
14
  import {
15
+ buildRecordEnvelope,
15
16
  isDeleteMarker,
16
17
  isTombstoneShape
17
- } from "./chunk-P3AFV6EA.js";
18
+ } from "./chunk-6E2JZRBD.js";
18
19
  import {
19
20
  decrypt,
20
21
  derivePresenceKey,
21
22
  encrypt
22
23
  } from "./chunk-QTDAPDDV.js";
23
24
  import {
24
- NOYDB_FORMAT_VERSION,
25
25
  NOYDB_SYNC_VERSION
26
26
  } from "./chunk-SFY6NT7D.js";
27
27
  import {
@@ -234,13 +234,10 @@ var PresenceHandle = class {
234
234
  const record = { lastSeen: now, iv, data };
235
235
  const json = JSON.stringify(record);
236
236
  const storeAdapter = this.syncAdapter ?? this.adapter;
237
- const envelope = {
238
- _noydb: NOYDB_FORMAT_VERSION,
239
- _v: 1,
240
- _ts: now,
241
- _iv: "",
242
- _data: json
243
- };
237
+ const envelope = buildRecordEnvelope(
238
+ { collection: this.storageCollection, id: recordId },
239
+ { version: 1, ts: now, iv: "", data: json }
240
+ );
244
241
  try {
245
242
  await storeAdapter.put(
246
243
  this.vault,
@@ -1118,13 +1115,10 @@ var SyncEngine = class {
1118
1115
  last_pull: this.lastPull,
1119
1116
  dirty: this.dirty
1120
1117
  };
1121
- const envelope = {
1122
- _noydb: NOYDB_FORMAT_VERSION,
1123
- _v: 1,
1124
- _ts: (/* @__PURE__ */ new Date()).toISOString(),
1125
- _iv: "",
1126
- _data: JSON.stringify(meta)
1127
- };
1118
+ const envelope = buildRecordEnvelope(
1119
+ { collection: "_sync", id: "meta" },
1120
+ { version: 1, iv: "", data: JSON.stringify(meta) }
1121
+ );
1128
1122
  await this.local.put(this.vault, "_sync", "meta", envelope);
1129
1123
  }
1130
1124
  };
@@ -1192,4 +1186,4 @@ export {
1192
1186
  SyncEngine,
1193
1187
  SyncTransaction
1194
1188
  };
1195
- //# sourceMappingURL=chunk-AIR3LSJH.js.map
1189
+ //# sourceMappingURL=chunk-56W3T5O2.js.map