@objectstack/spec 0.8.2 → 0.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (188) hide show
  1. package/dist/ai/devops-agent.zod.d.ts +1 -1
  2. package/dist/ai/feedback-loop.zod.d.ts +4293 -0
  3. package/dist/ai/feedback-loop.zod.d.ts.map +1 -0
  4. package/dist/ai/feedback-loop.zod.js +53 -0
  5. package/dist/ai/index.d.ts +1 -0
  6. package/dist/ai/index.d.ts.map +1 -1
  7. package/dist/ai/index.js +1 -0
  8. package/dist/api/documentation.zod.d.ts +1073 -0
  9. package/dist/api/documentation.zod.d.ts.map +1 -0
  10. package/dist/api/documentation.zod.js +487 -0
  11. package/dist/api/errors.zod.d.ts +6 -6
  12. package/dist/api/graphql.zod.d.ts +3 -3
  13. package/dist/api/hub.zod.d.ts +5239 -0
  14. package/dist/api/hub.zod.d.ts.map +1 -0
  15. package/dist/api/hub.zod.js +784 -0
  16. package/dist/api/index.d.ts +4 -0
  17. package/dist/api/index.d.ts.map +1 -1
  18. package/dist/api/index.js +4 -0
  19. package/dist/api/odata.zod.d.ts +1 -1
  20. package/dist/api/registry.example.d.ts +411 -0
  21. package/dist/api/registry.example.d.ts.map +1 -0
  22. package/dist/api/registry.example.js +470 -0
  23. package/dist/api/registry.zod.d.ts +2095 -0
  24. package/dist/api/registry.zod.d.ts.map +1 -0
  25. package/dist/api/registry.zod.js +755 -0
  26. package/dist/api/websocket.zod.d.ts +8 -8
  27. package/dist/auth/scim.zod.d.ts +3 -3
  28. package/dist/automation/flow.zod.d.ts +3 -3
  29. package/dist/contracts/index.d.ts +1 -0
  30. package/dist/contracts/index.d.ts.map +1 -1
  31. package/dist/contracts/index.js +1 -0
  32. package/dist/contracts/schema-driver.d.ts +21 -0
  33. package/dist/contracts/schema-driver.d.ts.map +1 -0
  34. package/dist/contracts/schema-driver.js +2 -0
  35. package/dist/hub/composer.zod.d.ts +226 -0
  36. package/dist/hub/composer.zod.d.ts.map +1 -1
  37. package/dist/hub/hub-federation.zod.d.ts +764 -0
  38. package/dist/hub/hub-federation.zod.d.ts.map +1 -0
  39. package/dist/hub/hub-federation.zod.js +441 -0
  40. package/dist/hub/index.d.ts +2 -0
  41. package/dist/hub/index.d.ts.map +1 -1
  42. package/dist/hub/index.js +3 -0
  43. package/dist/hub/plugin-security.zod.d.ts +1029 -0
  44. package/dist/hub/plugin-security.zod.d.ts.map +1 -0
  45. package/dist/hub/plugin-security.zod.js +637 -0
  46. package/dist/index.d.ts +1 -0
  47. package/dist/index.d.ts.map +1 -1
  48. package/dist/index.js +2 -1
  49. package/dist/integration/connector/vercel.zod.d.ts +2 -2
  50. package/dist/qa/index.d.ts +11 -0
  51. package/dist/qa/index.d.ts.map +1 -0
  52. package/dist/qa/index.js +26 -0
  53. package/dist/qa/testing.zod.d.ts +345 -0
  54. package/dist/qa/testing.zod.d.ts.map +1 -0
  55. package/dist/qa/testing.zod.js +69 -0
  56. package/dist/stack.zod.d.ts +576 -3
  57. package/dist/stack.zod.d.ts.map +1 -1
  58. package/dist/system/index.d.ts +2 -0
  59. package/dist/system/index.d.ts.map +1 -1
  60. package/dist/system/index.js +2 -0
  61. package/dist/system/manifest.zod.d.ts +226 -0
  62. package/dist/system/manifest.zod.d.ts.map +1 -1
  63. package/dist/system/manifest.zod.js +8 -0
  64. package/dist/system/message-queue.zod.d.ts +2 -2
  65. package/dist/system/metadata-loader.zod.d.ts +1 -1
  66. package/dist/system/migration.zod.d.ts +4205 -0
  67. package/dist/system/migration.zod.d.ts.map +1 -0
  68. package/dist/system/migration.zod.js +70 -0
  69. package/dist/system/plugin-loading.zod.d.ts +575 -0
  70. package/dist/system/plugin-loading.zod.d.ts.map +1 -0
  71. package/dist/system/plugin-loading.zod.js +612 -0
  72. package/json-schema/ai/FeedbackLoop.json +7 -0
  73. package/json-schema/ai/Issue.json +7 -0
  74. package/json-schema/ai/MetadataSource.json +7 -0
  75. package/json-schema/ai/Resolution.json +7 -0
  76. package/json-schema/api/ApiChangelogEntry.json +7 -0
  77. package/json-schema/api/ApiDiscoveryQuery.json +7 -0
  78. package/json-schema/api/ApiDiscoveryResponse.json +7 -0
  79. package/json-schema/api/ApiDocumentationConfig.json +7 -0
  80. package/json-schema/api/ApiEndpointRegistration.json +7 -0
  81. package/json-schema/api/ApiMetadata.json +7 -0
  82. package/json-schema/api/ApiParameter.json +7 -0
  83. package/json-schema/api/ApiProtocolType.json +7 -0
  84. package/json-schema/api/ApiRegistry.json +7 -0
  85. package/json-schema/api/ApiRegistryEntry.json +7 -0
  86. package/json-schema/api/ApiResponse.json +7 -0
  87. package/json-schema/api/ApiTestCollection.json +7 -0
  88. package/json-schema/api/ApiTestRequest.json +7 -0
  89. package/json-schema/api/ApiTestingUiConfig.json +7 -0
  90. package/json-schema/api/ApiTestingUiType.json +7 -0
  91. package/json-schema/api/BuildStatusResponse.json +7 -0
  92. package/json-schema/api/CodeGenerationTemplate.json +7 -0
  93. package/json-schema/api/CompileManifestRequest.json +7 -0
  94. package/json-schema/api/CompileManifestResponse.json +7 -0
  95. package/json-schema/api/ConflictResolutionStrategy.json +7 -0
  96. package/json-schema/api/CreateSpaceRequest.json +7 -0
  97. package/json-schema/api/CreateTenantRequest.json +7 -0
  98. package/json-schema/api/GeneratedApiDocumentation.json +7 -0
  99. package/json-schema/api/GetBuildStatusRequest.json +7 -0
  100. package/json-schema/api/GetMarketplacePluginRequest.json +7 -0
  101. package/json-schema/api/GetPluginVersionsRequest.json +7 -0
  102. package/json-schema/api/GetPluginVersionsResponse.json +7 -0
  103. package/json-schema/api/HttpStatusCode.json +7 -0
  104. package/json-schema/api/HubHealthResponse.json +7 -0
  105. package/json-schema/api/HubMetricsResponse.json +7 -0
  106. package/json-schema/api/IssueLicenseRequest.json +7 -0
  107. package/json-schema/api/LicenseResponse.json +7 -0
  108. package/json-schema/api/ListLicensesRequest.json +7 -0
  109. package/json-schema/api/ListLicensesResponse.json +7 -0
  110. package/json-schema/api/ListMarketplaceRequest.json +7 -0
  111. package/json-schema/api/ListMarketplaceResponse.json +7 -0
  112. package/json-schema/api/ListSpacesRequest.json +7 -0
  113. package/json-schema/api/ListSpacesResponse.json +7 -0
  114. package/json-schema/api/ListTenantsRequest.json +7 -0
  115. package/json-schema/api/ListTenantsResponse.json +7 -0
  116. package/json-schema/api/MarketplacePluginResponse.json +7 -0
  117. package/json-schema/api/ObjectQLReference.json +7 -0
  118. package/json-schema/api/OpenApiSecurityScheme.json +7 -0
  119. package/json-schema/api/OpenApiServer.json +7 -0
  120. package/json-schema/api/OpenApiSpec.json +7 -0
  121. package/json-schema/api/PaginationRequest.json +7 -0
  122. package/json-schema/api/PaginationResponse.json +7 -0
  123. package/json-schema/api/PluginResponse.json +7 -0
  124. package/json-schema/api/PluginVersionInfo.json +7 -0
  125. package/json-schema/api/PublishPluginRequest.json +7 -0
  126. package/json-schema/api/RevokeLicenseRequest.json +7 -0
  127. package/json-schema/api/SchemaDefinition.json +7 -0
  128. package/json-schema/api/SearchPluginsRequest.json +7 -0
  129. package/json-schema/api/SearchPluginsResponse.json +7 -0
  130. package/json-schema/api/SpaceResponse.json +7 -0
  131. package/json-schema/api/TenantResponse.json +7 -0
  132. package/json-schema/api/UpdatePluginRequest.json +7 -0
  133. package/json-schema/api/UpdateSpaceRequest.json +7 -0
  134. package/json-schema/api/UpdateTenantRequest.json +7 -0
  135. package/json-schema/api/ValidateLicenseRequest.json +7 -0
  136. package/json-schema/api/ValidateLicenseResponse.json +7 -0
  137. package/json-schema/hub/DependencyConflict.json +7 -0
  138. package/json-schema/hub/DependencyGraph.json +7 -0
  139. package/json-schema/hub/DependencyGraphNode.json +7 -0
  140. package/json-schema/hub/DependencyResolutionResult.json +7 -0
  141. package/json-schema/hub/EdgeLocation.json +7 -0
  142. package/json-schema/hub/FederationTopology.json +7 -0
  143. package/json-schema/hub/GlobalRegistryEntry.json +7 -0
  144. package/json-schema/hub/HubInstance.json +7 -0
  145. package/json-schema/hub/PackageDependency.json +7 -0
  146. package/json-schema/hub/PluginProvenance.json +7 -0
  147. package/json-schema/hub/PluginTrustScore.json +7 -0
  148. package/json-schema/hub/Region.json +7 -0
  149. package/json-schema/hub/ReplicationJob.json +7 -0
  150. package/json-schema/hub/SBOM.json +7 -0
  151. package/json-schema/hub/SBOMEntry.json +7 -0
  152. package/json-schema/hub/SecurityPolicy.json +7 -0
  153. package/json-schema/hub/SecurityScanResult.json +7 -0
  154. package/json-schema/hub/SecurityVulnerability.json +7 -0
  155. package/json-schema/hub/TenantPlacementPolicy.json +7 -0
  156. package/json-schema/hub/VulnerabilitySeverity.json +7 -0
  157. package/json-schema/qa/TestAction.json +7 -0
  158. package/json-schema/qa/TestActionType.json +7 -0
  159. package/json-schema/qa/TestAssertion.json +7 -0
  160. package/json-schema/qa/TestAssertionType.json +7 -0
  161. package/json-schema/qa/TestContext.json +7 -0
  162. package/json-schema/qa/TestScenario.json +7 -0
  163. package/json-schema/qa/TestStep.json +7 -0
  164. package/json-schema/qa/TestSuite.json +7 -0
  165. package/json-schema/system/AddFieldOperation.json +7 -0
  166. package/json-schema/system/ChangeSet.json +7 -0
  167. package/json-schema/system/CreateObjectOperation.json +7 -0
  168. package/json-schema/system/DeleteObjectOperation.json +7 -0
  169. package/json-schema/system/ExecuteSqlOperation.json +7 -0
  170. package/json-schema/system/MigrationDependency.json +7 -0
  171. package/json-schema/system/MigrationOperation.json +7 -0
  172. package/json-schema/system/ModifyFieldOperation.json +7 -0
  173. package/json-schema/system/PluginCaching.json +7 -0
  174. package/json-schema/system/PluginCodeSplitting.json +7 -0
  175. package/json-schema/system/PluginDependencyResolution.json +7 -0
  176. package/json-schema/system/PluginDynamicImport.json +7 -0
  177. package/json-schema/system/PluginHotReload.json +7 -0
  178. package/json-schema/system/PluginInitialization.json +7 -0
  179. package/json-schema/system/PluginLoadingConfig.json +7 -0
  180. package/json-schema/system/PluginLoadingEvent.json +7 -0
  181. package/json-schema/system/PluginLoadingState.json +7 -0
  182. package/json-schema/system/PluginLoadingStrategy.json +7 -0
  183. package/json-schema/system/PluginPerformanceMonitoring.json +7 -0
  184. package/json-schema/system/PluginPreloadConfig.json +7 -0
  185. package/json-schema/system/PluginSandboxing.json +7 -0
  186. package/json-schema/system/RemoveFieldOperation.json +7 -0
  187. package/json-schema/system/RenameObjectOperation.json +7 -0
  188. package/package.json +1 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"documentation.zod.d.ts","sourceRoot":"","sources":["../../src/api/documentation.zod.ts"],"names":[],"mappings":"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"}
