cojson 0.13.17 → 0.13.18

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 (166) hide show
  1. package/.turbo/turbo-build.log +1 -1
  2. package/CHANGELOG.md +9 -0
  3. package/dist/PeerState.d.ts +3 -0
  4. package/dist/PeerState.d.ts.map +1 -1
  5. package/dist/PeerState.js +9 -0
  6. package/dist/PeerState.js.map +1 -1
  7. package/dist/SyncStateManager.d.ts.map +1 -1
  8. package/dist/SyncStateManager.js +2 -3
  9. package/dist/SyncStateManager.js.map +1 -1
  10. package/dist/coValue.d.ts +4 -4
  11. package/dist/coValue.d.ts.map +1 -1
  12. package/dist/coValue.js +4 -4
  13. package/dist/coValue.js.map +1 -1
  14. package/dist/coValueCore/coValueCore.d.ts +143 -0
  15. package/dist/coValueCore/coValueCore.d.ts.map +1 -0
  16. package/dist/{coValueCore.js → coValueCore/coValueCore.js} +314 -246
  17. package/dist/coValueCore/coValueCore.js.map +1 -0
  18. package/dist/coValueCore/verifiedState.d.ts +65 -0
  19. package/dist/coValueCore/verifiedState.d.ts.map +1 -0
  20. package/dist/coValueCore/verifiedState.js +210 -0
  21. package/dist/coValueCore/verifiedState.js.map +1 -0
  22. package/dist/coValues/account.d.ts +8 -10
  23. package/dist/coValues/account.d.ts.map +1 -1
  24. package/dist/coValues/account.js +12 -13
  25. package/dist/coValues/account.js.map +1 -1
  26. package/dist/coValues/coList.d.ts +3 -3
  27. package/dist/coValues/coList.d.ts.map +1 -1
  28. package/dist/coValues/coList.js +6 -3
  29. package/dist/coValues/coList.js.map +1 -1
  30. package/dist/coValues/coMap.d.ts +3 -3
  31. package/dist/coValues/coMap.d.ts.map +1 -1
  32. package/dist/coValues/coMap.js +3 -3
  33. package/dist/coValues/coMap.js.map +1 -1
  34. package/dist/coValues/coPlainText.d.ts +2 -2
  35. package/dist/coValues/coPlainText.d.ts.map +1 -1
  36. package/dist/coValues/coPlainText.js +4 -4
  37. package/dist/coValues/coPlainText.js.map +1 -1
  38. package/dist/coValues/coStream.d.ts +3 -3
  39. package/dist/coValues/coStream.d.ts.map +1 -1
  40. package/dist/coValues/coStream.js +3 -3
  41. package/dist/coValues/coStream.js.map +1 -1
  42. package/dist/coValues/group.d.ts +7 -2
  43. package/dist/coValues/group.d.ts.map +1 -1
  44. package/dist/coValues/group.js +29 -26
  45. package/dist/coValues/group.js.map +1 -1
  46. package/dist/coreToCoValue.d.ts +2 -2
  47. package/dist/coreToCoValue.d.ts.map +1 -1
  48. package/dist/coreToCoValue.js +10 -14
  49. package/dist/coreToCoValue.js.map +1 -1
  50. package/dist/exports.d.ts +6 -5
  51. package/dist/exports.d.ts.map +1 -1
  52. package/dist/exports.js +3 -4
  53. package/dist/exports.js.map +1 -1
  54. package/dist/localNode.d.ts +30 -24
  55. package/dist/localNode.d.ts.map +1 -1
  56. package/dist/localNode.js +139 -170
  57. package/dist/localNode.js.map +1 -1
  58. package/dist/permissions.d.ts +2 -1
  59. package/dist/permissions.d.ts.map +1 -1
  60. package/dist/permissions.js +15 -11
  61. package/dist/permissions.js.map +1 -1
  62. package/dist/priority.d.ts +1 -1
  63. package/dist/priority.d.ts.map +1 -1
  64. package/dist/sync.d.ts +2 -2
  65. package/dist/sync.d.ts.map +1 -1
  66. package/dist/sync.js +86 -55
  67. package/dist/sync.js.map +1 -1
  68. package/dist/tests/coList.test.js +19 -16
  69. package/dist/tests/coList.test.js.map +1 -1
  70. package/dist/tests/coMap.test.js +12 -13
  71. package/dist/tests/coMap.test.js.map +1 -1
  72. package/dist/tests/coPlainText.test.js +9 -10
  73. package/dist/tests/coPlainText.test.js.map +1 -1
  74. package/dist/tests/coStream.test.js +22 -17
  75. package/dist/tests/coStream.test.js.map +1 -1
  76. package/dist/tests/coValueCore.test.js +22 -28
  77. package/dist/tests/coValueCore.test.js.map +1 -1
  78. package/dist/tests/coValueCoreLoadingState.test.d.ts +2 -0
  79. package/dist/tests/coValueCoreLoadingState.test.d.ts.map +1 -0
  80. package/dist/tests/{coValueState.test.js → coValueCoreLoadingState.test.js} +62 -46
  81. package/dist/tests/coValueCoreLoadingState.test.js.map +1 -0
  82. package/dist/tests/group.test.js +42 -43
  83. package/dist/tests/group.test.js.map +1 -1
  84. package/dist/tests/messagesTestUtils.d.ts +2 -2
  85. package/dist/tests/messagesTestUtils.d.ts.map +1 -1
  86. package/dist/tests/messagesTestUtils.js +1 -1
  87. package/dist/tests/messagesTestUtils.js.map +1 -1
  88. package/dist/tests/permissions.test.js +224 -292
  89. package/dist/tests/permissions.test.js.map +1 -1
  90. package/dist/tests/priority.test.js +13 -14
  91. package/dist/tests/priority.test.js.map +1 -1
  92. package/dist/tests/sync.auth.test.d.ts +2 -0
  93. package/dist/tests/sync.auth.test.d.ts.map +1 -0
  94. package/dist/tests/sync.auth.test.js +141 -0
  95. package/dist/tests/sync.auth.test.js.map +1 -0
  96. package/dist/tests/sync.load.test.js +4 -4
  97. package/dist/tests/sync.load.test.js.map +1 -1
  98. package/dist/tests/sync.mesh.test.js +25 -12
  99. package/dist/tests/sync.mesh.test.js.map +1 -1
  100. package/dist/tests/sync.peerReconciliation.test.js +19 -19
  101. package/dist/tests/sync.peerReconciliation.test.js.map +1 -1
  102. package/dist/tests/sync.storage.test.js +20 -13
  103. package/dist/tests/sync.storage.test.js.map +1 -1
  104. package/dist/tests/sync.test.js +32 -39
  105. package/dist/tests/sync.test.js.map +1 -1
  106. package/dist/tests/sync.upload.test.js +126 -37
  107. package/dist/tests/sync.upload.test.js.map +1 -1
  108. package/dist/tests/testUtils.d.ts +24 -15
  109. package/dist/tests/testUtils.d.ts.map +1 -1
  110. package/dist/tests/testUtils.js +88 -61
  111. package/dist/tests/testUtils.js.map +1 -1
  112. package/dist/typeUtils/expectGroup.js +1 -1
  113. package/dist/typeUtils/expectGroup.js.map +1 -1
  114. package/package.json +1 -1
  115. package/src/PeerState.ts +11 -0
  116. package/src/SyncStateManager.ts +2 -3
  117. package/src/coValue.ts +11 -8
  118. package/src/{coValueCore.ts → coValueCore/coValueCore.ts} +469 -413
  119. package/src/coValueCore/verifiedState.ts +376 -0
  120. package/src/coValues/account.ts +20 -25
  121. package/src/coValues/coList.ts +12 -6
  122. package/src/coValues/coMap.ts +9 -6
  123. package/src/coValues/coPlainText.ts +9 -6
  124. package/src/coValues/coStream.ts +9 -6
  125. package/src/coValues/group.ts +50 -28
  126. package/src/coreToCoValue.ts +14 -15
  127. package/src/exports.ts +9 -7
  128. package/src/localNode.ts +227 -273
  129. package/src/permissions.ts +18 -12
  130. package/src/priority.ts +1 -1
  131. package/src/sync.ts +96 -63
  132. package/src/tests/coList.test.ts +21 -15
  133. package/src/tests/coMap.test.ts +12 -13
  134. package/src/tests/coPlainText.test.ts +12 -9
  135. package/src/tests/coStream.test.ts +25 -16
  136. package/src/tests/coValueCore.test.ts +30 -27
  137. package/src/tests/{coValueState.test.ts → coValueCoreLoadingState.test.ts} +67 -57
  138. package/src/tests/group.test.ts +44 -68
  139. package/src/tests/messagesTestUtils.ts +3 -8
  140. package/src/tests/permissions.test.ts +283 -449
  141. package/src/tests/priority.test.ts +17 -13
  142. package/src/tests/sync.auth.test.ts +188 -0
  143. package/src/tests/sync.load.test.ts +4 -4
  144. package/src/tests/sync.mesh.test.ts +25 -12
  145. package/src/tests/sync.peerReconciliation.test.ts +25 -25
  146. package/src/tests/sync.storage.test.ts +20 -13
  147. package/src/tests/sync.test.ts +43 -43
  148. package/src/tests/sync.upload.test.ts +157 -37
  149. package/src/tests/testUtils.ts +120 -74
  150. package/src/typeUtils/expectGroup.ts +1 -1
  151. package/dist/CoValuesStore.d.ts +0 -14
  152. package/dist/CoValuesStore.d.ts.map +0 -1
  153. package/dist/CoValuesStore.js +0 -32
  154. package/dist/CoValuesStore.js.map +0 -1
  155. package/dist/coValueCore.d.ts +0 -142
  156. package/dist/coValueCore.d.ts.map +0 -1
  157. package/dist/coValueCore.js.map +0 -1
  158. package/dist/coValueState.d.ts +0 -34
  159. package/dist/coValueState.d.ts.map +0 -1
  160. package/dist/coValueState.js +0 -190
  161. package/dist/coValueState.js.map +0 -1
  162. package/dist/tests/coValueState.test.d.ts +0 -2
  163. package/dist/tests/coValueState.test.d.ts.map +0 -1
  164. package/dist/tests/coValueState.test.js.map +0 -1
  165. package/src/CoValuesStore.ts +0 -41
  166. package/src/coValueState.ts +0 -245
