@cosmicdrift/kumiko-framework 0.406.0 → 0.410.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 (212) hide show
  1. package/AGENTS.md +4 -2
  2. package/agents/api/framework-db.md +1 -0
  3. package/agents/api/framework-engine.md +17 -2
  4. package/agents/api/framework-ui-types.md +15 -0
  5. package/agents/api/renderer-web.md +156 -2
  6. package/agents/api/types.md +113 -71
  7. package/agents/api.md +4 -4
  8. package/agents/boot-rules.md +744 -0
  9. package/agents/examples/anonymous-access.md +23 -1
  10. package/agents/examples/contact.md +173 -0
  11. package/agents/examples/delivery-notifications.md +34 -1
  12. package/agents/examples/record-detail-layout.md +13 -2
  13. package/agents/examples/search.md +65 -3
  14. package/agents/examples/secrets-demo.md +96 -2
  15. package/agents/examples/tenant-inactivity.md +138 -0
  16. package/agents/examples.md +2 -0
  17. package/agents/features-index.md +4 -0
  18. package/agents/features.md +25 -1
  19. package/agents/widgets.md +12 -1
  20. package/dist/api/export/export-rows.js +1 -0
  21. package/dist/compliance/index.d.ts +1 -1
  22. package/dist/db/event-store-executor-read-where.js +15 -5
  23. package/dist/db/index.d.ts +1 -1
  24. package/dist/db/index.js +1 -1
  25. package/dist/db/migrate-generator.js +3 -1
  26. package/dist/db/queries/event-consumer.js +11 -7
  27. package/dist/db/queries/event-store.d.ts +2 -1
  28. package/dist/db/queries/event-store.js +25 -6
  29. package/dist/db/queries/rls-boot-catalog.js +3 -1
  30. package/dist/db/queries/session-advisory-lock.d.ts +7 -0
  31. package/dist/db/queries/session-advisory-lock.js +23 -0
  32. package/dist/db/query.js +7 -10
  33. package/dist/db/row-level-security-connection.js +4 -2
  34. package/dist/engine/access.js +5 -1
  35. package/dist/engine/active-membership.js +1 -0
  36. package/dist/engine/boot-validator/access-declarations.js +76 -33
  37. package/dist/engine/boot-validator/action-wiring.js +8 -6
  38. package/dist/engine/boot-validator/agent-effect-rules.d.ts +12 -0
  39. package/dist/engine/boot-validator/agent-effect-rules.js +12 -0
  40. package/dist/engine/boot-validator/agent-effect.d.ts +2 -0
  41. package/dist/engine/boot-validator/agent-effect.js +20 -0
  42. package/dist/engine/boot-validator/boot-context.js +5 -1
  43. package/dist/engine/boot-validator/boot-environment-rules.d.ts +12 -0
  44. package/dist/engine/boot-validator/boot-environment-rules.js +12 -0
  45. package/dist/engine/boot-validator/boot-phases-app.js +5 -1
  46. package/dist/engine/boot-validator/boot-phases.js +3 -1
  47. package/dist/engine/boot-validator/boot-rules.d.ts +2624 -0
  48. package/dist/engine/boot-validator/boot-rules.js +58 -0
  49. package/dist/engine/boot-validator/bundled-lists-table.js +23 -9
  50. package/dist/engine/boot-validator/config-deps.js +71 -23
  51. package/dist/engine/boot-validator/config-edit-action-rules.d.ts +17 -0
  52. package/dist/engine/boot-validator/config-edit-action-rules.js +17 -0
  53. package/dist/engine/boot-validator/config-key-rules.d.ts +117 -0
  54. package/dist/engine/boot-validator/config-key-rules.js +117 -0
  55. package/dist/engine/boot-validator/custom-screen-write-qns.js +6 -2
  56. package/dist/engine/boot-validator/derived-sql-fields-rules.d.ts +77 -0
  57. package/dist/engine/boot-validator/derived-sql-fields-rules.js +77 -0
  58. package/dist/engine/boot-validator/derived-sql-fields.js +53 -17
  59. package/dist/engine/boot-validator/detail-screens.js +10 -4
  60. package/dist/engine/boot-validator/entity-declaration-rules.d.ts +92 -0
  61. package/dist/engine/boot-validator/entity-declaration-rules.js +92 -0
  62. package/dist/engine/boot-validator/entity-handler-access-rules.d.ts +102 -0
  63. package/dist/engine/boot-validator/entity-handler-access-rules.js +102 -0
  64. package/dist/engine/boot-validator/entity-handler.d.ts +0 -7
  65. package/dist/engine/boot-validator/entity-handler.js +259 -355
  66. package/dist/engine/boot-validator/entity-image-variants.d.ts +2 -0
  67. package/dist/engine/boot-validator/entity-image-variants.js +91 -0
  68. package/dist/engine/boot-validator/entity-list-aggregate-options.js +8 -2
  69. package/dist/engine/boot-validator/entity-reference-embedded-rules.d.ts +117 -0
  70. package/dist/engine/boot-validator/entity-reference-embedded-rules.js +117 -0
  71. package/dist/engine/boot-validator/entity-select-image-rules.d.ts +122 -0
  72. package/dist/engine/boot-validator/entity-select-image-rules.js +122 -0
  73. package/dist/engine/boot-validator/entity-select.d.ts +8 -0
  74. package/dist/engine/boot-validator/entity-select.js +197 -0
  75. package/dist/engine/boot-validator/entity-structure-rules.d.ts +107 -0
  76. package/dist/engine/boot-validator/entity-structure-rules.js +107 -0
  77. package/dist/engine/boot-validator/field-conditions-rules.d.ts +92 -0
  78. package/dist/engine/boot-validator/field-conditions-rules.js +92 -0
  79. package/dist/engine/boot-validator/field-conditions.js +67 -22
  80. package/dist/engine/boot-validator/form-derivations-rules.d.ts +77 -0
  81. package/dist/engine/boot-validator/form-derivations-rules.js +77 -0
  82. package/dist/engine/boot-validator/form-derivations.js +52 -18
  83. package/dist/engine/boot-validator/global-tenancy.js +13 -7
  84. package/dist/engine/boot-validator/handler-declaration-rules.d.ts +77 -0
  85. package/dist/engine/boot-validator/handler-declaration-rules.js +77 -0
  86. package/dist/engine/boot-validator/handler-field-references-rules.d.ts +22 -0
  87. package/dist/engine/boot-validator/handler-field-references-rules.js +22 -0
  88. package/dist/engine/boot-validator/handler-field-references.js +14 -6
  89. package/dist/engine/boot-validator/list-bulk-actions-rules.d.ts +42 -0
  90. package/dist/engine/boot-validator/list-bulk-actions-rules.js +42 -0
  91. package/dist/engine/boot-validator/list-bulk-actions.js +29 -11
  92. package/dist/engine/boot-validator/list-column-layout.js +22 -10
  93. package/dist/engine/boot-validator/list-query-rules.d.ts +107 -0
  94. package/dist/engine/boot-validator/list-query-rules.js +107 -0
  95. package/dist/engine/boot-validator/list-table-aggregate-options.js +43 -15
  96. package/dist/engine/boot-validator/list-table-aggregate-query.js +7 -3
  97. package/dist/engine/boot-validator/list-table-aggregate-rules.d.ts +82 -0
  98. package/dist/engine/boot-validator/list-table-aggregate-rules.js +82 -0
  99. package/dist/engine/boot-validator/list-table-export-options.js +19 -7
  100. package/dist/engine/boot-validator/list-table-options.js +33 -13
  101. package/dist/engine/boot-validator/list-table-reject-unknown-keys.js +6 -2
  102. package/dist/engine/boot-validator/list-table-rules.d.ts +132 -0
  103. package/dist/engine/boot-validator/list-table-rules.js +132 -0
  104. package/dist/engine/boot-validator/nav-rules.d.ts +42 -0
  105. package/dist/engine/boot-validator/nav-rules.js +42 -0
  106. package/dist/engine/boot-validator/nav.js +33 -17
  107. package/dist/engine/boot-validator/ownership-rules.d.ts +27 -0
  108. package/dist/engine/boot-validator/ownership-rules.js +27 -0
  109. package/dist/engine/boot-validator/ownership.js +28 -12
  110. package/dist/engine/boot-validator/parent-ref.js +32 -20
  111. package/dist/engine/boot-validator/projection-list-screens.js +76 -35
  112. package/dist/engine/boot-validator/query-output-columns.js +9 -3
  113. package/dist/engine/boot-validator/query-refs.js +20 -10
  114. package/dist/engine/boot-validator/query-rules.d.ts +37 -0
  115. package/dist/engine/boot-validator/query-rules.js +37 -0
  116. package/dist/engine/boot-validator/read-gate.js +14 -10
  117. package/dist/engine/boot-validator/record-owned.js +5 -1
  118. package/dist/engine/boot-validator/related-list-table-rules.js +17 -7
  119. package/dist/engine/boot-validator/screens-actions-rules.d.ts +185 -0
  120. package/dist/engine/boot-validator/screens-actions-rules.js +185 -0
  121. package/dist/engine/boot-validator/screens-actions.js +169 -93
  122. package/dist/engine/boot-validator/screens-dashboard-chart-rules.d.ts +87 -0
  123. package/dist/engine/boot-validator/screens-dashboard-chart-rules.js +87 -0
  124. package/dist/engine/boot-validator/screens-dashboard-rules.d.ts +227 -0
  125. package/dist/engine/boot-validator/screens-dashboard-rules.js +227 -0
  126. package/dist/engine/boot-validator/screens-dashboard.js +222 -85
  127. package/dist/engine/boot-validator/screens-forms-layout-rules.d.ts +122 -0
  128. package/dist/engine/boot-validator/screens-forms-layout-rules.js +122 -0
  129. package/dist/engine/boot-validator/screens-forms-rules.d.ts +152 -0
  130. package/dist/engine/boot-validator/screens-forms-rules.js +152 -0
  131. package/dist/engine/boot-validator/screens-forms.js +240 -112
  132. package/dist/engine/boot-validator/screens-kind-config-edit.js +72 -16
  133. package/dist/engine/boot-validator/screens-kind-entity-edit.js +15 -7
  134. package/dist/engine/boot-validator/screens-kind-entity-list.js +57 -32
  135. package/dist/engine/boot-validator/screens-kind-projection-detail-rules.d.ts +92 -0
  136. package/dist/engine/boot-validator/screens-kind-projection-detail-rules.js +92 -0
  137. package/dist/engine/boot-validator/screens-kind-projection-detail.js +85 -47
  138. package/dist/engine/boot-validator/screens-kind-rules.d.ts +137 -0
  139. package/dist/engine/boot-validator/screens-kind-rules.js +137 -0
  140. package/dist/engine/boot-validator/screens-kind-secret-mint.js +18 -8
  141. package/dist/engine/boot-validator/screens-kind-shared.js +40 -22
  142. package/dist/engine/boot-validator/screens-lists-rules.d.ts +82 -0
  143. package/dist/engine/boot-validator/screens-lists-rules.js +82 -0
  144. package/dist/engine/boot-validator/screens-lists.js +90 -45
  145. package/dist/engine/boot-validator/screens-rules.d.ts +57 -0
  146. package/dist/engine/boot-validator/screens-rules.js +57 -0
  147. package/dist/engine/boot-validator/screens.js +17 -12
  148. package/dist/engine/boot-validator/transaction-phases.js +12 -4
  149. package/dist/engine/boot-validator/transfer-graph.js +17 -11
  150. package/dist/engine/boot-validator/url-prefill-fields.js +9 -5
  151. package/dist/engine/boot-validator/workspaces.js +11 -5
  152. package/dist/engine/boot-validator/zod-shape.js +6 -2
  153. package/dist/engine/entity-handlers.d.ts +1 -0
  154. package/dist/engine/entity-handlers.js +3 -0
  155. package/dist/engine/entity-list-runtime-options.js +23 -29
  156. package/dist/engine/extensions/tenant-data.d.ts +3 -0
  157. package/dist/engine/factories.d.ts +1 -1
  158. package/dist/engine/factories.js +4 -3
  159. package/dist/engine/index.d.ts +4 -2
  160. package/dist/engine/index.js +2 -0
  161. package/dist/engine/project-app-schema-for-roles.js +29 -14
  162. package/dist/engine/registry-facade.js +7 -8
  163. package/dist/engine/registry-validate.js +5 -1
  164. package/dist/engine/soft-delete-cleanup.d.ts +1 -0
  165. package/dist/engine/soft-delete-cleanup.js +5 -0
  166. package/dist/engine/steps/describe-workflow-step-error.js +1 -0
  167. package/dist/es-ops/operations-schema.d.ts +1 -1
  168. package/dist/event-store/ensure-dead-letter-table.d.ts +2 -0
  169. package/dist/event-store/ensure-dead-letter-table.js +10 -0
  170. package/dist/event-store/rebuild-dead-letter.js +2 -8
  171. package/dist/event-store/upcaster-dead-letter.js +2 -8
  172. package/dist/files/copy-pending-file-refs-to-tenant.d.ts +28 -0
  173. package/dist/files/copy-pending-file-refs-to-tenant.js +87 -0
  174. package/dist/files/file-routes.d.ts +1 -1
  175. package/dist/files/file-routes.js +21 -6
  176. package/dist/files/index.d.ts +2 -0
  177. package/dist/files/index.js +1 -0
  178. package/dist/i18n/required-surface-keys.js +1 -0
  179. package/dist/jobs/job-runner-helpers.js +1 -0
  180. package/dist/jobs/job-runner.js +7 -12
  181. package/dist/logging/utils.js +30 -60
  182. package/dist/observability/metrics-handle.js +10 -21
  183. package/dist/pipeline/cascade-handler.js +7 -6
  184. package/dist/pipeline/dispatch-query.js +18 -5
  185. package/dist/pipeline/dispatch-shared.d.ts +1 -0
  186. package/dist/pipeline/dispatch-shared.js +3 -1
  187. package/dist/pipeline/dispatch-write.js +10 -12
  188. package/dist/pipeline/dispatcher.js +12 -14
  189. package/dist/pipeline/event-dispatcher-admin.js +9 -8
  190. package/dist/pipeline/event-dispatcher-delivery.d.ts +19 -1
  191. package/dist/pipeline/event-dispatcher-delivery.js +121 -29
  192. package/dist/pipeline/event-dispatcher.d.ts +5 -1
  193. package/dist/pipeline/event-dispatcher.js +28 -21
  194. package/dist/pipeline/handler-context-phase-denials.js +2 -0
  195. package/dist/pipeline/multi-stream-apply-context.js +12 -20
  196. package/dist/pipeline/system-hooks.d.ts +4 -1
  197. package/dist/pipeline/system-hooks.js +79 -6
  198. package/dist/pipeline/system-identity-switch.js +10 -7
  199. package/dist/search/build-search-snippet.d.ts +9 -0
  200. package/dist/search/build-search-snippet.js +40 -0
  201. package/dist/search/index.d.ts +1 -0
  202. package/dist/search/index.js +1 -0
  203. package/dist/search/meilisearch-adapter.d.ts +32 -0
  204. package/dist/search/meilisearch-adapter.js +153 -56
  205. package/dist/search/meilisearch-chunking.d.ts +21 -0
  206. package/dist/search/meilisearch-chunking.js +96 -0
  207. package/dist/search/reindex-entity.d.ts +1 -0
  208. package/dist/search/reindex-entity.js +97 -52
  209. package/dist/ui-types/index.d.ts +1 -1
  210. package/dist/upgrade-cli.js +3 -14
  211. package/package.json +3 -3
  212. package/src/changes.json +79 -0
