@fuzdev/fuz_app 0.67.0 → 0.68.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 (168) hide show
  1. package/dist/auth/CLAUDE.md +99 -5
  2. package/dist/auth/account_queries.d.ts +87 -4
  3. package/dist/auth/account_queries.d.ts.map +1 -1
  4. package/dist/auth/account_queries.js +107 -17
  5. package/dist/auth/account_schema.d.ts +19 -0
  6. package/dist/auth/account_schema.d.ts.map +1 -1
  7. package/dist/auth/account_schema.js +8 -0
  8. package/dist/auth/admin_action_specs.d.ts +168 -0
  9. package/dist/auth/admin_action_specs.d.ts.map +1 -1
  10. package/dist/auth/admin_action_specs.js +146 -1
  11. package/dist/auth/admin_actions.d.ts.map +1 -1
  12. package/dist/auth/admin_actions.js +218 -4
  13. package/dist/auth/audit_log_ddl.d.ts +10 -1
  14. package/dist/auth/audit_log_ddl.d.ts.map +1 -1
  15. package/dist/auth/audit_log_ddl.js +13 -4
  16. package/dist/auth/audit_log_schema.d.ts +34 -1
  17. package/dist/auth/audit_log_schema.d.ts.map +1 -1
  18. package/dist/auth/audit_log_schema.js +73 -0
  19. package/dist/auth/auth_ddl.d.ts +2 -2
  20. package/dist/auth/auth_ddl.d.ts.map +1 -1
  21. package/dist/auth/auth_ddl.js +10 -2
  22. package/dist/auth/cell_action_specs.d.ts +1295 -0
  23. package/dist/auth/cell_action_specs.d.ts.map +1 -0
  24. package/dist/auth/cell_action_specs.js +397 -0
  25. package/dist/auth/cell_actions.d.ts +63 -0
  26. package/dist/auth/cell_actions.d.ts.map +1 -0
  27. package/dist/auth/cell_actions.js +546 -0
  28. package/dist/auth/cell_audit_action_specs.d.ts +131 -0
  29. package/dist/auth/cell_audit_action_specs.d.ts.map +1 -0
  30. package/dist/auth/cell_audit_action_specs.js +70 -0
  31. package/dist/auth/cell_audit_actions.d.ts +18 -0
  32. package/dist/auth/cell_audit_actions.d.ts.map +1 -0
  33. package/dist/auth/cell_audit_actions.js +59 -0
  34. package/dist/auth/cell_audit_events.d.ts +28 -0
  35. package/dist/auth/cell_audit_events.d.ts.map +1 -0
  36. package/dist/auth/cell_audit_events.js +42 -0
  37. package/dist/auth/cell_audit_metadata.d.ts +48 -0
  38. package/dist/auth/cell_audit_metadata.d.ts.map +1 -0
  39. package/dist/auth/cell_audit_metadata.js +46 -0
  40. package/dist/auth/cell_authorize.d.ts +88 -0
  41. package/dist/auth/cell_authorize.d.ts.map +1 -0
  42. package/dist/auth/cell_authorize.js +172 -0
  43. package/dist/auth/cell_data_schema.d.ts +44 -0
  44. package/dist/auth/cell_data_schema.d.ts.map +1 -0
  45. package/dist/auth/cell_data_schema.js +42 -0
  46. package/dist/auth/cell_field_action_specs.d.ts +244 -0
  47. package/dist/auth/cell_field_action_specs.d.ts.map +1 -0
  48. package/dist/auth/cell_field_action_specs.js +136 -0
  49. package/dist/auth/cell_field_actions.d.ts +34 -0
  50. package/dist/auth/cell_field_actions.d.ts.map +1 -0
  51. package/dist/auth/cell_field_actions.js +153 -0
  52. package/dist/auth/cell_field_audit_metadata.d.ts +30 -0
  53. package/dist/auth/cell_field_audit_metadata.d.ts.map +1 -0
  54. package/dist/auth/cell_field_audit_metadata.js +28 -0
  55. package/dist/auth/cell_grant_action_specs.d.ts +333 -0
  56. package/dist/auth/cell_grant_action_specs.d.ts.map +1 -0
  57. package/dist/auth/cell_grant_action_specs.js +148 -0
  58. package/dist/auth/cell_grant_actions.d.ts +50 -0
  59. package/dist/auth/cell_grant_actions.d.ts.map +1 -0
  60. package/dist/auth/cell_grant_actions.js +208 -0
  61. package/dist/auth/cell_grant_audit_metadata.d.ts +75 -0
  62. package/dist/auth/cell_grant_audit_metadata.d.ts.map +1 -0
  63. package/dist/auth/cell_grant_audit_metadata.js +54 -0
  64. package/dist/auth/cell_item_action_specs.d.ts +331 -0
  65. package/dist/auth/cell_item_action_specs.d.ts.map +1 -0
  66. package/dist/auth/cell_item_action_specs.js +182 -0
  67. package/dist/auth/cell_item_actions.d.ts +37 -0
  68. package/dist/auth/cell_item_actions.d.ts.map +1 -0
  69. package/dist/auth/cell_item_actions.js +204 -0
  70. package/dist/auth/cell_item_audit_metadata.d.ts +35 -0
  71. package/dist/auth/cell_item_audit_metadata.d.ts.map +1 -0
  72. package/dist/auth/cell_item_audit_metadata.js +32 -0
  73. package/dist/auth/cell_relation_visibility.d.ts +32 -0
  74. package/dist/auth/cell_relation_visibility.d.ts.map +1 -0
  75. package/dist/auth/cell_relation_visibility.js +57 -0
  76. package/dist/auth/deps.d.ts +9 -0
  77. package/dist/auth/deps.d.ts.map +1 -1
  78. package/dist/auth/role_grant_queries.d.ts +30 -0
  79. package/dist/auth/role_grant_queries.d.ts.map +1 -1
  80. package/dist/auth/role_grant_queries.js +54 -0
  81. package/dist/db/CLAUDE.md +118 -0
  82. package/dist/db/cell_audit_queries.d.ts +26 -0
  83. package/dist/db/cell_audit_queries.d.ts.map +1 -0
  84. package/dist/db/cell_audit_queries.js +53 -0
  85. package/dist/db/cell_ddl.d.ts +151 -0
  86. package/dist/db/cell_ddl.d.ts.map +1 -0
  87. package/dist/db/cell_ddl.js +247 -0
  88. package/dist/db/cell_field_queries.d.ts +105 -0
  89. package/dist/db/cell_field_queries.d.ts.map +1 -0
  90. package/dist/db/cell_field_queries.js +113 -0
  91. package/dist/db/cell_grant_queries.d.ts +132 -0
  92. package/dist/db/cell_grant_queries.d.ts.map +1 -0
  93. package/dist/db/cell_grant_queries.js +145 -0
  94. package/dist/db/cell_history_ddl.d.ts +38 -0
  95. package/dist/db/cell_history_ddl.d.ts.map +1 -0
  96. package/dist/db/cell_history_ddl.js +61 -0
  97. package/dist/db/cell_item_queries.d.ts +107 -0
  98. package/dist/db/cell_item_queries.d.ts.map +1 -0
  99. package/dist/db/cell_item_queries.js +119 -0
  100. package/dist/db/cell_queries.d.ts +327 -0
  101. package/dist/db/cell_queries.d.ts.map +1 -0
  102. package/dist/db/cell_queries.js +431 -0
  103. package/dist/db/fact_ddl.d.ts +38 -0
  104. package/dist/db/fact_ddl.d.ts.map +1 -0
  105. package/dist/db/fact_ddl.js +71 -0
  106. package/dist/db/fact_queries.d.ts +140 -0
  107. package/dist/db/fact_queries.d.ts.map +1 -0
  108. package/dist/db/fact_queries.js +161 -0
  109. package/dist/db/fact_store.d.ts +112 -0
  110. package/dist/db/fact_store.d.ts.map +1 -0
  111. package/dist/db/fact_store.js +225 -0
  112. package/dist/server/env.d.ts +2 -0
  113. package/dist/server/env.d.ts.map +1 -1
  114. package/dist/server/env.js +6 -0
  115. package/dist/server/fact_write.d.ts +32 -0
  116. package/dist/server/fact_write.d.ts.map +1 -0
  117. package/dist/server/fact_write.js +56 -0
  118. package/dist/server/file_fact_fetcher.d.ts +42 -0
  119. package/dist/server/file_fact_fetcher.d.ts.map +1 -0
  120. package/dist/server/file_fact_fetcher.js +60 -0
  121. package/dist/server/file_fact_url.d.ts +53 -0
  122. package/dist/server/file_fact_url.d.ts.map +1 -0
  123. package/dist/server/file_fact_url.js +52 -0
  124. package/dist/server/serve_fact_route.d.ts +78 -0
  125. package/dist/server/serve_fact_route.d.ts.map +1 -0
  126. package/dist/server/serve_fact_route.js +205 -0
  127. package/dist/testing/CLAUDE.md +58 -5
  128. package/dist/testing/app_server.d.ts +12 -0
  129. package/dist/testing/app_server.d.ts.map +1 -1
  130. package/dist/testing/app_server.js +36 -2
  131. package/dist/testing/audit_completeness.d.ts.map +1 -1
  132. package/dist/testing/audit_completeness.js +67 -1
  133. package/dist/testing/cross_backend/account_lifecycle.d.ts +10 -0
  134. package/dist/testing/cross_backend/account_lifecycle.d.ts.map +1 -0
  135. package/dist/testing/cross_backend/account_lifecycle.js +76 -0
  136. package/dist/testing/cross_backend/capabilities.d.ts +31 -0
  137. package/dist/testing/cross_backend/capabilities.d.ts.map +1 -1
  138. package/dist/testing/cross_backend/capabilities.js +3 -0
  139. package/dist/testing/cross_backend/cell_cross_helpers.d.ts +39 -0
  140. package/dist/testing/cross_backend/cell_cross_helpers.d.ts.map +1 -0
  141. package/dist/testing/cross_backend/cell_cross_helpers.js +45 -0
  142. package/dist/testing/cross_backend/cell_crud.d.ts +4 -0
  143. package/dist/testing/cross_backend/cell_crud.d.ts.map +1 -0
  144. package/dist/testing/cross_backend/cell_crud.js +168 -0
  145. package/dist/testing/cross_backend/cell_relations.d.ts +4 -0
  146. package/dist/testing/cross_backend/cell_relations.d.ts.map +1 -0
  147. package/dist/testing/cross_backend/cell_relations.js +229 -0
  148. package/dist/testing/cross_backend/default_backend_configs.d.ts.map +1 -1
  149. package/dist/testing/cross_backend/default_backend_configs.js +6 -0
  150. package/dist/testing/cross_backend/setup.d.ts.map +1 -1
  151. package/dist/testing/cross_backend/setup.js +5 -0
  152. package/dist/testing/cross_backend/spawn_backend.d.ts.map +1 -1
  153. package/dist/testing/cross_backend/spawn_backend.js +31 -3
  154. package/dist/testing/cross_backend/testing_server_bun.d.ts.map +1 -1
  155. package/dist/testing/cross_backend/testing_server_bun.js +29 -2
  156. package/dist/testing/entities.d.ts.map +1 -1
  157. package/dist/testing/entities.js +4 -0
  158. package/dist/testing/ws_round_trip.d.ts.map +1 -1
  159. package/dist/testing/ws_round_trip.js +4 -0
  160. package/dist/ui/AdminAccounts.svelte +58 -0
  161. package/dist/ui/AdminAccounts.svelte.d.ts.map +1 -1
  162. package/dist/ui/admin_accounts_state.svelte.d.ts +30 -2
  163. package/dist/ui/admin_accounts_state.svelte.d.ts.map +1 -1
  164. package/dist/ui/admin_accounts_state.svelte.js +45 -1
  165. package/dist/ui/admin_rpc_adapters.d.ts +6 -2
  166. package/dist/ui/admin_rpc_adapters.d.ts.map +1 -1
  167. package/dist/ui/admin_rpc_adapters.js +5 -1
  168. package/package.json +4 -2
