@econ-v1/domain 7.6.143 → 7.6.145
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.
- package/dist/errors/index.d.ts +3 -3
- package/dist/errors/index.d.ts.map +1 -1
- package/dist/events/index.d.ts +18 -3
- package/dist/events/index.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/errors/index.js +2 -2
- package/src/events/index.js +4 -2
- package/src/services/discovery-probe-service.js +1 -1
- package/src/services/invite-redemption-service.js +2 -2
- package/src/services/lan-candidate-refresh-service.js +1 -1
- package/src/services/lcd-decision-service.js +1 -1
- package/src/services/onboarding-status-service.js +1 -1
- package/src/services/owner-claim-service.js +4 -4
- package/src/services/peer-directory-service.js +1 -1
- package/src/services/wallet-mirror-service.js +2 -2
- package/src/services/wifi-provisioning-service.js +4 -4
package/dist/errors/index.d.ts
CHANGED
|
@@ -29,8 +29,8 @@
|
|
|
29
29
|
export const DOMAIN_ERROR_CODES: readonly ["access-code-invalid", "approval_denied", "capability_not_declared", "capability_unavailable", "child_unavailable", "code-already-bound", "conflict", "forbidden", "invalid_payload", "invalid_request", "not_found", "page_changed", "scope_unavailable", "script_timeout", "script_unavailable", "stage_composition_not_enabled", "timeout", "unauthorized", "unknown_command", "unsupported_query", "validation_failed"];
|
|
30
30
|
/** @type {readonly ["outbox_delivery_failed", "sync_conflict", "sync_terminal_failure"]} */
|
|
31
31
|
export const SYNC_ERROR_CODES: readonly ["outbox_delivery_failed", "sync_conflict", "sync_terminal_failure"];
|
|
32
|
-
/** @type {readonly ["connection_lost", "offline", "unavailable"]} */
|
|
33
|
-
export const TRANSPORT_ERROR_CODES: readonly ["connection_lost", "offline", "unavailable"];
|
|
32
|
+
/** @type {readonly ["connection_lost", "offline", "unavailable", "rate_limited"]} */
|
|
33
|
+
export const TRANSPORT_ERROR_CODES: readonly ["connection_lost", "offline", "unavailable", "rate_limited"];
|
|
34
34
|
/**
|
|
35
35
|
* @extends {SerializableClientErrorBase<"domain", DomainErrorCode>}
|
|
36
36
|
*/
|
|
@@ -52,7 +52,7 @@ export class SyncError extends SerializableClientErrorBase<"sync", "outbox_deliv
|
|
|
52
52
|
/**
|
|
53
53
|
* @extends {SerializableClientErrorBase<"transport", TransportErrorCode>}
|
|
54
54
|
*/
|
|
55
|
-
export class TransportError extends SerializableClientErrorBase<"transport", "offline" | "unavailable" | "connection_lost"> {
|
|
55
|
+
export class TransportError extends SerializableClientErrorBase<"transport", "offline" | "unavailable" | "connection_lost" | "rate_limited"> {
|
|
56
56
|
/**
|
|
57
57
|
* @param {ErrorOptions<TransportErrorCode>} options
|
|
58
58
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/errors/index.js"],"names":[],"mappings":"AAEA;;GAEG;AACH;;GAEG;AACH;;GAEG;AACH;;GAEG;AACH;;;GAGG;AACH;;;;GAIG;AACH;;GAEG;AACH;;GAEG;AACH,obAAob;AACpb,iCADW,SAAS,CAAC,qBAAqB,EAAE,iBAAiB,EAAE,yBAAyB,EAAE,wBAAwB,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,UAAU,EAAE,WAAW,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,WAAW,EAAE,cAAc,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,oBAAoB,EAAE,+BAA+B,EAAE,SAAS,EAAE,cAAc,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,mBAAmB,CAAC,CA0C9a;AACF,4FAA4F;AAC5F,+BADW,SAAS,CAAC,wBAAwB,EAAE,eAAe,EAAE,uBAAuB,CAAC,CACa;AACrG,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/errors/index.js"],"names":[],"mappings":"AAEA;;GAEG;AACH;;GAEG;AACH;;GAEG;AACH;;GAEG;AACH;;;GAGG;AACH;;;;GAIG;AACH;;GAEG;AACH;;GAEG;AACH,obAAob;AACpb,iCADW,SAAS,CAAC,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C,IAAI,EAAE,KAAK,CAAC;IAAC,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAAE;0BAGxG,WAAW,GAAG,SAAS,GAAG,cAAc;sCAGtC,iBAAiB,CAAC,QAAQ,EAAE,eAAe,CAAC,GAAG,iBAAiB,CAAC,MAAM,EAAE,aAAa,CAAC,GAAG,iBAAiB,CAAC,WAAW,EAAE,kBAAkB,CAAC;AAiD3J;;;;;GAKG;AACH,0CAJsB,KAAK,SAAd,MAAQ,EACC,KAAK,SAAd,MAAQ;IAmBjB;;;;KAIC;IACD,wBAKC;IAzBD;;;KAGC;IACD,eAFQ,KAAK,CAER;IACL;;;KAGC;IACD,eAFQ,KAAK,CAER;IACL;;;KAGC;IACD,kBAFQ,UAAU,GAAG,SAAS,CAEtB;IAYR;;KAEC;IACD,UAFW,iBAAiB,CAAC,KAAK,EAAE,KAAK,CAAC,CAMzC;CACJ"}
|
package/dist/events/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/** @typedef {(typeof KERNEL_EVENT_TYPES)[number]} CoreKernelEventType */
|
|
2
2
|
/** @typedef {AppEventType | CoreKernelEventType} KernelEventType */
|
|
3
|
-
/** @typedef {{ readonly "client-presence.changed": { readonly deviceId: string }, readonly "client-storage.state-changed": { readonly code?: string, readonly message?: string, readonly status: "ready" | "recovery-required" | "starting" }, readonly "offline.stage-progress-changed": {}, readonly "offline.stage-readiness-changed": { readonly readiness: OfflineStageReadiness }, readonly "offline.identity-invalidated": { readonly scope: OfflineIdentityScope }, readonly "app.data.changed": { readonly appName: string, readonly cursor: string, readonly revision: string, readonly stream: string }, readonly "app.data.committed": { readonly appName: string, readonly cursor: string, readonly revision: string, readonly stream: string }, readonly "device-cleanup.changed": { readonly state?: string }, readonly "domain.entity-changed": { readonly entity?: "push" | string, readonly action: "created" | "deleted" | "updated", readonly entityId: string, readonly entityType: string }, readonly "onboarding.flow-changed": { readonly stepId: string }, readonly "outbox.state-changed": { readonly intent: OutboxIntent }, readonly "room.job-stream": RoomJobStreamPayload, readonly "room.turn-stream": RoomTurnStreamPayload, readonly "stage.catalog-invalidated": { readonly reason: string }, readonly "query.invalidated": { readonly name: QueryName }, readonly "stage.registry-changed": { readonly appNames: readonly string[] }, readonly "shell.stage.app-changed": { readonly app: string | null }, readonly "sync.delta-applied": { readonly domain: string, readonly cursor: string }, readonly "transport.state-changed": { readonly state: TransportState }, readonly "connectivity.changed": { readonly reachability: "online" | "unreachable" | "session-required" | "unknown" }, readonly "ip-pool.health-changed": { readonly connectionState: "closed" | "filtered" | "open" | "unknown", readonly consecutiveFailures: number, readonly ipEntryId: string, readonly isHealthy: boolean, readonly latencyMs?: number } }} KernelEventPayloads */
|
|
3
|
+
/** @typedef {{ readonly "client-presence.changed": { readonly deviceId: string }, readonly "client-storage.state-changed": { readonly code?: string, readonly message?: string, readonly status: "ready" | "recovery-required" | "starting" }, readonly "offline.stage-progress-changed": {}, readonly "offline.stage-readiness-changed": { readonly readiness: OfflineStageReadiness }, readonly "offline.identity-invalidated": { readonly scope: OfflineIdentityScope }, readonly "app.data.changed": { readonly appName: string, readonly cursor: string, readonly revision: string, readonly stream: string }, readonly "app.data.committed": { readonly appName: string, readonly cursor: string, readonly revision: string, readonly stream: string }, readonly "device-cleanup.changed": { readonly state?: string }, readonly "domain.entity-changed": { readonly entity?: "push" | string, readonly action: "created" | "deleted" | "updated", readonly entityId: string, readonly entityType: string }, readonly "onboarding.flow-changed": { readonly stepId: string }, readonly "outbox.state-changed": { readonly intent: OutboxIntent }, readonly "room.job-stream": RoomJobStreamPayload, readonly "room.turn-stream": RoomTurnStreamPayload, readonly "stage.catalog-invalidated": { readonly reason: string }, readonly "query.invalidated": { readonly name: QueryName }, readonly "stage.registry-changed": { readonly appNames: readonly string[] }, readonly "shell.stage.app-changed": { readonly app: string | null }, readonly "sync.delta-applied": { readonly domain: string, readonly cursor: string }, readonly "transport.request-loop-suspected": { readonly caller: string, readonly operation: string, readonly action: "suspected" | "cleared", readonly enforced: false }, readonly "transport.request-budget-exceeded": { readonly scope?: "caller" | "total", readonly operation?: string, readonly enforced?: boolean, readonly caller: string, readonly observedRate: number, readonly action: "delayed" | "refused" | "suspended" | "cleared", readonly retryAfterMs: number }, readonly "transport.state-changed": { readonly state: TransportState }, readonly "connectivity.changed": { readonly reachability: "online" | "unreachable" | "session-required" | "unknown" }, readonly "ip-pool.health-changed": { readonly connectionState: "closed" | "filtered" | "open" | "unknown", readonly consecutiveFailures: number, readonly ipEntryId: string, readonly isHealthy: boolean, readonly latencyMs?: number } }} KernelEventPayloads */
|
|
4
4
|
/** @template {KernelEventType} T @typedef {T extends CoreKernelEventType ? KernelEventPayloads[T] : AppEventPayload} KernelEventPayload */
|
|
5
5
|
/** @template {KernelEventType} T @typedef {{ readonly occurredAt: string, readonly payload: KernelEventPayload<T>, readonly type: T }} KernelEventByType */
|
|
6
6
|
/** @typedef {{ readonly occurredAt: string, readonly payload: AppEventPayload, readonly type: AppEventType }} AppDomainEvent */
|
|
@@ -25,8 +25,8 @@ export function appEventScope(value: string): AppEventType | undefined;
|
|
|
25
25
|
export function appEventType(resource: string, instance?: string): AppEventType;
|
|
26
26
|
/** @param {string} value @returns {value is QueryName} */
|
|
27
27
|
export function isQueryName(value: string): value is QueryName;
|
|
28
|
-
/** @type {readonly ["transport.state-changed", "stage.catalog-invalidated", "stage.registry-changed", "query.invalidated", "outbox.state-changed", "domain.entity-changed", "sync.delta-applied", "client-storage.state-changed", "offline.stage-progress-changed", "offline.stage-readiness-changed", "offline.identity-invalidated", "app.data.changed", "app.data.committed", "onboarding.flow-changed", "device-cleanup.changed", "room.turn-stream", "room.job-stream", "connectivity.changed", "ip-pool.health-changed", "shell.stage.app-changed", "client-presence.changed"]} */
|
|
29
|
-
export const KERNEL_EVENT_TYPES: readonly ["transport.state-changed", "stage.catalog-invalidated", "stage.registry-changed", "query.invalidated", "outbox.state-changed", "domain.entity-changed", "sync.delta-applied", "client-storage.state-changed", "offline.stage-progress-changed", "offline.stage-readiness-changed", "offline.identity-invalidated", "app.data.changed", "app.data.committed", "onboarding.flow-changed", "device-cleanup.changed", "room.turn-stream", "room.job-stream", "connectivity.changed", "ip-pool.health-changed", "shell.stage.app-changed", "client-presence.changed"];
|
|
28
|
+
/** @type {readonly ["transport.request-loop-suspected", "transport.request-budget-exceeded", "transport.state-changed", "stage.catalog-invalidated", "stage.registry-changed", "query.invalidated", "outbox.state-changed", "domain.entity-changed", "sync.delta-applied", "client-storage.state-changed", "offline.stage-progress-changed", "offline.stage-readiness-changed", "offline.identity-invalidated", "app.data.changed", "app.data.committed", "onboarding.flow-changed", "device-cleanup.changed", "room.turn-stream", "room.job-stream", "connectivity.changed", "ip-pool.health-changed", "shell.stage.app-changed", "client-presence.changed"]} */
|
|
29
|
+
export const KERNEL_EVENT_TYPES: readonly ["transport.request-loop-suspected", "transport.request-budget-exceeded", "transport.state-changed", "stage.catalog-invalidated", "stage.registry-changed", "query.invalidated", "outbox.state-changed", "domain.entity-changed", "sync.delta-applied", "client-storage.state-changed", "offline.stage-progress-changed", "offline.stage-readiness-changed", "offline.identity-invalidated", "app.data.changed", "app.data.committed", "onboarding.flow-changed", "device-cleanup.changed", "room.turn-stream", "room.job-stream", "connectivity.changed", "ip-pool.health-changed", "shell.stage.app-changed", "client-presence.changed"];
|
|
30
30
|
export type CoreKernelEventType = (typeof KERNEL_EVENT_TYPES)[number];
|
|
31
31
|
export type KernelEventType = AppEventType | CoreKernelEventType;
|
|
32
32
|
export type KernelEventPayloads = {
|
|
@@ -90,6 +90,21 @@ export type KernelEventPayloads = {
|
|
|
90
90
|
readonly domain: string;
|
|
91
91
|
readonly cursor: string;
|
|
92
92
|
};
|
|
93
|
+
readonly "transport.request-loop-suspected": {
|
|
94
|
+
readonly caller: string;
|
|
95
|
+
readonly operation: string;
|
|
96
|
+
readonly action: "suspected" | "cleared";
|
|
97
|
+
readonly enforced: false;
|
|
98
|
+
};
|
|
99
|
+
readonly "transport.request-budget-exceeded": {
|
|
100
|
+
readonly scope?: "caller" | "total";
|
|
101
|
+
readonly operation?: string;
|
|
102
|
+
readonly enforced?: boolean;
|
|
103
|
+
readonly caller: string;
|
|
104
|
+
readonly observedRate: number;
|
|
105
|
+
readonly action: "delayed" | "refused" | "suspended" | "cleared";
|
|
106
|
+
readonly retryAfterMs: number;
|
|
107
|
+
};
|
|
93
108
|
readonly "transport.state-changed": {
|
|
94
109
|
readonly state: TransportState;
|
|
95
110
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/events/index.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/events/index.js"],"names":[],"mappings":"AAqEA,yEAAyE;AACzE,oEAAoE;AAUpE,y7EAAy7E;AACz7E,2IAA2I;AAC3I,4JAA4J;AAC5J,gIAAgI;AAChI,wHAAwH;AAExH,kJAAkJ;AAClJ,kCADoC,CAAC,SAAtB,mBAAoB,SAAW,WAAW,QAAgB,CAAC,GAAiB,KAAK,IAAI,OAAO,CAAC,WAAW,EAAE;IAAE,QAAQ,CAAC,IAAI,EAAE,CAAC,CAAA;CAAE,CAAC,CAG7I;AAED,oEAAoE;AACpE,6CADY,MAAM,GAAkB,KAAK,IAAI,mBAAmB,CAK/D;AAED,6DAA6D;AAC7D,sCADY,MAAM,GAAkB,KAAK,IAAI,YAAY,CAGxD;AAED,gEAAgE;AAChE,yCADY,MAAM,GAAkB,KAAK,IAAI,eAAe,CAG3D;AAED,0DAA0D;AAC1D,wCADY,MAAM,GAAkB,MAAM,GAAG,SAAS,CAGrD;AAED,0DAA0D;AAC1D,wCADY,MAAM,GAAkB,MAAM,GAAG,SAAS,CAGrD;AAED,gEAAgE;AAChE,qCADY,MAAM,GAAkB,YAAY,GAAG,SAAS,CAI3D;AAED,kFAAkF;AAClF,uCADY,MAAM,aAAmB,MAAM,GAAuB,YAAY,CAU7E;AAED,0DAA0D;AAC1D,mCADY,MAAM,GAA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MAAM,CAAC;QAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAA;CAAE;mCAC7R;IAAE,QAAQ,CAAC,GAAG,EAAE,cAAc,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,KAAK,GAAG,UAAU,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,WAAW,CAAA;CAAE"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@econ-v1/domain",
|
|
3
|
-
"version": "7.6.
|
|
3
|
+
"version": "7.6.145",
|
|
4
4
|
"description": "Platform-neutral domain contracts and errors for Node clients",
|
|
5
5
|
"license": "MIT OR Apache-2.0",
|
|
6
6
|
"author": "Node contributors",
|
|
@@ -57,6 +57,6 @@
|
|
|
57
57
|
"access": "public"
|
|
58
58
|
},
|
|
59
59
|
"dependencies": {
|
|
60
|
-
"@econ-v1/ports": "7.6.
|
|
60
|
+
"@econ-v1/ports": "7.6.145"
|
|
61
61
|
}
|
|
62
62
|
}
|
package/src/errors/index.js
CHANGED
|
@@ -72,8 +72,8 @@ export const DOMAIN_ERROR_CODES = [
|
|
|
72
72
|
];
|
|
73
73
|
/** @type {readonly ["outbox_delivery_failed", "sync_conflict", "sync_terminal_failure"]} */
|
|
74
74
|
export const SYNC_ERROR_CODES = ["outbox_delivery_failed", "sync_conflict", "sync_terminal_failure"];
|
|
75
|
-
/** @type {readonly ["connection_lost", "offline", "unavailable"]} */
|
|
76
|
-
export const TRANSPORT_ERROR_CODES = ["connection_lost", "offline", "unavailable"];
|
|
75
|
+
/** @type {readonly ["connection_lost", "offline", "unavailable", "rate_limited"]} */
|
|
76
|
+
export const TRANSPORT_ERROR_CODES = ["connection_lost", "offline", "unavailable", "rate_limited"];
|
|
77
77
|
/**
|
|
78
78
|
* @abstract
|
|
79
79
|
* @template {string} TKind
|
package/src/events/index.js
CHANGED
|
@@ -40,8 +40,10 @@ function parseAppEventType(value) {
|
|
|
40
40
|
return { instance, resource };
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
/** @type {readonly ["transport.state-changed", "stage.catalog-invalidated", "stage.registry-changed", "query.invalidated", "outbox.state-changed", "domain.entity-changed", "sync.delta-applied", "client-storage.state-changed", "offline.stage-progress-changed", "offline.stage-readiness-changed", "offline.identity-invalidated", "app.data.changed", "app.data.committed", "onboarding.flow-changed", "device-cleanup.changed", "room.turn-stream", "room.job-stream", "connectivity.changed", "ip-pool.health-changed", "shell.stage.app-changed", "client-presence.changed"]} */
|
|
43
|
+
/** @type {readonly ["transport.request-loop-suspected", "transport.request-budget-exceeded", "transport.state-changed", "stage.catalog-invalidated", "stage.registry-changed", "query.invalidated", "outbox.state-changed", "domain.entity-changed", "sync.delta-applied", "client-storage.state-changed", "offline.stage-progress-changed", "offline.stage-readiness-changed", "offline.identity-invalidated", "app.data.changed", "app.data.committed", "onboarding.flow-changed", "device-cleanup.changed", "room.turn-stream", "room.job-stream", "connectivity.changed", "ip-pool.health-changed", "shell.stage.app-changed", "client-presence.changed"]} */
|
|
44
44
|
export const KERNEL_EVENT_TYPES = [
|
|
45
|
+
"transport.request-loop-suspected",
|
|
46
|
+
"transport.request-budget-exceeded",
|
|
45
47
|
"transport.state-changed",
|
|
46
48
|
"stage.catalog-invalidated",
|
|
47
49
|
"stage.registry-changed",
|
|
@@ -76,7 +78,7 @@ export const KERNEL_EVENT_TYPES = [
|
|
|
76
78
|
* shape a de-duplication would take — declared in `@econ-v1/ports` and re-exported outward — and
|
|
77
79
|
* is the follow-up if this union ever grows a fifth state.
|
|
78
80
|
*/
|
|
79
|
-
/** @typedef {{ readonly "client-presence.changed": { readonly deviceId: string }, readonly "client-storage.state-changed": { readonly code?: string, readonly message?: string, readonly status: "ready" | "recovery-required" | "starting" }, readonly "offline.stage-progress-changed": {}, readonly "offline.stage-readiness-changed": { readonly readiness: OfflineStageReadiness }, readonly "offline.identity-invalidated": { readonly scope: OfflineIdentityScope }, readonly "app.data.changed": { readonly appName: string, readonly cursor: string, readonly revision: string, readonly stream: string }, readonly "app.data.committed": { readonly appName: string, readonly cursor: string, readonly revision: string, readonly stream: string }, readonly "device-cleanup.changed": { readonly state?: string }, readonly "domain.entity-changed": { readonly entity?: "push" | string, readonly action: "created" | "deleted" | "updated", readonly entityId: string, readonly entityType: string }, readonly "onboarding.flow-changed": { readonly stepId: string }, readonly "outbox.state-changed": { readonly intent: OutboxIntent }, readonly "room.job-stream": RoomJobStreamPayload, readonly "room.turn-stream": RoomTurnStreamPayload, readonly "stage.catalog-invalidated": { readonly reason: string }, readonly "query.invalidated": { readonly name: QueryName }, readonly "stage.registry-changed": { readonly appNames: readonly string[] }, readonly "shell.stage.app-changed": { readonly app: string | null }, readonly "sync.delta-applied": { readonly domain: string, readonly cursor: string }, readonly "transport.state-changed": { readonly state: TransportState }, readonly "connectivity.changed": { readonly reachability: "online" | "unreachable" | "session-required" | "unknown" }, readonly "ip-pool.health-changed": { readonly connectionState: "closed" | "filtered" | "open" | "unknown", readonly consecutiveFailures: number, readonly ipEntryId: string, readonly isHealthy: boolean, readonly latencyMs?: number } }} KernelEventPayloads */
|
|
81
|
+
/** @typedef {{ readonly "client-presence.changed": { readonly deviceId: string }, readonly "client-storage.state-changed": { readonly code?: string, readonly message?: string, readonly status: "ready" | "recovery-required" | "starting" }, readonly "offline.stage-progress-changed": {}, readonly "offline.stage-readiness-changed": { readonly readiness: OfflineStageReadiness }, readonly "offline.identity-invalidated": { readonly scope: OfflineIdentityScope }, readonly "app.data.changed": { readonly appName: string, readonly cursor: string, readonly revision: string, readonly stream: string }, readonly "app.data.committed": { readonly appName: string, readonly cursor: string, readonly revision: string, readonly stream: string }, readonly "device-cleanup.changed": { readonly state?: string }, readonly "domain.entity-changed": { readonly entity?: "push" | string, readonly action: "created" | "deleted" | "updated", readonly entityId: string, readonly entityType: string }, readonly "onboarding.flow-changed": { readonly stepId: string }, readonly "outbox.state-changed": { readonly intent: OutboxIntent }, readonly "room.job-stream": RoomJobStreamPayload, readonly "room.turn-stream": RoomTurnStreamPayload, readonly "stage.catalog-invalidated": { readonly reason: string }, readonly "query.invalidated": { readonly name: QueryName }, readonly "stage.registry-changed": { readonly appNames: readonly string[] }, readonly "shell.stage.app-changed": { readonly app: string | null }, readonly "sync.delta-applied": { readonly domain: string, readonly cursor: string }, readonly "transport.request-loop-suspected": { readonly caller: string, readonly operation: string, readonly action: "suspected" | "cleared", readonly enforced: false }, readonly "transport.request-budget-exceeded": { readonly scope?: "caller" | "total", readonly operation?: string, readonly enforced?: boolean, readonly caller: string, readonly observedRate: number, readonly action: "delayed" | "refused" | "suspended" | "cleared", readonly retryAfterMs: number }, readonly "transport.state-changed": { readonly state: TransportState }, readonly "connectivity.changed": { readonly reachability: "online" | "unreachable" | "session-required" | "unknown" }, readonly "ip-pool.health-changed": { readonly connectionState: "closed" | "filtered" | "open" | "unknown", readonly consecutiveFailures: number, readonly ipEntryId: string, readonly isHealthy: boolean, readonly latencyMs?: number } }} KernelEventPayloads */
|
|
80
82
|
/** @template {KernelEventType} T @typedef {T extends CoreKernelEventType ? KernelEventPayloads[T] : AppEventPayload} KernelEventPayload */
|
|
81
83
|
/** @template {KernelEventType} T @typedef {{ readonly occurredAt: string, readonly payload: KernelEventPayload<T>, readonly type: T }} KernelEventByType */
|
|
82
84
|
/** @typedef {{ readonly occurredAt: string, readonly payload: AppEventPayload, readonly type: AppEventType }} AppDomainEvent */
|
|
@@ -86,7 +86,7 @@ export class DiscoveryProbeService {
|
|
|
86
86
|
|
|
87
87
|
try {
|
|
88
88
|
/** @type {unknown} */
|
|
89
|
-
const metadata = await client.invoke({
|
|
89
|
+
const metadata = await client.invoke({ caller: "kernel:discovery-probe-service",
|
|
90
90
|
operation: "GET /api/v2/node/metadata",
|
|
91
91
|
payload: {},
|
|
92
92
|
});
|
|
@@ -36,14 +36,14 @@ export class InviteRedemptionService {
|
|
|
36
36
|
async #request(purpose, code, confirmation) {
|
|
37
37
|
const publicKey = await this.#keys.publicKey();
|
|
38
38
|
const codeHash = purpose === "redeem" ? await this.#hashCode(code) : "";
|
|
39
|
-
const challenge = await this.#node.invoke({
|
|
39
|
+
const challenge = await this.#node.invoke({ caller: "kernel:invite-redemption-service",
|
|
40
40
|
operation: "POST /api/v2/invite/challenge",
|
|
41
41
|
payload: { public_key: publicKey, purpose, code_hash: codeHash, ...(purpose === "redeem" && confirmation !== undefined ? { onboarding_confirmation: confirmation } : {}) },
|
|
42
42
|
});
|
|
43
43
|
if (challenge === null || typeof challenge !== "object" || typeof challenge.challenge_id !== "string" || typeof challenge.challenge !== "string")
|
|
44
44
|
throw new Error("malformed-challenge");
|
|
45
45
|
const signature = await this.#keys.sign(challenge.challenge);
|
|
46
|
-
return await this.#node.invoke({
|
|
46
|
+
return await this.#node.invoke({ caller: "kernel:invite-redemption-service",
|
|
47
47
|
operation: `POST /api/v2/invite/${purpose}`,
|
|
48
48
|
payload: { public_key: publicKey, challenge_id: challenge.challenge_id, signature,
|
|
49
49
|
...(purpose === "redeem" ? { code, ...(confirmation !== undefined ? { onboarding_confirmation: confirmation } : {}) } : {}) },
|
|
@@ -36,7 +36,7 @@ export class LanCandidateRefreshService {
|
|
|
36
36
|
if (!isNodeId(homeNodeId))
|
|
37
37
|
throw new TypeError("Home node transport identity is not established");
|
|
38
38
|
/** @type {unknown} */
|
|
39
|
-
const response = await home.invoke({
|
|
39
|
+
const response = await home.invoke({ caller: "kernel:lan-candidate-refresh-service",
|
|
40
40
|
operation: "GET /api/v2/client-transport/candidates?features=wan-origins",
|
|
41
41
|
payload: {},
|
|
42
42
|
});
|
|
@@ -42,7 +42,7 @@ export class LcdDecisionService {
|
|
|
42
42
|
// the node's audit log for what is a client-side programming error.
|
|
43
43
|
if (trimmed.length === 0) return "not-accepted";
|
|
44
44
|
try {
|
|
45
|
-
await this.#node.invoke({
|
|
45
|
+
await this.#node.invoke({ caller: "kernel:lcd-decision-service",
|
|
46
46
|
operation,
|
|
47
47
|
payload: { operation_hash: trimmed },
|
|
48
48
|
});
|
|
@@ -44,7 +44,7 @@ export class OnboardingStatusService {
|
|
|
44
44
|
/** @type {boolean | undefined} */
|
|
45
45
|
let claimed;
|
|
46
46
|
try {
|
|
47
|
-
const response = await this.#node.invoke({
|
|
47
|
+
const response = await this.#node.invoke({ caller: "kernel:onboarding-status-service",
|
|
48
48
|
operation: "GET /api/auth/onboarding-status",
|
|
49
49
|
payload: {},
|
|
50
50
|
});
|
|
@@ -49,7 +49,7 @@ export class OwnerClaimService {
|
|
|
49
49
|
*/
|
|
50
50
|
async prepareClaim(accessCode) {
|
|
51
51
|
const publicKeyHex = await this.#crypto.publicKey();
|
|
52
|
-
const prepared = await this.#node.invoke({
|
|
52
|
+
const prepared = await this.#node.invoke({ caller: "kernel:owner-claim-service",
|
|
53
53
|
operation: "POST /api/v2/node/onboarding-prepare",
|
|
54
54
|
payload: {
|
|
55
55
|
public_key_multibase: publicKeyHex,
|
|
@@ -84,7 +84,7 @@ export class OwnerClaimService {
|
|
|
84
84
|
async awaitConfirmation(operationHash) {
|
|
85
85
|
const deadline = Date.now() + CONFIRMATION_TIMEOUT_MS;
|
|
86
86
|
for (;;) {
|
|
87
|
-
const status = await this.#node.invoke({
|
|
87
|
+
const status = await this.#node.invoke({ caller: "kernel:owner-claim-service",
|
|
88
88
|
operation: `GET /api/v2/node/operation-status/${encodeURIComponent(operationHash)}`,
|
|
89
89
|
payload: {},
|
|
90
90
|
});
|
|
@@ -129,7 +129,7 @@ export class OwnerClaimService {
|
|
|
129
129
|
/** @type {OnboardingCompleteWire} */
|
|
130
130
|
let result;
|
|
131
131
|
try {
|
|
132
|
-
const challenge = await this.#node.invoke({
|
|
132
|
+
const challenge = await this.#node.invoke({ caller: "kernel:owner-claim-service",
|
|
133
133
|
operation: "POST /api/auth/onboarding-challenge",
|
|
134
134
|
payload: {},
|
|
135
135
|
});
|
|
@@ -147,7 +147,7 @@ export class OwnerClaimService {
|
|
|
147
147
|
} catch {
|
|
148
148
|
genesisDevice = undefined;
|
|
149
149
|
}
|
|
150
|
-
result = await this.#node.invoke({
|
|
150
|
+
result = await this.#node.invoke({ caller: "kernel:owner-claim-service",
|
|
151
151
|
operation: "POST /api/auth/complete-onboarding",
|
|
152
152
|
payload: {
|
|
153
153
|
challenge_id: challenge.challenge_id,
|
|
@@ -52,7 +52,7 @@ export class PeerDirectoryService {
|
|
|
52
52
|
* @returns {Promise<readonly HomeNodeCandidate[]>}
|
|
53
53
|
*/
|
|
54
54
|
async refreshLanCandidates(home) {
|
|
55
|
-
const metadata = await home.invoke({
|
|
55
|
+
const metadata = await home.invoke({ caller: "kernel:peer-directory-service",
|
|
56
56
|
operation: "GET /api/v2/node/metadata",
|
|
57
57
|
payload: {},
|
|
58
58
|
});
|
|
@@ -307,7 +307,7 @@ export class WalletMirrorService {
|
|
|
307
307
|
return current;
|
|
308
308
|
this.#assertOnline();
|
|
309
309
|
try {
|
|
310
|
-
const response = await this.#homeNode.invoke({ operation: "wallet.authoritative-snapshot", payload: {} });
|
|
310
|
+
const response = await this.#homeNode.invoke({ caller: "kernel:wallet-mirror-service", operation: "wallet.authoritative-snapshot", payload: {} });
|
|
311
311
|
const payload = parseSnapshotPayload(response);
|
|
312
312
|
await this.applyDelta({ cursor: `refresh:${this.#id()}`, id: this.#id(), payload });
|
|
313
313
|
}
|
|
@@ -328,7 +328,7 @@ export class WalletMirrorService {
|
|
|
328
328
|
async #execute(command) {
|
|
329
329
|
this.#assertOnline();
|
|
330
330
|
try {
|
|
331
|
-
const response = await this.#homeNode.invoke({
|
|
331
|
+
const response = await this.#homeNode.invoke({ caller: "kernel:wallet-mirror-service",
|
|
332
332
|
operation: command.payload.kind === "create-invoice" ? "wallet.create-invoice" : "wallet.pay-invoice",
|
|
333
333
|
payload: { ...command.payload, idempotencyKey: command.idempotencyKey },
|
|
334
334
|
});
|
|
@@ -68,7 +68,7 @@ export class WifiProvisioningService {
|
|
|
68
68
|
async status(deadlineMs = STATUS_DEADLINE_MS) {
|
|
69
69
|
try {
|
|
70
70
|
const wire = await Promise.race([
|
|
71
|
-
this.#node.invoke({
|
|
71
|
+
this.#node.invoke({ caller: "kernel:wifi-provisioning-service",
|
|
72
72
|
operation: "GET /api/v2/wifi/status",
|
|
73
73
|
payload: {},
|
|
74
74
|
}),
|
|
@@ -92,7 +92,7 @@ export class WifiProvisioningService {
|
|
|
92
92
|
*/
|
|
93
93
|
async scan() {
|
|
94
94
|
try {
|
|
95
|
-
const wire = await this.#node.invoke({
|
|
95
|
+
const wire = await this.#node.invoke({ caller: "kernel:wifi-provisioning-service",
|
|
96
96
|
operation: "GET /api/v2/wifi/scan",
|
|
97
97
|
payload: {},
|
|
98
98
|
});
|
|
@@ -132,7 +132,7 @@ export class WifiProvisioningService {
|
|
|
132
132
|
};
|
|
133
133
|
if (secret !== undefined) payload.password = secret;
|
|
134
134
|
try {
|
|
135
|
-
const wire = await this.#node.invoke({
|
|
135
|
+
const wire = await this.#node.invoke({ caller: "kernel:wifi-provisioning-service",
|
|
136
136
|
operation: "POST /api/v2/wifi/configure",
|
|
137
137
|
payload,
|
|
138
138
|
});
|
|
@@ -168,7 +168,7 @@ export class WifiProvisioningService {
|
|
|
168
168
|
let reportedTransportLost = false;
|
|
169
169
|
for (;;) {
|
|
170
170
|
try {
|
|
171
|
-
const wire = await this.#node.invoke({ operation, payload: {} });
|
|
171
|
+
const wire = await this.#node.invoke({ caller: "kernel:wifi-provisioning-service", operation, payload: {} });
|
|
172
172
|
consecutiveFailures = 0;
|
|
173
173
|
const status = typeof wire.status === "string" ? wire.status : "";
|
|
174
174
|
if (status === "Connected") return "connected";
|