@objectstack/spec 0.1.0 → 0.1.2
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.
- package/README.md +134 -121
- package/dist/ai/agent.zod.d.ts +164 -0
- package/dist/ai/agent.zod.d.ts.map +1 -0
- package/dist/ai/agent.zod.js +51 -0
- package/dist/api/contract.zod.d.ts +1733 -0
- package/dist/api/contract.zod.d.ts.map +1 -0
- package/dist/api/contract.zod.js +138 -0
- package/dist/data/dataset.zod.d.ts +60 -0
- package/dist/data/dataset.zod.d.ts.map +1 -0
- package/dist/data/dataset.zod.js +54 -0
- package/dist/data/field.zod.d.ts +1808 -0
- package/dist/data/field.zod.d.ts.map +1 -0
- package/dist/data/field.zod.js +222 -0
- package/dist/data/flow.zod.d.ts +242 -0
- package/dist/data/flow.zod.d.ts.map +1 -0
- package/dist/data/flow.zod.js +77 -0
- package/dist/data/mapping.zod.d.ts +470 -0
- package/dist/data/mapping.zod.d.ts.map +1 -0
- package/dist/data/mapping.zod.js +65 -0
- package/dist/data/object.zod.d.ts +844 -0
- package/dist/data/object.zod.d.ts.map +1 -0
- package/dist/data/object.zod.js +81 -0
- package/dist/data/permission.zod.d.ts +163 -0
- package/dist/data/permission.zod.d.ts.map +1 -0
- package/dist/data/permission.zod.js +62 -0
- package/dist/data/query.zod.d.ts +438 -0
- package/dist/data/query.zod.d.ts.map +1 -0
- package/dist/data/query.zod.js +147 -0
- package/dist/data/sharing.zod.d.ts +63 -0
- package/dist/data/sharing.zod.d.ts.map +1 -0
- package/dist/data/sharing.zod.js +57 -0
- package/dist/data/trigger.zod.d.ts +354 -0
- package/dist/data/trigger.zod.d.ts.map +1 -0
- package/dist/data/trigger.zod.js +195 -0
- package/dist/data/validation.zod.d.ts +276 -0
- package/dist/data/validation.zod.d.ts.map +1 -0
- package/dist/data/validation.zod.js +105 -0
- package/dist/data/workflow.zod.d.ts +195 -0
- package/dist/data/workflow.zod.d.ts.map +1 -0
- package/dist/data/workflow.zod.js +64 -0
- package/dist/index.d.ts +41 -5
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +62 -5
- package/dist/system/api.zod.d.ts +294 -0
- package/dist/system/api.zod.d.ts.map +1 -0
- package/dist/system/api.zod.js +56 -0
- package/dist/system/constants/index.d.ts +11 -0
- package/dist/system/constants/index.d.ts.map +1 -0
- package/dist/system/constants/index.js +26 -0
- package/dist/system/constants/paths.d.ts +71 -0
- package/dist/system/constants/paths.d.ts.map +1 -0
- package/dist/system/constants/paths.js +65 -0
- package/dist/system/datasource.zod.d.ts +210 -0
- package/dist/system/datasource.zod.d.ts.map +1 -0
- package/dist/system/datasource.zod.js +90 -0
- package/dist/system/discovery.zod.d.ts +174 -0
- package/dist/system/discovery.zod.d.ts.map +1 -0
- package/dist/system/discovery.zod.js +53 -0
- package/dist/system/driver.zod.d.ts +1525 -0
- package/dist/system/driver.zod.d.ts.map +1 -0
- package/dist/system/driver.zod.js +290 -0
- package/dist/system/identity.zod.d.ts +204 -0
- package/dist/system/identity.zod.d.ts.map +1 -0
- package/dist/system/identity.zod.js +68 -0
- package/dist/system/license.zod.d.ts +110 -0
- package/dist/system/license.zod.d.ts.map +1 -0
- package/dist/system/license.zod.js +63 -0
- package/dist/system/manifest.zod.d.ts +397 -0
- package/dist/system/manifest.zod.d.ts.map +1 -0
- package/dist/system/manifest.zod.js +142 -0
- package/dist/system/plugin.zod.d.ts +3516 -0
- package/dist/system/plugin.zod.d.ts.map +1 -0
- package/dist/system/plugin.zod.js +226 -0
- package/dist/system/policy.zod.d.ts +209 -0
- package/dist/system/policy.zod.d.ts.map +1 -0
- package/dist/system/policy.zod.js +54 -0
- package/dist/system/role.zod.d.ts +34 -0
- package/dist/system/role.zod.d.ts.map +1 -0
- package/dist/system/role.zod.js +25 -0
- package/dist/system/territory.zod.d.ts +91 -0
- package/dist/system/territory.zod.d.ts.map +1 -0
- package/dist/system/territory.zod.js +64 -0
- package/dist/system/translation.zod.d.ts +171 -0
- package/dist/system/translation.zod.d.ts.map +1 -0
- package/dist/system/translation.zod.js +34 -0
- package/dist/system/types/index.d.ts +7 -0
- package/dist/system/types/index.d.ts.map +1 -0
- package/dist/system/types/index.js +22 -0
- package/dist/system/types/plugin.d.ts +113 -0
- package/dist/system/types/plugin.d.ts.map +1 -0
- package/dist/system/types/plugin.js +6 -0
- package/dist/system/webhook.zod.d.ts +106 -0
- package/dist/system/webhook.zod.d.ts.map +1 -0
- package/dist/system/webhook.zod.js +56 -0
- package/dist/ui/action.zod.d.ts +155 -0
- package/dist/ui/action.zod.d.ts.map +1 -0
- package/dist/ui/action.zod.js +54 -0
- package/dist/ui/app.zod.d.ts +405 -0
- package/dist/ui/app.zod.d.ts.map +1 -0
- package/dist/ui/app.zod.js +138 -0
- package/dist/ui/dashboard.zod.d.ts +213 -0
- package/dist/ui/dashboard.zod.d.ts.map +1 -0
- package/dist/ui/dashboard.zod.js +72 -0
- package/dist/ui/page.zod.d.ts +187 -0
- package/dist/ui/page.zod.d.ts.map +1 -0
- package/dist/ui/page.zod.js +48 -0
- package/dist/ui/report.zod.d.ts +233 -0
- package/dist/ui/report.zod.d.ts.map +1 -0
- package/dist/ui/report.zod.js +74 -0
- package/dist/ui/theme.zod.d.ts +1221 -0
- package/dist/ui/theme.zod.d.ts.map +1 -0
- package/dist/ui/theme.zod.js +202 -0
- package/dist/ui/view.zod.d.ts +887 -0
- package/dist/ui/view.zod.d.ts.map +1 -0
- package/dist/ui/view.zod.js +83 -0
- package/dist/ui/widget.zod.d.ts +350 -0
- package/dist/ui/widget.zod.d.ts.map +1 -0
- package/dist/ui/widget.zod.js +66 -0
- package/json-schema/AIKnowledge.json +30 -0
- package/json-schema/AIModelConfig.json +41 -0
- package/json-schema/AITool.json +33 -0
- package/json-schema/Action.json +162 -0
- package/json-schema/ActionParam.json +82 -0
- package/json-schema/Address.json +40 -0
- package/json-schema/Agent.json +140 -0
- package/json-schema/AggregationFunction.json +19 -0
- package/json-schema/AggregationNode.json +42 -0
- package/json-schema/Animation.json +56 -0
- package/json-schema/ApiCapabilities.json +28 -0
- package/json-schema/ApiEndpoint.json +162 -0
- package/json-schema/ApiError.json +27 -0
- package/json-schema/ApiMapping.json +28 -0
- package/json-schema/ApiRoutes.json +41 -0
- package/json-schema/App.json +297 -0
- package/json-schema/AppBranding.json +24 -0
- package/json-schema/AsyncValidation.json +70 -0
- package/json-schema/AuditPolicy.json +31 -0
- package/json-schema/AuthProtocol.json +17 -0
- package/json-schema/AuthProvider.json +171 -0
- package/json-schema/BaseResponse.json +63 -0
- package/json-schema/BorderRadius.json +44 -0
- package/json-schema/Breakpoints.json +36 -0
- package/json-schema/BulkRequest.json +29 -0
- package/json-schema/BulkResponse.json +108 -0
- package/json-schema/CalendarConfig.json +28 -0
- package/json-schema/ChartType.json +19 -0
- package/json-schema/ColorPalette.json +83 -0
- package/json-schema/ConditionalValidation.json +793 -0
- package/json-schema/CreateRequest.json +20 -0
- package/json-schema/CrossFieldValidation.json +56 -0
- package/json-schema/CustomValidator.json +57 -0
- package/json-schema/Dashboard.json +117 -0
- package/json-schema/DashboardNavItem.json +42 -0
- package/json-schema/DashboardWidget.json +89 -0
- package/json-schema/Dataset.json +63 -0
- package/json-schema/DatasetMode.json +16 -0
- package/json-schema/Datasource.json +75 -0
- package/json-schema/DatasourceCapabilities.json +36 -0
- package/json-schema/DeleteResponse.json +68 -0
- package/json-schema/Discovery.json +114 -0
- package/json-schema/DriverCapabilities.json +39 -0
- package/json-schema/DriverDefinition.json +66 -0
- package/json-schema/DriverInterface.json +58 -0
- package/json-schema/DriverOptions.json +23 -0
- package/json-schema/DriverType.json +10 -0
- package/json-schema/EmailAlertAction.json +37 -0
- package/json-schema/ExportRequest.json +786 -0
- package/json-schema/Feature.json +51 -0
- package/json-schema/Field.json +290 -0
- package/json-schema/FieldMapping.json +83 -0
- package/json-schema/FieldNode.json +32 -0
- package/json-schema/FieldPermission.json +22 -0
- package/json-schema/FieldType.json +42 -0
- package/json-schema/FieldUpdateAction.json +32 -0
- package/json-schema/FieldWidgetProps.json +327 -0
- package/json-schema/FilterNode.json +52 -0
- package/json-schema/FilterOperator.json +26 -0
- package/json-schema/Flow.json +186 -0
- package/json-schema/FlowEdge.json +37 -0
- package/json-schema/FlowNode.json +65 -0
- package/json-schema/FlowNodeAction.json +24 -0
- package/json-schema/FlowVariable.json +34 -0
- package/json-schema/FormSection.json +42 -0
- package/json-schema/FormView.json +99 -0
- package/json-schema/FormatValidation.json +59 -0
- package/json-schema/GanttConfig.json +32 -0
- package/json-schema/GroupNavItem.json +42 -0
- package/json-schema/HttpMethod.json +16 -0
- package/json-schema/I18nContext.json +12 -0
- package/json-schema/Index.json +30 -0
- package/json-schema/JoinNode.json +455 -0
- package/json-schema/JoinType.json +15 -0
- package/json-schema/KanbanConfig.json +31 -0
- package/json-schema/LDAPConfig.json +39 -0
- package/json-schema/License.json +57 -0
- package/json-schema/ListRecordResponse.json +103 -0
- package/json-schema/ListView.json +153 -0
- package/json-schema/Locale.json +10 -0
- package/json-schema/LocationCoordinates.json +36 -0
- package/json-schema/Logger.json +25 -0
- package/json-schema/LogicOperator.json +14 -0
- package/json-schema/Manifest.json +315 -0
- package/json-schema/Mapping.json +598 -0
- package/json-schema/MenuItem.json +28 -0
- package/json-schema/MetricType.json +14 -0
- package/json-schema/ModificationResult.json +46 -0
- package/json-schema/NavigationItem.json +214 -0
- package/json-schema/NetworkPolicy.json +31 -0
- package/json-schema/OIDCConfig.json +46 -0
- package/json-schema/OWDModel.json +14 -0
- package/json-schema/Object.json +428 -0
- package/json-schema/ObjectCapabilities.json +62 -0
- package/json-schema/ObjectNavItem.json +46 -0
- package/json-schema/ObjectPermission.json +42 -0
- package/json-schema/ObjectQLClient.json +12 -0
- package/json-schema/Page.json +117 -0
- package/json-schema/PageComponent.json +36 -0
- package/json-schema/PageNavItem.json +47 -0
- package/json-schema/PageRegion.json +63 -0
- package/json-schema/PasswordPolicy.json +41 -0
- package/json-schema/PermissionSet.json +96 -0
- package/json-schema/Plan.json +53 -0
- package/json-schema/Plugin.json +20 -0
- package/json-schema/PluginContext.json +91 -0
- package/json-schema/PluginLifecycle.json +11 -0
- package/json-schema/Policy.json +138 -0
- package/json-schema/Query.json +456 -0
- package/json-schema/RateLimit.json +26 -0
- package/json-schema/RecordData.json +11 -0
- package/json-schema/Report.json +219 -0
- package/json-schema/ReportChart.json +45 -0
- package/json-schema/ReportColumn.json +35 -0
- package/json-schema/ReportGrouping.json +38 -0
- package/json-schema/ReportType.json +15 -0
- package/json-schema/Role.json +32 -0
- package/json-schema/Router.json +12 -0
- package/json-schema/SAMLConfig.json +44 -0
- package/json-schema/Scheduler.json +12 -0
- package/json-schema/ScopedStorage.json +12 -0
- package/json-schema/ScriptValidation.json +48 -0
- package/json-schema/SelectOption.json +32 -0
- package/json-schema/SessionPolicy.json +27 -0
- package/json-schema/Shadow.json +44 -0
- package/json-schema/SharingLevel.json +13 -0
- package/json-schema/SharingRule.json +58 -0
- package/json-schema/SharingRuleType.json +15 -0
- package/json-schema/SingleRecordResponse.json +69 -0
- package/json-schema/SortNode.json +26 -0
- package/json-schema/Spacing.json +64 -0
- package/json-schema/StateMachineValidation.json +59 -0
- package/json-schema/SystemAPI.json +12 -0
- package/json-schema/Territory.json +77 -0
- package/json-schema/TerritoryModel.json +34 -0
- package/json-schema/TerritoryType.json +15 -0
- package/json-schema/Theme.json +543 -0
- package/json-schema/ThemeMode.json +14 -0
- package/json-schema/TransformType.json +18 -0
- package/json-schema/TranslationBundle.json +78 -0
- package/json-schema/TranslationData.json +75 -0
- package/json-schema/Trigger.json +73 -0
- package/json-schema/TriggerAction.json +14 -0
- package/json-schema/TriggerContext.json +61 -0
- package/json-schema/TriggerTiming.json +13 -0
- package/json-schema/Typography.json +142 -0
- package/json-schema/UniquenessValidation.json +59 -0
- package/json-schema/UpdateRequest.json +20 -0
- package/json-schema/UrlNavItem.json +51 -0
- package/json-schema/ValidationRule.json +794 -0
- package/json-schema/View.json +500 -0
- package/json-schema/Webhook.json +88 -0
- package/json-schema/WebhookReceiver.json +66 -0
- package/json-schema/WebhookTriggerType.json +16 -0
- package/json-schema/WindowFunction.json +24 -0
- package/json-schema/WindowFunctionNode.json +104 -0
- package/json-schema/WindowSpec.json +65 -0
- package/json-schema/WorkflowAction.json +84 -0
- package/json-schema/WorkflowRule.json +128 -0
- package/json-schema/WorkflowTriggerType.json +16 -0
- package/json-schema/ZIndex.json +44 -0
- package/package.json +34 -20
- package/dist/examples.d.ts +0 -28
- package/dist/examples.d.ts.map +0 -1
- package/dist/examples.js +0 -250
- package/dist/types/index.d.ts +0 -9
- package/dist/types/index.d.ts.map +0 -1
- package/dist/types/index.js +0 -8
- package/dist/types/meta/field-type.d.ts +0 -54
- package/dist/types/meta/field-type.d.ts.map +0 -1
- package/dist/types/meta/field-type.js +0 -42
- package/dist/types/meta/index.d.ts +0 -13
- package/dist/types/meta/index.d.ts.map +0 -1
- package/dist/types/meta/index.js +0 -12
- package/dist/types/meta/object-entity.d.ts +0 -246
- package/dist/types/meta/object-entity.d.ts.map +0 -1
- package/dist/types/meta/object-entity.js +0 -9
- package/dist/types/meta/object-field.d.ts +0 -199
- package/dist/types/meta/object-field.d.ts.map +0 -1
- package/dist/types/meta/object-field.js +0 -9
- package/dist/types/meta/object-view.d.ts +0 -430
- package/dist/types/meta/object-view.d.ts.map +0 -1
- package/dist/types/meta/object-view.js +0 -9
- package/src/examples.ts +0 -257
- package/src/index.ts +0 -10
- package/src/types/index.ts +0 -9
- package/src/types/meta/field-type.ts +0 -91
- package/src/types/meta/index.ts +0 -13
- package/src/types/meta/object-entity.ts +0 -265
- package/src/types/meta/object-field.ts +0 -218
- package/src/types/meta/object-view.ts +0 -475
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"plugin.zod.d.ts","sourceRoot":"","sources":["../../src/system/plugin.zod.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;GAEG;AACH,eAAO,MAAM,YAAY;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G;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAwGH;;;OAGG;;IAGH;;;OAGG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAEH,CAAC;AAEH;;GAEG;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AACpE,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AACzE,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC"}
|
|
@@ -0,0 +1,226 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PluginSchema = exports.PluginLifecycleSchema = exports.PluginContextSchema = exports.I18nContextSchema = exports.ScopedStorageSchema = exports.SystemAPISchema = exports.SchedulerSchema = exports.RouterSchema = exports.ObjectQLClientSchema = exports.LoggerSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
/**
|
|
6
|
+
* Interface schemas for Context Capabilities
|
|
7
|
+
*/
|
|
8
|
+
exports.LoggerSchema = zod_1.z.object({
|
|
9
|
+
debug: zod_1.z.any().describe('(message: string, ...meta: any[]) => void'),
|
|
10
|
+
info: zod_1.z.any().describe('(message: string, ...meta: any[]) => void'),
|
|
11
|
+
warn: zod_1.z.any().describe('(message: string, ...meta: any[]) => void'),
|
|
12
|
+
error: zod_1.z.any().describe('(message: string, ...meta: any[]) => void'),
|
|
13
|
+
}).describe('Structured Logger');
|
|
14
|
+
exports.ObjectQLClientSchema = zod_1.z.object({
|
|
15
|
+
object: zod_1.z.function().args(zod_1.z.string()).returns(zod_1.z.any()).describe('Get query interface for an object'),
|
|
16
|
+
query: zod_1.z.function().args(zod_1.z.string()).returns(zod_1.z.promise(zod_1.z.any())).describe('Execute arbitrary SOQL-like query'),
|
|
17
|
+
}).describe('ObjectQL Data Access Client');
|
|
18
|
+
exports.RouterSchema = zod_1.z.object({
|
|
19
|
+
get: zod_1.z.function().args(zod_1.z.string(), zod_1.z.function()).describe('Register GET route'),
|
|
20
|
+
post: zod_1.z.function().args(zod_1.z.string(), zod_1.z.function()).describe('Register POST route'),
|
|
21
|
+
use: zod_1.z.function().args(zod_1.z.string().optional(), zod_1.z.function()).describe('Register Middleware'),
|
|
22
|
+
}).describe('HTTP Router Interface');
|
|
23
|
+
exports.SchedulerSchema = zod_1.z.object({
|
|
24
|
+
schedule: zod_1.z.function().args(zod_1.z.string(), zod_1.z.string(), zod_1.z.function()).describe('Schedule a cron job'),
|
|
25
|
+
}).describe('Job Scheduler Interface');
|
|
26
|
+
exports.SystemAPISchema = zod_1.z.object({
|
|
27
|
+
getCurrentUser: zod_1.z.function().returns(zod_1.z.promise(zod_1.z.any())),
|
|
28
|
+
getConfig: zod_1.z.function().args(zod_1.z.string()).returns(zod_1.z.promise(zod_1.z.any())),
|
|
29
|
+
}).describe('Access to System Core');
|
|
30
|
+
exports.ScopedStorageSchema = zod_1.z.object({
|
|
31
|
+
get: zod_1.z.function().args(zod_1.z.string()).returns(zod_1.z.promise(zod_1.z.any())).describe('Get value by key'),
|
|
32
|
+
set: zod_1.z.function().args(zod_1.z.string(), zod_1.z.any()).returns(zod_1.z.promise(zod_1.z.void())).describe('Set value for key'),
|
|
33
|
+
delete: zod_1.z.function().args(zod_1.z.string()).returns(zod_1.z.promise(zod_1.z.void())).describe('Delete key'),
|
|
34
|
+
}).describe('Plugin Scoped Data Storage (KV)');
|
|
35
|
+
exports.I18nContextSchema = zod_1.z.object({
|
|
36
|
+
t: zod_1.z.function().args(zod_1.z.string(), zod_1.z.record(zod_1.z.any()).optional()).returns(zod_1.z.string()).describe('Translate a key'),
|
|
37
|
+
getLocale: zod_1.z.function().returns(zod_1.z.string()).describe('Get current context locale'),
|
|
38
|
+
}).describe('Internationalization Helper');
|
|
39
|
+
/**
|
|
40
|
+
* Plugin Context Schema
|
|
41
|
+
*
|
|
42
|
+
* This defines the runtime context available to plugins during their lifecycle.
|
|
43
|
+
* The context provides access to core ObjectStack APIs and services.
|
|
44
|
+
*
|
|
45
|
+
* @example
|
|
46
|
+
* export default {
|
|
47
|
+
* onEnable: async (context: PluginContext) => {
|
|
48
|
+
* const { ql, os, logger } = context;
|
|
49
|
+
* logger.info('Plugin enabled');
|
|
50
|
+
* await ql.object('custom_object').find({});
|
|
51
|
+
* }
|
|
52
|
+
* };
|
|
53
|
+
*/
|
|
54
|
+
exports.PluginContextSchema = zod_1.z.object({
|
|
55
|
+
/**
|
|
56
|
+
* ObjectQL data access API.
|
|
57
|
+
* Provides methods to query and manipulate business objects.
|
|
58
|
+
*
|
|
59
|
+
* @example
|
|
60
|
+
* await context.ql.object('account').find({ status: 'active' });
|
|
61
|
+
* await context.ql.object('contact').create({ name: 'John Doe' });
|
|
62
|
+
*/
|
|
63
|
+
ql: exports.ObjectQLClientSchema,
|
|
64
|
+
/**
|
|
65
|
+
* ObjectOS system API.
|
|
66
|
+
* Provides access to system-level functionality and configuration.
|
|
67
|
+
*
|
|
68
|
+
* @example
|
|
69
|
+
* const user = await context.os.getCurrentUser();
|
|
70
|
+
* const config = await context.os.getConfig('plugin.settings');
|
|
71
|
+
*/
|
|
72
|
+
os: exports.SystemAPISchema,
|
|
73
|
+
/**
|
|
74
|
+
* Logging interface.
|
|
75
|
+
* Provides structured logging capabilities with different levels.
|
|
76
|
+
*
|
|
77
|
+
* @example
|
|
78
|
+
* context.logger.info('Operation completed');
|
|
79
|
+
* context.logger.error('Operation failed', { error });
|
|
80
|
+
*/
|
|
81
|
+
logger: exports.LoggerSchema,
|
|
82
|
+
/**
|
|
83
|
+
* Scoped Storage.
|
|
84
|
+
* Key-Value store isolated for this plugin.
|
|
85
|
+
*
|
|
86
|
+
* @example
|
|
87
|
+
* await context.storage.set('last_sync', Date.now());
|
|
88
|
+
*/
|
|
89
|
+
storage: exports.ScopedStorageSchema,
|
|
90
|
+
/**
|
|
91
|
+
* I18n Helper.
|
|
92
|
+
*
|
|
93
|
+
* @example
|
|
94
|
+
* const msg = context.i18n.t('error.invalid_input');
|
|
95
|
+
*/
|
|
96
|
+
i18n: exports.I18nContextSchema,
|
|
97
|
+
/**
|
|
98
|
+
* Metadata registry.
|
|
99
|
+
* Provides access to system metadata like object schemas, field definitions, etc.
|
|
100
|
+
*
|
|
101
|
+
* @example
|
|
102
|
+
* const schema = await context.metadata.getObject('account');
|
|
103
|
+
* const fields = await context.metadata.getFields('account');
|
|
104
|
+
*/
|
|
105
|
+
metadata: zod_1.z.any().describe('Metadata registry'),
|
|
106
|
+
/**
|
|
107
|
+
* Event bus.
|
|
108
|
+
* Provides pub/sub capabilities for system and custom events.
|
|
109
|
+
*
|
|
110
|
+
* @example
|
|
111
|
+
* context.events.on('record.created', handler);
|
|
112
|
+
* context.events.emit('custom.event', data);
|
|
113
|
+
*/
|
|
114
|
+
events: zod_1.z.any().describe('Event bus'),
|
|
115
|
+
/**
|
|
116
|
+
* Application Runtime Capabilities.
|
|
117
|
+
* Provides mechanisms to extend the running application (Routes, Jobs, etc).
|
|
118
|
+
*/
|
|
119
|
+
app: zod_1.z.object({
|
|
120
|
+
router: exports.RouterSchema,
|
|
121
|
+
scheduler: exports.SchedulerSchema.optional(),
|
|
122
|
+
}).describe('App Runtime Capabilities'),
|
|
123
|
+
});
|
|
124
|
+
/**
|
|
125
|
+
* Plugin Lifecycle Schema
|
|
126
|
+
*
|
|
127
|
+
* This defines the lifecycle hooks available to plugins.
|
|
128
|
+
* Plugins can implement any or all of these hooks to respond to lifecycle events.
|
|
129
|
+
*
|
|
130
|
+
* All hooks receive PluginContext as their first parameter.
|
|
131
|
+
* All hooks are optional and asynchronous.
|
|
132
|
+
*
|
|
133
|
+
* @example
|
|
134
|
+
* export default {
|
|
135
|
+
* onInstall: async (context) => {
|
|
136
|
+
* // Initialize database tables
|
|
137
|
+
* await context.ql.object('plugin_data').syncSchema();
|
|
138
|
+
* },
|
|
139
|
+
*
|
|
140
|
+
* onEnable: async (context) => {
|
|
141
|
+
* // Start background services
|
|
142
|
+
* await startScheduler(context);
|
|
143
|
+
* },
|
|
144
|
+
*
|
|
145
|
+
* onDisable: async (context) => {
|
|
146
|
+
* // Stop background services
|
|
147
|
+
* await stopScheduler();
|
|
148
|
+
* }
|
|
149
|
+
* };
|
|
150
|
+
*/
|
|
151
|
+
exports.PluginLifecycleSchema = zod_1.z.object({
|
|
152
|
+
/**
|
|
153
|
+
* Called when the plugin is first installed.
|
|
154
|
+
* Use this to set up initial data, create database tables, or register resources.
|
|
155
|
+
*
|
|
156
|
+
* @param context - Plugin runtime context
|
|
157
|
+
*/
|
|
158
|
+
onInstall: zod_1.z.function()
|
|
159
|
+
.args(exports.PluginContextSchema)
|
|
160
|
+
.returns(zod_1.z.promise(zod_1.z.void()))
|
|
161
|
+
.optional()
|
|
162
|
+
.describe('Hook called on plugin installation'),
|
|
163
|
+
/**
|
|
164
|
+
* Called when the plugin is enabled.
|
|
165
|
+
* Use this to start services, register event handlers, or initialize runtime state.
|
|
166
|
+
*
|
|
167
|
+
* @param context - Plugin runtime context
|
|
168
|
+
*/
|
|
169
|
+
onEnable: zod_1.z.function()
|
|
170
|
+
.args(exports.PluginContextSchema)
|
|
171
|
+
.returns(zod_1.z.promise(zod_1.z.void()))
|
|
172
|
+
.optional()
|
|
173
|
+
.describe('Hook called when plugin is enabled'),
|
|
174
|
+
/**
|
|
175
|
+
* Called when the plugin is disabled.
|
|
176
|
+
* Use this to stop services, unregister handlers, or clean up runtime state.
|
|
177
|
+
*
|
|
178
|
+
* @param context - Plugin runtime context
|
|
179
|
+
*/
|
|
180
|
+
onDisable: zod_1.z.function()
|
|
181
|
+
.args(exports.PluginContextSchema)
|
|
182
|
+
.returns(zod_1.z.promise(zod_1.z.void()))
|
|
183
|
+
.optional()
|
|
184
|
+
.describe('Hook called when plugin is disabled'),
|
|
185
|
+
/**
|
|
186
|
+
* Called when the plugin is uninstalled.
|
|
187
|
+
* Use this to clean up data, remove database tables, or unregister resources.
|
|
188
|
+
*
|
|
189
|
+
* @param context - Plugin runtime context
|
|
190
|
+
*/
|
|
191
|
+
onUninstall: zod_1.z.function()
|
|
192
|
+
.args(exports.PluginContextSchema)
|
|
193
|
+
.returns(zod_1.z.promise(zod_1.z.void()))
|
|
194
|
+
.optional()
|
|
195
|
+
.describe('Hook called on plugin uninstallation'),
|
|
196
|
+
/**
|
|
197
|
+
* Called when the plugin is upgraded to a new version.
|
|
198
|
+
* Use this to migrate data, update schemas, or handle breaking changes.
|
|
199
|
+
*
|
|
200
|
+
* @param context - Plugin runtime context
|
|
201
|
+
* @param fromVersion - Previous version string
|
|
202
|
+
* @param toVersion - New version string
|
|
203
|
+
*/
|
|
204
|
+
onUpgrade: zod_1.z.function()
|
|
205
|
+
.args(exports.PluginContextSchema, zod_1.z.string(), zod_1.z.string())
|
|
206
|
+
.returns(zod_1.z.promise(zod_1.z.void()))
|
|
207
|
+
.optional()
|
|
208
|
+
.describe('Hook called on plugin upgrade'),
|
|
209
|
+
});
|
|
210
|
+
/**
|
|
211
|
+
* Complete Plugin Definition Schema
|
|
212
|
+
*
|
|
213
|
+
* Combines lifecycle hooks with plugin metadata.
|
|
214
|
+
*/
|
|
215
|
+
exports.PluginSchema = exports.PluginLifecycleSchema.extend({
|
|
216
|
+
/**
|
|
217
|
+
* Plugin metadata identifier.
|
|
218
|
+
* Should match the id in the manifest.
|
|
219
|
+
*/
|
|
220
|
+
id: zod_1.z.string().optional().describe('Plugin identifier'),
|
|
221
|
+
/**
|
|
222
|
+
* Plugin version.
|
|
223
|
+
* Should match the version in the manifest.
|
|
224
|
+
*/
|
|
225
|
+
version: zod_1.z.string().optional().describe('Plugin version'),
|
|
226
|
+
});
|
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* Password Complexity Policy
|
|
4
|
+
*/
|
|
5
|
+
export declare const PasswordPolicySchema: z.ZodObject<{
|
|
6
|
+
minLength: z.ZodDefault<z.ZodNumber>;
|
|
7
|
+
requireUppercase: z.ZodDefault<z.ZodBoolean>;
|
|
8
|
+
requireLowercase: z.ZodDefault<z.ZodBoolean>;
|
|
9
|
+
requireNumbers: z.ZodDefault<z.ZodBoolean>;
|
|
10
|
+
requireSymbols: z.ZodDefault<z.ZodBoolean>;
|
|
11
|
+
expirationDays: z.ZodOptional<z.ZodNumber>;
|
|
12
|
+
historyCount: z.ZodDefault<z.ZodNumber>;
|
|
13
|
+
}, "strip", z.ZodTypeAny, {
|
|
14
|
+
minLength: number;
|
|
15
|
+
requireUppercase: boolean;
|
|
16
|
+
requireLowercase: boolean;
|
|
17
|
+
requireNumbers: boolean;
|
|
18
|
+
requireSymbols: boolean;
|
|
19
|
+
historyCount: number;
|
|
20
|
+
expirationDays?: number | undefined;
|
|
21
|
+
}, {
|
|
22
|
+
minLength?: number | undefined;
|
|
23
|
+
requireUppercase?: boolean | undefined;
|
|
24
|
+
requireLowercase?: boolean | undefined;
|
|
25
|
+
requireNumbers?: boolean | undefined;
|
|
26
|
+
requireSymbols?: boolean | undefined;
|
|
27
|
+
expirationDays?: number | undefined;
|
|
28
|
+
historyCount?: number | undefined;
|
|
29
|
+
}>;
|
|
30
|
+
/**
|
|
31
|
+
* Network Access Policy (IP Whitelisting)
|
|
32
|
+
*/
|
|
33
|
+
export declare const NetworkPolicySchema: z.ZodObject<{
|
|
34
|
+
trustedRanges: z.ZodArray<z.ZodString, "many">;
|
|
35
|
+
blockUnknown: z.ZodDefault<z.ZodBoolean>;
|
|
36
|
+
vpnRequired: z.ZodDefault<z.ZodBoolean>;
|
|
37
|
+
}, "strip", z.ZodTypeAny, {
|
|
38
|
+
trustedRanges: string[];
|
|
39
|
+
blockUnknown: boolean;
|
|
40
|
+
vpnRequired: boolean;
|
|
41
|
+
}, {
|
|
42
|
+
trustedRanges: string[];
|
|
43
|
+
blockUnknown?: boolean | undefined;
|
|
44
|
+
vpnRequired?: boolean | undefined;
|
|
45
|
+
}>;
|
|
46
|
+
/**
|
|
47
|
+
* Session Policy
|
|
48
|
+
*/
|
|
49
|
+
export declare const SessionPolicySchema: z.ZodObject<{
|
|
50
|
+
idleTimeout: z.ZodDefault<z.ZodNumber>;
|
|
51
|
+
absoluteTimeout: z.ZodDefault<z.ZodNumber>;
|
|
52
|
+
forceMfa: z.ZodDefault<z.ZodBoolean>;
|
|
53
|
+
}, "strip", z.ZodTypeAny, {
|
|
54
|
+
idleTimeout: number;
|
|
55
|
+
absoluteTimeout: number;
|
|
56
|
+
forceMfa: boolean;
|
|
57
|
+
}, {
|
|
58
|
+
idleTimeout?: number | undefined;
|
|
59
|
+
absoluteTimeout?: number | undefined;
|
|
60
|
+
forceMfa?: boolean | undefined;
|
|
61
|
+
}>;
|
|
62
|
+
/**
|
|
63
|
+
* Audit Retention Policy
|
|
64
|
+
*/
|
|
65
|
+
export declare const AuditPolicySchema: z.ZodObject<{
|
|
66
|
+
logRetentionDays: z.ZodDefault<z.ZodNumber>;
|
|
67
|
+
sensitiveFields: z.ZodArray<z.ZodString, "many">;
|
|
68
|
+
captureRead: z.ZodDefault<z.ZodBoolean>;
|
|
69
|
+
}, "strip", z.ZodTypeAny, {
|
|
70
|
+
logRetentionDays: number;
|
|
71
|
+
sensitiveFields: string[];
|
|
72
|
+
captureRead: boolean;
|
|
73
|
+
}, {
|
|
74
|
+
sensitiveFields: string[];
|
|
75
|
+
logRetentionDays?: number | undefined;
|
|
76
|
+
captureRead?: boolean | undefined;
|
|
77
|
+
}>;
|
|
78
|
+
/**
|
|
79
|
+
* Security Policy Schema
|
|
80
|
+
* "The Cloud Compliance Contract"
|
|
81
|
+
*/
|
|
82
|
+
export declare const PolicySchema: z.ZodObject<{
|
|
83
|
+
name: z.ZodString;
|
|
84
|
+
password: z.ZodOptional<z.ZodObject<{
|
|
85
|
+
minLength: z.ZodDefault<z.ZodNumber>;
|
|
86
|
+
requireUppercase: z.ZodDefault<z.ZodBoolean>;
|
|
87
|
+
requireLowercase: z.ZodDefault<z.ZodBoolean>;
|
|
88
|
+
requireNumbers: z.ZodDefault<z.ZodBoolean>;
|
|
89
|
+
requireSymbols: z.ZodDefault<z.ZodBoolean>;
|
|
90
|
+
expirationDays: z.ZodOptional<z.ZodNumber>;
|
|
91
|
+
historyCount: z.ZodDefault<z.ZodNumber>;
|
|
92
|
+
}, "strip", z.ZodTypeAny, {
|
|
93
|
+
minLength: number;
|
|
94
|
+
requireUppercase: boolean;
|
|
95
|
+
requireLowercase: boolean;
|
|
96
|
+
requireNumbers: boolean;
|
|
97
|
+
requireSymbols: boolean;
|
|
98
|
+
historyCount: number;
|
|
99
|
+
expirationDays?: number | undefined;
|
|
100
|
+
}, {
|
|
101
|
+
minLength?: number | undefined;
|
|
102
|
+
requireUppercase?: boolean | undefined;
|
|
103
|
+
requireLowercase?: boolean | undefined;
|
|
104
|
+
requireNumbers?: boolean | undefined;
|
|
105
|
+
requireSymbols?: boolean | undefined;
|
|
106
|
+
expirationDays?: number | undefined;
|
|
107
|
+
historyCount?: number | undefined;
|
|
108
|
+
}>>;
|
|
109
|
+
network: z.ZodOptional<z.ZodObject<{
|
|
110
|
+
trustedRanges: z.ZodArray<z.ZodString, "many">;
|
|
111
|
+
blockUnknown: z.ZodDefault<z.ZodBoolean>;
|
|
112
|
+
vpnRequired: z.ZodDefault<z.ZodBoolean>;
|
|
113
|
+
}, "strip", z.ZodTypeAny, {
|
|
114
|
+
trustedRanges: string[];
|
|
115
|
+
blockUnknown: boolean;
|
|
116
|
+
vpnRequired: boolean;
|
|
117
|
+
}, {
|
|
118
|
+
trustedRanges: string[];
|
|
119
|
+
blockUnknown?: boolean | undefined;
|
|
120
|
+
vpnRequired?: boolean | undefined;
|
|
121
|
+
}>>;
|
|
122
|
+
session: z.ZodOptional<z.ZodObject<{
|
|
123
|
+
idleTimeout: z.ZodDefault<z.ZodNumber>;
|
|
124
|
+
absoluteTimeout: z.ZodDefault<z.ZodNumber>;
|
|
125
|
+
forceMfa: z.ZodDefault<z.ZodBoolean>;
|
|
126
|
+
}, "strip", z.ZodTypeAny, {
|
|
127
|
+
idleTimeout: number;
|
|
128
|
+
absoluteTimeout: number;
|
|
129
|
+
forceMfa: boolean;
|
|
130
|
+
}, {
|
|
131
|
+
idleTimeout?: number | undefined;
|
|
132
|
+
absoluteTimeout?: number | undefined;
|
|
133
|
+
forceMfa?: boolean | undefined;
|
|
134
|
+
}>>;
|
|
135
|
+
audit: z.ZodOptional<z.ZodObject<{
|
|
136
|
+
logRetentionDays: z.ZodDefault<z.ZodNumber>;
|
|
137
|
+
sensitiveFields: z.ZodArray<z.ZodString, "many">;
|
|
138
|
+
captureRead: z.ZodDefault<z.ZodBoolean>;
|
|
139
|
+
}, "strip", z.ZodTypeAny, {
|
|
140
|
+
logRetentionDays: number;
|
|
141
|
+
sensitiveFields: string[];
|
|
142
|
+
captureRead: boolean;
|
|
143
|
+
}, {
|
|
144
|
+
sensitiveFields: string[];
|
|
145
|
+
logRetentionDays?: number | undefined;
|
|
146
|
+
captureRead?: boolean | undefined;
|
|
147
|
+
}>>;
|
|
148
|
+
/** Assignment */
|
|
149
|
+
isDefault: z.ZodDefault<z.ZodBoolean>;
|
|
150
|
+
assignedProfiles: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
151
|
+
}, "strip", z.ZodTypeAny, {
|
|
152
|
+
name: string;
|
|
153
|
+
isDefault: boolean;
|
|
154
|
+
password?: {
|
|
155
|
+
minLength: number;
|
|
156
|
+
requireUppercase: boolean;
|
|
157
|
+
requireLowercase: boolean;
|
|
158
|
+
requireNumbers: boolean;
|
|
159
|
+
requireSymbols: boolean;
|
|
160
|
+
historyCount: number;
|
|
161
|
+
expirationDays?: number | undefined;
|
|
162
|
+
} | undefined;
|
|
163
|
+
assignedProfiles?: string[] | undefined;
|
|
164
|
+
network?: {
|
|
165
|
+
trustedRanges: string[];
|
|
166
|
+
blockUnknown: boolean;
|
|
167
|
+
vpnRequired: boolean;
|
|
168
|
+
} | undefined;
|
|
169
|
+
session?: {
|
|
170
|
+
idleTimeout: number;
|
|
171
|
+
absoluteTimeout: number;
|
|
172
|
+
forceMfa: boolean;
|
|
173
|
+
} | undefined;
|
|
174
|
+
audit?: {
|
|
175
|
+
logRetentionDays: number;
|
|
176
|
+
sensitiveFields: string[];
|
|
177
|
+
captureRead: boolean;
|
|
178
|
+
} | undefined;
|
|
179
|
+
}, {
|
|
180
|
+
name: string;
|
|
181
|
+
password?: {
|
|
182
|
+
minLength?: number | undefined;
|
|
183
|
+
requireUppercase?: boolean | undefined;
|
|
184
|
+
requireLowercase?: boolean | undefined;
|
|
185
|
+
requireNumbers?: boolean | undefined;
|
|
186
|
+
requireSymbols?: boolean | undefined;
|
|
187
|
+
expirationDays?: number | undefined;
|
|
188
|
+
historyCount?: number | undefined;
|
|
189
|
+
} | undefined;
|
|
190
|
+
isDefault?: boolean | undefined;
|
|
191
|
+
assignedProfiles?: string[] | undefined;
|
|
192
|
+
network?: {
|
|
193
|
+
trustedRanges: string[];
|
|
194
|
+
blockUnknown?: boolean | undefined;
|
|
195
|
+
vpnRequired?: boolean | undefined;
|
|
196
|
+
} | undefined;
|
|
197
|
+
session?: {
|
|
198
|
+
idleTimeout?: number | undefined;
|
|
199
|
+
absoluteTimeout?: number | undefined;
|
|
200
|
+
forceMfa?: boolean | undefined;
|
|
201
|
+
} | undefined;
|
|
202
|
+
audit?: {
|
|
203
|
+
sensitiveFields: string[];
|
|
204
|
+
logRetentionDays?: number | undefined;
|
|
205
|
+
captureRead?: boolean | undefined;
|
|
206
|
+
} | undefined;
|
|
207
|
+
}>;
|
|
208
|
+
export type Policy = z.infer<typeof PolicySchema>;
|
|
209
|
+
//# sourceMappingURL=policy.zod.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"policy.zod.d.ts","sourceRoot":"","sources":["../../src/system/policy.zod.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;GAEG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;EAQ/B,CAAC;AAEH;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;EAI9B,CAAC;AAEH;;GAEG;AACH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;EAI9B,CAAC;AAEH;;GAEG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;EAI5B,CAAC;AAEH;;;GAGG;AACH,eAAO,MAAM,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAQvB,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAGjB,CAAC;AAEH,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC"}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PolicySchema = exports.AuditPolicySchema = exports.SessionPolicySchema = exports.NetworkPolicySchema = exports.PasswordPolicySchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
/**
|
|
6
|
+
* Password Complexity Policy
|
|
7
|
+
*/
|
|
8
|
+
exports.PasswordPolicySchema = zod_1.z.object({
|
|
9
|
+
minLength: zod_1.z.number().default(8),
|
|
10
|
+
requireUppercase: zod_1.z.boolean().default(true),
|
|
11
|
+
requireLowercase: zod_1.z.boolean().default(true),
|
|
12
|
+
requireNumbers: zod_1.z.boolean().default(true),
|
|
13
|
+
requireSymbols: zod_1.z.boolean().default(false),
|
|
14
|
+
expirationDays: zod_1.z.number().optional().describe('Force password change every X days'),
|
|
15
|
+
historyCount: zod_1.z.number().default(3).describe('Prevent reusing last X passwords'),
|
|
16
|
+
});
|
|
17
|
+
/**
|
|
18
|
+
* Network Access Policy (IP Whitelisting)
|
|
19
|
+
*/
|
|
20
|
+
exports.NetworkPolicySchema = zod_1.z.object({
|
|
21
|
+
trustedRanges: zod_1.z.array(zod_1.z.string()).describe('CIDR ranges allowed to access (e.g. 10.0.0.0/8)'),
|
|
22
|
+
blockUnknown: zod_1.z.boolean().default(false).describe('Block all IPs not in trusted ranges'),
|
|
23
|
+
vpnRequired: zod_1.z.boolean().default(false),
|
|
24
|
+
});
|
|
25
|
+
/**
|
|
26
|
+
* Session Policy
|
|
27
|
+
*/
|
|
28
|
+
exports.SessionPolicySchema = zod_1.z.object({
|
|
29
|
+
idleTimeout: zod_1.z.number().default(30).describe('Minutes before idle session logout'),
|
|
30
|
+
absoluteTimeout: zod_1.z.number().default(480).describe('Max session duration (minutes)'),
|
|
31
|
+
forceMfa: zod_1.z.boolean().default(false).describe('Require 2FA for all users'),
|
|
32
|
+
});
|
|
33
|
+
/**
|
|
34
|
+
* Audit Retention Policy
|
|
35
|
+
*/
|
|
36
|
+
exports.AuditPolicySchema = zod_1.z.object({
|
|
37
|
+
logRetentionDays: zod_1.z.number().default(180),
|
|
38
|
+
sensitiveFields: zod_1.z.array(zod_1.z.string()).describe('Fields to redact in logs (e.g. password, ssn)'),
|
|
39
|
+
captureRead: zod_1.z.boolean().default(false).describe('Log read access (High volume!)'),
|
|
40
|
+
});
|
|
41
|
+
/**
|
|
42
|
+
* Security Policy Schema
|
|
43
|
+
* "The Cloud Compliance Contract"
|
|
44
|
+
*/
|
|
45
|
+
exports.PolicySchema = zod_1.z.object({
|
|
46
|
+
name: zod_1.z.string().regex(/^[a-z_][a-z0-9_]*$/).describe('Policy Name'),
|
|
47
|
+
password: exports.PasswordPolicySchema.optional(),
|
|
48
|
+
network: exports.NetworkPolicySchema.optional(),
|
|
49
|
+
session: exports.SessionPolicySchema.optional(),
|
|
50
|
+
audit: exports.AuditPolicySchema.optional(),
|
|
51
|
+
/** Assignment */
|
|
52
|
+
isDefault: zod_1.z.boolean().default(false).describe('Apply to all users by default'),
|
|
53
|
+
assignedProfiles: zod_1.z.array(zod_1.z.string()).optional().describe('Apply to specific profiles'),
|
|
54
|
+
});
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* Role Schema (aka Business Unit / Org Unit)
|
|
4
|
+
* Defines the organizational hierarchy (Reporting Structure).
|
|
5
|
+
*
|
|
6
|
+
* COMPARISON:
|
|
7
|
+
* - Salesforce: "Role" (Hierarchy for visibility rollup)
|
|
8
|
+
* - Microsoft: "Business Unit" (Structural container for data)
|
|
9
|
+
* - Kubernetes/AWS: "Role" usually refers to Permissions (we use PermissionSet for that)
|
|
10
|
+
*
|
|
11
|
+
* ROLES IN OBJECTSTACK:
|
|
12
|
+
* Used primarily for "Reporting Structure" - Managers see subordinates' data.
|
|
13
|
+
*/
|
|
14
|
+
export declare const RoleSchema: z.ZodObject<{
|
|
15
|
+
/** Identity */
|
|
16
|
+
name: z.ZodString;
|
|
17
|
+
label: z.ZodString;
|
|
18
|
+
/** Hierarchy */
|
|
19
|
+
parent: z.ZodOptional<z.ZodString>;
|
|
20
|
+
/** Description */
|
|
21
|
+
description: z.ZodOptional<z.ZodString>;
|
|
22
|
+
}, "strip", z.ZodTypeAny, {
|
|
23
|
+
label: string;
|
|
24
|
+
name: string;
|
|
25
|
+
description?: string | undefined;
|
|
26
|
+
parent?: string | undefined;
|
|
27
|
+
}, {
|
|
28
|
+
label: string;
|
|
29
|
+
name: string;
|
|
30
|
+
description?: string | undefined;
|
|
31
|
+
parent?: string | undefined;
|
|
32
|
+
}>;
|
|
33
|
+
export type Role = z.infer<typeof RoleSchema>;
|
|
34
|
+
//# sourceMappingURL=role.zod.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"role.zod.d.ts","sourceRoot":"","sources":["../../src/system/role.zod.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,UAAU;IACrB,eAAe;;;IAIf,gBAAgB;;IAGhB,kBAAkB;;;;;;;;;;;;EAElB,CAAC;AAEH,MAAM,MAAM,IAAI,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.RoleSchema = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
/**
|
|
6
|
+
* Role Schema (aka Business Unit / Org Unit)
|
|
7
|
+
* Defines the organizational hierarchy (Reporting Structure).
|
|
8
|
+
*
|
|
9
|
+
* COMPARISON:
|
|
10
|
+
* - Salesforce: "Role" (Hierarchy for visibility rollup)
|
|
11
|
+
* - Microsoft: "Business Unit" (Structural container for data)
|
|
12
|
+
* - Kubernetes/AWS: "Role" usually refers to Permissions (we use PermissionSet for that)
|
|
13
|
+
*
|
|
14
|
+
* ROLES IN OBJECTSTACK:
|
|
15
|
+
* Used primarily for "Reporting Structure" - Managers see subordinates' data.
|
|
16
|
+
*/
|
|
17
|
+
exports.RoleSchema = zod_1.z.object({
|
|
18
|
+
/** Identity */
|
|
19
|
+
name: zod_1.z.string().regex(/^[a-z_][a-z0-9_]*$/).describe('Unique role name'),
|
|
20
|
+
label: zod_1.z.string().describe('Display label (e.g. VP of Sales)'),
|
|
21
|
+
/** Hierarchy */
|
|
22
|
+
parent: zod_1.z.string().optional().describe('Parent Role ID (Reports To)'),
|
|
23
|
+
/** Description */
|
|
24
|
+
description: zod_1.z.string().optional(),
|
|
25
|
+
});
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* Territory Management Protocol
|
|
4
|
+
* Defines a matrix reporting structure that exists parallel to the Role Hierarchy.
|
|
5
|
+
*
|
|
6
|
+
* USE CASE:
|
|
7
|
+
* - Enterprise Sales Teams (Geo-based: "EMEA", "APAC")
|
|
8
|
+
* - Industry Verticals (Industry-based: "Healthcare", "Financial")
|
|
9
|
+
* - Strategic Accounts (Account-based: "Strategic Accounts")
|
|
10
|
+
*
|
|
11
|
+
* DIFFERENCE FROM ROLE:
|
|
12
|
+
* - Role: Hierarchy of PEOPLE (Who reports to whom). Stable. HR-driven.
|
|
13
|
+
* - Territory: Hierarchy of ACCOUNTS/REVENUE (Who owns which market). Flexible. Sales-driven.
|
|
14
|
+
* - One User can be assigned to MANY Territories (Matrix).
|
|
15
|
+
* - One User has only ONE Role (Tree).
|
|
16
|
+
*/
|
|
17
|
+
export declare const TerritoryType: z.ZodEnum<["geography", "industry", "named_account", "product_line"]>;
|
|
18
|
+
/**
|
|
19
|
+
* Territory Model Schema
|
|
20
|
+
* A container for a version of territory planning.
|
|
21
|
+
* (e.g. "Fiscal Year 2024 Planning" vs "Fiscal Year 2025 Planning")
|
|
22
|
+
*/
|
|
23
|
+
export declare const TerritoryModelSchema: z.ZodObject<{
|
|
24
|
+
name: z.ZodString;
|
|
25
|
+
state: z.ZodDefault<z.ZodEnum<["planning", "active", "archived"]>>;
|
|
26
|
+
startDate: z.ZodOptional<z.ZodString>;
|
|
27
|
+
endDate: z.ZodOptional<z.ZodString>;
|
|
28
|
+
}, "strip", z.ZodTypeAny, {
|
|
29
|
+
state: "active" | "planning" | "archived";
|
|
30
|
+
name: string;
|
|
31
|
+
startDate?: string | undefined;
|
|
32
|
+
endDate?: string | undefined;
|
|
33
|
+
}, {
|
|
34
|
+
name: string;
|
|
35
|
+
state?: "active" | "planning" | "archived" | undefined;
|
|
36
|
+
startDate?: string | undefined;
|
|
37
|
+
endDate?: string | undefined;
|
|
38
|
+
}>;
|
|
39
|
+
/**
|
|
40
|
+
* Territory Node Schema
|
|
41
|
+
* A single node in the territory tree.
|
|
42
|
+
*/
|
|
43
|
+
export declare const TerritorySchema: z.ZodObject<{
|
|
44
|
+
/** Identity */
|
|
45
|
+
name: z.ZodString;
|
|
46
|
+
label: z.ZodString;
|
|
47
|
+
/** Structure */
|
|
48
|
+
modelId: z.ZodString;
|
|
49
|
+
parent: z.ZodOptional<z.ZodString>;
|
|
50
|
+
type: z.ZodDefault<z.ZodEnum<["geography", "industry", "named_account", "product_line"]>>;
|
|
51
|
+
/**
|
|
52
|
+
* Assignment Rules (The "Magic")
|
|
53
|
+
* How do accounts automatically fall into this territory?
|
|
54
|
+
* e.g. "BillingCountry = 'US' AND BillingState = 'CA'"
|
|
55
|
+
*/
|
|
56
|
+
assignmentRule: z.ZodOptional<z.ZodString>;
|
|
57
|
+
/**
|
|
58
|
+
* User Assignment
|
|
59
|
+
* Users assigned to work this territory.
|
|
60
|
+
*/
|
|
61
|
+
assignedUsers: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
62
|
+
/** Access Level */
|
|
63
|
+
accountAccess: z.ZodDefault<z.ZodEnum<["read", "edit"]>>;
|
|
64
|
+
opportunityAccess: z.ZodDefault<z.ZodEnum<["read", "edit"]>>;
|
|
65
|
+
caseAccess: z.ZodDefault<z.ZodEnum<["read", "edit"]>>;
|
|
66
|
+
}, "strip", z.ZodTypeAny, {
|
|
67
|
+
type: "geography" | "industry" | "named_account" | "product_line";
|
|
68
|
+
label: string;
|
|
69
|
+
name: string;
|
|
70
|
+
modelId: string;
|
|
71
|
+
accountAccess: "read" | "edit";
|
|
72
|
+
opportunityAccess: "read" | "edit";
|
|
73
|
+
caseAccess: "read" | "edit";
|
|
74
|
+
parent?: string | undefined;
|
|
75
|
+
assignmentRule?: string | undefined;
|
|
76
|
+
assignedUsers?: string[] | undefined;
|
|
77
|
+
}, {
|
|
78
|
+
label: string;
|
|
79
|
+
name: string;
|
|
80
|
+
modelId: string;
|
|
81
|
+
type?: "geography" | "industry" | "named_account" | "product_line" | undefined;
|
|
82
|
+
parent?: string | undefined;
|
|
83
|
+
assignmentRule?: string | undefined;
|
|
84
|
+
assignedUsers?: string[] | undefined;
|
|
85
|
+
accountAccess?: "read" | "edit" | undefined;
|
|
86
|
+
opportunityAccess?: "read" | "edit" | undefined;
|
|
87
|
+
caseAccess?: "read" | "edit" | undefined;
|
|
88
|
+
}>;
|
|
89
|
+
export type Territory = z.infer<typeof TerritorySchema>;
|
|
90
|
+
export type TerritoryModel = z.infer<typeof TerritoryModelSchema>;
|
|
91
|
+
//# sourceMappingURL=territory.zod.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"territory.zod.d.ts","sourceRoot":"","sources":["../../src/system/territory.zod.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;;;;;;;GAcG;AAEH,eAAO,MAAM,aAAa,uEAKxB,CAAC;AAEH;;;;GAIG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;EAK/B,CAAC;AAEH;;;GAGG;AACH,eAAO,MAAM,eAAe;IAC1B,eAAe;;;IAIf,gBAAgB;;;;IAKhB;;;;OAIG;;IAGH;;;OAGG;;IAGH,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;EAInB,CAAC;AAEH,MAAM,MAAM,SAAS,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AACxD,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC"}
|