@@ -0,0 +1,102 @@
1
+ export declare const HANDLER_ACCESS_RULES: {
2
+ readonly presaveWithoutMappedWrite: {
3
+ readonly id: "extension/presave-without-mapped-write";
4
+ readonly summary: "An extension with preSave is used only on entities that have an entity-mapped write handler.";
5
+ readonly fix: 'Use create/update/delete on a matching entity or name the handler "entity:verb".';
6
+ };
7
+ readonly accessMissing: {
8
+ readonly id: "handler/access-missing";
9
+ readonly summary: "Every write, query and stream handler declares an access rule.";
10
+ readonly fix: "Set access: { roles: [...] } or { openToAll: { reason } }.";
11
+ };
12
+ readonly additionalBucketsEmpty: {
13
+ readonly id: "rate-limit/additional-buckets-empty";
14
+ readonly summary: "additionalRateLimits lists at least one bucket.";
15
+ readonly fix: "Declare a bucket or drop additionalRateLimits.";
16
+ };
17
+ readonly additionalPayloadFieldDuplicate: {
18
+ readonly id: "rate-limit/additional-payload-field-duplicate";
19
+ readonly summary: "additionalRateLimits has one entry per payloadField.";
20
+ readonly fix: "Keep one entry per payloadField.";
21
+ };
22
+ readonly additionalWithoutIpBucket: {
23
+ readonly id: "rate-limit/additional-without-ip-bucket";
24
+ readonly summary: "An anonymous handler with additionalRateLimits also has an ip-keyed rateLimit.";
25
+ readonly fix: 'Set rateLimit: { per: "ip", ... } on the handler.';
26
+ };
27
+ readonly payloadFieldUnknown: {
28
+ readonly id: "rate-limit/payload-field-unknown";
29
+ readonly summary: "Every additionalRateLimits payloadField is a field of the handler schema.";
30
+ readonly fix: "Name a field of the handler Zod object schema.";
31
+ };
32
+ readonly payloadLimitInvalid: {
33
+ readonly id: "rate-limit/payload-limit-invalid";
34
+ readonly summary: "An additionalRateLimits limit is a positive integer.";
35
+ readonly fix: "Set limit to a positive integer.";
36
+ };
37
+ readonly payloadWindowInvalid: {
38
+ readonly id: "rate-limit/payload-window-invalid";
39
+ readonly summary: "An additionalRateLimits windowSeconds is a positive integer.";
40
+ readonly fix: "Set windowSeconds to a positive integer.";
41
+ };
42
+ readonly tenantlessAnonymousAccess: {
43
+ readonly id: "handler/tenantless-anonymous-access";
44
+ readonly summary: "A tenantlessAnonymous handler allows exactly the anonymous role.";
45
+ readonly fix: 'Set access to { roles: ["anonymous"] } or remove tenantlessAnonymous.';
46
+ };
47
+ readonly tenantlessAnonymousWithoutRateLimit: {
48
+ readonly id: "handler/tenantless-anonymous-without-rate-limit";
49
+ readonly summary: "A tenantlessAnonymous handler declares an active rateLimit.";
50
+ readonly fix: 'Set rateLimit: { per: "ip", ... }; disabled does not count.';
51
+ };
52
+ readonly tenantlessAnonymousRateLimitPer: {
53
+ readonly id: "handler/tenantless-anonymous-rate-limit-per";
54
+ readonly summary: "A tenantlessAnonymous handler rate-limits per ip or ip+handler.";
55
+ readonly fix: 'Use per "ip" or "ip+handler".';
56
+ };
57
+ readonly costWithoutRateLimit: {
58
+ readonly id: "rate-limit/cost-without-rate-limit";
59
+ readonly summary: "rateLimitCost requires an active rateLimit.";
60
+ readonly fix: "Declare rateLimit or drop rateLimitCost.";
61
+ };
62
+ readonly costOnAnonymousHandler: {
63
+ readonly id: "rate-limit/cost-on-anonymous-handler";
64
+ readonly summary: "rateLimitCost is declared only on authenticated handlers without an ip bucket.";
65
+ readonly fix: 'Use a user/tenant bucket and drop "anonymous", or drop rateLimitCost.';
66
+ };
67
+ readonly disabledWithoutReason: {
68
+ readonly id: "rate-limit/disabled-without-reason";
69
+ readonly summary: "A disabled rateLimit carries a non-empty reason.";
70
+ readonly fix: 'Provide { disabled: true, reason: "..." }.';
71
+ };
72
+ readonly bucketListEmpty: {
73
+ readonly id: "rate-limit/bucket-list-empty";
74
+ readonly summary: "A rateLimit array lists at least one bucket.";
75
+ readonly fix: "Declare a bucket or drop the option.";
76
+ };
77
+ readonly bucketPerDuplicate: {
78
+ readonly id: "rate-limit/bucket-per-duplicate";
79
+ readonly summary: 'A rateLimit array has one entry per "per".';
80
+ readonly fix: 'Keep one entry per "per".';
81
+ };
82
+ readonly accessAllRole: {
83
+ readonly id: "handler/access-all-role";
84
+ readonly summary: 'Handler access does not list the role "all".';
85
+ readonly fix: 'Use roles: ["anonymous"] plus an ip rateLimit, or openToAll: { reason }.';
86
+ };
87
+ readonly anonymousWithoutRateLimit: {
88
+ readonly id: "rate-limit/anonymous-without-rate-limit";
89
+ readonly summary: "A handler that allows anonymous callers declares a rateLimit.";
90
+ readonly fix: 'Set rateLimit: { per: "ip", ... } or { disabled: true, reason }.';
91
+ };
92
+ readonly anonymousUserBucket: {
93
+ readonly id: "rate-limit/anonymous-user-bucket";
94
+ readonly summary: "A handler that allows anonymous callers does not bucket per user.";
95
+ readonly fix: 'Use rateLimit.per "ip" or "ip+handler".';
96
+ };
97
+ readonly perInstanceWithTable: {
98
+ readonly id: "projection/per-instance-with-table";
99
+ readonly summary: "A MultiStreamProjection with a table uses shared delivery.";
100
+ readonly fix: 'Use delivery "shared", or drop the table for side-effect-only consumers.';
101
+ };
102
+ };
@@ -0,0 +1,102 @@
1
+ export const HANDLER_ACCESS_RULES = {
2
+ presaveWithoutMappedWrite: {
3
+ id: "extension/presave-without-mapped-write",
4
+ summary: "An extension with preSave is used only on entities that have an entity-mapped write handler.",
5
+ fix: 'Use create/update/delete on a matching entity or name the handler "entity:verb".',
6
+ },
7
+ accessMissing: {
8
+ id: "handler/access-missing",
9
+ summary: "Every write, query and stream handler declares an access rule.",
10
+ fix: "Set access: { roles: [...] } or { openToAll: { reason } }.",
11
+ },
12
+ additionalBucketsEmpty: {
13
+ id: "rate-limit/additional-buckets-empty",
14
+ summary: "additionalRateLimits lists at least one bucket.",
15
+ fix: "Declare a bucket or drop additionalRateLimits.",
16
+ },
17
+ additionalPayloadFieldDuplicate: {
18
+ id: "rate-limit/additional-payload-field-duplicate",
19
+ summary: "additionalRateLimits has one entry per payloadField.",
20
+ fix: "Keep one entry per payloadField.",
21
+ },
22
+ additionalWithoutIpBucket: {
23
+ id: "rate-limit/additional-without-ip-bucket",
24
+ summary: "An anonymous handler with additionalRateLimits also has an ip-keyed rateLimit.",
25
+ fix: 'Set rateLimit: { per: "ip", ... } on the handler.',
26
+ },
27
+ payloadFieldUnknown: {
28
+ id: "rate-limit/payload-field-unknown",
29
+ summary: "Every additionalRateLimits payloadField is a field of the handler schema.",
30
+ fix: "Name a field of the handler Zod object schema.",
31
+ },
32
+ payloadLimitInvalid: {
33
+ id: "rate-limit/payload-limit-invalid",
34
+ summary: "An additionalRateLimits limit is a positive integer.",
35
+ fix: "Set limit to a positive integer.",
36
+ },
37
+ payloadWindowInvalid: {
38
+ id: "rate-limit/payload-window-invalid",
39
+ summary: "An additionalRateLimits windowSeconds is a positive integer.",
40
+ fix: "Set windowSeconds to a positive integer.",
41
+ },
42
+ tenantlessAnonymousAccess: {
43
+ id: "handler/tenantless-anonymous-access",
44
+ summary: "A tenantlessAnonymous handler allows exactly the anonymous role.",
45
+ fix: 'Set access to { roles: ["anonymous"] } or remove tenantlessAnonymous.',
46
+ },
47
+ tenantlessAnonymousWithoutRateLimit: {
48
+ id: "handler/tenantless-anonymous-without-rate-limit",
49
+ summary: "A tenantlessAnonymous handler declares an active rateLimit.",
50
+ fix: 'Set rateLimit: { per: "ip", ... }; disabled does not count.',
51
+ },
52
+ tenantlessAnonymousRateLimitPer: {
53
+ id: "handler/tenantless-anonymous-rate-limit-per",
54
+ summary: "A tenantlessAnonymous handler rate-limits per ip or ip+handler.",
55
+ fix: 'Use per "ip" or "ip+handler".',
56
+ },
57
+ costWithoutRateLimit: {
58
+ id: "rate-limit/cost-without-rate-limit",
59
+ summary: "rateLimitCost requires an active rateLimit.",
60
+ fix: "Declare rateLimit or drop rateLimitCost.",
61
+ },
62
+ costOnAnonymousHandler: {
63
+ id: "rate-limit/cost-on-anonymous-handler",
64
+ summary: "rateLimitCost is declared only on authenticated handlers without an ip bucket.",
65
+ fix: 'Use a user/tenant bucket and drop "anonymous", or drop rateLimitCost.',
66
+ },
67
+ disabledWithoutReason: {
68
+ id: "rate-limit/disabled-without-reason",
69
+ summary: "A disabled rateLimit carries a non-empty reason.",
70
+ fix: 'Provide { disabled: true, reason: "..." }.',
71
+ },
72
+ bucketListEmpty: {
73
+ id: "rate-limit/bucket-list-empty",
74
+ summary: "A rateLimit array lists at least one bucket.",
75
+ fix: "Declare a bucket or drop the option.",
76
+ },
77
+ bucketPerDuplicate: {
78
+ id: "rate-limit/bucket-per-duplicate",
79
+ summary: 'A rateLimit array has one entry per "per".',
80
+ fix: 'Keep one entry per "per".',
81
+ },
82
+ accessAllRole: {
83
+ id: "handler/access-all-role",
84
+ summary: 'Handler access does not list the role "all".',
85
+ fix: 'Use roles: ["anonymous"] plus an ip rateLimit, or openToAll: { reason }.',
86
+ },
87
+ anonymousWithoutRateLimit: {
88
+ id: "rate-limit/anonymous-without-rate-limit",
89
+ summary: "A handler that allows anonymous callers declares a rateLimit.",
90
+ fix: 'Set rateLimit: { per: "ip", ... } or { disabled: true, reason }.',
91
+ },
92
+ anonymousUserBucket: {
93
+ id: "rate-limit/anonymous-user-bucket",
94
+ summary: "A handler that allows anonymous callers does not bucket per user.",
95
+ fix: 'Use rateLimit.per "ip" or "ip+handler".',
96
+ },
97
+ perInstanceWithTable: {
98
+ id: "projection/per-instance-with-table",
99
+ summary: "A MultiStreamProjection with a table uses shared delivery.",
100
+ fix: 'Use delivery "shared", or drop the table for side-effect-only consumers.',
101
+ },
102
+ };
@@ -1,5 +1,4 @@
1
1
  import type { QueryHandlerDef } from "@cosmicdrift/kumiko-types/handlers";
