@objectstack/spec 1.0.11 → 1.0.12
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 +41 -1
- package/dist/ai/index.d.mts +2 -1
- package/dist/ai/index.d.ts +2 -1
- package/dist/ai/index.js +2047 -1944
- package/dist/ai/index.js.map +1 -1
- package/dist/ai/index.mjs +2047 -1944
- package/dist/ai/index.mjs.map +1 -1
- package/dist/api/index.d.mts +3 -1
- package/dist/api/index.d.ts +3 -1
- package/dist/api/index.js +2599 -2292
- package/dist/api/index.js.map +1 -1
- package/dist/api/index.mjs +2587 -2292
- package/dist/api/index.mjs.map +1 -1
- package/dist/automation/index.d.mts +2 -1
- package/dist/automation/index.d.ts +2 -1
- package/dist/automation/index.js +83 -0
- package/dist/automation/index.js.map +1 -1
- package/dist/automation/index.mjs +77 -0
- package/dist/automation/index.mjs.map +1 -1
- package/dist/contracts/index.d.mts +3 -2
- package/dist/contracts/index.d.ts +3 -2
- package/dist/data/index.d.mts +3 -2
- package/dist/data/index.d.ts +3 -2
- package/dist/data/index.js +658 -556
- package/dist/data/index.js.map +1 -1
- package/dist/data/index.mjs +656 -556
- package/dist/data/index.mjs.map +1 -1
- package/dist/{driver.zod-lfi00zVT.d.ts → driver.zod-CfGk9GYh.d.ts} +2164 -11
- package/dist/{driver.zod-BOM_Etco.d.mts → driver.zod-y1cX6R3c.d.mts} +2164 -11
- package/dist/hub/index.d.mts +1 -1
- package/dist/hub/index.d.ts +1 -1
- package/dist/hub/index.js +789 -724
- package/dist/hub/index.js.map +1 -1
- package/dist/hub/index.mjs +789 -724
- package/dist/hub/index.mjs.map +1 -1
- package/dist/{index-C67cfwmW.d.ts → index-B0Hf65bV.d.ts} +13 -5
- package/dist/{index-DLcySG7U.d.ts → index-B5pKM0My.d.ts} +335 -4370
- package/dist/{index-Os7lItRe.d.mts → index-BA022mg2.d.ts} +6178 -129
- package/dist/{index-B5-VbOKg.d.mts → index-BGeLoH2z.d.ts} +4251 -74
- package/dist/{index-CH5zloR3.d.ts → index-BwO__aqV.d.ts} +1 -1
- package/dist/{index-Dp7GFJ8V.d.mts → index-Cia3JPQ8.d.mts} +13 -5
- package/dist/{index-D12rNohm.d.mts → index-CpD1q1FP.d.ts} +35 -18
- package/dist/{index-Os7lItRe.d.ts → index-D5RSFPuB.d.mts} +6178 -129
- package/dist/{index-CU4m6noq.d.mts → index-DGjpaj0X.d.mts} +1 -1
- package/dist/{index-D12rNohm.d.ts → index-Dfn5VXl6.d.mts} +35 -18
- package/dist/{index-l6WIlmOD.d.mts → index-Dgybxlky.d.mts} +177 -158
- package/dist/{index-l6WIlmOD.d.ts → index-Dgybxlky.d.ts} +177 -158
- package/dist/{index-DLcySG7U.d.mts → index-Dpsk8PF4.d.mts} +335 -4370
- package/dist/{index-CyognKSZ.d.ts → index-DrNah5E0.d.ts} +1952 -6990
- package/dist/{index-DE_lJ11p.d.mts → index-OO84R20k.d.mts} +1952 -6990
- package/dist/{index-B5-VbOKg.d.ts → index-upA3Xt04.d.mts} +4251 -74
- package/dist/index.d.mts +8072 -1922
- package/dist/index.d.ts +8072 -1922
- package/dist/index.js +8563 -8249
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +8563 -8249
- package/dist/index.mjs.map +1 -1
- package/dist/integration/index.d.mts +1 -1
- package/dist/integration/index.d.ts +1 -1
- package/dist/kernel/index.d.mts +2 -1
- package/dist/kernel/index.d.ts +2 -1
- package/dist/kernel/index.js +884 -684
- package/dist/kernel/index.js.map +1 -1
- package/dist/kernel/index.mjs +870 -684
- package/dist/kernel/index.mjs.map +1 -1
- package/dist/package-registry.zod-JMcOYNxM.d.mts +21119 -0
- package/dist/package-registry.zod-JMcOYNxM.d.ts +21119 -0
- package/dist/state-machine.zod-B-lFFSxQ.d.mts +285 -0
- package/dist/state-machine.zod-B-lFFSxQ.d.ts +285 -0
- package/dist/system/index.d.mts +2 -1
- package/dist/system/index.d.ts +2 -1
- package/dist/system/index.js +749 -651
- package/dist/system/index.js.map +1 -1
- package/dist/system/index.mjs +749 -651
- package/dist/system/index.mjs.map +1 -1
- package/dist/ui/index.d.mts +1 -1
- package/dist/ui/index.d.ts +1 -1
- package/json-schema/ai/Agent.json +499 -0
- package/json-schema/ai/DevOpsAgent.json +499 -0
- package/json-schema/ai/FeedbackLoop.json +2188 -186
- package/json-schema/ai/Resolution.json +2188 -186
- package/json-schema/api/ApiRoutes.json +4 -0
- package/json-schema/api/CompileManifestResponse.json +40 -10
- package/json-schema/api/DisablePackageRequest.json +18 -0
- package/json-schema/api/DisablePackageResponse.json +1521 -0
- package/json-schema/api/Discovery.json +4 -0
- package/json-schema/api/EnablePackageRequest.json +18 -0
- package/json-schema/api/EnablePackageResponse.json +1521 -0
- package/json-schema/api/GetDiscoveryResponse.json +4 -0
- package/json-schema/api/GetPackageRequest.json +18 -0
- package/json-schema/api/GetPackageResponse.json +1518 -0
- package/json-schema/api/InstallPackageRequest.json +1483 -0
- package/json-schema/api/InstallPackageResponse.json +1521 -0
- package/json-schema/api/ListPackagesRequest.json +42 -0
- package/json-schema/api/ListPackagesResponse.json +1525 -0
- package/json-schema/api/ObjectDefinitionResponse.json +1001 -0
- package/json-schema/api/ObjectStackProtocol.json +86 -1
- package/json-schema/api/RestApiConfig.json +5 -0
- package/json-schema/api/RestServerConfig.json +5 -0
- package/json-schema/api/UninstallPackageRequest.json +18 -0
- package/json-schema/api/UninstallPackageResponse.json +25 -0
- package/json-schema/automation/ActionRef.json +30 -0
- package/json-schema/automation/Event.json +24 -0
- package/json-schema/automation/Flow.json +1 -0
- package/json-schema/automation/FlowNode.json +1 -0
- package/json-schema/automation/FlowNodeAction.json +1 -0
- package/json-schema/automation/GuardRef.json +30 -0
- package/json-schema/automation/StateMachine.json +504 -0
- package/json-schema/automation/StateNode.json +324 -0
- package/json-schema/automation/Transition.json +73 -0
- package/json-schema/data/Object.json +1001 -0
- package/json-schema/data/ObjectExtension.json +2376 -0
- package/json-schema/data/ObjectOwnershipEnum.json +13 -0
- package/json-schema/hub/ComposerResponse.json +40 -10
- package/json-schema/kernel/DisablePackageRequest.json +18 -0
- package/json-schema/kernel/DisablePackageResponse.json +1521 -0
- package/json-schema/kernel/EnablePackageRequest.json +18 -0
- package/json-schema/kernel/EnablePackageResponse.json +1521 -0
- package/json-schema/kernel/EventBusConfig.json +15 -0
- package/json-schema/kernel/EventHandler.json +6 -0
- package/json-schema/kernel/EventPersistence.json +3 -0
- package/json-schema/kernel/EventRoute.json +3 -0
- package/json-schema/kernel/EventWebhookConfig.json +3 -0
- package/json-schema/kernel/GetPackageRequest.json +18 -0
- package/json-schema/kernel/GetPackageResponse.json +1518 -0
- package/json-schema/kernel/InstallPackageRequest.json +1483 -0
- package/json-schema/kernel/InstallPackageResponse.json +1521 -0
- package/json-schema/kernel/InstalledPackage.json +1509 -0
- package/json-schema/kernel/ListPackagesRequest.json +42 -0
- package/json-schema/kernel/ListPackagesResponse.json +1525 -0
- package/json-schema/kernel/Manifest.json +40 -10
- package/json-schema/kernel/PackageStatusEnum.json +16 -0
- package/json-schema/kernel/Plugin.json +5 -0
- package/json-schema/kernel/PluginContext.json +31 -7
- package/json-schema/kernel/PluginLifecycle.json +7 -1
- package/json-schema/kernel/RealTimeNotificationConfig.json +3 -0
- package/json-schema/kernel/UninstallPackageRequest.json +18 -0
- package/json-schema/kernel/UninstallPackageResponse.json +25 -0
- package/json-schema/system/ChangeSet.json +2188 -186
- package/json-schema/system/CreateObjectOperation.json +1001 -0
- package/json-schema/system/MigrationOperation.json +1001 -0
- package/package.json +29 -15
- package/prompts/create-new-project.md +37 -19
- package/dist/{index-I3piy4U4.d.mts → index-BmU_sD1f.d.mts} +8 -8
- package/dist/{index-CkhpsEUw.d.ts → index-BnXuc_HO.d.ts} +8 -8
- package/dist/{index-CIDI-8zR.d.mts → index-C_NTOcet.d.mts} +98 -98
- package/dist/{index-CIDI-8zR.d.ts → index-C_NTOcet.d.ts} +98 -98
package/dist/hub/index.js
CHANGED
|
@@ -80,10 +80,10 @@ __export(hub_exports, {
|
|
|
80
80
|
module.exports = __toCommonJS(hub_exports);
|
|
81
81
|
|
|
82
82
|
// src/hub/composer.zod.ts
|
|
83
|
-
var
|
|
83
|
+
var import_zod6 = require("zod");
|
|
84
84
|
|
|
85
85
|
// src/kernel/manifest.zod.ts
|
|
86
|
-
var
|
|
86
|
+
var import_zod5 = require("zod");
|
|
87
87
|
|
|
88
88
|
// src/kernel/plugin-capability.zod.ts
|
|
89
89
|
var import_zod = require("zod");
|
|
@@ -902,48 +902,48 @@ var PluginLoadingStateSchema = import_zod2.z.object({
|
|
|
902
902
|
var import_zod3 = require("zod");
|
|
903
903
|
var PluginContextSchema = import_zod3.z.object({
|
|
904
904
|
ql: import_zod3.z.object({
|
|
905
|
-
object: import_zod3.z.
|
|
905
|
+
object: import_zod3.z.any(),
|
|
906
906
|
// Return any to allow method chaining
|
|
907
|
-
query: import_zod3.z.
|
|
907
|
+
query: import_zod3.z.any()
|
|
908
908
|
}).passthrough().describe("ObjectQL Engine Interface"),
|
|
909
909
|
os: import_zod3.z.object({
|
|
910
|
-
getCurrentUser: import_zod3.z.
|
|
911
|
-
getConfig: import_zod3.z.
|
|
910
|
+
getCurrentUser: import_zod3.z.any(),
|
|
911
|
+
getConfig: import_zod3.z.any()
|
|
912
912
|
}).passthrough().describe("ObjectStack Kernel Interface"),
|
|
913
913
|
logger: import_zod3.z.object({
|
|
914
|
-
debug: import_zod3.z.
|
|
915
|
-
info: import_zod3.z.
|
|
916
|
-
warn: import_zod3.z.
|
|
917
|
-
error: import_zod3.z.
|
|
914
|
+
debug: import_zod3.z.any(),
|
|
915
|
+
info: import_zod3.z.any(),
|
|
916
|
+
warn: import_zod3.z.any(),
|
|
917
|
+
error: import_zod3.z.any()
|
|
918
918
|
}).passthrough().describe("Logger Interface"),
|
|
919
919
|
storage: import_zod3.z.object({
|
|
920
|
-
get: import_zod3.z.
|
|
921
|
-
set: import_zod3.z.
|
|
922
|
-
delete: import_zod3.z.
|
|
920
|
+
get: import_zod3.z.any(),
|
|
921
|
+
set: import_zod3.z.any(),
|
|
922
|
+
delete: import_zod3.z.any()
|
|
923
923
|
}).passthrough().describe("Storage Interface"),
|
|
924
924
|
i18n: import_zod3.z.object({
|
|
925
|
-
t: import_zod3.z.
|
|
926
|
-
getLocale: import_zod3.z.
|
|
925
|
+
t: import_zod3.z.any(),
|
|
926
|
+
getLocale: import_zod3.z.any()
|
|
927
927
|
}).passthrough().describe("Internationalization Interface"),
|
|
928
928
|
metadata: import_zod3.z.record(import_zod3.z.string(), import_zod3.z.any()),
|
|
929
929
|
events: import_zod3.z.record(import_zod3.z.string(), import_zod3.z.any()),
|
|
930
930
|
app: import_zod3.z.object({
|
|
931
931
|
router: import_zod3.z.object({
|
|
932
|
-
get: import_zod3.z.
|
|
933
|
-
post: import_zod3.z.
|
|
934
|
-
use: import_zod3.z.
|
|
932
|
+
get: import_zod3.z.any(),
|
|
933
|
+
post: import_zod3.z.any(),
|
|
934
|
+
use: import_zod3.z.any()
|
|
935
935
|
}).passthrough()
|
|
936
936
|
}).passthrough().describe("App Framework Interface"),
|
|
937
937
|
drivers: import_zod3.z.object({
|
|
938
|
-
register: import_zod3.z.
|
|
938
|
+
register: import_zod3.z.any()
|
|
939
939
|
}).passthrough().describe("Driver Registry")
|
|
940
940
|
});
|
|
941
941
|
var PluginLifecycleSchema = import_zod3.z.object({
|
|
942
|
-
onInstall: import_zod3.z.
|
|
943
|
-
onEnable: import_zod3.z.
|
|
944
|
-
onDisable: import_zod3.z.
|
|
945
|
-
onUninstall: import_zod3.z.
|
|
946
|
-
onUpgrade: import_zod3.z.
|
|
942
|
+
onInstall: import_zod3.z.any().optional(),
|
|
943
|
+
onEnable: import_zod3.z.any().optional(),
|
|
944
|
+
onDisable: import_zod3.z.any().optional(),
|
|
945
|
+
onUninstall: import_zod3.z.any().optional(),
|
|
946
|
+
onUpgrade: import_zod3.z.any().optional()
|
|
947
947
|
});
|
|
948
948
|
var CORE_PLUGIN_TYPES = [
|
|
949
949
|
"ui",
|
|
@@ -977,8 +977,53 @@ var PluginSchema = PluginLifecycleSchema.extend({
|
|
|
977
977
|
homepage: import_zod3.z.string().url().optional()
|
|
978
978
|
});
|
|
979
979
|
|
|
980
|
+
// src/data/dataset.zod.ts
|
|
981
|
+
var import_zod4 = require("zod");
|
|
982
|
+
var DatasetMode = import_zod4.z.enum([
|
|
983
|
+
"insert",
|
|
984
|
+
// Try to insert, fail on duplicate
|
|
985
|
+
"update",
|
|
986
|
+
// Only update found records, ignore new
|
|
987
|
+
"upsert",
|
|
988
|
+
// Create new or Update existing (Standard)
|
|
989
|
+
"replace",
|
|
990
|
+
// Delete ALL records in object then insert (Dangerous - use for cache tables)
|
|
991
|
+
"ignore"
|
|
992
|
+
// Try to insert, silently skip duplicates
|
|
993
|
+
]);
|
|
994
|
+
var DatasetSchema = import_zod4.z.object({
|
|
995
|
+
/**
|
|
996
|
+
* Target Object
|
|
997
|
+
* The machine name of the object to populate.
|
|
998
|
+
*/
|
|
999
|
+
object: import_zod4.z.string().regex(/^[a-z_][a-z0-9_]*$/).describe("Target Object Name"),
|
|
1000
|
+
/**
|
|
1001
|
+
* Idempotency Key (The "Upsert" Key)
|
|
1002
|
+
* The field used to check if a record already exists.
|
|
1003
|
+
* Best Practice: Use a natural key like 'code', 'slug', 'username' or 'external_id'.
|
|
1004
|
+
* Standard: '_id' (internal ID) is rarely used for portable seed data.
|
|
1005
|
+
*/
|
|
1006
|
+
externalId: import_zod4.z.string().default("name").describe("Field match for uniqueness check"),
|
|
1007
|
+
/**
|
|
1008
|
+
* Import Strategy
|
|
1009
|
+
*/
|
|
1010
|
+
mode: DatasetMode.default("upsert").describe("Conflict resolution strategy"),
|
|
1011
|
+
/**
|
|
1012
|
+
* Environment Scope
|
|
1013
|
+
* - 'all': Always load
|
|
1014
|
+
* - 'dev': Only for development/demo
|
|
1015
|
+
* - 'test': Only for CI/CD tests
|
|
1016
|
+
*/
|
|
1017
|
+
env: import_zod4.z.array(import_zod4.z.enum(["prod", "dev", "test"])).default(["prod", "dev", "test"]).describe("Applicable environments"),
|
|
1018
|
+
/**
|
|
1019
|
+
* The Payload
|
|
1020
|
+
* Array of raw JSON objects matching the Object Schema.
|
|
1021
|
+
*/
|
|
1022
|
+
records: import_zod4.z.array(import_zod4.z.record(import_zod4.z.string(), import_zod4.z.any())).describe("Data records")
|
|
1023
|
+
});
|
|
1024
|
+
|
|
980
1025
|
// src/kernel/manifest.zod.ts
|
|
981
|
-
var ManifestSchema =
|
|
1026
|
+
var ManifestSchema = import_zod5.z.object({
|
|
982
1027
|
/**
|
|
983
1028
|
* Unique package identifier using reverse domain notation.
|
|
984
1029
|
* Must be unique across the entire ecosystem.
|
|
@@ -986,14 +1031,30 @@ var ManifestSchema = import_zod4.z.object({
|
|
|
986
1031
|
* @example "com.steedos.crm"
|
|
987
1032
|
* @example "org.apache.superset"
|
|
988
1033
|
*/
|
|
989
|
-
id:
|
|
1034
|
+
id: import_zod5.z.string().describe("Unique package identifier (reverse domain style)"),
|
|
1035
|
+
/**
|
|
1036
|
+
* Short namespace identifier for metadata scoping.
|
|
1037
|
+
* Used as a prefix for objects and other metadata to prevent naming collisions
|
|
1038
|
+
* across packages from different vendors.
|
|
1039
|
+
*
|
|
1040
|
+
* Rules:
|
|
1041
|
+
* - 2-20 characters, lowercase letters, digits, and underscores only.
|
|
1042
|
+
* - Must be unique within a running instance.
|
|
1043
|
+
* - Platform-reserved namespaces (no prefix applied): "base", "system".
|
|
1044
|
+
* - FQN (Fully Qualified Name) = `{namespace}__{short_name}` (double underscore separator).
|
|
1045
|
+
*
|
|
1046
|
+
* @example "crm" → objects become crm__account, crm__deal
|
|
1047
|
+
* @example "todo" → objects become todo__task
|
|
1048
|
+
* @example "base" → objects keep short name (platform reserved)
|
|
1049
|
+
*/
|
|
1050
|
+
namespace: import_zod5.z.string().regex(/^[a-z][a-z0-9_]{1,19}$/, "Namespace must be 2-20 chars, lowercase alphanumeric + underscore").optional().describe('Short namespace identifier for metadata scoping (e.g. "crm", "todo")'),
|
|
990
1051
|
/**
|
|
991
1052
|
* Package version following semantic versioning (major.minor.patch).
|
|
992
1053
|
*
|
|
993
1054
|
* @example "1.0.0"
|
|
994
1055
|
* @example "2.1.0-beta.1"
|
|
995
1056
|
*/
|
|
996
|
-
version:
|
|
1057
|
+
version: import_zod5.z.string().regex(/^\d+\.\d+\.\d+$/).describe("Package version (semantic versioning)"),
|
|
997
1058
|
/**
|
|
998
1059
|
* Type of the package in the ObjectStack ecosystem.
|
|
999
1060
|
* - plugin: General-purpose functionality extension (Runtime: standard)
|
|
@@ -1007,7 +1068,7 @@ var ManifestSchema = import_zod4.z.object({
|
|
|
1007
1068
|
* - objectql: Core engine
|
|
1008
1069
|
* - adapter: Host adapter (Express, Fastify)
|
|
1009
1070
|
*/
|
|
1010
|
-
type:
|
|
1071
|
+
type: import_zod5.z.enum([
|
|
1011
1072
|
"plugin",
|
|
1012
1073
|
...CORE_PLUGIN_TYPES,
|
|
1013
1074
|
"module",
|
|
@@ -1021,40 +1082,40 @@ var ManifestSchema = import_zod4.z.object({
|
|
|
1021
1082
|
*
|
|
1022
1083
|
* @example "Project Management"
|
|
1023
1084
|
*/
|
|
1024
|
-
name:
|
|
1085
|
+
name: import_zod5.z.string().describe("Human-readable package name"),
|
|
1025
1086
|
/**
|
|
1026
1087
|
* Brief description of the package functionality.
|
|
1027
1088
|
* Displayed in the marketplace and plugin manager.
|
|
1028
1089
|
*/
|
|
1029
|
-
description:
|
|
1090
|
+
description: import_zod5.z.string().optional().describe("Package description"),
|
|
1030
1091
|
/**
|
|
1031
1092
|
* Array of permission strings that the package requires.
|
|
1032
1093
|
* These form the "Scope" requested by the package at installation.
|
|
1033
1094
|
*
|
|
1034
1095
|
* @example ["system.user.read", "system.data.write"]
|
|
1035
1096
|
*/
|
|
1036
|
-
permissions:
|
|
1097
|
+
permissions: import_zod5.z.array(import_zod5.z.string()).optional().describe("Array of required permission strings"),
|
|
1037
1098
|
/**
|
|
1038
1099
|
* Glob patterns specifying ObjectQL schemas files.
|
|
1039
1100
|
* Matches `*.object.yml` or `*.object.ts` files to load business objects.
|
|
1040
1101
|
*
|
|
1041
1102
|
* @example ["./src/objects/*.object.yml"]
|
|
1042
1103
|
*/
|
|
1043
|
-
objects:
|
|
1104
|
+
objects: import_zod5.z.array(import_zod5.z.string()).optional().describe("Glob patterns for ObjectQL schemas files"),
|
|
1044
1105
|
/**
|
|
1045
1106
|
* Defines system level DataSources.
|
|
1046
1107
|
* Matches `*.datasource.yml` files.
|
|
1047
1108
|
*
|
|
1048
1109
|
* @example ["./src/datasources/*.datasource.mongo.yml"]
|
|
1049
1110
|
*/
|
|
1050
|
-
datasources:
|
|
1111
|
+
datasources: import_zod5.z.array(import_zod5.z.string()).optional().describe("Glob patterns for Datasource definitions"),
|
|
1051
1112
|
/**
|
|
1052
1113
|
* Package Dependencies.
|
|
1053
1114
|
* Map of package IDs to version requirements.
|
|
1054
1115
|
*
|
|
1055
1116
|
* @example { "@steedos/plugin-auth": "^2.0.0" }
|
|
1056
1117
|
*/
|
|
1057
|
-
dependencies:
|
|
1118
|
+
dependencies: import_zod5.z.record(import_zod5.z.string(), import_zod5.z.string()).optional().describe("Package dependencies"),
|
|
1058
1119
|
/**
|
|
1059
1120
|
* Plugin Configuration Schema.
|
|
1060
1121
|
* Defines the settings this plugin exposes to the user via UI/ENV.
|
|
@@ -1069,110 +1130,114 @@ var ManifestSchema = import_zod4.z.object({
|
|
|
1069
1130
|
* }
|
|
1070
1131
|
* }
|
|
1071
1132
|
*/
|
|
1072
|
-
configuration:
|
|
1073
|
-
title:
|
|
1074
|
-
properties:
|
|
1075
|
-
type:
|
|
1076
|
-
default:
|
|
1077
|
-
description:
|
|
1078
|
-
required:
|
|
1079
|
-
secret:
|
|
1080
|
-
enum:
|
|
1133
|
+
configuration: import_zod5.z.object({
|
|
1134
|
+
title: import_zod5.z.string().optional(),
|
|
1135
|
+
properties: import_zod5.z.record(import_zod5.z.string(), import_zod5.z.object({
|
|
1136
|
+
type: import_zod5.z.enum(["string", "number", "boolean", "array", "object"]).describe("Data type of the setting"),
|
|
1137
|
+
default: import_zod5.z.any().optional().describe("Default value"),
|
|
1138
|
+
description: import_zod5.z.string().optional().describe("Tooltip description"),
|
|
1139
|
+
required: import_zod5.z.boolean().optional().describe("Is this setting required?"),
|
|
1140
|
+
secret: import_zod5.z.boolean().optional().describe("If true, value is encrypted/masked (e.g. API Keys)"),
|
|
1141
|
+
enum: import_zod5.z.array(import_zod5.z.string()).optional().describe("Allowed values for select inputs")
|
|
1081
1142
|
})).describe("Map of configuration keys to their definitions")
|
|
1082
1143
|
}).optional().describe("Plugin configuration settings"),
|
|
1083
1144
|
/**
|
|
1084
1145
|
* Contribution Points (VS Code Style).
|
|
1085
1146
|
* formalized way to extend the platform capabilities.
|
|
1086
1147
|
*/
|
|
1087
|
-
contributes:
|
|
1148
|
+
contributes: import_zod5.z.object({
|
|
1088
1149
|
/**
|
|
1089
1150
|
* Register new Metadata Kinds (CRDs).
|
|
1090
1151
|
* Enables the system to parse and validate new file types.
|
|
1091
1152
|
* Example: Registering a BI plugin to handle *.report.ts
|
|
1092
1153
|
*/
|
|
1093
|
-
kinds:
|
|
1094
|
-
id:
|
|
1095
|
-
globs:
|
|
1096
|
-
description:
|
|
1154
|
+
kinds: import_zod5.z.array(import_zod5.z.object({
|
|
1155
|
+
id: import_zod5.z.string().describe('The generic identifier of the kind (e.g., "sys.bi.report")'),
|
|
1156
|
+
globs: import_zod5.z.array(import_zod5.z.string()).describe('File patterns to watch (e.g., ["**/*.report.ts"])'),
|
|
1157
|
+
description: import_zod5.z.string().optional().describe("Description of what this kind represents")
|
|
1097
1158
|
})).optional().describe("New Metadata Types to recognize"),
|
|
1098
1159
|
/**
|
|
1099
1160
|
* Register System Hooks.
|
|
1100
1161
|
* Declares that this plugin listens to specific system events.
|
|
1101
1162
|
*/
|
|
1102
|
-
events:
|
|
1163
|
+
events: import_zod5.z.array(import_zod5.z.string()).optional().describe("Events this plugin listens to"),
|
|
1103
1164
|
/**
|
|
1104
1165
|
* Register UI Menus.
|
|
1105
1166
|
*/
|
|
1106
|
-
menus:
|
|
1107
|
-
id:
|
|
1108
|
-
label:
|
|
1109
|
-
command:
|
|
1167
|
+
menus: import_zod5.z.record(import_zod5.z.string(), import_zod5.z.array(import_zod5.z.object({
|
|
1168
|
+
id: import_zod5.z.string(),
|
|
1169
|
+
label: import_zod5.z.string(),
|
|
1170
|
+
command: import_zod5.z.string().optional()
|
|
1110
1171
|
}))).optional().describe("UI Menu contributions"),
|
|
1111
1172
|
/**
|
|
1112
1173
|
* Register Custom Themes.
|
|
1113
1174
|
*/
|
|
1114
|
-
themes:
|
|
1115
|
-
id:
|
|
1116
|
-
label:
|
|
1117
|
-
path:
|
|
1175
|
+
themes: import_zod5.z.array(import_zod5.z.object({
|
|
1176
|
+
id: import_zod5.z.string(),
|
|
1177
|
+
label: import_zod5.z.string(),
|
|
1178
|
+
path: import_zod5.z.string()
|
|
1118
1179
|
})).optional().describe("Theme contributions"),
|
|
1119
1180
|
/**
|
|
1120
1181
|
* Register Translations.
|
|
1121
1182
|
* Path to translation files (e.g. "locales/en.json").
|
|
1122
1183
|
*/
|
|
1123
|
-
translations:
|
|
1124
|
-
locale:
|
|
1125
|
-
path:
|
|
1184
|
+
translations: import_zod5.z.array(import_zod5.z.object({
|
|
1185
|
+
locale: import_zod5.z.string(),
|
|
1186
|
+
path: import_zod5.z.string()
|
|
1126
1187
|
})).optional().describe("Translation resources"),
|
|
1127
1188
|
/**
|
|
1128
1189
|
* Register Server Actions.
|
|
1129
1190
|
* Invocable functions exposed to Flows or API.
|
|
1130
1191
|
*/
|
|
1131
|
-
actions:
|
|
1132
|
-
name:
|
|
1133
|
-
label:
|
|
1134
|
-
description:
|
|
1135
|
-
input:
|
|
1136
|
-
output:
|
|
1192
|
+
actions: import_zod5.z.array(import_zod5.z.object({
|
|
1193
|
+
name: import_zod5.z.string().describe("Unique action name"),
|
|
1194
|
+
label: import_zod5.z.string().optional(),
|
|
1195
|
+
description: import_zod5.z.string().optional(),
|
|
1196
|
+
input: import_zod5.z.any().optional().describe("Input validation schema"),
|
|
1197
|
+
output: import_zod5.z.any().optional().describe("Output schema")
|
|
1137
1198
|
})).optional().describe("Exposed server actions"),
|
|
1138
1199
|
/**
|
|
1139
1200
|
* Register Storage Drivers.
|
|
1140
1201
|
* Enables connecting to new types of datasources.
|
|
1141
1202
|
*/
|
|
1142
|
-
drivers:
|
|
1143
|
-
id:
|
|
1144
|
-
label:
|
|
1145
|
-
description:
|
|
1203
|
+
drivers: import_zod5.z.array(import_zod5.z.object({
|
|
1204
|
+
id: import_zod5.z.string().describe('Driver unique identifier (e.g. "postgres", "mongo")'),
|
|
1205
|
+
label: import_zod5.z.string().describe("Human readable name"),
|
|
1206
|
+
description: import_zod5.z.string().optional()
|
|
1146
1207
|
})).optional().describe("Driver contributions"),
|
|
1147
1208
|
/**
|
|
1148
1209
|
* Register Custom Field Types.
|
|
1149
1210
|
* Extends the data model with new widget types.
|
|
1150
1211
|
*/
|
|
1151
|
-
fieldTypes:
|
|
1152
|
-
name:
|
|
1153
|
-
label:
|
|
1154
|
-
description:
|
|
1212
|
+
fieldTypes: import_zod5.z.array(import_zod5.z.object({
|
|
1213
|
+
name: import_zod5.z.string().describe('Unique field type name (e.g. "vector")'),
|
|
1214
|
+
label: import_zod5.z.string().describe("Display label"),
|
|
1215
|
+
description: import_zod5.z.string().optional()
|
|
1155
1216
|
})).optional().describe("Field Type contributions"),
|
|
1156
1217
|
/**
|
|
1157
1218
|
* Register Custom Query Operators/Functions.
|
|
1158
1219
|
* Extends ObjectQL with new functions (e.g. distance()).
|
|
1159
1220
|
*/
|
|
1160
|
-
functions:
|
|
1161
|
-
name:
|
|
1162
|
-
description:
|
|
1163
|
-
args:
|
|
1164
|
-
returnType:
|
|
1221
|
+
functions: import_zod5.z.array(import_zod5.z.object({
|
|
1222
|
+
name: import_zod5.z.string().describe('Function name (e.g. "distance")'),
|
|
1223
|
+
description: import_zod5.z.string().optional(),
|
|
1224
|
+
args: import_zod5.z.array(import_zod5.z.string()).optional().describe("Argument types"),
|
|
1225
|
+
returnType: import_zod5.z.string().optional()
|
|
1165
1226
|
})).optional().describe("Query Function contributions")
|
|
1166
1227
|
}).optional().describe("Platform contributions"),
|
|
1167
1228
|
/**
|
|
1168
1229
|
* Initial data seeding configuration.
|
|
1169
1230
|
* Defines default records to be inserted when the package is installed.
|
|
1231
|
+
*
|
|
1232
|
+
* Uses the standard DatasetSchema which supports idempotent upsert via
|
|
1233
|
+
* `externalId`, environment scoping via `env`, and multiple conflict
|
|
1234
|
+
* resolution modes.
|
|
1235
|
+
*
|
|
1236
|
+
* @deprecated Prefer using the top-level `data` field on the Stack Definition
|
|
1237
|
+
* (defineStack({ data: [...] })) for better visibility and metadata registration.
|
|
1238
|
+
* This field is retained for backward compatibility with manifest-only packages.
|
|
1170
1239
|
*/
|
|
1171
|
-
data:
|
|
1172
|
-
object: import_zod4.z.string().describe("Target Object Name"),
|
|
1173
|
-
records: import_zod4.z.array(import_zod4.z.record(import_zod4.z.string(), import_zod4.z.any())).describe("List of records to insert"),
|
|
1174
|
-
mode: import_zod4.z.enum(["upsert", "insert", "ignore"]).default("upsert").describe("Seeding mode")
|
|
1175
|
-
})).optional().describe("Initial seed data"),
|
|
1240
|
+
data: import_zod5.z.array(DatasetSchema).optional().describe("Initial seed data (prefer top-level data field)"),
|
|
1176
1241
|
/**
|
|
1177
1242
|
* Plugin Capability Manifest.
|
|
1178
1243
|
* Declares protocols implemented, interfaces provided, dependencies, and extension points.
|
|
@@ -1183,7 +1248,7 @@ var ManifestSchema = import_zod4.z.object({
|
|
|
1183
1248
|
* Extension points contributed by this package.
|
|
1184
1249
|
* Allows packages to extend UI components, add functionality, etc.
|
|
1185
1250
|
*/
|
|
1186
|
-
extensions:
|
|
1251
|
+
extensions: import_zod5.z.record(import_zod5.z.string(), import_zod5.z.any()).optional().describe("Extension points and contributions"),
|
|
1187
1252
|
/**
|
|
1188
1253
|
* Plugin Loading Configuration.
|
|
1189
1254
|
* Configures how the plugin is loaded, initialized, and managed at runtime.
|
|
@@ -1193,61 +1258,61 @@ var ManifestSchema = import_zod4.z.object({
|
|
|
1193
1258
|
});
|
|
1194
1259
|
|
|
1195
1260
|
// src/hub/composer.zod.ts
|
|
1196
|
-
var DependencyRequirementSchema =
|
|
1197
|
-
id:
|
|
1198
|
-
version:
|
|
1261
|
+
var DependencyRequirementSchema = import_zod6.z.object({
|
|
1262
|
+
id: import_zod6.z.string().describe('Plugin ID (e.g. "com.example.crm")'),
|
|
1263
|
+
version: import_zod6.z.string().default("latest").describe('SemVer range or "latest"'),
|
|
1199
1264
|
/**
|
|
1200
1265
|
* Configuration Overrides
|
|
1201
1266
|
* Tenant-specific settings that override plugin defaults.
|
|
1202
1267
|
* Example: { "currency": "USD", "apiKey": "..." }
|
|
1203
1268
|
*/
|
|
1204
|
-
configuration:
|
|
1269
|
+
configuration: import_zod6.z.record(import_zod6.z.string(), import_zod6.z.any()).optional().describe("Configuration overrides"),
|
|
1205
1270
|
/**
|
|
1206
1271
|
* Feature Flags
|
|
1207
1272
|
* Enable/Disable specific features within the plugin.
|
|
1208
1273
|
*/
|
|
1209
|
-
features:
|
|
1274
|
+
features: import_zod6.z.record(import_zod6.z.string(), import_zod6.z.boolean()).optional().describe("Feature toggles")
|
|
1210
1275
|
});
|
|
1211
|
-
var BillOfMaterialsSchema =
|
|
1212
|
-
tenantId:
|
|
1276
|
+
var BillOfMaterialsSchema = import_zod6.z.object({
|
|
1277
|
+
tenantId: import_zod6.z.string().describe("Target Tenant ID"),
|
|
1213
1278
|
/**
|
|
1214
1279
|
* List of installed plugins/apps.
|
|
1215
1280
|
* implementation order matters (later plugins override earlier ones by default).
|
|
1216
1281
|
*/
|
|
1217
|
-
dependencies:
|
|
1282
|
+
dependencies: import_zod6.z.array(DependencyRequirementSchema).describe("Installed packages"),
|
|
1218
1283
|
/**
|
|
1219
1284
|
* Environment Variables injection.
|
|
1220
1285
|
* Maps abstract keys to secure vault references or concrete values.
|
|
1221
1286
|
*/
|
|
1222
|
-
environment:
|
|
1287
|
+
environment: import_zod6.z.record(import_zod6.z.string(), import_zod6.z.string()).optional(),
|
|
1223
1288
|
/**
|
|
1224
1289
|
* Global Resolution Strategy
|
|
1225
1290
|
* How to handle conflicts when multiple plugins define the same resource.
|
|
1226
1291
|
*/
|
|
1227
|
-
resolutionStrategy:
|
|
1292
|
+
resolutionStrategy: import_zod6.z.enum(["strict", "override", "merge"]).default("override").describe("Conflict resolution strategy (strict=fail, override=last-wins, merge=deep-merge)")
|
|
1228
1293
|
});
|
|
1229
|
-
var ConflictReportSchema =
|
|
1230
|
-
resourceType:
|
|
1231
|
-
resourceId:
|
|
1232
|
-
sources:
|
|
1233
|
-
resolution:
|
|
1234
|
-
severity:
|
|
1294
|
+
var ConflictReportSchema = import_zod6.z.object({
|
|
1295
|
+
resourceType: import_zod6.z.enum(["object", "field", "api", "ui"]).describe("Type of colliding resource"),
|
|
1296
|
+
resourceId: import_zod6.z.string().describe("ID of the resource"),
|
|
1297
|
+
sources: import_zod6.z.array(import_zod6.z.string()).describe("List of plugin IDs defining this resource"),
|
|
1298
|
+
resolution: import_zod6.z.string().describe('How it was resolved (e.g. "com.example.erp won")'),
|
|
1299
|
+
severity: import_zod6.z.enum(["info", "warning", "error"]).describe("Severity of the conflict")
|
|
1235
1300
|
});
|
|
1236
|
-
var ComposerRequestSchema =
|
|
1301
|
+
var ComposerRequestSchema = import_zod6.z.object({
|
|
1237
1302
|
bom: BillOfMaterialsSchema,
|
|
1238
1303
|
/**
|
|
1239
1304
|
* Target Runtime Version
|
|
1240
1305
|
* Ensure generated manifest is compatible with the specific runtime version.
|
|
1241
1306
|
*/
|
|
1242
|
-
runtimeVersion:
|
|
1307
|
+
runtimeVersion: import_zod6.z.string().optional(),
|
|
1243
1308
|
/**
|
|
1244
1309
|
* Dry Run
|
|
1245
1310
|
* If true, generates report but does not persist the manifest.
|
|
1246
1311
|
*/
|
|
1247
|
-
dryRun:
|
|
1312
|
+
dryRun: import_zod6.z.boolean().default(false)
|
|
1248
1313
|
});
|
|
1249
|
-
var ComposerResponseSchema =
|
|
1250
|
-
success:
|
|
1314
|
+
var ComposerResponseSchema = import_zod6.z.object({
|
|
1315
|
+
success: import_zod6.z.boolean(),
|
|
1251
1316
|
/**
|
|
1252
1317
|
* The Holy Grail: The Executable System Manifest.
|
|
1253
1318
|
* This is what the Runtime loads to boot.
|
|
@@ -1257,150 +1322,150 @@ var ComposerResponseSchema = import_zod5.z.object({
|
|
|
1257
1322
|
* Manifest URL
|
|
1258
1323
|
* Presigned URL to download the manifest if stored externally (e.g. Vercel KV/S3).
|
|
1259
1324
|
*/
|
|
1260
|
-
manifestUrl:
|
|
1325
|
+
manifestUrl: import_zod6.z.string().url().optional().describe("Presigned download URL"),
|
|
1261
1326
|
/**
|
|
1262
1327
|
* Compilation Metadata
|
|
1263
1328
|
*/
|
|
1264
|
-
buildId:
|
|
1265
|
-
timestamp:
|
|
1266
|
-
duration:
|
|
1329
|
+
buildId: import_zod6.z.string(),
|
|
1330
|
+
timestamp: import_zod6.z.string().datetime(),
|
|
1331
|
+
duration: import_zod6.z.number().describe("Compilation time in ms"),
|
|
1267
1332
|
/**
|
|
1268
1333
|
* Analysis
|
|
1269
1334
|
*/
|
|
1270
|
-
conflicts:
|
|
1271
|
-
errors:
|
|
1335
|
+
conflicts: import_zod6.z.array(ConflictReportSchema).optional(),
|
|
1336
|
+
errors: import_zod6.z.array(import_zod6.z.string()).optional()
|
|
1272
1337
|
});
|
|
1273
1338
|
|
|
1274
1339
|
// src/hub/marketplace.zod.ts
|
|
1275
|
-
var
|
|
1340
|
+
var import_zod8 = require("zod");
|
|
1276
1341
|
|
|
1277
1342
|
// src/hub/plugin-registry.zod.ts
|
|
1278
|
-
var
|
|
1279
|
-
var PluginVendorSchema =
|
|
1343
|
+
var import_zod7 = require("zod");
|
|
1344
|
+
var PluginVendorSchema = import_zod7.z.object({
|
|
1280
1345
|
/**
|
|
1281
1346
|
* Vendor identifier (reverse domain notation)
|
|
1282
1347
|
* Example: "com.acme", "org.apache", "com.objectstack"
|
|
1283
1348
|
*/
|
|
1284
|
-
id:
|
|
1349
|
+
id: import_zod7.z.string().regex(/^[a-z][a-z0-9]*(\.[a-z][a-z0-9]*)+$/).describe("Vendor identifier (reverse domain)"),
|
|
1285
1350
|
/**
|
|
1286
1351
|
* Vendor display name
|
|
1287
1352
|
*/
|
|
1288
|
-
name:
|
|
1353
|
+
name: import_zod7.z.string(),
|
|
1289
1354
|
/**
|
|
1290
1355
|
* Vendor website
|
|
1291
1356
|
*/
|
|
1292
|
-
website:
|
|
1357
|
+
website: import_zod7.z.string().url().optional(),
|
|
1293
1358
|
/**
|
|
1294
1359
|
* Contact email
|
|
1295
1360
|
*/
|
|
1296
|
-
email:
|
|
1361
|
+
email: import_zod7.z.string().email().optional(),
|
|
1297
1362
|
/**
|
|
1298
1363
|
* Verification status
|
|
1299
1364
|
*/
|
|
1300
|
-
verified:
|
|
1365
|
+
verified: import_zod7.z.boolean().default(false).describe("Whether vendor is verified by ObjectStack"),
|
|
1301
1366
|
/**
|
|
1302
1367
|
* Trust level
|
|
1303
1368
|
*/
|
|
1304
|
-
trustLevel:
|
|
1369
|
+
trustLevel: import_zod7.z.enum(["official", "verified", "community", "unverified"]).default("unverified")
|
|
1305
1370
|
});
|
|
1306
|
-
var PluginQualityMetricsSchema =
|
|
1371
|
+
var PluginQualityMetricsSchema = import_zod7.z.object({
|
|
1307
1372
|
/**
|
|
1308
1373
|
* Test coverage percentage
|
|
1309
1374
|
*/
|
|
1310
|
-
testCoverage:
|
|
1375
|
+
testCoverage: import_zod7.z.number().min(0).max(100).optional(),
|
|
1311
1376
|
/**
|
|
1312
1377
|
* Documentation score (0-100)
|
|
1313
1378
|
*/
|
|
1314
|
-
documentationScore:
|
|
1379
|
+
documentationScore: import_zod7.z.number().min(0).max(100).optional(),
|
|
1315
1380
|
/**
|
|
1316
1381
|
* Code quality score (0-100)
|
|
1317
1382
|
*/
|
|
1318
|
-
codeQuality:
|
|
1383
|
+
codeQuality: import_zod7.z.number().min(0).max(100).optional(),
|
|
1319
1384
|
/**
|
|
1320
1385
|
* Security scan status
|
|
1321
1386
|
*/
|
|
1322
|
-
securityScan:
|
|
1323
|
-
lastScanDate:
|
|
1324
|
-
vulnerabilities:
|
|
1325
|
-
critical:
|
|
1326
|
-
high:
|
|
1327
|
-
medium:
|
|
1328
|
-
low:
|
|
1387
|
+
securityScan: import_zod7.z.object({
|
|
1388
|
+
lastScanDate: import_zod7.z.string().datetime().optional(),
|
|
1389
|
+
vulnerabilities: import_zod7.z.object({
|
|
1390
|
+
critical: import_zod7.z.number().int().min(0).default(0),
|
|
1391
|
+
high: import_zod7.z.number().int().min(0).default(0),
|
|
1392
|
+
medium: import_zod7.z.number().int().min(0).default(0),
|
|
1393
|
+
low: import_zod7.z.number().int().min(0).default(0)
|
|
1329
1394
|
}).optional(),
|
|
1330
|
-
passed:
|
|
1395
|
+
passed: import_zod7.z.boolean().default(false)
|
|
1331
1396
|
}).optional(),
|
|
1332
1397
|
/**
|
|
1333
1398
|
* Conformance test results
|
|
1334
1399
|
*/
|
|
1335
|
-
conformanceTests:
|
|
1336
|
-
protocolId:
|
|
1337
|
-
passed:
|
|
1338
|
-
totalTests:
|
|
1339
|
-
passedTests:
|
|
1340
|
-
lastRunDate:
|
|
1400
|
+
conformanceTests: import_zod7.z.array(import_zod7.z.object({
|
|
1401
|
+
protocolId: import_zod7.z.string().describe("Protocol being tested"),
|
|
1402
|
+
passed: import_zod7.z.boolean(),
|
|
1403
|
+
totalTests: import_zod7.z.number().int().min(0),
|
|
1404
|
+
passedTests: import_zod7.z.number().int().min(0),
|
|
1405
|
+
lastRunDate: import_zod7.z.string().datetime().optional()
|
|
1341
1406
|
})).optional()
|
|
1342
1407
|
});
|
|
1343
|
-
var PluginStatisticsSchema =
|
|
1408
|
+
var PluginStatisticsSchema = import_zod7.z.object({
|
|
1344
1409
|
/**
|
|
1345
1410
|
* Total downloads
|
|
1346
1411
|
*/
|
|
1347
|
-
downloads:
|
|
1412
|
+
downloads: import_zod7.z.number().int().min(0).default(0),
|
|
1348
1413
|
/**
|
|
1349
1414
|
* Downloads in the last 30 days
|
|
1350
1415
|
*/
|
|
1351
|
-
downloadsLastMonth:
|
|
1416
|
+
downloadsLastMonth: import_zod7.z.number().int().min(0).default(0),
|
|
1352
1417
|
/**
|
|
1353
1418
|
* Number of active installations
|
|
1354
1419
|
*/
|
|
1355
|
-
activeInstallations:
|
|
1420
|
+
activeInstallations: import_zod7.z.number().int().min(0).default(0),
|
|
1356
1421
|
/**
|
|
1357
1422
|
* User ratings
|
|
1358
1423
|
*/
|
|
1359
|
-
ratings:
|
|
1360
|
-
average:
|
|
1361
|
-
count:
|
|
1362
|
-
distribution:
|
|
1363
|
-
"5":
|
|
1364
|
-
"4":
|
|
1365
|
-
"3":
|
|
1366
|
-
"2":
|
|
1367
|
-
"1":
|
|
1424
|
+
ratings: import_zod7.z.object({
|
|
1425
|
+
average: import_zod7.z.number().min(0).max(5).default(0),
|
|
1426
|
+
count: import_zod7.z.number().int().min(0).default(0),
|
|
1427
|
+
distribution: import_zod7.z.object({
|
|
1428
|
+
"5": import_zod7.z.number().int().min(0).default(0),
|
|
1429
|
+
"4": import_zod7.z.number().int().min(0).default(0),
|
|
1430
|
+
"3": import_zod7.z.number().int().min(0).default(0),
|
|
1431
|
+
"2": import_zod7.z.number().int().min(0).default(0),
|
|
1432
|
+
"1": import_zod7.z.number().int().min(0).default(0)
|
|
1368
1433
|
}).optional()
|
|
1369
1434
|
}).optional(),
|
|
1370
1435
|
/**
|
|
1371
1436
|
* GitHub stars (if open source)
|
|
1372
1437
|
*/
|
|
1373
|
-
stars:
|
|
1438
|
+
stars: import_zod7.z.number().int().min(0).optional(),
|
|
1374
1439
|
/**
|
|
1375
1440
|
* Number of dependent plugins
|
|
1376
1441
|
*/
|
|
1377
|
-
dependents:
|
|
1442
|
+
dependents: import_zod7.z.number().int().min(0).default(0)
|
|
1378
1443
|
});
|
|
1379
|
-
var PluginRegistryEntrySchema =
|
|
1444
|
+
var PluginRegistryEntrySchema = import_zod7.z.object({
|
|
1380
1445
|
/**
|
|
1381
1446
|
* Plugin identifier (must match manifest.id)
|
|
1382
1447
|
*/
|
|
1383
|
-
id:
|
|
1448
|
+
id: import_zod7.z.string().regex(/^([a-z][a-z0-9]*\.)+[a-z][a-z0-9-]+$/).describe("Plugin identifier (reverse domain notation)"),
|
|
1384
1449
|
/**
|
|
1385
1450
|
* Current version
|
|
1386
1451
|
*/
|
|
1387
|
-
version:
|
|
1452
|
+
version: import_zod7.z.string().regex(/^\d+\.\d+\.\d+$/),
|
|
1388
1453
|
/**
|
|
1389
1454
|
* Plugin display name
|
|
1390
1455
|
*/
|
|
1391
|
-
name:
|
|
1456
|
+
name: import_zod7.z.string(),
|
|
1392
1457
|
/**
|
|
1393
1458
|
* Short description
|
|
1394
1459
|
*/
|
|
1395
|
-
description:
|
|
1460
|
+
description: import_zod7.z.string().optional(),
|
|
1396
1461
|
/**
|
|
1397
1462
|
* Detailed documentation/README
|
|
1398
1463
|
*/
|
|
1399
|
-
readme:
|
|
1464
|
+
readme: import_zod7.z.string().optional(),
|
|
1400
1465
|
/**
|
|
1401
1466
|
* Plugin type/category
|
|
1402
1467
|
*/
|
|
1403
|
-
category:
|
|
1468
|
+
category: import_zod7.z.enum([
|
|
1404
1469
|
"data",
|
|
1405
1470
|
// Data management, storage, databases
|
|
1406
1471
|
"integration",
|
|
@@ -1427,7 +1492,7 @@ var PluginRegistryEntrySchema = import_zod6.z.object({
|
|
|
1427
1492
|
/**
|
|
1428
1493
|
* Tags for categorization
|
|
1429
1494
|
*/
|
|
1430
|
-
tags:
|
|
1495
|
+
tags: import_zod7.z.array(import_zod7.z.string()).optional(),
|
|
1431
1496
|
/**
|
|
1432
1497
|
* Vendor information
|
|
1433
1498
|
*/
|
|
@@ -1439,42 +1504,42 @@ var PluginRegistryEntrySchema = import_zod6.z.object({
|
|
|
1439
1504
|
/**
|
|
1440
1505
|
* Compatibility information
|
|
1441
1506
|
*/
|
|
1442
|
-
compatibility:
|
|
1507
|
+
compatibility: import_zod7.z.object({
|
|
1443
1508
|
/**
|
|
1444
1509
|
* Minimum ObjectStack version required
|
|
1445
1510
|
*/
|
|
1446
|
-
minObjectStackVersion:
|
|
1511
|
+
minObjectStackVersion: import_zod7.z.string().optional(),
|
|
1447
1512
|
/**
|
|
1448
1513
|
* Maximum ObjectStack version supported
|
|
1449
1514
|
*/
|
|
1450
|
-
maxObjectStackVersion:
|
|
1515
|
+
maxObjectStackVersion: import_zod7.z.string().optional(),
|
|
1451
1516
|
/**
|
|
1452
1517
|
* Node.js version requirement
|
|
1453
1518
|
*/
|
|
1454
|
-
nodeVersion:
|
|
1519
|
+
nodeVersion: import_zod7.z.string().optional(),
|
|
1455
1520
|
/**
|
|
1456
1521
|
* Supported platforms
|
|
1457
1522
|
*/
|
|
1458
|
-
platforms:
|
|
1523
|
+
platforms: import_zod7.z.array(import_zod7.z.enum(["linux", "darwin", "win32", "browser"])).optional()
|
|
1459
1524
|
}).optional(),
|
|
1460
1525
|
/**
|
|
1461
1526
|
* Links and resources
|
|
1462
1527
|
*/
|
|
1463
|
-
links:
|
|
1464
|
-
homepage:
|
|
1465
|
-
repository:
|
|
1466
|
-
documentation:
|
|
1467
|
-
bugs:
|
|
1468
|
-
changelog:
|
|
1528
|
+
links: import_zod7.z.object({
|
|
1529
|
+
homepage: import_zod7.z.string().url().optional(),
|
|
1530
|
+
repository: import_zod7.z.string().url().optional(),
|
|
1531
|
+
documentation: import_zod7.z.string().url().optional(),
|
|
1532
|
+
bugs: import_zod7.z.string().url().optional(),
|
|
1533
|
+
changelog: import_zod7.z.string().url().optional()
|
|
1469
1534
|
}).optional(),
|
|
1470
1535
|
/**
|
|
1471
1536
|
* Media assets
|
|
1472
1537
|
*/
|
|
1473
|
-
media:
|
|
1474
|
-
icon:
|
|
1475
|
-
logo:
|
|
1476
|
-
screenshots:
|
|
1477
|
-
video:
|
|
1538
|
+
media: import_zod7.z.object({
|
|
1539
|
+
icon: import_zod7.z.string().url().optional(),
|
|
1540
|
+
logo: import_zod7.z.string().url().optional(),
|
|
1541
|
+
screenshots: import_zod7.z.array(import_zod7.z.string().url()).optional(),
|
|
1542
|
+
video: import_zod7.z.string().url().optional()
|
|
1478
1543
|
}).optional(),
|
|
1479
1544
|
/**
|
|
1480
1545
|
* Quality metrics
|
|
@@ -1487,70 +1552,70 @@ var PluginRegistryEntrySchema = import_zod6.z.object({
|
|
|
1487
1552
|
/**
|
|
1488
1553
|
* License information
|
|
1489
1554
|
*/
|
|
1490
|
-
license:
|
|
1555
|
+
license: import_zod7.z.string().optional().describe("SPDX license identifier"),
|
|
1491
1556
|
/**
|
|
1492
1557
|
* Pricing (if commercial)
|
|
1493
1558
|
*/
|
|
1494
|
-
pricing:
|
|
1495
|
-
model:
|
|
1496
|
-
price:
|
|
1497
|
-
currency:
|
|
1498
|
-
billingPeriod:
|
|
1559
|
+
pricing: import_zod7.z.object({
|
|
1560
|
+
model: import_zod7.z.enum(["free", "freemium", "paid", "enterprise"]),
|
|
1561
|
+
price: import_zod7.z.number().min(0).optional(),
|
|
1562
|
+
currency: import_zod7.z.string().default("USD").optional(),
|
|
1563
|
+
billingPeriod: import_zod7.z.enum(["one-time", "monthly", "yearly"]).optional()
|
|
1499
1564
|
}).optional(),
|
|
1500
1565
|
/**
|
|
1501
1566
|
* Publication dates
|
|
1502
1567
|
*/
|
|
1503
|
-
publishedAt:
|
|
1504
|
-
updatedAt:
|
|
1568
|
+
publishedAt: import_zod7.z.string().datetime().optional(),
|
|
1569
|
+
updatedAt: import_zod7.z.string().datetime().optional(),
|
|
1505
1570
|
/**
|
|
1506
1571
|
* Deprecation status
|
|
1507
1572
|
*/
|
|
1508
|
-
deprecated:
|
|
1509
|
-
deprecationMessage:
|
|
1510
|
-
replacedBy:
|
|
1573
|
+
deprecated: import_zod7.z.boolean().default(false),
|
|
1574
|
+
deprecationMessage: import_zod7.z.string().optional(),
|
|
1575
|
+
replacedBy: import_zod7.z.string().optional().describe("Plugin ID that replaces this one"),
|
|
1511
1576
|
/**
|
|
1512
1577
|
* Feature flags
|
|
1513
1578
|
*/
|
|
1514
|
-
flags:
|
|
1515
|
-
experimental:
|
|
1516
|
-
beta:
|
|
1517
|
-
featured:
|
|
1518
|
-
verified:
|
|
1579
|
+
flags: import_zod7.z.object({
|
|
1580
|
+
experimental: import_zod7.z.boolean().default(false),
|
|
1581
|
+
beta: import_zod7.z.boolean().default(false),
|
|
1582
|
+
featured: import_zod7.z.boolean().default(false),
|
|
1583
|
+
verified: import_zod7.z.boolean().default(false)
|
|
1519
1584
|
}).optional()
|
|
1520
1585
|
});
|
|
1521
|
-
var PluginSearchFiltersSchema =
|
|
1586
|
+
var PluginSearchFiltersSchema = import_zod7.z.object({
|
|
1522
1587
|
/**
|
|
1523
1588
|
* Search query
|
|
1524
1589
|
*/
|
|
1525
|
-
query:
|
|
1590
|
+
query: import_zod7.z.string().optional(),
|
|
1526
1591
|
/**
|
|
1527
1592
|
* Filter by category
|
|
1528
1593
|
*/
|
|
1529
|
-
category:
|
|
1594
|
+
category: import_zod7.z.array(import_zod7.z.string()).optional(),
|
|
1530
1595
|
/**
|
|
1531
1596
|
* Filter by tags
|
|
1532
1597
|
*/
|
|
1533
|
-
tags:
|
|
1598
|
+
tags: import_zod7.z.array(import_zod7.z.string()).optional(),
|
|
1534
1599
|
/**
|
|
1535
1600
|
* Filter by vendor trust level
|
|
1536
1601
|
*/
|
|
1537
|
-
trustLevel:
|
|
1602
|
+
trustLevel: import_zod7.z.array(import_zod7.z.enum(["official", "verified", "community", "unverified"])).optional(),
|
|
1538
1603
|
/**
|
|
1539
1604
|
* Filter by protocols implemented
|
|
1540
1605
|
*/
|
|
1541
|
-
implementsProtocols:
|
|
1606
|
+
implementsProtocols: import_zod7.z.array(import_zod7.z.string()).optional(),
|
|
1542
1607
|
/**
|
|
1543
1608
|
* Filter by pricing model
|
|
1544
1609
|
*/
|
|
1545
|
-
pricingModel:
|
|
1610
|
+
pricingModel: import_zod7.z.array(import_zod7.z.enum(["free", "freemium", "paid", "enterprise"])).optional(),
|
|
1546
1611
|
/**
|
|
1547
1612
|
* Minimum rating
|
|
1548
1613
|
*/
|
|
1549
|
-
minRating:
|
|
1614
|
+
minRating: import_zod7.z.number().min(0).max(5).optional(),
|
|
1550
1615
|
/**
|
|
1551
1616
|
* Sort options
|
|
1552
1617
|
*/
|
|
1553
|
-
sortBy:
|
|
1618
|
+
sortBy: import_zod7.z.enum([
|
|
1554
1619
|
"relevance",
|
|
1555
1620
|
"downloads",
|
|
1556
1621
|
"rating",
|
|
@@ -1560,97 +1625,97 @@ var PluginSearchFiltersSchema = import_zod6.z.object({
|
|
|
1560
1625
|
/**
|
|
1561
1626
|
* Sort order
|
|
1562
1627
|
*/
|
|
1563
|
-
sortOrder:
|
|
1628
|
+
sortOrder: import_zod7.z.enum(["asc", "desc"]).default("desc").optional(),
|
|
1564
1629
|
/**
|
|
1565
1630
|
* Pagination
|
|
1566
1631
|
*/
|
|
1567
|
-
page:
|
|
1568
|
-
limit:
|
|
1632
|
+
page: import_zod7.z.number().int().min(1).default(1).optional(),
|
|
1633
|
+
limit: import_zod7.z.number().int().min(1).max(100).default(20).optional()
|
|
1569
1634
|
});
|
|
1570
|
-
var PluginInstallConfigSchema =
|
|
1635
|
+
var PluginInstallConfigSchema = import_zod7.z.object({
|
|
1571
1636
|
/**
|
|
1572
1637
|
* Plugin identifier to install
|
|
1573
1638
|
*/
|
|
1574
|
-
pluginId:
|
|
1639
|
+
pluginId: import_zod7.z.string(),
|
|
1575
1640
|
/**
|
|
1576
1641
|
* Version to install (supports semver ranges)
|
|
1577
1642
|
*/
|
|
1578
|
-
version:
|
|
1643
|
+
version: import_zod7.z.string().optional().describe("Defaults to latest"),
|
|
1579
1644
|
/**
|
|
1580
1645
|
* Plugin-specific configuration values
|
|
1581
1646
|
*/
|
|
1582
|
-
config:
|
|
1647
|
+
config: import_zod7.z.record(import_zod7.z.string(), import_zod7.z.any()).optional(),
|
|
1583
1648
|
/**
|
|
1584
1649
|
* Whether to auto-update
|
|
1585
1650
|
*/
|
|
1586
|
-
autoUpdate:
|
|
1651
|
+
autoUpdate: import_zod7.z.boolean().default(false).optional(),
|
|
1587
1652
|
/**
|
|
1588
1653
|
* Installation options
|
|
1589
1654
|
*/
|
|
1590
|
-
options:
|
|
1655
|
+
options: import_zod7.z.object({
|
|
1591
1656
|
/**
|
|
1592
1657
|
* Skip dependency installation
|
|
1593
1658
|
*/
|
|
1594
|
-
skipDependencies:
|
|
1659
|
+
skipDependencies: import_zod7.z.boolean().default(false).optional(),
|
|
1595
1660
|
/**
|
|
1596
1661
|
* Force reinstall
|
|
1597
1662
|
*/
|
|
1598
|
-
force:
|
|
1663
|
+
force: import_zod7.z.boolean().default(false).optional(),
|
|
1599
1664
|
/**
|
|
1600
1665
|
* Installation target
|
|
1601
1666
|
*/
|
|
1602
|
-
target:
|
|
1667
|
+
target: import_zod7.z.enum(["system", "space", "user"]).default("space").optional()
|
|
1603
1668
|
}).optional()
|
|
1604
1669
|
});
|
|
1605
1670
|
|
|
1606
1671
|
// src/hub/marketplace.zod.ts
|
|
1607
1672
|
var PluginAuthorSchema = PluginVendorSchema;
|
|
1608
|
-
var PluginPricingSchema =
|
|
1609
|
-
type:
|
|
1610
|
-
currency:
|
|
1611
|
-
amount:
|
|
1612
|
-
interval:
|
|
1613
|
-
trialDays:
|
|
1673
|
+
var PluginPricingSchema = import_zod8.z.object({
|
|
1674
|
+
type: import_zod8.z.enum(["free", "one_time", "recurring"]),
|
|
1675
|
+
currency: import_zod8.z.string().default("USD"),
|
|
1676
|
+
amount: import_zod8.z.number().min(0),
|
|
1677
|
+
interval: import_zod8.z.enum(["month", "year"]).optional().describe("Required if type is recurring"),
|
|
1678
|
+
trialDays: import_zod8.z.number().int().optional()
|
|
1614
1679
|
});
|
|
1615
|
-
var PluginVersionSchema =
|
|
1616
|
-
version:
|
|
1617
|
-
publishedAt:
|
|
1618
|
-
downloadUrl:
|
|
1619
|
-
checksum:
|
|
1620
|
-
engine:
|
|
1621
|
-
node:
|
|
1622
|
-
objectstack:
|
|
1680
|
+
var PluginVersionSchema = import_zod8.z.object({
|
|
1681
|
+
version: import_zod8.z.string().describe("SemVer string (e.g. 1.0.0)"),
|
|
1682
|
+
publishedAt: import_zod8.z.string().datetime().describe("Publication date"),
|
|
1683
|
+
downloadUrl: import_zod8.z.string().url().describe("Archive download URL"),
|
|
1684
|
+
checksum: import_zod8.z.string().optional().describe("Integrity checksum (shasum)"),
|
|
1685
|
+
engine: import_zod8.z.object({
|
|
1686
|
+
node: import_zod8.z.string().optional(),
|
|
1687
|
+
objectstack: import_zod8.z.string().describe("Required ObjectStack kernel version range")
|
|
1623
1688
|
}).optional().describe("Engine compatibility"),
|
|
1624
|
-
dependencies:
|
|
1625
|
-
changeLog:
|
|
1689
|
+
dependencies: import_zod8.z.record(import_zod8.z.string(), import_zod8.z.string()).optional().describe("Runtime plugin dependencies"),
|
|
1690
|
+
changeLog: import_zod8.z.string().optional().describe("Release notes")
|
|
1626
1691
|
});
|
|
1627
|
-
var MarketplacePluginSchema =
|
|
1692
|
+
var MarketplacePluginSchema = import_zod8.z.object({
|
|
1628
1693
|
/**
|
|
1629
1694
|
* Package Identifier
|
|
1630
1695
|
* Usually the NPM package name (e.g. "@steedos/plugin-crm")
|
|
1631
1696
|
*/
|
|
1632
|
-
id:
|
|
1697
|
+
id: import_zod8.z.string(),
|
|
1633
1698
|
/**
|
|
1634
1699
|
* Version History
|
|
1635
1700
|
* Registry of all available versions
|
|
1636
1701
|
*/
|
|
1637
|
-
versions:
|
|
1702
|
+
versions: import_zod8.z.record(import_zod8.z.string(), PluginVersionSchema).optional().describe("Map of versions (1.0.0) -> Details"),
|
|
1638
1703
|
/**
|
|
1639
1704
|
* Display Name
|
|
1640
1705
|
*/
|
|
1641
|
-
label:
|
|
1706
|
+
label: import_zod8.z.string(),
|
|
1642
1707
|
/**
|
|
1643
1708
|
* Short Description
|
|
1644
1709
|
*/
|
|
1645
|
-
description:
|
|
1710
|
+
description: import_zod8.z.string().optional(),
|
|
1646
1711
|
/**
|
|
1647
1712
|
* Detailed README / Documentation content
|
|
1648
1713
|
*/
|
|
1649
|
-
readme:
|
|
1714
|
+
readme: import_zod8.z.string().optional(),
|
|
1650
1715
|
/**
|
|
1651
1716
|
* Latest Version
|
|
1652
1717
|
*/
|
|
1653
|
-
version:
|
|
1718
|
+
version: import_zod8.z.string(),
|
|
1654
1719
|
/**
|
|
1655
1720
|
* Vendor / Publisher
|
|
1656
1721
|
*/
|
|
@@ -1658,8 +1723,8 @@ var MarketplacePluginSchema = import_zod7.z.object({
|
|
|
1658
1723
|
/**
|
|
1659
1724
|
* Categorization
|
|
1660
1725
|
*/
|
|
1661
|
-
tags:
|
|
1662
|
-
category:
|
|
1726
|
+
tags: import_zod8.z.array(import_zod8.z.string()).optional(),
|
|
1727
|
+
category: import_zod8.z.enum([
|
|
1663
1728
|
"app",
|
|
1664
1729
|
"integration",
|
|
1665
1730
|
"theme",
|
|
@@ -1674,29 +1739,29 @@ var MarketplacePluginSchema = import_zod7.z.object({
|
|
|
1674
1739
|
/**
|
|
1675
1740
|
* Assets
|
|
1676
1741
|
*/
|
|
1677
|
-
icon:
|
|
1678
|
-
screenshots:
|
|
1742
|
+
icon: import_zod8.z.string().url().optional(),
|
|
1743
|
+
screenshots: import_zod8.z.array(import_zod8.z.string().url()).optional(),
|
|
1679
1744
|
/**
|
|
1680
1745
|
* Links
|
|
1681
1746
|
*/
|
|
1682
|
-
homepage:
|
|
1683
|
-
repository:
|
|
1684
|
-
bugs:
|
|
1747
|
+
homepage: import_zod8.z.string().url().optional(),
|
|
1748
|
+
repository: import_zod8.z.string().url().optional(),
|
|
1749
|
+
bugs: import_zod8.z.string().url().optional(),
|
|
1685
1750
|
/**
|
|
1686
1751
|
* Statistics
|
|
1687
1752
|
*/
|
|
1688
|
-
downloads:
|
|
1689
|
-
rating:
|
|
1753
|
+
downloads: import_zod8.z.number().int().optional(),
|
|
1754
|
+
rating: import_zod8.z.number().min(0).max(5).optional(),
|
|
1690
1755
|
/**
|
|
1691
1756
|
* Commercial Information
|
|
1692
1757
|
*/
|
|
1693
1758
|
pricing: PluginPricingSchema.optional(),
|
|
1694
|
-
verified:
|
|
1759
|
+
verified: import_zod8.z.boolean().default(false).describe("Is verified maintaned by ObjectStack")
|
|
1695
1760
|
});
|
|
1696
1761
|
|
|
1697
1762
|
// src/hub/registry-config.zod.ts
|
|
1698
|
-
var
|
|
1699
|
-
var RegistrySyncPolicySchema =
|
|
1763
|
+
var import_zod9 = require("zod");
|
|
1764
|
+
var RegistrySyncPolicySchema = import_zod9.z.enum([
|
|
1700
1765
|
"manual",
|
|
1701
1766
|
// Manual synchronization only
|
|
1702
1767
|
"auto",
|
|
@@ -1704,11 +1769,11 @@ var RegistrySyncPolicySchema = import_zod8.z.enum([
|
|
|
1704
1769
|
"proxy"
|
|
1705
1770
|
// Proxy requests to upstream without caching
|
|
1706
1771
|
]).describe("Registry synchronization strategy");
|
|
1707
|
-
var RegistryUpstreamSchema =
|
|
1772
|
+
var RegistryUpstreamSchema = import_zod9.z.object({
|
|
1708
1773
|
/**
|
|
1709
1774
|
* Upstream registry URL
|
|
1710
1775
|
*/
|
|
1711
|
-
url:
|
|
1776
|
+
url: import_zod9.z.string().url().describe("Upstream registry endpoint"),
|
|
1712
1777
|
/**
|
|
1713
1778
|
* Synchronization policy
|
|
1714
1779
|
*/
|
|
@@ -1716,43 +1781,43 @@ var RegistryUpstreamSchema = import_zod8.z.object({
|
|
|
1716
1781
|
/**
|
|
1717
1782
|
* Sync interval in seconds (for auto sync)
|
|
1718
1783
|
*/
|
|
1719
|
-
syncInterval:
|
|
1784
|
+
syncInterval: import_zod9.z.number().int().min(60).optional().describe("Auto-sync interval in seconds"),
|
|
1720
1785
|
/**
|
|
1721
1786
|
* Authentication credentials
|
|
1722
1787
|
*/
|
|
1723
|
-
auth:
|
|
1724
|
-
type:
|
|
1725
|
-
username:
|
|
1726
|
-
password:
|
|
1727
|
-
token:
|
|
1728
|
-
apiKey:
|
|
1788
|
+
auth: import_zod9.z.object({
|
|
1789
|
+
type: import_zod9.z.enum(["none", "basic", "bearer", "api-key", "oauth2"]).default("none"),
|
|
1790
|
+
username: import_zod9.z.string().optional(),
|
|
1791
|
+
password: import_zod9.z.string().optional(),
|
|
1792
|
+
token: import_zod9.z.string().optional(),
|
|
1793
|
+
apiKey: import_zod9.z.string().optional()
|
|
1729
1794
|
}).optional(),
|
|
1730
1795
|
/**
|
|
1731
1796
|
* TLS/SSL configuration
|
|
1732
1797
|
*/
|
|
1733
|
-
tls:
|
|
1734
|
-
enabled:
|
|
1735
|
-
verifyCertificate:
|
|
1736
|
-
certificate:
|
|
1737
|
-
privateKey:
|
|
1798
|
+
tls: import_zod9.z.object({
|
|
1799
|
+
enabled: import_zod9.z.boolean().default(true),
|
|
1800
|
+
verifyCertificate: import_zod9.z.boolean().default(true),
|
|
1801
|
+
certificate: import_zod9.z.string().optional(),
|
|
1802
|
+
privateKey: import_zod9.z.string().optional()
|
|
1738
1803
|
}).optional(),
|
|
1739
1804
|
/**
|
|
1740
1805
|
* Timeout settings
|
|
1741
1806
|
*/
|
|
1742
|
-
timeout:
|
|
1807
|
+
timeout: import_zod9.z.number().int().min(1e3).default(3e4).describe("Request timeout in milliseconds"),
|
|
1743
1808
|
/**
|
|
1744
1809
|
* Retry configuration
|
|
1745
1810
|
*/
|
|
1746
|
-
retry:
|
|
1747
|
-
maxAttempts:
|
|
1748
|
-
backoff:
|
|
1811
|
+
retry: import_zod9.z.object({
|
|
1812
|
+
maxAttempts: import_zod9.z.number().int().min(0).default(3),
|
|
1813
|
+
backoff: import_zod9.z.enum(["fixed", "linear", "exponential"]).default("exponential")
|
|
1749
1814
|
}).optional()
|
|
1750
1815
|
});
|
|
1751
|
-
var RegistryConfigSchema =
|
|
1816
|
+
var RegistryConfigSchema = import_zod9.z.object({
|
|
1752
1817
|
/**
|
|
1753
1818
|
* Registry type
|
|
1754
1819
|
*/
|
|
1755
|
-
type:
|
|
1820
|
+
type: import_zod9.z.enum([
|
|
1756
1821
|
"public",
|
|
1757
1822
|
// Public marketplace (e.g., plugins.objectstack.com)
|
|
1758
1823
|
"private",
|
|
@@ -1763,76 +1828,76 @@ var RegistryConfigSchema = import_zod8.z.object({
|
|
|
1763
1828
|
/**
|
|
1764
1829
|
* Upstream registries (for hybrid/private registries)
|
|
1765
1830
|
*/
|
|
1766
|
-
upstream:
|
|
1831
|
+
upstream: import_zod9.z.array(RegistryUpstreamSchema).optional().describe("Upstream registries to sync from or proxy to"),
|
|
1767
1832
|
/**
|
|
1768
1833
|
* Scopes managed by this registry
|
|
1769
1834
|
*/
|
|
1770
|
-
scope:
|
|
1835
|
+
scope: import_zod9.z.array(import_zod9.z.string()).optional().describe("npm-style scopes managed by this registry (e.g., @my-corp, @enterprise)"),
|
|
1771
1836
|
/**
|
|
1772
1837
|
* Default scope for new plugins
|
|
1773
1838
|
*/
|
|
1774
|
-
defaultScope:
|
|
1839
|
+
defaultScope: import_zod9.z.string().optional().describe("Default scope prefix for new plugins"),
|
|
1775
1840
|
/**
|
|
1776
1841
|
* Registry storage configuration
|
|
1777
1842
|
*/
|
|
1778
|
-
storage:
|
|
1843
|
+
storage: import_zod9.z.object({
|
|
1779
1844
|
/**
|
|
1780
1845
|
* Storage backend type
|
|
1781
1846
|
*/
|
|
1782
|
-
backend:
|
|
1847
|
+
backend: import_zod9.z.enum(["local", "s3", "gcs", "azure-blob", "oss"]).default("local"),
|
|
1783
1848
|
/**
|
|
1784
1849
|
* Storage path or bucket name
|
|
1785
1850
|
*/
|
|
1786
|
-
path:
|
|
1851
|
+
path: import_zod9.z.string().optional(),
|
|
1787
1852
|
/**
|
|
1788
1853
|
* Credentials
|
|
1789
1854
|
*/
|
|
1790
|
-
credentials:
|
|
1855
|
+
credentials: import_zod9.z.record(import_zod9.z.string(), import_zod9.z.any()).optional()
|
|
1791
1856
|
}).optional(),
|
|
1792
1857
|
/**
|
|
1793
1858
|
* Registry visibility
|
|
1794
1859
|
*/
|
|
1795
|
-
visibility:
|
|
1860
|
+
visibility: import_zod9.z.enum(["public", "private", "internal"]).default("private").describe("Who can access this registry"),
|
|
1796
1861
|
/**
|
|
1797
1862
|
* Access control
|
|
1798
1863
|
*/
|
|
1799
|
-
accessControl:
|
|
1864
|
+
accessControl: import_zod9.z.object({
|
|
1800
1865
|
/**
|
|
1801
1866
|
* Require authentication for read
|
|
1802
1867
|
*/
|
|
1803
|
-
requireAuthForRead:
|
|
1868
|
+
requireAuthForRead: import_zod9.z.boolean().default(false),
|
|
1804
1869
|
/**
|
|
1805
1870
|
* Require authentication for write
|
|
1806
1871
|
*/
|
|
1807
|
-
requireAuthForWrite:
|
|
1872
|
+
requireAuthForWrite: import_zod9.z.boolean().default(true),
|
|
1808
1873
|
/**
|
|
1809
1874
|
* Allowed users/teams
|
|
1810
1875
|
*/
|
|
1811
|
-
allowedPrincipals:
|
|
1876
|
+
allowedPrincipals: import_zod9.z.array(import_zod9.z.string()).optional()
|
|
1812
1877
|
}).optional(),
|
|
1813
1878
|
/**
|
|
1814
1879
|
* Caching configuration
|
|
1815
1880
|
*/
|
|
1816
|
-
cache:
|
|
1817
|
-
enabled:
|
|
1818
|
-
ttl:
|
|
1819
|
-
maxSize:
|
|
1881
|
+
cache: import_zod9.z.object({
|
|
1882
|
+
enabled: import_zod9.z.boolean().default(true),
|
|
1883
|
+
ttl: import_zod9.z.number().int().min(0).default(3600).describe("Cache TTL in seconds"),
|
|
1884
|
+
maxSize: import_zod9.z.number().int().optional().describe("Maximum cache size in bytes")
|
|
1820
1885
|
}).optional(),
|
|
1821
1886
|
/**
|
|
1822
1887
|
* Mirroring configuration (for high availability)
|
|
1823
1888
|
*/
|
|
1824
|
-
mirrors:
|
|
1825
|
-
url:
|
|
1826
|
-
priority:
|
|
1889
|
+
mirrors: import_zod9.z.array(import_zod9.z.object({
|
|
1890
|
+
url: import_zod9.z.string().url(),
|
|
1891
|
+
priority: import_zod9.z.number().int().min(1).default(1)
|
|
1827
1892
|
})).optional().describe("Mirror registries for redundancy")
|
|
1828
1893
|
});
|
|
1829
1894
|
|
|
1830
1895
|
// src/hub/space.zod.ts
|
|
1831
|
-
var
|
|
1896
|
+
var import_zod11 = require("zod");
|
|
1832
1897
|
|
|
1833
1898
|
// src/hub/tenant.zod.ts
|
|
1834
|
-
var
|
|
1835
|
-
var TenantIsolationLevel =
|
|
1899
|
+
var import_zod10 = require("zod");
|
|
1900
|
+
var TenantIsolationLevel = import_zod10.z.enum([
|
|
1836
1901
|
"shared_schema",
|
|
1837
1902
|
// Shared DB, shared schema, row-level isolation (most economical)
|
|
1838
1903
|
"isolated_schema",
|
|
@@ -1840,29 +1905,29 @@ var TenantIsolationLevel = import_zod9.z.enum([
|
|
|
1840
1905
|
"isolated_db"
|
|
1841
1906
|
// Separate database per tenant (maximum isolation)
|
|
1842
1907
|
]);
|
|
1843
|
-
var TenantQuotaSchema =
|
|
1908
|
+
var TenantQuotaSchema = import_zod10.z.object({
|
|
1844
1909
|
/**
|
|
1845
1910
|
* Maximum number of users allowed for this tenant
|
|
1846
1911
|
*/
|
|
1847
|
-
maxUsers:
|
|
1912
|
+
maxUsers: import_zod10.z.number().int().positive().optional().describe("Maximum number of users"),
|
|
1848
1913
|
/**
|
|
1849
1914
|
* Maximum storage space in bytes
|
|
1850
1915
|
*/
|
|
1851
|
-
maxStorage:
|
|
1916
|
+
maxStorage: import_zod10.z.number().int().positive().optional().describe("Maximum storage in bytes"),
|
|
1852
1917
|
/**
|
|
1853
1918
|
* API rate limit (requests per minute)
|
|
1854
1919
|
*/
|
|
1855
|
-
apiRateLimit:
|
|
1920
|
+
apiRateLimit: import_zod10.z.number().int().positive().optional().describe("API requests per minute")
|
|
1856
1921
|
});
|
|
1857
|
-
var TenantSchema =
|
|
1922
|
+
var TenantSchema = import_zod10.z.object({
|
|
1858
1923
|
/**
|
|
1859
1924
|
* Unique tenant identifier
|
|
1860
1925
|
*/
|
|
1861
|
-
id:
|
|
1926
|
+
id: import_zod10.z.string().describe("Unique tenant identifier"),
|
|
1862
1927
|
/**
|
|
1863
1928
|
* Tenant display name
|
|
1864
1929
|
*/
|
|
1865
|
-
name:
|
|
1930
|
+
name: import_zod10.z.string().describe("Tenant display name"),
|
|
1866
1931
|
/**
|
|
1867
1932
|
* Data isolation level
|
|
1868
1933
|
*/
|
|
@@ -1870,26 +1935,26 @@ var TenantSchema = import_zod9.z.object({
|
|
|
1870
1935
|
/**
|
|
1871
1936
|
* Custom configuration values
|
|
1872
1937
|
*/
|
|
1873
|
-
customizations:
|
|
1938
|
+
customizations: import_zod10.z.record(import_zod10.z.string(), import_zod10.z.any()).optional().describe("Custom configuration values"),
|
|
1874
1939
|
/**
|
|
1875
1940
|
* Resource quotas
|
|
1876
1941
|
*/
|
|
1877
1942
|
quotas: TenantQuotaSchema.optional()
|
|
1878
1943
|
});
|
|
1879
|
-
var RowLevelIsolationStrategySchema =
|
|
1880
|
-
strategy:
|
|
1944
|
+
var RowLevelIsolationStrategySchema = import_zod10.z.object({
|
|
1945
|
+
strategy: import_zod10.z.literal("shared_schema").describe("Row-level isolation strategy"),
|
|
1881
1946
|
/**
|
|
1882
1947
|
* Database configuration for row-level isolation
|
|
1883
1948
|
*/
|
|
1884
|
-
database:
|
|
1949
|
+
database: import_zod10.z.object({
|
|
1885
1950
|
/**
|
|
1886
1951
|
* Whether to enable Row-Level Security (RLS)
|
|
1887
1952
|
*/
|
|
1888
|
-
enableRLS:
|
|
1953
|
+
enableRLS: import_zod10.z.boolean().default(true).describe("Enable PostgreSQL Row-Level Security"),
|
|
1889
1954
|
/**
|
|
1890
1955
|
* Tenant context setting method
|
|
1891
1956
|
*/
|
|
1892
|
-
contextMethod:
|
|
1957
|
+
contextMethod: import_zod10.z.enum([
|
|
1893
1958
|
"session_variable",
|
|
1894
1959
|
// SET app.current_tenant = 'tenant_123'
|
|
1895
1960
|
"search_path",
|
|
@@ -1900,63 +1965,63 @@ var RowLevelIsolationStrategySchema = import_zod9.z.object({
|
|
|
1900
1965
|
/**
|
|
1901
1966
|
* Session variable name for tenant context
|
|
1902
1967
|
*/
|
|
1903
|
-
contextVariable:
|
|
1968
|
+
contextVariable: import_zod10.z.string().default("app.current_tenant").describe("Session variable name"),
|
|
1904
1969
|
/**
|
|
1905
1970
|
* Whether to validate tenant_id at application level
|
|
1906
1971
|
*/
|
|
1907
|
-
applicationValidation:
|
|
1972
|
+
applicationValidation: import_zod10.z.boolean().default(true).describe("Application-level tenant validation")
|
|
1908
1973
|
}).optional().describe("Database configuration"),
|
|
1909
1974
|
/**
|
|
1910
1975
|
* Performance optimization settings
|
|
1911
1976
|
*/
|
|
1912
|
-
performance:
|
|
1977
|
+
performance: import_zod10.z.object({
|
|
1913
1978
|
/**
|
|
1914
1979
|
* Whether to use partial indexes for tenant_id
|
|
1915
1980
|
*/
|
|
1916
|
-
usePartialIndexes:
|
|
1981
|
+
usePartialIndexes: import_zod10.z.boolean().default(true).describe("Use partial indexes per tenant"),
|
|
1917
1982
|
/**
|
|
1918
1983
|
* Whether to use table partitioning
|
|
1919
1984
|
*/
|
|
1920
|
-
usePartitioning:
|
|
1985
|
+
usePartitioning: import_zod10.z.boolean().default(false).describe("Use table partitioning by tenant_id"),
|
|
1921
1986
|
/**
|
|
1922
1987
|
* Connection pool size per tenant
|
|
1923
1988
|
*/
|
|
1924
|
-
poolSizePerTenant:
|
|
1989
|
+
poolSizePerTenant: import_zod10.z.number().int().positive().optional().describe("Connection pool size per tenant")
|
|
1925
1990
|
}).optional().describe("Performance settings")
|
|
1926
1991
|
});
|
|
1927
|
-
var SchemaLevelIsolationStrategySchema =
|
|
1928
|
-
strategy:
|
|
1992
|
+
var SchemaLevelIsolationStrategySchema = import_zod10.z.object({
|
|
1993
|
+
strategy: import_zod10.z.literal("isolated_schema").describe("Schema-level isolation strategy"),
|
|
1929
1994
|
/**
|
|
1930
1995
|
* Schema configuration
|
|
1931
1996
|
*/
|
|
1932
|
-
schema:
|
|
1997
|
+
schema: import_zod10.z.object({
|
|
1933
1998
|
/**
|
|
1934
1999
|
* Schema naming pattern
|
|
1935
2000
|
* Use {tenant_id} as placeholder (must contain only alphanumeric and underscores)
|
|
1936
2001
|
* The tenant_id will be sanitized before substitution to prevent SQL injection
|
|
1937
2002
|
*/
|
|
1938
|
-
namingPattern:
|
|
2003
|
+
namingPattern: import_zod10.z.string().default("tenant_{tenant_id}").describe("Schema naming pattern"),
|
|
1939
2004
|
/**
|
|
1940
2005
|
* Whether to include public schema in search_path
|
|
1941
2006
|
*/
|
|
1942
|
-
includePublicSchema:
|
|
2007
|
+
includePublicSchema: import_zod10.z.boolean().default(true).describe("Include public schema"),
|
|
1943
2008
|
/**
|
|
1944
2009
|
* Default schema for shared resources
|
|
1945
2010
|
*/
|
|
1946
|
-
sharedSchema:
|
|
2011
|
+
sharedSchema: import_zod10.z.string().default("public").describe("Schema for shared resources"),
|
|
1947
2012
|
/**
|
|
1948
2013
|
* Whether to automatically create schema on tenant creation
|
|
1949
2014
|
*/
|
|
1950
|
-
autoCreateSchema:
|
|
2015
|
+
autoCreateSchema: import_zod10.z.boolean().default(true).describe("Auto-create schema")
|
|
1951
2016
|
}).optional().describe("Schema configuration"),
|
|
1952
2017
|
/**
|
|
1953
2018
|
* Migration configuration
|
|
1954
2019
|
*/
|
|
1955
|
-
migrations:
|
|
2020
|
+
migrations: import_zod10.z.object({
|
|
1956
2021
|
/**
|
|
1957
2022
|
* Migration strategy
|
|
1958
2023
|
*/
|
|
1959
|
-
strategy:
|
|
2024
|
+
strategy: import_zod10.z.enum([
|
|
1960
2025
|
"parallel",
|
|
1961
2026
|
// Run migrations on all schemas in parallel
|
|
1962
2027
|
"sequential",
|
|
@@ -1967,42 +2032,42 @@ var SchemaLevelIsolationStrategySchema = import_zod9.z.object({
|
|
|
1967
2032
|
/**
|
|
1968
2033
|
* Maximum concurrent migrations
|
|
1969
2034
|
*/
|
|
1970
|
-
maxConcurrent:
|
|
2035
|
+
maxConcurrent: import_zod10.z.number().int().positive().default(10).describe("Max concurrent migrations"),
|
|
1971
2036
|
/**
|
|
1972
2037
|
* Whether to rollback on first failure
|
|
1973
2038
|
*/
|
|
1974
|
-
rollbackOnError:
|
|
2039
|
+
rollbackOnError: import_zod10.z.boolean().default(true).describe("Rollback on error")
|
|
1975
2040
|
}).optional().describe("Migration configuration"),
|
|
1976
2041
|
/**
|
|
1977
2042
|
* Performance optimization settings
|
|
1978
2043
|
*/
|
|
1979
|
-
performance:
|
|
2044
|
+
performance: import_zod10.z.object({
|
|
1980
2045
|
/**
|
|
1981
2046
|
* Whether to use connection pooling per schema
|
|
1982
2047
|
*/
|
|
1983
|
-
poolPerSchema:
|
|
2048
|
+
poolPerSchema: import_zod10.z.boolean().default(false).describe("Separate pool per schema"),
|
|
1984
2049
|
/**
|
|
1985
2050
|
* Schema cache TTL in seconds
|
|
1986
2051
|
*/
|
|
1987
|
-
schemaCacheTTL:
|
|
2052
|
+
schemaCacheTTL: import_zod10.z.number().int().positive().default(3600).describe("Schema cache TTL")
|
|
1988
2053
|
}).optional().describe("Performance settings")
|
|
1989
2054
|
});
|
|
1990
|
-
var DatabaseLevelIsolationStrategySchema =
|
|
1991
|
-
strategy:
|
|
2055
|
+
var DatabaseLevelIsolationStrategySchema = import_zod10.z.object({
|
|
2056
|
+
strategy: import_zod10.z.literal("isolated_db").describe("Database-level isolation strategy"),
|
|
1992
2057
|
/**
|
|
1993
2058
|
* Database configuration
|
|
1994
2059
|
*/
|
|
1995
|
-
database:
|
|
2060
|
+
database: import_zod10.z.object({
|
|
1996
2061
|
/**
|
|
1997
2062
|
* Database naming pattern
|
|
1998
2063
|
* Use {tenant_id} as placeholder (must contain only alphanumeric and underscores)
|
|
1999
2064
|
* The tenant_id will be sanitized before substitution to prevent SQL injection
|
|
2000
2065
|
*/
|
|
2001
|
-
namingPattern:
|
|
2066
|
+
namingPattern: import_zod10.z.string().default("tenant_{tenant_id}").describe("Database naming pattern"),
|
|
2002
2067
|
/**
|
|
2003
2068
|
* Database server/cluster assignment strategy
|
|
2004
2069
|
*/
|
|
2005
|
-
serverStrategy:
|
|
2070
|
+
serverStrategy: import_zod10.z.enum([
|
|
2006
2071
|
"shared",
|
|
2007
2072
|
// All tenant databases on same server
|
|
2008
2073
|
"sharded",
|
|
@@ -2013,41 +2078,41 @@ var DatabaseLevelIsolationStrategySchema = import_zod9.z.object({
|
|
|
2013
2078
|
/**
|
|
2014
2079
|
* Whether to use separate credentials per tenant
|
|
2015
2080
|
*/
|
|
2016
|
-
separateCredentials:
|
|
2081
|
+
separateCredentials: import_zod10.z.boolean().default(true).describe("Separate credentials per tenant"),
|
|
2017
2082
|
/**
|
|
2018
2083
|
* Whether to automatically create database on tenant creation
|
|
2019
2084
|
*/
|
|
2020
|
-
autoCreateDatabase:
|
|
2085
|
+
autoCreateDatabase: import_zod10.z.boolean().default(true).describe("Auto-create database")
|
|
2021
2086
|
}).optional().describe("Database configuration"),
|
|
2022
2087
|
/**
|
|
2023
2088
|
* Connection pooling configuration
|
|
2024
2089
|
*/
|
|
2025
|
-
connectionPool:
|
|
2090
|
+
connectionPool: import_zod10.z.object({
|
|
2026
2091
|
/**
|
|
2027
2092
|
* Pool size per tenant database
|
|
2028
2093
|
*/
|
|
2029
|
-
poolSize:
|
|
2094
|
+
poolSize: import_zod10.z.number().int().positive().default(10).describe("Connection pool size"),
|
|
2030
2095
|
/**
|
|
2031
2096
|
* Maximum number of tenant pools to keep active
|
|
2032
2097
|
*/
|
|
2033
|
-
maxActivePools:
|
|
2098
|
+
maxActivePools: import_zod10.z.number().int().positive().default(100).describe("Max active pools"),
|
|
2034
2099
|
/**
|
|
2035
2100
|
* Idle pool timeout in seconds
|
|
2036
2101
|
*/
|
|
2037
|
-
idleTimeout:
|
|
2102
|
+
idleTimeout: import_zod10.z.number().int().positive().default(300).describe("Idle pool timeout"),
|
|
2038
2103
|
/**
|
|
2039
2104
|
* Whether to use connection pooler (PgBouncer, etc.)
|
|
2040
2105
|
*/
|
|
2041
|
-
usePooler:
|
|
2106
|
+
usePooler: import_zod10.z.boolean().default(true).describe("Use connection pooler")
|
|
2042
2107
|
}).optional().describe("Connection pool configuration"),
|
|
2043
2108
|
/**
|
|
2044
2109
|
* Backup and restore configuration
|
|
2045
2110
|
*/
|
|
2046
|
-
backup:
|
|
2111
|
+
backup: import_zod10.z.object({
|
|
2047
2112
|
/**
|
|
2048
2113
|
* Backup strategy per tenant
|
|
2049
2114
|
*/
|
|
2050
|
-
strategy:
|
|
2115
|
+
strategy: import_zod10.z.enum([
|
|
2051
2116
|
"individual",
|
|
2052
2117
|
// Separate backup per tenant
|
|
2053
2118
|
"consolidated",
|
|
@@ -2058,82 +2123,82 @@ var DatabaseLevelIsolationStrategySchema = import_zod9.z.object({
|
|
|
2058
2123
|
/**
|
|
2059
2124
|
* Backup frequency in hours
|
|
2060
2125
|
*/
|
|
2061
|
-
frequencyHours:
|
|
2126
|
+
frequencyHours: import_zod10.z.number().int().positive().default(24).describe("Backup frequency"),
|
|
2062
2127
|
/**
|
|
2063
2128
|
* Retention period in days
|
|
2064
2129
|
*/
|
|
2065
|
-
retentionDays:
|
|
2130
|
+
retentionDays: import_zod10.z.number().int().positive().default(30).describe("Backup retention days")
|
|
2066
2131
|
}).optional().describe("Backup configuration"),
|
|
2067
2132
|
/**
|
|
2068
2133
|
* Encryption configuration
|
|
2069
2134
|
*/
|
|
2070
|
-
encryption:
|
|
2135
|
+
encryption: import_zod10.z.object({
|
|
2071
2136
|
/**
|
|
2072
2137
|
* Whether to use per-tenant encryption keys
|
|
2073
2138
|
*/
|
|
2074
|
-
perTenantKeys:
|
|
2139
|
+
perTenantKeys: import_zod10.z.boolean().default(false).describe("Per-tenant encryption keys"),
|
|
2075
2140
|
/**
|
|
2076
2141
|
* Encryption algorithm
|
|
2077
2142
|
*/
|
|
2078
|
-
algorithm:
|
|
2143
|
+
algorithm: import_zod10.z.string().default("AES-256-GCM").describe("Encryption algorithm"),
|
|
2079
2144
|
/**
|
|
2080
2145
|
* Key management service
|
|
2081
2146
|
*/
|
|
2082
|
-
keyManagement:
|
|
2147
|
+
keyManagement: import_zod10.z.enum(["aws_kms", "azure_key_vault", "gcp_kms", "hashicorp_vault", "custom"]).optional().describe("Key management service")
|
|
2083
2148
|
}).optional().describe("Encryption configuration")
|
|
2084
2149
|
});
|
|
2085
|
-
var TenantIsolationConfigSchema =
|
|
2150
|
+
var TenantIsolationConfigSchema = import_zod10.z.discriminatedUnion("strategy", [
|
|
2086
2151
|
RowLevelIsolationStrategySchema,
|
|
2087
2152
|
SchemaLevelIsolationStrategySchema,
|
|
2088
2153
|
DatabaseLevelIsolationStrategySchema
|
|
2089
2154
|
]);
|
|
2090
|
-
var TenantSecurityPolicySchema =
|
|
2155
|
+
var TenantSecurityPolicySchema = import_zod10.z.object({
|
|
2091
2156
|
/**
|
|
2092
2157
|
* Encryption requirements
|
|
2093
2158
|
*/
|
|
2094
|
-
encryption:
|
|
2159
|
+
encryption: import_zod10.z.object({
|
|
2095
2160
|
/**
|
|
2096
2161
|
* Require encryption at rest
|
|
2097
2162
|
*/
|
|
2098
|
-
atRest:
|
|
2163
|
+
atRest: import_zod10.z.boolean().default(true).describe("Require encryption at rest"),
|
|
2099
2164
|
/**
|
|
2100
2165
|
* Require encryption in transit
|
|
2101
2166
|
*/
|
|
2102
|
-
inTransit:
|
|
2167
|
+
inTransit: import_zod10.z.boolean().default(true).describe("Require encryption in transit"),
|
|
2103
2168
|
/**
|
|
2104
2169
|
* Require field-level encryption for sensitive data
|
|
2105
2170
|
*/
|
|
2106
|
-
fieldLevel:
|
|
2171
|
+
fieldLevel: import_zod10.z.boolean().default(false).describe("Require field-level encryption")
|
|
2107
2172
|
}).optional().describe("Encryption requirements"),
|
|
2108
2173
|
/**
|
|
2109
2174
|
* Access control requirements
|
|
2110
2175
|
*/
|
|
2111
|
-
accessControl:
|
|
2176
|
+
accessControl: import_zod10.z.object({
|
|
2112
2177
|
/**
|
|
2113
2178
|
* Require multi-factor authentication
|
|
2114
2179
|
*/
|
|
2115
|
-
requireMFA:
|
|
2180
|
+
requireMFA: import_zod10.z.boolean().default(false).describe("Require MFA"),
|
|
2116
2181
|
/**
|
|
2117
2182
|
* Require SSO/SAML authentication
|
|
2118
2183
|
*/
|
|
2119
|
-
requireSSO:
|
|
2184
|
+
requireSSO: import_zod10.z.boolean().default(false).describe("Require SSO"),
|
|
2120
2185
|
/**
|
|
2121
2186
|
* IP whitelist
|
|
2122
2187
|
*/
|
|
2123
|
-
ipWhitelist:
|
|
2188
|
+
ipWhitelist: import_zod10.z.array(import_zod10.z.string()).optional().describe("Allowed IP addresses"),
|
|
2124
2189
|
/**
|
|
2125
2190
|
* Session timeout in seconds
|
|
2126
2191
|
*/
|
|
2127
|
-
sessionTimeout:
|
|
2192
|
+
sessionTimeout: import_zod10.z.number().int().positive().default(3600).describe("Session timeout")
|
|
2128
2193
|
}).optional().describe("Access control requirements"),
|
|
2129
2194
|
/**
|
|
2130
2195
|
* Audit and compliance requirements
|
|
2131
2196
|
*/
|
|
2132
|
-
compliance:
|
|
2197
|
+
compliance: import_zod10.z.object({
|
|
2133
2198
|
/**
|
|
2134
2199
|
* Compliance standards to enforce
|
|
2135
2200
|
*/
|
|
2136
|
-
standards:
|
|
2201
|
+
standards: import_zod10.z.array(import_zod10.z.enum([
|
|
2137
2202
|
"sox",
|
|
2138
2203
|
"hipaa",
|
|
2139
2204
|
"gdpr",
|
|
@@ -2144,77 +2209,77 @@ var TenantSecurityPolicySchema = import_zod9.z.object({
|
|
|
2144
2209
|
/**
|
|
2145
2210
|
* Require audit logging for all operations
|
|
2146
2211
|
*/
|
|
2147
|
-
requireAuditLog:
|
|
2212
|
+
requireAuditLog: import_zod10.z.boolean().default(true).describe("Require audit logging"),
|
|
2148
2213
|
/**
|
|
2149
2214
|
* Audit log retention period in days
|
|
2150
2215
|
*/
|
|
2151
|
-
auditRetentionDays:
|
|
2216
|
+
auditRetentionDays: import_zod10.z.number().int().positive().default(365).describe("Audit retention days"),
|
|
2152
2217
|
/**
|
|
2153
2218
|
* Data residency requirements
|
|
2154
2219
|
*/
|
|
2155
|
-
dataResidency:
|
|
2220
|
+
dataResidency: import_zod10.z.object({
|
|
2156
2221
|
/**
|
|
2157
2222
|
* Required geographic region
|
|
2158
2223
|
*/
|
|
2159
|
-
region:
|
|
2224
|
+
region: import_zod10.z.string().optional().describe("Required region (e.g., US, EU, APAC)"),
|
|
2160
2225
|
/**
|
|
2161
2226
|
* Prohibited regions
|
|
2162
2227
|
*/
|
|
2163
|
-
excludeRegions:
|
|
2228
|
+
excludeRegions: import_zod10.z.array(import_zod10.z.string()).optional().describe("Prohibited regions")
|
|
2164
2229
|
}).optional().describe("Data residency requirements")
|
|
2165
2230
|
}).optional().describe("Compliance requirements")
|
|
2166
2231
|
});
|
|
2167
2232
|
|
|
2168
2233
|
// src/hub/space.zod.ts
|
|
2169
|
-
var SubscriptionStatus =
|
|
2234
|
+
var SubscriptionStatus = import_zod11.z.enum([
|
|
2170
2235
|
"active",
|
|
2171
2236
|
"past_due",
|
|
2172
2237
|
"canceled",
|
|
2173
2238
|
"trialing",
|
|
2174
2239
|
"incomplete"
|
|
2175
2240
|
]);
|
|
2176
|
-
var SpaceSubscriptionSchema =
|
|
2177
|
-
planId:
|
|
2241
|
+
var SpaceSubscriptionSchema = import_zod11.z.object({
|
|
2242
|
+
planId: import_zod11.z.string().describe("Reference to Plan Code"),
|
|
2178
2243
|
status: SubscriptionStatus,
|
|
2179
|
-
currentPeriodEnd:
|
|
2180
|
-
stripeCustomerId:
|
|
2181
|
-
stripeSubscriptionId:
|
|
2244
|
+
currentPeriodEnd: import_zod11.z.string().datetime().optional(),
|
|
2245
|
+
stripeCustomerId: import_zod11.z.string().optional(),
|
|
2246
|
+
stripeSubscriptionId: import_zod11.z.string().optional(),
|
|
2182
2247
|
/**
|
|
2183
2248
|
* Purchased Add-ons from Marketplace
|
|
2184
2249
|
*/
|
|
2185
|
-
addons:
|
|
2186
|
-
pluginId:
|
|
2187
|
-
quantity:
|
|
2250
|
+
addons: import_zod11.z.array(import_zod11.z.object({
|
|
2251
|
+
pluginId: import_zod11.z.string().describe("Marketplace Plugin ID (NPM package name)"),
|
|
2252
|
+
quantity: import_zod11.z.number().default(1),
|
|
2188
2253
|
status: SubscriptionStatus.default("active")
|
|
2189
2254
|
})).optional(),
|
|
2190
2255
|
/**
|
|
2191
2256
|
* Quota Usage Snapshot
|
|
2192
2257
|
* Cached usage metrics for quick display/validation.
|
|
2193
2258
|
*/
|
|
2194
|
-
usage:
|
|
2259
|
+
usage: import_zod11.z.record(import_zod11.z.string(), import_zod11.z.number()).optional()
|
|
2195
2260
|
});
|
|
2196
|
-
var DeploymentTargetSchema =
|
|
2197
|
-
provider:
|
|
2198
|
-
region:
|
|
2199
|
-
url:
|
|
2200
|
-
env:
|
|
2261
|
+
var DeploymentTargetSchema = import_zod11.z.object({
|
|
2262
|
+
provider: import_zod11.z.enum(["vercel", "docker", "kubernetes"]),
|
|
2263
|
+
region: import_zod11.z.string().optional(),
|
|
2264
|
+
url: import_zod11.z.string().url().optional().describe("Public Access URL"),
|
|
2265
|
+
env: import_zod11.z.record(import_zod11.z.string(), import_zod11.z.string()).optional().describe("Runtime Environment Variables")
|
|
2201
2266
|
});
|
|
2202
|
-
var HubSpaceSchema =
|
|
2203
|
-
id:
|
|
2267
|
+
var HubSpaceSchema = import_zod11.z.object({
|
|
2268
|
+
id: import_zod11.z.string().uuid(),
|
|
2204
2269
|
/**
|
|
2205
2270
|
* Display Name
|
|
2206
2271
|
*/
|
|
2207
|
-
name:
|
|
2208
|
-
slug:
|
|
2272
|
+
name: import_zod11.z.string(),
|
|
2273
|
+
slug: import_zod11.z.string().describe("URL friendly identifier"),
|
|
2209
2274
|
/**
|
|
2210
2275
|
* Owner (User or Org ID in Hub)
|
|
2211
2276
|
*/
|
|
2212
|
-
ownerId:
|
|
2277
|
+
ownerId: import_zod11.z.string(),
|
|
2213
2278
|
/**
|
|
2214
2279
|
* The Runtime Instance Definition
|
|
2215
2280
|
* Defines the technical execution environment.
|
|
2216
2281
|
*/
|
|
2217
|
-
runtime:
|
|
2282
|
+
runtime: import_zod11.z.object({
|
|
2218
2283
|
isolation: TenantIsolationLevel.describe("Data isolation strategy"),
|
|
2219
2284
|
quotas: TenantQuotaSchema.optional().describe("Resource quotas")
|
|
2220
2285
|
}).optional().describe("Runtime instance configuration"),
|
|
@@ -2226,11 +2291,11 @@ var HubSpaceSchema = import_zod10.z.object({
|
|
|
2226
2291
|
/**
|
|
2227
2292
|
* The Current Actual State (Last Successful Build)
|
|
2228
2293
|
*/
|
|
2229
|
-
lastBuild:
|
|
2230
|
-
id:
|
|
2231
|
-
timestamp:
|
|
2232
|
-
manifestUrl:
|
|
2233
|
-
status:
|
|
2294
|
+
lastBuild: import_zod11.z.object({
|
|
2295
|
+
id: import_zod11.z.string(),
|
|
2296
|
+
timestamp: import_zod11.z.string().datetime(),
|
|
2297
|
+
manifestUrl: import_zod11.z.string().url().optional(),
|
|
2298
|
+
status: import_zod11.z.enum(["pending", "success", "failed"])
|
|
2234
2299
|
}).optional(),
|
|
2235
2300
|
/**
|
|
2236
2301
|
* Commercial / Billing Info
|
|
@@ -2240,13 +2305,13 @@ var HubSpaceSchema = import_zod10.z.object({
|
|
|
2240
2305
|
* Infrastructure Settings
|
|
2241
2306
|
*/
|
|
2242
2307
|
deployment: DeploymentTargetSchema.optional(),
|
|
2243
|
-
createdAt:
|
|
2244
|
-
updatedAt:
|
|
2308
|
+
createdAt: import_zod11.z.string(),
|
|
2309
|
+
updatedAt: import_zod11.z.string()
|
|
2245
2310
|
});
|
|
2246
2311
|
|
|
2247
2312
|
// src/hub/license.zod.ts
|
|
2248
|
-
var
|
|
2249
|
-
var MetricType =
|
|
2313
|
+
var import_zod12 = require("zod");
|
|
2314
|
+
var MetricType = import_zod12.z.enum([
|
|
2250
2315
|
"boolean",
|
|
2251
2316
|
// Feature Flag (Enabled/Disabled)
|
|
2252
2317
|
"counter",
|
|
@@ -2254,115 +2319,115 @@ var MetricType = import_zod11.z.enum([
|
|
|
2254
2319
|
"gauge"
|
|
2255
2320
|
// Current Level (e.g. Storage Used, Users Active) - Point in time
|
|
2256
2321
|
]);
|
|
2257
|
-
var FeatureSchema =
|
|
2258
|
-
code:
|
|
2259
|
-
label:
|
|
2260
|
-
description:
|
|
2322
|
+
var FeatureSchema = import_zod12.z.object({
|
|
2323
|
+
code: import_zod12.z.string().regex(/^[a-z_][a-z0-9_.]*$/).describe("Feature code (e.g. core.api_access)"),
|
|
2324
|
+
label: import_zod12.z.string(),
|
|
2325
|
+
description: import_zod12.z.string().optional(),
|
|
2261
2326
|
type: MetricType.default("boolean"),
|
|
2262
2327
|
/** For counters/gauges */
|
|
2263
|
-
unit:
|
|
2328
|
+
unit: import_zod12.z.enum(["count", "bytes", "seconds", "percent"]).optional(),
|
|
2264
2329
|
/** Dependencies (e.g. 'audit_log' requires 'enterprise_tier') */
|
|
2265
|
-
requires:
|
|
2330
|
+
requires: import_zod12.z.array(import_zod12.z.string()).optional()
|
|
2266
2331
|
});
|
|
2267
|
-
var PlanSchema =
|
|
2268
|
-
code:
|
|
2269
|
-
label:
|
|
2270
|
-
active:
|
|
2332
|
+
var PlanSchema = import_zod12.z.object({
|
|
2333
|
+
code: import_zod12.z.string().describe("Plan code (e.g. pro_v1)"),
|
|
2334
|
+
label: import_zod12.z.string(),
|
|
2335
|
+
active: import_zod12.z.boolean().default(true),
|
|
2271
2336
|
/** Feature Entitlements */
|
|
2272
|
-
features:
|
|
2337
|
+
features: import_zod12.z.array(import_zod12.z.string()).describe("List of enabled boolean features"),
|
|
2273
2338
|
/** Limit Quotas */
|
|
2274
|
-
limits:
|
|
2339
|
+
limits: import_zod12.z.record(import_zod12.z.string(), import_zod12.z.number()).describe("Map of metric codes to limit values (e.g. { storage_gb: 10 })"),
|
|
2275
2340
|
/** Pricing (Optional Metadata) */
|
|
2276
|
-
currency:
|
|
2277
|
-
priceMonthly:
|
|
2278
|
-
priceYearly:
|
|
2341
|
+
currency: import_zod12.z.string().default("USD").optional(),
|
|
2342
|
+
priceMonthly: import_zod12.z.number().optional(),
|
|
2343
|
+
priceYearly: import_zod12.z.number().optional()
|
|
2279
2344
|
});
|
|
2280
|
-
var LicenseSchema =
|
|
2345
|
+
var LicenseSchema = import_zod12.z.object({
|
|
2281
2346
|
/** Identity */
|
|
2282
|
-
spaceId:
|
|
2283
|
-
planCode:
|
|
2347
|
+
spaceId: import_zod12.z.string().describe("Target Space ID"),
|
|
2348
|
+
planCode: import_zod12.z.string(),
|
|
2284
2349
|
/** Validity */
|
|
2285
|
-
issuedAt:
|
|
2286
|
-
expiresAt:
|
|
2350
|
+
issuedAt: import_zod12.z.string().datetime(),
|
|
2351
|
+
expiresAt: import_zod12.z.string().datetime().optional(),
|
|
2287
2352
|
// Null = Perpetual
|
|
2288
2353
|
/** Status */
|
|
2289
|
-
status:
|
|
2354
|
+
status: import_zod12.z.enum(["active", "expired", "suspended", "trial"]),
|
|
2290
2355
|
/** Overrides (Specific to this space, exceeding the plan) */
|
|
2291
|
-
customFeatures:
|
|
2292
|
-
customLimits:
|
|
2356
|
+
customFeatures: import_zod12.z.array(import_zod12.z.string()).optional(),
|
|
2357
|
+
customLimits: import_zod12.z.record(import_zod12.z.string(), import_zod12.z.number()).optional(),
|
|
2293
2358
|
/** Authorized Add-ons */
|
|
2294
|
-
plugins:
|
|
2359
|
+
plugins: import_zod12.z.array(import_zod12.z.string()).optional().describe("List of enabled plugin package IDs"),
|
|
2295
2360
|
/** Signature */
|
|
2296
|
-
signature:
|
|
2361
|
+
signature: import_zod12.z.string().optional().describe("Cryptographic signature of the license")
|
|
2297
2362
|
});
|
|
2298
2363
|
|
|
2299
2364
|
// src/hub/hub-federation.zod.ts
|
|
2300
|
-
var
|
|
2301
|
-
var RegionSchema =
|
|
2365
|
+
var import_zod13 = require("zod");
|
|
2366
|
+
var RegionSchema = import_zod13.z.object({
|
|
2302
2367
|
/**
|
|
2303
2368
|
* Region identifier (e.g., us-east-1, eu-west-1, ap-southeast-1)
|
|
2304
2369
|
*/
|
|
2305
|
-
id:
|
|
2370
|
+
id: import_zod13.z.string().regex(/^[a-z]{2}-[a-z]+-\d+$/).describe("Region identifier"),
|
|
2306
2371
|
/**
|
|
2307
2372
|
* Display name
|
|
2308
2373
|
*/
|
|
2309
|
-
name:
|
|
2374
|
+
name: import_zod13.z.string().describe("Human-readable region name"),
|
|
2310
2375
|
/**
|
|
2311
2376
|
* Geographic location
|
|
2312
2377
|
*/
|
|
2313
|
-
location:
|
|
2314
|
-
continent:
|
|
2315
|
-
country:
|
|
2316
|
-
city:
|
|
2317
|
-
latitude:
|
|
2318
|
-
longitude:
|
|
2378
|
+
location: import_zod13.z.object({
|
|
2379
|
+
continent: import_zod13.z.enum(["NA", "SA", "EU", "AF", "AS", "OC", "AN"]),
|
|
2380
|
+
country: import_zod13.z.string().regex(/^[A-Z]{2}$/).describe("ISO 3166-1 alpha-2 country code"),
|
|
2381
|
+
city: import_zod13.z.string().optional(),
|
|
2382
|
+
latitude: import_zod13.z.number().min(-90).max(90).optional(),
|
|
2383
|
+
longitude: import_zod13.z.number().min(-180).max(180).optional()
|
|
2319
2384
|
}),
|
|
2320
2385
|
/**
|
|
2321
2386
|
* Cloud provider and region mapping
|
|
2322
2387
|
*/
|
|
2323
|
-
provider:
|
|
2324
|
-
name:
|
|
2325
|
-
region:
|
|
2388
|
+
provider: import_zod13.z.object({
|
|
2389
|
+
name: import_zod13.z.enum(["aws", "azure", "gcp", "cloudflare", "vercel", "self-hosted"]),
|
|
2390
|
+
region: import_zod13.z.string().describe("Provider-specific region identifier")
|
|
2326
2391
|
}).optional(),
|
|
2327
2392
|
/**
|
|
2328
2393
|
* Region capabilities
|
|
2329
2394
|
*/
|
|
2330
|
-
capabilities:
|
|
2331
|
-
databases:
|
|
2332
|
-
storage:
|
|
2333
|
-
compute:
|
|
2334
|
-
cdn:
|
|
2395
|
+
capabilities: import_zod13.z.object({
|
|
2396
|
+
databases: import_zod13.z.array(import_zod13.z.enum(["postgres", "mysql", "mongodb", "redis"])).default([]),
|
|
2397
|
+
storage: import_zod13.z.array(import_zod13.z.enum(["s3", "azure-blob", "gcs"])).default([]),
|
|
2398
|
+
compute: import_zod13.z.array(import_zod13.z.enum(["containers", "serverless", "vm"])).default([]),
|
|
2399
|
+
cdn: import_zod13.z.boolean().default(false)
|
|
2335
2400
|
}).optional(),
|
|
2336
2401
|
/**
|
|
2337
2402
|
* Compliance and certifications
|
|
2338
2403
|
*/
|
|
2339
|
-
compliance:
|
|
2404
|
+
compliance: import_zod13.z.array(import_zod13.z.enum(["gdpr", "hipaa", "soc2", "iso27001", "pci-dss"])).default([]),
|
|
2340
2405
|
/**
|
|
2341
2406
|
* Region status
|
|
2342
2407
|
*/
|
|
2343
|
-
status:
|
|
2408
|
+
status: import_zod13.z.enum(["active", "read-only", "maintenance", "deprecated"]).default("active"),
|
|
2344
2409
|
/**
|
|
2345
2410
|
* Resource limits for this region
|
|
2346
2411
|
*/
|
|
2347
|
-
limits:
|
|
2348
|
-
maxSpaces:
|
|
2349
|
-
maxTenants:
|
|
2350
|
-
maxStorage:
|
|
2412
|
+
limits: import_zod13.z.object({
|
|
2413
|
+
maxSpaces: import_zod13.z.number().int().positive().optional(),
|
|
2414
|
+
maxTenants: import_zod13.z.number().int().positive().optional(),
|
|
2415
|
+
maxStorage: import_zod13.z.number().int().positive().optional().describe("Bytes")
|
|
2351
2416
|
}).optional()
|
|
2352
2417
|
});
|
|
2353
|
-
var HubInstanceSchema =
|
|
2418
|
+
var HubInstanceSchema = import_zod13.z.object({
|
|
2354
2419
|
/**
|
|
2355
2420
|
* Instance identifier
|
|
2356
2421
|
*/
|
|
2357
|
-
id:
|
|
2422
|
+
id: import_zod13.z.string().uuid(),
|
|
2358
2423
|
/**
|
|
2359
2424
|
* Region where this hub is deployed
|
|
2360
2425
|
*/
|
|
2361
|
-
regionId:
|
|
2426
|
+
regionId: import_zod13.z.string(),
|
|
2362
2427
|
/**
|
|
2363
2428
|
* Hub role in federation
|
|
2364
2429
|
*/
|
|
2365
|
-
role:
|
|
2430
|
+
role: import_zod13.z.enum([
|
|
2366
2431
|
"primary",
|
|
2367
2432
|
// Primary/master hub
|
|
2368
2433
|
"secondary",
|
|
@@ -2373,71 +2438,71 @@ var HubInstanceSchema = import_zod12.z.object({
|
|
|
2373
2438
|
/**
|
|
2374
2439
|
* Endpoint URLs
|
|
2375
2440
|
*/
|
|
2376
|
-
endpoints:
|
|
2377
|
-
api:
|
|
2378
|
-
admin:
|
|
2379
|
-
grpc:
|
|
2441
|
+
endpoints: import_zod13.z.object({
|
|
2442
|
+
api: import_zod13.z.string().url().describe("Public API endpoint"),
|
|
2443
|
+
admin: import_zod13.z.string().url().optional().describe("Admin console"),
|
|
2444
|
+
grpc: import_zod13.z.string().optional().describe("gRPC endpoint for inter-hub communication")
|
|
2380
2445
|
}),
|
|
2381
2446
|
/**
|
|
2382
2447
|
* Replication configuration
|
|
2383
2448
|
*/
|
|
2384
|
-
replication:
|
|
2449
|
+
replication: import_zod13.z.object({
|
|
2385
2450
|
/**
|
|
2386
2451
|
* Source hub for replication (if this is a secondary)
|
|
2387
2452
|
*/
|
|
2388
|
-
primaryHubId:
|
|
2453
|
+
primaryHubId: import_zod13.z.string().uuid().optional(),
|
|
2389
2454
|
/**
|
|
2390
2455
|
* Replication lag tolerance in seconds
|
|
2391
2456
|
*/
|
|
2392
|
-
lagTolerance:
|
|
2457
|
+
lagTolerance: import_zod13.z.number().int().positive().default(5),
|
|
2393
2458
|
/**
|
|
2394
2459
|
* Replication mode
|
|
2395
2460
|
*/
|
|
2396
|
-
mode:
|
|
2461
|
+
mode: import_zod13.z.enum(["sync", "async", "semi-sync"]).default("async")
|
|
2397
2462
|
}).optional(),
|
|
2398
2463
|
/**
|
|
2399
2464
|
* Health status
|
|
2400
2465
|
*/
|
|
2401
|
-
health:
|
|
2402
|
-
status:
|
|
2403
|
-
lastCheck:
|
|
2404
|
-
uptime:
|
|
2466
|
+
health: import_zod13.z.object({
|
|
2467
|
+
status: import_zod13.z.enum(["healthy", "degraded", "unhealthy"]),
|
|
2468
|
+
lastCheck: import_zod13.z.string().datetime(),
|
|
2469
|
+
uptime: import_zod13.z.number().describe("Seconds")
|
|
2405
2470
|
}).optional(),
|
|
2406
2471
|
/**
|
|
2407
2472
|
* Version
|
|
2408
2473
|
*/
|
|
2409
|
-
version:
|
|
2474
|
+
version: import_zod13.z.string(),
|
|
2410
2475
|
/**
|
|
2411
2476
|
* Metadata
|
|
2412
2477
|
*/
|
|
2413
|
-
createdAt:
|
|
2414
|
-
updatedAt:
|
|
2478
|
+
createdAt: import_zod13.z.string().datetime(),
|
|
2479
|
+
updatedAt: import_zod13.z.string().datetime()
|
|
2415
2480
|
});
|
|
2416
|
-
var FederationTopologySchema =
|
|
2481
|
+
var FederationTopologySchema = import_zod13.z.object({
|
|
2417
2482
|
/**
|
|
2418
2483
|
* Federation identifier
|
|
2419
2484
|
*/
|
|
2420
|
-
id:
|
|
2485
|
+
id: import_zod13.z.string().uuid(),
|
|
2421
2486
|
/**
|
|
2422
2487
|
* Federation name
|
|
2423
2488
|
*/
|
|
2424
|
-
name:
|
|
2489
|
+
name: import_zod13.z.string(),
|
|
2425
2490
|
/**
|
|
2426
2491
|
* Regions in this federation
|
|
2427
2492
|
*/
|
|
2428
|
-
regions:
|
|
2493
|
+
regions: import_zod13.z.array(RegionSchema),
|
|
2429
2494
|
/**
|
|
2430
2495
|
* Hub instances
|
|
2431
2496
|
*/
|
|
2432
|
-
hubs:
|
|
2497
|
+
hubs: import_zod13.z.array(HubInstanceSchema),
|
|
2433
2498
|
/**
|
|
2434
2499
|
* Routing strategy
|
|
2435
2500
|
*/
|
|
2436
|
-
routing:
|
|
2501
|
+
routing: import_zod13.z.object({
|
|
2437
2502
|
/**
|
|
2438
2503
|
* How to route tenant requests
|
|
2439
2504
|
*/
|
|
2440
|
-
strategy:
|
|
2505
|
+
strategy: import_zod13.z.enum([
|
|
2441
2506
|
"geo-proximity",
|
|
2442
2507
|
// Route to nearest region
|
|
2443
2508
|
"data-residency",
|
|
@@ -2450,117 +2515,117 @@ var FederationTopologySchema = import_zod12.z.object({
|
|
|
2450
2515
|
/**
|
|
2451
2516
|
* Failover behavior
|
|
2452
2517
|
*/
|
|
2453
|
-
failover:
|
|
2454
|
-
enabled:
|
|
2455
|
-
maxRetries:
|
|
2456
|
-
timeout:
|
|
2518
|
+
failover: import_zod13.z.object({
|
|
2519
|
+
enabled: import_zod13.z.boolean().default(true),
|
|
2520
|
+
maxRetries: import_zod13.z.number().int().min(0).default(3),
|
|
2521
|
+
timeout: import_zod13.z.number().int().positive().default(5e3).describe("Milliseconds")
|
|
2457
2522
|
})
|
|
2458
2523
|
}),
|
|
2459
2524
|
/**
|
|
2460
2525
|
* Data synchronization settings
|
|
2461
2526
|
*/
|
|
2462
|
-
synchronization:
|
|
2527
|
+
synchronization: import_zod13.z.object({
|
|
2463
2528
|
/**
|
|
2464
2529
|
* What data to sync across regions
|
|
2465
2530
|
*/
|
|
2466
|
-
scope:
|
|
2531
|
+
scope: import_zod13.z.object({
|
|
2467
2532
|
/**
|
|
2468
2533
|
* Sync plugin registry
|
|
2469
2534
|
*/
|
|
2470
|
-
plugins:
|
|
2535
|
+
plugins: import_zod13.z.boolean().default(true),
|
|
2471
2536
|
/**
|
|
2472
2537
|
* Sync tenant metadata (not data)
|
|
2473
2538
|
*/
|
|
2474
|
-
tenants:
|
|
2539
|
+
tenants: import_zod13.z.boolean().default(true),
|
|
2475
2540
|
/**
|
|
2476
2541
|
* Sync spaces metadata
|
|
2477
2542
|
*/
|
|
2478
|
-
spaces:
|
|
2543
|
+
spaces: import_zod13.z.boolean().default(false),
|
|
2479
2544
|
/**
|
|
2480
2545
|
* Sync licenses
|
|
2481
2546
|
*/
|
|
2482
|
-
licenses:
|
|
2547
|
+
licenses: import_zod13.z.boolean().default(true)
|
|
2483
2548
|
}),
|
|
2484
2549
|
/**
|
|
2485
2550
|
* Sync frequency
|
|
2486
2551
|
*/
|
|
2487
|
-
frequency:
|
|
2552
|
+
frequency: import_zod13.z.enum(["realtime", "hourly", "daily"]).default("realtime"),
|
|
2488
2553
|
/**
|
|
2489
2554
|
* Conflict resolution
|
|
2490
2555
|
*/
|
|
2491
|
-
conflictResolution:
|
|
2556
|
+
conflictResolution: import_zod13.z.enum(["last-write-wins", "primary-wins", "manual"]).default("last-write-wins")
|
|
2492
2557
|
})
|
|
2493
2558
|
});
|
|
2494
|
-
var TenantPlacementPolicySchema =
|
|
2559
|
+
var TenantPlacementPolicySchema = import_zod13.z.object({
|
|
2495
2560
|
/**
|
|
2496
2561
|
* Tenant identifier
|
|
2497
2562
|
*/
|
|
2498
|
-
tenantId:
|
|
2563
|
+
tenantId: import_zod13.z.string(),
|
|
2499
2564
|
/**
|
|
2500
2565
|
* Primary region (where tenant data lives)
|
|
2501
2566
|
*/
|
|
2502
|
-
primaryRegion:
|
|
2567
|
+
primaryRegion: import_zod13.z.string(),
|
|
2503
2568
|
/**
|
|
2504
2569
|
* Replica regions (for disaster recovery)
|
|
2505
2570
|
*/
|
|
2506
|
-
replicaRegions:
|
|
2571
|
+
replicaRegions: import_zod13.z.array(import_zod13.z.string()).default([]),
|
|
2507
2572
|
/**
|
|
2508
2573
|
* Data residency constraints
|
|
2509
2574
|
*/
|
|
2510
|
-
dataResidency:
|
|
2575
|
+
dataResidency: import_zod13.z.object({
|
|
2511
2576
|
/**
|
|
2512
2577
|
* Allowed regions for data storage
|
|
2513
2578
|
*/
|
|
2514
|
-
allowedRegions:
|
|
2579
|
+
allowedRegions: import_zod13.z.array(import_zod13.z.string()).optional(),
|
|
2515
2580
|
/**
|
|
2516
2581
|
* Prohibited regions
|
|
2517
2582
|
*/
|
|
2518
|
-
prohibitedRegions:
|
|
2583
|
+
prohibitedRegions: import_zod13.z.array(import_zod13.z.string()).default([]),
|
|
2519
2584
|
/**
|
|
2520
2585
|
* Continent restriction
|
|
2521
2586
|
*/
|
|
2522
|
-
continent:
|
|
2587
|
+
continent: import_zod13.z.enum(["NA", "SA", "EU", "AF", "AS", "OC", "AN"]).optional()
|
|
2523
2588
|
}).optional(),
|
|
2524
2589
|
/**
|
|
2525
2590
|
* Failover policy
|
|
2526
2591
|
*/
|
|
2527
|
-
failover:
|
|
2592
|
+
failover: import_zod13.z.object({
|
|
2528
2593
|
/**
|
|
2529
2594
|
* Enable automatic failover
|
|
2530
2595
|
*/
|
|
2531
|
-
enabled:
|
|
2596
|
+
enabled: import_zod13.z.boolean().default(true),
|
|
2532
2597
|
/**
|
|
2533
2598
|
* Preferred failover order (region IDs)
|
|
2534
2599
|
*/
|
|
2535
|
-
preferredOrder:
|
|
2600
|
+
preferredOrder: import_zod13.z.array(import_zod13.z.string()).default([]),
|
|
2536
2601
|
/**
|
|
2537
2602
|
* Maximum acceptable latency for failover target (ms)
|
|
2538
2603
|
*/
|
|
2539
|
-
maxLatency:
|
|
2604
|
+
maxLatency: import_zod13.z.number().int().positive().default(100)
|
|
2540
2605
|
}).optional(),
|
|
2541
2606
|
/**
|
|
2542
2607
|
* Latency requirements
|
|
2543
2608
|
*/
|
|
2544
|
-
latency:
|
|
2609
|
+
latency: import_zod13.z.object({
|
|
2545
2610
|
/**
|
|
2546
2611
|
* Maximum acceptable latency for primary region (ms)
|
|
2547
2612
|
*/
|
|
2548
|
-
maxPrimaryLatency:
|
|
2613
|
+
maxPrimaryLatency: import_zod13.z.number().int().positive().default(50),
|
|
2549
2614
|
/**
|
|
2550
2615
|
* Maximum acceptable latency for replicas (ms)
|
|
2551
2616
|
*/
|
|
2552
|
-
maxReplicaLatency:
|
|
2617
|
+
maxReplicaLatency: import_zod13.z.number().int().positive().default(200)
|
|
2553
2618
|
}).optional()
|
|
2554
2619
|
});
|
|
2555
|
-
var ReplicationJobSchema =
|
|
2620
|
+
var ReplicationJobSchema = import_zod13.z.object({
|
|
2556
2621
|
/**
|
|
2557
2622
|
* Job identifier
|
|
2558
2623
|
*/
|
|
2559
|
-
id:
|
|
2624
|
+
id: import_zod13.z.string().uuid(),
|
|
2560
2625
|
/**
|
|
2561
2626
|
* Job type
|
|
2562
2627
|
*/
|
|
2563
|
-
type:
|
|
2628
|
+
type: import_zod13.z.enum([
|
|
2564
2629
|
"initial-sync",
|
|
2565
2630
|
// First-time full sync
|
|
2566
2631
|
"incremental",
|
|
@@ -2571,84 +2636,84 @@ var ReplicationJobSchema = import_zod12.z.object({
|
|
|
2571
2636
|
/**
|
|
2572
2637
|
* Source hub
|
|
2573
2638
|
*/
|
|
2574
|
-
sourceHubId:
|
|
2639
|
+
sourceHubId: import_zod13.z.string().uuid(),
|
|
2575
2640
|
/**
|
|
2576
2641
|
* Target hub(s)
|
|
2577
2642
|
*/
|
|
2578
|
-
targetHubIds:
|
|
2643
|
+
targetHubIds: import_zod13.z.array(import_zod13.z.string().uuid()),
|
|
2579
2644
|
/**
|
|
2580
2645
|
* Resource scope
|
|
2581
2646
|
*/
|
|
2582
|
-
scope:
|
|
2647
|
+
scope: import_zod13.z.object({
|
|
2583
2648
|
/**
|
|
2584
2649
|
* Resource type
|
|
2585
2650
|
*/
|
|
2586
|
-
resourceType:
|
|
2651
|
+
resourceType: import_zod13.z.enum(["plugin", "tenant", "space", "license", "all"]),
|
|
2587
2652
|
/**
|
|
2588
2653
|
* Specific resource IDs (empty = all)
|
|
2589
2654
|
*/
|
|
2590
|
-
resourceIds:
|
|
2655
|
+
resourceIds: import_zod13.z.array(import_zod13.z.string()).default([])
|
|
2591
2656
|
}),
|
|
2592
2657
|
/**
|
|
2593
2658
|
* Job status
|
|
2594
2659
|
*/
|
|
2595
|
-
status:
|
|
2660
|
+
status: import_zod13.z.enum(["pending", "running", "completed", "failed", "cancelled"]),
|
|
2596
2661
|
/**
|
|
2597
2662
|
* Progress
|
|
2598
2663
|
*/
|
|
2599
|
-
progress:
|
|
2600
|
-
total:
|
|
2601
|
-
completed:
|
|
2602
|
-
failed:
|
|
2664
|
+
progress: import_zod13.z.object({
|
|
2665
|
+
total: import_zod13.z.number().int().min(0),
|
|
2666
|
+
completed: import_zod13.z.number().int().min(0),
|
|
2667
|
+
failed: import_zod13.z.number().int().min(0)
|
|
2603
2668
|
}).optional(),
|
|
2604
2669
|
/**
|
|
2605
2670
|
* Timestamps
|
|
2606
2671
|
*/
|
|
2607
|
-
createdAt:
|
|
2608
|
-
startedAt:
|
|
2609
|
-
completedAt:
|
|
2672
|
+
createdAt: import_zod13.z.string().datetime(),
|
|
2673
|
+
startedAt: import_zod13.z.string().datetime().optional(),
|
|
2674
|
+
completedAt: import_zod13.z.string().datetime().optional(),
|
|
2610
2675
|
/**
|
|
2611
2676
|
* Errors
|
|
2612
2677
|
*/
|
|
2613
|
-
errors:
|
|
2614
|
-
timestamp:
|
|
2615
|
-
resourceId:
|
|
2616
|
-
error:
|
|
2678
|
+
errors: import_zod13.z.array(import_zod13.z.object({
|
|
2679
|
+
timestamp: import_zod13.z.string().datetime(),
|
|
2680
|
+
resourceId: import_zod13.z.string(),
|
|
2681
|
+
error: import_zod13.z.string()
|
|
2617
2682
|
})).default([])
|
|
2618
2683
|
});
|
|
2619
|
-
var GlobalRegistryEntrySchema =
|
|
2684
|
+
var GlobalRegistryEntrySchema = import_zod13.z.object({
|
|
2620
2685
|
/**
|
|
2621
2686
|
* Resource identifier
|
|
2622
2687
|
*/
|
|
2623
|
-
resourceId:
|
|
2688
|
+
resourceId: import_zod13.z.string(),
|
|
2624
2689
|
/**
|
|
2625
2690
|
* Resource type
|
|
2626
2691
|
*/
|
|
2627
|
-
resourceType:
|
|
2692
|
+
resourceType: import_zod13.z.enum(["plugin", "tenant", "space", "license"]),
|
|
2628
2693
|
/**
|
|
2629
2694
|
* Regions where this resource exists
|
|
2630
2695
|
*/
|
|
2631
|
-
locations:
|
|
2632
|
-
regionId:
|
|
2633
|
-
hubId:
|
|
2634
|
-
isPrimary:
|
|
2635
|
-
lastSyncedAt:
|
|
2636
|
-
version:
|
|
2696
|
+
locations: import_zod13.z.array(import_zod13.z.object({
|
|
2697
|
+
regionId: import_zod13.z.string(),
|
|
2698
|
+
hubId: import_zod13.z.string().uuid(),
|
|
2699
|
+
isPrimary: import_zod13.z.boolean().default(false),
|
|
2700
|
+
lastSyncedAt: import_zod13.z.string().datetime().optional(),
|
|
2701
|
+
version: import_zod13.z.string().optional()
|
|
2637
2702
|
})),
|
|
2638
2703
|
/**
|
|
2639
2704
|
* Global version vector clock (for conflict detection)
|
|
2640
2705
|
*/
|
|
2641
|
-
versionVector:
|
|
2706
|
+
versionVector: import_zod13.z.record(import_zod13.z.string(), import_zod13.z.number().int()).optional()
|
|
2642
2707
|
});
|
|
2643
|
-
var EdgeLocationSchema =
|
|
2708
|
+
var EdgeLocationSchema = import_zod13.z.object({
|
|
2644
2709
|
/**
|
|
2645
2710
|
* Location identifier
|
|
2646
2711
|
*/
|
|
2647
|
-
id:
|
|
2712
|
+
id: import_zod13.z.string(),
|
|
2648
2713
|
/**
|
|
2649
2714
|
* Parent region
|
|
2650
2715
|
*/
|
|
2651
|
-
regionId:
|
|
2716
|
+
regionId: import_zod13.z.string(),
|
|
2652
2717
|
/**
|
|
2653
2718
|
* Location details
|
|
2654
2719
|
*/
|
|
@@ -2656,24 +2721,24 @@ var EdgeLocationSchema = import_zod12.z.object({
|
|
|
2656
2721
|
/**
|
|
2657
2722
|
* Caching configuration
|
|
2658
2723
|
*/
|
|
2659
|
-
cache:
|
|
2724
|
+
cache: import_zod13.z.object({
|
|
2660
2725
|
/**
|
|
2661
2726
|
* What to cache at edge
|
|
2662
2727
|
*/
|
|
2663
|
-
resources:
|
|
2728
|
+
resources: import_zod13.z.array(import_zod13.z.enum(["plugins", "static-assets", "api-responses"])).default([]),
|
|
2664
2729
|
/**
|
|
2665
2730
|
* TTL in seconds
|
|
2666
2731
|
*/
|
|
2667
|
-
ttl:
|
|
2732
|
+
ttl: import_zod13.z.number().int().positive().default(3600),
|
|
2668
2733
|
/**
|
|
2669
2734
|
* Cache size limit (bytes)
|
|
2670
2735
|
*/
|
|
2671
|
-
maxSize:
|
|
2736
|
+
maxSize: import_zod13.z.number().int().positive().optional()
|
|
2672
2737
|
}),
|
|
2673
2738
|
/**
|
|
2674
2739
|
* Status
|
|
2675
2740
|
*/
|
|
2676
|
-
status:
|
|
2741
|
+
status: import_zod13.z.enum(["active", "inactive"]).default("active")
|
|
2677
2742
|
});
|
|
2678
2743
|
var HubFederationProtocol = {
|
|
2679
2744
|
Region: RegionSchema,
|
|
@@ -2686,31 +2751,31 @@ var HubFederationProtocol = {
|
|
|
2686
2751
|
};
|
|
2687
2752
|
|
|
2688
2753
|
// src/hub/plugin-security.zod.ts
|
|
2689
|
-
var
|
|
2690
|
-
var VulnerabilitySeverity =
|
|
2754
|
+
var import_zod14 = require("zod");
|
|
2755
|
+
var VulnerabilitySeverity = import_zod14.z.enum([
|
|
2691
2756
|
"critical",
|
|
2692
2757
|
"high",
|
|
2693
2758
|
"medium",
|
|
2694
2759
|
"low",
|
|
2695
2760
|
"info"
|
|
2696
2761
|
]);
|
|
2697
|
-
var SecurityVulnerabilitySchema =
|
|
2762
|
+
var SecurityVulnerabilitySchema = import_zod14.z.object({
|
|
2698
2763
|
/**
|
|
2699
2764
|
* CVE identifier (if applicable)
|
|
2700
2765
|
*/
|
|
2701
|
-
cve:
|
|
2766
|
+
cve: import_zod14.z.string().regex(/^CVE-\d{4}-\d+$/).optional().describe("CVE identifier"),
|
|
2702
2767
|
/**
|
|
2703
2768
|
* Vulnerability identifier (GHSA, SNYK, etc.)
|
|
2704
2769
|
*/
|
|
2705
|
-
id:
|
|
2770
|
+
id: import_zod14.z.string().describe("Vulnerability ID"),
|
|
2706
2771
|
/**
|
|
2707
2772
|
* Title
|
|
2708
2773
|
*/
|
|
2709
|
-
title:
|
|
2774
|
+
title: import_zod14.z.string(),
|
|
2710
2775
|
/**
|
|
2711
2776
|
* Description
|
|
2712
2777
|
*/
|
|
2713
|
-
description:
|
|
2778
|
+
description: import_zod14.z.string(),
|
|
2714
2779
|
/**
|
|
2715
2780
|
* Severity
|
|
2716
2781
|
*/
|
|
@@ -2718,149 +2783,149 @@ var SecurityVulnerabilitySchema = import_zod13.z.object({
|
|
|
2718
2783
|
/**
|
|
2719
2784
|
* CVSS score (0-10)
|
|
2720
2785
|
*/
|
|
2721
|
-
cvss:
|
|
2786
|
+
cvss: import_zod14.z.number().min(0).max(10).optional(),
|
|
2722
2787
|
/**
|
|
2723
2788
|
* Affected package
|
|
2724
2789
|
*/
|
|
2725
|
-
package:
|
|
2726
|
-
name:
|
|
2727
|
-
version:
|
|
2728
|
-
ecosystem:
|
|
2790
|
+
package: import_zod14.z.object({
|
|
2791
|
+
name: import_zod14.z.string(),
|
|
2792
|
+
version: import_zod14.z.string(),
|
|
2793
|
+
ecosystem: import_zod14.z.string().optional()
|
|
2729
2794
|
}),
|
|
2730
2795
|
/**
|
|
2731
2796
|
* Vulnerable version range
|
|
2732
2797
|
*/
|
|
2733
|
-
vulnerableVersions:
|
|
2798
|
+
vulnerableVersions: import_zod14.z.string().describe("Semver range of vulnerable versions"),
|
|
2734
2799
|
/**
|
|
2735
2800
|
* Patched versions
|
|
2736
2801
|
*/
|
|
2737
|
-
patchedVersions:
|
|
2802
|
+
patchedVersions: import_zod14.z.string().optional().describe("Semver range of patched versions"),
|
|
2738
2803
|
/**
|
|
2739
2804
|
* References
|
|
2740
2805
|
*/
|
|
2741
|
-
references:
|
|
2742
|
-
type:
|
|
2743
|
-
url:
|
|
2806
|
+
references: import_zod14.z.array(import_zod14.z.object({
|
|
2807
|
+
type: import_zod14.z.enum(["advisory", "article", "report", "web"]),
|
|
2808
|
+
url: import_zod14.z.string().url()
|
|
2744
2809
|
})).default([]),
|
|
2745
2810
|
/**
|
|
2746
2811
|
* CWE (Common Weakness Enumeration)
|
|
2747
2812
|
*/
|
|
2748
|
-
cwe:
|
|
2813
|
+
cwe: import_zod14.z.array(import_zod14.z.string()).default([]),
|
|
2749
2814
|
/**
|
|
2750
2815
|
* Published date
|
|
2751
2816
|
*/
|
|
2752
|
-
publishedAt:
|
|
2817
|
+
publishedAt: import_zod14.z.string().datetime().optional(),
|
|
2753
2818
|
/**
|
|
2754
2819
|
* Mitigation advice
|
|
2755
2820
|
*/
|
|
2756
|
-
mitigation:
|
|
2821
|
+
mitigation: import_zod14.z.string().optional()
|
|
2757
2822
|
});
|
|
2758
|
-
var SecurityScanResultSchema =
|
|
2823
|
+
var SecurityScanResultSchema = import_zod14.z.object({
|
|
2759
2824
|
/**
|
|
2760
2825
|
* Scan identifier
|
|
2761
2826
|
*/
|
|
2762
|
-
scanId:
|
|
2827
|
+
scanId: import_zod14.z.string().uuid(),
|
|
2763
2828
|
/**
|
|
2764
2829
|
* Plugin being scanned
|
|
2765
2830
|
*/
|
|
2766
|
-
plugin:
|
|
2767
|
-
id:
|
|
2768
|
-
version:
|
|
2831
|
+
plugin: import_zod14.z.object({
|
|
2832
|
+
id: import_zod14.z.string(),
|
|
2833
|
+
version: import_zod14.z.string()
|
|
2769
2834
|
}),
|
|
2770
2835
|
/**
|
|
2771
2836
|
* Scan timestamp
|
|
2772
2837
|
*/
|
|
2773
|
-
scannedAt:
|
|
2838
|
+
scannedAt: import_zod14.z.string().datetime(),
|
|
2774
2839
|
/**
|
|
2775
2840
|
* Scanner information
|
|
2776
2841
|
*/
|
|
2777
|
-
scanner:
|
|
2778
|
-
name:
|
|
2779
|
-
version:
|
|
2842
|
+
scanner: import_zod14.z.object({
|
|
2843
|
+
name: import_zod14.z.string().describe("Scanner name (e.g., snyk, osv, trivy)"),
|
|
2844
|
+
version: import_zod14.z.string()
|
|
2780
2845
|
}),
|
|
2781
2846
|
/**
|
|
2782
2847
|
* Scan status
|
|
2783
2848
|
*/
|
|
2784
|
-
status:
|
|
2849
|
+
status: import_zod14.z.enum(["passed", "failed", "warning"]),
|
|
2785
2850
|
/**
|
|
2786
2851
|
* Vulnerabilities found
|
|
2787
2852
|
*/
|
|
2788
|
-
vulnerabilities:
|
|
2853
|
+
vulnerabilities: import_zod14.z.array(SecurityVulnerabilitySchema),
|
|
2789
2854
|
/**
|
|
2790
2855
|
* Vulnerability summary
|
|
2791
2856
|
*/
|
|
2792
|
-
summary:
|
|
2793
|
-
critical:
|
|
2794
|
-
high:
|
|
2795
|
-
medium:
|
|
2796
|
-
low:
|
|
2797
|
-
info:
|
|
2798
|
-
total:
|
|
2857
|
+
summary: import_zod14.z.object({
|
|
2858
|
+
critical: import_zod14.z.number().int().min(0).default(0),
|
|
2859
|
+
high: import_zod14.z.number().int().min(0).default(0),
|
|
2860
|
+
medium: import_zod14.z.number().int().min(0).default(0),
|
|
2861
|
+
low: import_zod14.z.number().int().min(0).default(0),
|
|
2862
|
+
info: import_zod14.z.number().int().min(0).default(0),
|
|
2863
|
+
total: import_zod14.z.number().int().min(0).default(0)
|
|
2799
2864
|
}),
|
|
2800
2865
|
/**
|
|
2801
2866
|
* License compliance issues
|
|
2802
2867
|
*/
|
|
2803
|
-
licenseIssues:
|
|
2804
|
-
package:
|
|
2805
|
-
license:
|
|
2806
|
-
reason:
|
|
2807
|
-
severity:
|
|
2868
|
+
licenseIssues: import_zod14.z.array(import_zod14.z.object({
|
|
2869
|
+
package: import_zod14.z.string(),
|
|
2870
|
+
license: import_zod14.z.string(),
|
|
2871
|
+
reason: import_zod14.z.string(),
|
|
2872
|
+
severity: import_zod14.z.enum(["error", "warning", "info"])
|
|
2808
2873
|
})).default([]),
|
|
2809
2874
|
/**
|
|
2810
2875
|
* Code quality issues
|
|
2811
2876
|
*/
|
|
2812
|
-
codeQuality:
|
|
2813
|
-
score:
|
|
2814
|
-
issues:
|
|
2815
|
-
type:
|
|
2816
|
-
severity:
|
|
2817
|
-
message:
|
|
2818
|
-
file:
|
|
2819
|
-
line:
|
|
2877
|
+
codeQuality: import_zod14.z.object({
|
|
2878
|
+
score: import_zod14.z.number().min(0).max(100).optional(),
|
|
2879
|
+
issues: import_zod14.z.array(import_zod14.z.object({
|
|
2880
|
+
type: import_zod14.z.enum(["security", "quality", "style"]),
|
|
2881
|
+
severity: import_zod14.z.enum(["error", "warning", "info"]),
|
|
2882
|
+
message: import_zod14.z.string(),
|
|
2883
|
+
file: import_zod14.z.string().optional(),
|
|
2884
|
+
line: import_zod14.z.number().int().optional()
|
|
2820
2885
|
})).default([])
|
|
2821
2886
|
}).optional(),
|
|
2822
2887
|
/**
|
|
2823
2888
|
* Next scan scheduled
|
|
2824
2889
|
*/
|
|
2825
|
-
nextScanAt:
|
|
2890
|
+
nextScanAt: import_zod14.z.string().datetime().optional()
|
|
2826
2891
|
});
|
|
2827
|
-
var SecurityPolicySchema =
|
|
2892
|
+
var SecurityPolicySchema = import_zod14.z.object({
|
|
2828
2893
|
/**
|
|
2829
2894
|
* Policy identifier
|
|
2830
2895
|
*/
|
|
2831
|
-
id:
|
|
2896
|
+
id: import_zod14.z.string(),
|
|
2832
2897
|
/**
|
|
2833
2898
|
* Policy name
|
|
2834
2899
|
*/
|
|
2835
|
-
name:
|
|
2900
|
+
name: import_zod14.z.string(),
|
|
2836
2901
|
/**
|
|
2837
2902
|
* Automatic scanning
|
|
2838
2903
|
*/
|
|
2839
|
-
autoScan:
|
|
2840
|
-
enabled:
|
|
2841
|
-
frequency:
|
|
2904
|
+
autoScan: import_zod14.z.object({
|
|
2905
|
+
enabled: import_zod14.z.boolean().default(true),
|
|
2906
|
+
frequency: import_zod14.z.enum(["on-publish", "daily", "weekly", "monthly"]).default("daily")
|
|
2842
2907
|
}),
|
|
2843
2908
|
/**
|
|
2844
2909
|
* Vulnerability thresholds
|
|
2845
2910
|
*/
|
|
2846
|
-
thresholds:
|
|
2911
|
+
thresholds: import_zod14.z.object({
|
|
2847
2912
|
/**
|
|
2848
2913
|
* Block plugin if critical vulnerabilities exceed this
|
|
2849
2914
|
*/
|
|
2850
|
-
maxCritical:
|
|
2915
|
+
maxCritical: import_zod14.z.number().int().min(0).default(0),
|
|
2851
2916
|
/**
|
|
2852
2917
|
* Block plugin if high vulnerabilities exceed this
|
|
2853
2918
|
*/
|
|
2854
|
-
maxHigh:
|
|
2919
|
+
maxHigh: import_zod14.z.number().int().min(0).default(0),
|
|
2855
2920
|
/**
|
|
2856
2921
|
* Warn if medium vulnerabilities exceed this
|
|
2857
2922
|
*/
|
|
2858
|
-
maxMedium:
|
|
2923
|
+
maxMedium: import_zod14.z.number().int().min(0).default(5)
|
|
2859
2924
|
}),
|
|
2860
2925
|
/**
|
|
2861
2926
|
* Allowed licenses
|
|
2862
2927
|
*/
|
|
2863
|
-
allowedLicenses:
|
|
2928
|
+
allowedLicenses: import_zod14.z.array(import_zod14.z.string()).default([
|
|
2864
2929
|
"MIT",
|
|
2865
2930
|
"Apache-2.0",
|
|
2866
2931
|
"BSD-3-Clause",
|
|
@@ -2870,152 +2935,152 @@ var SecurityPolicySchema = import_zod13.z.object({
|
|
|
2870
2935
|
/**
|
|
2871
2936
|
* Prohibited licenses
|
|
2872
2937
|
*/
|
|
2873
|
-
prohibitedLicenses:
|
|
2938
|
+
prohibitedLicenses: import_zod14.z.array(import_zod14.z.string()).default([
|
|
2874
2939
|
"GPL-3.0",
|
|
2875
2940
|
"AGPL-3.0"
|
|
2876
2941
|
]),
|
|
2877
2942
|
/**
|
|
2878
2943
|
* Code signing requirements
|
|
2879
2944
|
*/
|
|
2880
|
-
codeSigning:
|
|
2881
|
-
required:
|
|
2882
|
-
allowedSigners:
|
|
2945
|
+
codeSigning: import_zod14.z.object({
|
|
2946
|
+
required: import_zod14.z.boolean().default(false),
|
|
2947
|
+
allowedSigners: import_zod14.z.array(import_zod14.z.string()).default([])
|
|
2883
2948
|
}).optional(),
|
|
2884
2949
|
/**
|
|
2885
2950
|
* Sandbox restrictions
|
|
2886
2951
|
*/
|
|
2887
|
-
sandbox:
|
|
2952
|
+
sandbox: import_zod14.z.object({
|
|
2888
2953
|
/**
|
|
2889
2954
|
* Restrict network access
|
|
2890
2955
|
*/
|
|
2891
|
-
networkAccess:
|
|
2956
|
+
networkAccess: import_zod14.z.enum(["none", "localhost", "allowlist", "all"]).default("all"),
|
|
2892
2957
|
/**
|
|
2893
2958
|
* Allowed network destinations (if allowlist)
|
|
2894
2959
|
*/
|
|
2895
|
-
allowedDestinations:
|
|
2960
|
+
allowedDestinations: import_zod14.z.array(import_zod14.z.string()).default([]),
|
|
2896
2961
|
/**
|
|
2897
2962
|
* File system access
|
|
2898
2963
|
*/
|
|
2899
|
-
filesystemAccess:
|
|
2964
|
+
filesystemAccess: import_zod14.z.enum(["none", "read-only", "temp-only", "full"]).default("full"),
|
|
2900
2965
|
/**
|
|
2901
2966
|
* Maximum memory (MB)
|
|
2902
2967
|
*/
|
|
2903
|
-
maxMemoryMB:
|
|
2968
|
+
maxMemoryMB: import_zod14.z.number().int().positive().optional(),
|
|
2904
2969
|
/**
|
|
2905
2970
|
* Maximum CPU time (seconds)
|
|
2906
2971
|
*/
|
|
2907
|
-
maxCPUSeconds:
|
|
2972
|
+
maxCPUSeconds: import_zod14.z.number().int().positive().optional()
|
|
2908
2973
|
}).optional()
|
|
2909
2974
|
});
|
|
2910
|
-
var PackageDependencySchema =
|
|
2975
|
+
var PackageDependencySchema = import_zod14.z.object({
|
|
2911
2976
|
/**
|
|
2912
2977
|
* Package name/ID
|
|
2913
2978
|
*/
|
|
2914
|
-
name:
|
|
2979
|
+
name: import_zod14.z.string(),
|
|
2915
2980
|
/**
|
|
2916
2981
|
* Version constraint (semver range)
|
|
2917
2982
|
*/
|
|
2918
|
-
versionConstraint:
|
|
2983
|
+
versionConstraint: import_zod14.z.string().describe("Semver range (e.g., `^1.0.0`, `>=2.0.0 <3.0.0`)"),
|
|
2919
2984
|
/**
|
|
2920
2985
|
* Dependency type
|
|
2921
2986
|
*/
|
|
2922
|
-
type:
|
|
2987
|
+
type: import_zod14.z.enum(["required", "optional", "peer", "dev"]).default("required"),
|
|
2923
2988
|
/**
|
|
2924
2989
|
* Resolved version (filled during resolution)
|
|
2925
2990
|
*/
|
|
2926
|
-
resolvedVersion:
|
|
2991
|
+
resolvedVersion: import_zod14.z.string().optional()
|
|
2927
2992
|
});
|
|
2928
|
-
var DependencyGraphNodeSchema =
|
|
2993
|
+
var DependencyGraphNodeSchema = import_zod14.z.object({
|
|
2929
2994
|
/**
|
|
2930
2995
|
* Package identifier
|
|
2931
2996
|
*/
|
|
2932
|
-
id:
|
|
2997
|
+
id: import_zod14.z.string(),
|
|
2933
2998
|
/**
|
|
2934
2999
|
* Package version
|
|
2935
3000
|
*/
|
|
2936
|
-
version:
|
|
3001
|
+
version: import_zod14.z.string(),
|
|
2937
3002
|
/**
|
|
2938
3003
|
* Dependencies of this package
|
|
2939
3004
|
*/
|
|
2940
|
-
dependencies:
|
|
3005
|
+
dependencies: import_zod14.z.array(PackageDependencySchema).default([]),
|
|
2941
3006
|
/**
|
|
2942
3007
|
* Depth in dependency tree
|
|
2943
3008
|
*/
|
|
2944
|
-
depth:
|
|
3009
|
+
depth: import_zod14.z.number().int().min(0),
|
|
2945
3010
|
/**
|
|
2946
3011
|
* Whether this is a direct dependency
|
|
2947
3012
|
*/
|
|
2948
|
-
isDirect:
|
|
3013
|
+
isDirect: import_zod14.z.boolean(),
|
|
2949
3014
|
/**
|
|
2950
3015
|
* Package metadata
|
|
2951
3016
|
*/
|
|
2952
|
-
metadata:
|
|
2953
|
-
name:
|
|
2954
|
-
description:
|
|
2955
|
-
license:
|
|
2956
|
-
homepage:
|
|
3017
|
+
metadata: import_zod14.z.object({
|
|
3018
|
+
name: import_zod14.z.string(),
|
|
3019
|
+
description: import_zod14.z.string().optional(),
|
|
3020
|
+
license: import_zod14.z.string().optional(),
|
|
3021
|
+
homepage: import_zod14.z.string().url().optional()
|
|
2957
3022
|
}).optional()
|
|
2958
3023
|
});
|
|
2959
|
-
var DependencyGraphSchema =
|
|
3024
|
+
var DependencyGraphSchema = import_zod14.z.object({
|
|
2960
3025
|
/**
|
|
2961
3026
|
* Root package
|
|
2962
3027
|
*/
|
|
2963
|
-
root:
|
|
2964
|
-
id:
|
|
2965
|
-
version:
|
|
3028
|
+
root: import_zod14.z.object({
|
|
3029
|
+
id: import_zod14.z.string(),
|
|
3030
|
+
version: import_zod14.z.string()
|
|
2966
3031
|
}),
|
|
2967
3032
|
/**
|
|
2968
3033
|
* All nodes in the graph
|
|
2969
3034
|
*/
|
|
2970
|
-
nodes:
|
|
3035
|
+
nodes: import_zod14.z.array(DependencyGraphNodeSchema),
|
|
2971
3036
|
/**
|
|
2972
3037
|
* Edges (dependency relationships)
|
|
2973
3038
|
*/
|
|
2974
|
-
edges:
|
|
2975
|
-
from:
|
|
2976
|
-
to:
|
|
2977
|
-
constraint:
|
|
3039
|
+
edges: import_zod14.z.array(import_zod14.z.object({
|
|
3040
|
+
from: import_zod14.z.string().describe("Package ID"),
|
|
3041
|
+
to: import_zod14.z.string().describe("Package ID"),
|
|
3042
|
+
constraint: import_zod14.z.string().describe("Version constraint")
|
|
2978
3043
|
})),
|
|
2979
3044
|
/**
|
|
2980
3045
|
* Resolution statistics
|
|
2981
3046
|
*/
|
|
2982
|
-
stats:
|
|
2983
|
-
totalDependencies:
|
|
2984
|
-
directDependencies:
|
|
2985
|
-
maxDepth:
|
|
3047
|
+
stats: import_zod14.z.object({
|
|
3048
|
+
totalDependencies: import_zod14.z.number().int().min(0),
|
|
3049
|
+
directDependencies: import_zod14.z.number().int().min(0),
|
|
3050
|
+
maxDepth: import_zod14.z.number().int().min(0)
|
|
2986
3051
|
})
|
|
2987
3052
|
});
|
|
2988
|
-
var DependencyConflictSchema =
|
|
3053
|
+
var DependencyConflictSchema = import_zod14.z.object({
|
|
2989
3054
|
/**
|
|
2990
3055
|
* Package with conflict
|
|
2991
3056
|
*/
|
|
2992
|
-
package:
|
|
3057
|
+
package: import_zod14.z.string(),
|
|
2993
3058
|
/**
|
|
2994
3059
|
* Conflicting versions
|
|
2995
3060
|
*/
|
|
2996
|
-
conflicts:
|
|
2997
|
-
version:
|
|
2998
|
-
requestedBy:
|
|
2999
|
-
constraint:
|
|
3061
|
+
conflicts: import_zod14.z.array(import_zod14.z.object({
|
|
3062
|
+
version: import_zod14.z.string(),
|
|
3063
|
+
requestedBy: import_zod14.z.array(import_zod14.z.string()).describe("Packages that require this version"),
|
|
3064
|
+
constraint: import_zod14.z.string()
|
|
3000
3065
|
})),
|
|
3001
3066
|
/**
|
|
3002
3067
|
* Suggested resolution
|
|
3003
3068
|
*/
|
|
3004
|
-
resolution:
|
|
3005
|
-
strategy:
|
|
3006
|
-
version:
|
|
3007
|
-
reason:
|
|
3069
|
+
resolution: import_zod14.z.object({
|
|
3070
|
+
strategy: import_zod14.z.enum(["pick-highest", "pick-lowest", "manual"]),
|
|
3071
|
+
version: import_zod14.z.string().optional(),
|
|
3072
|
+
reason: import_zod14.z.string().optional()
|
|
3008
3073
|
}).optional(),
|
|
3009
3074
|
/**
|
|
3010
3075
|
* Severity
|
|
3011
3076
|
*/
|
|
3012
|
-
severity:
|
|
3077
|
+
severity: import_zod14.z.enum(["error", "warning", "info"])
|
|
3013
3078
|
});
|
|
3014
|
-
var DependencyResolutionResultSchema =
|
|
3079
|
+
var DependencyResolutionResultSchema = import_zod14.z.object({
|
|
3015
3080
|
/**
|
|
3016
3081
|
* Resolution status
|
|
3017
3082
|
*/
|
|
3018
|
-
status:
|
|
3083
|
+
status: import_zod14.z.enum(["success", "conflict", "error"]),
|
|
3019
3084
|
/**
|
|
3020
3085
|
* Resolved dependency graph
|
|
3021
3086
|
*/
|
|
@@ -3023,207 +3088,207 @@ var DependencyResolutionResultSchema = import_zod13.z.object({
|
|
|
3023
3088
|
/**
|
|
3024
3089
|
* Conflicts detected
|
|
3025
3090
|
*/
|
|
3026
|
-
conflicts:
|
|
3091
|
+
conflicts: import_zod14.z.array(DependencyConflictSchema).default([]),
|
|
3027
3092
|
/**
|
|
3028
3093
|
* Errors encountered
|
|
3029
3094
|
*/
|
|
3030
|
-
errors:
|
|
3031
|
-
package:
|
|
3032
|
-
error:
|
|
3095
|
+
errors: import_zod14.z.array(import_zod14.z.object({
|
|
3096
|
+
package: import_zod14.z.string(),
|
|
3097
|
+
error: import_zod14.z.string()
|
|
3033
3098
|
})).default([]),
|
|
3034
3099
|
/**
|
|
3035
3100
|
* Installation order (topological sort)
|
|
3036
3101
|
*/
|
|
3037
|
-
installOrder:
|
|
3102
|
+
installOrder: import_zod14.z.array(import_zod14.z.string()).default([]),
|
|
3038
3103
|
/**
|
|
3039
3104
|
* Resolution time (ms)
|
|
3040
3105
|
*/
|
|
3041
|
-
resolvedIn:
|
|
3106
|
+
resolvedIn: import_zod14.z.number().int().min(0).optional()
|
|
3042
3107
|
});
|
|
3043
|
-
var SBOMEntrySchema =
|
|
3108
|
+
var SBOMEntrySchema = import_zod14.z.object({
|
|
3044
3109
|
/**
|
|
3045
3110
|
* Component name
|
|
3046
3111
|
*/
|
|
3047
|
-
name:
|
|
3112
|
+
name: import_zod14.z.string(),
|
|
3048
3113
|
/**
|
|
3049
3114
|
* Component version
|
|
3050
3115
|
*/
|
|
3051
|
-
version:
|
|
3116
|
+
version: import_zod14.z.string(),
|
|
3052
3117
|
/**
|
|
3053
3118
|
* Package URL (purl)
|
|
3054
3119
|
*/
|
|
3055
|
-
purl:
|
|
3120
|
+
purl: import_zod14.z.string().optional().describe("Package URL identifier"),
|
|
3056
3121
|
/**
|
|
3057
3122
|
* License
|
|
3058
3123
|
*/
|
|
3059
|
-
license:
|
|
3124
|
+
license: import_zod14.z.string().optional(),
|
|
3060
3125
|
/**
|
|
3061
3126
|
* Hashes
|
|
3062
3127
|
*/
|
|
3063
|
-
hashes:
|
|
3064
|
-
sha256:
|
|
3065
|
-
sha512:
|
|
3128
|
+
hashes: import_zod14.z.object({
|
|
3129
|
+
sha256: import_zod14.z.string().optional(),
|
|
3130
|
+
sha512: import_zod14.z.string().optional()
|
|
3066
3131
|
}).optional(),
|
|
3067
3132
|
/**
|
|
3068
3133
|
* Supplier
|
|
3069
3134
|
*/
|
|
3070
|
-
supplier:
|
|
3071
|
-
name:
|
|
3072
|
-
url:
|
|
3135
|
+
supplier: import_zod14.z.object({
|
|
3136
|
+
name: import_zod14.z.string(),
|
|
3137
|
+
url: import_zod14.z.string().url().optional()
|
|
3073
3138
|
}).optional(),
|
|
3074
3139
|
/**
|
|
3075
3140
|
* External references
|
|
3076
3141
|
*/
|
|
3077
|
-
externalRefs:
|
|
3078
|
-
type:
|
|
3079
|
-
url:
|
|
3142
|
+
externalRefs: import_zod14.z.array(import_zod14.z.object({
|
|
3143
|
+
type: import_zod14.z.enum(["website", "repository", "documentation", "issue-tracker"]),
|
|
3144
|
+
url: import_zod14.z.string().url()
|
|
3080
3145
|
})).default([])
|
|
3081
3146
|
});
|
|
3082
|
-
var SBOMSchema =
|
|
3147
|
+
var SBOMSchema = import_zod14.z.object({
|
|
3083
3148
|
/**
|
|
3084
3149
|
* SBOM format
|
|
3085
3150
|
*/
|
|
3086
|
-
format:
|
|
3151
|
+
format: import_zod14.z.enum(["spdx", "cyclonedx"]).default("cyclonedx"),
|
|
3087
3152
|
/**
|
|
3088
3153
|
* SBOM version
|
|
3089
3154
|
*/
|
|
3090
|
-
version:
|
|
3155
|
+
version: import_zod14.z.string(),
|
|
3091
3156
|
/**
|
|
3092
3157
|
* Plugin metadata
|
|
3093
3158
|
*/
|
|
3094
|
-
plugin:
|
|
3095
|
-
id:
|
|
3096
|
-
version:
|
|
3097
|
-
name:
|
|
3159
|
+
plugin: import_zod14.z.object({
|
|
3160
|
+
id: import_zod14.z.string(),
|
|
3161
|
+
version: import_zod14.z.string(),
|
|
3162
|
+
name: import_zod14.z.string()
|
|
3098
3163
|
}),
|
|
3099
3164
|
/**
|
|
3100
3165
|
* Components (dependencies)
|
|
3101
3166
|
*/
|
|
3102
|
-
components:
|
|
3167
|
+
components: import_zod14.z.array(SBOMEntrySchema),
|
|
3103
3168
|
/**
|
|
3104
3169
|
* Generation timestamp
|
|
3105
3170
|
*/
|
|
3106
|
-
generatedAt:
|
|
3171
|
+
generatedAt: import_zod14.z.string().datetime(),
|
|
3107
3172
|
/**
|
|
3108
3173
|
* Generator tool
|
|
3109
3174
|
*/
|
|
3110
|
-
generator:
|
|
3111
|
-
name:
|
|
3112
|
-
version:
|
|
3175
|
+
generator: import_zod14.z.object({
|
|
3176
|
+
name: import_zod14.z.string(),
|
|
3177
|
+
version: import_zod14.z.string()
|
|
3113
3178
|
}).optional()
|
|
3114
3179
|
});
|
|
3115
|
-
var PluginProvenanceSchema =
|
|
3180
|
+
var PluginProvenanceSchema = import_zod14.z.object({
|
|
3116
3181
|
/**
|
|
3117
3182
|
* Plugin identifier
|
|
3118
3183
|
*/
|
|
3119
|
-
pluginId:
|
|
3184
|
+
pluginId: import_zod14.z.string(),
|
|
3120
3185
|
/**
|
|
3121
3186
|
* Plugin version
|
|
3122
3187
|
*/
|
|
3123
|
-
version:
|
|
3188
|
+
version: import_zod14.z.string(),
|
|
3124
3189
|
/**
|
|
3125
3190
|
* Build information
|
|
3126
3191
|
*/
|
|
3127
|
-
build:
|
|
3192
|
+
build: import_zod14.z.object({
|
|
3128
3193
|
/**
|
|
3129
3194
|
* Build timestamp
|
|
3130
3195
|
*/
|
|
3131
|
-
timestamp:
|
|
3196
|
+
timestamp: import_zod14.z.string().datetime(),
|
|
3132
3197
|
/**
|
|
3133
3198
|
* Build environment
|
|
3134
3199
|
*/
|
|
3135
|
-
environment:
|
|
3136
|
-
os:
|
|
3137
|
-
arch:
|
|
3138
|
-
nodeVersion:
|
|
3200
|
+
environment: import_zod14.z.object({
|
|
3201
|
+
os: import_zod14.z.string(),
|
|
3202
|
+
arch: import_zod14.z.string(),
|
|
3203
|
+
nodeVersion: import_zod14.z.string()
|
|
3139
3204
|
}).optional(),
|
|
3140
3205
|
/**
|
|
3141
3206
|
* Source repository
|
|
3142
3207
|
*/
|
|
3143
|
-
source:
|
|
3144
|
-
repository:
|
|
3145
|
-
commit:
|
|
3146
|
-
branch:
|
|
3147
|
-
tag:
|
|
3208
|
+
source: import_zod14.z.object({
|
|
3209
|
+
repository: import_zod14.z.string().url(),
|
|
3210
|
+
commit: import_zod14.z.string().regex(/^[a-f0-9]{40}$/),
|
|
3211
|
+
branch: import_zod14.z.string().optional(),
|
|
3212
|
+
tag: import_zod14.z.string().optional()
|
|
3148
3213
|
}).optional(),
|
|
3149
3214
|
/**
|
|
3150
3215
|
* Builder identity
|
|
3151
3216
|
*/
|
|
3152
|
-
builder:
|
|
3153
|
-
name:
|
|
3154
|
-
email:
|
|
3217
|
+
builder: import_zod14.z.object({
|
|
3218
|
+
name: import_zod14.z.string(),
|
|
3219
|
+
email: import_zod14.z.string().email().optional()
|
|
3155
3220
|
}).optional()
|
|
3156
3221
|
}),
|
|
3157
3222
|
/**
|
|
3158
3223
|
* Artifact hashes
|
|
3159
3224
|
*/
|
|
3160
|
-
artifacts:
|
|
3161
|
-
filename:
|
|
3162
|
-
sha256:
|
|
3163
|
-
size:
|
|
3225
|
+
artifacts: import_zod14.z.array(import_zod14.z.object({
|
|
3226
|
+
filename: import_zod14.z.string(),
|
|
3227
|
+
sha256: import_zod14.z.string(),
|
|
3228
|
+
size: import_zod14.z.number().int().positive()
|
|
3164
3229
|
})),
|
|
3165
3230
|
/**
|
|
3166
3231
|
* Signatures
|
|
3167
3232
|
*/
|
|
3168
|
-
signatures:
|
|
3169
|
-
algorithm:
|
|
3170
|
-
publicKey:
|
|
3171
|
-
signature:
|
|
3172
|
-
signedBy:
|
|
3173
|
-
timestamp:
|
|
3233
|
+
signatures: import_zod14.z.array(import_zod14.z.object({
|
|
3234
|
+
algorithm: import_zod14.z.enum(["rsa", "ecdsa", "ed25519"]),
|
|
3235
|
+
publicKey: import_zod14.z.string(),
|
|
3236
|
+
signature: import_zod14.z.string(),
|
|
3237
|
+
signedBy: import_zod14.z.string(),
|
|
3238
|
+
timestamp: import_zod14.z.string().datetime()
|
|
3174
3239
|
})).default([]),
|
|
3175
3240
|
/**
|
|
3176
3241
|
* Attestations
|
|
3177
3242
|
*/
|
|
3178
|
-
attestations:
|
|
3179
|
-
type:
|
|
3180
|
-
status:
|
|
3181
|
-
url:
|
|
3182
|
-
timestamp:
|
|
3243
|
+
attestations: import_zod14.z.array(import_zod14.z.object({
|
|
3244
|
+
type: import_zod14.z.enum(["code-review", "security-scan", "test-results", "ci-build"]),
|
|
3245
|
+
status: import_zod14.z.enum(["passed", "failed"]),
|
|
3246
|
+
url: import_zod14.z.string().url().optional(),
|
|
3247
|
+
timestamp: import_zod14.z.string().datetime()
|
|
3183
3248
|
})).default([])
|
|
3184
3249
|
});
|
|
3185
|
-
var PluginTrustScoreSchema =
|
|
3250
|
+
var PluginTrustScoreSchema = import_zod14.z.object({
|
|
3186
3251
|
/**
|
|
3187
3252
|
* Plugin identifier
|
|
3188
3253
|
*/
|
|
3189
|
-
pluginId:
|
|
3254
|
+
pluginId: import_zod14.z.string(),
|
|
3190
3255
|
/**
|
|
3191
3256
|
* Overall trust score (0-100)
|
|
3192
3257
|
*/
|
|
3193
|
-
score:
|
|
3258
|
+
score: import_zod14.z.number().min(0).max(100),
|
|
3194
3259
|
/**
|
|
3195
3260
|
* Score components
|
|
3196
3261
|
*/
|
|
3197
|
-
components:
|
|
3262
|
+
components: import_zod14.z.object({
|
|
3198
3263
|
/**
|
|
3199
3264
|
* Vendor reputation (0-100)
|
|
3200
3265
|
*/
|
|
3201
|
-
vendorReputation:
|
|
3266
|
+
vendorReputation: import_zod14.z.number().min(0).max(100),
|
|
3202
3267
|
/**
|
|
3203
3268
|
* Security scan results (0-100)
|
|
3204
3269
|
*/
|
|
3205
|
-
securityScore:
|
|
3270
|
+
securityScore: import_zod14.z.number().min(0).max(100),
|
|
3206
3271
|
/**
|
|
3207
3272
|
* Code quality (0-100)
|
|
3208
3273
|
*/
|
|
3209
|
-
codeQuality:
|
|
3274
|
+
codeQuality: import_zod14.z.number().min(0).max(100),
|
|
3210
3275
|
/**
|
|
3211
3276
|
* Community engagement (0-100)
|
|
3212
3277
|
*/
|
|
3213
|
-
communityScore:
|
|
3278
|
+
communityScore: import_zod14.z.number().min(0).max(100),
|
|
3214
3279
|
/**
|
|
3215
3280
|
* Update frequency (0-100)
|
|
3216
3281
|
*/
|
|
3217
|
-
maintenanceScore:
|
|
3282
|
+
maintenanceScore: import_zod14.z.number().min(0).max(100)
|
|
3218
3283
|
}),
|
|
3219
3284
|
/**
|
|
3220
3285
|
* Trust level
|
|
3221
3286
|
*/
|
|
3222
|
-
level:
|
|
3287
|
+
level: import_zod14.z.enum(["verified", "trusted", "neutral", "untrusted", "blocked"]),
|
|
3223
3288
|
/**
|
|
3224
3289
|
* Verification badges
|
|
3225
3290
|
*/
|
|
3226
|
-
badges:
|
|
3291
|
+
badges: import_zod14.z.array(import_zod14.z.enum([
|
|
3227
3292
|
"official",
|
|
3228
3293
|
// Official ObjectStack plugin
|
|
3229
3294
|
"verified-vendor",
|
|
@@ -3240,7 +3305,7 @@ var PluginTrustScoreSchema = import_zod13.z.object({
|
|
|
3240
3305
|
/**
|
|
3241
3306
|
* Last updated
|
|
3242
3307
|
*/
|
|
3243
|
-
updatedAt:
|
|
3308
|
+
updatedAt: import_zod14.z.string().datetime()
|
|
3244
3309
|
});
|
|
3245
3310
|
var PluginSecurityProtocol = {
|
|
3246
3311
|
VulnerabilitySeverity,
|