@@ -0,0 +1,487 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.OpenApiSpec = exports.ApiTestCollection = exports.ApiDocumentationConfig = exports.GeneratedApiDocumentationSchema = exports.ApiDocumentationConfigSchema = exports.CodeGenerationTemplateSchema = exports.ApiChangelogEntrySchema = exports.ApiTestCollectionSchema = exports.ApiTestRequestSchema = exports.ApiTestingUiConfigSchema = exports.ApiTestingUiType = exports.OpenApiSpecSchema = exports.OpenApiSecuritySchemeSchema = exports.OpenApiServerSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ /**
6
+ * API Documentation & Testing Interface Protocol
7
+ *
8
+ * Provides schemas for generating interactive API documentation and testing
9
+ * interfaces similar to Swagger UI, GraphQL Playground, Postman, etc.
10
+ *
11
+ * Features:
12
+ * - OpenAPI/Swagger specification generation
13
+ * - Interactive API testing playground
14
+ * - API versioning and changelog
15
+ * - Code generation templates
16
+ * - Mock server configuration
17
+ *
18
+ * Architecture Alignment:
19
+ * - Swagger UI: Interactive API documentation
20
+ * - Postman: API testing collections
21
+ * - GraphQL Playground: GraphQL-specific testing
22
+ * - Redoc: Documentation rendering
23
+ *
24
+ * @example Documentation Config
25
+ * ```typescript
26
+ * const docConfig: ApiDocumentationConfig = {
27
+ * enabled: true,
28
+ * title: 'ObjectStack API',
29
+ * version: '1.0.0',
30
+ * servers: [{ url: 'https://api.example.com', description: 'Production' }],
31
+ * ui: {
32
+ * type: 'swagger-ui',
33
+ * theme: 'light',
34
+ * enableTryItOut: true
35
+ * }
36
+ * }
37
+ * ```
38
+ */
39
+ // ==========================================
40
+ // OpenAPI Specification
41
+ // ==========================================
42
+ /**
43
+ * OpenAPI Server Schema
44
+ *
45
+ * Server configuration for OpenAPI specification.
46
+ */
47
+ exports.OpenApiServerSchema = zod_1.z.object({
48
+ /** Server URL */
49
+ url: zod_1.z.string().url().describe('Server base URL'),
50
+ /** Server description */
51
+ description: zod_1.z.string().optional().describe('Server description'),
52
+ /** Server variables */
53
+ variables: zod_1.z.record(zod_1.z.string(), zod_1.z.object({
54
+ default: zod_1.z.string(),
55
+ description: zod_1.z.string().optional(),
56
+ enum: zod_1.z.array(zod_1.z.string()).optional(),
57
+ })).optional().describe('URL template variables'),
58
+ });
59
+ /**
60
+ * OpenAPI Security Scheme Schema
61
+ *
62
+ * Security scheme definition for OpenAPI.
63
+ */
64
+ exports.OpenApiSecuritySchemeSchema = zod_1.z.object({
65
+ /** Security scheme type */
66
+ type: zod_1.z.enum(['apiKey', 'http', 'oauth2', 'openIdConnect']).describe('Security type'),
67
+ /** Scheme name */
68
+ scheme: zod_1.z.string().optional().describe('HTTP auth scheme (bearer, basic, etc.)'),
69
+ /** Bearer format */
70
+ bearerFormat: zod_1.z.string().optional().describe('Bearer token format (e.g., JWT)'),
71
+ /** API key name */
72
+ name: zod_1.z.string().optional().describe('API key parameter name'),
73
+ /** API key location */
74
+ in: zod_1.z.enum(['header', 'query', 'cookie']).optional().describe('API key location'),
75
+ /** OAuth flows */
76
+ flows: zod_1.z.object({
77
+ implicit: zod_1.z.any().optional(),
78
+ password: zod_1.z.any().optional(),
79
+ clientCredentials: zod_1.z.any().optional(),
80
+ authorizationCode: zod_1.z.any().optional(),
81
+ }).optional().describe('OAuth2 flows'),
82
+ /** OpenID Connect URL */
83
+ openIdConnectUrl: zod_1.z.string().url().optional().describe('OpenID Connect discovery URL'),
84
+ /** Description */
85
+ description: zod_1.z.string().optional().describe('Security scheme description'),
86
+ });
87
+ /**
88
+ * OpenAPI Specification Schema
89
+ *
90
+ * Complete OpenAPI 3.0 specification structure.
91
+ *
92
+ * @see https://swagger.io/specification/
93
+ *
94
+ * @example
95
+ * ```json
96
+ * {
97
+ * "openapi": "3.0.0",
98
+ * "info": {
99
+ * "title": "ObjectStack API",
100
+ * "version": "1.0.0",
101
+ * "description": "ObjectStack unified API"
102
+ * },
103
+ * "servers": [
104
+ * { "url": "https://api.example.com" }
105
+ * ],
106
+ * "paths": { ... },
107
+ * "components": { ... }
108
+ * }
109
+ * ```
110
+ */
111
+ exports.OpenApiSpecSchema = zod_1.z.object({
112
+ /** OpenAPI version */
113
+ openapi: zod_1.z.string().default('3.0.0').describe('OpenAPI specification version'),
114
+ /** API information */
115
+ info: zod_1.z.object({
116
+ title: zod_1.z.string().describe('API title'),
117
+ version: zod_1.z.string().describe('API version'),
118
+ description: zod_1.z.string().optional().describe('API description'),
119
+ termsOfService: zod_1.z.string().url().optional().describe('Terms of service URL'),
120
+ contact: zod_1.z.object({
121
+ name: zod_1.z.string().optional(),
122
+ url: zod_1.z.string().url().optional(),
123
+ email: zod_1.z.string().email().optional(),
124
+ }).optional(),
125
+ license: zod_1.z.object({
126
+ name: zod_1.z.string(),
127
+ url: zod_1.z.string().url().optional(),
128
+ }).optional(),
129
+ }).describe('API metadata'),
130
+ /** Servers */
131
+ servers: zod_1.z.array(exports.OpenApiServerSchema).optional().default([]).describe('API servers'),
132
+ /** API paths */
133
+ paths: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).describe('API paths and operations'),
134
+ /** Reusable components */
135
+ components: zod_1.z.object({
136
+ schemas: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
137
+ responses: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
138
+ parameters: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
139
+ examples: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
140
+ requestBodies: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
141
+ headers: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
142
+ securitySchemes: zod_1.z.record(zod_1.z.string(), exports.OpenApiSecuritySchemeSchema).optional(),
143
+ links: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
144
+ callbacks: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional(),
145
+ }).optional().describe('Reusable components'),
146
+ /** Security requirements */
147
+ security: zod_1.z.array(zod_1.z.record(zod_1.z.string(), zod_1.z.array(zod_1.z.string()))).optional()
148
+ .describe('Global security requirements'),
149
+ /** Tags */
150
+ tags: zod_1.z.array(zod_1.z.object({
151
+ name: zod_1.z.string(),
152
+ description: zod_1.z.string().optional(),
153
+ externalDocs: zod_1.z.object({
154
+ description: zod_1.z.string().optional(),
155
+ url: zod_1.z.string().url(),
156
+ }).optional(),
157
+ })).optional().describe('Tag definitions'),
158
+ /** External documentation */
159
+ externalDocs: zod_1.z.object({
160
+ description: zod_1.z.string().optional(),
161
+ url: zod_1.z.string().url(),
162
+ }).optional().describe('External documentation'),
163
+ });
164
+ // ==========================================
165
+ // API Testing Playground
166
+ // ==========================================
167
+ /**
168
+ * API Testing UI Type
169
+ */
170
+ exports.ApiTestingUiType = zod_1.z.enum([
171
+ 'swagger-ui', // Swagger UI
172
+ 'redoc', // Redoc
173
+ 'rapidoc', // RapiDoc
174
+ 'stoplight', // Stoplight Elements
175
+ 'scalar', // Scalar API Reference
176
+ 'graphql-playground', // GraphQL Playground
177
+ 'graphiql', // GraphiQL
178
+ 'postman', // Postman-like interface
179
+ 'custom', // Custom implementation
180
+ ]);
181
+ /**
182
+ * API Testing UI Configuration Schema
183
+ *
184
+ * Configuration for interactive API testing interface.
185
+ *
186
+ * @example Swagger UI Config
187
+ * ```json
188
+ * {
189
+ * "type": "swagger-ui",
190
+ * "path": "/api-docs",
191
+ * "theme": "light",
192
+ * "enableTryItOut": true,
193
+ * "enableFilter": true,
194
+ * "enableCors": true,
195
+ * "defaultModelsExpandDepth": 1
196
+ * }
197
+ * ```
198
+ */
199
+ exports.ApiTestingUiConfigSchema = zod_1.z.object({
200
+ /** UI type */
201
+ type: exports.ApiTestingUiType.describe('Testing UI implementation'),
202
+ /** UI path */
203
+ path: zod_1.z.string().default('/api-docs').describe('URL path for documentation UI'),
204
+ /** UI theme */
205
+ theme: zod_1.z.enum(['light', 'dark', 'auto']).default('light').describe('UI color theme'),
206
+ /** Enable try-it-out feature */
207
+ enableTryItOut: zod_1.z.boolean().default(true).describe('Enable interactive API testing'),
208
+ /** Enable filtering */
209
+ enableFilter: zod_1.z.boolean().default(true).describe('Enable endpoint filtering'),
210
+ /** Enable CORS for testing */
211
+ enableCors: zod_1.z.boolean().default(true).describe('Enable CORS for browser testing'),
212
+ /** Default expand depth for models */
213
+ defaultModelsExpandDepth: zod_1.z.number().int().min(-1).default(1)
214
+ .describe('Default expand depth for schemas (-1 = fully expand)'),
215
+ /** Display request duration */
216
+ displayRequestDuration: zod_1.z.boolean().default(true).describe('Show request duration'),
217
+ /** Syntax highlighting */
218
+ syntaxHighlighting: zod_1.z.boolean().default(true).describe('Enable syntax highlighting'),
219
+ /** Custom CSS URL */
220
+ customCssUrl: zod_1.z.string().url().optional().describe('Custom CSS stylesheet URL'),
221
+ /** Custom JavaScript URL */
222
+ customJsUrl: zod_1.z.string().url().optional().describe('Custom JavaScript URL'),
223
+ /** Layout options */
224
+ layout: zod_1.z.object({
225
+ showExtensions: zod_1.z.boolean().default(false).describe('Show vendor extensions'),
226
+ showCommonExtensions: zod_1.z.boolean().default(false).describe('Show common extensions'),
227
+ deepLinking: zod_1.z.boolean().default(true).describe('Enable deep linking'),
228
+ displayOperationId: zod_1.z.boolean().default(false).describe('Display operation IDs'),
229
+ defaultModelRendering: zod_1.z.enum(['example', 'model']).default('example')
230
+ .describe('Default model rendering mode'),
231
+ defaultModelsExpandDepth: zod_1.z.number().int().default(1).describe('Models expand depth'),
232
+ defaultModelExpandDepth: zod_1.z.number().int().default(1).describe('Single model expand depth'),
233
+ docExpansion: zod_1.z.enum(['list', 'full', 'none']).default('list')
234
+ .describe('Documentation expansion mode'),
235
+ }).optional().describe('Layout configuration'),
236
+ });
237
+ /**
238
+ * API Test Request Schema
239
+ *
240
+ * Represents a saved/example API test request.
241
+ *
242
+ * @example
243
+ * ```json
244
+ * {
245
+ * "name": "Get Customer by ID",
246
+ * "description": "Retrieves a customer record",
247
+ * "method": "GET",
248
+ * "url": "/api/v1/data/customer/123",
249
+ * "headers": {
250
+ * "Authorization": "Bearer {{token}}"
251
+ * },
252
+ * "variables": {
253
+ * "token": "sample_token"
254
+ * }
255
+ * }
256
+ * ```
257
+ */
258
+ exports.ApiTestRequestSchema = zod_1.z.object({
259
+ /** Request name */
260
+ name: zod_1.z.string().describe('Test request name'),
261
+ /** Request description */
262
+ description: zod_1.z.string().optional().describe('Request description'),
263
+ /** HTTP method */
264
+ method: zod_1.z.enum(['GET', 'POST', 'PUT', 'PATCH', 'DELETE', 'HEAD', 'OPTIONS'])
265
+ .describe('HTTP method'),
266
+ /** Request URL */
267
+ url: zod_1.z.string().describe('Request URL (can include variables)'),
268
+ /** Request headers */
269
+ headers: zod_1.z.record(zod_1.z.string(), zod_1.z.string()).optional().default({})
270
+ .describe('Request headers'),
271
+ /** Query parameters */
272
+ queryParams: zod_1.z.record(zod_1.z.string(), zod_1.z.union([zod_1.z.string(), zod_1.z.number(), zod_1.z.boolean()]))
273
+ .optional().default({}).describe('Query parameters'),
274
+ /** Request body */
275
+ body: zod_1.z.any().optional().describe('Request body'),
276
+ /** Environment variables */
277
+ variables: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional().default({})
278
+ .describe('Template variables'),
279
+ /** Expected response */
280
+ expectedResponse: zod_1.z.object({
281
+ statusCode: zod_1.z.number().int(),
282
+ body: zod_1.z.any().optional(),
283
+ }).optional().describe('Expected response for validation'),
284
+ });
285
+ /**
286
+ * API Test Collection Schema
287
+ *
288
+ * Collection of test requests (similar to Postman collections).
289
+ *
290
+ * @example
291
+ * ```json
292
+ * {
293
+ * "name": "Customer API Tests",
294
+ * "description": "Test collection for customer endpoints",
295
+ * "variables": {
296
+ * "baseUrl": "https://api.example.com",
297
+ * "apiKey": "test_key"
298
+ * },
299
+ * "requests": [...]
300
+ * }
301
+ * ```
302
+ */
303
+ exports.ApiTestCollectionSchema = zod_1.z.object({
304
+ /** Collection name */
305
+ name: zod_1.z.string().describe('Collection name'),
306
+ /** Collection description */
307
+ description: zod_1.z.string().optional().describe('Collection description'),
308
+ /** Collection variables */
309
+ variables: zod_1.z.record(zod_1.z.string(), zod_1.z.any()).optional().default({})
310
+ .describe('Shared variables'),
311
+ /** Test requests */
312
+ requests: zod_1.z.array(exports.ApiTestRequestSchema).describe('Test requests in this collection'),
313
+ /** Folders/grouping */
314
+ folders: zod_1.z.array(zod_1.z.object({
315
+ name: zod_1.z.string(),
316
+ description: zod_1.z.string().optional(),
317
+ requests: zod_1.z.array(exports.ApiTestRequestSchema),
318
+ })).optional().describe('Request folders for organization'),
319
+ });
320
+ // ==========================================
321
+ // API Documentation Configuration
322
+ // ==========================================
323
+ /**
324
+ * API Changelog Entry Schema
325
+ *
326
+ * Documents changes in API versions.
327
+ */
328
+ exports.ApiChangelogEntrySchema = zod_1.z.object({
329
+ /** Version */
330
+ version: zod_1.z.string().describe('API version'),
331
+ /** Release date */
332
+ date: zod_1.z.string().date().describe('Release date'),
333
+ /** Changes */
334
+ changes: zod_1.z.object({
335
+ added: zod_1.z.array(zod_1.z.string()).optional().default([]).describe('New features'),
336
+ changed: zod_1.z.array(zod_1.z.string()).optional().default([]).describe('Changes'),
337
+ deprecated: zod_1.z.array(zod_1.z.string()).optional().default([]).describe('Deprecations'),
338
+ removed: zod_1.z.array(zod_1.z.string()).optional().default([]).describe('Removed features'),
339
+ fixed: zod_1.z.array(zod_1.z.string()).optional().default([]).describe('Bug fixes'),
340
+ security: zod_1.z.array(zod_1.z.string()).optional().default([]).describe('Security fixes'),
341
+ }).describe('Version changes'),
342
+ /** Migration guide */
343
+ migrationGuide: zod_1.z.string().optional().describe('Migration guide URL or text'),
344
+ });
345
+ /**
346
+ * Code Generation Template Schema
347
+ *
348
+ * Templates for generating client code.
349
+ */
350
+ exports.CodeGenerationTemplateSchema = zod_1.z.object({
351
+ /** Language/framework */
352
+ language: zod_1.z.string().describe('Target language/framework (e.g., typescript, python, curl)'),
353
+ /** Template name */
354
+ name: zod_1.z.string().describe('Template name'),
355
+ /** Template content */
356
+ template: zod_1.z.string().describe('Code template with placeholders'),
357
+ /** Template variables */
358
+ variables: zod_1.z.array(zod_1.z.string()).optional().describe('Required template variables'),
359
+ });
360
+ /**
361
+ * API Documentation Configuration Schema
362
+ *
363
+ * Complete configuration for API documentation and testing interface.
364
+ *
365
+ * @example
366
+ * ```json
367
+ * {
368
+ * "enabled": true,
369
+ * "title": "ObjectStack API Documentation",
370
+ * "version": "1.0.0",
371
+ * "description": "Unified API for ObjectStack platform",
372
+ * "servers": [
373
+ * { "url": "https://api.example.com", "description": "Production" }
374
+ * ],
375
+ * "ui": {
376
+ * "type": "swagger-ui",
377
+ * "theme": "light",
378
+ * "enableTryItOut": true
379
+ * },
380
+ * "generateOpenApi": true,
381
+ * "generateTestCollections": true
382
+ * }
383
+ * ```
384
+ */
385
+ exports.ApiDocumentationConfigSchema = zod_1.z.object({
386
+ /** Enable documentation */
387
+ enabled: zod_1.z.boolean().default(true).describe('Enable API documentation'),
388
+ /** Documentation title */
389
+ title: zod_1.z.string().default('API Documentation').describe('Documentation title'),
390
+ /** API version */
391
+ version: zod_1.z.string().describe('API version'),
392
+ /** API description */
393
+ description: zod_1.z.string().optional().describe('API description'),
394
+ /** Server configurations */
395
+ servers: zod_1.z.array(exports.OpenApiServerSchema).optional().default([])
396
+ .describe('API server URLs'),
397
+ /** UI configuration */
398
+ ui: exports.ApiTestingUiConfigSchema.optional().describe('Testing UI configuration'),
399
+ /** Generate OpenAPI spec */
400
+ generateOpenApi: zod_1.z.boolean().default(true).describe('Generate OpenAPI 3.0 specification'),
401
+ /** Generate test collections */
402
+ generateTestCollections: zod_1.z.boolean().default(true)
403
+ .describe('Generate API test collections'),
404
+ /** Test collections */
405
+ testCollections: zod_1.z.array(exports.ApiTestCollectionSchema).optional().default([])
406
+ .describe('Predefined test collections'),
407
+ /** API changelog */
408
+ changelog: zod_1.z.array(exports.ApiChangelogEntrySchema).optional().default([])
409
+ .describe('API version changelog'),
410
+ /** Code generation templates */
411
+ codeTemplates: zod_1.z.array(exports.CodeGenerationTemplateSchema).optional().default([])
412
+ .describe('Code generation templates'),
413
+ /** Terms of service */
414
+ termsOfService: zod_1.z.string().url().optional().describe('Terms of service URL'),
415
+ /** Contact information */
416
+ contact: zod_1.z.object({
417
+ name: zod_1.z.string().optional(),
418
+ url: zod_1.z.string().url().optional(),
419
+ email: zod_1.z.string().email().optional(),
420
+ }).optional().describe('Contact information'),
421
+ /** License */
422
+ license: zod_1.z.object({
423
+ name: zod_1.z.string(),
424
+ url: zod_1.z.string().url().optional(),
425
+ }).optional().describe('API license'),
426
+ /** External documentation */
427
+ externalDocs: zod_1.z.object({
428
+ description: zod_1.z.string().optional(),
429
+ url: zod_1.z.string().url(),
430
+ }).optional().describe('External documentation link'),
431
+ /** Security schemes */
432
+ securitySchemes: zod_1.z.record(zod_1.z.string(), exports.OpenApiSecuritySchemeSchema).optional()
433
+ .describe('Security scheme definitions'),
434
+ /** Global tags */
435
+ tags: zod_1.z.array(zod_1.z.object({
436
+ name: zod_1.z.string(),
437
+ description: zod_1.z.string().optional(),
438
+ externalDocs: zod_1.z.object({
439
+ description: zod_1.z.string().optional(),
440
+ url: zod_1.z.string().url(),
441
+ }).optional(),
442
+ })).optional().describe('Global tag definitions'),
443
+ });
444
+ // ==========================================
445
+ // API Documentation Generation
446
+ // ==========================================
447
+ /**
448
+ * Generated API Documentation Schema
449
+ *
450
+ * Output of documentation generation process.
451
+ */
452
+ exports.GeneratedApiDocumentationSchema = zod_1.z.object({
453
+ /** OpenAPI specification */
454
+ openApiSpec: exports.OpenApiSpecSchema.optional().describe('Generated OpenAPI specification'),
455
+ /** Test collections */
456
+ testCollections: zod_1.z.array(exports.ApiTestCollectionSchema).optional()
457
+ .describe('Generated test collections'),
458
+ /** Markdown documentation */
459
+ markdown: zod_1.z.string().optional().describe('Generated markdown documentation'),
460
+ /** HTML documentation */
461
+ html: zod_1.z.string().optional().describe('Generated HTML documentation'),
462
+ /** Generation timestamp */
463
+ generatedAt: zod_1.z.string().datetime().describe('Generation timestamp'),
464
+ /** Source APIs */
465
+ sourceApis: zod_1.z.array(zod_1.z.string()).describe('Source API IDs used for generation'),
466
+ });
467
+ // ==========================================
468
+ // Helper Functions
469
+ // ==========================================
470
+ /**
471
+ * Helper to create API documentation config
472
+ */
473
+ exports.ApiDocumentationConfig = Object.assign(exports.ApiDocumentationConfigSchema, {
474
+ create: (config) => config,
475
+ });
476
+ /**
477
+ * Helper to create API test collection
478
+ */
479
+ exports.ApiTestCollection = Object.assign(exports.ApiTestCollectionSchema, {
480
+ create: (config) => config,
481
+ });
482
+ /**
483
+ * Helper to create OpenAPI specification
484
+ */
485
+ exports.OpenApiSpec = Object.assign(exports.OpenApiSpecSchema, {
486
+ create: (config) => config,
487
+ });
@@ -23,10 +23,10 @@ export declare const ErrorCategory: z.ZodEnum<{
23
23
  validation: "validation";
24
24
  authorization: "authorization";
25
25
  server: "server";
26
- not_found: "not_found";
26
+ maintenance: "maintenance";
27
27
  conflict: "conflict";
28
+ not_found: "not_found";
28
29
  rate_limit: "rate_limit";
29
- maintenance: "maintenance";
30
30
  }>;
