@cero-base/cero 1.18.2 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/README.md +38 -644
  2. package/package.json +16 -12
  3. package/src/build/index.js +21 -50
  4. package/src/build/internal.js +121 -0
  5. package/src/build/schemas.js +2 -8
  6. package/src/extensions/handle-sync.js +3 -10
  7. package/src/extensions/index.js +6 -0
  8. package/src/extensions/profile-sync.js +0 -5
  9. package/src/handle/index.js +255 -300
  10. package/src/index.js +65 -112
  11. package/src/lib/bluetooth.js +25 -56
  12. package/src/lib/constants.js +0 -15
  13. package/src/lib/operators.js +24 -74
  14. package/src/lib/peek.js +4 -8
  15. package/src/lib/refs.js +46 -0
  16. package/src/lib/spec.js +2 -3
  17. package/src/local/index.js +4 -5
  18. package/src/rpc/client.js +27 -39
  19. package/src/rpc/index.js +3 -3
  20. package/src/rpc/server.js +29 -40
  21. package/types/build/index.d.ts +19 -7
  22. package/types/build/internal.d.ts +78 -0
  23. package/types/build/schemas.d.ts +3 -3
  24. package/types/extensions/handle-sync.d.ts +4 -9
  25. package/types/extensions/index.d.ts +24 -2
  26. package/types/extensions/profile-sync.d.ts +2 -6
  27. package/types/handle/index.d.ts +218 -254
  28. package/types/index.d.ts +78 -102
  29. package/types/lib/bluetooth.d.ts +24 -46
  30. package/types/lib/constants.d.ts +5 -16
  31. package/types/lib/operators.d.ts +49 -77
  32. package/types/lib/peek.d.ts +3 -4
  33. package/types/lib/refs.d.ts +36 -0
  34. package/types/lib/spec.d.ts +5 -1
  35. package/types/local/index.d.ts +24 -23
  36. package/types/rpc/client.d.ts +107 -127
  37. package/types/rpc/index.d.ts +7 -2
  38. package/types/rpc/server.d.ts +62 -76
  39. package/src/build/builtins.js +0 -174
  40. package/src/lib/internal.js +0 -9
  41. package/src/lib/utils.js +0 -67
  42. package/types/build/builtins.d.ts +0 -100
  43. package/types/lib/internal.d.ts +0 -24
  44. package/types/lib/utils.d.ts +0 -55
