@fuzdev/fuz_app 0.181.0 → 0.182.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 (114) hide show
  1. package/dist/actions/CLAUDE.md +24 -6
  2. package/dist/actions/action_rpc.d.ts +11 -1
  3. package/dist/actions/action_rpc.d.ts.map +1 -1
  4. package/dist/actions/action_rpc.js +3 -2
  5. package/dist/actions/action_types.d.ts +16 -1
  6. package/dist/actions/action_types.d.ts.map +1 -1
  7. package/dist/actions/action_types.js +1 -1
  8. package/dist/actions/notification_sender.d.ts +83 -0
  9. package/dist/actions/notification_sender.d.ts.map +1 -0
  10. package/dist/actions/notification_sender.js +85 -0
  11. package/dist/actions/perform_action.d.ts +9 -0
  12. package/dist/actions/perform_action.d.ts.map +1 -1
  13. package/dist/actions/perform_action.js +22 -13
  14. package/dist/actions/register_action_ws.d.ts +14 -0
  15. package/dist/actions/register_action_ws.d.ts.map +1 -1
  16. package/dist/actions/register_action_ws.js +3 -2
  17. package/dist/actions/ws_socket_session.d.ts +3 -0
  18. package/dist/actions/ws_socket_session.d.ts.map +1 -1
  19. package/dist/actions/ws_socket_session.js +2 -1
  20. package/dist/auth/CLAUDE.md +60 -41
  21. package/dist/auth/account_actions.d.ts.map +1 -1
  22. package/dist/auth/account_actions.js +13 -3
  23. package/dist/auth/account_queries.d.ts +158 -16
  24. package/dist/auth/account_queries.d.ts.map +1 -1
  25. package/dist/auth/account_queries.js +189 -18
  26. package/dist/auth/account_routes.d.ts +1 -1
  27. package/dist/auth/account_routes.d.ts.map +1 -1
  28. package/dist/auth/account_routes.js +27 -26
  29. package/dist/auth/admin_actions.d.ts.map +1 -1
  30. package/dist/auth/admin_actions.js +71 -28
  31. package/dist/auth/api_token_queries.d.ts +13 -5
  32. package/dist/auth/api_token_queries.d.ts.map +1 -1
  33. package/dist/auth/api_token_queries.js +24 -9
  34. package/dist/auth/bearer_auth.d.ts.map +1 -1
  35. package/dist/auth/bearer_auth.js +3 -2
  36. package/dist/auth/daemon_token_middleware.d.ts.map +1 -1
  37. package/dist/auth/daemon_token_middleware.js +12 -1
  38. package/dist/auth/deps.d.ts +10 -0
  39. package/dist/auth/deps.d.ts.map +1 -1
  40. package/dist/auth/request_context.d.ts +73 -73
  41. package/dist/auth/request_context.d.ts.map +1 -1
  42. package/dist/auth/request_context.js +78 -96
  43. package/dist/auth/resolved_auth.d.ts +10 -5
  44. package/dist/auth/resolved_auth.d.ts.map +1 -1
  45. package/dist/auth/resolved_auth.js +2 -2
  46. package/dist/auth/role_grant_offer_action_specs.d.ts +1 -1
  47. package/dist/auth/role_grant_offer_action_specs.d.ts.map +1 -1
  48. package/dist/auth/role_grant_offer_action_specs.js +2 -1
  49. package/dist/auth/role_grant_offer_actions.d.ts +7 -11
  50. package/dist/auth/role_grant_offer_actions.d.ts.map +1 -1
  51. package/dist/auth/role_grant_offer_actions.js +61 -93
  52. package/dist/auth/role_grant_offer_notifications.d.ts +87 -38
  53. package/dist/auth/role_grant_offer_notifications.d.ts.map +1 -1
  54. package/dist/auth/role_grant_offer_notifications.js +75 -22
  55. package/dist/auth/role_grant_offer_queries.d.ts +96 -15
  56. package/dist/auth/role_grant_offer_queries.d.ts.map +1 -1
  57. package/dist/auth/role_grant_offer_queries.js +185 -70
  58. package/dist/auth/role_grant_offer_schema.js +1 -1
  59. package/dist/auth/role_grant_queries.d.ts +52 -12
  60. package/dist/auth/role_grant_queries.d.ts.map +1 -1
  61. package/dist/auth/role_grant_queries.js +75 -24
  62. package/dist/auth/role_grant_sql.d.ts +21 -0
  63. package/dist/auth/role_grant_sql.d.ts.map +1 -1
  64. package/dist/auth/role_grant_sql.js +21 -0
  65. package/dist/auth/self_service_role_actions.d.ts.map +1 -1
  66. package/dist/auth/self_service_role_actions.js +9 -2
  67. package/dist/auth/session_queries.d.ts +34 -13
  68. package/dist/auth/session_queries.d.ts.map +1 -1
  69. package/dist/auth/session_queries.js +48 -18
  70. package/dist/auth/standard_rpc_actions.d.ts +6 -19
  71. package/dist/auth/standard_rpc_actions.d.ts.map +1 -1
  72. package/dist/auth/standard_rpc_actions.js +5 -6
  73. package/dist/auth/token_scope.d.ts +1 -1
  74. package/dist/auth/token_scope.js +1 -1
  75. package/dist/http/CLAUDE.md +7 -6
  76. package/dist/http/auth_shape.d.ts +1 -1
  77. package/dist/http/error_schemas.d.ts +9 -21
  78. package/dist/http/error_schemas.d.ts.map +1 -1
  79. package/dist/http/error_schemas.js +14 -24
  80. package/dist/http/route_spec.d.ts +2 -2
  81. package/dist/server/app_backend.d.ts.map +1 -1
  82. package/dist/server/app_backend.js +3 -1
  83. package/dist/server/app_server.d.ts +26 -16
  84. package/dist/server/app_server.d.ts.map +1 -1
  85. package/dist/server/app_server.js +17 -7
  86. package/dist/server/serve_fact_route.d.ts +3 -3
  87. package/dist/server/serve_fact_route.js +12 -12
  88. package/dist/testing/CLAUDE.md +5 -5
  89. package/dist/testing/app_server.d.ts.map +1 -1
  90. package/dist/testing/app_server.js +3 -1
  91. package/dist/testing/auth_apps.js +1 -1
  92. package/dist/testing/cross_backend/account_lifecycle.d.ts.map +1 -1
  93. package/dist/testing/cross_backend/account_lifecycle.js +43 -0
  94. package/dist/testing/cross_backend/default_spine_surface.d.ts +1 -26
  95. package/dist/testing/cross_backend/default_spine_surface.d.ts.map +1 -1
  96. package/dist/testing/cross_backend/default_spine_surface.js +2 -6
  97. package/dist/testing/cross_backend/full_spine_mount.d.ts +3 -10
  98. package/dist/testing/cross_backend/full_spine_mount.d.ts.map +1 -1
  99. package/dist/testing/cross_backend/full_spine_mount.js +4 -4
  100. package/dist/testing/cross_backend/role_grant_offer_notification_ws.d.ts +5 -4
  101. package/dist/testing/cross_backend/role_grant_offer_notification_ws.d.ts.map +1 -1
  102. package/dist/testing/cross_backend/role_grant_offer_notification_ws.js +183 -30
  103. package/dist/testing/cross_backend/session_cap.d.ts.map +1 -1
  104. package/dist/testing/cross_backend/session_cap.js +26 -5
  105. package/dist/testing/middleware.d.ts +1 -1
  106. package/dist/testing/middleware.js +5 -5
  107. package/dist/testing/resolved_auth.d.ts +3 -1
  108. package/dist/testing/resolved_auth.d.ts.map +1 -1
  109. package/dist/testing/resolved_auth.js +4 -4
  110. package/dist/testing/stubs.d.ts.map +1 -1
  111. package/dist/testing/stubs.js +5 -2
  112. package/dist/testing/ws_round_trip.d.ts.map +1 -1
  113. package/dist/testing/ws_round_trip.js +8 -4
  114. package/package.json +1 -1