31
31
  export type ErrorCategory = z.infer<typeof ErrorCategory>;
32
32
  /**
@@ -277,10 +277,10 @@ export declare const EnhancedApiErrorSchema: z.ZodObject<{
277
277
  validation: "validation";
278
278
  authorization: "authorization";
279
279
  server: "server";
280
- not_found: "not_found";
280
+ maintenance: "maintenance";
281
281
  conflict: "conflict";
282
+ not_found: "not_found";
282
283
  rate_limit: "rate_limit";
283
- maintenance: "maintenance";
284
284
  }>>;
285
285
  httpStatus: z.ZodOptional<z.ZodNumber>;
286
286
  retryable: z.ZodDefault<z.ZodBoolean>;
@@ -437,10 +437,10 @@ export declare const ErrorResponseSchema: z.ZodObject<{
437
437
  validation: "validation";
438
438
  authorization: "authorization";
439
439
  server: "server";
440
- not_found: "not_found";
440
+ maintenance: "maintenance";
441
441
  conflict: "conflict";
442
+ not_found: "not_found";
442
443
  rate_limit: "rate_limit";
443
- maintenance: "maintenance";
444
444
  }>>;
445
445
  httpStatus: z.ZodOptional<z.ZodNumber>;
446
446
  retryable: z.ZodDefault<z.ZodBoolean>;
@@ -157,8 +157,8 @@ export declare const GraphQLQueryConfigSchema: z.ZodObject<{
157
157
  gt: "gt";
158
158
  gte: "gte";
159
159
  eq: "eq";
160
- ne: "ne";
161
160
  contains: "contains";
161
+ ne: "ne";
162
162
  notIn: "notIn";
163
163
  isNull: "isNull";
164
164
  isNotNull: "isNotNull";
@@ -619,8 +619,8 @@ export declare const GraphQLConfigSchema: z.ZodObject<{
619
619
  gt: "gt";
620
620
  gte: "gte";
621
621
  eq: "eq";
622
- ne: "ne";
623
622
  contains: "contains";
623
+ ne: "ne";
624
624
  notIn: "notIn";
625
625
  isNull: "isNull";
626
626
  isNotNull: "isNotNull";
@@ -995,8 +995,8 @@ export declare const GraphQLConfig: z.ZodObject<{
995
995
  gt: "gt";
996
996
  gte: "gte";
997
997
  eq: "eq";
998
- ne: "ne";
999
998
  contains: "contains";
999
+ ne: "ne";
1000
1000
  notIn: "notIn";
1001
1001
  isNull: "isNull";
1002
1002
  isNotNull: "isNotNull";