@@ -1,7 +1,17 @@
1
1
  import { base58 } from "@scure/base";
2
2
  import { CoID } from "../coValue.js";
3
- import { CoValueUniqueness } from "../coValueCore.js";
4
- import { Encrypted, KeyID, KeySecret, Sealed } from "../crypto/crypto.js";
3
+ import {
4
+ AvailableCoValueCore,
5
+ CoValueCore,
6
+ } from "../coValueCore/coValueCore.js";
7
+ import { CoValueUniqueness } from "../coValueCore/verifiedState.js";
8
+ import {
9
+ CryptoProvider,
10
+ Encrypted,
11
+ KeyID,
12
+ KeySecret,
13
+ Sealed,
14
+ } from "../crypto/crypto.js";
5
15
  import {
6
16
  AgentID,
7
17
  ChildGroupReference,
@@ -17,6 +27,7 @@ import { logger } from "../logger.js";
17
27
  import { AccountRole, Role } from "../permissions.js";
18
28
  import { expectGroup } from "../typeUtils/expectGroup.js";
19
29
  import {
30
+ ControlledAccount,
20
31
  ControlledAccountOrAgent,
21
32
  RawAccount,
22
33
  RawAccountID,
@@ -77,6 +88,18 @@ export type GroupShape = {
77
88
  export class RawGroup<
78
89
  Meta extends JsonObject | null = JsonObject | null,
79
90
  > extends RawCoMap<GroupShape, Meta> {
91
+ protected readonly crypto: CryptoProvider;
92
+
93
+ constructor(
94
+ core: AvailableCoValueCore,
95
+ options?: {
96
+ ignorePrivateTransactions: boolean;
97
+ },
98
+ ) {
99
+ super(core, options);
100
+ this.crypto = core.node.crypto;
101
+ }
102
+
80
103
  /**
81
104
  * Returns the current role of a given account.
82
105
  *
@@ -174,7 +197,6 @@ export class RawGroup<
174
197
 
175
198
  loadAllChildGroups() {
176
199
  const requests: Promise<unknown>[] = [];
177
- const store = this.core.node.coValuesStore;
178
200
  const peers = this.core.node.syncManager.getServerAndStoragePeers();
179
201
 
180
202
  for (const key of this.keys()) {
@@ -183,11 +205,11 @@ export class RawGroup<
183
205
  }
184
206
 
185
207
  const id = getChildGroupId(key);
186
- const child = store.get(id);
208
+ const child = this.core.node.getCoValue(id);
187
209
 
188
210
  if (
189
- child.highLevelState === "unknown" ||
190
- child.highLevelState === "unavailable"
211
+ child.loadingState === "unknown" ||
212
+ child.loadingState === "unavailable"
191
213
  ) {
192
214
  child.loadFromPeers(peers).catch(() => {
193
215
  logger.error(`Failed to load child group ${id}`);
@@ -195,8 +217,8 @@ export class RawGroup<
195
217
  }
196
218
 
197
219
  requests.push(
198
- child.getCoValue().then((coValue) => {
199
- if (coValue === "unavailable") {
220
+ child.waitForAvailableOrUnavailable().then((coValue) => {
221
+ if (!coValue.isAvailable()) {
200
222
  throw new Error(`Child group ${child.id} is unavailable`);
201
223
  }
202
224
 
@@ -236,7 +258,7 @@ export class RawGroup<
236
258
  * @category 1. Role reading
237
259
  */
238
260
  myRole(): Role | undefined {
239
- return this.roleOfInternal(this.core.node.account.id);
261
+ return this.roleOfInternal(this.core.node.getCurrentAgent().id);
240
262
  }
241
263
 
242
264
  /**
@@ -357,7 +379,7 @@ export class RawGroup<
357
379
  memberKey: RawAccountID | AgentID,
358
380
  agent: AgentID,
359
381
  ) {
360
- const writeKeyForNewMember = this.core.crypto.newRandomKeySecret();
382
+ const writeKeyForNewMember = this.crypto.newRandomKeySecret();
361
383
 
362
384
  this.set(`writeKeyFor_${memberKey}`, writeKeyForNewMember.id, "trusting");
363
385
 
@@ -404,10 +426,10 @@ export class RawGroup<
404
426
  ) {
405
427
  this.set(
406
428
  `${keyID}_for_${memberKey}`,
407
- this.core.crypto.seal({
429
+ this.crypto.seal({
408
430
  message: secret,
409
- from: this.core.node.account.currentSealerSecret(),
410
- to: this.core.crypto.getAgentSealerID(agent),
431
+ from: this.core.node.getCurrentAgent().currentSealerSecret(),
432
+ to: this.crypto.getAgentSealerID(agent),
411
433
  nOnceMaterial: {
412
434
  in: this.id,
413
435
  tx: this.core.nextTransactionID(),
@@ -433,7 +455,7 @@ export class RawGroup<
433
455
 
434
456
  getCurrentReadKeyId() {
435
457
  if (this.myRole() === "writeOnly") {
436
- const accountId = this.core.node.account.id;
458
+ const accountId = this.core.node.getCurrentAgent().id;
437
459
 
438
460
  const key = this.get(`writeKeyFor_${accountId}`) as KeyID;
439
461
 
@@ -441,7 +463,7 @@ export class RawGroup<
441
463
  if (!key && this.get("everyone") === "writeOnly") {
442
464
  this.internalCreateWriteOnlyKeyForMember(
443
465
  accountId,
444
- this.core.node.account.currentAgentID(),
466
+ this.core.node.getCurrentAgent().currentAgentID(),
445
467
  );
446
468
 
447
469
  return this.get(`writeKeyFor_${accountId}`) as KeyID;
@@ -509,7 +531,7 @@ export class RawGroup<
509
531
  secret: maybeCurrentReadKey.secret,
510
532
  };
511
533
 
512
- const newReadKey = this.core.crypto.newRandomKeySecret();
534
+ const newReadKey = this.crypto.newRandomKeySecret();
513
535
 
514
536
  for (const readerID of currentlyPermittedReaders) {
515
537
  const agent = this.core.node
@@ -539,7 +561,7 @@ export class RawGroup<
539
561
  )
540
562
  ._unsafeUnwrap({ withStackTrace: true });
541
563
 
542
- const writeOnlyKey = this.core.crypto.newRandomKeySecret();
564
+ const writeOnlyKey = this.crypto.newRandomKeySecret();
543
565
 
544
566
  this.storeKeyRevelationForMember(
545
567
  writeOnlyMemberID,
@@ -568,7 +590,7 @@ export class RawGroup<
568
590
 
569
591
  this.set(
570
592
  `${currentReadKey.id}_for_${newReadKey.id}`,
571
- this.core.crypto.encryptKeySecret({
593
+ this.crypto.encryptKeySecret({
572
594
  encrypting: newReadKey,
573
595
  toEncrypt: currentReadKey,
574
596
  }).encrypted,
@@ -594,7 +616,7 @@ export class RawGroup<
594
616
 
595
617
  this.set(
596
618
  `${newReadKey.id}_for_${parentReadKeyID}`,
597
- this.core.crypto.encryptKeySecret({
619
+ this.crypto.encryptKeySecret({
598
620
  encrypting: {
599
621
  id: parentReadKeyID,
600
622
  secret: parentReadKeySecret,
@@ -678,7 +700,7 @@ export class RawGroup<
678
700
 
679
701
  this.set(
680
702
  `${childReadKeyID}_for_${parentReadKeyID}`,
681
- this.core.crypto.encryptKeySecret({
703
+ this.crypto.encryptKeySecret({
682
704
  encrypting: {
683
705
  id: parentReadKeyID,
684
706
  secret: parentReadKeySecret,
@@ -763,10 +785,10 @@ export class RawGroup<
763
785
  * @category 2. Role changing
764
786
  */
765
787
  createInvite(role: AccountRole): InviteSecret {
766
- const secretSeed = this.core.crypto.newRandomSecretSeed();
788
+ const secretSeed = this.crypto.newRandomSecretSeed();
767
789
 
768
- const inviteSecret = this.core.crypto.agentSecretFromSecretSeed(secretSeed);
769
- const inviteID = this.core.crypto.getAgentID(inviteSecret);
790
+ const inviteSecret = this.crypto.agentSecretFromSecretSeed(secretSeed);
791
+ const inviteID = this.crypto.getAgentID(inviteSecret);
770
792
 
771
793
  this.addMemberInternal(inviteID, `${role}Invite` as Role);
772
794
 
@@ -783,7 +805,7 @@ export class RawGroup<
783
805
  init?: M["_shape"],
784
806
  meta?: M["headerMeta"],
785
807
  initPrivacy: "trusting" | "private" = "private",
786
- uniqueness: CoValueUniqueness = this.core.crypto.createdNowUnique(),
808
+ uniqueness: CoValueUniqueness = this.crypto.createdNowUnique(),
787
809
  ): M {
788
810
  const map = this.core.node
789
811
  .createCoValue({
@@ -814,7 +836,7 @@ export class RawGroup<
814
836
  init?: L["_item"][],
815
837
  meta?: L["headerMeta"],
816
838
  initPrivacy: "trusting" | "private" = "private",
817
- uniqueness: CoValueUniqueness = this.core.crypto.createdNowUnique(),
839
+ uniqueness: CoValueUniqueness = this.crypto.createdNowUnique(),
818
840
  ): L {
819
841
  const list = this.core.node
820
842
  .createCoValue({
@@ -854,7 +876,7 @@ export class RawGroup<
854
876
  group: this.id,
855
877
  },
856
878
  meta: meta || null,
857
- ...this.core.crypto.createdNowUnique(),
879
+ ...this.crypto.createdNowUnique(),
858
880
  })
859
881
  .getCurrentContent() as T;
860
882
 
@@ -868,7 +890,7 @@ export class RawGroup<
868
890
  /** @category 3. Value creation */
869
891
  createStream<C extends RawCoStream>(
870
892
  meta?: C["headerMeta"],
871
- uniqueness: CoValueUniqueness = this.core.crypto.createdNowUnique(),
893
+ uniqueness: CoValueUniqueness = this.crypto.createdNowUnique(),
872
894
  ): C {
873
895
  return this.core.node
874
896
  .createCoValue({
@@ -886,7 +908,7 @@ export class RawGroup<
886
908
  /** @category 3. Value creation */
887
909
  createBinaryStream<C extends RawBinaryCoStream>(
888
910
  meta: C["headerMeta"] = { type: "binary" },
889
- uniqueness: CoValueUniqueness = this.core.crypto.createdNowUnique(),
911
+ uniqueness: CoValueUniqueness = this.crypto.createdNowUnique(),
890
912
  ): C {
891
913
  return this.core.node
892
914
  .createCoValue({
@@ -1,6 +1,6 @@
1
1
  import { RawUnknownCoValue } from "./coValue.js";
2
- import type { CoValueCore } from "./coValueCore.js";
3
- import { RawAccount, RawControlledAccount } from "./coValues/account.js";
2
+ import type { AvailableCoValueCore } from "./coValueCore/coValueCore.js";
3
+ import { RawAccount } from "./coValues/account.js";
4
4
  import { RawCoList } from "./coValues/coList.js";
5
5
  import { RawCoMap } from "./coValues/coMap.js";
6
6
  import { RawCoPlainText } from "./coValues/coPlainText.js";
@@ -8,32 +8,31 @@ import { RawBinaryCoStream, RawCoStream } from "./coValues/coStream.js";
8
8
  import { RawGroup } from "./coValues/group.js";
9
9
 
10
10
  export function coreToCoValue(
11
- core: CoValueCore,
11
+ core: AvailableCoValueCore,
12
12
  options?: { ignorePrivateTransactions: true },
13
13
  ) {
14
- if (core.header.type === "comap") {
15
- if (core.header.ruleset.type === "group") {
14
+ if (core.verified.header.type === "comap") {
15
+ if (core.verified.header.ruleset.type === "group") {
16
16
  if (
17
- core.header.meta?.type === "account" &&
17
+ core.verified.header.meta?.type === "account" &&
18
18
  !options?.ignorePrivateTransactions
19
19
  ) {
20
- if (core.id === core.node.account.id) {
21
- return new RawControlledAccount(core, core.node.account.agentSecret);
22
- } else {
23
- return new RawAccount(core);
24
- }
20
+ return new RawAccount(core);
25
21
  } else {
26
22
  return new RawGroup(core, options);
27
23
  }
28
24
  } else {
29
25
  return new RawCoMap(core);
30
26
  }
31
- } else if (core.header.type === "coplaintext") {
27
+ } else if (core.verified.header.type === "coplaintext") {
32
28
  return new RawCoPlainText(core);
33
- } else if (core.header.type === "colist") {
29
+ } else if (core.verified.header.type === "colist") {
34
30
  return new RawCoList(core);
35
- } else if (core.header.type === "costream") {
36
- if (core.header.meta && core.header.meta.type === "binary") {
31
+ } else if (core.verified.header.type === "costream") {
32
+ if (
33
+ core.verified.header.meta &&
34
+ core.verified.header.meta.type === "binary"
35
+ ) {
37
36
  return new RawBinaryCoStream(core);
38
37
  } else {
39
38
  return new RawCoStream(core);
package/src/exports.ts CHANGED
@@ -1,15 +1,16 @@
1
1
  import { base64URLtoBytes, bytesToBase64url } from "./base64url.js";
2
2
  import { type RawCoValue } from "./coValue.js";
3
3
  import {
4
+ CO_VALUE_LOADING_CONFIG,
4
5
  CoValueCore,
5
- type CoValueUniqueness,
6
6
  MAX_RECOMMENDED_TX_SIZE,
7
7
  idforHeader,
8
- } from "./coValueCore.js";
8
+ } from "./coValueCore/coValueCore.js";
9
+ import { CoValueUniqueness } from "./coValueCore/verifiedState.js";
9
10
  import {
11
+ ControlledAccount,
10
12
  ControlledAgent,
11
13
  RawAccount,
12
- RawControlledAccount,
13
14
  RawProfile,
14
15
  accountHeaderForInitialAgentSecret,
15
16
  } from "./coValues/account.js";
@@ -76,7 +77,6 @@ import {
76
77
 
77
78
  type Value = JsonValue | AnyRawCoValue;
78
79
 
79
- import { CO_VALUE_LOADING_CONFIG } from "./coValueState.js";
80
80
  import { logger } from "./logger.js";
81
81
  import { getPriorityFromHeader } from "./priority.js";
82
82
 
@@ -121,6 +121,7 @@ export {
121
121
  AnyRawCoValue,
122
122
  RawAccount,
123
123
  RawAccountID,
124
+ ControlledAccount,
124
125
  AccountMeta,
125
126
  RawAccountMigration,
126
127
  RawProfile as Profile,
@@ -128,7 +129,6 @@ export {
128
129
  Media,
129
130
  CoValueCore,
130
131
  ControlledAgent,
131
- RawControlledAccount,
132
132
  MAX_RECOMMENDED_TX_SIZE,
133
133
  JsonObject,
134
134
  JsonValue,
@@ -173,8 +173,10 @@ export namespace CojsonInternalTypes {
173
173
  export type LoadMessage = import("./sync.js").LoadMessage;
174
174
  export type NewContentMessage = import("./sync.js").NewContentMessage;
175
175
  export type SessionNewContent = import("./sync.js").SessionNewContent;
176
- export type CoValueHeader = import("./coValueCore.js").CoValueHeader;
177
- export type Transaction = import("./coValueCore.js").Transaction;
176
+ // biome-ignore format: inserts spurious trialing comma that breaks some parsers
177
+ export type CoValueHeader = import("./coValueCore/verifiedState.js").CoValueHeader;
178
+ // biome-ignore format: inserts spurious trialing comma that breaks some parsers
179
+ export type Transaction = import("./coValueCore/verifiedState.js").Transaction;
178
180
  export type TransactionID = import("./ids.js").TransactionID;
179
181
  export type Signature = import("./crypto/crypto.js").Signature;
180
182
  export type RawCoID = import("./ids.js").RawCoID;