@cotal-ai/core 0.4.0 → 0.6.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 (45) hide show
  1. package/dist/acls.d.ts +45 -0
  2. package/dist/acls.d.ts.map +1 -0
  3. package/dist/acls.js +86 -0
  4. package/dist/acls.js.map +1 -0
  5. package/dist/agent-file.d.ts +7 -0
  6. package/dist/agent-file.d.ts.map +1 -1
  7. package/dist/agent-file.js +29 -2
  8. package/dist/agent-file.js.map +1 -1
  9. package/dist/channels.d.ts +13 -2
  10. package/dist/channels.d.ts.map +1 -1
  11. package/dist/channels.js +24 -1
  12. package/dist/channels.js.map +1 -1
  13. package/dist/command.d.ts +3 -0
  14. package/dist/command.d.ts.map +1 -1
  15. package/dist/endpoint.d.ts +341 -61
  16. package/dist/endpoint.d.ts.map +1 -1
  17. package/dist/endpoint.js +1178 -205
  18. package/dist/endpoint.js.map +1 -1
  19. package/dist/index.d.ts +3 -0
  20. package/dist/index.d.ts.map +1 -1
  21. package/dist/index.js +3 -0
  22. package/dist/index.js.map +1 -1
  23. package/dist/lease.d.ts +40 -0
  24. package/dist/lease.d.ts.map +1 -0
  25. package/dist/lease.js +64 -0
  26. package/dist/lease.js.map +1 -0
  27. package/dist/members.d.ts +93 -0
  28. package/dist/members.d.ts.map +1 -0
  29. package/dist/members.js +193 -0
  30. package/dist/members.js.map +1 -0
  31. package/dist/provision.d.ts +38 -13
  32. package/dist/provision.d.ts.map +1 -1
  33. package/dist/provision.js +121 -17
  34. package/dist/provision.js.map +1 -1
  35. package/dist/streams.d.ts +48 -23
  36. package/dist/streams.d.ts.map +1 -1
  37. package/dist/streams.js +101 -32
  38. package/dist/streams.js.map +1 -1
  39. package/dist/subjects.d.ts +85 -4
  40. package/dist/subjects.d.ts.map +1 -1
  41. package/dist/subjects.js +134 -4
  42. package/dist/subjects.js.map +1 -1
  43. package/dist/types.d.ts +128 -5
  44. package/dist/types.d.ts.map +1 -1
  45. package/package.json +2 -2
@@ -1,5 +1,6 @@
1
1
  import { EventEmitter } from "node:events";
2
- import type { AgentCard, ChannelConfig, ControlReply, ControlRequest, ControlRequestInit, EndpointRef, Part, Presence, PresenceStatus, CotalMessage } from "./types.js";
2
+ import type { AgentCard, ChannelConfig, ControlReply, ControlRequest, ControlRequestInit, EndpointRef, Part, Presence, PresenceStatus, AttentionMode, ChannelMode, CotalMessage, DeliveryClass } from "./types.js";
3
+ import { type DeliveryLeaseInfo } from "./lease.js";
3
4
  export declare const DEFAULT_SERVER = "nats://127.0.0.1:4222";
4
5
  /** Space joined when none is given on the CLI (the `cotal-<space>` cmux tab, etc.). */
5
6
  export declare const DEFAULT_SPACE = "main";