@@ -1,4 +1,131 @@
1
- export { Ref } from "../lib/utils.js";
1
+ import AbortController from 'bare-abort-controller';
2
+ import ReadyResource from 'ready-resource';
3
+ import { Identity } from '@cero-base/core/identity';
4
+ import { Database } from '@cero-base/core/database';
5
+ import { Pairing } from '@cero-base/core/pairing';
6
+ import { Blobs } from '@cero-base/core/blobs';
7
+ import { FileServer } from '@cero-base/core/blobs/server';
8
+ export { Ref } from '../lib/refs.js';
9
+ export type Network = import('@cero-base/core/network').Network;
10
+ export type Local = import('../local/index.js').Local;
11
+ export type KeyPair = import('@cero-base/core/identity').KeyPair;
12
+ export type HandleOpts = {
13
+ /**
14
+ * Parent handle when this is a child slot.
15
+ */
16
+ parent?: Handle;
17
+ /**
18
+ * Long-lived user identity. Inherited from `parent` if omitted.
19
+ */
20
+ identity?: Identity;
21
+ /**
22
+ * Shared swarm. Inherited from `parent` if omitted.
23
+ */
24
+ network?: Network;
25
+ /**
26
+ * Pre-existing Corestore. Falls back to `parent.store.store`.
27
+ */
28
+ store?: any;
29
+ /**
30
+ * Built cero spec.
31
+ */
32
+ spec?: any;
33
+ /**
34
+ * Local store for per-handle keypairs.
35
+ */
36
+ local?: Local;
37
+ /**
38
+ * Owned HypercoreStorage to close on shutdown.
39
+ */
40
+ storage?: any;
41
+ /**
42
+ * Owned identity Discovery to destroy on shutdown.
43
+ */
44
+ discovery?: any;
45
+ /**
46
+ * Data directory (root handles only).
47
+ */
48
+ dir?: string;
49
+ /**
50
+ * Pass-through cero(...) options.
51
+ */
52
+ opts?: any;
53
+ routes?: Record<string, Function>;
54
+ /**
55
+ * Existing database key.
56
+ */
57
+ key?: Uint8Array;
58
+ /**
59
+ * Existing encryption key.
60
+ */
61
+ encryptionKey?: Uint8Array;
62
+ /**
63
+ * Rotation epochs delivered at join.
64
+ */
65
+ epochs?: Array<{
66
+ epoch: number;
67
+ entropy: Uint8Array;
68
+ }>;
69
+ /**
70
+ * Corestore namespace.
71
+ */
72
+ namespace?: string;
73
+ /**
74
+ * Writer keypair.
75
+ */
76
+ keyPair?: KeyPair;
77
+ /**
78
+ * Join discovery server-only; flip later with `setActive`.
79
+ */
80
+ passive?: boolean;
81
+ /**
82
+ * When `false`, skips creating a `Pairing` session.
83
+ */
84
+ pair?: boolean;
85
+ };
86
+ export type CreateChildOpts = {
87
+ name?: string | null;
88
+ routes?: Record<string, Function>;
89
+ role?: string;
90
+ accept?: boolean;
91
+ };
92
+ export type JoinChildOpts = {
93
+ routes?: Record<string, Function>;
94
+ timeout?: number;
95
+ };
96
+ export type StaticJoinOpts = {
97
+ parent?: Handle;
98
+ network?: Network;
99
+ identity?: Identity;
100
+ store?: any;
101
+ spec?: any;
102
+ namespace?: string;
103
+ routes?: Record<string, Function>;
104
+ timeout?: number;
105
+ };
106
+ export type AcceptOpts = {
107
+ /**
108
+ * Role to grant the joining peer. Falls back to the invite's role, then `'member'`.
109
+ */
110
+ role?: string;
111
+ name?: string | null;
112
+ };
113
+ export type HandleExtra = {
114
+ /**
115
+ * Display name; set on child handles by the owner flow.
116
+ */
117
+ name?: string | null;
118
+ /**
119
+ * `profile` ref, attached dynamically when the schema declares one.
120
+ */
121
+ profile?: import('../lib/refs.js').Ref;
122
+ /**
123
+ * `members` ref, attached dynamically when the schema declares one.
124
+ */
125
+ members?: import('../lib/refs.js').Ref;
126
+ };
127
+ export type Child = Handle & HandleExtra;
128
+ export type CeroHandle = Handle & Record<string, import('../lib/refs.js').Ref>;
2
129
  /**
3
130
  * @typedef {import('@cero-base/core/network').Network} Network
4
131
  * @typedef {import('../local/index.js').Local} Local
@@ -48,37 +175,19 @@ export { Ref } from "../lib/utils.js";
48
175
  * @property {string} [role] Role to grant the joining peer. Falls back to the invite's role, then `'member'`.
49
176
  * @property {string | null} [name]
50
177
  *
51
- * @typedef {object} RecoverOpts
52
- * @property {number} [timeout]
53
- *
54
178
  * @typedef {object} HandleExtra
55
179
  * @property {string | null} [name] Display name; set on child handles by the owner flow.
56
- * @property {import('../lib/utils.js').Ref} [profile] `profile` ref, attached dynamically when the schema declares one.
57
- * @property {import('../lib/utils.js').Ref} [members] `members` ref, attached dynamically when the schema declares one.
180
+ * @property {import('../lib/refs.js').Ref} [profile] `profile` ref, attached dynamically when the schema declares one.
181
+ * @property {import('../lib/refs.js').Ref} [members] `members` ref, attached dynamically when the schema declares one.
58
182
  *
59
183
  * @typedef {Handle & HandleExtra} Child A child handle plus its dynamically-attached refs.
60
184
  *
61
- * @typedef {Handle & Record<string, import('../lib/utils.js').Ref>} CeroHandle A handle with every schema ref reachable as a `Ref` property (e.g. `me.profile`, `room.messages`).
185
+ * @typedef {Handle & Record<string, import('../lib/refs.js').Ref>} CeroHandle A handle with every schema ref reachable as a `Ref` property (e.g. `me.profile`, `room.messages`).
62
186
  */
