@objectstack/spec 0.3.0 → 0.3.1

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 (386) hide show
  1. package/dist/ai/conversation.zod.d.ts +1059 -0
  2. package/dist/ai/conversation.zod.d.ts.map +1 -0
  3. package/dist/ai/conversation.zod.js +248 -0
  4. package/dist/ai/cost.zod.d.ts +2025 -0
  5. package/dist/ai/cost.zod.d.ts.map +1 -0
  6. package/dist/ai/cost.zod.js +324 -0
  7. package/dist/ai/index.d.ts +8 -0
  8. package/dist/ai/index.d.ts.map +1 -1
  9. package/dist/ai/index.js +8 -0
  10. package/dist/ai/model-registry.zod.d.ts +53 -53
  11. package/dist/ai/nlq.zod.d.ts +24 -24
  12. package/dist/ai/predictive.zod.d.ts +838 -0
  13. package/dist/ai/predictive.zod.d.ts.map +1 -0
  14. package/dist/ai/predictive.zod.js +244 -0
  15. package/dist/ai/rag-pipeline.zod.d.ts +22 -22
  16. package/dist/ai/workflow-automation.zod.d.ts +590 -0
  17. package/dist/ai/workflow-automation.zod.d.ts.map +1 -0
  18. package/dist/ai/workflow-automation.zod.js +197 -0
  19. package/dist/api/contract.zod.d.ts +22 -22
  20. package/dist/data/field.zod.d.ts +409 -4
  21. package/dist/data/field.zod.d.ts.map +1 -1
  22. package/dist/data/field.zod.js +28 -2
  23. package/dist/data/mapping.zod.d.ts +6 -6
  24. package/dist/data/object.zod.d.ts +80 -10
  25. package/dist/data/object.zod.d.ts.map +1 -1
  26. package/dist/data/workflow.zod.d.ts +809 -18
  27. package/dist/data/workflow.zod.d.ts.map +1 -1
  28. package/dist/data/workflow.zod.js +115 -7
  29. package/dist/system/api.zod.d.ts +4 -4
  30. package/dist/system/audit.zod.d.ts +1172 -0
  31. package/dist/system/audit.zod.d.ts.map +1 -0
  32. package/dist/system/audit.zod.js +596 -0
  33. package/dist/system/auth.zod.d.ts +8 -8
  34. package/dist/system/driver.zod.d.ts +4 -4
  35. package/dist/system/events.zod.d.ts +177 -0
  36. package/dist/system/events.zod.d.ts.map +1 -0
  37. package/dist/system/events.zod.js +51 -0
  38. package/dist/system/identity.zod.d.ts +4 -4
  39. package/dist/system/index.d.ts +5 -0
  40. package/dist/system/index.d.ts.map +1 -1
  41. package/dist/system/index.js +5 -0
  42. package/dist/system/job.zod.d.ts +237 -0
  43. package/dist/system/job.zod.d.ts.map +1 -0
  44. package/dist/system/job.zod.js +82 -0
  45. package/dist/system/manifest.zod.d.ts +10 -10
  46. package/dist/system/realtime.zod.d.ts +135 -0
  47. package/dist/system/realtime.zod.d.ts.map +1 -0
  48. package/dist/system/realtime.zod.js +83 -0
  49. package/dist/system/tenant.zod.d.ts +1151 -0
  50. package/dist/system/tenant.zod.d.ts.map +1 -0
  51. package/dist/system/tenant.zod.js +498 -0
  52. package/dist/system/webhook.zod.d.ts +2 -2
  53. package/dist/ui/action.zod.d.ts +8 -8
  54. package/dist/ui/theme.zod.d.ts +12 -12
  55. package/dist/ui/widget.zod.d.ts +40 -5
  56. package/dist/ui/widget.zod.d.ts.map +1 -1
  57. package/json-schema/README.md +127 -0
  58. package/json-schema/ai/AITask.json +123 -0
  59. package/json-schema/ai/AITaskType.json +21 -0
  60. package/json-schema/ai/AIWorkflowAutomation.json +379 -0
  61. package/json-schema/ai/AIWorkflowExecutionResult.json +105 -0
  62. package/json-schema/ai/AIWorkflowTrigger.json +18 -0
  63. package/json-schema/ai/BatchAIWorkflowExecution.json +48 -0
  64. package/json-schema/ai/BillingPeriod.json +18 -0
  65. package/json-schema/ai/BudgetLimit.json +111 -0
  66. package/json-schema/ai/BudgetStatus.json +91 -0
  67. package/json-schema/ai/BudgetType.json +17 -0
  68. package/json-schema/ai/ConversationAnalytics.json +86 -0
  69. package/json-schema/ai/ConversationContext.json +48 -0
  70. package/json-schema/ai/ConversationMessage.json +209 -0
  71. package/json-schema/ai/ConversationSession.json +458 -0
  72. package/json-schema/ai/ConversationSummary.json +73 -0
  73. package/json-schema/ai/CostAlert.json +107 -0
  74. package/json-schema/ai/CostAlertType.json +16 -0
  75. package/json-schema/ai/CostAnalytics.json +589 -0
  76. package/json-schema/ai/CostBreakdownDimension.json +20 -0
  77. package/json-schema/ai/CostBreakdownEntry.json +60 -0
  78. package/json-schema/ai/CostEntry.json +106 -0
  79. package/json-schema/ai/CostMetricType.json +17 -0
  80. package/json-schema/ai/CostOptimizationRecommendation.json +100 -0
  81. package/json-schema/ai/CostQueryFilters.json +112 -0
  82. package/json-schema/ai/CostReport.json +964 -0
  83. package/json-schema/ai/EvaluationMetrics.json +64 -0
  84. package/json-schema/ai/FunctionCall.json +28 -0
  85. package/json-schema/ai/Hyperparameters.json +80 -0
  86. package/json-schema/ai/MessageContent.json +46 -0
  87. package/json-schema/ai/MessageContentType.json +16 -0
  88. package/json-schema/ai/MessagePruningEvent.json +92 -0
  89. package/json-schema/ai/MessageRole.json +16 -0
  90. package/json-schema/ai/ModelDrift.json +73 -0
  91. package/json-schema/ai/ModelFeature.json +71 -0
  92. package/json-schema/ai/PostProcessingAction.json +41 -0
  93. package/json-schema/ai/PredictionRequest.json +39 -0
  94. package/json-schema/ai/PredictionResult.json +82 -0
  95. package/json-schema/ai/PredictiveModel.json +445 -0
  96. package/json-schema/ai/PredictiveModelType.json +18 -0
  97. package/json-schema/ai/TokenBudgetConfig.json +92 -0
  98. package/json-schema/ai/TokenBudgetStrategy.json +16 -0
  99. package/json-schema/ai/TokenUsageStats.json +66 -0
  100. package/json-schema/ai/ToolCall.json +49 -0
  101. package/json-schema/ai/TrainingConfig.json +88 -0
  102. package/json-schema/ai/WorkflowFieldCondition.json +33 -0
  103. package/json-schema/ai/WorkflowSchedule.json +51 -0
  104. package/json-schema/data/CustomScriptAction.json +49 -0
  105. package/json-schema/{Field.json → data/Field.json} +50 -1
  106. package/json-schema/{FieldType.json → data/FieldType.json} +4 -1
  107. package/json-schema/data/HttpCallAction.json +81 -0
  108. package/json-schema/{Object.json → data/Object.json} +50 -1
  109. package/json-schema/data/PushNotificationAction.json +59 -0
  110. package/json-schema/data/SlackMessageAction.json +45 -0
  111. package/json-schema/data/SmsNotificationAction.json +50 -0
  112. package/json-schema/data/TaskCreationAction.json +59 -0
  113. package/json-schema/data/TeamsMessageAction.json +45 -0
  114. package/json-schema/data/WebhookTriggerAction.json +58 -0
  115. package/json-schema/data/WorkflowAction.json +465 -0
  116. package/json-schema/data/WorkflowRule.json +509 -0
  117. package/json-schema/system/AuditConfig.json +587 -0
  118. package/json-schema/system/AuditEvent.json +232 -0
  119. package/json-schema/system/AuditEventActor.json +48 -0
  120. package/json-schema/system/AuditEventChange.json +25 -0
  121. package/json-schema/system/AuditEventFilter.json +127 -0
  122. package/json-schema/system/AuditEventSeverity.json +19 -0
  123. package/json-schema/system/AuditEventTarget.json +33 -0
  124. package/json-schema/system/AuditEventType.json +53 -0
  125. package/json-schema/system/AuditRetentionPolicy.json +73 -0
  126. package/json-schema/system/AuditStorageConfig.json +60 -0
  127. package/json-schema/system/CronSchedule.json +29 -0
  128. package/json-schema/system/DatabaseLevelIsolationStrategy.json +139 -0
  129. package/json-schema/system/Event.json +52 -0
  130. package/json-schema/system/EventHandler.json +29 -0
  131. package/json-schema/system/EventMetadata.json +33 -0
  132. package/json-schema/system/EventPersistence.json +25 -0
  133. package/json-schema/system/EventRoute.json +27 -0
  134. package/json-schema/system/IntervalSchedule.json +25 -0
  135. package/json-schema/system/Job.json +127 -0
  136. package/json-schema/system/JobExecution.json +49 -0
  137. package/json-schema/system/JobExecutionStatus.json +15 -0
  138. package/json-schema/system/LevelIsolationStrategySchema.json +93 -0
  139. package/json-schema/system/OnceSchedule.json +25 -0
  140. package/json-schema/system/Presence.json +40 -0
  141. package/json-schema/system/PresenceStatus.json +14 -0
  142. package/json-schema/system/RealtimeAction.json +14 -0
  143. package/json-schema/system/RealtimeEvent.json +51 -0
  144. package/json-schema/system/RealtimeEventType.json +15 -0
  145. package/json-schema/system/RetryPolicy.json +30 -0
  146. package/json-schema/system/RowLevelIsolationStrategy.json +74 -0
  147. package/json-schema/system/Schedule.json +71 -0
  148. package/json-schema/system/Subscription.json +65 -0
  149. package/json-schema/system/SubscriptionEvent.json +32 -0
  150. package/json-schema/system/SuspiciousActivityRule.json +175 -0
  151. package/json-schema/system/Tenant.json +61 -0
  152. package/json-schema/system/TenantIsolationConfig.json +298 -0
  153. package/json-schema/system/TenantIsolationLevel.json +14 -0
  154. package/json-schema/system/TenantQuota.json +27 -0
  155. package/json-schema/system/TenantSecurityPolicy.json +115 -0
  156. package/json-schema/system/TransportProtocol.json +14 -0
  157. package/json-schema/{Action.json → ui/Action.json} +4 -1
  158. package/json-schema/{ActionParam.json → ui/ActionParam.json} +4 -1
  159. package/json-schema/{FieldWidgetProps.json → ui/FieldWidgetProps.json} +50 -1
  160. package/package.json +12 -12
  161. package/json-schema/AuthenticationConfig.json +0 -601
  162. package/json-schema/AuthenticationProvider.json +0 -617
  163. package/json-schema/MenuItem.json +0 -28
  164. package/json-schema/WorkflowAction.json +0 -84
  165. package/json-schema/WorkflowRule.json +0 -128
  166. /package/json-schema/{AIKnowledge.json → ai/AIKnowledge.json} +0 -0
  167. /package/json-schema/{AIModelConfig.json → ai/AIModelConfig.json} +0 -0
  168. /package/json-schema/{AITool.json → ai/AITool.json} +0 -0
  169. /package/json-schema/{Agent.json → ai/Agent.json} +0 -0
  170. /package/json-schema/{ChunkingStrategy.json → ai/ChunkingStrategy.json} +0 -0
  171. /package/json-schema/{DocumentChunk.json → ai/DocumentChunk.json} +0 -0
  172. /package/json-schema/{DocumentLoaderConfig.json → ai/DocumentLoaderConfig.json} +0 -0
  173. /package/json-schema/{DocumentMetadata.json → ai/DocumentMetadata.json} +0 -0
  174. /package/json-schema/{EmbeddingModel.json → ai/EmbeddingModel.json} +0 -0
  175. /package/json-schema/{Entity.json → ai/Entity.json} +0 -0
  176. /package/json-schema/{FieldSynonymConfig.json → ai/FieldSynonymConfig.json} +0 -0
  177. /package/json-schema/{ModelCapability.json → ai/ModelCapability.json} +0 -0
  178. /package/json-schema/{ModelConfig.json → ai/ModelConfig.json} +0 -0
  179. /package/json-schema/{ModelLimits.json → ai/ModelLimits.json} +0 -0
  180. /package/json-schema/{ModelPricing.json → ai/ModelPricing.json} +0 -0
  181. /package/json-schema/{ModelProvider.json → ai/ModelProvider.json} +0 -0
  182. /package/json-schema/{ModelRegistry.json → ai/ModelRegistry.json} +0 -0
  183. /package/json-schema/{ModelRegistryEntry.json → ai/ModelRegistryEntry.json} +0 -0
  184. /package/json-schema/{ModelSelectionCriteria.json → ai/ModelSelectionCriteria.json} +0 -0
  185. /package/json-schema/{NLQAnalytics.json → ai/NLQAnalytics.json} +0 -0
  186. /package/json-schema/{NLQFieldMapping.json → ai/NLQFieldMapping.json} +0 -0
  187. /package/json-schema/{NLQModelConfig.json → ai/NLQModelConfig.json} +0 -0
  188. /package/json-schema/{NLQParseResult.json → ai/NLQParseResult.json} +0 -0
  189. /package/json-schema/{NLQRequest.json → ai/NLQRequest.json} +0 -0
  190. /package/json-schema/{NLQResponse.json → ai/NLQResponse.json} +0 -0
  191. /package/json-schema/{NLQTrainingExample.json → ai/NLQTrainingExample.json} +0 -0
  192. /package/json-schema/{PromptTemplate.json → ai/PromptTemplate.json} +0 -0
  193. /package/json-schema/{PromptVariable.json → ai/PromptVariable.json} +0 -0
  194. /package/json-schema/{QueryContext.json → ai/QueryContext.json} +0 -0
  195. /package/json-schema/{QueryIntent.json → ai/QueryIntent.json} +0 -0
  196. /package/json-schema/{QueryTemplate.json → ai/QueryTemplate.json} +0 -0
  197. /package/json-schema/{RAGPipelineConfig.json → ai/RAGPipelineConfig.json} +0 -0
  198. /package/json-schema/{RAGPipelineStatus.json → ai/RAGPipelineStatus.json} +0 -0
  199. /package/json-schema/{RAGQueryRequest.json → ai/RAGQueryRequest.json} +0 -0
  200. /package/json-schema/{RAGQueryResponse.json → ai/RAGQueryResponse.json} +0 -0
  201. /package/json-schema/{RerankingConfig.json → ai/RerankingConfig.json} +0 -0
  202. /package/json-schema/{RetrievalStrategy.json → ai/RetrievalStrategy.json} +0 -0
  203. /package/json-schema/{Timeframe.json → ai/Timeframe.json} +0 -0
  204. /package/json-schema/{VectorStoreConfig.json → ai/VectorStoreConfig.json} +0 -0
  205. /package/json-schema/{VectorStoreProvider.json → ai/VectorStoreProvider.json} +0 -0
  206. /package/json-schema/{ApiError.json → api/ApiError.json} +0 -0
  207. /package/json-schema/{BaseResponse.json → api/BaseResponse.json} +0 -0
  208. /package/json-schema/{BulkRequest.json → api/BulkRequest.json} +0 -0
  209. /package/json-schema/{BulkResponse.json → api/BulkResponse.json} +0 -0
  210. /package/json-schema/{CreateRequest.json → api/CreateRequest.json} +0 -0
  211. /package/json-schema/{DeleteResponse.json → api/DeleteResponse.json} +0 -0
  212. /package/json-schema/{ExportRequest.json → api/ExportRequest.json} +0 -0
  213. /package/json-schema/{ListRecordResponse.json → api/ListRecordResponse.json} +0 -0
  214. /package/json-schema/{ModificationResult.json → api/ModificationResult.json} +0 -0
  215. /package/json-schema/{RecordData.json → api/RecordData.json} +0 -0
  216. /package/json-schema/{SingleRecordResponse.json → api/SingleRecordResponse.json} +0 -0
  217. /package/json-schema/{UpdateRequest.json → api/UpdateRequest.json} +0 -0
  218. /package/json-schema/{Address.json → data/Address.json} +0 -0
  219. /package/json-schema/{AggregationFunction.json → data/AggregationFunction.json} +0 -0
  220. /package/json-schema/{AggregationNode.json → data/AggregationNode.json} +0 -0
  221. /package/json-schema/{AsyncValidation.json → data/AsyncValidation.json} +0 -0
  222. /package/json-schema/{ComparisonOperator.json → data/ComparisonOperator.json} +0 -0
  223. /package/json-schema/{ConditionalValidation.json → data/ConditionalValidation.json} +0 -0
  224. /package/json-schema/{CrossFieldValidation.json → data/CrossFieldValidation.json} +0 -0
  225. /package/json-schema/{CustomValidator.json → data/CustomValidator.json} +0 -0
  226. /package/json-schema/{Dataset.json → data/Dataset.json} +0 -0
  227. /package/json-schema/{DatasetMode.json → data/DatasetMode.json} +0 -0
  228. /package/json-schema/{EmailAlertAction.json → data/EmailAlertAction.json} +0 -0
  229. /package/json-schema/{EqualityOperator.json → data/EqualityOperator.json} +0 -0
  230. /package/json-schema/{FieldMapping.json → data/FieldMapping.json} +0 -0
  231. /package/json-schema/{FieldNode.json → data/FieldNode.json} +0 -0
  232. /package/json-schema/{FieldOperators.json → data/FieldOperators.json} +0 -0
  233. /package/json-schema/{FieldPermission.json → data/FieldPermission.json} +0 -0
  234. /package/json-schema/{FieldUpdateAction.json → data/FieldUpdateAction.json} +0 -0
  235. /package/json-schema/{FilterCondition.json → data/FilterCondition.json} +0 -0
  236. /package/json-schema/{FilterNode.json → data/FilterNode.json} +0 -0
  237. /package/json-schema/{FilterOperator.json → data/FilterOperator.json} +0 -0
  238. /package/json-schema/{Flow.json → data/Flow.json} +0 -0
  239. /package/json-schema/{FlowEdge.json → data/FlowEdge.json} +0 -0
  240. /package/json-schema/{FlowNode.json → data/FlowNode.json} +0 -0
  241. /package/json-schema/{FlowNodeAction.json → data/FlowNodeAction.json} +0 -0
  242. /package/json-schema/{FlowVariable.json → data/FlowVariable.json} +0 -0
  243. /package/json-schema/{FormatValidation.json → data/FormatValidation.json} +0 -0
  244. /package/json-schema/{Index.json → data/Index.json} +0 -0
  245. /package/json-schema/{JoinNode.json → data/JoinNode.json} +0 -0
  246. /package/json-schema/{JoinType.json → data/JoinType.json} +0 -0
  247. /package/json-schema/{LocationCoordinates.json → data/LocationCoordinates.json} +0 -0
  248. /package/json-schema/{LogicOperator.json → data/LogicOperator.json} +0 -0
  249. /package/json-schema/{Mapping.json → data/Mapping.json} +0 -0
  250. /package/json-schema/{NormalizedFilter.json → data/NormalizedFilter.json} +0 -0
  251. /package/json-schema/{OWDModel.json → data/OWDModel.json} +0 -0
  252. /package/json-schema/{ObjectCapabilities.json → data/ObjectCapabilities.json} +0 -0
  253. /package/json-schema/{ObjectPermission.json → data/ObjectPermission.json} +0 -0
  254. /package/json-schema/{PermissionSet.json → data/PermissionSet.json} +0 -0
  255. /package/json-schema/{Query.json → data/Query.json} +0 -0
  256. /package/json-schema/{QueryFilter.json → data/QueryFilter.json} +0 -0
  257. /package/json-schema/{RangeOperator.json → data/RangeOperator.json} +0 -0
  258. /package/json-schema/{ScriptValidation.json → data/ScriptValidation.json} +0 -0
  259. /package/json-schema/{SelectOption.json → data/SelectOption.json} +0 -0
  260. /package/json-schema/{SetOperator.json → data/SetOperator.json} +0 -0
  261. /package/json-schema/{SharingLevel.json → data/SharingLevel.json} +0 -0
  262. /package/json-schema/{SharingRule.json → data/SharingRule.json} +0 -0
  263. /package/json-schema/{SharingRuleType.json → data/SharingRuleType.json} +0 -0
  264. /package/json-schema/{SortNode.json → data/SortNode.json} +0 -0
  265. /package/json-schema/{SpecialOperator.json → data/SpecialOperator.json} +0 -0
  266. /package/json-schema/{StateMachineValidation.json → data/StateMachineValidation.json} +0 -0
  267. /package/json-schema/{StringOperator.json → data/StringOperator.json} +0 -0
  268. /package/json-schema/{TransformType.json → data/TransformType.json} +0 -0
  269. /package/json-schema/{Trigger.json → data/Trigger.json} +0 -0
  270. /package/json-schema/{TriggerAction.json → data/TriggerAction.json} +0 -0
  271. /package/json-schema/{TriggerContext.json → data/TriggerContext.json} +0 -0
  272. /package/json-schema/{TriggerTiming.json → data/TriggerTiming.json} +0 -0
  273. /package/json-schema/{UniquenessValidation.json → data/UniquenessValidation.json} +0 -0
  274. /package/json-schema/{ValidationRule.json → data/ValidationRule.json} +0 -0
  275. /package/json-schema/{WindowFunction.json → data/WindowFunction.json} +0 -0
  276. /package/json-schema/{WindowFunctionNode.json → data/WindowFunctionNode.json} +0 -0
  277. /package/json-schema/{WindowSpec.json → data/WindowSpec.json} +0 -0
  278. /package/json-schema/{WorkflowTriggerType.json → data/WorkflowTriggerType.json} +0 -0
  279. /package/json-schema/{Account.json → system/Account.json} +0 -0
  280. /package/json-schema/{AccountLinkingConfig.json → system/AccountLinkingConfig.json} +0 -0
  281. /package/json-schema/{ApiCapabilities.json → system/ApiCapabilities.json} +0 -0
  282. /package/json-schema/{ApiEndpoint.json → system/ApiEndpoint.json} +0 -0
  283. /package/json-schema/{ApiMapping.json → system/ApiMapping.json} +0 -0
  284. /package/json-schema/{ApiRoutes.json → system/ApiRoutes.json} +0 -0
  285. /package/json-schema/{AuditPolicy.json → system/AuditPolicy.json} +0 -0
  286. /package/json-schema/{AuthConfig.json → system/AuthConfig.json} +0 -0
  287. /package/json-schema/{AuthPluginConfig.json → system/AuthPluginConfig.json} +0 -0
  288. /package/json-schema/{AuthStrategy.json → system/AuthStrategy.json} +0 -0
  289. /package/json-schema/{CSRFConfig.json → system/CSRFConfig.json} +0 -0
  290. /package/json-schema/{DatabaseAdapter.json → system/DatabaseAdapter.json} +0 -0
  291. /package/json-schema/{DatabaseMapping.json → system/DatabaseMapping.json} +0 -0
  292. /package/json-schema/{Datasource.json → system/Datasource.json} +0 -0
  293. /package/json-schema/{DatasourceCapabilities.json → system/DatasourceCapabilities.json} +0 -0
  294. /package/json-schema/{Discovery.json → system/Discovery.json} +0 -0
  295. /package/json-schema/{DriverCapabilities.json → system/DriverCapabilities.json} +0 -0
  296. /package/json-schema/{DriverDefinition.json → system/DriverDefinition.json} +0 -0
  297. /package/json-schema/{DriverInterface.json → system/DriverInterface.json} +0 -0
  298. /package/json-schema/{DriverOptions.json → system/DriverOptions.json} +0 -0
  299. /package/json-schema/{DriverType.json → system/DriverType.json} +0 -0
  300. /package/json-schema/{EmailPasswordConfig.json → system/EmailPasswordConfig.json} +0 -0
  301. /package/json-schema/{EnterpriseAuthConfig.json → system/EnterpriseAuthConfig.json} +0 -0
  302. /package/json-schema/{Feature.json → system/Feature.json} +0 -0
  303. /package/json-schema/{HttpMethod.json → system/HttpMethod.json} +0 -0
  304. /package/json-schema/{I18nContext.json → system/I18nContext.json} +0 -0
  305. /package/json-schema/{Invitation.json → system/Invitation.json} +0 -0
  306. /package/json-schema/{InvitationStatus.json → system/InvitationStatus.json} +0 -0
  307. /package/json-schema/{LDAPConfig.json → system/LDAPConfig.json} +0 -0
  308. /package/json-schema/{License.json → system/License.json} +0 -0
  309. /package/json-schema/{Locale.json → system/Locale.json} +0 -0
  310. /package/json-schema/{Logger.json → system/Logger.json} +0 -0
  311. /package/json-schema/{MagicLinkConfig.json → system/MagicLinkConfig.json} +0 -0
  312. /package/json-schema/{Manifest.json → system/Manifest.json} +0 -0
  313. /package/json-schema/{Member.json → system/Member.json} +0 -0
  314. /package/json-schema/{MetricType.json → system/MetricType.json} +0 -0
  315. /package/json-schema/{NetworkPolicy.json → system/NetworkPolicy.json} +0 -0
  316. /package/json-schema/{OAuthProvider.json → system/OAuthProvider.json} +0 -0
  317. /package/json-schema/{OIDCConfig.json → system/OIDCConfig.json} +0 -0
  318. /package/json-schema/{ObjectQLClient.json → system/ObjectQLClient.json} +0 -0
  319. /package/json-schema/{Organization.json → system/Organization.json} +0 -0
  320. /package/json-schema/{PasskeyConfig.json → system/PasskeyConfig.json} +0 -0
  321. /package/json-schema/{PasswordPolicy.json → system/PasswordPolicy.json} +0 -0
  322. /package/json-schema/{Plan.json → system/Plan.json} +0 -0
  323. /package/json-schema/{Plugin.json → system/Plugin.json} +0 -0
  324. /package/json-schema/{PluginContext.json → system/PluginContext.json} +0 -0
  325. /package/json-schema/{PluginLifecycle.json → system/PluginLifecycle.json} +0 -0
  326. /package/json-schema/{Policy.json → system/Policy.json} +0 -0
  327. /package/json-schema/{RateLimit.json → system/RateLimit.json} +0 -0
  328. /package/json-schema/{RateLimitConfig.json → system/RateLimitConfig.json} +0 -0
  329. /package/json-schema/{Role.json → system/Role.json} +0 -0
  330. /package/json-schema/{Router.json → system/Router.json} +0 -0
  331. /package/json-schema/{SAMLConfig.json → system/SAMLConfig.json} +0 -0
  332. /package/json-schema/{Scheduler.json → system/Scheduler.json} +0 -0
  333. /package/json-schema/{ScopedStorage.json → system/ScopedStorage.json} +0 -0
  334. /package/json-schema/{Session.json → system/Session.json} +0 -0
  335. /package/json-schema/{SessionConfig.json → system/SessionConfig.json} +0 -0
  336. /package/json-schema/{SessionPolicy.json → system/SessionPolicy.json} +0 -0
  337. /package/json-schema/{StandardAuthProvider.json → system/StandardAuthProvider.json} +0 -0
  338. /package/json-schema/{SystemAPI.json → system/SystemAPI.json} +0 -0
  339. /package/json-schema/{Territory.json → system/Territory.json} +0 -0
  340. /package/json-schema/{TerritoryModel.json → system/TerritoryModel.json} +0 -0
  341. /package/json-schema/{TerritoryType.json → system/TerritoryType.json} +0 -0
  342. /package/json-schema/{TranslationBundle.json → system/TranslationBundle.json} +0 -0
  343. /package/json-schema/{TranslationData.json → system/TranslationData.json} +0 -0
  344. /package/json-schema/{TwoFactorConfig.json → system/TwoFactorConfig.json} +0 -0
  345. /package/json-schema/{User.json → system/User.json} +0 -0
  346. /package/json-schema/{UserFieldMapping.json → system/UserFieldMapping.json} +0 -0
  347. /package/json-schema/{VerificationToken.json → system/VerificationToken.json} +0 -0
  348. /package/json-schema/{Webhook.json → system/Webhook.json} +0 -0
  349. /package/json-schema/{WebhookReceiver.json → system/WebhookReceiver.json} +0 -0
  350. /package/json-schema/{WebhookTriggerType.json → system/WebhookTriggerType.json} +0 -0
  351. /package/json-schema/{Animation.json → ui/Animation.json} +0 -0
  352. /package/json-schema/{App.json → ui/App.json} +0 -0
  353. /package/json-schema/{AppBranding.json → ui/AppBranding.json} +0 -0
  354. /package/json-schema/{BorderRadius.json → ui/BorderRadius.json} +0 -0
  355. /package/json-schema/{Breakpoints.json → ui/Breakpoints.json} +0 -0
  356. /package/json-schema/{CalendarConfig.json → ui/CalendarConfig.json} +0 -0
  357. /package/json-schema/{ChartType.json → ui/ChartType.json} +0 -0
  358. /package/json-schema/{ColorPalette.json → ui/ColorPalette.json} +0 -0
  359. /package/json-schema/{Dashboard.json → ui/Dashboard.json} +0 -0
  360. /package/json-schema/{DashboardNavItem.json → ui/DashboardNavItem.json} +0 -0
  361. /package/json-schema/{DashboardWidget.json → ui/DashboardWidget.json} +0 -0
  362. /package/json-schema/{FormSection.json → ui/FormSection.json} +0 -0
  363. /package/json-schema/{FormView.json → ui/FormView.json} +0 -0
  364. /package/json-schema/{GanttConfig.json → ui/GanttConfig.json} +0 -0
  365. /package/json-schema/{GroupNavItem.json → ui/GroupNavItem.json} +0 -0
  366. /package/json-schema/{KanbanConfig.json → ui/KanbanConfig.json} +0 -0
  367. /package/json-schema/{ListView.json → ui/ListView.json} +0 -0
  368. /package/json-schema/{NavigationItem.json → ui/NavigationItem.json} +0 -0
  369. /package/json-schema/{ObjectNavItem.json → ui/ObjectNavItem.json} +0 -0
  370. /package/json-schema/{Page.json → ui/Page.json} +0 -0
  371. /package/json-schema/{PageComponent.json → ui/PageComponent.json} +0 -0
  372. /package/json-schema/{PageNavItem.json → ui/PageNavItem.json} +0 -0
  373. /package/json-schema/{PageRegion.json → ui/PageRegion.json} +0 -0
  374. /package/json-schema/{Report.json → ui/Report.json} +0 -0
  375. /package/json-schema/{ReportChart.json → ui/ReportChart.json} +0 -0
  376. /package/json-schema/{ReportColumn.json → ui/ReportColumn.json} +0 -0
  377. /package/json-schema/{ReportGrouping.json → ui/ReportGrouping.json} +0 -0
  378. /package/json-schema/{ReportType.json → ui/ReportType.json} +0 -0
  379. /package/json-schema/{Shadow.json → ui/Shadow.json} +0 -0
  380. /package/json-schema/{Spacing.json → ui/Spacing.json} +0 -0
  381. /package/json-schema/{Theme.json → ui/Theme.json} +0 -0
  382. /package/json-schema/{ThemeMode.json → ui/ThemeMode.json} +0 -0
  383. /package/json-schema/{Typography.json → ui/Typography.json} +0 -0
  384. /package/json-schema/{UrlNavItem.json → ui/UrlNavItem.json} +0 -0
  385. /package/json-schema/{View.json → ui/View.json} +0 -0
  386. /package/json-schema/{ZIndex.json → ui/ZIndex.json} +0 -0