@@ -1 +1 @@
1
- {"version":3,"file":"app_server.d.ts","sourceRoot":"","sources":["../../src/lib/server/app_server.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,IAAI,EAAE,KAAK,OAAO,EAAE,MAAM,MAAM,CAAC;AAE1C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAChD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,8BAA8B,CAAC;AAG9D,OAAO,EAKN,KAAK,cAAc,EACnB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAC5E,OAAO,EAAqB,KAAK,SAAS,EAAE,MAAM,oBAAoB,CAAC;AACvE,OAAO,EAIN,KAAK,WAAW,EAChB,MAAM,8BAA8B,CAAC;AAEtC,OAAO,EACN,WAAW,EAMX,KAAK,eAAe,EACpB,KAAK,kBAAkB,EACvB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAChE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AACxD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAGhE,OAAO,oBAAoB,CAAC;AAE5B,OAAO,EAA4B,KAAK,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAKhF,OAAO,EAEN,KA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;;;;;;;;GASG;AACH,eAAO,MAAM,0BAA0B,GACtC,OAAO,sBAAsB,KAC3B,KAAK,CAAC,oBAAoB,CAgC5B,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkDG;AACH,eAAO,MAAM,iBAAiB,GAAU,SAAS,gBAAgB,KAAG,OAAO,CAAC,SAAS,CAQpF,CAAC"}
@@ -196,7 +196,10 @@ export const collect_config_diagnostics = (input) => {
196
196
  * to `backend.deps.connection_closer`, so the revocation handlers built from
197
197
  * `ctx.deps` close their connections with no further wiring, and — when the
198
198
  * server mounts either — one `create_revocation_guard` listener on that closer
199
- * repeats each close on the audit row.
199
+ * repeats each close on the audit row. Each WebSocket connection registry is
200
+ * added to `backend.deps.notification_sender` as well, the sender every
201
+ * mounted RPC and WebSocket dispatcher puts on its handler contexts, so an
202
+ * action's notification reaches the account's sockets with no wiring either.
200
203
  * The
201
204
  * `audit_sse` field on the returned `AppServer` (and the
202
205
  * `AppServerContext` passed to `create_route_specs`) is non-null in that
@@ -205,11 +208,12 @@ export const collect_config_diagnostics = (input) => {
205
208
  *
206
209
  * Assembly acquires a few things that outlive it — the rate limiters it
207
210
  * builds, the listeners it registers on `deps.audit`, the members it adds to
208
- * `deps.connection_closer` — and records a release for each as it goes. When
209
- * assembly throws, every release recorded so far runs, last acquired first
210
- * (one that throws is logged and the rest still run), and the original error
211
- * is rethrown: a failed assembly leaves the backend's emitter and closer as
212
- * it found them and no limiter timer running. When `auth_cleanup` is set, the
211
+ * `deps.connection_closer` and `deps.notification_sender` — and records a
212
+ * release for each as it goes. When assembly throws, every release recorded
213
+ * so far runs, last acquired first (one that throws is logged and the rest
214
+ * still run), and the original error is rethrown: a failed assembly leaves
215
+ * the backend's emitter, closer and notification sender as it found them and
216
+ * no limiter timer running. When `auth_cleanup` is set, the
213
217
  * auth cleanup schedule starts as the last step of assembly — nothing after
214
218
  * it can throw, so an assembly that throws leaves no schedule running.
215
219
  *
@@ -403,7 +407,8 @@ const assemble_app_server = async (options, releases) => {
403
407
  actions: endpoint.actions,
404
408
  log,
405
409
  action_ip_rate_limiter,
406
- action_account_rate_limiter
410
+ action_account_rate_limiter,
411
+ notification_sender: deps.notification_sender
407
412
  }));
408
413
  }
409
414
  }
@@ -620,12 +625,17 @@ const assemble_app_server = async (options, releases) => {
620
625
  required_roles: endpoint.required_roles,
621
626
  action_ip_rate_limiter,
622
627
  action_account_rate_limiter,
628
+ notification_sender: deps.notification_sender,
623
629
  on_effect_error
624
630
  });
625
631
  mounted_ws_endpoints[endpoint.path] = endpoint_registry;
626
632
  // every revocation's close — the handlers' and the guard's — reaches
627
633
  // this registry
628
634
  releases.push(deps.connection_closer.add(endpoint_registry));
635
+ // and so does every action's notification, from either transport; a
636
+ // registry two endpoints share is one member, so no socket hears a
637
+ // notification twice
638
+ releases.push(deps.notification_sender.add(endpoint_registry));
629
639
  }
630
640
  }
631
641
  // Post-route middleware (before static serving)
@@ -71,14 +71,14 @@
71
71
  * Auth shape on the cell-scoped route is `{account: 'none', actor: 'none'}`
72
72
  * — the dispatcher's authorization phase is skipped for pure-public routes,
73
73
  * so the handler builds the `RequestContext` itself from the resolved account
74
- * id (`get_public_account_id`, over what the `/api/*` auth middleware set) by
74
+ * (`get_public_account`, over what the `/api/*` auth middleware set) by
75
75
  * resolving the caller's single actor and loading their role_grants.
76
76
  * Unauthed callers pass through with `req_ctx: null` and are admitted only by
77
77
  * a `cell.visibility === 'public'` cell whose `moderation` admits an audience (unmoderated or
78
78
  * `'approved'`). Multi-actor accounts fall through with `req_ctx: null`
79
79
  * — there's no `acting?` slot on a pure-public route, so multi-actor
80
80
  * callers are treated as anonymous. A scope-narrowed API token is treated as
81
- * anonymous too, not refused (`get_public_account_id`): a narrowed token
81
+ * anonymous too, not refused (`get_public_account`): a narrowed token
82
82
  * reaches no non-RPC surface, but on a route that admits anonymous callers