@@ -33,6 +34,9 @@ export interface EndpointOptions {
33
34
  watchPresence?: boolean;
34
35
  /** Create inbound stream consumers (DM / chat / anycast). Default true; a pure observer sets false. */
35
36
  consume?: boolean;
37
+ /** Initial per-channel attention overrides to publish in presence from the first heartbeat (the
38
+ * connector's file-default seed). Mirror only — never read back into delivery. */
39
+ channelModes?: Record<string, ChannelMode>;
36
40
  /** How long an unacked (un-surfaced) message waits before redelivery (ms). */
37
41
  ackWaitMs?: number;
38
42
  /** Retire this instance's durable consumers after it's been gone this long (ms). */
@@ -47,18 +51,9 @@ export interface ChannelMember {
47
51
  role?: string;
48
52
  live: boolean;
49
53
  }
50
- /**
51
- * Events: "message" (CotalMessage), "presence" (PresenceEvent), "roster" (Presence[]), "error" (Error),
52
- * "connection" ({ connected: boolean }) — true on every successful (re)bind (initial start, manual
53
- * reconnect, AND background self-heal), false the moment the connection drops (rebuild null window /
54
- * terminal close). Lets an in-process agent track connectedness off the endpoint's own (re)binds
55
- * instead of an imperative flag the self-heal path can't reach.
56
- *
57
- * Callers MUST attach an "error" listener before `start()`: async faults (incl. NATS
58
- * permission denials, surfaced via `watchStatus`) are emitted as "error", and Node throws
59
- * synchronously on an unhandled "error" — a missing listener turns any such fault into a
60
- * process crash instead of a logged denial.
61
- */
54
+ /** A value or a promise of it — the Plane-3 `aclFor` reads the durable ACL registry FRESH per entry
55
+ * (async), so the reader/fan-out call sites await it. */
56
+ type MaybePromise<T> = T | Promise<T>;
62
57
  export declare class CotalEndpoint extends EventEmitter {
63
58
  readonly card: AgentCard;
64
59
  readonly space: string;
@@ -81,6 +76,18 @@ export declare class CotalEndpoint extends EventEmitter {
81
76
  private jsm?;
82
77
  private kv?;
83
78
  private channelKv?;
79
+ /** Plane-3 durable-membership registry KV — lazily opened by the privileged delivery daemon (or a
80
+ * short-lived provisioner). */
81
+ private membersKv?;
82
+ private aclKv?;
83
+ private deliveryKv?;
84
+ /** The live `ctl.delivery` serve subscription (delivery daemon) — re-created on every (re)connect by
85
+ * {@link armDeliveryControl}; tracked so the stale one is dropped on reconnect. */
86
+ private deliveryServeSub?;
87
+ /** When set, this endpoint hosts the Plane-3 fan-out writer + trusted reader (the server-side delivery
88
+ * daemon). `aclFor` maps an owner id to its current read ACL (`allowSubscribe`) for the reader's
89
+ * re-authorization — read FRESH per entry from the durable ACL registry KV, hence async. */
90
+ private plane3?;
84
91
  /** Live local cache of the channel registry (key = channel token), kept by a KV watch. */
85
92
  private readonly channelConfigs;
86
93
  private channelDefaults;
@@ -94,11 +101,51 @@ export declare class CotalEndpoint extends EventEmitter {
94
101
  private histLock;
95
102
  private readonly subs;
96
103
  private readonly streamMsgs;
104
+ /** Per-channel native core subscriptions (SPEC v0.3) — the manager-free live read path for boot +
105
+ * runtime channels (there is no per-instance chat durable). Keyed by channel so leave unsubscribes
106
+ * just one. */
107
+ private readonly chatSubs;
108
+ /** Channels whose core-sub the broker refused (async sub.allow violation) — read by the
109
+ * broker-confirmed join: a denied subscribe is NOT a successful join (SPEC conformance #13). */
110
+ private readonly chatSubDenied;
111
+ /** Channels this session has a Plane-3 durable backstop for (per-channel join GENERATION, from
112
+ * durableJoin, so leave passes it back for the stale-leave guard). A durable channel's core-sub is
113
+ * NOT coverage-dropped — it stays a live wake-hint, dedup-coalesced with the Plane-3 durable copy by
114
+ * id-dedup. Drives the durable-state surface + routes leave to `durableLeave`. PERSISTS across
115
+ * reconnect (like `this.channels`): the membership record + the `dlv_<id>` durable are persistent so
116
+ * the backstop survives a reconnect on its own; the agent can't re-read the privileged members KV,
117
+ * so this in-memory mirror is kept, not rebuilt. Cleared only on full stop. */
118
+ private readonly plane3Channels;
119
+ /** Channels whose live sub was REFUSED while they held a Plane-3 durable membership, whose §7
120
+ * tombstone has not yet confirmed (channel → join generation). {@link closeRefusedMembership} retries
121
+ * the tombstone until it lands; until then this is a `durable-unclosed` state surfaced via
122
+ * {@link pendingDurableLeaves} (the connector shows it in `cotal_channels`, never as ordinary
123
+ * absence). Persists across reconnect; cleared on tombstone success or full stop. */
124
+ private readonly pendingDurableLeave;
125
+ /** Boot durable channels whose self-join hasn't yet established a membership (daemon down/absent at
126
+ * first connect, or a transient `durable:false`). {@link reconcileBootJoin} retries with capped
127
+ * backoff until the membership exists or the channel is left — so a first-connect daemon outage
128
+ * self-heals on recovery instead of leaving the channel silently live-only. Surfaced to the connector
129
+ * via {@link hasDurableMembership} (a joined durable channel NOT yet a member renders degraded). */
130
+ private readonly pendingBootJoins;
131
+ /** Chat-join subjects currently being broker-confirmed. An out-of-ACL subscribe among these trips an
132
+ * EXPECTED async permission violation that joinChannel turns into a clean throw, so watchStatus
133
+ * suppresses it rather than surfacing a spurious connection error. */
134
+ private readonly confirmingChatSubs;
135
+ /** True until the first successful connect completes its boot backfill — distinguishes first-connect
136
+ * (backfill the boot channels' history) from a reconnect (reopen the core-subs, no re-backfill).
137
+ * Persists across reconnect (NOT connection-scoped). Replaces the legacy chat-durable consumed-cursor
138
+ * signal now that there is no per-instance chat durable. */
139
+ private firstConnect;
97
140
  private heartbeatTimer?;
98
141
  private sweepTimer?;
99
142
  private readonly roster;
100
143
  private status;
101
144
  private activity?;
145
+ /** Mirror of the connector's authoritative attention state, published in presence (advisory). The
146
+ * endpoint never reads these back into delivery — they exist only to broadcast. */
147
+ private attentionMode?;
148
+ private channelModes?;
102
149
  private stopped;
103
150
  /** In-flight rebuild (drain+rebind) — serializes manual reconnect, the supervisor's
104
151
  * closed(), and reestablishLoop so only ONE rebuild runs at a time (a second trigger
@@ -191,44 +238,75 @@ export declare class CotalEndpoint extends EventEmitter {
191
238
  tap(handler: (subject: string, msg: CotalMessage | undefined) => void, opts?: {
192
239
  subject?: string;
193
240
  }): void;
194
- /** Serve control requests for a service (manager side). */
195
- serveControl(service: string, handler: (req: ControlRequest) => Promise<ControlReply> | ControlReply): void;
241
+ /** Serve control requests for a service. Returns the subscription so a caller that re-registers on
242
+ * reconnect (the delivery daemon) can drop the stale one. `boundReply` is REQUIRED for any service
243
+ * whose responder holds a wildcard publish grant over the service subtree (the delivery daemon's
244
+ * `ctl.delivery.*.reply.>`): without it, an authenticated caller could set its reply target to a
245
+ * PEER's reply lane (`ctl.delivery.<victim>.reply.<n>`) and turn the responder into a confused
246
+ * deputy — the broker does NOT permission-check the requester's embedded reply subject. With it, a
247
+ * reply is published only when `m.reply` is under the AUTHENTICATED request subject
248
+ * (`${m.subject}.reply.…`), binding the reply to the broker-policed sender token. (The manager's
249
+ * tiers reply into the per-id `_INBOX` and leave it off.) */
250
+ serveControl(service: string, handler: (req: ControlRequest) => Promise<ControlReply> | ControlReply, opts?: {
251
+ boundReply?: boolean;
252
+ }): import("@nats-io/transport-node").Subscription;
196
253
  /** Send a control request to a service and await its reply (client side). */
197
254
  requestControl(service: string, req: ControlRequestInit, timeoutMs?: number): Promise<ControlReply>;
255
+ /** Send a durable-membership request to the SERVER-SIDE delivery daemon (`ctl.delivery`) and await its
256
+ * reply. Unlike {@link requestControl}, the reply rides a subject UNDER `ctl.delivery.<id>.>` (not the
257
+ * per-id `_INBOX`), so the scoped delivery cred can answer without broad inbox-publish — see
258
+ * CONTROL_DELIVERY. `noMux` lets us name the reply subject while keeping NoResponders detection (so a
259
+ * caller can fail-closed vs. degrade to live-only when no daemon is present). */
260
+ private requestDelivery;
198
261
  getRoster(): Presence[];
199
262
  setActivity(activity: string): Promise<void>;
200
263
  setStatus(status: PresenceStatus): Promise<void>;
264
+ /** Publish the agent's global attention mode into presence (advisory observability). Mirror only —
265
+ * delivery decisions stay in the connector's authoritative state. */
266
+ setAttention(attention: AttentionMode): Promise<void>;
267
+ /** Publish the agent's per-channel attention overrides into presence (advisory). An empty map drops
268
+ * the field. Mirror only — never read back into delivery. */
269
+ setChannelModes(modes: Record<string, ChannelMode>): Promise<void>;
270
+ /** Overlay the host's live model onto the card's display-only `meta.model` and republish presence.
271
+ * For connectors that learn the actual model only *after* launch (e.g. Claude Code's `SessionStart`
272
+ * hook payload) rather than from an operator pin. Display-only discovery metadata; a no-op when the
273
+ * value is empty or already current (no redundant publish). The mutated card is read live by every
274
+ * later publish, so even a pre-connect call surfaces on the first presence write. */
275
+ setCardModel(model: string): Promise<void>;
201
276
  /** This channel's registry config from the live local cache (undefined if unset). */
202
277
  getChannelConfig(channel: string): ChannelConfig | undefined;
203
278
  /** Effective replay-on-join policy for a channel: per-channel override ?? space default ??
204
279
  * true. Reads the live cache, so it reflects runtime registry edits. */
205
280
  channelReplay(channel: string): boolean;
281
+ /** Effective delivery class for a channel (per-channel override ?? space default ?? "durable"),
282
+ * from the live watch cache — drives the non-gating delivery-health surface (only durable-class
283
+ * channels have a Plane-3 backstop to report on). */
284
+ channelDeliveryClass(channel: string): DeliveryClass;
206
285
  /** The channels this endpoint is currently subscribed to (live — reflects join/leave). */
207
286
  joinedChannels(): string[];
208
287
  /**
209
- * Join a channel mid-session: add it to our chat durable's `filter_subjects` (same durable,
210
- * same ack-floor, no teardown `update` rides the self-scoped create grant), capture the
211
- * stream frontier as this channel's join watermark, and backfill its history if replay is on.
212
- * Idempotent: re-joining a channel already in our filter is a no-op (no re-backfill). Returns
213
- * the number of historical messages backfilled (emitted as `historical` "message" events).
288
+ * Join a channel mid-session: open a native core subscription (manager-free live read, broker-
289
+ * confirmed against `sub.allow`), capture the stream frontier as the join watermark, backfill its
290
+ * history if replay is on, and for a `durable`-class channel when a delivery daemon is present —
291
+ * request a Plane-3 durable backstop (via `ctl.delivery`). Idempotent: re-joining is a no-op (no
292
+ * re-backfill). Returns the backfill count + whether the durable backstop is active (+ a `reason`
293
+ * when a durable channel couldn't get one).
214
294
  */
215
295
  joinChannel(channel: string): Promise<{
216
296
  joined: boolean;
217
297
  backfilled: number;
298
+ durable: boolean;
299
+ reason?: string;
218
300
  }>;
219
- /** Leave a channel mid-session: drop it from the durable's `filter_subjects`. Refuses to leave
220
- * the *last* channel (an empty filter would match every chat subject the opposite of
221
- * leaving). Returns whether anything changed. */
301
+ /** Leave a channel mid-session MANAGER-FREE for the live read: close the core subscription. For a
302
+ * Plane-3 durable channel, the membership is tombstoned FIRST at the leave cursor (SPEC §7: leave is
303
+ * a hard read boundary for the backstop — a pre-leave entry stays deliverable, `seq > leaveCursor` is
304
+ * denied). FAIL-CLOSED: if the tombstone can't be confirmed the call throws and the leave is NOT
305
+ * applied (live sub stays up, local mirror intact) so the caller can retry — never close the live
306
+ * read while the backstop keeps delivering. */
222
307
  leaveChannel(channel: string): Promise<{
223
308
  left: boolean;
224
309
  }>;
225
- /** Move the chat live-tail durable to a new channel set. OPEN mode self-serves the
226
- * `consumers.update` (the agent owns its durable). AUTH mode is bind-only — the agent has no
227
- * UPDATE grant — so it sends a mediated control request to the manager, which validates the set
228
- * ⊆ its `allowSubscribe` before moving the filter. Throws clearly when no privileged responder is
229
- * present: a manager-less standalone auth session is fixed to its boot subscribe set — a
230
- * documented limitation, not a silent degrade. */
231
- private setChatFilter;
232
310
  /** One coherent channel model for dashboards: every channel that has messages OR a registry
233
311
  * entry (configured-but-empty), each tagged with its {@link ChannelConfig}. Works even on
234
312
  * observer endpoints (no consumers needed). */
@@ -238,20 +316,15 @@ export declare class CotalEndpoint extends EventEmitter {
238
316
  config?: ChannelConfig;
239
317
  }[]>;
240
318
  /**
241
- * Who is subscribed to a channel — **broker truth, not self-report**. In Cotal a peer
242
- * joins a channel by creating a chat-stream durable consumer (`chat_<id>`,
243
- * `filter_subjects` = its channels), so `consumers.list(CHAT)` already records the real
244
- * membership; we join it with presence so a lingering durable for a gone peer shows as a
245
- * stale ghost (`live: false`) rather than a phantom listener.
246
- *
247
- * `channelMembers("review")` that channel's members; `channelMembers()` every channel
248
- * mapped to its members. A member on a wildcard (`team.>`) counts for every concrete
249
- * channel it subsumes (`team.backend`) membership is the *effective subscription*.
250
- *
251
- * Privileged read: `consumers.list` needs `$JS.API.CONSUMER.LIST.<chat stream>`, which only
252
- * the allow-all manager profile holds today (agents, observer, and admin are all denied), so
253
- * this is not an agent-facing capability — serving it from a dashboard profile is a one-line
254
- * ACL grant away.
319
+ * Who is a durable member of a channel — read from the privileged members registry (Plane-3),
320
+ * joined with presence for liveness (a member whose peer is gone but lingering shows `live:false`,
321
+ * not a phantom). Only CURRENT, ACTIVATED members (non-tombstoned, and past activation catch-up — a
322
+ * join still completing or that failed catch-up reported durable:false and stays hidden here until
323
+ * confirmed, so this surface never overstates membership). A wildcard registry channel would count for
324
+ * the concrete channels it subsumes, but durable membership is per-concrete-channel, so records are
325
+ * concrete. `live`-class channels carry no durable record membership there is the live core-sub,
326
+ * not tracked here. Privileged read (the members KV is manager-write/read; agents hold no grant), so
327
+ * it is served by the manager, not an agent capability.
255
328
  */
256
329
  channelMembers(channel: string): Promise<ChannelMember[]>;
257
330
  channelMembers(): Promise<Map<string, ChannelMember[]>>;
@@ -287,21 +360,6 @@ export declare class CotalEndpoint extends EventEmitter {
287
360
  /** Create the three backing streams for this space (idempotent). Open-mode lazy create;
288
361
  * the same definitions are used by `cotal up` at privileged setup. */
289
362
  private ensureStreams;
290
- /**
291
- * Privileged: pre-create an agent's bind-only chat live-tail durable (auth mode), filtered to its
292
- * `subscribe` set, so the agent can BIND it without holding CONSUMER.CREATE/UPDATE on CHAT — its
293
- * live read can't be self-widened past `allowSubscribe`. The creator sets the filter; the agent
294
- * never does (mirrors {@link provisionDmInbox}). Idempotent. The caller must be permissive on CHAT.
295
- */
296
- provisionChatDurable(targetId: string, subscribe: string[]): Promise<void>;
297
- /**
298
- * Privileged: move an agent's bind-only chat durable to a new channel set — the write half of the
299
- * mediated join/leave. The manager calls this AFTER validating the set ⊆ the agent's
300
- * `allowSubscribe`; the agent itself has no UPDATE grant, so this trusted path is the only way its
301
- * live filter moves. The filter is rebuilt from channel names here (not from agent-supplied
302
- * subjects) so a caller can't smuggle a hand-built filter.
303
- */
304
- setChatFilterFor(targetId: string, channels: string[]): Promise<void>;
305
363
  /**
306
364
  * Privileged: pre-create an agent's DM inbox durable (auth mode), so the agent can BIND
307
365
  * it without holding CONSUMER.CREATE on DM_<space>. The creator sets the filter to
@@ -310,6 +368,14 @@ export declare class CotalEndpoint extends EventEmitter {
310
368
  * safe to call again on manager restart. The caller must be permissive on DM_<space>.
311
369
  */
312
370
  provisionDmInbox(targetId: string): Promise<void>;
371
+ /**
372
+ * Privileged: pre-create an agent's bind-only Plane-3 DELIVER durable (`dlv_<id>`, filtered to
373
+ * `dlv.<id>`), so the agent can BIND its per-member durable handoff without holding CONSUMER.CREATE
374
+ * on the DLV stream. Same bind-only model as {@link provisionDmInbox}: the creator sets the filter,
375
+ * the agent never does. The trusted reader transfers re-authorized copies onto `dlv.<id>`; the agent
376
+ * acks them via native JetStream (SPEC §8). Idempotent. The caller must be permissive on DLV.
377
+ */
378
+ provisionDlvInbox(targetId: string): Promise<void>;
313
379
  /**
314
380
  * Privileged: pre-create a role's shared TASK work-queue durable (auth mode), so agents
315
381
  * of that role can BIND it without holding CONSUMER.CREATE on TASK_<space>. The creator
@@ -317,6 +383,204 @@ export declare class CotalEndpoint extends EventEmitter {
317
383
  * Idempotent per role. The caller must be permissive on TASK_<space>.
318
384
  */
319
385
  provisionTaskQueue(role: string): Promise<void>;
386
+ /** Lazily open the privileged members registry KV (delivery daemon / open-mode self). */
387
+ private membersRegistry;
388
+ /** Lazily open the durable read-ACL registry KV. Privileged write (the manager records an agent's
389
+ * ACL at mint); the delivery daemon reads it fresh per durable entry to re-authorize. */
390
+ private aclRegistry;
391
+ /** Privileged ({@link DurableProvisioner}): record an agent's read ACL in the durable registry at
392
+ * provision/mint time — the same act as baking it into the JWT, persisted so the server-side
393
+ * delivery daemon can re-authorize the agent's durable entries and validate its runtime
394
+ * durable-joins without holding any in-memory ledger. Written ATOMICALLY ({@link writeAclRecord}),
395
+ * so a present record is always complete (`[]` = known no-read, never a half-write). */
396
+ commitAcl(targetId: string, allowSubscribe: string[]): Promise<void>;
397
+ /** The server-side delivery daemon's fresh-per-entry ACL read: an owner's CURRENT read ACL
398
+ * (`allowSubscribe`) from the durable registry, or `undefined` if no record (an unknown owner — the
399
+ * reader DEFERS, never drops). A present `[]` (known no-read) returns `[]` (the reader DROPS). */
400
+ aclForOwner(owner: string): Promise<string[] | undefined>;
401
+ /** Lazily open the delivery lease/readiness KV (pre-created at `cotal up`; bind, never create). */
402
+ private deliveryRegistry;
403
+ private encodeLease;
404
+ /** Acquire the single-flight delivery lease for a shard via an ATOMIC CAS create, marked NOT-ready.
405
+ * THROWS if a live lease exists — a loud refusal-to-bind (the daemon exits), never a retry, so two
406
+ * daemons can't split a durable's delivery. A crashed holder's lease auto-expires (bucket TTL),
407
+ * freeing a re-acquire. Acquired BEFORE binding (single-flight gate); {@link markDeliveryLeaseReady}
408
+ * flips it ready AFTER the loops + `ctl.delivery` are bound. Returns the lease revision. */
409
+ acquireDeliveryLease(shardIndex: number): Promise<number>;
410
+ /** Flip the held lease to READY (CAS `kv.update`) AFTER `startPlane3` has bound the loops + the
411
+ * `ctl.delivery` responder — so "lease ready" proves the responder is up, not just that the slot was
412
+ * claimed. Returns the new revision. */
413
+ markDeliveryLeaseReady(shardIndex: number, revision: number): Promise<number>;
414
+ /** Renew the held lease (CAS `kv.update` against `revision`, keeping `ready:true`) to refresh it before
415
+ * the bucket TTL expires it. Returns the new revision. Throws if the revision moved (lost the lease —
416
+ * the daemon should exit). */
417
+ renewDeliveryLease(shardIndex: number, revision: number): Promise<number>;
418
+ /** Release the held lease on clean shutdown so a replacement daemon re-acquires immediately (best
419
+ * effort — a crash just lets the bucket TTL expire it). */
420
+ releaseDeliveryLease(shardIndex: number): Promise<void>;
421
+ /** Read a shard's delivery lease (the daemon-availability signal), or `undefined` if none is live.
422
+ * READ-ONLY surface — drives Component 6's `cotal_channels` delivery-health field (an agent reads it
423
+ * under its own cred, which holds lease-bucket read but no write). */
424
+ readDeliveryLease(shardIndex: number): Promise<DeliveryLeaseInfo | undefined>;
425
+ /** Privileged: one owner's NON-TOMBSTONED durable memberships as `{channel, generation, activated}` —
426
+ * the server-side delivery daemon serves this to a connecting agent (the `listMemberships` op on
427
+ * `ctl.delivery`). The agent seeds its leave mirror from the ACTIVATED ones (the confirmed backstops),
428
+ * but the non-activated ones are returned too so `leaveChannel` can discover + close a record that
429
+ * still routes under the pure-interval predicate (a crash-stuck pending activation) — without reading
430
+ * the privileged KV itself. */
431
+ ownerMemberships(owner: string): Promise<{
432
+ channel: string;
433
+ generation: number;
434
+ activated: boolean;
435
+ }[]>;
436
+ /** Effective delivery class read AUTHORITATIVELY from the registry KV (not the watch cache) — so a
437
+ * `live`→`durable` flip is seen by fan-out without a cache-propagation gap (red-team MED-3). */
438
+ private deliveryClassFresh;
439
+ /** Collision-safe `@mention` → owner-id resolution: a name that resolves to exactly one present
440
+ * peer wins; 0 or >1 matches drop (never fan a directed durable copy to an unrelated same-named
441
+ * bystander — red-team LOW; SPEC §4 unique instance id). */
442
+ private resolveOwnerByName;
443
+ /** Publish one fan-out entry into an owner's mixed inbox, idempotent via `Nats-Msg-Id`
444
+ * (`<msgId>:<owner>:<generation>`) so a catch-up copy and a racing fan-out copy collapse. */
445
+ private publishDinbox;
446
+ /** The fan-out consumer's delivered stream-seq — the activation-fence upper bound (red-team
447
+ * BLOCKER-1: the shared fan-out cursor advances independently of the stream frontier). */
448
+ private fanoutDeliveredSeq;
449
+ /**
450
+ * Privileged durable-JOIN write (v3: the delivery daemon calls this from its `ctl.delivery` handler
451
+ * after validating channel ⊆ the caller's read ACL): capture `joinCursor`, commit a `durable-active`
452
+ * record (CAS + generation bump), then ACTIVATION CATCH-UP idempotently copies `(joinCursor, fence]`
453
+ * into the owner inbox where `fence = max(frontier, fanoutDelivered)` — fan-out owns `seq > fence`.
454
+ * Idempotent against a timeout-retry (an already-activated membership no-ops). Returns `{durable:false}`
455
+ * (honest degrade) only if the catch-up window was evicted.
456
+ *
457
+ * Runs on the daemon (which hosts the fan-out/reader loops + the members KV), so catch-up + the
458
+ * activation fence read are in-process — no cross-process cursor read.
459
+ */
460
+ durableJoinFor(owner: string, channel: string): Promise<{
461
+ durable: boolean;
462
+ reason?: string;
463
+ generation?: number;
464
+ }>;
465
+ /** Privileged durable-LEAVE write: tombstone the membership at `leaveCursor = frontier` so the
466
+ * backstop denies `seq > leaveCursor` while a pre-leave entry stays deliverable (SPEC §7 interval). */
467
+ durableLeaveFor(owner: string, channel: string, expectedGeneration?: number): Promise<void>;
468
+ /** Idempotently copy the eligible chat messages in `(fromSeqExcl, toSeqIncl]` for `channel` into the
469
+ * owner inbox, via a DEDICATED per-(owner,join) ephemeral consumer (NOT the agent-scoped
470
+ * `chathist_<id>`/`histLock` — red-team HIGH-8). `evicted` ⇒ the oldest eligible seq aged out under
471
+ * `discard=Old` (the start seq could not be served), a durable shortfall the caller surfaces. */
472
+ private catchupCopy;
473
+ /** Start the Plane-3 fan-out writer + trusted reader on THIS (privileged, server-side delivery-daemon)
474
+ * endpoint, AND serve the `ctl.delivery` control service (runtime durable join/leave/list). `aclFor`
475
+ * maps an owner id to its current read ACL for the reader's re-authorization — read FRESH per entry
476
+ * from the durable ACL registry (async). Call once after connect; idempotent durable creation lets it
477
+ * resume on a daemon restart. Both the JS loops AND the `ctl.delivery` subscription are (re)bound by
478
+ * {@link armPlane3} on EVERY (re)connect — a reconnect drains the old connection, so re-binding both
479
+ * is required, not optional (the responder would otherwise be lost on a broker blip). */
480
+ startPlane3(aclFor: (owner: string) => MaybePromise<string[] | undefined>): Promise<void>;
481
+ /** Serve one runtime durable-membership control request (the server-side delivery daemon). The caller
482
+ * id is the authenticated subject sender ({@link serveControl} fail-closes on a mismatch). Validation
483
+ * is against the durable ACL registry — the SAME KV the reader re-auths against (single source of
484
+ * truth, no in-memory ledger to drift). */
485
+ private handleDeliveryControl;
486
+ /** Validate the channel ARG shape only — non-blank, valid, concrete (NO ACL check, that is op-specific).
487
+ * Returns the channel on success or a ControlReply error to short-circuit. */
488
+ private checkDurableChannelArg;
489
+ /** JOIN requires the channel be within the caller's CURRENT read ACL (you can't durable-subscribe a
490
+ * channel you may not read). */
491
+ private deliveryJoin;
492
+ /** LEAVE must NOT require current-ACL coverage. Leave fires precisely when the ACL was narrowed/revoked
493
+ * (a refused live sub → {@link closeRefusedMembership}); gating the tombstone on the current ACL would
494
+ * loop forever and leave the SPEC §7 boundary open (the membership could resume if the ACL is later
495
+ * restored). The guards are: authenticated caller (serveControl), concrete channel, a finite generation
496
+ * (the join epoch — without it a stale/replayed leave could tombstone a newer rejoin), and an EXISTING
497
+ * own membership; `durableLeaveFor` → `tombstoneMember` then enforces the generation match. */
498
+ private deliveryLeave;
499
+ /** (Re)bind the Plane-3 fan-out writer + trusted reader. Idempotent — the durables resume from their
500
+ * cursor. Called by {@link startPlane3} once AND by {@link connectAndBind} on every (re)connect, so
501
+ * the delivery daemon's reconnect RE-ARMS the backstop + the ctl.delivery responder. Without this, a broker blip would silently kill
502
+ * the loops while `durableJoinFor` kept reporting `durable:true` (the impl-review's BLOCKER-1). No-op
503
+ * unless this endpoint hosts Plane-3 (`this.plane3` set). */
504
+ private armPlane3;
505
+ /** (Re)register the `ctl.delivery` control responder on the CURRENT connection. A reconnect drains the
506
+ * old connection (the old sub is dead and `clearConnectionScoped` leaves caller-owned subs alone), so
507
+ * this MUST run on every arm — otherwise durable join/leave/list silently lose their responder after a
508
+ * broker blip. The stale sub is dropped (unsubscribed + removed from `this.subs`) before re-creating.
509
+ * `boundReply` is essential here: the daemon holds a wildcard reply-publish grant, so the serve path
510
+ * must reject any reply target outside the authenticated sender's own subtree (confused-deputy fix). */
511
+ private armDeliveryControl;
512
+ /** Fan-out loop: bind the privileged `fanout` durable on CHAT and route each message (routing only —
513
+ * the trusted reader is the auth gate). */
514
+ private runFanout;
515
+ /** Route ONE chat message to eligible owners' mixed inboxes. `durable` channel → its `durable-active`
516
+ * members within interval; `live` channel → `@mention` targets authorized to read it (ACL only).
517
+ * Members KV is scanned FRESH per message (no cache — red-team BLOCKER-1 catch-up correctness). */
518
+ private fanOutMessage;
519
+ /** Trusted-reader loop: bind the single privileged `reader` durable over `dinbox.>` and re-authorize
520
+ * + transfer each entry. */
521
+ private runReader;
522
+ /** Re-authorize ONE mixed-inbox entry and transfer it to the owner's DELIVER store. Deny (drop) on a
523
+ * revoked/narrowed ACL or out-of-interval seq; on transfer success, ack the mixed entry (durability
524
+ * has moved to DLV — an §8 equivalent per-member at-least-once mechanism). The agent acks DLV. */
525
+ private readerHandle;
526
+ /** Agent-side: bind + pump our pre-created Plane-3 DELIVER durable (`dlv_<id>`). Every message here is
527
+ * delivery-daemon-written (DLV is delivery-write-only, broker-enforced) and is a CHANNEL message by contract
528
+ * (the backstop never carries DMs), so `kind=channel` is path-derived (SPEC §4) and the body is
529
+ * trusted (no spoof-guard). `durable:true` — real JetStream ack, coalesced with the core-sub live
530
+ * copy by `MeshAgent.ingest`. No-op when the durable isn't present (open mode / not provisioned). */
531
+ private pumpDlv;
532
+ /** Agent-side: request a Plane-3 durable backstop for a channel via the server-side delivery daemon (ctl.delivery). Throws
533
+ * when no privileged writer is present (open / no delivery daemon). 30s timeout — activation catch-up may
534
+ * run before the reply (the window is small, but a busy channel can take more than the 5s default). */
535
+ durableJoinChannel(channel: string): Promise<{
536
+ durable: boolean;
537
+ reason?: string;
538
+ generation?: number;
539
+ }>;
540
+ /** Agent-side: release a Plane-3 durable backstop (tombstone membership at the leave cursor). Passes
541
+ * the join generation so a stale leave can't tombstone a newer rejoin (the delivery daemon validates it). */
542
+ durableLeaveChannel(channel: string, generation?: number): Promise<void>;
543
+ /** Fail-closed async cleanup for a channel forced out by a LATE sub.allow refusal (the broker revoked
544
+ * the live read). The sync sub callback can't await, so this RETRIES the Plane-3 tombstone with capped
545
+ * backoff UNTIL IT SUCCEEDS (or the endpoint stops) — the §7 boundary always closes once the manager
546
+ * is reachable, never a silent give-up. While pending, the channel is tracked in
547
+ * {@link pendingDurableLeave} and surfaced via {@link pendingDurableLeaves} (the connector shows it in
548
+ * `cotal_channels` as `durable-unclosed`, never ordinary absence). The generation is kept the whole
549
+ * time. Authoritative closure of a revoked membership is also handled by revocation (rotate creds + tear down). */
550
+ private closeRefusedMembership;
551
+ /** Channels with a Plane-3 durable membership whose §7 tombstone is still pending after a refused live
552
+ * sub (see {@link closeRefusedMembership}) — surfaced by the connector as a `durable-unclosed` state so
553
+ * it is never presented as ordinary "not subscribed". */
554
+ pendingDurableLeaves(): string[];
555
+ /** A control request that found NO responder — open / manager-less (no privileged control plane),
556
+ * distinct from a responder that errored. nats.js surfaces it as NoRespondersError, or a RequestError
557
+ * whose `isNoResponders()` is true. */
558
+ private isNoResponders;
559
+ /** Agent-side: this session's CURRENT durable memberships (channel + join generation) from the
560
+ * manager — the agent holds no read on the privileged members KV. `undefined` ⇒ NO control responder
561
+ * (open / no delivery daemon, so there is no Plane-3 and no memberships). THROWS on a responder-present RPC
562
+ * failure, so a caller can FAIL-CLOSED rather than mistaking a transient error for "no membership". */
563
+ private fetchMemberships;
564
+ /** Agent-side, first connect (auth): SELF-JOIN this session's durable boot channels via the
565
+ * server-side delivery daemon — replacing the old manager-written boot membership. Each concrete
566
+ * `durable`-class boot channel gets a `durableJoin` whose returned generation seeds the leave mirror
567
+ * + durable-state surface; an already-active membership (a relaunch) is idempotent (no re-catch-up).
568
+ * If the daemon is down/absent at first connect (or reports a transient `durable:false`), the channel
569
+ * is handed to {@link reconcileBootJoin} for capped-backoff retry — so the backstop is RESTORED once
570
+ * the daemon recovers, not left silently live-only. Until a membership exists the channel renders
571
+ * degraded in `cotal_channels` ({@link hasDurableMembership}). */
572
+ private armBootDurableMemberships;
573
+ /** Retry a boot durable self-join with capped backoff until a membership EXISTS (success → seed
574
+ * `plane3Channels`) or the channel is left / the endpoint stops. Mirrors {@link closeRefusedMembership}:
575
+ * a one-shot first-connect attempt that swallowed a daemon outage would leave the boot channel live-only
576
+ * forever after the daemon recovers (and the lease-based health could then read "active" with no owner
577
+ * membership). This loop is the reconcile that closes that gap. Idempotent — a channel already pending
578
+ * is not double-driven; survives reconnect (it re-issues `durableJoinChannel` on the current connection). */
579
+ private reconcileBootJoin;
580
+ /** True if this session holds an established Plane-3 durable membership for `channel` (in `plane3Channels`).
581
+ * Drives the membership-aware delivery-health surface: a joined durable channel that is NOT yet a member
582
+ * (boot self-join pending / daemon down) must render degraded, never "active" off a live lease alone. */
583
+ hasDurableMembership(channel: string): boolean;
320
584
  /** Lazily obtain a JetStream manager — so a non-consuming endpoint (e.g. the supervisor,
321
585
  * consume:false) can still pre-create others' durables. */
322
586
  private manager;
@@ -324,6 +588,18 @@ export declare class CotalEndpoint extends EventEmitter {
324
588
  private startConsumers;
325
589
  /** Drive one consumer: decode, drop our own echo, and hand each message to listeners with ack control. */
326
590
  private pump;
591
+ /** Open a native core subscription to a channel's live feed (the manager-free live read path,
592
+ * broker-enforced by `sub.allow`). At-most-once — no replay, no ack; it is the live delivery for
593
+ * every channel (boot + runtime). For a `durable` channel it is also the low-latency wake-hint
594
+ * alongside the Plane-3 durable copy, coalesced by the receiver's id-dedup. Drops our own echo +
595
+ * spoofed senders. */
596
+ private subscribeChat;
597
+ /** Close a channel's core subscription (manager-free leave). */
598
+ private unsubscribeChat;
599
+ /** Confirm a just-opened core subscription was accepted by the broker. A `sub.allow` violation is
600
+ * async in NATS, so flush (round-trips the SUB) then settle briefly to let the refusal land — a
601
+ * denied subscribe must not read as a successful join (SPEC conformance #13). */
602
+ private confirmChatSub;
327
603
  /** The highest join watermark among the joined subscriptions that cover `concreteChannel`
328
604
  * (a wildcard sub like `team.>` covers `team.backend`), or undefined if none — the tail
329
605
  * drops a chat message with `seq <= ` this. */
@@ -335,8 +611,8 @@ export declare class CotalEndpoint extends EventEmitter {
335
611
  * focus-watermark a connector captures on entering `focus` (recall reads ambient after it). */
336
612
  chatFrontier(): Promise<number>;
337
613
  /** Phase 1 of a join — arm each channel's tail-drop watermark at the current frontier. MUST run
338
- * BEFORE the filter flip (consumers.update, or pump on a fresh create) so the tail can never
339
- * carry a just-joined message un-watermarked — which would double-emit it (live + backfill).
614
+ * BEFORE opening the core subscription so the live tail can never carry a just-joined message
615
+ * un-watermarked — which would double-emit it (live + backfill).
340
616
  * Returns the per-channel frontiers for {@link backfillArmed}. */
341
617
  private armJoin;
342
618
  /** Phase 2 of a join — backfill each armed channel's history up to its frontier (replay-gated),
@@ -401,6 +677,10 @@ export declare class CotalEndpoint extends EventEmitter {
401
677
  private handleChannelEntry;
402
678
  private handleKvEntry;
403
679
  private applyPresence;
680
+ /** Materialize an OFFLINE presence record: drop the advisory attention fields. An offline peer must
681
+ * not show a stale `[focus]` or "locally muted #x" hint — SPEC: attention removed on offline sweep,
682
+ * channel modes reset on restart. card/activity/ts are kept. */
683
+ private toOffline;
404
684
  /** Mark a known peer offline (on KV delete/purge), keeping it in the roster. */
405
685
  private markOffline;
406
686
  private sweep;
@@ -1 +1 @@
1
- {"version":3,"file":"endpoint.d.ts","sourceRoot":"","sources":["../src/endpoint.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AA4B3C,OAAO,KAAK,EACV,SAAS,EACT,aAAa,EAEb,YAAY,EACZ,cAAc,EACd,kBAAkB,EAElB,WAAW,EAEX,IAAI,EACJ,QAAQ,EACR,cAAc,EACd,YAAY,EACb,MAAM,YAAY,CAAC;AAkCpB,eAAO,MAAM,cAAc,0BAA0B,CAAC;AAEtD,uFAAuF;AACvF,eAAO,MAAM,aAAa,SAAS,CAAC;AAEpC,MAAM,WAAW,eAAe;IAC9B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