63
187
  /**
64
188
  * A cero handle — a single writable database session attached to a swarm.
65
- * The "root" handle is the user's facade; child handles (created via
66
- * `_create`/`_join`/`_load`) live under it and share the same identity,
67
- * network and corestore. Ref properties (`profile`, `members`, ...) are
68
- * attached dynamically per the schema; child handles also carry a `name`.
69
189
  */
70
- export class Handle extends ReadyResource {
71
- /**
72
- * Pair into an existing handle via an invite, returning a brand-new
73
- * `Handle` already configured with the resolved key + encryption key.
74
- *
75
- * @param {string} invite
76
- * @param {StaticJoinOpts} [opts]
77
- * @returns {Promise<Handle>}
78
- */
79
- static join(invite: string, { parent, network, identity, store, spec, namespace, routes, timeout }?: StaticJoinOpts): Promise<Handle>;
80
- /** @param {HandleOpts} [opts] */
81
- constructor(opts?: HandleOpts);
190
+ export declare class Handle extends ReadyResource {
82
191
  identity: any;
83
192
  network: any;
84
193
  spec: any;
@@ -101,11 +210,45 @@ export class Handle extends ReadyResource {
101
210
  store: Database;
102
211
  pair: Pairing;
103
212
  _wantsPair: boolean;
213
+ _ac: AbortController;
104
214
  _invitesSync: () => Promise<void>;
215
+ /** @param {HandleOpts} [opts] */
216
+ constructor(opts?: HandleOpts);
217
+ /**
218
+ * An `AbortSignal` that fires when this handle closes.
219
+ *
220
+ * @returns {AbortSignal}
221
+ */
222
+ get signal(): AbortSignal;
223
+ /** The top-most handle in the parent chain — itself for a root handle. */
224
+ get root(): this;
225
+ /**
226
+ * Lazily-built file server for this identity. Root-only — child handles
227
+ * reach it through `this.root.fileServer`.
228
+ *
229
+ * @returns {FileServer}
230
+ */
231
+ get fileServer(): FileServer;
105
232
  /**
106
- * Tie a destroyable resource (a `watch` stream, a timer, any `{ destroy }`)
107
- * to this handle's lifecycle — it's destroyed automatically on close, so
108
- * callers don't track cleanup. De-registers itself if destroyed earlier.
233
+ * Lazily-built blob store for THIS handle's writing device, at the current rotation epoch.
234
+ *
235
+ * @returns {Blobs}
236
+ */
237
+ get blobs(): Blobs;
238
+ /** Canonical id — identity id for the root handle, store key for children. */
239
+ get id(): any;
240
+ /** This device's id + name. `null` on child handles. */
241
+ get device(): {
242
+ id: any;
243
+ name: any;
244
+ };
245
+ get suspended(): boolean;
246
+ _open(): Promise<void>;
247
+ _close(): Promise<void>;
248
+ /**
249
+ * Tie a destroyable resource (a `watch` stream, a timer, any `{ destroy }`) to this
250
+ * handle's lifecycle — it's destroyed automatically on close, so callers don't track
251
+ * cleanup.
109
252
  *
110
253
  * @template {{ destroy?: Function, once?: Function }} T
111
254
  * @param {T} resource
@@ -115,15 +258,6 @@ export class Handle extends ReadyResource {
115
258
  destroy?: Function;
116
259
  once?: Function;
117
260
  }>(resource: T): T;
118
- /**
119
- * An `AbortSignal` that fires when this handle closes. Pass it as
120
- * `{ signal }` to `on`/`after`/`before`/`watch` to drop a subscription on
121
- * close — or use your own `AbortController` for a finer scope.
122
- *
123
- * @returns {AbortSignal}
124
- */
125
- get signal(): AbortSignal;
126
- _ac: AbortController;
127
261
  /**
128
262
  * `EventEmitter.on` plus an optional `{ signal }` that removes the listener
129
263
  * when the signal aborts — e.g. `me.on('handle', fn, { signal: me.signal })`.
@@ -136,24 +270,6 @@ export class Handle extends ReadyResource {
136
270
  on(event: string, fn: (...args: any[]) => void, opts?: {
137
271
  signal?: AbortSignal;
138
272
  }): this;
139
- /** The top-most handle in the parent chain — itself for a root handle. */
140
- get root(): this;
141
- /**
142
- * Lazily-built file server for this identity. Root-only — child handles
143
- * reach it through `this.root.fileServer`.
144
- *
145
- * @returns {FileServer}
146
- */
147
- get fileServer(): FileServer;
148
- /**
149
- * @param {Uint8Array} coreKey
150
- * @param {object} info
151
- * @returns {{ key: Uint8Array, encryptionKey: Uint8Array } | null}
152
- */
153
- _resolveCore(coreKey: Uint8Array, info: object): {
154
- key: Uint8Array;
155
- encryptionKey: Uint8Array;
156
- } | null;
157
273
  /**
158
274
  * Resolve a durable file id to an ephemeral download url via this identity's
159
275
  * file server.
@@ -162,38 +278,6 @@ export class Handle extends ReadyResource {
162
278
  * @returns {string}
163
279
  */
164
280
  getLink(id: string): string;
165
- /**
166
- * Lazily-built blob store for THIS handle's writing device, at the current
167
- * rotation epoch. One core per writer per epoch that writes files: the base
168
- * era uses the handle's encryptionKey, rotated epochs use a key derived
169
- * from the epoch entropy — so a removed member cannot decrypt files added
170
- * after the rotation. Instances carry `.stamp` so the file row records
171
- * which era its core belongs to.
172
- *
173
- * @returns {Blobs}
174
- */
175
- get blobs(): Blobs;
176
- _baseBlobs(): Blobs;
177
- _makeBlobs(name: any, encryptionKey: any, stamp: any): Blobs;
178
- /**
179
- * Remember the blob-core key a file id points at so the file server can
180
- * open the core. Lives on the Handle (not the shared operators) because the
181
- * epoch-key derivation pulls native crypto — the RPC client must stay
182
- * bundleable without it.
183
- *
184
- * @param {string} id
185
- * @param {number} [stamp]
186
- */
187
- _registerBlobCore(id: string, stamp?: number): void;
188
- _blobCoreKey(stamp: any): Uint8Array<ArrayBufferLike>;
189
- /** Canonical id — identity id for the root handle, store key for children. */
190
- get id(): any;
191
- /** This device's id + name. `null` on child handles. */
192
- get device(): {
193
- id: string;
194
- name: any;
195
- };
196
- get suspended(): boolean;
197
281
  /**
198
282
  * Initialise a fresh database: write the genesis claim, derive the writer.
199
283
  * Forwards to `Database.bootstrap`.
@@ -210,17 +294,9 @@ export class Handle extends ReadyResource {
210
294
  */
211
295
  claim(): Promise<void>;
212
296
  /**
213
- * Claim + wait until this peer becomes a writer + bring the bee up to date.
214
- * Used by `restore()` after wiping local state.
215
- *
216
- * @param {RecoverOpts} [opts]
217
- * @returns {Promise<void>}
218
- */
219
- recover({ timeout }?: RecoverOpts): Promise<void>;
220
- /**
221
- * Flip this handle's swarm announce mode — `setActive(false)` demotes an
222
- * idle/background room to server-only (still reachable, stops searching);
223
- * `setActive(true)` promotes it back on focus. Cheap, safe to call often.
297
+ * Flip this handle's swarm announce mode `setActive(false)` demotes an idle/background
298
+ * room to server-only (still reachable, stops searching); `setActive(true)` promotes it
299
+ * back on focus.
224
300
  *
225
301
  * @param {boolean} active
226
302
  * @returns {Promise<void>}
@@ -237,7 +313,6 @@ export class Handle extends ReadyResource {
237
313
  expiresIn?: number;
238
314
  data?: any;
239
315
  }): Promise<string>;
240
- _syncInvites(): Promise<void>;
241
316
  /**
242
317
  * Revoke a previously-minted invite by its string form.
243
318
  *
@@ -254,7 +329,6 @@ export class Handle extends ReadyResource {
254
329
  * @returns {Promise<void>}
255
330
  */
256
331
  accept(candidate: any, { role, name }?: AcceptOpts): Promise<void>;
257
- _checkGrant(role: any): Promise<void>;
258
332
  /**
259
333
  * Leave a child handle — removes it from the parent's `handles` collection
260
334
  * and closes the session. No-op on root handles.
@@ -263,9 +337,41 @@ export class Handle extends ReadyResource {
263
337
  */
264
338
  leave(): Promise<void>;
265
339
  /**
266
- * Create a new child handle of `type`. Owner-flow generates a fresh
267
- * writer, adds it as a writer + member, and registers the child on the
268
- * parent's `handles` collection.
340
+ * Pause networking + storage. Idempotent; no-op on child handles.
341
+ *
342
+ * @returns {Promise<void>}
343
+ */
344
+ suspend(): Promise<void>;
345
+ /**
346
+ * Resume a suspended root handle. Idempotent; no-op on child handles.
347
+ *
348
+ * @returns {Promise<void>}
349
+ */
350
+ resume(): Promise<void>;
351
+ /**
352
+ * @param {Uint8Array} coreKey
353
+ * @param {object} info
354
+ * @returns {{ key: Uint8Array, encryptionKey: Uint8Array } | null}
355
+ */
356
+ _resolveCore(coreKey: Uint8Array, info: object): {
357
+ key: Uint8Array;
358
+ encryptionKey: Uint8Array;
359
+ } | null;
360
+ _baseBlobs(): Blobs;
361
+ _makeBlobs(name: any, encryptionKey: any, stamp: any): Blobs;
362
+ /**
363
+ * Remember the blob-core key a file id points at so the file server can open the core.
364
+ *
365
+ * @param {string} id
366
+ * @param {number} [stamp]
367
+ */
368
+ _registerBlobCore(id: string, stamp?: number): void;
369
+ _blobCoreKey(stamp: any): Uint8Array<ArrayBufferLike>;
370
+ _syncInvites(): Promise<void>;
371
+ _checkGrant(role: any): Promise<void>;
372
+ /**
373
+ * Create a new child handle of `type`. Owner-flow — generates a fresh writer, adds it as a
374
+ * writer + member, and registers the child on the parent's `handles` collection.
269
375
  *
270
376
  * @param {string} type
271
377
  * @param {CreateChildOpts} [opts]
@@ -273,9 +379,7 @@ export class Handle extends ReadyResource {
273
379
  */
274
380
  _create(type: string, { name, routes, role, accept }?: CreateChildOpts): Promise<Handle>;
275
381
  /**
276
- * Join a child handle by invite (joiner-flow). Waits for writer
277
- * capability and registers the child on the parent's `handles`
278
- * collection.
382
+ * Join a child handle by invite (joiner-flow).
279
383
  *
280
384
  * @param {string} invite
281
385
  * @param {string} type
@@ -292,9 +396,8 @@ export class Handle extends ReadyResource {
292
396
  */
293
397
  _pair(invite: string, type: string, { routes, timeout }?: JoinChildOpts, target?: Uint8Array | null): Promise<Handle>;
294
398
  /**
295
- * Get an open child by id, or re-open it. Concurrent calls for the same id
296
- * share one in-flight load, so the child is built — and `handle` emitted —
297
- * exactly once.
399
+ * Get an open child by id, or re-open it. Concurrent calls for the same id share one
400
+ * in-flight load, so the child is built — and `handle` emitted — exactly once.
298
401
  *
299
402
  * @param {string} type
300
403
  * @param {string} id
@@ -310,19 +413,7 @@ export class Handle extends ReadyResource {
310
413
  * @returns {Promise<Handle>}
311
414
  */
312
415
  _reopen(type: string, id: string, opts: any): Promise<Handle>;
313
- /**
314
- * Pause networking + storage. Idempotent; no-op on child handles.
315
- *
316
- * @returns {Promise<void>}
317
- */
318
- suspend(): Promise<void>;
319
416
  _suspend(): Promise<void>;
320
- /**
321
- * Resume a suspended root handle. Idempotent; no-op on child handles.
322
- *
323
- * @returns {Promise<void>}
324
- */
325
- resume(): Promise<void>;
326
417
  _resume(): Promise<void>;
327
418
  /**
328
419
  * @param {Handle} child
@@ -348,140 +439,13 @@ export class Handle extends ReadyResource {
348
439
  publicKey: Uint8Array;
349
440
  secretKey: Uint8Array;
350
441
  } | null>;
351
- }
352
- export type Network = import("@cero-base/core/network").Network;
353
- export type Local = import("../local/index.js").Local;
354
- export type KeyPair = import("@cero-base/core/identity").KeyPair;
355
- export type HandleOpts = {
356
- /**
357
- * Parent handle when this is a child slot.
358
- */
359
- parent?: Handle;
360
- /**
361
- * Long-lived user identity. Inherited from `parent` if omitted.
362
- */
363
- identity?: Identity;
364
- /**
365
- * Shared swarm. Inherited from `parent` if omitted.
366
- */
367
- network?: Network;
368
- /**
369
- * Pre-existing Corestore. Falls back to `parent.store.store`.
370
- */
371
- store?: any;
372
- /**
373
- * Built cero spec.
374
- */
375
- spec?: any;
376
- /**
377
- * Local store for per-handle keypairs.
378
- */
379
- local?: Local;
380
- /**
381
- * Owned HypercoreStorage to close on shutdown.
382
- */
383
- storage?: any;
384
- /**
385
- * Owned identity Discovery to destroy on shutdown.
386
- */
387
- discovery?: any;
388
- /**
389
- * Data directory (root handles only).
390
- */
391
- dir?: string;
392
- /**
393
- * Pass-through cero(...) options.
394
- */
395
- opts?: any;
396
- routes?: Record<string, Function>;
397
- /**
398
- * Existing database key.
399
- */
400
- key?: Uint8Array;
401
- /**
402
- * Existing encryption key.
403
- */
404
- encryptionKey?: Uint8Array;
405
- /**
406
- * Rotation epochs delivered at join.
407
- */
408
- epochs?: Array<{
409
- epoch: number;
410
- entropy: Uint8Array;
411
- }>;
412
- /**
413
- * Corestore namespace.
414
- */
415
- namespace?: string;
416
- /**
417
- * Writer keypair.
418
- */
419
- keyPair?: KeyPair;
420
- /**
421
- * Join discovery server-only; flip later with `setActive`.
422
- */
423
- passive?: boolean;
424
- /**
425
- * When `false`, skips creating a `Pairing` session.
426
- */
427
- pair?: boolean;
428
- };
429
- export type CreateChildOpts = {
430
- name?: string | null;
431
- routes?: Record<string, Function>;
432
- role?: string;
433
- accept?: boolean;
434
- };
435
- export type JoinChildOpts = {
436
- routes?: Record<string, Function>;
437
- timeout?: number;
438
- };
439
- export type StaticJoinOpts = {
440
- parent?: Handle;
441
- network?: Network;
442
- identity?: Identity;
443
- store?: any;
444
- spec?: any;
445
- namespace?: string;
446
- routes?: Record<string, Function>;
447
- timeout?: number;
448
- };
449
- export type AcceptOpts = {
450
442
  /**
451
- * Role to grant the joining peer. Falls back to the invite's role, then `'member'`.
452
- */
453
- role?: string;
454
- name?: string | null;
455
- };
456
- export type RecoverOpts = {
457
- timeout?: number;
458
- };
459
- export type HandleExtra = {
460
- /**
461
- * Display name; set on child handles by the owner flow.
462
- */
463
- name?: string | null;
464
- /**
465
- * `profile` ref, attached dynamically when the schema declares one.
466
- */
467
- profile?: import("../lib/utils.js").Ref;
468
- /**
469
- * `members` ref, attached dynamically when the schema declares one.
443
+ * Pair into an existing handle via an invite, returning a brand-new
444
+ * `Handle` already configured with the resolved key + encryption key.
445
+ *
446
+ * @param {string} invite
447
+ * @param {StaticJoinOpts} [opts]
448
+ * @returns {Promise<Handle>}
470
449
  */
471
- members?: import("../lib/utils.js").Ref;
472
- };
473
- /**
474
- * A child handle plus its dynamically-attached refs.
475
- */
476
- export type Child = Handle & HandleExtra;
477
- /**
478
- * A handle with every schema ref reachable as a `Ref` property (e.g. `me.profile`, `room.messages`).
479
- */
480
- export type CeroHandle = Handle & Record<string, import("../lib/utils.js").Ref>;
481
- import ReadyResource from 'ready-resource';
482
- import { FileServer } from '@cero-base/core/blobs/server';
483
- import { Blobs } from '@cero-base/core/blobs';
484
- import { Database } from '@cero-base/core/database';
485
- import { Pairing } from '@cero-base/core/pairing';
486
- import AbortController from 'bare-abort-controller';
487
- import { Identity } from '@cero-base/core/identity';
450
+ static join(invite: string, { parent, network, identity, store, spec, namespace, routes, timeout }?: StaticJoinOpts): Promise<Handle>;
451
+ }