@@ -0,0 +1,1172 @@
1
+ import { z } from 'zod';
2
+ /**
3
+ * Audit Log Architecture
4
+ *
5
+ * Comprehensive audit logging system for compliance and security.
6
+ * Supports SOX, HIPAA, GDPR, and other regulatory requirements.
7
+ *
8
+ * Features:
9
+ * - Records all CRUD operations on data
10
+ * - Tracks authentication events (login, logout, password reset)
11
+ * - Monitors authorization changes (permissions, roles)
12
+ * - Configurable retention policies (180-day GDPR requirement)
13
+ * - Suspicious activity detection and alerting
14
+ */
15
+ /**
16
+ * Audit Event Type Enum
17
+ * Categorizes different types of auditable events in the system
18
+ */
19
+ export declare const AuditEventType: z.ZodEnum<["data.create", "data.read", "data.update", "data.delete", "data.export", "data.import", "data.bulk_update", "data.bulk_delete", "auth.login", "auth.login_failed", "auth.logout", "auth.session_created", "auth.session_expired", "auth.password_reset", "auth.password_changed", "auth.email_verified", "auth.mfa_enabled", "auth.mfa_disabled", "auth.account_locked", "auth.account_unlocked", "authz.permission_granted", "authz.permission_revoked", "authz.role_assigned", "authz.role_removed", "authz.role_created", "authz.role_updated", "authz.role_deleted", "authz.policy_created", "authz.policy_updated", "authz.policy_deleted", "system.config_changed", "system.plugin_installed", "system.plugin_uninstalled", "system.backup_created", "system.backup_restored", "system.integration_added", "system.integration_removed", "security.access_denied", "security.suspicious_activity", "security.data_breach", "security.api_key_created", "security.api_key_revoked"]>;
20
+ export type AuditEventType = z.infer<typeof AuditEventType>;
21
+ /**
22
+ * Audit Event Severity Level
23
+ * Indicates the importance/criticality of an audit event
24
+ */
25
+ export declare const AuditEventSeverity: z.ZodEnum<["debug", "info", "notice", "warning", "error", "critical", "alert", "emergency"]>;
26
+ export type AuditEventSeverity = z.infer<typeof AuditEventSeverity>;
27
+ /**
28
+ * Audit Event Actor Schema
29
+ * Identifies who/what performed the action
30
+ */
31
+ export declare const AuditEventActorSchema: z.ZodObject<{
32
+ /**
33
+ * Actor type (user, system, service, api_client, etc.)
34
+ */
35
+ type: z.ZodEnum<["user", "system", "service", "api_client", "integration"]>;
36
+ /**
37
+ * Unique identifier for the actor
38
+ */
39
+ id: z.ZodString;
40
+ /**
41
+ * Display name of the actor
42
+ */
43
+ name: z.ZodOptional<z.ZodString>;
44
+ /**
45
+ * Email address (for user actors)
46
+ */
47
+ email: z.ZodOptional<z.ZodString>;
48
+ /**
49
+ * IP address of the actor
50
+ */
51
+ ipAddress: z.ZodOptional<z.ZodString>;
52
+ /**
53
+ * User agent string (for web/API requests)
54
+ */
55
+ userAgent: z.ZodOptional<z.ZodString>;
56
+ }, "strip", z.ZodTypeAny, {
57
+ type: "system" | "user" | "service" | "api_client" | "integration";
58
+ id: string;
59
+ email?: string | undefined;
60
+ name?: string | undefined;
61
+ ipAddress?: string | undefined;
62
+ userAgent?: string | undefined;
63
+ }, {
64
+ type: "system" | "user" | "service" | "api_client" | "integration";
65
+ id: string;
66
+ email?: string | undefined;
67
+ name?: string | undefined;
68
+ ipAddress?: string | undefined;
69
+ userAgent?: string | undefined;
70
+ }>;
71
+ export type AuditEventActor = z.infer<typeof AuditEventActorSchema>;
72
+ /**
73
+ * Audit Event Target Schema
74
+ * Identifies what was acted upon
75
+ */
76
+ export declare const AuditEventTargetSchema: z.ZodObject<{
77
+ /**
78
+ * Target type (e.g., 'object', 'record', 'user', 'role', 'config')
79
+ */
80
+ type: z.ZodString;
81
+ /**
82
+ * Unique identifier for the target
83
+ */
84
+ id: z.ZodString;
85
+ /**
86
+ * Display name of the target
87
+ */
88
+ name: z.ZodOptional<z.ZodString>;
89
+ /**
90
+ * Additional metadata about the target
91
+ */
92
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
93
+ }, "strip", z.ZodTypeAny, {
94
+ type: string;
95
+ id: string;
96
+ name?: string | undefined;
97
+ metadata?: Record<string, any> | undefined;
98
+ }, {
99
+ type: string;
100
+ id: string;
101
+ name?: string | undefined;
102
+ metadata?: Record<string, any> | undefined;
103
+ }>;
104
+ export type AuditEventTarget = z.infer<typeof AuditEventTargetSchema>;
105
+ /**
106
+ * Audit Event Change Schema
107
+ * Describes what changed (for update operations)
108
+ */
109
+ export declare const AuditEventChangeSchema: z.ZodObject<{
110
+ /**
111
+ * Field/property that changed
112
+ */
113
+ field: z.ZodString;
114
+ /**
115
+ * Value before the change
116
+ */
117
+ oldValue: z.ZodOptional<z.ZodAny>;
118
+ /**
119
+ * Value after the change
120
+ */
121
+ newValue: z.ZodOptional<z.ZodAny>;
122
+ }, "strip", z.ZodTypeAny, {
123
+ field: string;
124
+ oldValue?: any;
125
+ newValue?: any;
126
+ }, {
127
+ field: string;
128
+ oldValue?: any;
129
+ newValue?: any;
130
+ }>;
131
+ export type AuditEventChange = z.infer<typeof AuditEventChangeSchema>;
132
+ /**
133
+ * Audit Event Schema
134
+ * Complete audit event record
135
+ */
136
+ export declare const AuditEventSchema: z.ZodObject<{
137
+ /**
138
+ * Unique identifier for this audit event
139
+ */
140
+ id: z.ZodString;
141
+ /**
142
+ * Type of event being audited
143
+ */
144
+ eventType: z.ZodEnum<["data.create", "data.read", "data.update", "data.delete", "data.export", "data.import", "data.bulk_update", "data.bulk_delete", "auth.login", "auth.login_failed", "auth.logout", "auth.session_created", "auth.session_expired", "auth.password_reset", "auth.password_changed", "auth.email_verified", "auth.mfa_enabled", "auth.mfa_disabled", "auth.account_locked", "auth.account_unlocked", "authz.permission_granted", "authz.permission_revoked", "authz.role_assigned", "authz.role_removed", "authz.role_created", "authz.role_updated", "authz.role_deleted", "authz.policy_created", "authz.policy_updated", "authz.policy_deleted", "system.config_changed", "system.plugin_installed", "system.plugin_uninstalled", "system.backup_created", "system.backup_restored", "system.integration_added", "system.integration_removed", "security.access_denied", "security.suspicious_activity", "security.data_breach", "security.api_key_created", "security.api_key_revoked"]>;
145
+ /**
146
+ * Severity level of the event
147
+ */
148
+ severity: z.ZodDefault<z.ZodEnum<["debug", "info", "notice", "warning", "error", "critical", "alert", "emergency"]>>;
149
+ /**
150
+ * Timestamp when the event occurred (ISO 8601)
151
+ */
152
+ timestamp: z.ZodString;
153
+ /**
154
+ * Who/what performed the action
155
+ */
156
+ actor: z.ZodObject<{
157
+ /**
158
+ * Actor type (user, system, service, api_client, etc.)
159
+ */
160
+ type: z.ZodEnum<["user", "system", "service", "api_client", "integration"]>;
161
+ /**
162
+ * Unique identifier for the actor
163
+ */
164
+ id: z.ZodString;
165
+ /**
166
+ * Display name of the actor
167
+ */
168
+ name: z.ZodOptional<z.ZodString>;
169
+ /**
170
+ * Email address (for user actors)
171
+ */
172
+ email: z.ZodOptional<z.ZodString>;
173
+ /**
174
+ * IP address of the actor
175
+ */
176
+ ipAddress: z.ZodOptional<z.ZodString>;
177
+ /**
178
+ * User agent string (for web/API requests)
179
+ */
180
+ userAgent: z.ZodOptional<z.ZodString>;
181
+ }, "strip", z.ZodTypeAny, {
182
+ type: "system" | "user" | "service" | "api_client" | "integration";
183
+ id: string;
184
+ email?: string | undefined;
185
+ name?: string | undefined;
186
+ ipAddress?: string | undefined;
187
+ userAgent?: string | undefined;
188
+ }, {
189
+ type: "system" | "user" | "service" | "api_client" | "integration";
190
+ id: string;
191
+ email?: string | undefined;
192
+ name?: string | undefined;
193
+ ipAddress?: string | undefined;
194
+ userAgent?: string | undefined;
195
+ }>;
196
+ /**
197
+ * What was acted upon
198
+ */
199
+ target: z.ZodOptional<z.ZodObject<{
200
+ /**
201
+ * Target type (e.g., 'object', 'record', 'user', 'role', 'config')
202
+ */
203
+ type: z.ZodString;
204
+ /**
205
+ * Unique identifier for the target
206
+ */
207
+ id: z.ZodString;
208
+ /**
209
+ * Display name of the target
210
+ */
211
+ name: z.ZodOptional<z.ZodString>;
212
+ /**
213
+ * Additional metadata about the target
214
+ */
215
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
216
+ }, "strip", z.ZodTypeAny, {
217
+ type: string;
218
+ id: string;
219
+ name?: string | undefined;
220
+ metadata?: Record<string, any> | undefined;
221
+ }, {
222
+ type: string;
223
+ id: string;
224
+ name?: string | undefined;
225
+ metadata?: Record<string, any> | undefined;
226
+ }>>;
227
+ /**
228
+ * Human-readable description of the action
229
+ */
230
+ description: z.ZodString;
231
+ /**
232
+ * Detailed changes (for update operations)
233
+ */
234
+ changes: z.ZodOptional<z.ZodArray<z.ZodObject<{
235
+ /**
236
+ * Field/property that changed
237
+ */
238
+ field: z.ZodString;
239
+ /**
240
+ * Value before the change
241
+ */
242
+ oldValue: z.ZodOptional<z.ZodAny>;
243
+ /**
244
+ * Value after the change
245
+ */
246
+ newValue: z.ZodOptional<z.ZodAny>;
247
+ }, "strip", z.ZodTypeAny, {
248
+ field: string;
249
+ oldValue?: any;
250
+ newValue?: any;
251
+ }, {
252
+ field: string;
253
+ oldValue?: any;
254
+ newValue?: any;
255
+ }>, "many">>;
256
+ /**
257
+ * Result of the action (success, failure, partial)
258
+ */
259
+ result: z.ZodDefault<z.ZodEnum<["success", "failure", "partial"]>>;
260
+ /**
261
+ * Error message (if result is failure)
262
+ */
263
+ errorMessage: z.ZodOptional<z.ZodString>;
264
+ /**
265
+ * Tenant identifier (for multi-tenant systems)
266
+ */
267
+ tenantId: z.ZodOptional<z.ZodString>;
268
+ /**
269
+ * Request/trace ID for correlation
270
+ */
271
+ requestId: z.ZodOptional<z.ZodString>;
272
+ /**
273
+ * Additional context and metadata
274
+ */
275
+ metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
276
+ /**
277
+ * Geographic location (if available)
278
+ */
279
+ location: z.ZodOptional<z.ZodObject<{
280
+ country: z.ZodOptional<z.ZodString>;
281
+ region: z.ZodOptional<z.ZodString>;
282
+ city: z.ZodOptional<z.ZodString>;
283
+ }, "strip", z.ZodTypeAny, {
284
+ city?: string | undefined;
285
+ country?: string | undefined;
286
+ region?: string | undefined;
287
+ }, {
288
+ city?: string | undefined;
289
+ country?: string | undefined;
290
+ region?: string | undefined;
291
+ }>>;
292
+ }, "strip", z.ZodTypeAny, {
293
+ description: string;
294
+ severity: "error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency";
295
+ id: string;
296
+ eventType: "data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked";
297
+ timestamp: string;
298
+ actor: {
299
+ type: "system" | "user" | "service" | "api_client" | "integration";
300
+ id: string;
301
+ email?: string | undefined;
302
+ name?: string | undefined;
303
+ ipAddress?: string | undefined;
304
+ userAgent?: string | undefined;
305
+ };
306
+ result: "partial" | "success" | "failure";
307
+ location?: {
308
+ city?: string | undefined;
309
+ country?: string | undefined;
310
+ region?: string | undefined;
311
+ } | undefined;
312
+ target?: {
313
+ type: string;
314
+ id: string;
315
+ name?: string | undefined;
316
+ metadata?: Record<string, any> | undefined;
317
+ } | undefined;
318
+ metadata?: Record<string, any> | undefined;
319
+ changes?: {
320
+ field: string;
321
+ oldValue?: any;
322
+ newValue?: any;
323
+ }[] | undefined;
324
+ errorMessage?: string | undefined;
325
+ tenantId?: string | undefined;
326
+ requestId?: string | undefined;
327
+ }, {
328
+ description: string;
329
+ id: string;
330
+ eventType: "data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked";
331
+ timestamp: string;
332
+ actor: {
333
+ type: "system" | "user" | "service" | "api_client" | "integration";
334
+ id: string;
335
+ email?: string | undefined;
336
+ name?: string | undefined;
337
+ ipAddress?: string | undefined;
338
+ userAgent?: string | undefined;
339
+ };
340
+ location?: {
341
+ city?: string | undefined;
342
+ country?: string | undefined;
343
+ region?: string | undefined;
344
+ } | undefined;
345
+ severity?: "error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency" | undefined;
346
+ target?: {
347
+ type: string;
348
+ id: string;
349
+ name?: string | undefined;
350
+ metadata?: Record<string, any> | undefined;
351
+ } | undefined;
352
+ metadata?: Record<string, any> | undefined;
353
+ changes?: {
354
+ field: string;
355
+ oldValue?: any;
356
+ newValue?: any;
357
+ }[] | undefined;
358
+ result?: "partial" | "success" | "failure" | undefined;
359
+ errorMessage?: string | undefined;
360
+ tenantId?: string | undefined;
361
+ requestId?: string | undefined;
362
+ }>;
363
+ export type AuditEvent = z.infer<typeof AuditEventSchema>;
364
+ /**
365
+ * Audit Retention Policy Schema
366
+ * Defines how long audit logs are retained
367
+ */
368
+ export declare const AuditRetentionPolicySchema: z.ZodObject<{
369
+ /**
370
+ * Retention period in days
371
+ * Default: 180 days (GDPR 6-month requirement)
372
+ */
373
+ retentionDays: z.ZodDefault<z.ZodNumber>;
374
+ /**
375
+ * Whether to archive logs after retention period
376
+ * If true, logs are moved to cold storage; if false, they are deleted
377
+ */
378
+ archiveAfterRetention: z.ZodDefault<z.ZodBoolean>;
379
+ /**
380
+ * Archive storage configuration
381
+ */
382
+ archiveStorage: z.ZodOptional<z.ZodObject<{
383
+ type: z.ZodEnum<["s3", "gcs", "azure_blob", "filesystem"]>;
384
+ endpoint: z.ZodOptional<z.ZodString>;
385
+ bucket: z.ZodOptional<z.ZodString>;
386
+ path: z.ZodOptional<z.ZodString>;
387
+ credentials: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
388
+ }, "strip", z.ZodTypeAny, {
389
+ type: "s3" | "gcs" | "azure_blob" | "filesystem";
390
+ path?: string | undefined;
391
+ credentials?: Record<string, any> | undefined;
392
+ endpoint?: string | undefined;
393
+ bucket?: string | undefined;
394
+ }, {
395
+ type: "s3" | "gcs" | "azure_blob" | "filesystem";
396
+ path?: string | undefined;
397
+ credentials?: Record<string, any> | undefined;
398
+ endpoint?: string | undefined;
399
+ bucket?: string | undefined;
400
+ }>>;
401
+ /**
402
+ * Event types that have different retention periods
403
+ * Overrides the default retentionDays for specific event types
404
+ */
405
+ customRetention: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNumber>>;
406
+ /**
407
+ * Minimum retention period for compliance
408
+ * Prevents accidental deletion below compliance requirements
409
+ */
410
+ minimumRetentionDays: z.ZodOptional<z.ZodNumber>;
411
+ }, "strip", z.ZodTypeAny, {
412
+ retentionDays: number;
413
+ archiveAfterRetention: boolean;
414
+ archiveStorage?: {
415
+ type: "s3" | "gcs" | "azure_blob" | "filesystem";
416
+ path?: string | undefined;
417
+ credentials?: Record<string, any> | undefined;
418
+ endpoint?: string | undefined;
419
+ bucket?: string | undefined;
420
+ } | undefined;
421
+ customRetention?: Record<string, number> | undefined;
422
+ minimumRetentionDays?: number | undefined;
423
+ }, {
424
+ retentionDays?: number | undefined;
425
+ archiveAfterRetention?: boolean | undefined;
426
+ archiveStorage?: {
427
+ type: "s3" | "gcs" | "azure_blob" | "filesystem";
428
+ path?: string | undefined;
429
+ credentials?: Record<string, any> | undefined;
430
+ endpoint?: string | undefined;
431
+ bucket?: string | undefined;
432
+ } | undefined;
433
+ customRetention?: Record<string, number> | undefined;
434
+ minimumRetentionDays?: number | undefined;
435
+ }>;
436
+ export type AuditRetentionPolicy = z.infer<typeof AuditRetentionPolicySchema>;
437
+ /**
438
+ * Suspicious Activity Rule Schema
439
+ * Defines rules for detecting suspicious activities
440
+ */
441
+ export declare const SuspiciousActivityRuleSchema: z.ZodObject<{
442
+ /**
443
+ * Unique identifier for the rule
444
+ */
445
+ id: z.ZodString;
446
+ /**
447
+ * Rule name
448
+ */
449
+ name: z.ZodString;
450
+ /**
451
+ * Rule description
452
+ */
453
+ description: z.ZodOptional<z.ZodString>;
454
+ /**
455
+ * Whether the rule is enabled
456
+ */
457
+ enabled: z.ZodDefault<z.ZodBoolean>;
458
+ /**
459
+ * Event types to monitor
460
+ */
461
+ eventTypes: z.ZodArray<z.ZodEnum<["data.create", "data.read", "data.update", "data.delete", "data.export", "data.import", "data.bulk_update", "data.bulk_delete", "auth.login", "auth.login_failed", "auth.logout", "auth.session_created", "auth.session_expired", "auth.password_reset", "auth.password_changed", "auth.email_verified", "auth.mfa_enabled", "auth.mfa_disabled", "auth.account_locked", "auth.account_unlocked", "authz.permission_granted", "authz.permission_revoked", "authz.role_assigned", "authz.role_removed", "authz.role_created", "authz.role_updated", "authz.role_deleted", "authz.policy_created", "authz.policy_updated", "authz.policy_deleted", "system.config_changed", "system.plugin_installed", "system.plugin_uninstalled", "system.backup_created", "system.backup_restored", "system.integration_added", "system.integration_removed", "security.access_denied", "security.suspicious_activity", "security.data_breach", "security.api_key_created", "security.api_key_revoked"]>, "many">;
462
+ /**
463
+ * Detection condition
464
+ */
465
+ condition: z.ZodObject<{
466
+ /**
467
+ * Number of events that trigger the rule
468
+ */
469
+ threshold: z.ZodNumber;
470
+ /**
471
+ * Time window in seconds
472
+ */
473
+ windowSeconds: z.ZodNumber;
474
+ /**
475
+ * Grouping criteria (e.g., by actor.id, by ipAddress)
476
+ */
477
+ groupBy: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
478
+ /**
479
+ * Additional filters
480
+ */
481
+ filters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
482
+ }, "strip", z.ZodTypeAny, {
483
+ threshold: number;
484
+ windowSeconds: number;
485
+ filters?: Record<string, any> | undefined;
486
+ groupBy?: string[] | undefined;
487
+ }, {
488
+ threshold: number;
489
+ windowSeconds: number;
490
+ filters?: Record<string, any> | undefined;
491
+ groupBy?: string[] | undefined;
492
+ }>;
493
+ /**
494
+ * Actions to take when rule is triggered
495
+ */
496
+ actions: z.ZodArray<z.ZodEnum<["alert", "lock_account", "block_ip", "require_mfa", "log_critical", "webhook"]>, "many">;
497
+ /**
498
+ * Severity level for triggered alerts
499
+ */
500
+ alertSeverity: z.ZodDefault<z.ZodEnum<["debug", "info", "notice", "warning", "error", "critical", "alert", "emergency"]>>;
501
+ /**
502
+ * Notification configuration
503
+ */
504
+ notifications: z.ZodOptional<z.ZodObject<{
505
+ /**
506
+ * Email addresses to notify
507
+ */
508
+ email: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
509
+ /**
510
+ * Slack webhook URL
511
+ */
512
+ slack: z.ZodOptional<z.ZodString>;
513
+ /**
514
+ * Custom webhook URL
515
+ */
516
+ webhook: z.ZodOptional<z.ZodString>;
517
+ }, "strip", z.ZodTypeAny, {
518
+ email?: string[] | undefined;
519
+ webhook?: string | undefined;
520
+ slack?: string | undefined;
521
+ }, {
522
+ email?: string[] | undefined;
523
+ webhook?: string | undefined;
524
+ slack?: string | undefined;
525
+ }>>;
526
+ }, "strip", z.ZodTypeAny, {
527
+ name: string;
528
+ condition: {
529
+ threshold: number;
530
+ windowSeconds: number;
531
+ filters?: Record<string, any> | undefined;
532
+ groupBy?: string[] | undefined;
533
+ };
534
+ actions: ("alert" | "lock_account" | "block_ip" | "require_mfa" | "log_critical" | "webhook")[];
535
+ id: string;
536
+ enabled: boolean;
537
+ eventTypes: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[];
538
+ alertSeverity: "error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency";
539
+ description?: string | undefined;
540
+ notifications?: {
541
+ email?: string[] | undefined;
542
+ webhook?: string | undefined;
543
+ slack?: string | undefined;
544
+ } | undefined;
545
+ }, {
546
+ name: string;
547
+ condition: {
548
+ threshold: number;
549
+ windowSeconds: number;
550
+ filters?: Record<string, any> | undefined;
551
+ groupBy?: string[] | undefined;
552
+ };
553
+ actions: ("alert" | "lock_account" | "block_ip" | "require_mfa" | "log_critical" | "webhook")[];
554
+ id: string;
555
+ eventTypes: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[];
556
+ description?: string | undefined;
557
+ enabled?: boolean | undefined;
558
+ alertSeverity?: "error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency" | undefined;
559
+ notifications?: {
560
+ email?: string[] | undefined;
561
+ webhook?: string | undefined;
562
+ slack?: string | undefined;
563
+ } | undefined;
564
+ }>;
565
+ export type SuspiciousActivityRule = z.infer<typeof SuspiciousActivityRuleSchema>;
566
+ /**
567
+ * Audit Log Storage Configuration
568
+ * Defines where and how audit logs are stored
569
+ */
570
+ export declare const AuditStorageConfigSchema: z.ZodObject<{
571
+ /**
572
+ * Storage backend type
573
+ */
574
+ type: z.ZodEnum<["database", "elasticsearch", "mongodb", "clickhouse", "s3", "gcs", "azure_blob", "custom"]>;
575
+ /**
576
+ * Connection string or configuration
577
+ */
578
+ connectionString: z.ZodOptional<z.ZodString>;
579
+ /**
580
+ * Storage configuration
581
+ */
582
+ config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
583
+ /**
584
+ * Whether to enable buffering/batching
585
+ */
586
+ bufferEnabled: z.ZodDefault<z.ZodBoolean>;
587
+ /**
588
+ * Buffer size (number of events before flush)
589
+ */
590
+ bufferSize: z.ZodDefault<z.ZodNumber>;
591
+ /**
592
+ * Buffer flush interval in seconds
593
+ */
594
+ flushIntervalSeconds: z.ZodDefault<z.ZodNumber>;
595
+ /**
596
+ * Whether to compress stored data
597
+ */
598
+ compression: z.ZodDefault<z.ZodBoolean>;
599
+ }, "strip", z.ZodTypeAny, {
600
+ type: "custom" | "database" | "s3" | "gcs" | "azure_blob" | "elasticsearch" | "mongodb" | "clickhouse";
601
+ bufferEnabled: boolean;
602
+ bufferSize: number;
603
+ flushIntervalSeconds: number;
604
+ compression: boolean;
605
+ config?: Record<string, any> | undefined;
606
+ connectionString?: string | undefined;
607
+ }, {
608
+ type: "custom" | "database" | "s3" | "gcs" | "azure_blob" | "elasticsearch" | "mongodb" | "clickhouse";
609
+ config?: Record<string, any> | undefined;
610
+ connectionString?: string | undefined;
611
+ bufferEnabled?: boolean | undefined;
612
+ bufferSize?: number | undefined;
613
+ flushIntervalSeconds?: number | undefined;
614
+ compression?: boolean | undefined;
615
+ }>;
616
+ export type AuditStorageConfig = z.infer<typeof AuditStorageConfigSchema>;
617
+ /**
618
+ * Audit Event Filter Schema
619
+ * Defines filters for querying audit events
620
+ */
621
+ export declare const AuditEventFilterSchema: z.ZodObject<{
622
+ /**
623
+ * Filter by event types
624
+ */
625
+ eventTypes: z.ZodOptional<z.ZodArray<z.ZodEnum<["data.create", "data.read", "data.update", "data.delete", "data.export", "data.import", "data.bulk_update", "data.bulk_delete", "auth.login", "auth.login_failed", "auth.logout", "auth.session_created", "auth.session_expired", "auth.password_reset", "auth.password_changed", "auth.email_verified", "auth.mfa_enabled", "auth.mfa_disabled", "auth.account_locked", "auth.account_unlocked", "authz.permission_granted", "authz.permission_revoked", "authz.role_assigned", "authz.role_removed", "authz.role_created", "authz.role_updated", "authz.role_deleted", "authz.policy_created", "authz.policy_updated", "authz.policy_deleted", "system.config_changed", "system.plugin_installed", "system.plugin_uninstalled", "system.backup_created", "system.backup_restored", "system.integration_added", "system.integration_removed", "security.access_denied", "security.suspicious_activity", "security.data_breach", "security.api_key_created", "security.api_key_revoked"]>, "many">>;
626
+ /**
627
+ * Filter by severity levels
628
+ */
629
+ severities: z.ZodOptional<z.ZodArray<z.ZodEnum<["debug", "info", "notice", "warning", "error", "critical", "alert", "emergency"]>, "many">>;
630
+ /**
631
+ * Filter by actor ID
632
+ */
633
+ actorId: z.ZodOptional<z.ZodString>;
634
+ /**
635
+ * Filter by tenant ID
636
+ */
637
+ tenantId: z.ZodOptional<z.ZodString>;
638
+ /**
639
+ * Filter by time range
640
+ */
641
+ timeRange: z.ZodOptional<z.ZodObject<{
642
+ from: z.ZodString;
643
+ to: z.ZodString;
644
+ }, "strip", z.ZodTypeAny, {
645
+ to: string;
646
+ from: string;
647
+ }, {
648
+ to: string;
649
+ from: string;
650
+ }>>;
651
+ /**
652
+ * Filter by result status
653
+ */
654
+ result: z.ZodOptional<z.ZodEnum<["success", "failure", "partial"]>>;
655
+ /**
656
+ * Search query (full-text search)
657
+ */
658
+ searchQuery: z.ZodOptional<z.ZodString>;
659
+ /**
660
+ * Custom filters
661
+ */
662
+ customFilters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
663
+ }, "strip", z.ZodTypeAny, {
664
+ result?: "partial" | "success" | "failure" | undefined;
665
+ tenantId?: string | undefined;
666
+ eventTypes?: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[] | undefined;
667
+ severities?: ("error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency")[] | undefined;
668
+ actorId?: string | undefined;
669
+ timeRange?: {
670
+ to: string;
671
+ from: string;
672
+ } | undefined;
673
+ searchQuery?: string | undefined;
674
+ customFilters?: Record<string, any> | undefined;
675
+ }, {
676
+ result?: "partial" | "success" | "failure" | undefined;
677
+ tenantId?: string | undefined;
678
+ eventTypes?: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[] | undefined;
679
+ severities?: ("error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency")[] | undefined;
680
+ actorId?: string | undefined;
681
+ timeRange?: {
682
+ to: string;
683
+ from: string;
684
+ } | undefined;
685
+ searchQuery?: string | undefined;
686
+ customFilters?: Record<string, any> | undefined;
687
+ }>;
688
+ export type AuditEventFilter = z.infer<typeof AuditEventFilterSchema>;
689
+ /**
690
+ * Complete Audit Configuration Schema
691
+ * Main configuration for the audit system
692
+ */
693
+ export declare const AuditConfigSchema: z.ZodObject<{
694
+ /**
695
+ * Unique identifier for this audit configuration
696
+ * Must be in snake_case following ObjectStack conventions
697
+ * Maximum length: 64 characters
698
+ */
699
+ name: z.ZodString;
700
+ /**
701
+ * Human-readable label
702
+ */
703
+ label: z.ZodString;
704
+ /**
705
+ * Whether audit logging is enabled
706
+ */
707
+ enabled: z.ZodDefault<z.ZodBoolean>;
708
+ /**
709
+ * Event types to audit
710
+ * If not specified, all event types are audited
711
+ */
712
+ eventTypes: z.ZodOptional<z.ZodArray<z.ZodEnum<["data.create", "data.read", "data.update", "data.delete", "data.export", "data.import", "data.bulk_update", "data.bulk_delete", "auth.login", "auth.login_failed", "auth.logout", "auth.session_created", "auth.session_expired", "auth.password_reset", "auth.password_changed", "auth.email_verified", "auth.mfa_enabled", "auth.mfa_disabled", "auth.account_locked", "auth.account_unlocked", "authz.permission_granted", "authz.permission_revoked", "authz.role_assigned", "authz.role_removed", "authz.role_created", "authz.role_updated", "authz.role_deleted", "authz.policy_created", "authz.policy_updated", "authz.policy_deleted", "system.config_changed", "system.plugin_installed", "system.plugin_uninstalled", "system.backup_created", "system.backup_restored", "system.integration_added", "system.integration_removed", "security.access_denied", "security.suspicious_activity", "security.data_breach", "security.api_key_created", "security.api_key_revoked"]>, "many">>;
713
+ /**
714
+ * Event types to exclude from auditing
715
+ */
716
+ excludeEventTypes: z.ZodOptional<z.ZodArray<z.ZodEnum<["data.create", "data.read", "data.update", "data.delete", "data.export", "data.import", "data.bulk_update", "data.bulk_delete", "auth.login", "auth.login_failed", "auth.logout", "auth.session_created", "auth.session_expired", "auth.password_reset", "auth.password_changed", "auth.email_verified", "auth.mfa_enabled", "auth.mfa_disabled", "auth.account_locked", "auth.account_unlocked", "authz.permission_granted", "authz.permission_revoked", "authz.role_assigned", "authz.role_removed", "authz.role_created", "authz.role_updated", "authz.role_deleted", "authz.policy_created", "authz.policy_updated", "authz.policy_deleted", "system.config_changed", "system.plugin_installed", "system.plugin_uninstalled", "system.backup_created", "system.backup_restored", "system.integration_added", "system.integration_removed", "security.access_denied", "security.suspicious_activity", "security.data_breach", "security.api_key_created", "security.api_key_revoked"]>, "many">>;
717
+ /**
718
+ * Minimum severity level to log
719
+ * Events below this level are not logged
720
+ */
721
+ minimumSeverity: z.ZodDefault<z.ZodEnum<["debug", "info", "notice", "warning", "error", "critical", "alert", "emergency"]>>;
722
+ /**
723
+ * Storage configuration
724
+ */
725
+ storage: z.ZodObject<{
726
+ /**
727
+ * Storage backend type
728
+ */
729
+ type: z.ZodEnum<["database", "elasticsearch", "mongodb", "clickhouse", "s3", "gcs", "azure_blob", "custom"]>;
730
+ /**
731
+ * Connection string or configuration
732
+ */
733
+ connectionString: z.ZodOptional<z.ZodString>;
734
+ /**
735
+ * Storage configuration
736
+ */
737
+ config: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
738
+ /**
739
+ * Whether to enable buffering/batching
740
+ */
741
+ bufferEnabled: z.ZodDefault<z.ZodBoolean>;
742
+ /**
743
+ * Buffer size (number of events before flush)
744
+ */
745
+ bufferSize: z.ZodDefault<z.ZodNumber>;
746
+ /**
747
+ * Buffer flush interval in seconds
748
+ */
749
+ flushIntervalSeconds: z.ZodDefault<z.ZodNumber>;
750
+ /**
751
+ * Whether to compress stored data
752
+ */
753
+ compression: z.ZodDefault<z.ZodBoolean>;
754
+ }, "strip", z.ZodTypeAny, {
755
+ type: "custom" | "database" | "s3" | "gcs" | "azure_blob" | "elasticsearch" | "mongodb" | "clickhouse";
756
+ bufferEnabled: boolean;
757
+ bufferSize: number;
758
+ flushIntervalSeconds: number;
759
+ compression: boolean;
760
+ config?: Record<string, any> | undefined;
761
+ connectionString?: string | undefined;
762
+ }, {
763
+ type: "custom" | "database" | "s3" | "gcs" | "azure_blob" | "elasticsearch" | "mongodb" | "clickhouse";
764
+ config?: Record<string, any> | undefined;
765
+ connectionString?: string | undefined;
766
+ bufferEnabled?: boolean | undefined;
767
+ bufferSize?: number | undefined;
768
+ flushIntervalSeconds?: number | undefined;
769
+ compression?: boolean | undefined;
770
+ }>;
771
+ /**
772
+ * Retention policy
773
+ */
774
+ retentionPolicy: z.ZodDefault<z.ZodObject<{
775
+ /**
776
+ * Retention period in days
777
+ * Default: 180 days (GDPR 6-month requirement)
778
+ */
779
+ retentionDays: z.ZodDefault<z.ZodNumber>;
780
+ /**
781
+ * Whether to archive logs after retention period
782
+ * If true, logs are moved to cold storage; if false, they are deleted
783
+ */
784
+ archiveAfterRetention: z.ZodDefault<z.ZodBoolean>;
785
+ /**
786
+ * Archive storage configuration
787
+ */
788
+ archiveStorage: z.ZodOptional<z.ZodObject<{
789
+ type: z.ZodEnum<["s3", "gcs", "azure_blob", "filesystem"]>;
790
+ endpoint: z.ZodOptional<z.ZodString>;
791
+ bucket: z.ZodOptional<z.ZodString>;
792
+ path: z.ZodOptional<z.ZodString>;
793
+ credentials: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
794
+ }, "strip", z.ZodTypeAny, {
795
+ type: "s3" | "gcs" | "azure_blob" | "filesystem";
796
+ path?: string | undefined;
797
+ credentials?: Record<string, any> | undefined;
798
+ endpoint?: string | undefined;
799
+ bucket?: string | undefined;
800
+ }, {
801
+ type: "s3" | "gcs" | "azure_blob" | "filesystem";
802
+ path?: string | undefined;
803
+ credentials?: Record<string, any> | undefined;
804
+ endpoint?: string | undefined;
805
+ bucket?: string | undefined;
806
+ }>>;
807
+ /**
808
+ * Event types that have different retention periods
809
+ * Overrides the default retentionDays for specific event types
810
+ */
811
+ customRetention: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNumber>>;
812
+ /**
813
+ * Minimum retention period for compliance
814
+ * Prevents accidental deletion below compliance requirements
815
+ */
816
+ minimumRetentionDays: z.ZodOptional<z.ZodNumber>;
817
+ }, "strip", z.ZodTypeAny, {
818
+ retentionDays: number;
819
+ archiveAfterRetention: boolean;
820
+ archiveStorage?: {
821
+ type: "s3" | "gcs" | "azure_blob" | "filesystem";
822
+ path?: string | undefined;
823
+ credentials?: Record<string, any> | undefined;
824
+ endpoint?: string | undefined;
825
+ bucket?: string | undefined;
826
+ } | undefined;
827
+ customRetention?: Record<string, number> | undefined;
828
+ minimumRetentionDays?: number | undefined;
829
+ }, {
830
+ retentionDays?: number | undefined;
831
+ archiveAfterRetention?: boolean | undefined;
832
+ archiveStorage?: {
833
+ type: "s3" | "gcs" | "azure_blob" | "filesystem";
834
+ path?: string | undefined;
835
+ credentials?: Record<string, any> | undefined;
836
+ endpoint?: string | undefined;
837
+ bucket?: string | undefined;
838
+ } | undefined;
839
+ customRetention?: Record<string, number> | undefined;
840
+ minimumRetentionDays?: number | undefined;
841
+ }>>;
842
+ /**
843
+ * Suspicious activity detection rules
844
+ */
845
+ suspiciousActivityRules: z.ZodDefault<z.ZodArray<z.ZodObject<{
846
+ /**
847
+ * Unique identifier for the rule
848
+ */
849
+ id: z.ZodString;
850
+ /**
851
+ * Rule name
852
+ */
853
+ name: z.ZodString;
854
+ /**
855
+ * Rule description
856
+ */
857
+ description: z.ZodOptional<z.ZodString>;
858
+ /**
859
+ * Whether the rule is enabled
860
+ */
861
+ enabled: z.ZodDefault<z.ZodBoolean>;
862
+ /**
863
+ * Event types to monitor
864
+ */
865
+ eventTypes: z.ZodArray<z.ZodEnum<["data.create", "data.read", "data.update", "data.delete", "data.export", "data.import", "data.bulk_update", "data.bulk_delete", "auth.login", "auth.login_failed", "auth.logout", "auth.session_created", "auth.session_expired", "auth.password_reset", "auth.password_changed", "auth.email_verified", "auth.mfa_enabled", "auth.mfa_disabled", "auth.account_locked", "auth.account_unlocked", "authz.permission_granted", "authz.permission_revoked", "authz.role_assigned", "authz.role_removed", "authz.role_created", "authz.role_updated", "authz.role_deleted", "authz.policy_created", "authz.policy_updated", "authz.policy_deleted", "system.config_changed", "system.plugin_installed", "system.plugin_uninstalled", "system.backup_created", "system.backup_restored", "system.integration_added", "system.integration_removed", "security.access_denied", "security.suspicious_activity", "security.data_breach", "security.api_key_created", "security.api_key_revoked"]>, "many">;
866
+ /**
867
+ * Detection condition
868
+ */
869
+ condition: z.ZodObject<{
870
+ /**
871
+ * Number of events that trigger the rule
872
+ */
873
+ threshold: z.ZodNumber;
874
+ /**
875
+ * Time window in seconds
876
+ */
877
+ windowSeconds: z.ZodNumber;
878
+ /**
879
+ * Grouping criteria (e.g., by actor.id, by ipAddress)
880
+ */
881
+ groupBy: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
882
+ /**
883
+ * Additional filters
884
+ */
885
+ filters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodAny>>;
886
+ }, "strip", z.ZodTypeAny, {
887
+ threshold: number;
888
+ windowSeconds: number;
889
+ filters?: Record<string, any> | undefined;
890
+ groupBy?: string[] | undefined;
891
+ }, {
892
+ threshold: number;
893
+ windowSeconds: number;
894
+ filters?: Record<string, any> | undefined;
895
+ groupBy?: string[] | undefined;
896
+ }>;
897
+ /**
898
+ * Actions to take when rule is triggered
899
+ */
900
+ actions: z.ZodArray<z.ZodEnum<["alert", "lock_account", "block_ip", "require_mfa", "log_critical", "webhook"]>, "many">;
901
+ /**
902
+ * Severity level for triggered alerts
903
+ */
904
+ alertSeverity: z.ZodDefault<z.ZodEnum<["debug", "info", "notice", "warning", "error", "critical", "alert", "emergency"]>>;
905
+ /**
906
+ * Notification configuration
907
+ */
908
+ notifications: z.ZodOptional<z.ZodObject<{
909
+ /**
910
+ * Email addresses to notify
911
+ */
912
+ email: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
913
+ /**
914
+ * Slack webhook URL
915
+ */
916
+ slack: z.ZodOptional<z.ZodString>;
917
+ /**
918
+ * Custom webhook URL
919
+ */
920
+ webhook: z.ZodOptional<z.ZodString>;
921
+ }, "strip", z.ZodTypeAny, {
922
+ email?: string[] | undefined;
923
+ webhook?: string | undefined;
924
+ slack?: string | undefined;
925
+ }, {
926
+ email?: string[] | undefined;
927
+ webhook?: string | undefined;
928
+ slack?: string | undefined;
929
+ }>>;
930
+ }, "strip", z.ZodTypeAny, {
931
+ name: string;
932
+ condition: {
933
+ threshold: number;
934
+ windowSeconds: number;
935
+ filters?: Record<string, any> | undefined;
936
+ groupBy?: string[] | undefined;
937
+ };
938
+ actions: ("alert" | "lock_account" | "block_ip" | "require_mfa" | "log_critical" | "webhook")[];
939
+ id: string;
940
+ enabled: boolean;
941
+ eventTypes: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[];
942
+ alertSeverity: "error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency";
943
+ description?: string | undefined;
944
+ notifications?: {
945
+ email?: string[] | undefined;
946
+ webhook?: string | undefined;
947
+ slack?: string | undefined;
948
+ } | undefined;
949
+ }, {
950
+ name: string;
951
+ condition: {
952
+ threshold: number;
953
+ windowSeconds: number;
954
+ filters?: Record<string, any> | undefined;
955
+ groupBy?: string[] | undefined;
956
+ };
957
+ actions: ("alert" | "lock_account" | "block_ip" | "require_mfa" | "log_critical" | "webhook")[];
958
+ id: string;
959
+ eventTypes: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[];
960
+ description?: string | undefined;
961
+ enabled?: boolean | undefined;
962
+ alertSeverity?: "error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency" | undefined;
963
+ notifications?: {
964
+ email?: string[] | undefined;
965
+ webhook?: string | undefined;
966
+ slack?: string | undefined;
967
+ } | undefined;
968
+ }>, "many">>;
969
+ /**
970
+ * Whether to include sensitive data in audit logs
971
+ * If false, sensitive fields are redacted/masked
972
+ */
973
+ includeSensitiveData: z.ZodDefault<z.ZodBoolean>;
974
+ /**
975
+ * Fields to redact from audit logs
976
+ */
977
+ redactFields: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
978
+ /**
979
+ * Whether to log successful read operations
980
+ * Can be disabled to reduce log volume
981
+ */
982
+ logReads: z.ZodDefault<z.ZodBoolean>;
983
+ /**
984
+ * Sampling rate for read operations (0.0 to 1.0)
985
+ * Only applies if logReads is true
986
+ */
987
+ readSamplingRate: z.ZodDefault<z.ZodNumber>;
988
+ /**
989
+ * Whether to log system/internal operations
990
+ */
991
+ logSystemEvents: z.ZodDefault<z.ZodBoolean>;
992
+ /**
993
+ * Custom audit event handlers
994
+ * Note: Function handlers are for runtime configuration only and will not be serialized to JSON Schema
995
+ */
996
+ customHandlers: z.ZodOptional<z.ZodArray<z.ZodObject<{
997
+ eventType: z.ZodEnum<["data.create", "data.read", "data.update", "data.delete", "data.export", "data.import", "data.bulk_update", "data.bulk_delete", "auth.login", "auth.login_failed", "auth.logout", "auth.session_created", "auth.session_expired", "auth.password_reset", "auth.password_changed", "auth.email_verified", "auth.mfa_enabled", "auth.mfa_disabled", "auth.account_locked", "auth.account_unlocked", "authz.permission_granted", "authz.permission_revoked", "authz.role_assigned", "authz.role_removed", "authz.role_created", "authz.role_updated", "authz.role_deleted", "authz.policy_created", "authz.policy_updated", "authz.policy_deleted", "system.config_changed", "system.plugin_installed", "system.plugin_uninstalled", "system.backup_created", "system.backup_restored", "system.integration_added", "system.integration_removed", "security.access_denied", "security.suspicious_activity", "security.data_breach", "security.api_key_created", "security.api_key_revoked"]>;
998
+ handlerId: z.ZodString;
999
+ }, "strip", z.ZodTypeAny, {
1000
+ eventType: "data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked";
1001
+ handlerId: string;
1002
+ }, {
1003
+ eventType: "data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked";
1004
+ handlerId: string;
1005
+ }>, "many">>;
1006
+ /**
1007
+ * Compliance mode configuration
1008
+ */
1009
+ compliance: z.ZodOptional<z.ZodObject<{
1010
+ /**
1011
+ * Compliance standards to enforce
1012
+ */
1013
+ standards: z.ZodOptional<z.ZodArray<z.ZodEnum<["sox", "hipaa", "gdpr", "pci_dss", "iso_27001", "fedramp"]>, "many">>;
1014
+ /**
1015
+ * Whether to enforce immutable audit logs
1016
+ */
1017
+ immutableLogs: z.ZodDefault<z.ZodBoolean>;
1018
+ /**
1019
+ * Whether to require cryptographic signing
1020
+ */
1021
+ requireSigning: z.ZodDefault<z.ZodBoolean>;
1022
+ /**
1023
+ * Signing key configuration
1024
+ */
1025
+ signingKey: z.ZodOptional<z.ZodString>;
1026
+ }, "strip", z.ZodTypeAny, {
1027
+ immutableLogs: boolean;
1028
+ requireSigning: boolean;
1029
+ standards?: ("sox" | "hipaa" | "gdpr" | "pci_dss" | "iso_27001" | "fedramp")[] | undefined;
1030
+ signingKey?: string | undefined;
1031
+ }, {
1032
+ standards?: ("sox" | "hipaa" | "gdpr" | "pci_dss" | "iso_27001" | "fedramp")[] | undefined;
1033
+ immutableLogs?: boolean | undefined;
1034
+ requireSigning?: boolean | undefined;
1035
+ signingKey?: string | undefined;
1036
+ }>>;
1037
+ }, "strip", z.ZodTypeAny, {
1038
+ label: string;
1039
+ name: string;
1040
+ enabled: boolean;
1041
+ minimumSeverity: "error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency";
1042
+ storage: {
1043
+ type: "custom" | "database" | "s3" | "gcs" | "azure_blob" | "elasticsearch" | "mongodb" | "clickhouse";
1044
+ bufferEnabled: boolean;
1045
+ bufferSize: number;
1046
+ flushIntervalSeconds: number;
1047
+ compression: boolean;
1048
+ config?: Record<string, any> | undefined;
1049
+ connectionString?: string | undefined;
1050
+ };
1051
+ retentionPolicy: {
1052
+ retentionDays: number;
1053
+ archiveAfterRetention: boolean;
1054
+ archiveStorage?: {
1055
+ type: "s3" | "gcs" | "azure_blob" | "filesystem";
1056
+ path?: string | undefined;
1057
+ credentials?: Record<string, any> | undefined;
1058
+ endpoint?: string | undefined;
1059
+ bucket?: string | undefined;
1060
+ } | undefined;
1061
+ customRetention?: Record<string, number> | undefined;
1062
+ minimumRetentionDays?: number | undefined;
1063
+ };
1064
+ suspiciousActivityRules: {
1065
+ name: string;
1066
+ condition: {
1067
+ threshold: number;
1068
+ windowSeconds: number;
1069
+ filters?: Record<string, any> | undefined;
1070
+ groupBy?: string[] | undefined;
1071
+ };
1072
+ actions: ("alert" | "lock_account" | "block_ip" | "require_mfa" | "log_critical" | "webhook")[];
1073
+ id: string;
1074
+ enabled: boolean;
1075
+ eventTypes: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[];
1076
+ alertSeverity: "error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency";
1077
+ description?: string | undefined;
1078
+ notifications?: {
1079
+ email?: string[] | undefined;
1080
+ webhook?: string | undefined;
1081
+ slack?: string | undefined;
1082
+ } | undefined;
1083
+ }[];
1084
+ includeSensitiveData: boolean;
1085
+ redactFields: string[];
1086
+ logReads: boolean;
1087
+ readSamplingRate: number;
1088
+ logSystemEvents: boolean;
1089
+ compliance?: {
1090
+ immutableLogs: boolean;
1091
+ requireSigning: boolean;
1092
+ standards?: ("sox" | "hipaa" | "gdpr" | "pci_dss" | "iso_27001" | "fedramp")[] | undefined;
1093
+ signingKey?: string | undefined;
1094
+ } | undefined;
1095
+ eventTypes?: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[] | undefined;
1096
+ excludeEventTypes?: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[] | undefined;
1097
+ customHandlers?: {
1098
+ eventType: "data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked";
1099
+ handlerId: string;
1100
+ }[] | undefined;
1101
+ }, {
1102
+ label: string;
1103
+ name: string;
1104
+ storage: {
1105
+ type: "custom" | "database" | "s3" | "gcs" | "azure_blob" | "elasticsearch" | "mongodb" | "clickhouse";
1106
+ config?: Record<string, any> | undefined;
1107
+ connectionString?: string | undefined;
1108
+ bufferEnabled?: boolean | undefined;
1109
+ bufferSize?: number | undefined;
1110
+ flushIntervalSeconds?: number | undefined;
1111
+ compression?: boolean | undefined;
1112
+ };
1113
+ enabled?: boolean | undefined;
1114
+ compliance?: {
1115
+ standards?: ("sox" | "hipaa" | "gdpr" | "pci_dss" | "iso_27001" | "fedramp")[] | undefined;
1116
+ immutableLogs?: boolean | undefined;
1117
+ requireSigning?: boolean | undefined;
1118
+ signingKey?: string | undefined;
1119
+ } | undefined;
1120
+ eventTypes?: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[] | undefined;
1121
+ excludeEventTypes?: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[] | undefined;
1122
+ minimumSeverity?: "error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency" | undefined;
1123
+ retentionPolicy?: {
1124
+ retentionDays?: number | undefined;
1125
+ archiveAfterRetention?: boolean | undefined;
1126
+ archiveStorage?: {
1127
+ type: "s3" | "gcs" | "azure_blob" | "filesystem";
1128
+ path?: string | undefined;
1129
+ credentials?: Record<string, any> | undefined;
1130
+ endpoint?: string | undefined;
1131
+ bucket?: string | undefined;
1132
+ } | undefined;
1133
+ customRetention?: Record<string, number> | undefined;
1134
+ minimumRetentionDays?: number | undefined;
1135
+ } | undefined;
1136
+ suspiciousActivityRules?: {
1137
+ name: string;
1138
+ condition: {
1139
+ threshold: number;
1140
+ windowSeconds: number;
1141
+ filters?: Record<string, any> | undefined;
1142
+ groupBy?: string[] | undefined;
1143
+ };
1144
+ actions: ("alert" | "lock_account" | "block_ip" | "require_mfa" | "log_critical" | "webhook")[];
1145
+ id: string;
1146
+ eventTypes: ("data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked")[];
1147
+ description?: string | undefined;
1148
+ enabled?: boolean | undefined;
1149
+ alertSeverity?: "error" | "warning" | "info" | "debug" | "notice" | "critical" | "alert" | "emergency" | undefined;
1150
+ notifications?: {
1151
+ email?: string[] | undefined;
1152
+ webhook?: string | undefined;
1153
+ slack?: string | undefined;
1154
+ } | undefined;
1155
+ }[] | undefined;
1156
+ includeSensitiveData?: boolean | undefined;
1157
+ redactFields?: string[] | undefined;
1158
+ logReads?: boolean | undefined;
1159
+ readSamplingRate?: number | undefined;
1160
+ logSystemEvents?: boolean | undefined;
1161
+ customHandlers?: {
1162
+ eventType: "data.create" | "data.read" | "data.update" | "data.delete" | "data.export" | "data.import" | "data.bulk_update" | "data.bulk_delete" | "auth.login" | "auth.login_failed" | "auth.logout" | "auth.session_created" | "auth.session_expired" | "auth.password_reset" | "auth.password_changed" | "auth.email_verified" | "auth.mfa_enabled" | "auth.mfa_disabled" | "auth.account_locked" | "auth.account_unlocked" | "authz.permission_granted" | "authz.permission_revoked" | "authz.role_assigned" | "authz.role_removed" | "authz.role_created" | "authz.role_updated" | "authz.role_deleted" | "authz.policy_created" | "authz.policy_updated" | "authz.policy_deleted" | "system.config_changed" | "system.plugin_installed" | "system.plugin_uninstalled" | "system.backup_created" | "system.backup_restored" | "system.integration_added" | "system.integration_removed" | "security.access_denied" | "security.suspicious_activity" | "security.data_breach" | "security.api_key_created" | "security.api_key_revoked";
1163
+ handlerId: string;
1164
+ }[] | undefined;
1165
+ }>;
1166
+ export type AuditConfig = z.infer<typeof AuditConfigSchema>;
1167
+ /**
1168
+ * Default suspicious activity rules
1169
+ * Common security patterns to detect
1170
+ */
1171
+ export declare const DEFAULT_SUSPICIOUS_ACTIVITY_RULES: SuspiciousActivityRule[];
1172
+ //# sourceMappingURL=audit.zod.d.ts.map