@skmtc/core 0.0.796 → 0.0.798
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/esm/app/validate.d.ts +32 -0
- package/esm/app/validate.d.ts.map +1 -1
- package/esm/app/validate.js +32 -0
- package/esm/context/CoreContext.d.ts +147 -2
- package/esm/context/CoreContext.d.ts.map +1 -1
- package/esm/context/CoreContext.js +87 -0
- package/esm/context/GenerateContext.d.ts +180 -0
- package/esm/context/GenerateContext.d.ts.map +1 -1
- package/esm/context/GenerateContext.js +25 -0
- package/esm/context/ParseContext.d.ts +6 -0
- package/esm/context/ParseContext.d.ts.map +1 -1
- package/esm/context/ParseContext.js +6 -0
- package/esm/dsl/constants.d.ts +28 -0
- package/esm/dsl/constants.d.ts.map +1 -1
- package/esm/dsl/constants.js +28 -0
- package/esm/oas/_helpers/parseDefault.d.ts +148 -0
- package/esm/oas/_helpers/parseDefault.d.ts.map +1 -1
- package/esm/oas/_helpers/parseDefault.js +128 -0
- package/esm/oas/_helpers/parseEnum.d.ts +124 -0
- package/esm/oas/_helpers/parseEnum.d.ts.map +1 -1
- package/esm/oas/_helpers/parseEnum.js +104 -0
- package/esm/oas/_helpers/parseExample.d.ts +107 -0
- package/esm/oas/_helpers/parseExample.d.ts.map +1 -1
- package/esm/oas/_helpers/parseExample.js +87 -0
- package/esm/oas/_helpers/parseFormat.d.ts +154 -0
- package/esm/oas/_helpers/parseFormat.d.ts.map +1 -1
- package/esm/oas/_helpers/parseFormat.js +138 -0
- package/esm/oas/_helpers/parseNullable.d.ts +127 -0
- package/esm/oas/_helpers/parseNullable.d.ts.map +1 -1
- package/esm/oas/_helpers/parseNullable.js +113 -0
- package/esm/oas/example/toExamplesV3.d.ts +39 -0
- package/esm/oas/example/toExamplesV3.d.ts.map +1 -1
- package/esm/oas/example/toExamplesV3.js +29 -0
- package/esm/oas/object/Object.d.ts +6 -0
- package/esm/oas/object/Object.d.ts.map +1 -1
- package/esm/oas/object/Object.js +6 -0
- package/esm/oas/operation/Operation.d.ts +34 -0
- package/esm/oas/operation/Operation.d.ts.map +1 -1
- package/esm/oas/operation/Operation.js +14 -0
- package/esm/oas/parameter/Parameter.d.ts +3 -0
- package/esm/oas/parameter/Parameter.d.ts.map +1 -1
- package/esm/oas/parameter/Parameter.js +3 -0
- package/esm/oas/ref/ref-types.d.ts +42 -0
- package/esm/oas/ref/ref-types.d.ts.map +1 -1
- package/esm/oas/ref/ref-types.js +9 -0
- package/esm/oas/securitySchemes/security-scheme-types.d.ts +63 -0
- package/esm/oas/securitySchemes/security-scheme-types.d.ts.map +1 -1
- package/esm/oas/securitySchemes/security-scheme-types.js +15 -0
- package/esm/run/toV3JsonDocument.d.ts +90 -0
- package/esm/run/toV3JsonDocument.d.ts.map +1 -1
- package/esm/run/toV3JsonDocument.js +84 -0
- package/esm/types/Results.d.ts +32 -0
- package/esm/types/Results.d.ts.map +1 -1
- package/esm/types/Results.js +12 -0
- package/package.json +1 -1
- package/script/app/validate.d.ts +32 -0
- package/script/app/validate.d.ts.map +1 -1
- package/script/app/validate.js +32 -0
- package/script/context/CoreContext.d.ts +147 -2
- package/script/context/CoreContext.d.ts.map +1 -1
- package/script/context/CoreContext.js +87 -0
- package/script/context/GenerateContext.d.ts +180 -0
- package/script/context/GenerateContext.d.ts.map +1 -1
- package/script/context/GenerateContext.js +25 -0
- package/script/context/ParseContext.d.ts +6 -0
- package/script/context/ParseContext.d.ts.map +1 -1
- package/script/context/ParseContext.js +6 -0
- package/script/dsl/constants.d.ts +28 -0
- package/script/dsl/constants.d.ts.map +1 -1
- package/script/dsl/constants.js +28 -0
- package/script/oas/_helpers/parseDefault.d.ts +148 -0
- package/script/oas/_helpers/parseDefault.d.ts.map +1 -1
- package/script/oas/_helpers/parseDefault.js +128 -0
- package/script/oas/_helpers/parseEnum.d.ts +124 -0
- package/script/oas/_helpers/parseEnum.d.ts.map +1 -1
- package/script/oas/_helpers/parseEnum.js +104 -0
- package/script/oas/_helpers/parseExample.d.ts +107 -0
- package/script/oas/_helpers/parseExample.d.ts.map +1 -1
- package/script/oas/_helpers/parseExample.js +87 -0
- package/script/oas/_helpers/parseFormat.d.ts +154 -0
- package/script/oas/_helpers/parseFormat.d.ts.map +1 -1
- package/script/oas/_helpers/parseFormat.js +138 -0
- package/script/oas/_helpers/parseNullable.d.ts +127 -0
- package/script/oas/_helpers/parseNullable.d.ts.map +1 -1
- package/script/oas/_helpers/parseNullable.js +113 -0
- package/script/oas/example/toExamplesV3.d.ts +39 -0
- package/script/oas/example/toExamplesV3.d.ts.map +1 -1
- package/script/oas/example/toExamplesV3.js +29 -0
- package/script/oas/object/Object.d.ts +6 -0
- package/script/oas/object/Object.d.ts.map +1 -1
- package/script/oas/object/Object.js +6 -0
- package/script/oas/operation/Operation.d.ts +34 -0
- package/script/oas/operation/Operation.d.ts.map +1 -1
- package/script/oas/operation/Operation.js +14 -0
- package/script/oas/parameter/Parameter.d.ts +3 -0
- package/script/oas/parameter/Parameter.d.ts.map +1 -1
- package/script/oas/parameter/Parameter.js +3 -0
- package/script/oas/ref/ref-types.d.ts +42 -0
- package/script/oas/ref/ref-types.d.ts.map +1 -1
- package/script/oas/ref/ref-types.js +9 -0
- package/script/oas/securitySchemes/security-scheme-types.d.ts +63 -0
- package/script/oas/securitySchemes/security-scheme-types.d.ts.map +1 -1
- package/script/oas/securitySchemes/security-scheme-types.js +15 -0
- package/script/run/toV3JsonDocument.d.ts +90 -0
- package/script/run/toV3JsonDocument.d.ts.map +1 -1
- package/script/run/toV3JsonDocument.js +84 -0
- package/script/types/Results.d.ts +32 -0
- package/script/types/Results.d.ts.map +1 -1
- package/script/types/Results.js +12 -0
|
@@ -5,18 +5,57 @@ import type { OasRef } from '../ref/Ref.js';
|
|
|
5
5
|
type ToExampleSimpleV3Args = {
|
|
6
6
|
example: unknown;
|
|
7
7
|
};
|
|
8
|
+
/**
|
|
9
|
+
* Creates a simple OAS example from a value.
|
|
10
|
+
*
|
|
11
|
+
* Converts a raw example value into an OasExample object with basic
|
|
12
|
+
* fields. Used for simple example scenarios where only the value matters.
|
|
13
|
+
*
|
|
14
|
+
* @param args - Arguments containing the example value
|
|
15
|
+
* @returns OasExample object with the provided value
|
|
16
|
+
*/
|
|
8
17
|
export declare const toExampleSimpleV3: ({ example }: ToExampleSimpleV3Args) => OasExample | OasRef<"example">;
|
|
18
|
+
/**
|
|
19
|
+
* Arguments for processing OpenAPI v3 examples into OAS example objects.
|
|
20
|
+
*
|
|
21
|
+
* Handles both single example and examples collection scenarios,
|
|
22
|
+
* with context for tracing and error handling.
|
|
23
|
+
*/
|
|
9
24
|
export type ToExamplesV3Args = {
|
|
25
|
+
/** Single example object (OpenAPI v3 format) */
|
|
10
26
|
example: OpenAPIV3.ExampleObject | undefined;
|
|
27
|
+
/** Collection of named examples (OpenAPI v3 format) */
|
|
11
28
|
examples: Record<string, OpenAPIV3.ExampleObject | OpenAPIV3.ReferenceObject> | undefined;
|
|
29
|
+
/** Key name for the example context */
|
|
12
30
|
exampleKey: string;
|
|
31
|
+
/** Parse context for tracing and error handling */
|
|
13
32
|
context: ParseContext;
|
|
14
33
|
};
|
|
34
|
+
/**
|
|
35
|
+
* Processes OpenAPI v3 examples into OAS example objects.
|
|
36
|
+
*
|
|
37
|
+
* Handles both single example and examples collection scenarios,
|
|
38
|
+
* converting them to the internal OAS representation. Provides
|
|
39
|
+
* warnings when both formats are specified simultaneously.
|
|
40
|
+
*
|
|
41
|
+
* @param args - Arguments containing example data and context
|
|
42
|
+
* @returns Record of processed examples, or undefined if no examples
|
|
43
|
+
*/
|
|
15
44
|
export declare const toExamplesV3: ({ example, examples, exampleKey, context }: ToExamplesV3Args) => Record<string, OasExample | OasRef<"example">> | undefined;
|
|
16
45
|
type ToExampleV3Args = {
|
|
17
46
|
example: OpenAPIV3.ExampleObject | OpenAPIV3.ReferenceObject;
|
|
18
47
|
context: ParseContext;
|
|
19
48
|
};
|
|
49
|
+
/**
|
|
50
|
+
* Processes a single OpenAPI v3 example into an OAS example object.
|
|
51
|
+
*
|
|
52
|
+
* Converts OpenAPI v3 example objects or references into the internal
|
|
53
|
+
* OAS representation, handling both direct examples and $ref references.
|
|
54
|
+
* Processes specification extensions and maintains all example metadata.
|
|
55
|
+
*
|
|
56
|
+
* @param args - Arguments containing the example and parsing context
|
|
57
|
+
* @returns OasExample object or reference to an example
|
|
58
|
+
*/
|
|
20
59
|
export declare const toExampleV3: ({ example, context }: ToExampleV3Args) => OasExample | OasRef<"example">;
|
|
21
60
|
export {};
|
|
22
61
|
//# sourceMappingURL=toExamplesV3.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"toExamplesV3.d.ts","sourceRoot":"","sources":["../../../src/oas/example/toExamplesV3.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAA;AACjE,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AAG9C,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAEzC,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAG3C,KAAK,qBAAqB,GAAG;IAC3B,OAAO,EAAE,OAAO,CAAA;CACjB,CAAA;AAED,eAAO,MAAM,iBAAiB,GAAI,aAE/B,qBAAqB,KAAG,UAAU,GAAG,MAAM,CAAC,SAAS,CAQvD,CAAA;AAED,MAAM,MAAM,gBAAgB,GAAG;IAC7B,OAAO,EAAE,SAAS,CAAC,aAAa,GAAG,SAAS,CAAA;IAC5C,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,SAAS,CAAC,aAAa,GAAG,SAAS,CAAC,eAAe,CAAC,GAAG,SAAS,CAAA;IACzF,UAAU,EAAE,MAAM,CAAA;IAClB,OAAO,EAAE,YAAY,CAAA;CACtB,CAAA;AAED,eAAO,MAAM,YAAY,GAAI,4CAK1B,gBAAgB,KAAG,MAAM,CAAC,MAAM,EAAE,UAAU,GAAG,MAAM,CAAC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,CAAC,CAAC,GAAG,SAsBtE,CAAA;AAED,KAAK,eAAe,GAAG;IACrB,OAAO,EAAE,SAAS,CAAC,aAAa,GAAG,SAAS,CAAC,eAAe,CAAA;IAC5D,OAAO,EAAE,YAAY,CAAA;CACtB,CAAA;AAED;;;;;;;;;GASG;AACH,eAAO,MAAM,WAAW,GAAI,sBAGzB,eAAe,KAAG,UAAU,GAAG,MAAM,CAAC,SAAS,CAoBjD,CAAA"}
|
|
@@ -5,6 +5,15 @@ const refFns_js_1 = require("../../helpers/refFns.js");
|
|
|
5
5
|
const toRefV31_js_1 = require("../ref/toRefV31.js");
|
|
6
6
|
const Example_js_1 = require("./Example.js");
|
|
7
7
|
const toSpecificationExtensionsV3_js_1 = require("../specificationExtensions/toSpecificationExtensionsV3.js");
|
|
8
|
+
/**
|
|
9
|
+
* Creates a simple OAS example from a value.
|
|
10
|
+
*
|
|
11
|
+
* Converts a raw example value into an OasExample object with basic
|
|
12
|
+
* fields. Used for simple example scenarios where only the value matters.
|
|
13
|
+
*
|
|
14
|
+
* @param args - Arguments containing the example value
|
|
15
|
+
* @returns OasExample object with the provided value
|
|
16
|
+
*/
|
|
8
17
|
const toExampleSimpleV3 = ({ example }) => {
|
|
9
18
|
const fields = {
|
|
10
19
|
value: example,
|
|
@@ -14,6 +23,16 @@ const toExampleSimpleV3 = ({ example }) => {
|
|
|
14
23
|
return new Example_js_1.OasExample(fields);
|
|
15
24
|
};
|
|
16
25
|
exports.toExampleSimpleV3 = toExampleSimpleV3;
|
|
26
|
+
/**
|
|
27
|
+
* Processes OpenAPI v3 examples into OAS example objects.
|
|
28
|
+
*
|
|
29
|
+
* Handles both single example and examples collection scenarios,
|
|
30
|
+
* converting them to the internal OAS representation. Provides
|
|
31
|
+
* warnings when both formats are specified simultaneously.
|
|
32
|
+
*
|
|
33
|
+
* @param args - Arguments containing example data and context
|
|
34
|
+
* @returns Record of processed examples, or undefined if no examples
|
|
35
|
+
*/
|
|
17
36
|
const toExamplesV3 = ({ example, examples, exampleKey, context }) => {
|
|
18
37
|
if (example && examples) {
|
|
19
38
|
context.logger.warn(`Both example and examples are defined for ${exampleKey}`);
|
|
@@ -33,6 +52,16 @@ const toExamplesV3 = ({ example, examples, exampleKey, context }) => {
|
|
|
33
52
|
return undefined;
|
|
34
53
|
};
|
|
35
54
|
exports.toExamplesV3 = toExamplesV3;
|
|
55
|
+
/**
|
|
56
|
+
* Processes a single OpenAPI v3 example into an OAS example object.
|
|
57
|
+
*
|
|
58
|
+
* Converts OpenAPI v3 example objects or references into the internal
|
|
59
|
+
* OAS representation, handling both direct examples and $ref references.
|
|
60
|
+
* Processes specification extensions and maintains all example metadata.
|
|
61
|
+
*
|
|
62
|
+
* @param args - Arguments containing the example and parsing context
|
|
63
|
+
* @returns OasExample object or reference to an example
|
|
64
|
+
*/
|
|
36
65
|
const toExampleV3 = ({ example, context }) => {
|
|
37
66
|
if ((0, refFns_js_1.isRef)(example)) {
|
|
38
67
|
return (0, toRefV31_js_1.toRefV31)({ ref: example, refType: 'example', context });
|
|
@@ -182,11 +182,17 @@ export declare class OasObject<Nullable extends boolean | undefined = boolean |
|
|
|
182
182
|
* The default value of the object.
|
|
183
183
|
*/
|
|
184
184
|
default: Nullable extends true ? Record<string, unknown> | null | undefined : Record<string, unknown> | undefined;
|
|
185
|
+
/** Maximum number of properties allowed in the object */
|
|
185
186
|
maxProperties?: number;
|
|
187
|
+
/** Minimum number of properties required in the object */
|
|
186
188
|
minProperties?: number;
|
|
189
|
+
/** Whether the object is read-only */
|
|
187
190
|
readOnly?: boolean;
|
|
191
|
+
/** Whether the object is write-only */
|
|
188
192
|
writeOnly?: boolean;
|
|
193
|
+
/** Whether the object schema is deprecated */
|
|
189
194
|
deprecated?: boolean;
|
|
195
|
+
/** Array of valid enum values for the object */
|
|
190
196
|
enums?: Nullable extends true ? (Record<string, unknown> | null)[] | undefined : Record<string, unknown>[] | undefined;
|
|
191
197
|
/**
|
|
192
198
|
* Creates a new OasObject instance.
|
|
@@ -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AAE,EAAE,eAAe,GAAG,SAAS;IAmBnE;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA4BG;IACH,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,SAAS;IAkBvC,KAAK,IAAI,IAAI,IAAI,MAAM,CAAC,QAAQ,CAAC;IAIjC,OAAO,IAAI,SAAS;IAIpB,WAAW,IAAI,SAAS;IAIxB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAoCG;IACH,YAAY,CAAC,OAAO,EAAE,mBAAmB,GAAG,SAAS,CAAC,oBAAoB;CA8B3E"}
|
|
@@ -208,36 +208,42 @@ class OasObject {
|
|
|
208
208
|
writable: true,
|
|
209
209
|
value: void 0
|
|
210
210
|
});
|
|
211
|
+
/** Maximum number of properties allowed in the object */
|
|
211
212
|
Object.defineProperty(this, "maxProperties", {
|
|
212
213
|
enumerable: true,
|
|
213
214
|
configurable: true,
|
|
214
215
|
writable: true,
|
|
215
216
|
value: void 0
|
|
216
217
|
});
|
|
218
|
+
/** Minimum number of properties required in the object */
|
|
217
219
|
Object.defineProperty(this, "minProperties", {
|
|
218
220
|
enumerable: true,
|
|
219
221
|
configurable: true,
|
|
220
222
|
writable: true,
|
|
221
223
|
value: void 0
|
|
222
224
|
});
|
|
225
|
+
/** Whether the object is read-only */
|
|
223
226
|
Object.defineProperty(this, "readOnly", {
|
|
224
227
|
enumerable: true,
|
|
225
228
|
configurable: true,
|
|
226
229
|
writable: true,
|
|
227
230
|
value: void 0
|
|
228
231
|
});
|
|
232
|
+
/** Whether the object is write-only */
|
|
229
233
|
Object.defineProperty(this, "writeOnly", {
|
|
230
234
|
enumerable: true,
|
|
231
235
|
configurable: true,
|
|
232
236
|
writable: true,
|
|
233
237
|
value: void 0
|
|
234
238
|
});
|
|
239
|
+
/** Whether the object schema is deprecated */
|
|
235
240
|
Object.defineProperty(this, "deprecated", {
|
|
236
241
|
enumerable: true,
|
|
237
242
|
configurable: true,
|
|
238
243
|
writable: true,
|
|
239
244
|
value: void 0
|
|
240
245
|
});
|
|
246
|
+
/** Array of valid enum values for the object */
|
|
241
247
|
Object.defineProperty(this, "enums", {
|
|
242
248
|
enumerable: true,
|
|
243
249
|
configurable: true,
|
|
@@ -11,19 +11,39 @@ import { OasObject } from '../object/Object.js';
|
|
|
11
11
|
import type { ToJsonSchemaOptions } from '../schema/Schema.js';
|
|
12
12
|
import type { OpenAPIV3 } from 'openapi-types';
|
|
13
13
|
import type { OasSecurityRequirement } from '../securityRequirement/SecurityRequirement.js';
|
|
14
|
+
/**
|
|
15
|
+
* Fields for configuring an OpenAPI operation object.
|
|
16
|
+
*
|
|
17
|
+
* Contains all the properties needed to define a complete OpenAPI operation,
|
|
18
|
+
* including path information, parameters, request/response specifications,
|
|
19
|
+
* security requirements, and metadata.
|
|
20
|
+
*/
|
|
14
21
|
export type OperationFields = {
|
|
22
|
+
/** The API path for this operation */
|
|
15
23
|
path: string;
|
|
24
|
+
/** The HTTP method for this operation */
|
|
16
25
|
method: Method;
|
|
26
|
+
/** The parent path item containing this operation */
|
|
17
27
|
pathItem: OasPathItem | undefined;
|
|
28
|
+
/** Unique identifier for the operation */
|
|
18
29
|
operationId?: string | undefined;
|
|
30
|
+
/** Brief summary of the operation */
|
|
19
31
|
summary?: string | undefined;
|
|
32
|
+
/** Tags for organizing operations in documentation */
|
|
20
33
|
tags?: string[] | undefined;
|
|
34
|
+
/** Detailed description of the operation */
|
|
21
35
|
description?: string | undefined;
|
|
36
|
+
/** Parameters accepted by this operation */
|
|
22
37
|
parameters?: (OasParameter | OasRef<'parameter'>)[] | undefined;
|
|
38
|
+
/** Request body specification for this operation */
|
|
23
39
|
requestBody?: OasRequestBody | OasRef<'requestBody'> | undefined;
|
|
40
|
+
/** Response specifications mapped by status code */
|
|
24
41
|
responses: Record<string, OasResponse | OasRef<'response'>>;
|
|
42
|
+
/** Security requirements for this operation */
|
|
25
43
|
security?: OasSecurityRequirement[] | undefined;
|
|
44
|
+
/** Whether this operation is deprecated */
|
|
26
45
|
deprecated?: boolean | undefined;
|
|
46
|
+
/** OpenAPI specification extensions */
|
|
27
47
|
extensionFields?: Record<string, unknown>;
|
|
28
48
|
};
|
|
29
49
|
type ToRequestBodyMapArgs = {
|
|
@@ -138,19 +158,33 @@ type ToRequestBodyMapArgs = {
|
|
|
138
158
|
* ```
|
|
139
159
|
*/
|
|
140
160
|
export declare class OasOperation {
|
|
161
|
+
/** Type identifier for OAS operation objects */
|
|
141
162
|
oasType: 'operation';
|
|
163
|
+
/** The API path for this operation */
|
|
142
164
|
path: string;
|
|
165
|
+
/** The HTTP method for this operation */
|
|
143
166
|
method: Method;
|
|
167
|
+
/** The parent path item containing this operation */
|
|
144
168
|
pathItem: OasPathItem | undefined;
|
|
169
|
+
/** Unique identifier for the operation */
|
|
145
170
|
operationId: string | undefined;
|
|
171
|
+
/** Brief summary of the operation */
|
|
146
172
|
summary: string | undefined;
|
|
173
|
+
/** Tags for organizing operations in documentation */
|
|
147
174
|
tags: string[] | undefined;
|
|
175
|
+
/** Detailed description of the operation */
|
|
148
176
|
description: string | undefined;
|
|
177
|
+
/** Parameters accepted by this operation */
|
|
149
178
|
parameters: (OasParameter | OasRef<'parameter'>)[] | undefined;
|
|
179
|
+
/** Request body specification for this operation */
|
|
150
180
|
requestBody: OasRequestBody | OasRef<'requestBody'> | undefined;
|
|
181
|
+
/** Response specifications mapped by status code */
|
|
151
182
|
responses: Record<string, OasResponse | OasRef<'response'>>;
|
|
183
|
+
/** Security requirements for this operation */
|
|
152
184
|
security: OasSecurityRequirement[] | undefined;
|
|
185
|
+
/** Whether this operation is deprecated */
|
|
153
186
|
deprecated: boolean | undefined;
|
|
187
|
+
/** OpenAPI specification extensions */
|
|
154
188
|
extensionFields: Record<string, unknown> | undefined;
|
|
155
189
|
constructor(fields: OperationFields);
|
|
156
190
|
toSuccessResponse(): OasResponse | OasRef<'response'> | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Operation.d.ts","sourceRoot":"","sources":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nC,iBAAiB,IAAI,WAAW,GAAG,MAAM,CAAC,UAAU,CAAC,GAAG,SAAS;IAMjE,qBAAqB,IAAI,MAAM,GAAG,SAAS;IAiB3C,aAAa,CAAC,CAAC,EACb,GAAG,EAAE,CAAC,EAAE,MAAM,EAAE,WAAW,EAAE,EAAE,oBAAoB,KAAK,CAAC,EACzD,SAAS,SAAqB,GAC7B,CAAC,GAAG,SAAS;IAOhB;;;;;OAKG;IACH,QAAQ,CAAC,MAAM,CAAC,EAAE,oBAAoB,EAAE,GAAG,YAAY,EAAE;IAQzD,kBAAkB,CAAC,MAAM,CAAC,EAAE,oBAAoB,EAAE,GAAG,SAAS;IAY9D,YAAY,CAAC,OAAO,EAAE,mBAAmB,GAAG,SAAS,CAAC,eAAe;IAiBrE,MAAM,IAAI,MAAM;CAcjB"}
|
|
@@ -112,84 +112,98 @@ const Object_js_1 = require("../object/Object.js");
|
|
|
112
112
|
*/
|
|
113
113
|
class OasOperation {
|
|
114
114
|
constructor(fields) {
|
|
115
|
+
/** Type identifier for OAS operation objects */
|
|
115
116
|
Object.defineProperty(this, "oasType", {
|
|
116
117
|
enumerable: true,
|
|
117
118
|
configurable: true,
|
|
118
119
|
writable: true,
|
|
119
120
|
value: 'operation'
|
|
120
121
|
});
|
|
122
|
+
/** The API path for this operation */
|
|
121
123
|
Object.defineProperty(this, "path", {
|
|
122
124
|
enumerable: true,
|
|
123
125
|
configurable: true,
|
|
124
126
|
writable: true,
|
|
125
127
|
value: void 0
|
|
126
128
|
});
|
|
129
|
+
/** The HTTP method for this operation */
|
|
127
130
|
Object.defineProperty(this, "method", {
|
|
128
131
|
enumerable: true,
|
|
129
132
|
configurable: true,
|
|
130
133
|
writable: true,
|
|
131
134
|
value: void 0
|
|
132
135
|
});
|
|
136
|
+
/** The parent path item containing this operation */
|
|
133
137
|
Object.defineProperty(this, "pathItem", {
|
|
134
138
|
enumerable: true,
|
|
135
139
|
configurable: true,
|
|
136
140
|
writable: true,
|
|
137
141
|
value: void 0
|
|
138
142
|
});
|
|
143
|
+
/** Unique identifier for the operation */
|
|
139
144
|
Object.defineProperty(this, "operationId", {
|
|
140
145
|
enumerable: true,
|
|
141
146
|
configurable: true,
|
|
142
147
|
writable: true,
|
|
143
148
|
value: void 0
|
|
144
149
|
});
|
|
150
|
+
/** Brief summary of the operation */
|
|
145
151
|
Object.defineProperty(this, "summary", {
|
|
146
152
|
enumerable: true,
|
|
147
153
|
configurable: true,
|
|
148
154
|
writable: true,
|
|
149
155
|
value: void 0
|
|
150
156
|
});
|
|
157
|
+
/** Tags for organizing operations in documentation */
|
|
151
158
|
Object.defineProperty(this, "tags", {
|
|
152
159
|
enumerable: true,
|
|
153
160
|
configurable: true,
|
|
154
161
|
writable: true,
|
|
155
162
|
value: void 0
|
|
156
163
|
});
|
|
164
|
+
/** Detailed description of the operation */
|
|
157
165
|
Object.defineProperty(this, "description", {
|
|
158
166
|
enumerable: true,
|
|
159
167
|
configurable: true,
|
|
160
168
|
writable: true,
|
|
161
169
|
value: void 0
|
|
162
170
|
});
|
|
171
|
+
/** Parameters accepted by this operation */
|
|
163
172
|
Object.defineProperty(this, "parameters", {
|
|
164
173
|
enumerable: true,
|
|
165
174
|
configurable: true,
|
|
166
175
|
writable: true,
|
|
167
176
|
value: void 0
|
|
168
177
|
});
|
|
178
|
+
/** Request body specification for this operation */
|
|
169
179
|
Object.defineProperty(this, "requestBody", {
|
|
170
180
|
enumerable: true,
|
|
171
181
|
configurable: true,
|
|
172
182
|
writable: true,
|
|
173
183
|
value: void 0
|
|
174
184
|
});
|
|
185
|
+
/** Response specifications mapped by status code */
|
|
175
186
|
Object.defineProperty(this, "responses", {
|
|
176
187
|
enumerable: true,
|
|
177
188
|
configurable: true,
|
|
178
189
|
writable: true,
|
|
179
190
|
value: void 0
|
|
180
191
|
});
|
|
192
|
+
/** Security requirements for this operation */
|
|
181
193
|
Object.defineProperty(this, "security", {
|
|
182
194
|
enumerable: true,
|
|
183
195
|
configurable: true,
|
|
184
196
|
writable: true,
|
|
185
197
|
value: void 0
|
|
186
198
|
});
|
|
199
|
+
/** Whether this operation is deprecated */
|
|
187
200
|
Object.defineProperty(this, "deprecated", {
|
|
188
201
|
enumerable: true,
|
|
189
202
|
configurable: true,
|
|
190
203
|
writable: true,
|
|
191
204
|
value: void 0
|
|
192
205
|
});
|
|
206
|
+
/** OpenAPI specification extensions */
|
|
193
207
|
Object.defineProperty(this, "extensionFields", {
|
|
194
208
|
enumerable: true,
|
|
195
209
|
configurable: true,
|
|
@@ -182,8 +182,11 @@ export type ParameterFields = {
|
|
|
182
182
|
* ```
|
|
183
183
|
*/
|
|
184
184
|
export declare class OasParameter {
|
|
185
|
+
/** Type identifier for OAS parameter objects */
|
|
185
186
|
oasType: 'parameter';
|
|
187
|
+
/** The name of the parameter */
|
|
186
188
|
name: string;
|
|
189
|
+
/** Where the parameter is located (path, query, header, cookie) */
|
|
187
190
|
location: OasParameterLocation;
|
|
188
191
|
description?: string | undefined;
|
|
189
192
|
required?: boolean | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Parameter.d.ts","sourceRoot":"","sources":["../../../src/oas/parameter/Parameter.ts"],"names":[],"mappings":"AAAA,OAAO,yBAAyB,CAAC;AACjC,OAAO,KAAK,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAA;AACnF,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAA;AAC7D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAC3C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAA;AACvD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,qBAAqB,CAAA;AACpD,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,qBAAqB,CAAA;AAC9D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AAK9C;;GAEG;AACH,MAAM,MAAM,eAAe,GAAG;IAC5B,gCAA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");
|
|
|
148
148
|
*/
|
|
149
149
|
class OasParameter {
|
|
150
150
|
constructor(fields) {
|
|
151
|
+
/** Type identifier for OAS parameter objects */
|
|
151
152
|
Object.defineProperty(this, "oasType", {
|
|
152
153
|
enumerable: true,
|
|
153
154
|
configurable: true,
|
|
154
155
|
writable: true,
|
|
155
156
|
value: 'parameter'
|
|
156
157
|
});
|
|
158
|
+
/** The name of the parameter */
|
|
157
159
|
Object.defineProperty(this, "name", {
|
|
158
160
|
enumerable: true,
|
|
159
161
|
configurable: true,
|
|
160
162
|
writable: true,
|
|
161
163
|
value: void 0
|
|
162
164
|
});
|
|
165
|
+
/** Where the parameter is located (path, query, header, cookie) */
|
|
163
166
|
Object.defineProperty(this, "location", {
|
|
164
167
|
enumerable: true,
|
|
165
168
|
configurable: true,
|
|
@@ -1,27 +1,69 @@
|
|
|
1
1
|
import * as v from 'valibot';
|
|
2
|
+
/**
|
|
3
|
+
* Data type for OpenAPI schema reference objects.
|
|
4
|
+
*
|
|
5
|
+
* Represents $ref references to schema objects in OpenAPI documents,
|
|
6
|
+
* allowing for component reuse and circular reference handling.
|
|
7
|
+
*/
|
|
2
8
|
export type OasSchemaRefData = {
|
|
9
|
+
/** Type identifier for OAS reference objects */
|
|
3
10
|
oasType: 'ref';
|
|
11
|
+
/** The type of object being referenced */
|
|
4
12
|
refType: 'schema';
|
|
13
|
+
/** The reference path (e.g., '#/components/schemas/User') */
|
|
5
14
|
$ref: string;
|
|
15
|
+
/** Optional summary for the reference */
|
|
6
16
|
summary?: string;
|
|
17
|
+
/** Optional description for the reference */
|
|
7
18
|
description?: string;
|
|
8
19
|
};
|
|
20
|
+
/**
|
|
21
|
+
* Valibot schema for validating schema reference data.
|
|
22
|
+
*/
|
|
9
23
|
export declare const oasSchemaRefData: v.GenericSchema<OasSchemaRefData>;
|
|
24
|
+
/**
|
|
25
|
+
* Data type for OpenAPI response reference objects.
|
|
26
|
+
*
|
|
27
|
+
* Represents $ref references to response objects in OpenAPI documents,
|
|
28
|
+
* enabling response definition reuse across multiple operations.
|
|
29
|
+
*/
|
|
10
30
|
export type OasResponseRefData = {
|
|
31
|
+
/** Type identifier for OAS reference objects */
|
|
11
32
|
oasType: 'ref';
|
|
33
|
+
/** The type of object being referenced */
|
|
12
34
|
refType: 'response';
|
|
35
|
+
/** The reference path (e.g., '#/components/responses/NotFound') */
|
|
13
36
|
$ref: string;
|
|
37
|
+
/** Optional summary for the reference */
|
|
14
38
|
summary?: string;
|
|
39
|
+
/** Optional description for the reference */
|
|
15
40
|
description?: string;
|
|
16
41
|
};
|
|
42
|
+
/**
|
|
43
|
+
* Valibot schema for validating response reference data.
|
|
44
|
+
*/
|
|
17
45
|
export declare const oasResponseRefData: v.GenericSchema<OasResponseRefData>;
|
|
46
|
+
/**
|
|
47
|
+
* Data type for OpenAPI parameter reference objects.
|
|
48
|
+
*
|
|
49
|
+
* Represents $ref references to parameter objects in OpenAPI documents,
|
|
50
|
+
* allowing parameter definitions to be reused across operations.
|
|
51
|
+
*/
|
|
18
52
|
export type OasParameterRefData = {
|
|
53
|
+
/** Type identifier for OAS reference objects */
|
|
19
54
|
oasType: 'ref';
|
|
55
|
+
/** The type of object being referenced */
|
|
20
56
|
refType: 'parameter';
|
|
57
|
+
/** The reference path (e.g., '#/components/parameters/PageSize') */
|
|
21
58
|
$ref: string;
|
|
59
|
+
/** Optional summary for the reference */
|
|
22
60
|
summary?: string;
|
|
61
|
+
/** Optional description for the reference */
|
|
23
62
|
description?: string;
|
|
24
63
|
};
|
|
64
|
+
/**
|
|
65
|
+
* Valibot schema for validating parameter reference data.
|
|
66
|
+
*/
|
|
25
67
|
export declare const oasParameterRefData: v.GenericSchema<OasParameterRefData>;
|
|
26
68
|
export type OasExampleRefData = {
|
|
27
69
|
oasType: 'ref';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ref-types.d.ts","sourceRoot":"","sources":["../../../src/oas/ref/ref-types.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,CAA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iBAAiB,CAM/D,CAAA;AAEF,MAAM,MAAM,qBAAqB,GAAG;IAClC,OAAO,EAAE,KAAK,CAAA;IACd,OAAO,EAAE,aAAa,CAAA;IACtB,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,WAAW,CAAC,EAAE,MAAM,CAAA;CACrB,CAAA;AAED,eAAO,MAAM,qBAAqB,EAAE,CAAC,CAAC,aAAa,CAAC,qBAAqB,CAMvE,CAAA;AACF,MAAM,MAAM,gBAAgB,GAAG;IAC7B,OAAO,EAAE,KAAK,CAAA;IACd,OAAO,EAAE,QAAQ,CAAA;IACjB,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,WAAW,CAAC,EAAE,MAAM,CAAA;CACrB,CAAA;AAED,eAAO,MAAM,gBAAgB,EAAE,CAAC,CAAC,aAAa,CAAC,gBAAgB,CAM7D,CAAA;AAEF,MAAM,MAAM,wBAAwB,GAAG;IACrC,OAAO,EAAE,KAAK,CAAA;IACd,OAAO,EAAE,gBAAgB,CAAA;IACzB,IAAI,EAAE,MAAM,CAAA;CACb,CAAA;AAED,eAAO,MAAM,wBAAwB,EAAE,CAAC,CAAC,aAAa,CAAC,wBAAwB,CAI7E,CAAA;AAUF,MAAM,MAAM,UAAU,GAClB,gBAAgB,GAChB,kBAAkB,GAClB,mBAAmB,GACnB,iBAAiB,GACjB,qBAAqB,GACrB,gBAAgB,GAChB,wBAAwB,CAAA;AAG5B,eAAO,MAAM,UAAU,EAAE,CAAC,CAAC,aAAa,CAAC,UAAU,CASjD,CAAA"}
|
|
@@ -36,6 +36,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
36
36
|
exports.oasRefData = exports.oasSecuritySchemeRefData = exports.oasHeaderRefData = exports.oasRequestBodyRefData = exports.oasExampleRefData = exports.oasParameterRefData = exports.oasResponseRefData = exports.oasSchemaRefData = void 0;
|
|
37
37
|
const markdown_types_js_1 = require("../markdown/markdown-types.js");
|
|
38
38
|
const v = __importStar(require("valibot"));
|
|
39
|
+
/**
|
|
40
|
+
* Valibot schema for validating schema reference data.
|
|
41
|
+
*/
|
|
39
42
|
exports.oasSchemaRefData = v.object({
|
|
40
43
|
oasType: v.literal('ref'),
|
|
41
44
|
refType: v.literal('schema'),
|
|
@@ -43,6 +46,9 @@ exports.oasSchemaRefData = v.object({
|
|
|
43
46
|
summary: v.optional(v.string()),
|
|
44
47
|
description: v.optional(markdown_types_js_1.markdown)
|
|
45
48
|
});
|
|
49
|
+
/**
|
|
50
|
+
* Valibot schema for validating response reference data.
|
|
51
|
+
*/
|
|
46
52
|
exports.oasResponseRefData = v.object({
|
|
47
53
|
oasType: v.literal('ref'),
|
|
48
54
|
refType: v.literal('response'),
|
|
@@ -50,6 +56,9 @@ exports.oasResponseRefData = v.object({
|
|
|
50
56
|
summary: v.optional(v.string()),
|
|
51
57
|
description: v.optional(markdown_types_js_1.markdown)
|
|
52
58
|
});
|
|
59
|
+
/**
|
|
60
|
+
* Valibot schema for validating parameter reference data.
|
|
61
|
+
*/
|
|
53
62
|
exports.oasParameterRefData = v.object({
|
|
54
63
|
oasType: v.literal('ref'),
|
|
55
64
|
refType: v.literal('parameter'),
|