2
- import type { FieldCondition } from "@cosmicdrift/kumiko-types/screen";
3
2
  import type { FeatureDefinition } from "../types/index.ts";
4
3
  export declare const FILE_FIELD_TYPES: Set<string>;
5
4
  export declare const PII_DIRECT_NAME_HINTS: ReadonlySet<string>;
@@ -22,12 +21,6 @@ export declare function validateEncryptedFields(feature: FeatureDefinition): boo
22
21
  export declare function validateFileFields(feature: FeatureDefinition): boolean;
23
22
  export declare function validateReferenceFields(feature: FeatureDefinition, featureMap: ReadonlyMap<string, FeatureDefinition>, queryHandlers: ReadonlyMap<string, QueryHandlerDef>): void;
24
23
  export declare function validateEmbeddedFields(feature: FeatureDefinition, featureMap: ReadonlyMap<string, FeatureDefinition>, queryHandlers: ReadonlyMap<string, QueryHandlerDef>): void;
25
- export declare function validateEntitySelectOptionsQuery(feature: FeatureDefinition): void;
26
- export declare function validateEntitySelectAvailabilityQuery(feature: FeatureDefinition, queryHandlers: ReadonlyMap<string, QueryHandlerDef>): void;
27
- export declare function conditionComparisonValues(when: Exclude<FieldCondition, boolean>): readonly unknown[];
28
- export declare function validateEntitySelectConditionalOptions(feature: FeatureDefinition): void;
29
- export declare function validateMultiSelectFields(feature: FeatureDefinition): void;
30
- export declare function validateImageVariants(feature: FeatureDefinition): void;
31
24
  export declare const LOCKABLE_FIELD_TYPES: ReadonlySet<string>;
32
25
  export declare function validateLockedWhen(feature: FeatureDefinition): void;
33
26
  export declare function validateTransitions(feature: FeatureDefinition): void;