@@ -0,0 +1,208 @@
1
+ /**
2
+ * Cell-grant ACL RPC handlers.
3
+ *
4
+ * Three `request_response` actions bound to specs in
5
+ * `./cell_grant_action_specs.ts`:
6
+ *
7
+ * Grant management is **manage-tier only** (`can_manage_cell` = admin /
8
+ * owner). Editor-grant holders may edit a cell's content + relations but
9
+ * cannot manage its grants — delegating the share list would let an editor
10
+ * widen access or mint peer editors and escape the manager's authority.
11
+ *
12
+ * - `cell_grant_create` — admin / owner only. Validates role-shaped
13
+ * principals against the role schema; rejects owner-as-principal.
14
+ * Actor-shaped principals carry a pre-resolved `actor_id` (callers pick
15
+ * via `actor_search`). Idempotent — re-granting the same principal
16
+ * updates `level` via UPSERT.
17
+ * - `cell_grant_revoke` — admin / owner, plus self for actor-shaped grants
18
+ * ("leave shared cell"). Returns `still_admitted` computed by re-running
19
+ * `can_view_cell` against the remaining grants.
20
+ * - `cell_grant_list` — admin / owner only. Viewers and editors alike get
21
+ * the IDOR-mask 404 (the share list is the manager's to curate).
22
+ *
23
+ * All three 404 with `cell_not_found` on cell-miss / cell-unviewable, and
24
+ * with `cell_grant_not_found` on grant-miss, mirroring the existence-leak
25
+ * guards in `cell_actions.ts`.
26
+ *
27
+ * Audit events `cell_grant_create` / `cell_grant_revoke` carry IDs only
28
+ * (no display-name snapshots); see `./cell_grant_audit_metadata.ts`.
29
+ *
30
+ * @module
31
+ */
32
+ import { rpc_action } from '../actions/action_rpc.js';
33
+ import { jsonrpc_errors } from '../http/jsonrpc_errors.js';
34
+ import { cell_grant_create_action_spec, cell_grant_revoke_action_spec, cell_grant_list_action_spec, ERROR_CELL_GRANT_NOT_FOUND, ERROR_CELL_GRANT_PRINCIPAL_IS_OWNER, ERROR_CELL_GRANT_UNKNOWN_ROLE, } from './cell_grant_action_specs.js';
35
+ import { ERROR_CELL_NOT_FOUND } from './cell_action_specs.js';
36
+ import { can_view_cell, can_manage_cell } from './cell_authorize.js';
37
+ import { query_cell_get } from '../db/cell_queries.js';
38
+ import { query_cell_grant_create, query_cell_grant_get, query_cell_grant_delete, query_cell_grant_list_for_cell, } from '../db/cell_grant_queries.js';
39
+ export const to_grant_json = (row) => ({
40
+ id: row.id,
41
+ cell_id: row.cell_id,
42
+ level: row.level,
43
+ actor_id: row.actor_id,
44
+ role: row.role,
45
+ scope_id: row.scope_id,
46
+ granted_by: row.granted_by,
47
+ created_at: typeof row.created_at === 'string' ? row.created_at : row.created_at.toISOString(),
48
+ });
49
+ /**
50
+ * Build the audit-metadata principal envelope from a `cell_grant` row.
51
+ * Picks the actor-shape branch when `actor_id IS NOT NULL`,
52
+ * otherwise the role-shape branch. The CHECK constraint guarantees
53
+ * exactly one of the two holds.
54
+ */
55
+ const principal_from_row = (row) => row.actor_id !== null ? { actor_id: row.actor_id } : { role: row.role, scope_id: row.scope_id };
56
+ /**
57
+ * Map the wire-input principal to the query-input shape. Both arms pass
58
+ * through unchanged — the wire and query shapes are aligned (pickers run
59
+ * `actor_search` upstream and submit the resolved id).
60
+ */
61
+ const to_query_principal = (principal) => {
62
+ if (principal.kind === 'actor') {
63
+ return { kind: 'actor', actor_id: principal.actor_id };
64
+ }
65
+ return {
66
+ kind: 'role',
67
+ role: principal.role,
68
+ scope_id: principal.scope_id ?? null,
69
+ };
70
+ };
71
+ /**
72
+ * Reject the create when the principal actor is the cell's owner.
73
+ * Skipped for role-shaped principals (a role isn't a single actor) and
74
+ * for system cells (`created_by IS NULL`). With actor-grain principals
75
+ * the comparison is direct — `cell.created_by` is already an actor id.
76
+ */
77
+ const assert_principal_is_not_owner = (cell, principal) => {
78
+ if (principal.kind !== 'actor')
79
+ return;
80
+ if (cell.created_by === null)
81
+ return;
82
+ if (cell.created_by === principal.actor_id) {
83
+ throw jsonrpc_errors.invalid_params('grant principal is the cell owner', {
84
+ reason: ERROR_CELL_GRANT_PRINCIPAL_IS_OWNER,
85
+ });
86
+ }
87
+ };
88
+ /** Create the three `cell_grant_*` RPC actions. */
89
+ export const create_cell_grant_actions = (deps) => {
90
+ const { roles } = deps;
91
+ const create_handler = async (input, ctx) => {
92
+ const auth = ctx.auth;
93
+ const cell = await query_cell_get(ctx, input.cell_id);
94
+ if (!cell) {
95
+ // IDOR mask: same code as cell_get's miss/unviewable so probing
96
+ // for cells via the share endpoint is no easier than via cell_get.
97
+ throw jsonrpc_errors.not_found('cell', { reason: ERROR_CELL_NOT_FOUND });
98
+ }
99
+ // Grant management is manage-tier only (admin / owner). Editor-grant
100
+ // holders may edit the cell's content + relations but cannot mint
101
+ // grants of any level — delegating the share list would let editors
102
+ // widen access (or mint peer editors) and escape the manager's
103
+ // authority. Non-managers get the IDOR-mask 404, same as a non-viewer
104
+ // on the read path.
105
+ if (!can_manage_cell(auth, cell)) {
106
+ throw jsonrpc_errors.not_found('cell', { reason: ERROR_CELL_NOT_FOUND });
107
+ }
108
+ const principal = to_query_principal(input.principal);
109
+ // Role validity — only relevant for role-shaped principals; reject
110
+ // before insert so dead grant rows nothing can match are foreclosed.
111
+ if (principal.kind === 'role' && !roles.role_specs.has(principal.role)) {
112
+ throw jsonrpc_errors.invalid_params(`unknown role "${principal.role}"`, {
113
+ reason: ERROR_CELL_GRANT_UNKNOWN_ROLE,
114
+ });
115
+ }
116
+ assert_principal_is_not_owner(cell, principal);
117
+ const row = await query_cell_grant_create(ctx, {
118
+ cell_id: cell.id,
119
+ level: input.level,
120
+ principal,
121
+ granted_by: auth.actor.id,
122
+ });
123
+ deps.audit.emit(ctx, {
124
+ event_type: 'cell_grant_create',
125
+ actor_id: auth.actor.id,
126
+ account_id: auth.account.id,
127
+ ip: ctx.client_ip,
128
+ metadata: {
129
+ cell_id: row.cell_id,
130
+ grant_id: row.id,
131
+ level: row.level,
132
+ principal: principal_from_row(row),
133
+ },
134
+ });
135
+ return { grant: to_grant_json(row) };
136
+ };
137
+ const revoke_handler = async (input, ctx) => {
138
+ const auth = ctx.auth;
139
+ const grant = await query_cell_grant_get(ctx, input.grant_id);
140
+ if (!grant) {
141
+ throw jsonrpc_errors.not_found('cell grant', { reason: ERROR_CELL_GRANT_NOT_FOUND });
142
+ }
143
+ const cell = await query_cell_get(ctx, grant.cell_id);
144
+ if (!cell) {
145
+ // Grant exists but its cell is gone (soft-deleted out from under
146
+ // it). Treat as a grant miss for the IDOR mask.
147
+ throw jsonrpc_errors.not_found('cell grant', { reason: ERROR_CELL_GRANT_NOT_FOUND });
148
+ }
149
+ const is_manager = can_manage_cell(auth, cell);
150
+ // "Is the grant being revoked the caller's own actor-shaped grant?"
151
+ // Self-revoke is the leave-shared-cell affordance — open regardless of
152
+ // authority path. Owner-with-self-grant can't happen
153
+ // (`assert_principal_is_not_owner` blocks it at create time).
154
+ const is_self_actor_grant = grant.actor_id !== null && grant.actor_id === auth.actor.id;
155
+ // Grant management is manage-tier only (admin / owner); editor-grant
156
+ // holders cannot revoke grants (mirrors the create gate). The sole
157
+ // exception is self-revoke. Non-qualifying callers get the IDOR mask.
158
+ if (!is_manager && !is_self_actor_grant) {
159
+ throw jsonrpc_errors.not_found('cell grant', { reason: ERROR_CELL_GRANT_NOT_FOUND });
160
+ }
161
+ const deleted = await query_cell_grant_delete(ctx, grant.id);
162
+ if (!deleted) {
163
+ // Raced with another revoker. Same shape as cell_actions.ts —
164
+ // 404 covers the gap.
165
+ throw jsonrpc_errors.not_found('cell grant', { reason: ERROR_CELL_GRANT_NOT_FOUND });
166
+ }
167
+ // Recompute admit state against the remaining grants. Always true
168
+ // for non-self revokes (caller didn't admit via this row), but the
169
+ // recompute is uniform shape — let `can_view_cell` decide.
170
+ const remaining = await query_cell_grant_list_for_cell(ctx, cell.id);
171
+ const still_admitted = can_view_cell(auth, cell, remaining);
172
+ const audit_metadata = {
173
+ cell_id: deleted.cell_id,
174
+ grant_id: deleted.id,
175
+ level: deleted.level,
176
+ principal: principal_from_row(deleted),
177
+ ...(is_self_actor_grant ? { self: true } : {}),
178
+ };
179
+ deps.audit.emit(ctx, {
180
+ event_type: 'cell_grant_revoke',
181
+ actor_id: auth.actor.id,
182
+ account_id: auth.account.id,
183
+ ip: ctx.client_ip,
184
+ metadata: audit_metadata,
185
+ });
186
+ return { ok: true, still_admitted };
187
+ };
188
+ const list_handler = async (input, ctx) => {
189
+ const auth = ctx.auth;
190
+ const cell = await query_cell_get(ctx, input.cell_id);
191
+ if (!cell) {
192
+ throw jsonrpc_errors.not_found('cell', { reason: ERROR_CELL_NOT_FOUND });
193
+ }
194
+ // Same authz gate as create — manage tier only (admin / owner). The
195
+ // share list is the manager's to curate; viewers and editors alike
196
+ // fall through to the IDOR-mask 404.
197
+ if (!can_manage_cell(auth, cell)) {
198
+ throw jsonrpc_errors.not_found('cell', { reason: ERROR_CELL_NOT_FOUND });
199
+ }
200
+ const grants = await query_cell_grant_list_for_cell(ctx, cell.id);
201
+ return { grants: grants.map(to_grant_json) };
202
+ };
203
+ return [
204
+ rpc_action(cell_grant_create_action_spec, create_handler),
205
+ rpc_action(cell_grant_revoke_action_spec, revoke_handler),
206
+ rpc_action(cell_grant_list_action_spec, list_handler),
207
+ ];
208
+ };
@@ -0,0 +1,75 @@
1
+ /**
2
+ * Audit-log metadata schemas for the `cell_grant` ACL events.
3
+ *
4
+ * IDs only — no display-name snapshots. By convention audit logs store
5
+ * references, not denormalized strings; viewer tooling resolves
6
+ * `actor_id` → `actor.name`, `scope_id` → scope name, etc. at read time.
7
+ *
8
+ * Apps register these via `extra_events:` on `create_audit_log_config`
9
+ * alongside the other cell metadata schemas.
10
+ *
11
+ * @module
12
+ */
13
+ import { z } from 'zod';
14
+ /**
15
+ * Principal columns as stored on `cell_grant`. Discriminated by which
16
+ * keys are present: `{actor_id}` for an actor-shaped grant,
17
+ * `{role, scope_id}` for a role-shaped grant. Actor-shaped grants
18
+ * carry only the id; names are never persisted in the audit envelope.
19
+ */
20
+ export declare const CellGrantPrincipalAuditMetadata: z.ZodUnion<readonly [z.ZodObject<{
21
+ actor_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
22
+ }, z.core.$loose>, z.ZodObject<{
23
+ role: z.ZodString;
24
+ scope_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
25
+ }, z.core.$loose>]>;
26
+ export type CellGrantPrincipalAuditMetadata = z.infer<typeof CellGrantPrincipalAuditMetadata>;
27
+ /**
28
+ * Metadata envelope for `cell_grant_create`.
29
+ *
30
+ * Emitted on every successful create OR re-share update path
31
+ * (UPSERT-on-unique-index). The audit reader correlates create-vs-update
32
+ * via `grant_id` if needed; the design doesn't require distinguishing
33
+ * the two at the metadata level.
34
+ */
35
+ export declare const CellGrantCreateAuditMetadata: z.ZodObject<{
36
+ cell_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
37
+ grant_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
38
+ level: z.ZodEnum<{
39
+ viewer: "viewer";
40
+ editor: "editor";
41
+ }>;
42
+ principal: z.ZodUnion<readonly [z.ZodObject<{
43
+ actor_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
44
+ }, z.core.$loose>, z.ZodObject<{
45
+ role: z.ZodString;
46
+ scope_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
47
+ }, z.core.$loose>]>;
48
+ }, z.core.$loose>;
49
+ export type CellGrantCreateAuditMetadata = z.infer<typeof CellGrantCreateAuditMetadata>;
50
+ /**
51
+ * Metadata envelope for `cell_grant_revoke`.
52
+ *
53
+ * `self: true` distinguishes the recipient-side "leave shared cell"
54
+ * path (actor-shaped grant where the principal actor === caller
55
+ * actor) from a delegator-side revoke. Single event type for both
56
+ * — the boolean is enough for forensic review and avoids surface-
57
+ * doubling with a parallel `cell_grant_leave` event.
58
+ */
59
+ export declare const CellGrantRevokeAuditMetadata: z.ZodObject<{
60
+ cell_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
61
+ grant_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
62
+ level: z.ZodEnum<{
63
+ viewer: "viewer";
64
+ editor: "editor";
65
+ }>;
66
+ principal: z.ZodUnion<readonly [z.ZodObject<{
67
+ actor_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
68
+ }, z.core.$loose>, z.ZodObject<{
69
+ role: z.ZodString;
70
+ scope_id: z.ZodNullable<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
71
+ }, z.core.$loose>]>;
72
+ self: z.ZodOptional<z.ZodLiteral<true>>;
73
+ }, z.core.$loose>;
74
+ export type CellGrantRevokeAuditMetadata = z.infer<typeof CellGrantRevokeAuditMetadata>;
75
+ //# sourceMappingURL=cell_grant_audit_metadata.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cell_grant_audit_metadata.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/cell_grant_audit_metadata.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAGtB;;;;;GAKG;AACH,eAAO,MAAM,+BAA+B;;;;;mBAG1C,CAAC;AACH,MAAM,MAAM,+BAA+B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC;AAE9F;;;;;;;GAOG;AACH,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;iBAKvC,CAAC;AACH,MAAM,MAAM,4BAA4B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,CAAC;AAExF;;;;;;;;GAQG;AACH,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;iBAMvC,CAAC;AACH,MAAM,MAAM,4BAA4B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,CAAC"}
@@ -0,0 +1,54 @@
1
+ /**
2
+ * Audit-log metadata schemas for the `cell_grant` ACL events.
3
+ *
4
+ * IDs only — no display-name snapshots. By convention audit logs store
5
+ * references, not denormalized strings; viewer tooling resolves
6
+ * `actor_id` → `actor.name`, `scope_id` → scope name, etc. at read time.
7
+ *
8
+ * Apps register these via `extra_events:` on `create_audit_log_config`
9
+ * alongside the other cell metadata schemas.
10
+ *
11
+ * @module
12
+ */
13
+ import { z } from 'zod';
14
+ import { Uuid } from '@fuzdev/fuz_util/id.js';
15
+ /**
16
+ * Principal columns as stored on `cell_grant`. Discriminated by which
17
+ * keys are present: `{actor_id}` for an actor-shaped grant,
18
+ * `{role, scope_id}` for a role-shaped grant. Actor-shaped grants
19
+ * carry only the id; names are never persisted in the audit envelope.
20
+ */
21
+ export const CellGrantPrincipalAuditMetadata = z.union([
22
+ z.looseObject({ actor_id: Uuid }),
23
+ z.looseObject({ role: z.string(), scope_id: Uuid.nullable() }),
24
+ ]);
25
+ /**
26
+ * Metadata envelope for `cell_grant_create`.
27
+ *
28
+ * Emitted on every successful create OR re-share update path
29
+ * (UPSERT-on-unique-index). The audit reader correlates create-vs-update
30
+ * via `grant_id` if needed; the design doesn't require distinguishing
31
+ * the two at the metadata level.
32
+ */
33
+ export const CellGrantCreateAuditMetadata = z.looseObject({
34
+ cell_id: Uuid,
35
+ grant_id: Uuid,
36
+ level: z.enum(['viewer', 'editor']),
37
+ principal: CellGrantPrincipalAuditMetadata,
38
+ });
39
+ /**
40
+ * Metadata envelope for `cell_grant_revoke`.
41
+ *
42
+ * `self: true` distinguishes the recipient-side "leave shared cell"
43
+ * path (actor-shaped grant where the principal actor === caller
44
+ * actor) from a delegator-side revoke. Single event type for both
45
+ * — the boolean is enough for forensic review and avoids surface-
46
+ * doubling with a parallel `cell_grant_leave` event.
47
+ */
48
+ export const CellGrantRevokeAuditMetadata = z.looseObject({
49
+ cell_id: Uuid,
50
+ grant_id: Uuid,
51
+ level: z.enum(['viewer', 'editor']),
52
+ principal: CellGrantPrincipalAuditMetadata,
53
+ self: z.literal(true).optional(),
54
+ });
@@ -0,0 +1,331 @@
1
+ /**
2
+ * Cell-item RPC specs — declarative contract for the four ordered-child
3
+ * verbs (`insert` / `move` / `delete` / `list`).
4
+ *
5
+ * `(parent_id, position) → child_id` rows. `position` is opaque text
6
+ * (fractional-indexing key); the wire validates the alphabet
7
+ * (`^[0-9A-Za-z]+$`) and length, the lex-ordering invariant is the
8
+ * client's contract.
9
+ *
10
+ * @module
11
+ */
12
+ import { z } from 'zod';
13
+ /** Error reason — `cell_item_list` got neither `parent_id` nor `child_id`. */
14
+ export declare const ERROR_CELL_ITEM_LIST_REQUIRES_PARENT_OR_CHILD: "cell_item_list_requires_parent_or_child";
15
+ /**
16
+ * Error reason — `(parent_id, position)` collision on `cell_item_insert`
17
+ * or `cell_item_move`. Surfaces when two clients computed the same
18
+ * fractional-indexing key (rare given helper-side jitter; the safety
19
+ * net for the residual race). Client refreshes its bracket and retries.
20
+ */
21
+ export declare const ERROR_CELL_ITEM_POSITION_TAKEN: "cell_item_position_taken";
22
+ /**
23
+ * Position grammar — base62 fractional-indexing key. Wire enforces
24
+ * non-empty, alphabet only, and the helper's `FRACTIONAL_INDEX_LENGTH_MAX`
25
+ * cap (well above realistic lengths even for hundreds of consecutive
26
+ * front-inserts; set high to avoid arbitrary cliffs). Lex ordering is the
27
+ * contract; the no-trailing-`'0'` invariant lives in the helper, not the
28
+ * wire.
29
+ */
30
+ export declare const CellItemPosition: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
31
+ export type CellItemPosition = z.infer<typeof CellItemPosition>;
32
+ /**
33
+ * Wire-format for a `cell_item` row.
34
+ *
35
+ * `position` is branded `CellItemPosition` so consumers that round-trip
36
+ * the value back into a `position_after` / `position` input field don't
37
+ * need a cast at every call site. Wire ingress is validated by the
38
+ * `CellItemPosition` Zod schema (alphabet + length); wire egress trusts
39
+ * the DB CHECK constraint that backs `cell_item.position`, so the
40
+ * server-side `to_item_json` casts a raw string from `CellItemRow`.
41
+ */
42
+ export declare const ItemJson: z.ZodObject<{
43
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
44
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
45
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
46
+ created_at: z.ZodString;
47
+ }, z.core.$strict>;
48
+ export type ItemJson = z.infer<typeof ItemJson>;
49
+ /**
50
+ * Input for `cell_item_insert`. Caller computes `position` via
51
+ * `fractional_index_between(prev, next)` (`@fuzdev/fuz_util/fractional_index.js`)
52
+ * client-side. Returns `cell_item_position_taken` on `(parent_id,
53
+ * position)` unique violation; client refreshes bracket and retries.
54
+ */
55
+ export declare const CellItemInsertInput: z.ZodObject<{
56
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
57
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
58
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
59
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
60
+ }, z.core.$strict>;
61
+ export type CellItemInsertInput = z.infer<typeof CellItemInsertInput>;
62
+ export declare const CellItemInsertOutput: z.ZodObject<{
63
+ item: z.ZodObject<{
64
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
65
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
66
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
67
+ created_at: z.ZodString;
68
+ }, z.core.$strict>;
69
+ }, z.core.$strict>;
70
+ export type CellItemInsertOutput = z.infer<typeof CellItemInsertOutput>;
71
+ /**
72
+ * Input for `cell_item_move`. Move within the same parent (cross-parent
73
+ * moves are a future extension).
74
+ */
75
+ export declare const CellItemMoveInput: z.ZodObject<{
76
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
77
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
78
+ new_position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
79
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
80
+ }, z.core.$strict>;
81
+ export type CellItemMoveInput = z.infer<typeof CellItemMoveInput>;
82
+ export declare const CellItemMoveOutput: z.ZodObject<{
83
+ item: z.ZodObject<{
84
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
85
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
86
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
87
+ created_at: z.ZodString;
88
+ }, z.core.$strict>;
89
+ }, z.core.$strict>;
90
+ export type CellItemMoveOutput = z.infer<typeof CellItemMoveOutput>;
91
+ /** Input for `cell_item_delete`. Idempotent on the slot key. */
92
+ export declare const CellItemDeleteInput: z.ZodObject<{
93
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
94
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
95
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
96
+ }, z.core.$strict>;
97
+ export type CellItemDeleteInput = z.infer<typeof CellItemDeleteInput>;
98
+ export declare const CellItemDeleteOutput: z.ZodObject<{
99
+ ok: z.ZodLiteral<true>;
100
+ deleted: z.ZodBoolean;
101
+ }, z.core.$strict>;
102
+ export type CellItemDeleteOutput = z.infer<typeof CellItemDeleteOutput>;
103
+ /**
104
+ * Input for `cell_item_list`. Pass `parent_id` for forward items or
105
+ * `child_id` for reverse lists — exactly one. Reverse listing has 2-layer
106
+ * authz (child view-check gates the call; per-parent view-check filters
107
+ * the rows).
108
+ *
109
+ * Forward listing supports cursor pagination via `position_after`
110
+ * (return rows with `position > position_after`). The reverse listing
111
+ * doesn't paginate (the result set is small in practice — number of
112
+ * parents containing a given child).
113
+ */
114
+ export declare const CellItemListInput: z.ZodObject<{
115
+ parent_id: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
116
+ child_id: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
117
+ position_after: z.ZodOptional<z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">>;
118
+ limit: z.ZodOptional<z.ZodNumber>;
119
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
120
+ }, z.core.$strict>;
121
+ export type CellItemListInput = z.infer<typeof CellItemListInput>;
122
+ export declare const CellItemListOutput: z.ZodObject<{
123
+ items: z.ZodArray<z.ZodObject<{
124
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
125
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
126
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
127
+ created_at: z.ZodString;
128
+ }, z.core.$strict>>;
129
+ }, z.core.$strict>;
130
+ export type CellItemListOutput = z.infer<typeof CellItemListOutput>;
131
+ export declare const cell_item_insert_action_spec: {
132
+ method: string;
133
+ kind: "request_response";
134
+ initiator: "frontend";
135
+ auth: {
136
+ account: "required";
137
+ actor: "required";
138
+ };
139
+ side_effects: true;
140
+ input: z.ZodObject<{
141
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
142
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
143
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
144
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
145
+ }, z.core.$strict>;
146
+ output: z.ZodObject<{
147
+ item: z.ZodObject<{
148
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
149
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
150
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
151
+ created_at: z.ZodString;
152
+ }, z.core.$strict>;
153
+ }, z.core.$strict>;
154
+ async: true;
155
+ description: string;
156
+ };
157
+ export declare const cell_item_move_action_spec: {
158
+ method: string;
159
+ kind: "request_response";
160
+ initiator: "frontend";
161
+ auth: {
162
+ account: "required";
163
+ actor: "required";
164
+ };
165
+ side_effects: true;
166
+ input: z.ZodObject<{
167
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
168
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
169
+ new_position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
170
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
171
+ }, z.core.$strict>;
172
+ output: z.ZodObject<{
173
+ item: z.ZodObject<{
174
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
175
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
176
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
177
+ created_at: z.ZodString;
178
+ }, z.core.$strict>;
179
+ }, z.core.$strict>;
180
+ async: true;
181
+ description: string;
182
+ };
183
+ export declare const cell_item_delete_action_spec: {
184
+ method: string;
185
+ kind: "request_response";
186
+ initiator: "frontend";
187
+ auth: {
188
+ account: "required";
189
+ actor: "required";
190
+ };
191
+ side_effects: true;
192
+ input: z.ZodObject<{
193
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
194
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
195
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
196
+ }, z.core.$strict>;
197
+ output: z.ZodObject<{
198
+ ok: z.ZodLiteral<true>;
199
+ deleted: z.ZodBoolean;
200
+ }, z.core.$strict>;
201
+ async: true;
202
+ description: string;
203
+ };
204
+ export declare const cell_item_list_action_spec: {
205
+ method: string;
206
+ kind: "request_response";
207
+ initiator: "frontend";
208
+ auth: {
209
+ account: "optional";
210
+ actor: "optional";
211
+ };
212
+ side_effects: false;
213
+ input: z.ZodObject<{
214
+ parent_id: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
215
+ child_id: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
216
+ position_after: z.ZodOptional<z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">>;
217
+ limit: z.ZodOptional<z.ZodNumber>;
218
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
219
+ }, z.core.$strict>;
220
+ output: z.ZodObject<{
221
+ items: z.ZodArray<z.ZodObject<{
222
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
223
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
224
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
225
+ created_at: z.ZodString;
226
+ }, z.core.$strict>>;
227
+ }, z.core.$strict>;
228
+ async: true;
229
+ rate_limit: "ip";
230
+ description: string;
231
+ };
232
+ /** All cell_item action specs — composed into `all_cell_action_specs`. */
233
+ export declare const all_cell_item_action_specs: readonly [{
234
+ method: string;
235
+ kind: "request_response";
236
+ initiator: "frontend";
237
+ auth: {
238
+ account: "required";
239
+ actor: "required";
240
+ };
241
+ side_effects: true;
242
+ input: z.ZodObject<{
243
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
244
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
245
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
246
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
247
+ }, z.core.$strict>;
248
+ output: z.ZodObject<{
249
+ item: z.ZodObject<{
250
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
251
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
252
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
253
+ created_at: z.ZodString;
254
+ }, z.core.$strict>;
255
+ }, z.core.$strict>;
256
+ async: true;
257
+ description: string;
258
+ }, {
259
+ method: string;
260
+ kind: "request_response";
261
+ initiator: "frontend";
262
+ auth: {
263
+ account: "required";
264
+ actor: "required";
265
+ };
266
+ side_effects: true;
267
+ input: z.ZodObject<{
268
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
269
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
270
+ new_position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
271
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
272
+ }, z.core.$strict>;
273
+ output: z.ZodObject<{
274
+ item: z.ZodObject<{
275
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
276
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
277
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
278
+ created_at: z.ZodString;
279
+ }, z.core.$strict>;
280
+ }, z.core.$strict>;
281
+ async: true;
282
+ description: string;
283
+ }, {
284
+ method: string;
285
+ kind: "request_response";
286
+ initiator: "frontend";
287
+ auth: {
288
+ account: "required";
289
+ actor: "required";
290
+ };
291
+ side_effects: true;
292
+ input: z.ZodObject<{
293
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
294
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
295
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
296
+ }, z.core.$strict>;
297
+ output: z.ZodObject<{
298
+ ok: z.ZodLiteral<true>;
299
+ deleted: z.ZodBoolean;
300
+ }, z.core.$strict>;
301
+ async: true;
302
+ description: string;
303
+ }, {
304
+ method: string;
305
+ kind: "request_response";
306
+ initiator: "frontend";
307
+ auth: {
308
+ account: "optional";
309
+ actor: "optional";
310
+ };
311
+ side_effects: false;
312
+ input: z.ZodObject<{
313
+ parent_id: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
314
+ child_id: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
315
+ position_after: z.ZodOptional<z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">>;
316
+ limit: z.ZodOptional<z.ZodNumber>;
317
+ acting: z.ZodOptional<z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">>;
318
+ }, z.core.$strict>;
319
+ output: z.ZodObject<{
320
+ items: z.ZodArray<z.ZodObject<{
321
+ parent_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
322
+ position: z.core.$ZodBranded<z.ZodString, "CellItemPosition", "out">;
323
+ child_id: z.core.$ZodBranded<z.ZodUUID, "Uuid", "out">;
324
+ created_at: z.ZodString;
325
+ }, z.core.$strict>>;
326
+ }, z.core.$strict>;
327
+ async: true;
328
+ rate_limit: "ip";
329
+ description: string;
330
+ }];
331
+ //# sourceMappingURL=cell_item_action_specs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cell_item_action_specs.d.ts","sourceRoot":"../src/lib/","sources":["../../src/lib/auth/cell_item_action_specs.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAYtB,8EAA8E;AAC9E,eAAO,MAAM,6CAA6C,EACzD,yCAAkD,CAAC;AAEpD;;;;;GAKG;AACH,eAAO,MAAM,8BAA8B,EAAG,0BAAmC,CAAC;AAIlF;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,4DAKF,CAAC;AAC5B,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEhE;;;;;;;;;GASG;AACH,eAAO,MAAM,QAAQ;;;;;kBAKnB,CAAC;AACH,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,QAAQ,CAAC,CAAC;AAIhD;;;;;GAKG;AACH,eAAO,MAAM,mBAAmB;;;;;kBAO9B,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEtE,eAAO,MAAM,oBAAoB;;;;;;;kBAAmC,CAAC;AACrE,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAIxE;;;GAGG;AACH,eAAO,MAAM,iBAAiB;;;;;kBAK5B,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE,eAAO,MAAM,kBAAkB;;;;;;;kBAAmC,CAAC;AACnE,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAIpE,gEAAgE;AAChE,eAAO,MAAM,mBAAmB;;;;kBAI9B,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEtE,eAAO,MAAM,oBAAoB;;;kBAG/B,CAAC;AACH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAIxE;;;;;;;;;;GAUG;AACH,eAAO,MAAM,iBAAiB;;;;;;kBAmB3B,CAAC;AACJ,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAElE,eAAO,MAAM,kBAAkB;;;;;;;kBAE7B,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAIpE,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;CAWJ,CAAC;AAEtC,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;CAWF,CAAC;AAEtC,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;CAWJ,CAAC;AAEtC,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;CAYF,CAAC;AAEtC,0EAA0E;AAC1E,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAK7B,CAAC"}