83
83
  * a 403 would enforce nothing — the holder drops the `Authorization` header and
84
84
  * re-reads every public cell anyway.
@@ -160,7 +160,7 @@ export interface CreateServeFactRouteSpecOptions {
160
160
  * other referrers.
161
161
  *
162
162
  * Pure-public auth — the handler builds the per-request `RequestContext`
163
- * from the resolved account id (`get_public_account_id`) and enforces
163
+ * from the resolved account id (`get_public_account`) and enforces
164
164
  * visibility per-reference.
165
165
  */
166
166
  export declare const create_serve_cell_fact_route_spec: (options: CreateServeFactRouteSpecOptions) => RouteSpec;
@@ -71,14 +71,14 @@
71
71
  * Auth shape on the cell-scoped route is `{account: 'none', actor: 'none'}`
72
72
  * — the dispatcher's authorization phase is skipped for pure-public routes,
73
73
  * so the handler builds the `RequestContext` itself from the resolved account
74
- * id (`get_public_account_id`, over what the `/api/*` auth middleware set) by
74
+ * (`get_public_account`, over what the `/api/*` auth middleware set) by
75
75
  * resolving the caller's single actor and loading their role_grants.
76
76
  * Unauthed callers pass through with `req_ctx: null` and are admitted only by
77
77
  * a `cell.visibility === 'public'` cell whose `moderation` admits an audience (unmoderated or
78
78
  * `'approved'`). Multi-actor accounts fall through with `req_ctx: null`
79
79
  * — there's no `acting?` slot on a pure-public route, so multi-actor
80
80
  * callers are treated as anonymous. A scope-narrowed API token is treated as
81
- * anonymous too, not refused (`get_public_account_id`): a narrowed token
81
+ * anonymous too, not refused (`get_public_account`): a narrowed token
82
82
  * reaches no non-RPC surface, but on a route that admits anonymous callers
83
83
  * a 403 would enforce nothing — the holder drops the `Authorization` header and
84
84
  * re-reads every public cell anyway.
@@ -135,7 +135,7 @@ import { Readable } from 'node:stream';
135
135
  import { join } from 'node:path';
136
136
  import { ActingActor, FactHashSchema, Uuid } from '../primitive_schemas.js';
137
137
  import { literal, object } from '@fuzdev/fuz_schema/schema.ts';
138
- import { build_request_context, get_public_account_id, has_scoped_role } from '../auth/request_context.js';
138
+ import { build_request_context, get_public_account, has_scoped_role } from '../auth/request_context.js';
139
139
  import { ROLE_ADMIN } from '../auth/role_schema.js';
140
140
  import { query_active_actors_by_account } from '../auth/account_queries.js';
141
141
  import { define_route } from '../http/route_spec.js';
@@ -262,10 +262,10 @@ const serve_fact_bytes = async (route, hash, config) => {
262
262
  };
263
263
  /**
264
264
  * Resolve the caller's `RequestContext` on a pure-public route from the
265
- * session-middleware-set account id, read through `get_public_account_id`, so
266
- * a scope-narrowed API token returns `null` — downgraded to anonymous, not
267
- * refused (see the module doc). Twin of the Rust
268
- * `AuthGate::public_request_context`.
265
+ * account the auth middleware resolved, read through `get_public_account`,
266
+ * so a scope-narrowed API token returns `null` — downgraded to anonymous, not
267
+ * refused (see the module doc). The account is that row, not read again. Twin
268
+ * of the Rust `AuthGate::public_request_context`.
269
269
  *
270
270
  * Multi-actor accounts return `null` (no `acting?` slot on a public route to
271
271
  * disambiguate); single active-actor accounts resolve their actor and
@@ -276,13 +276,13 @@ const serve_fact_bytes = async (route, hash, config) => {
276
276
  */
277
277
  const build_public_request_context = async (route) => {
278
278
  // a narrowed token is the anonymous caller here, never a refusal
279
- const account_id = get_public_account_id(route);
280
- if (!account_id)
279
+ const account = get_public_account(route);
280
+ if (!account)
281
281
  return null;
282
- const actors = await query_active_actors_by_account({ db: route.db }, account_id);
282
+ const actors = await query_active_actors_by_account({ db: route.db }, account.id);
283
283
  if (actors.length !== 1)
284
284
  return null;
285
- return build_request_context({ db: route.db }, account_id, actors[0].id);
285
+ return build_request_context({ db: route.db }, account, actors[0]);
286
286
  };
287
287
  /**
288
288
  * Build the cell-scoped `GET /api/cells/:cell_id/facts/:hash` `RouteSpec`
@@ -297,7 +297,7 @@ const build_public_request_context = async (route) => {
297
297
  * other referrers.
298
298
  *
299
299
  * Pure-public auth — the handler builds the per-request `RequestContext`
300
- * from the resolved account id (`get_public_account_id`) and enforces
300
+ * from the resolved account id (`get_public_account`) and enforces
301
301
  * visibility per-reference.
302
302
  */
303
303
  export const create_serve_cell_fact_route_spec = (options) => {
@@ -33,7 +33,7 @@ time (never runtime), where a throwing guard would break `vite build`.
33
33
  - `stub_handler()` — a `route_raw` text answer (`stub`), a handler that fits any route (`attach_route_handler(shape, stub_handler)`).
34
34
  - `stub_route_spec(shape)` — a spec for a surface that is described and never served: `shape` with a handler that throws when run (the spine routes of `create_rust_spine_consumer_surface_spec`).
35
35
  - `stub_mw` — pass-through middleware (`async (_c, next) => next()`).
36
- - `create_stub_app_deps()` — factory: fresh `AppDeps` with a stub keyring (`sign` answers `<value>.stub_signature`, so an assembly's sample cookie mint runs; nothing else of it does anything), no-op password, a `create_noop_stub` DB, silent `Logger`, no-op `audit`, an empty `connection_closer`.
36
+ - `create_stub_app_deps()` — factory: fresh `AppDeps` with a stub keyring (`sign` answers `<value>.stub_signature`, so an assembly's sample cookie mint runs; nothing else of it does anything), no-op password, a `create_noop_stub` DB, silent `Logger`, no-op `audit`, an empty `connection_closer` and `notification_sender`.
37
37
  - `create_test_audit_emitter()` — no-op `AuditEmitter`; `emit` / `emit_role_grant_target` / `emit_pool` resolve immediately, `notify` no-op, `add_listener` throws (use `create_recording_audit_emitter` for a listener-accepting emitter), `listener_count` returns 0, `drain_inflight` resolves immediately, `is_tracking_inflight` returns `false`.
38
38
  - `create_stub_audit_sse()` — no-op `AuditLogSse` for surface-test wiring without booting real SSE. `on_audit_event` no-op (nothing is broadcast); `required_role` is `admin`; `registry` is a fresh `SseRegistry` (live `.count` / `.close_*` for registry-state tests, isolated per call). For real SSE plumbing build via `create_audit_log_sse` against `create_test_app`.
39
39
  - `create_stub_api_middleware({include_daemon_token?, origin_carve_outs?})` — stub `MiddlewareSpec[]` matching `create_auth_middleware_specs`'s output (origin, optional daemon_token, session, request_context, bearer_auth) for surface generation without booting real auth — the same names, paths, order, and declared `errors` (`origin` declares a 403; `bearer_auth` and `daemon_token` declare none, since both soft-fail through `next()`), pinned against the real factory by `auth/middleware.mounted.test.ts`. The surface merges middleware errors into every route under the path, so a stub declaring more would widen the test surface with statuses the live server never returns. Each spec gets its own pass-through handler (not the shared `stub_mw`), so `assert_middleware_stack_mounted` tells the layers apart. See `auth/CLAUDE.md` §Middleware for the real stack.
@@ -66,7 +66,7 @@ casts — the factory brands internally. Exported as `TestAccountOverrides` /
66
66
 
67
67
  ### `resolved_auth.ts` — `ResolvedAuth` factory
68
68
 
69
- `create_test_resolved_auth({credential_type, account_id, session_id?,
69
+ `create_test_resolved_auth({credential_type, account, session_id?,
70
70
  api_token_id?, scope?, credential_deadline?})` — the `ResolvedAuth` arm for a
71
71
  credential type, as the auth middleware builds it: a session's `session_hash`
72
72
  is `hash_session_token(session_id)` (default a fresh uuid), an API token's id
@@ -1697,7 +1697,7 @@ without.
1697
1697
 
1698
1698
  | suite | pins | gate |
1699
1699
  | --- | --- | --- |
1700
- | `account_lifecycle` | soft delete → undelete, keeper-confirmed purge, the `cannot_delete_keeper` guard, session-only self-delete, a deleted account's credentials refused — and still refused after the undelete, a fresh login working; role grants kept through the delete and conferring again after the undelete, offers made to the account staying superseded, its unclaimed invites void (a claimed one untouched) — each audit row, the `include_deleted` listing; and, ungated, a password change ending every session and API token of the account while another account's stay live | `account_lifecycle` (all but the password case) |
1700
+ | `account_lifecycle` | soft delete → undelete, keeper-confirmed purge, the `cannot_delete_keeper` guard, session-only self-delete, a deleted account's credentials refused — and still refused after the undelete, a fresh login working; role grants kept through the delete and conferring again after the undelete, offers made to the account staying superseded (and, on a purge, superseded and audited before the cascade), its unclaimed invites void (a claimed one untouched) — each audit row, the `include_deleted` listing; and, ungated, a password change ending every session and API token of the account while another account's stay live | `account_lifecycle` (all but the password case) |
1701
1701
  | `actor_lookup` | the keeper resolves its own actor in the leak-safe wire shape (the refusals are table rows) | — |
1702
1702
  | `app_settings` | an anonymous signup reads `open_signup` fresh after `app_settings_update` | — |
1703
1703
  | `body_size` | the 1 MiB body cap: cap+1 → 413 `payload_too_large`, exactly the cap not size-rejected, an over-cap chunked body → 413, no upload racing the close | — |
@@ -1726,7 +1726,7 @@ without.
1726
1726
  | `ready` | anonymous `GET /ready` → `200 {ready: true}` over the committed `expected_schema.json` | `ready` |
1727
1727
  | `role_grant_offer_enumeration` | `role_grant_offer_accept`'s deliberate split: a nonexistent offer → 404 `role_grant_offer_not_found`, a sibling actor's on the caller's own account → 403 `role_grant_offer_actor_mismatch` | — |
1728
1728
  | `role_grant_offer_lifecycle` | a decline or retract by a non-party → 404 identical to a missing offer; of a decided offer → 400 `role_grant_offer_terminal`; an accept after a decline or a retract the same, granting nothing, and a replayed accept answering the first grant; one audit row per success, none per refusal; lost grantor authority supersedes pending offers; a recipient's delete supersedes every pending offer to it, and an offer to a deleted account or actor answers as one to a missing one | — |
1729
- | `role_grant_offer_notification_ws` | each offer and role-grant notification strict-parsed against its params schema, with a bystander socket that must receive nothing behind a `heartbeat` barrier | `ws` |
1729
+ | `role_grant_offer_notification_ws` | each offer and role-grant notification strict-parsed against its params schema — a revoke's supersedes reaching every party's socket, and (with `account_lifecycle`) a delete's and a purge's reaching the live parties while the removed account's socket closes having heard nothing — the target socket hearing exactly the expected notifications once each, in order, and a bystander socket that must receive nothing, both behind a `heartbeat` barrier | `ws` |
1730
1730
  | `role_grant_participation` | the success paths of app-role conferral: assign + idempotency, a scoped assign, offer → accept, offer replay | — |
1731
1731
  | `role_grant_role_grammar` | an off-grammar `role` or scope kind on the grant verbs → `invalid_params` with no reason and no audit row | — |
1732
1732
  | `rooms_ws` | the room verbs and their notifications in `seq` order, the refusals' codes and reasons, exclusivity, eviction, disconnect, the per-connection limiter | `ws` + `rooms` |
@@ -2284,7 +2284,7 @@ re-roll the serve / daemon-info / drain boilerplate:
2284
2284
  - `testing/cross_backend/full_spine_mount.ts` — `build_full_spine_rpc_actions(deps, options)` — the **full** live RPC mount: the declared bundle **plus** the off-declared-surface families the binary live-mounts (`_testing_*` backdoors, the cell verb set, the opt-in `actor_lookup` / `actor_search` resolvers). `build_full_spine_mount(deps, options)` builds it once for both of the binary's endpoints, returning `FullSpineMount` (`{rpc_actions, ws_actions}`): the WS list is `protocol_actions` plus every RPC action not already among them, then the WS-only room verbs and `room_notification_actions`, twinning the Rust `testing_spine_stub`, which serves one registry on RPC and WS (the one difference is `cancel` — a registered protocol action on TS, owned by the read loop on Rust — and the stub's RPC dispatcher refuses its `ws_only` room verbs). `options.room_registry` is the registry the room verbs, `_testing_room_evict`, and `_testing_reset` (which clears it) share — the binary builds it with `create_spine_room_registry(connections)` (exclusive, the default bounds; the twin of the stub's `stub_room_registry`) over its WS endpoints' connection registry; omitted, one over a fresh connection registry serves enumeration. Single-sources the mount so the binary and the `spine_method_coverage` reconciliation test build the same list. `create_spine_live_rpc_endpoints()` wraps the list, built on stub deps, as one endpoint at `SPINE_RPC_PATH` — the `live_rpc_endpoints` value the conformance table, the differential and the auth-row generator resolve off-surface methods from (no handler built there runs).
2285
2285
  - `testing/cross_backend/ts_spine_backend_config.ts` — `ts_spine_node_backend_config()` / `ts_spine_bun_backend_config()` presets (in-memory pglet, no external infra), the TS analog of `rust_spine_stub_backend_config()`.
2286
2286
 
2287
- fuz_app's own binary wiring (`src/test/cross_backend/testing_spine_server{,_node,_bun}.ts`) is the worked example: ~one `build_app` over `create_app_backend` + `create_app_server` (`rate_limiters: 'disabled_for_testing'` plus whichever login / action limiters its env toggles built, `build_full_spine_mount`'s two lists on one `rpc_endpoints` entry and two `ws_endpoints` entries — `/api/ws` and the role-gated `SPINE_ROLE_GATED_WS_PATH` — sharing one `registry`, which is also the role-grant-offer `notification_sender`), reusing `default_spine_surface`. `src/test/cross_backend/testing_spine_server.db.test.ts` builds it with the Node adapter in-process and asserts its surface lists both WS endpoints (the gated one with its `required_roles`) and passes the surface invariants. The `_node`/`_bun` entries differ only in which adapter they wire — `build_spine_app` is runtime-agnostic. It leaves `create_app_server`'s `auth_cleanup` off, as the Rust `testing_spine_stub` leaves its twin unscheduled: a background pass would delete rows and write audit rows under a running suite. A consumer's cross-process test binary may schedule it when nothing its suites seed is already expired (the conformance table's `expired_session` principal seeds a backdated session row); an in-process harness leaves it off.
2287
+ fuz_app's own binary wiring (`src/test/cross_backend/testing_spine_server{,_node,_bun}.ts`) is the worked example: ~one `build_app` over `create_app_backend` + `create_app_server` (`rate_limiters: 'disabled_for_testing'` plus whichever login / action limiters its env toggles built, `build_full_spine_mount`'s two lists on one `rpc_endpoints` entry and two `ws_endpoints` entries — `/api/ws` and the role-gated `SPINE_ROLE_GATED_WS_PATH` — sharing one `registry` — one member of the backend's `notification_sender`, so each socket hears a notification once), reusing `default_spine_surface`. `src/test/cross_backend/testing_spine_server.db.test.ts` builds it with the Node adapter in-process and asserts its surface lists both WS endpoints (the gated one with its `required_roles`) and passes the surface invariants. The `_node`/`_bun` entries differ only in which adapter they wire — `build_spine_app` is runtime-agnostic. It leaves `create_app_server`'s `auth_cleanup` off, as the Rust `testing_spine_stub` leaves its twin unscheduled: a background pass would delete rows and write audit rows under a running suite. A consumer's cross-process test binary may schedule it when nothing its suites seed is already expired (the conformance table's `expired_session` principal seeds a backdated session row); an in-process harness leaves it off.
2288
2288
 
2289
2289
  The TS spine binary serves the audit stream, `GET /api/admin/audit/stream`:
2290
2290
  `build_spine_app` passes `audit_log_sse: true` and `create_spine_route_specs`
@@ -1 +1 @@
1
- {"version":3,"file":"app_server.d.ts","sourceRoot":"","sources":["../../src/lib/testing/app_server.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,CAAC;AAE7B;;;;;;;;;;;;;GAaG;AAEH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAGjC,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,yBAAyB,CAAC;AAIpD,OAAO,EAAkB,KAAK,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAElE,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AAC9C,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAU5D,OAAO,EAA+B,KAAK,cAAc,EAAE,MAAM,2BAA2B,CAAC;AAC7F,OAAO,EAAkB,KAAK,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAG3E,OAAO,EAEN,KAAK,UAAU,EACf,KAAK,YAAY,EAC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,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,KAAK,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACxF,qDAAqD;IACrD,cAAc,EAAE,CAAC,OAAO,CAAC,EAAE,wBAAwB,KAAK,OAAO,CAAC,WAAW,CAAC,CAAC;IAC7E,2PAA2P;IAC3P,OAAO,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;CAC7B;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,kCAAkC,QAAO,IAAI,CACzD,gBAAgB,EAChB,iBAAiB,GAAG,OAAO,GAAG,YAAY,CAa1C,CAAC;AAgCF;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,eAAe,GAAU,SAAS,oBAAoB,KAAG,OAAO,CAAC,OAAO,CAqFpF,CAAC"}
@@ -13,6 +13,7 @@ import { create_session_cookie_value } from '../auth/session_cookie.js';
13
13
  import { run_migrations } from '../db/migrate.js';
14
14
  import { AUTH_MIGRATION_NS } from '../auth/migrations.js';
15
15
  import { create_realtime_closer } from '../actions/connection_closer.js';
16
+ import { create_realtime_notification_sender } from '../actions/notification_sender.js';
16
17
  import { default_audit_factory } from '../server/app_backend.js';
17
18
  import { create_app_server } from '../server/app_server.js';
18
19
  import { generate_daemon_token, DAEMON_TOKEN_HEADER } from '../auth/daemon_token.js';
@@ -218,7 +219,8 @@ const _build_test_backend = async (options) => {
218
219
  db,
219
220
  log: test_log,
220
221
  audit: audit_factory({ db, log: test_log }),
221
- connection_closer: create_realtime_closer()
222
+ connection_closer: create_realtime_closer(),
223
+ notification_sender: create_realtime_notification_sender()
222
224
  }
223
225
  };
224
226
  return { backend, keyring: keyring_result.keyring };
@@ -45,7 +45,7 @@ export const create_test_app_from_specs = (route_specs, auth_ctx, credential_typ
45
45
  if (auth_ctx) {
46
46
  c.set(RESOLVED_AUTH_KEY, create_test_resolved_auth({
47
47
  credential_type: credential_type ?? CREDENTIAL_TYPE_SESSION,
48
- account_id: auth_ctx.account.id
48
+ account: auth_ctx.account
49
49
  }));
50
50
  c.set(REQUEST_CONTEXT_KEY, auth_ctx);
51
51
  c.set(TEST_CONTEXT_PRESET_KEY, TEST_CONTEXT_PRESET);
@@ -1 +1 @@
1
- {"version":3,"file":"account_lifecycle.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/account_lifecycle.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AA2E9B,OAAO,KAAK,EAAE,uCAAuC,EAAe,MAAM,YAAY,CAAC;AAQvF;;;;;GAKG;AACH,MAAM,WAAW,gCAAiC,SAAQ,uCAAuC;IAChG,2DAA2D;IAC3D,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC;IAC7B,wEAAwE;IACxE,QAAQ,CAAC,aAAa,CAAC,EAAE,MAAM,CAAC;IAChC,6DAA6D;IAC7D,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;CAC9B;AAQD,eAAO,MAAM,sCAAsC,GAClD,SAAS,gCAAgC,KACvC,IAy2BF,CAAC"}
1
+ {"version":3,"file":"account_lifecycle.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/account_lifecycle.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAgF9B,OAAO,KAAK,EAAE,uCAAuC,EAAe,MAAM,YAAY,CAAC;AAQvF;;;;;GAKG;AACH,MAAM,WAAW,gCAAiC,SAAQ,uCAAuC;IAChG,2DAA2D;IAC3D,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC;IAC7B,wEAAwE;IACxE,QAAQ,CAAC,aAAa,CAAC,EAAE,MAAM,CAAC;IAChC,6DAA6D;IAC7D,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;CAC9B;AAQD,eAAO,MAAM,sCAAsC,GAClD,SAAS,gCAAgC,KACvC,IAg7BF,CAAC"}
@@ -21,6 +21,11 @@ import '../assert_dev_env.js';
21
21
  * an `outcome: 'failure'` row; `admin_account_list` with `include_deleted`
22
22
  * lists tombstoned rows with `deleted_at` set.
23
23
  *
24
+ * A purge ends the pending offers made to the account before its cascade
25
+ * deletes them, as a delete does — one `role_grant_offer_supersede` row each,
26
+ * `account_deleted` with the account as cause — and the grantor's history no
27
+ * longer lists them: the audit row is what remains.
28
+ *
24
29
  * Two credential end states, each proven live before it is killed: a session
25
30
  * and an API token minted before a soft delete stay dead after the undelete
26
31
  * (the delete removed their rows, and the undelete clears only the
@@ -169,6 +174,44 @@ export const describe_account_lifecycle_cross_tests = (options) => {
169
174
  assert.ok(row, 'account_purge writes a success row targeting the victim');
170
175
  assert.strictEqual(row.metadata?.username, victim.account.username, 'account_purge snapshots the username');
171
176
  });
177
+ test_if(capabilities.account_lifecycle, 'a purge supersedes the offers made to the account, audited, before its cascade deletes them', async () => {
178
+ const fixture = await setup_test();
179
+ const victim = await fixture.create_account({ username: 'lifecycle_purge_offered' });
180
+ const grantor = await fixture.create_account({
181
+ username: 'lifecycle_purge_offerer',
182
+ roles: [ROLE_ADMIN]
183
+ });
184
+ const offer = async (headers, params) => {
185
+ const res = await rpc(fixture, 'role_grant_offer_create', { to_account_id: victim.account.id, role: ROLE_ADMIN, ...params }, headers);
186
+ if (!res.ok)
187
+ assert.fail(`role_grant_offer_create: ${JSON.stringify(res)}`);
188
+ return res.result.offer.id;
189
+ };
190
+ const by_account = await offer(fixture.create_session_headers(), {});
191
+ const by_actor = await offer(grantor.create_session_headers(), {
192
+ to_actor_id: victim.actor.id
193
+ });
194
+ expect_output(await cross_rpc_call(fixture.fresh_transport({ origin: null }), rpc_path, 'account_purge', { account_id: victim.account.id, confirm: true }, fixture.create_daemon_token_headers()), AccountPurgeOutput);
195
+ const supersedes = await list_audit_events(fixture, { event_type: 'role_grant_offer_supersede' }, rpc_path);
196
+ for (const [offer_id, grantor_headers, label] of [
197
+ [by_account, fixture.create_session_headers(), 'the account-addressed offer'],
198
+ [by_actor, grantor.create_session_headers(), 'the actor-addressed offer']
199
+ ]) {
200
+ const rows = supersedes.filter((e) => e.metadata?.offer_id === offer_id);
201
+ assert.strictEqual(rows.length, 1, `one role_grant_offer_supersede row for ${label}`);
202
+ assert.strictEqual(rows[0].target_account_id, victim.account.id, label);
203
+ assert_audit_metadata_fields(fixture, rows[0].metadata, {
204
+ offer_id,
205
+ role: ROLE_ADMIN,
206
+ scope_id: null,
207
+ reason: 'account_deleted',
208
+ cause_id: victim.account.id
209
+ });
210
+ // the cascade deleted the row: the audit row is all that remains
211
+ const { offers } = expect_output(await rpc(fixture, 'role_grant_offer_history', {}, grantor_headers), RoleGrantOfferHistoryOutput);
212
+ assert.notInclude(offers.map((o) => o.id), offer_id, `the grantor's history no longer lists ${label}`);
213
+ }
214
+ });
172
215
  test_if(capabilities.account_lifecycle, 'keeper guard: delete + purge refuse the keeper account', async () => {
173
216
  const fixture = await setup_test();
174
217
  const t = fixture.fresh_transport();
@@ -17,7 +17,6 @@ import '../assert_dev_env.js';
17
17
  * @module
18
18
  */
19
19
  import type { Logger } from '@fuzdev/fuz_util/log.ts';
20
- import type { NotificationSender } from '../../auth/role_grant_offer_notifications.js';
21
20
  import { type RoleRegistry } from '../../auth/role_schema.js';
22
21
  import { type SessionOptions } from '../../auth/session_cookie.js';
23
22
  import { type RouteSpec } from '../../http/route_spec.js';
@@ -40,26 +39,6 @@ export declare const spine_session_options: SessionOptions<string>;
40
39
  * (`admin_account_list.grantable_roles` carries it on both spines).
41
40
  */
42
41
  export declare const spine_roles: RoleRegistry;
43
- /** Options for `spine_rpc_endpoints`. */
44
- export interface SpineRpcEndpointsOptions {
45
- /**
46
- * WS notification sender threaded into the role-grant-offer sub-factory for
47
- * server-initiated fan-out (`role_grant_offer_received` / `_accepted` /
48
- * `_declined` / `_retracted` / `_supersede`, flat `role_grant_revoked`).
49
- *
50
- * **Shared-instance trap.** Pass the SAME `ConnectionRegistry`
51
- * instance the WS endpoint registers connections against — the registry
52
- * *is* the fan-out target, so a separate instance would fan out to an
53
- * empty registry and reach nobody (silently). The TS spine binary
54
- * constructs one `ConnectionRegistry` and threads it both here and into
55
- * `register_action_ws`.
56
- *
57
- * Omitted (the default) for the shared `create_spine_surface_spec` path —
58
- * surface generation doesn't depend on it, and it must stay absent there so
59
- * the declared snapshot is unaffected.
60
- */
61
- readonly notification_sender?: NotificationSender | null;
62
- }
63
42
  /**
64
43
  * Factory-form RPC endpoints over the per-test `ctx.deps`. `create_app_server`
65
44
  * (in the binary) owns live dispatch; the surface builder invokes the factory
@@ -70,12 +49,8 @@ export interface SpineRpcEndpointsOptions {
70
49
  * `actions` (see `testing/cross_backend/testing_reset_actions.ts`); it is intentionally excluded
71
50
  * here so it stays off the declared surface (the harness calls it directly
72
51
  * over the daemon-token channel).
73
- *
74
- * `options.notification_sender`, when supplied, reaches the role-grant-offer
75
- * sub-factory so the spine emits the WS notification family — see
76
- * `SpineRpcEndpointsOptions`.
77
52
  */
78
- export declare const spine_rpc_endpoints: (ctx: AppServerContext, options?: SpineRpcEndpointsOptions) => Array<RpcEndpointSpec>;
53
+ export declare const spine_rpc_endpoints: (ctx: AppServerContext) => Array<RpcEndpointSpec>;
79
54
  /**
80
55
  * Account REST + signup route specs under `/api/account` (bootstrap
81
56
  * auto-mounted by the surface builder / `create_app_server`), plus the
@@ -1 +1 @@
1
- {"version":3,"file":"default_spine_surface.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/default_spine_surface.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AAItD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,8CAA8C,CAAC;AACvF,OAAO,EAAwB,KAAK,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAEpF,OAAO,EAAyB,KAAK,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAI1F,OAAO,EAAsB,KAAK,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAC9E,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAC7E,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oCAAoC,CAAC;AAgB3E;;;GAGG;AACH,eAAO,MAAM,qBAAqB,EAAE,cAAc,CAAC,MAAM,CAAwC,CAAC;AAElG;;;;;;;;;;GAUG;AACH,eAAO,MAAM,WAAW,EAAE,YAGxB,CAAC;AAEH,yCAAyC;AACzC,MAAM,WAAW,wBAAwB;IACxC;;;;;;;;;;;;;;;OAeG;IACH,QAAQ,CAAC,mBAAmB,CAAC,EAAE,kBAAkB,GAAG,IAAI,CAAC;CACzD;AAED;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,mBAAmB,GAC/B,KAAK,gBAAgB,EACrB,UAAU,wBAAwB,KAChC,KAAK,CAAC,eAAe,CAQvB,CAAC;AAEF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,wBAAwB,GAAI,KAAK,gBAAgB,KAAG,KAAK,CAAC,SAAS,CAgC/E,CAAC;AAEF;;;;;;;;;GASG;AACH,eAAO,MAAM,6BAA6B,GAAI,MAAM,MAAM,KAAG,SAC+B,CAAC;AAE7F;;;;;;;;GAQG;AACH,eAAO,MAAM,yBAAyB,QAAO,cAS1C,CAAC"}
1
+ {"version":3,"file":"default_spine_surface.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/default_spine_surface.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAE9B;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,yBAAyB,CAAC;AAItD,OAAO,EAAwB,KAAK,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAEpF,OAAO,EAAyB,KAAK,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAI1F,OAAO,EAAsB,KAAK,SAAS,EAAE,MAAM,0BAA0B,CAAC;AAC9E,OAAO,KAAK,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAC7E,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oCAAoC,CAAC;AAgB3E;;;GAGG;AACH,eAAO,MAAM,qBAAqB,EAAE,cAAc,CAAC,MAAM,CAAwC,CAAC;AAElG;;;;;;;;;;GAUG;AACH,eAAO,MAAM,WAAW,EAAE,YAGxB,CAAC;AAEH;;;;;;;;;;GAUG;AACH,eAAO,MAAM,mBAAmB,GAAI,KAAK,gBAAgB,KAAG,KAAK,CAAC,eAAe,CAKhF,CAAC;AAEF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,wBAAwB,GAAI,KAAK,gBAAgB,KAAG,KAAK,CAAC,SAAS,CAgC/E,CAAC;AAEF;;;;;;;;;GASG;AACH,eAAO,MAAM,6BAA6B,GAAI,MAAM,MAAM,KAAG,SAC+B,CAAC;AAE7F;;;;;;;;GAQG;AACH,eAAO,MAAM,yBAAyB,QAAO,cAS1C,CAAC"}
@@ -45,15 +45,11 @@ export const spine_roles = create_role_registry([
45
45
  * `actions` (see `testing/cross_backend/testing_reset_actions.ts`); it is intentionally excluded
46
46
  * here so it stays off the declared surface (the harness calls it directly
47
47
  * over the daemon-token channel).
48
- *
49
- * `options.notification_sender`, when supplied, reaches the role-grant-offer
50
- * sub-factory so the spine emits the WS notification family — see
51
- * `SpineRpcEndpointsOptions`.
52
48
  */
53
- export const spine_rpc_endpoints = (ctx, options) => [
49
+ export const spine_rpc_endpoints = (ctx) => [
54
50
  {
55
51
  path: SPINE_RPC_PATH,
56
- actions: create_standard_rpc_actions({ ...ctx.deps, notification_sender: options?.notification_sender ?? null }, { roles: spine_roles })
52
+ actions: create_standard_rpc_actions(ctx.deps, { roles: spine_roles })
57
53
  }
58
54
  ];
59
55
  /**
@@ -45,7 +45,6 @@ import { ConnectionRegistry } from '../../actions/connection_registry.js';
45
45
  import { RoomRegistry } from '../../actions/room_registry.js';
46
46
  import type { AppDeps } from '../../auth/deps.js';
47
47
  import type { DaemonTokenState } from '../../auth/daemon_token.js';
48
- import type { NotificationSender } from '../../auth/role_grant_offer_notifications.js';
49
48
  import type { RpcEndpointSpec } from '../../http/surface.js';
50
49
  /**
51
50
  * The spine binary's room registry over `connections`: exclusive — one seat
@@ -66,12 +65,6 @@ export interface FullSpineMountOptions {
66
65
  * state satisfies it.
67
66
  */
68
67
  readonly daemon_token_state: DaemonTokenState;
69
- /**
70
- * WS notification sender for the role-grant-offer fan-out. Pass the SAME
71
- * `ConnectionRegistry` the WS endpoint registers connections against
72
- * (the registry is the fan-out target). Omitted for enumeration.
73
- */
74
- readonly notification_sender?: NotificationSender | null;
75
68
  /**
76
69
  * The room registry the room verbs and `_testing_room_evict` run on — built
77
70
  * by `create_spine_room_registry` over the SAME `ConnectionRegistry` the WS
@@ -90,10 +83,10 @@ export interface FullSpineMountOptions {
90
83
  * Mirrors the previous inline assembly in `testing_spine_server.ts` exactly —
91
84
  * `session_options` is pinned to `spine_session_options` (the binary's cookie
92
85
  * config) and `roles` to `spine_roles` (carrying `cell_editor`), so the only
93
- * runtime-varying inputs are the daemon-token state + notification sender.
86
+ * runtime-varying inputs are the daemon-token state and the room registry.
94
87
  *
95
88
  * @param deps - the backend `AppDeps` (stub deps suffice for method enumeration)
96
- * @param options - daemon-token state + optional WS notification sender and room registry
89
+ * @param options - daemon-token state + optional room registry
97
90
  * @returns every `RpcAction` the binary exposes, in mount order
98
91
  */
99
92
  export declare const build_full_spine_rpc_actions: (deps: AppDeps, options: FullSpineMountOptions) => Array<RpcAction>;
@@ -122,7 +115,7 @@ export interface FullSpineMount {
122
115
  * (never dispatched) on Rust.
123
116
  *
124
117
  * @param deps - the backend `AppDeps`
125
- * @param options - daemon-token state + optional WS notification sender and room registry
118
+ * @param options - daemon-token state + optional room registry
126
119
  * @returns the RPC and WS action lists, built once and sharing handler instances
127
120
  */
128
121
  export declare const build_full_spine_mount: (deps: AppDeps, options: FullSpineMountOptions) => FullSpineMount;
@@ -1 +1 @@
1
- {"version":3,"file":"full_spine_mount.d.ts","s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SAAS,CAAC,CAAC;IACvC;;;;;OAKG;IACH,QAAQ,CAAC,UAAU,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;CACnC;AAED;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,sBAAsB,GAClC,MAAM,OAAO,EACb,SAAS,qBAAqB,KAC5B,cAYF,CAAC;AAaF;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,+BAA+B,QAAO,KAAK,CAAC,eAAe,CAOvE,CAAC"}
@@ -58,10 +58,10 @@ export const create_spine_room_registry = (connections) => new RoomRegistry(conn
58
58
  * Mirrors the previous inline assembly in `testing_spine_server.ts` exactly —
59
59
  * `session_options` is pinned to `spine_session_options` (the binary's cookie
60
60
  * config) and `roles` to `spine_roles` (carrying `cell_editor`), so the only
61
- * runtime-varying inputs are the daemon-token state + notification sender.
61
+ * runtime-varying inputs are the daemon-token state and the room registry.
62
62
  *
63
63
  * @param deps - the backend `AppDeps` (stub deps suffice for method enumeration)
64
- * @param options - daemon-token state + optional WS notification sender and room registry
64
+ * @param options - daemon-token state + optional room registry
65
65
  * @returns every `RpcAction` the binary exposes, in mount order
66
66
  */
67
67
  export const build_full_spine_rpc_actions = (deps, options) => build_full_spine_actions(deps, options).rpc_actions;
@@ -77,7 +77,7 @@ const build_full_spine_actions = (deps, options) => {
77
77
  limiter: new RoomRateLimiter(DEFAULT_ROOM_RATE_LIMIT)
78
78
  });
79
79
  const actions = [
80
- ...create_standard_rpc_actions({ ...deps, notification_sender: options.notification_sender ?? null }, { roles: spine_roles }),
80
+ ...create_standard_rpc_actions(deps, { roles: spine_roles }),
81
81
  ...create_testing_actions(deps, {
82
82
  session_options: spine_session_options,
83
83
  daemon_token_state: options.daemon_token_state,
@@ -141,7 +141,7 @@ const build_full_spine_actions = (deps, options) => {
141
141
  * (never dispatched) on Rust.
142
142
  *
143
143
  * @param deps - the backend `AppDeps`
144
- * @param options - daemon-token state + optional WS notification sender and room registry
144
+ * @param options - daemon-token state + optional room registry
145
145
  * @returns the RPC and WS action lists, built once and sharing handler instances
146
146
  */
147
147
  export const build_full_spine_mount = (deps, options) => {
@@ -32,10 +32,11 @@ export interface RoleGrantOfferNotificationWsTestOptions extends WsEndpointTarge
32
32
  /**
33
33
  * Register the role-grant-offer WS notification suite — cases over a real
34
34
  * upgrade, one per server-initiated notification (received / accepted /
35
- * declined / retracted / revoke, global and scoped, + supersede on both the
36
- * accept and revoke cascades). Each opens the affected counterparty's socket, drives the
37
- * lifecycle RPC, and strict-parses the delivered frame against its canonical
38
- * params schema. Gated on `capabilities.ws`.
35
+ * declined / retracted / revoke, global and scoped, + supersede on the accept,
36
+ * revoke, delete and purge cascades). Each opens every party's socket, drives
37
+ * the lifecycle RPC, and strict-parses the delivered frames against their
38
+ * canonical params schema. Gated on `capabilities.ws`, the removals on
39
+ * `capabilities.account_lifecycle` too.
39
40
  */
40
41
  export declare const describe_role_grant_offer_notification_ws_tests: (options: RoleGrantOfferNotificationWsTestOptions) => void;
41
42
  //# sourceMappingURL=role_grant_offer_notification_ws.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"role_grant_offer_notification_ws.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/role_grant_offer_notification_ws.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAyF9B,OAAO,EAAE,KAAK,mBAAmB,EAAW,MAAM,mBAAmB,CAAC;AAKtE,OAAO,KAAK,EAAE,SAAS,EAAe,MAAM,YAAY,CAAC;AAEzD,OAAO,EAAmB,KAAK,gBAAgB,EAAyB,MAAM,kBAAkB,CAAC;AAKjG,2EAA2E;AAC3E,MAAM,WAAW,uCAAwC,SAAQ,gBAAgB;IAChF,8EAA8E;IAC9E,QAAQ,CAAC,UAAU,EAAE,SAAS,CAAC;IAC/B,uEAAuE;IACvE,QAAQ,CAAC,YAAY,EAAE,mBAAmB,CAAC;IAC3C;;;;;;OAMG;IACH,QAAQ,CAAC,iBAAiB,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IACnD;;;;OAIG;IACH,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;IAC9B;;;;OAIG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACpC;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,+CAA+C,GAC3D,SAAS,uCAAuC,KAC9C,IA8eF,CAAC"}
1
+ {"version":3,"file":"role_grant_offer_notification_ws.d.ts","sourceRoot":"","sources":["../../../src/lib/testing/cross_backend/role_grant_offer_notification_ws.ts"],"names":[],"mappings":"AAAA,OAAO,sBAAsB,CAAC;AAuG9B,OAAO,EAAE,KAAK,mBAAmB,EAAW,MAAM,mBAAmB,CAAC;AAOtE,OAAO,KAAK,EAAE,SAAS,EAAe,MAAM,YAAY,CAAC;AAEzD,OAAO,EAAmB,KAAK,gBAAgB,EAAyB,MAAM,kBAAkB,CAAC;AAwBjG,2EAA2E;AAC3E,MAAM,WAAW,uCAAwC,SAAQ,gBAAgB;IAChF,8EAA8E;IAC9E,QAAQ,CAAC,UAAU,EAAE,SAAS,CAAC;IAC/B,uEAAuE;IACvE,QAAQ,CAAC,YAAY,EAAE,mBAAmB,CAAC;IAC3C;;;;;;OAMG;IACH,QAAQ,CAAC,iBAAiB,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IACnD;;;;OAIG;IACH,QAAQ,CAAC,WAAW,CAAC,EAAE,MAAM,CAAC;IAC9B;;;;OAIG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;CACpC;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,+CAA+C,GAC3D,SAAS,uCAAuC,KAC9C,IA4qBF,CAAC"}