@orval/core 7.11.2 → 7.12.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1,299 +1,286 @@
1
- import SwaggerParser from '@apidevtools/swagger-parser';
2
- import { allLocales } from '@faker-js/faker';
3
- import { OpenAPIObject, SchemaObject, ResponsesObject, ReferenceObject, RequestBodyObject, OperationObject, InfoObject, ParameterObject, ComponentsObject, SchemasObject, PathItemObject, ResponseObject, ExampleObject } from 'openapi3-ts/oas30';
4
- import swagger2openapi from 'swagger2openapi';
5
- import { TypeDocOptions } from 'typedoc';
6
- import { SchemaObject as SchemaObject$1 } from 'openapi3-ts/dist/model/openapi30';
7
- import { ValueIteratee } from 'lodash';
8
- import { ServerObject } from 'openapi3-ts/oas31';
9
- import { CompareOperator } from 'compare-versions';
10
- import debug from 'debug';
1
+ import SwaggerParser from "@apidevtools/swagger-parser";
2
+ import { allLocales } from "@faker-js/faker";
3
+ import { JSONSchema6, JSONSchema7 } from "json-schema";
4
+ import { ComponentsObject, ExampleObject, InfoObject, OpenAPIObject, OperationObject, ParameterObject, PathItemObject, ReferenceObject, RequestBodyObject, ResponseObject, ResponsesObject, SchemaObject, SchemasObject } from "openapi3-ts/oas30";
5
+ import { ConvertInputOptions } from "swagger2openapi";
6
+ import { TypeDocOptions } from "typedoc";
7
+ import { ValueIteratee } from "lodash";
8
+ import { ServerObject } from "openapi3-ts/oas31";
9
+ import { CompareOperator } from "compare-versions";
10
+ import debug from "debug";
11
11
 
12
+ //#region rolldown:runtime
13
+ //#endregion
14
+ //#region src/types.d.ts
12
15
  interface Options {
13
- output?: string | OutputOptions;
14
- input?: string | InputOptions;
15
- hooks?: Partial<HooksOptions>;
16
+ output?: string | OutputOptions;
17
+ input?: string | InputOptions;
18
+ hooks?: Partial<HooksOptions>;
16
19
  }
17
20
  type OptionsFn = () => Options | Promise<Options>;
18
21
  type OptionsExport = Options | Promise<Options> | OptionsFn;
19
- type Config = {
20
- [project: string]: OptionsExport;
21
- };
22
+ type Config = Record<string, OptionsExport>;
22
23
  type ConfigFn = () => Config | Promise<Config>;
23
24
  type ConfigExternal = Config | Promise<Config> | ConfigFn;
24
- type NormalizedConfig = {
25
- [project: string]: NormalizedOptions;
26
- };
25
+ type NormalizedConfig = Record<string, NormalizedOptions | undefined>;
27
26
  interface NormalizedOptions {
28
- output: NormalizedOutputOptions;
29
- input: NormalizedInputOptions;
30
- hooks: NormalizedHookOptions;
27
+ output: NormalizedOutputOptions;
28
+ input: NormalizedInputOptions;
29
+ hooks: NormalizedHookOptions;
31
30
  }
32
31
  type NormalizedOutputOptions = {
33
- workspace?: string;
34
- target?: string;
35
- schemas?: string;
36
- namingConvention: NamingConvention;
37
- fileExtension: string;
38
- mode: OutputMode;
39
- mock?: GlobalMockOptions | ClientMockBuilder;
40
- override: NormalizedOverrideOutput;
41
- client: OutputClient | OutputClientFunc;
42
- httpClient: OutputHttpClient;
43
- clean: boolean | string[];
44
- docs: boolean | OutputDocsOptions;
45
- prettier: boolean;
46
- tslint: boolean;
47
- biome: boolean;
48
- tsconfig?: Tsconfig;
49
- packageJson?: PackageJson;
50
- headers: boolean;
51
- indexFiles: boolean;
52
- baseUrl?: string | BaseUrlFromSpec | BaseUrlFromConstant;
53
- allParamsOptional: boolean;
54
- urlEncodeParameters: boolean;
55
- unionAddMissingProperties: boolean;
56
- optionsParamRequired: boolean;
57
- propertySortOrder: PropertySortOrder;
32
+ workspace?: string;
33
+ target?: string;
34
+ schemas?: string;
35
+ namingConvention: NamingConvention;
36
+ fileExtension: string;
37
+ mode: OutputMode;
38
+ mock?: GlobalMockOptions | ClientMockBuilder;
39
+ override: NormalizedOverrideOutput;
40
+ client: OutputClient | OutputClientFunc;
41
+ httpClient: OutputHttpClient;
42
+ clean: boolean | string[];
43
+ docs: boolean | OutputDocsOptions;
44
+ prettier: boolean;
45
+ biome: boolean;
46
+ tsconfig?: Tsconfig;
47
+ packageJson?: PackageJson;
48
+ headers: boolean;
49
+ indexFiles: boolean;
50
+ baseUrl?: string | BaseUrlFromSpec | BaseUrlFromConstant;
51
+ allParamsOptional: boolean;
52
+ urlEncodeParameters: boolean;
53
+ unionAddMissingProperties: boolean;
54
+ optionsParamRequired: boolean;
55
+ propertySortOrder: PropertySortOrder;
58
56
  };
59
57
  type NormalizedParamsSerializerOptions = {
60
- qs?: Record<string, any>;
58
+ qs?: Record<string, any>;
61
59
  };
62
60
  type NormalizedOverrideOutput = {
63
- title?: (title: string) => string;
64
- transformer?: OutputTransformer;
65
- mutator?: NormalizedMutator;
66
- operations: {
67
- [key: string]: NormalizedOperationOptions;
61
+ title?: (title: string) => string;
62
+ transformer?: OutputTransformer;
63
+ mutator?: NormalizedMutator;
64
+ operations: Record<string, NormalizedOperationOptions>;
65
+ tags: Record<string, NormalizedOperationOptions>;
66
+ mock?: OverrideMockOptions;
67
+ contentType?: OverrideOutputContentType;
68
+ header: false | ((info: InfoObject) => string[] | string);
69
+ formData: NormalizedFormDataType<NormalizedMutator>;
70
+ formUrlEncoded: boolean | NormalizedMutator;
71
+ paramsSerializer?: NormalizedMutator;
72
+ paramsSerializerOptions?: NormalizedParamsSerializerOptions;
73
+ namingConvention: {
74
+ enum?: NamingConvention;
75
+ };
76
+ components: {
77
+ schemas: {
78
+ suffix: string;
79
+ itemSuffix: string;
68
80
  };
69
- tags: {
70
- [key: string]: NormalizedOperationOptions;
81
+ responses: {
82
+ suffix: string;
71
83
  };
72
- mock?: OverrideMockOptions;
73
- contentType?: OverrideOutputContentType;
74
- header: false | ((info: InfoObject) => string[] | string);
75
- formData: NormalizedFormDataType<NormalizedMutator>;
76
- formUrlEncoded: boolean | NormalizedMutator;
77
- paramsSerializer?: NormalizedMutator;
78
- paramsSerializerOptions?: NormalizedParamsSerializerOptions;
79
- namingConvention: {
80
- enum?: NamingConvention;
84
+ parameters: {
85
+ suffix: string;
81
86
  };
82
- components: {
83
- schemas: {
84
- suffix: string;
85
- itemSuffix: string;
86
- };
87
- responses: {
88
- suffix: string;
89
- };
90
- parameters: {
91
- suffix: string;
92
- };
93
- requestBodies: {
94
- suffix: string;
95
- };
87
+ requestBodies: {
88
+ suffix: string;
96
89
  };
97
- hono: NormalizedHonoOptions;
98
- query: NormalizedQueryOptions;
99
- angular: Required<AngularOptions>;
100
- swr: SwrOptions;
101
- zod: NormalizedZodOptions;
102
- fetch: FetchOptions;
103
- operationName?: (operation: OperationObject, route: string, verb: Verbs) => string;
104
- requestOptions: Record<string, any> | boolean;
105
- useDates?: boolean;
106
- coerceTypes?: boolean;
107
- useTypeOverInterfaces?: boolean;
108
- useDeprecatedOperations?: boolean;
109
- useBigInt?: boolean;
110
- useNamedParameters?: boolean;
111
- enumGenerationType: EnumGeneration;
112
- suppressReadonlyModifier?: boolean;
113
- jsDoc: NormalizedJsDocOptions;
90
+ };
91
+ hono: NormalizedHonoOptions;
92
+ query: NormalizedQueryOptions;
93
+ angular: Required<AngularOptions>;
94
+ swr: SwrOptions;
95
+ zod: NormalizedZodOptions;
96
+ fetch: NormalizedFetchOptions;
97
+ operationName?: (operation: OperationObject, route: string, verb: Verbs) => string;
98
+ requestOptions: Record<string, any> | boolean;
99
+ useDates?: boolean;
100
+ coerceTypes?: boolean;
101
+ useTypeOverInterfaces?: boolean;
102
+ useDeprecatedOperations?: boolean;
103
+ useBigInt?: boolean;
104
+ useNamedParameters?: boolean;
105
+ enumGenerationType: EnumGeneration;
106
+ suppressReadonlyModifier?: boolean;
107
+ jsDoc: NormalizedJsDocOptions;
114
108
  };
115
109
  type NormalizedMutator = {
116
- path: string;
117
- name?: string;
118
- default: boolean;
119
- alias?: Record<string, string>;
120
- extension?: string;
110
+ path: string;
111
+ name?: string;
112
+ default: boolean;
113
+ alias?: Record<string, string>;
114
+ extension?: string;
121
115
  };
122
116
  type NormalizedOperationOptions = {
123
- transformer?: OutputTransformer;
124
- mutator?: NormalizedMutator;
125
- mock?: {
126
- data?: MockData;
127
- properties?: MockProperties;
128
- };
129
- contentType?: OverrideOutputContentType;
130
- query?: NormalizedQueryOptions;
131
- angular?: Required<AngularOptions>;
132
- swr?: SwrOptions;
133
- zod?: NormalizedZodOptions;
134
- operationName?: (operation: OperationObject, route: string, verb: Verbs) => string;
135
- fetch?: FetchOptions;
136
- formData?: NormalizedFormDataType<NormalizedMutator>;
137
- formUrlEncoded?: boolean | NormalizedMutator;
138
- paramsSerializer?: NormalizedMutator;
139
- requestOptions?: object | boolean;
117
+ transformer?: OutputTransformer;
118
+ mutator?: NormalizedMutator;
119
+ mock?: {
120
+ data?: MockData;
121
+ properties?: MockProperties;
122
+ };
123
+ contentType?: OverrideOutputContentType;
124
+ query?: NormalizedQueryOptions;
125
+ angular?: Required<AngularOptions>;
126
+ swr?: SwrOptions;
127
+ zod?: NormalizedZodOptions;
128
+ operationName?: (operation: OperationObject, route: string, verb: Verbs) => string;
129
+ fetch?: FetchOptions;
130
+ formData?: NormalizedFormDataType<NormalizedMutator>;
131
+ formUrlEncoded?: boolean | NormalizedMutator;
132
+ paramsSerializer?: NormalizedMutator;
133
+ requestOptions?: object | boolean;
140
134
  };
141
135
  type NormalizedInputOptions = {
142
- target: string | Record<string, unknown> | OpenAPIObject;
143
- validation: boolean | object;
144
- override: OverrideInput;
145
- converterOptions: swagger2openapi.Options;
146
- parserOptions: SwaggerParserOptions;
147
- filters?: InputFiltersOption;
136
+ target: string | Record<string, unknown> | OpenAPIObject;
137
+ validation: boolean | object;
138
+ override: OverrideInput;
139
+ converterOptions: Partial<ConvertInputOptions>;
140
+ parserOptions: SwaggerParserOptions;
141
+ filters?: InputFiltersOption;
148
142
  };
149
143
  type OutputClientFunc = (clients: GeneratorClients) => ClientGeneratorsBuilder;
150
144
  type BaseUrlFromSpec = {
151
- getBaseUrlFromSpecification: true;
152
- variables?: {
153
- [variable: string]: string;
154
- };
155
- index?: number;
156
- baseUrl?: never;
145
+ getBaseUrlFromSpecification: true;
146
+ variables?: Record<string, string>;
147
+ index?: number;
148
+ baseUrl?: never;
157
149
  };
158
150
  type BaseUrlFromConstant = {
159
- getBaseUrlFromSpecification: false;
160
- variables?: never;
161
- index?: never;
162
- baseUrl: string;
151
+ getBaseUrlFromSpecification: false;
152
+ variables?: never;
153
+ index?: never;
154
+ baseUrl: string;
163
155
  };
164
156
  declare const PropertySortOrder: {
165
- readonly ALPHABETICAL: "Alphabetical";
166
- readonly SPECIFICATION: "Specification";
157
+ readonly ALPHABETICAL: "Alphabetical";
158
+ readonly SPECIFICATION: "Specification";
167
159
  };
168
160
  type PropertySortOrder = (typeof PropertySortOrder)[keyof typeof PropertySortOrder];
169
161
  declare const NamingConvention: {
170
- readonly CAMEL_CASE: "camelCase";
171
- readonly PASCAL_CASE: "PascalCase";
172
- readonly SNAKE_CASE: "snake_case";
173
- readonly KEBAB_CASE: "kebab-case";
162
+ readonly CAMEL_CASE: "camelCase";
163
+ readonly PASCAL_CASE: "PascalCase";
164
+ readonly SNAKE_CASE: "snake_case";
165
+ readonly KEBAB_CASE: "kebab-case";
174
166
  };
175
167
  type NamingConvention = (typeof NamingConvention)[keyof typeof NamingConvention];
176
168
  declare const EnumGeneration: {
177
- readonly CONST: "const";
178
- readonly ENUM: "enum";
179
- readonly UNION: "union";
169
+ readonly CONST: "const";
170
+ readonly ENUM: "enum";
171
+ readonly UNION: "union";
180
172
  };
181
173
  type EnumGeneration = (typeof EnumGeneration)[keyof typeof EnumGeneration];
182
174
  type OutputOptions = {
183
- workspace?: string;
184
- target?: string;
185
- schemas?: string;
186
- namingConvention?: NamingConvention;
187
- fileExtension?: string;
188
- mode?: OutputMode;
189
- mock?: boolean | GlobalMockOptions | ClientMockBuilder;
190
- override?: OverrideOutput;
191
- client?: OutputClient | OutputClientFunc;
192
- httpClient?: OutputHttpClient;
193
- clean?: boolean | string[];
194
- docs?: boolean | OutputDocsOptions;
195
- prettier?: boolean;
196
- tslint?: boolean;
197
- biome?: boolean;
198
- tsconfig?: string | Tsconfig;
199
- packageJson?: string;
200
- headers?: boolean;
201
- indexFiles?: boolean;
202
- baseUrl?: string | BaseUrlFromSpec | BaseUrlFromConstant;
203
- allParamsOptional?: boolean;
204
- urlEncodeParameters?: boolean;
205
- unionAddMissingProperties?: boolean;
206
- optionsParamRequired?: boolean;
207
- propertySortOrder?: PropertySortOrder;
175
+ workspace?: string;
176
+ target?: string;
177
+ schemas?: string;
178
+ namingConvention?: NamingConvention;
179
+ fileExtension?: string;
180
+ mode?: OutputMode;
181
+ mock?: boolean | GlobalMockOptions | ClientMockBuilder;
182
+ override?: OverrideOutput;
183
+ client?: OutputClient | OutputClientFunc;
184
+ httpClient?: OutputHttpClient;
185
+ clean?: boolean | string[];
186
+ docs?: boolean | OutputDocsOptions;
187
+ prettier?: boolean;
188
+ biome?: boolean;
189
+ tsconfig?: string | Tsconfig;
190
+ packageJson?: string;
191
+ headers?: boolean;
192
+ indexFiles?: boolean;
193
+ baseUrl?: string | BaseUrlFromSpec | BaseUrlFromConstant;
194
+ allParamsOptional?: boolean;
195
+ urlEncodeParameters?: boolean;
196
+ unionAddMissingProperties?: boolean;
197
+ optionsParamRequired?: boolean;
198
+ propertySortOrder?: PropertySortOrder;
208
199
  };
209
200
  type SwaggerParserOptions = Omit<SwaggerParser.Options, 'validate'> & {
210
- validate?: boolean;
201
+ validate?: boolean;
211
202
  };
212
203
  type InputFiltersOption = {
213
- mode?: 'include' | 'exclude';
214
- tags?: (string | RegExp)[];
215
- schemas?: (string | RegExp)[];
204
+ mode?: 'include' | 'exclude';
205
+ tags?: (string | RegExp)[];
206
+ schemas?: (string | RegExp)[];
216
207
  };
217
208
  type InputOptions = {
218
- target: string | Record<string, unknown> | OpenAPIObject;
219
- validation?: boolean | object;
220
- override?: OverrideInput;
221
- converterOptions?: swagger2openapi.Options;
222
- parserOptions?: SwaggerParserOptions;
223
- filters?: InputFiltersOption;
209
+ target: string | Record<string, unknown> | OpenAPIObject;
210
+ validation?: boolean | object;
211
+ override?: OverrideInput;
212
+ converterOptions?: Partial<ConvertInputOptions>;
213
+ parserOptions?: SwaggerParserOptions;
214
+ filters?: InputFiltersOption;
224
215
  };
225
216
  declare const OutputClient: {
226
- readonly ANGULAR: "angular";
227
- readonly AXIOS: "axios";
228
- readonly AXIOS_FUNCTIONS: "axios-functions";
229
- readonly REACT_QUERY: "react-query";
230
- readonly SVELTE_QUERY: "svelte-query";
231
- readonly VUE_QUERY: "vue-query";
232
- readonly SWR: "swr";
233
- readonly ZOD: "zod";
234
- readonly HONO: "hono";
235
- readonly FETCH: "fetch";
236
- readonly MCP: "mcp";
217
+ readonly ANGULAR: "angular";
218
+ readonly AXIOS: "axios";
219
+ readonly AXIOS_FUNCTIONS: "axios-functions";
220
+ readonly REACT_QUERY: "react-query";
221
+ readonly SVELTE_QUERY: "svelte-query";
222
+ readonly VUE_QUERY: "vue-query";
223
+ readonly SWR: "swr";
224
+ readonly ZOD: "zod";
225
+ readonly HONO: "hono";
226
+ readonly FETCH: "fetch";
227
+ readonly MCP: "mcp";
237
228
  };
238
229
  type OutputClient = (typeof OutputClient)[keyof typeof OutputClient];
239
230
  declare const OutputHttpClient: {
240
- readonly AXIOS: "axios";
241
- readonly FETCH: "fetch";
231
+ readonly AXIOS: "axios";
232
+ readonly FETCH: "fetch";
242
233
  };
243
234
  type OutputHttpClient = (typeof OutputHttpClient)[keyof typeof OutputHttpClient];
244
235
  declare const OutputMode: {
245
- readonly SINGLE: "single";
246
- readonly SPLIT: "split";
247
- readonly TAGS: "tags";
248
- readonly TAGS_SPLIT: "tags-split";
236
+ readonly SINGLE: "single";
237
+ readonly SPLIT: "split";
238
+ readonly TAGS: "tags";
239
+ readonly TAGS_SPLIT: "tags-split";
249
240
  };
250
241
  type OutputMode = (typeof OutputMode)[keyof typeof OutputMode];
251
242
  type OutputDocsOptions = {
252
- configPath?: string;
243
+ configPath?: string;
253
244
  } & Partial<TypeDocOptions>;
254
245
  declare const OutputMockType: {
255
- readonly MSW: "msw";
246
+ readonly MSW: "msw";
256
247
  };
257
248
  type OutputMockType = (typeof OutputMockType)[keyof typeof OutputMockType];
258
249
  type GlobalMockOptions = {
259
- type: OutputMockType;
260
- useExamples?: boolean;
261
- generateEachHttpStatus?: boolean;
262
- delay?: false | number | (() => number);
263
- delayFunctionLazyExecute?: boolean;
264
- baseUrl?: string;
265
- locale?: keyof typeof allLocales;
266
- indexMockFiles?: boolean;
250
+ type: OutputMockType;
251
+ useExamples?: boolean;
252
+ generateEachHttpStatus?: boolean;
253
+ delay?: false | number | (() => number);
254
+ delayFunctionLazyExecute?: boolean;
255
+ baseUrl?: string;
256
+ locale?: keyof typeof allLocales;
257
+ indexMockFiles?: boolean;
267
258
  };
268
259
  type OverrideMockOptions = Partial<GlobalMockOptions> & {
269
- arrayMin?: number;
270
- arrayMax?: number;
271
- stringMin?: number;
272
- stringMax?: number;
273
- numberMin?: number;
274
- numberMax?: number;
275
- required?: boolean;
276
- properties?: MockProperties;
277
- format?: Record<string, unknown>;
278
- fractionDigits?: number;
260
+ arrayMin?: number;
261
+ arrayMax?: number;
262
+ stringMin?: number;
263
+ stringMax?: number;
264
+ numberMin?: number;
265
+ numberMax?: number;
266
+ required?: boolean;
267
+ properties?: MockProperties;
268
+ format?: Record<string, unknown>;
269
+ fractionDigits?: number;
279
270
  };
280
271
  type MockOptions = Omit<OverrideMockOptions, 'properties'> & {
281
- properties?: Record<string, unknown>;
282
- operations?: Record<string, {
283
- properties: Record<string, unknown>;
284
- }>;
285
- tags?: Record<string, {
286
- properties: Record<string, unknown>;
287
- }>;
288
- };
289
- type MockPropertiesObject = {
290
- [key: string]: unknown;
291
- };
272
+ properties?: Record<string, unknown>;
273
+ operations?: Record<string, {
274
+ properties: Record<string, unknown>;
275
+ }>;
276
+ tags?: Record<string, {
277
+ properties: Record<string, unknown>;
278
+ }>;
279
+ };
280
+ type MockPropertiesObject = Record<string, unknown>;
292
281
  type MockPropertiesObjectFn = (specs: OpenAPIObject) => MockPropertiesObject;
293
282
  type MockProperties = MockPropertiesObject | MockPropertiesObjectFn;
294
- type MockDataObject = {
295
- [key: string]: unknown;
296
- };
283
+ type MockDataObject = Record<string, unknown>;
297
284
  type MockDataObjectFn = (specs: OpenAPIObject) => MockDataObject;
298
285
  type MockDataArray = unknown[];
299
286
  type MockDataArrayFn = (specs: OpenAPIObject) => MockDataArray;
@@ -301,278 +288,283 @@ type MockData = MockDataObject | MockDataObjectFn | MockDataArray | MockDataArra
301
288
  type OutputTransformerFn = (verb: GeneratorVerbOptions) => GeneratorVerbOptions;
302
289
  type OutputTransformer = string | OutputTransformerFn;
303
290
  type MutatorObject = {
304
- path: string;
305
- name?: string;
306
- default?: boolean;
307
- alias?: Record<string, string>;
308
- extension?: string;
291
+ path: string;
292
+ name?: string;
293
+ default?: boolean;
294
+ alias?: Record<string, string>;
295
+ extension?: string;
309
296
  };
310
297
  type Mutator = string | MutatorObject;
311
298
  type ParamsSerializerOptions = {
312
- qs?: Record<string, any>;
299
+ qs?: Record<string, any>;
313
300
  };
314
301
  declare const FormDataArrayHandling: {
315
- readonly SERIALIZE: "serialize";
316
- readonly EXPLODE: "explode";
317
- readonly SERIALIZE_WITH_BRACKETS: "serialize-with-brackets";
302
+ readonly SERIALIZE: "serialize";
303
+ readonly EXPLODE: "explode";
304
+ readonly SERIALIZE_WITH_BRACKETS: "serialize-with-brackets";
318
305
  };
319
306
  type FormDataArrayHandling = (typeof FormDataArrayHandling)[keyof typeof FormDataArrayHandling];
320
307
  type NormalizedFormDataType<TMutator> = {
321
- disabled: true;
322
- mutator?: never;
323
- arrayHandling: FormDataArrayHandling;
308
+ disabled: true;
309
+ mutator?: never;
310
+ arrayHandling: FormDataArrayHandling;
324
311
  } | {
325
- disabled: false;
326
- mutator?: TMutator;
327
- arrayHandling: FormDataArrayHandling;
312
+ disabled: false;
313
+ mutator?: TMutator;
314
+ arrayHandling: FormDataArrayHandling;
328
315
  };
329
316
  type FormDataType<TMutator> = {
330
- mutator: TMutator;
331
- arrayHandling?: FormDataArrayHandling;
317
+ mutator: TMutator;
318
+ arrayHandling?: FormDataArrayHandling;
332
319
  } | {
333
- mutator?: TMutator;
334
- arrayHandling: FormDataArrayHandling;
320
+ mutator?: TMutator;
321
+ arrayHandling: FormDataArrayHandling;
335
322
  };
336
323
  type OverrideOutput = {
337
- title?: (title: string) => string;
338
- transformer?: OutputTransformer;
339
- mutator?: Mutator;
340
- operations?: {
341
- [key: string]: OperationOptions;
324
+ title?: (title: string) => string;
325
+ transformer?: OutputTransformer;
326
+ mutator?: Mutator;
327
+ operations?: Record<string, OperationOptions>;
328
+ tags?: Record<string, OperationOptions>;
329
+ mock?: OverrideMockOptions;
330
+ contentType?: OverrideOutputContentType;
331
+ header?: boolean | ((info: InfoObject) => string[] | string);
332
+ formData?: boolean | Mutator | FormDataType<Mutator>;
333
+ formUrlEncoded?: boolean | Mutator;
334
+ paramsSerializer?: Mutator;
335
+ paramsSerializerOptions?: ParamsSerializerOptions;
336
+ namingConvention?: {
337
+ enum?: NamingConvention;
338
+ };
339
+ components?: {
340
+ schemas?: {
341
+ suffix?: string;
342
+ itemSuffix?: string;
342
343
  };
343
- tags?: {
344
- [key: string]: OperationOptions;
344
+ responses?: {
345
+ suffix?: string;
345
346
  };
346
- mock?: OverrideMockOptions;
347
- contentType?: OverrideOutputContentType;
348
- header?: boolean | ((info: InfoObject) => string[] | string);
349
- formData?: boolean | Mutator | FormDataType<Mutator>;
350
- formUrlEncoded?: boolean | Mutator;
351
- paramsSerializer?: Mutator;
352
- paramsSerializerOptions?: ParamsSerializerOptions;
353
- namingConvention?: {
354
- enum?: NamingConvention;
347
+ parameters?: {
348
+ suffix?: string;
355
349
  };
356
- components?: {
357
- schemas?: {
358
- suffix?: string;
359
- itemSuffix?: string;
360
- };
361
- responses?: {
362
- suffix?: string;
363
- };
364
- parameters?: {
365
- suffix?: string;
366
- };
367
- requestBodies?: {
368
- suffix?: string;
369
- };
350
+ requestBodies?: {
351
+ suffix?: string;
370
352
  };
371
- hono?: HonoOptions;
372
- query?: QueryOptions;
373
- swr?: SwrOptions;
374
- angular?: AngularOptions;
375
- zod?: ZodOptions;
376
- operationName?: (operation: OperationObject, route: string, verb: Verbs) => string;
377
- fetch?: FetchOptions;
378
- requestOptions?: Record<string, any> | boolean;
379
- useDates?: boolean;
380
- useTypeOverInterfaces?: boolean;
381
- useDeprecatedOperations?: boolean;
382
- useBigInt?: boolean;
383
- useNamedParameters?: boolean;
384
- /**
385
- * @deprecated use 'enumGenerationType="enum"' instead
386
- */
387
- useNativeEnums?: boolean;
388
- enumGenerationType?: EnumGeneration;
389
- suppressReadonlyModifier?: boolean;
390
- jsDoc?: JsDocOptions;
353
+ };
354
+ hono?: HonoOptions;
355
+ query?: QueryOptions;
356
+ swr?: SwrOptions;
357
+ angular?: AngularOptions;
358
+ zod?: ZodOptions;
359
+ operationName?: (operation: OperationObject, route: string, verb: Verbs) => string;
360
+ fetch?: FetchOptions;
361
+ requestOptions?: Record<string, any> | boolean;
362
+ useDates?: boolean;
363
+ useTypeOverInterfaces?: boolean;
364
+ useDeprecatedOperations?: boolean;
365
+ useBigInt?: boolean;
366
+ useNamedParameters?: boolean;
367
+ /**
368
+ * @deprecated use 'enumGenerationType="enum"' instead
369
+ */
370
+ useNativeEnums?: boolean;
371
+ enumGenerationType?: EnumGeneration;
372
+ suppressReadonlyModifier?: boolean;
373
+ jsDoc?: JsDocOptions;
391
374
  };
392
375
  type JsDocOptions = {
393
- filter?: (schema: Record<string, any>) => {
394
- key: string;
395
- value: string;
396
- }[];
376
+ filter?: (schema: Record<string, any>) => {
377
+ key: string;
378
+ value: string;
379
+ }[];
397
380
  };
398
381
  type NormalizedJsDocOptions = {
399
- filter?: (schema: Record<string, any>) => {
400
- key: string;
401
- value: string;
402
- }[];
382
+ filter?: (schema: Record<string, any>) => {
383
+ key: string;
384
+ value: string;
385
+ }[];
403
386
  };
404
387
  type OverrideOutputContentType = {
405
- include?: string[];
406
- exclude?: string[];
388
+ include?: string[];
389
+ exclude?: string[];
407
390
  };
408
391
  type NormalizedHonoOptions = {
409
- handlers?: string;
410
- compositeRoute: string;
411
- validator: boolean | 'hono';
412
- validatorOutputPath: string;
392
+ handlers?: string;
393
+ compositeRoute: string;
394
+ validator: boolean | 'hono';
395
+ validatorOutputPath: string;
413
396
  };
414
397
  type ZodDateTimeOptions = {
415
- offset?: boolean;
416
- local?: boolean;
417
- precision?: number;
398
+ offset?: boolean;
399
+ local?: boolean;
400
+ precision?: number;
418
401
  };
419
402
  type ZodTimeOptions = {
420
- precision?: -1 | 0 | 1 | 2 | 3;
403
+ precision?: -1 | 0 | 1 | 2 | 3;
421
404
  };
422
405
  type ZodOptions = {
423
- strict?: {
424
- param?: boolean;
425
- query?: boolean;
426
- header?: boolean;
427
- body?: boolean;
428
- response?: boolean;
429
- };
430
- generate: {
431
- param: boolean;
432
- query: boolean;
433
- header: boolean;
434
- body: boolean;
435
- response: boolean;
436
- };
437
- coerce?: {
438
- param?: boolean | ZodCoerceType[];
439
- query?: boolean | ZodCoerceType[];
440
- header?: boolean | ZodCoerceType[];
441
- body?: boolean | ZodCoerceType[];
442
- response?: boolean | ZodCoerceType[];
443
- };
444
- preprocess?: {
445
- param?: Mutator;
446
- query?: Mutator;
447
- header?: Mutator;
448
- body?: Mutator;
449
- response?: Mutator;
450
- };
451
- dateTimeOptions?: ZodDateTimeOptions;
452
- timeOptions?: ZodTimeOptions;
453
- generateEachHttpStatus?: boolean;
406
+ strict?: {
407
+ param?: boolean;
408
+ query?: boolean;
409
+ header?: boolean;
410
+ body?: boolean;
411
+ response?: boolean;
412
+ };
413
+ generate?: {
414
+ param?: boolean;
415
+ query?: boolean;
416
+ header?: boolean;
417
+ body?: boolean;
418
+ response?: boolean;
419
+ };
420
+ coerce?: {
421
+ param?: boolean | ZodCoerceType[];
422
+ query?: boolean | ZodCoerceType[];
423
+ header?: boolean | ZodCoerceType[];
424
+ body?: boolean | ZodCoerceType[];
425
+ response?: boolean | ZodCoerceType[];
426
+ };
427
+ preprocess?: {
428
+ param?: Mutator;
429
+ query?: Mutator;
430
+ header?: Mutator;
431
+ body?: Mutator;
432
+ response?: Mutator;
433
+ };
434
+ dateTimeOptions?: ZodDateTimeOptions;
435
+ timeOptions?: ZodTimeOptions;
436
+ generateEachHttpStatus?: boolean;
454
437
  };
455
438
  type ZodCoerceType = 'string' | 'number' | 'boolean' | 'bigint' | 'date';
456
439
  type NormalizedZodOptions = {
457
- strict: {
458
- param: boolean;
459
- query: boolean;
460
- header: boolean;
461
- body: boolean;
462
- response: boolean;
463
- };
464
- generate: {
465
- param: boolean;
466
- query: boolean;
467
- header: boolean;
468
- body: boolean;
469
- response: boolean;
470
- };
471
- coerce: {
472
- param: boolean | ZodCoerceType[];
473
- query: boolean | ZodCoerceType[];
474
- header: boolean | ZodCoerceType[];
475
- body: boolean | ZodCoerceType[];
476
- response: boolean | ZodCoerceType[];
477
- };
478
- preprocess: {
479
- param?: NormalizedMutator;
480
- query?: NormalizedMutator;
481
- header?: NormalizedMutator;
482
- body?: NormalizedMutator;
483
- response?: NormalizedMutator;
484
- };
485
- generateEachHttpStatus: boolean;
486
- dateTimeOptions: ZodDateTimeOptions;
487
- timeOptions: ZodTimeOptions;
440
+ strict: {
441
+ param: boolean;
442
+ query: boolean;
443
+ header: boolean;
444
+ body: boolean;
445
+ response: boolean;
446
+ };
447
+ generate: {
448
+ param: boolean;
449
+ query: boolean;
450
+ header: boolean;
451
+ body: boolean;
452
+ response: boolean;
453
+ };
454
+ coerce: {
455
+ param: boolean | ZodCoerceType[];
456
+ query: boolean | ZodCoerceType[];
457
+ header: boolean | ZodCoerceType[];
458
+ body: boolean | ZodCoerceType[];
459
+ response: boolean | ZodCoerceType[];
460
+ };
461
+ preprocess: {
462
+ param?: NormalizedMutator;
463
+ query?: NormalizedMutator;
464
+ header?: NormalizedMutator;
465
+ body?: NormalizedMutator;
466
+ response?: NormalizedMutator;
467
+ };
468
+ generateEachHttpStatus: boolean;
469
+ dateTimeOptions: ZodDateTimeOptions;
470
+ timeOptions: ZodTimeOptions;
488
471
  };
489
472
  type HonoOptions = {
490
- handlers?: string;
491
- compositeRoute?: string;
492
- validator?: boolean | 'hono';
493
- validatorOutputPath?: string;
473
+ handlers?: string;
474
+ compositeRoute?: string;
475
+ validator?: boolean | 'hono';
476
+ validatorOutputPath?: string;
494
477
  };
495
478
  type NormalizedQueryOptions = {
496
- useQuery?: boolean;
497
- useSuspenseQuery?: boolean;
498
- useMutation?: boolean;
499
- useInfinite?: boolean;
500
- useSuspenseInfiniteQuery?: boolean;
501
- useInfiniteQueryParam?: string;
502
- usePrefetch?: boolean;
503
- options?: any;
504
- queryKey?: NormalizedMutator;
505
- queryOptions?: NormalizedMutator;
506
- mutationOptions?: NormalizedMutator;
507
- shouldExportMutatorHooks?: boolean;
508
- shouldExportHttpClient?: boolean;
509
- shouldExportQueryKey?: boolean;
510
- shouldSplitQueryKey?: boolean;
511
- signal?: boolean;
512
- version?: 3 | 4 | 5;
479
+ useQuery?: boolean;
480
+ useSuspenseQuery?: boolean;
481
+ useMutation?: boolean;
482
+ useInfinite?: boolean;
483
+ useSuspenseInfiniteQuery?: boolean;
484
+ useInfiniteQueryParam?: string;
485
+ usePrefetch?: boolean;
486
+ options?: any;
487
+ queryKey?: NormalizedMutator;
488
+ queryOptions?: NormalizedMutator;
489
+ mutationOptions?: NormalizedMutator;
490
+ shouldExportMutatorHooks?: boolean;
491
+ shouldExportHttpClient?: boolean;
492
+ shouldExportQueryKey?: boolean;
493
+ shouldSplitQueryKey?: boolean;
494
+ useOperationIdAsQueryKey?: boolean;
495
+ signal?: boolean;
496
+ version?: 3 | 4 | 5;
513
497
  };
514
498
  type QueryOptions = {
515
- useQuery?: boolean;
516
- useSuspenseQuery?: boolean;
517
- useMutation?: boolean;
518
- useInfinite?: boolean;
519
- useSuspenseInfiniteQuery?: boolean;
520
- useInfiniteQueryParam?: string;
521
- usePrefetch?: boolean;
522
- options?: any;
523
- queryKey?: Mutator;
524
- queryOptions?: Mutator;
525
- mutationOptions?: Mutator;
526
- shouldExportMutatorHooks?: boolean;
527
- shouldExportHttpClient?: boolean;
528
- shouldExportQueryKey?: boolean;
529
- shouldSplitQueryKey?: boolean;
530
- signal?: boolean;
531
- version?: 3 | 4 | 5;
499
+ useQuery?: boolean;
500
+ useSuspenseQuery?: boolean;
501
+ useMutation?: boolean;
502
+ useInfinite?: boolean;
503
+ useSuspenseInfiniteQuery?: boolean;
504
+ useInfiniteQueryParam?: string;
505
+ usePrefetch?: boolean;
506
+ options?: any;
507
+ queryKey?: Mutator;
508
+ queryOptions?: Mutator;
509
+ mutationOptions?: Mutator;
510
+ shouldExportMutatorHooks?: boolean;
511
+ shouldExportHttpClient?: boolean;
512
+ shouldExportQueryKey?: boolean;
513
+ shouldSplitQueryKey?: boolean;
514
+ useOperationIdAsQueryKey?: boolean;
515
+ signal?: boolean;
516
+ version?: 3 | 4 | 5;
532
517
  };
533
518
  type AngularOptions = {
534
- provideIn?: 'root' | 'any' | boolean;
519
+ provideIn?: 'root' | 'any' | boolean;
535
520
  };
536
521
  type SwrOptions = {
537
- useInfinite?: boolean;
538
- useSWRMutationForGet?: boolean;
539
- swrOptions?: any;
540
- swrMutationOptions?: any;
541
- swrInfiniteOptions?: any;
522
+ useInfinite?: boolean;
523
+ useSWRMutationForGet?: boolean;
524
+ swrOptions?: any;
525
+ swrMutationOptions?: any;
526
+ swrInfiniteOptions?: any;
527
+ };
528
+ type NormalizedFetchOptions = {
529
+ includeHttpResponseReturnType: boolean;
530
+ forceSuccessResponse: boolean;
531
+ explode: boolean;
532
+ jsonReviver?: Mutator;
542
533
  };
543
534
  type FetchOptions = {
544
- includeHttpResponseReturnType?: boolean;
545
- explode?: boolean;
546
- jsonReviver?: Mutator;
535
+ includeHttpResponseReturnType?: boolean;
536
+ forceSuccessResponse?: boolean;
537
+ explode?: boolean;
538
+ jsonReviver?: Mutator;
547
539
  };
548
540
  type InputTransformerFn = (spec: OpenAPIObject) => OpenAPIObject;
549
541
  type InputTransformer = string | InputTransformerFn;
550
542
  type OverrideInput = {
551
- transformer?: InputTransformer;
543
+ transformer?: InputTransformer;
552
544
  };
553
545
  type OperationOptions = {
554
- transformer?: OutputTransformer;
555
- mutator?: Mutator;
556
- mock?: {
557
- data?: MockData;
558
- properties?: MockProperties;
559
- };
560
- query?: QueryOptions;
561
- angular?: Required<AngularOptions>;
562
- swr?: SwrOptions;
563
- zod?: ZodOptions;
564
- operationName?: (operation: OperationObject, route: string, verb: Verbs) => string;
565
- fetch?: FetchOptions;
566
- formData?: boolean | Mutator | FormDataType<Mutator>;
567
- formUrlEncoded?: boolean | Mutator;
568
- paramsSerializer?: Mutator;
569
- requestOptions?: object | boolean;
546
+ transformer?: OutputTransformer;
547
+ mutator?: Mutator;
548
+ mock?: {
549
+ data?: MockData;
550
+ properties?: MockProperties;
551
+ };
552
+ query?: QueryOptions;
553
+ angular?: Required<AngularOptions>;
554
+ swr?: SwrOptions;
555
+ zod?: ZodOptions;
556
+ operationName?: (operation: OperationObject, route: string, verb: Verbs) => string;
557
+ fetch?: FetchOptions;
558
+ formData?: boolean | Mutator | FormDataType<Mutator>;
559
+ formUrlEncoded?: boolean | Mutator;
560
+ paramsSerializer?: Mutator;
561
+ requestOptions?: object | boolean;
570
562
  };
571
563
  type Hook = 'afterAllFilesWrite';
572
564
  type HookFunction = (...args: any[]) => void | Promise<void>;
573
565
  interface HookOption {
574
- command: string | HookFunction;
575
- injectGeneratedDirsAndFiles?: boolean;
566
+ command: string | HookFunction;
567
+ injectGeneratedDirsAndFiles?: boolean;
576
568
  }
577
569
  type HookCommand = string | HookFunction | HookOption | (string | HookFunction | HookOption)[];
578
570
  type NormalizedHookCommand = HookCommand[];
@@ -580,618 +572,745 @@ type HooksOptions<T = HookCommand | NormalizedHookCommand> = Partial<Record<Hook
580
572
  type NormalizedHookOptions = HooksOptions<NormalizedHookCommand>;
581
573
  type Verbs = 'post' | 'put' | 'get' | 'patch' | 'delete' | 'head';
582
574
  declare const Verbs: {
583
- POST: Verbs;
584
- PUT: Verbs;
585
- GET: Verbs;
586
- PATCH: Verbs;
587
- DELETE: Verbs;
588
- HEAD: Verbs;
575
+ POST: Verbs;
576
+ PUT: Verbs;
577
+ GET: Verbs;
578
+ PATCH: Verbs;
579
+ DELETE: Verbs;
580
+ HEAD: Verbs;
589
581
  };
590
582
  type ImportOpenApi = {
591
- data: Record<string, unknown | OpenAPIObject>;
592
- input: NormalizedInputOptions;
593
- output: NormalizedOutputOptions;
594
- target: string;
595
- workspace: string;
583
+ data: JSONSchema6 | JSONSchema7 | Record<string, unknown | OpenAPIObject>;
584
+ input: NormalizedInputOptions;
585
+ output: NormalizedOutputOptions;
586
+ target: string;
587
+ workspace: string;
596
588
  };
597
589
  interface ContextSpecs {
598
- specKey: string;
599
- target: string;
600
- workspace: string;
601
- specs: Record<string, OpenAPIObject>;
602
- parents?: string[];
603
- output: NormalizedOutputOptions;
590
+ specKey: string;
591
+ target: string;
592
+ workspace: string;
593
+ specs: Record<string, OpenAPIObject>;
594
+ parents?: string[];
595
+ output: NormalizedOutputOptions;
604
596
  }
605
597
  interface GlobalOptions {
606
- projectName?: string;
607
- watch?: boolean | string | (string | boolean)[];
608
- clean?: boolean | string[];
609
- prettier?: boolean;
610
- tslint?: boolean;
611
- biome?: boolean;
612
- mock?: boolean | GlobalMockOptions;
613
- client?: OutputClient;
614
- httpClient?: OutputHttpClient;
615
- mode?: OutputMode;
616
- tsconfig?: string | Tsconfig;
617
- packageJson?: string;
618
- input?: string;
619
- output?: string;
598
+ projectName?: string;
599
+ watch?: boolean | string | (string | boolean)[];
600
+ clean?: boolean | string[];
601
+ prettier?: boolean;
602
+ biome?: boolean;
603
+ mock?: boolean | GlobalMockOptions;
604
+ client?: OutputClient;
605
+ httpClient?: OutputHttpClient;
606
+ mode?: OutputMode;
607
+ tsconfig?: string | Tsconfig;
608
+ packageJson?: string;
609
+ input?: string;
610
+ output?: string;
620
611
  }
621
612
  interface Tsconfig {
622
- baseUrl?: string;
623
- compilerOptions?: {
624
- esModuleInterop?: boolean;
625
- allowSyntheticDefaultImports?: boolean;
626
- exactOptionalPropertyTypes?: boolean;
627
- paths?: Record<string, string[]>;
628
- target?: TsConfigTarget;
629
- };
613
+ baseUrl?: string;
614
+ compilerOptions?: {
615
+ esModuleInterop?: boolean;
616
+ allowSyntheticDefaultImports?: boolean;
617
+ exactOptionalPropertyTypes?: boolean;
618
+ paths?: Record<string, string[]>;
619
+ target?: TsConfigTarget;
620
+ };
630
621
  }
631
622
  type TsConfigTarget = 'es3' | 'es5' | 'es6' | 'es2015' | 'es2016' | 'es2017' | 'es2018' | 'es2019' | 'es2020' | 'es2021' | 'es2022' | 'esnext';
632
623
  interface PackageJson {
633
- dependencies?: Record<string, string>;
634
- devDependencies?: Record<string, string>;
635
- peerDependencies?: Record<string, string>;
624
+ dependencies?: Record<string, string>;
625
+ devDependencies?: Record<string, string>;
626
+ peerDependencies?: Record<string, string>;
636
627
  }
637
628
  type GeneratorSchema = {
638
- name: string;
639
- model: string;
640
- imports: GeneratorImport[];
629
+ name: string;
630
+ model: string;
631
+ imports: GeneratorImport[];
641
632
  };
642
633
  type GeneratorImport = {
643
- name: string;
644
- schemaName?: string;
645
- isConstant?: boolean;
646
- alias?: string;
647
- specKey?: string;
648
- default?: boolean;
649
- values?: boolean;
650
- syntheticDefaultImport?: boolean;
634
+ name: string;
635
+ schemaName?: string;
636
+ isConstant?: boolean;
637
+ alias?: string;
638
+ specKey?: string;
639
+ default?: boolean;
640
+ values?: boolean;
641
+ syntheticDefaultImport?: boolean;
651
642
  };
652
643
  type GeneratorDependency = {
653
- exports: GeneratorImport[];
654
- dependency: string;
644
+ exports: GeneratorImport[];
645
+ dependency: string;
655
646
  };
656
647
  type GeneratorApiResponse = {
657
- operations: GeneratorOperations;
658
- schemas: GeneratorSchema[];
659
- };
660
- type GeneratorOperations = {
661
- [operationId: string]: GeneratorOperation;
648
+ operations: GeneratorOperations;
649
+ schemas: GeneratorSchema[];
662
650
  };
651
+ type GeneratorOperations = Record<string, GeneratorOperation>;
663
652
  type GeneratorTarget = {
664
- imports: GeneratorImport[];
665
- implementation: string;
666
- implementationMock: string;
667
- importsMock: GeneratorImport[];
668
- mutators?: GeneratorMutator[];
669
- clientMutators?: GeneratorMutator[];
670
- formData?: GeneratorMutator[];
671
- formUrlEncoded?: GeneratorMutator[];
672
- paramsSerializer?: GeneratorMutator[];
673
- fetchReviver?: GeneratorMutator[];
653
+ imports: GeneratorImport[];
654
+ implementation: string;
655
+ implementationMock: string;
656
+ importsMock: GeneratorImport[];
657
+ mutators?: GeneratorMutator[];
658
+ clientMutators?: GeneratorMutator[];
659
+ formData?: GeneratorMutator[];
660
+ formUrlEncoded?: GeneratorMutator[];
661
+ paramsSerializer?: GeneratorMutator[];
662
+ fetchReviver?: GeneratorMutator[];
674
663
  };
675
664
  type GeneratorTargetFull = {
676
- imports: GeneratorImport[];
677
- implementation: string;
678
- implementationMock: {
679
- function: string;
680
- handler: string;
681
- handlerName: string;
682
- };
683
- importsMock: GeneratorImport[];
684
- mutators?: GeneratorMutator[];
685
- clientMutators?: GeneratorMutator[];
686
- formData?: GeneratorMutator[];
687
- formUrlEncoded?: GeneratorMutator[];
688
- paramsSerializer?: GeneratorMutator[];
689
- fetchReviver?: GeneratorMutator[];
665
+ imports: GeneratorImport[];
666
+ implementation: string;
667
+ implementationMock: {
668
+ function: string;
669
+ handler: string;
670
+ handlerName: string;
671
+ };
672
+ importsMock: GeneratorImport[];
673
+ mutators?: GeneratorMutator[];
674
+ clientMutators?: GeneratorMutator[];
675
+ formData?: GeneratorMutator[];
676
+ formUrlEncoded?: GeneratorMutator[];
677
+ paramsSerializer?: GeneratorMutator[];
678
+ fetchReviver?: GeneratorMutator[];
690
679
  };
691
680
  type GeneratorOperation = {
692
- imports: GeneratorImport[];
693
- implementation: string;
694
- implementationMock: {
695
- function: string;
696
- handler: string;
697
- handlerName: string;
698
- };
699
- importsMock: GeneratorImport[];
700
- tags: string[];
701
- mutator?: GeneratorMutator;
702
- clientMutators?: GeneratorMutator[];
703
- formData?: GeneratorMutator;
704
- formUrlEncoded?: GeneratorMutator;
705
- paramsSerializer?: GeneratorMutator;
706
- fetchReviver?: GeneratorMutator;
707
- operationName: string;
708
- types?: {
709
- result: (title?: string) => string;
710
- };
681
+ imports: GeneratorImport[];
682
+ implementation: string;
683
+ implementationMock: {
684
+ function: string;
685
+ handler: string;
686
+ handlerName: string;
687
+ };
688
+ importsMock: GeneratorImport[];
689
+ tags: string[];
690
+ mutator?: GeneratorMutator;
691
+ clientMutators?: GeneratorMutator[];
692
+ formData?: GeneratorMutator;
693
+ formUrlEncoded?: GeneratorMutator;
694
+ paramsSerializer?: GeneratorMutator;
695
+ fetchReviver?: GeneratorMutator;
696
+ operationName: string;
697
+ types?: {
698
+ result: (title?: string) => string;
699
+ };
711
700
  };
712
701
  type GeneratorVerbOptions = {
713
- verb: Verbs;
714
- route: string;
715
- pathRoute: string;
716
- summary?: string;
717
- doc: string;
718
- tags: string[];
719
- operationId: string;
720
- operationName: string;
721
- response: GetterResponse;
722
- body: GetterBody;
723
- headers?: GetterQueryParam;
724
- queryParams?: GetterQueryParam;
725
- params: GetterParams;
726
- props: GetterProps;
727
- mutator?: GeneratorMutator;
728
- formData?: GeneratorMutator;
729
- formUrlEncoded?: GeneratorMutator;
730
- paramsSerializer?: GeneratorMutator;
731
- fetchReviver?: GeneratorMutator;
732
- override: NormalizedOverrideOutput;
733
- deprecated?: boolean;
734
- originalOperation: OperationObject;
702
+ verb: Verbs;
703
+ route: string;
704
+ pathRoute: string;
705
+ summary?: string;
706
+ doc: string;
707
+ tags: string[];
708
+ operationId: string;
709
+ operationName: string;
710
+ response: GetterResponse;
711
+ body: GetterBody;
712
+ headers?: GetterQueryParam;
713
+ queryParams?: GetterQueryParam;
714
+ params: GetterParams;
715
+ props: GetterProps;
716
+ mutator?: GeneratorMutator;
717
+ formData?: GeneratorMutator;
718
+ formUrlEncoded?: GeneratorMutator;
719
+ paramsSerializer?: GeneratorMutator;
720
+ fetchReviver?: GeneratorMutator;
721
+ override: NormalizedOverrideOutput;
722
+ deprecated?: boolean;
723
+ originalOperation: OperationObject;
735
724
  };
736
725
  type GeneratorVerbsOptions = GeneratorVerbOptions[];
737
726
  type GeneratorOptions = {
738
- route: string;
739
- pathRoute: string;
740
- override: NormalizedOverrideOutput;
741
- context: ContextSpecs;
742
- mock?: GlobalMockOptions | ClientMockBuilder;
743
- output: string;
727
+ route: string;
728
+ pathRoute: string;
729
+ override: NormalizedOverrideOutput;
730
+ context: ContextSpecs;
731
+ mock?: GlobalMockOptions | ClientMockBuilder;
732
+ output: string;
744
733
  };
745
734
  type GeneratorClient = {
746
- implementation: string;
747
- imports: GeneratorImport[];
748
- mutators?: GeneratorMutator[];
735
+ implementation: string;
736
+ imports: GeneratorImport[];
737
+ mutators?: GeneratorMutator[];
749
738
  };
750
739
  type GeneratorMutatorParsingInfo = {
751
- numberOfParams: number;
752
- returnNumberOfParams?: number;
740
+ numberOfParams: number;
741
+ returnNumberOfParams?: number;
753
742
  };
754
743
  type GeneratorMutator = {
755
- name: string;
756
- path: string;
757
- default: boolean;
758
- hasErrorType: boolean;
759
- errorTypeName: string;
760
- hasSecondArg: boolean;
761
- hasThirdArg: boolean;
762
- isHook: boolean;
763
- bodyTypeName?: string;
744
+ name: string;
745
+ path: string;
746
+ default: boolean;
747
+ hasErrorType: boolean;
748
+ errorTypeName: string;
749
+ hasSecondArg: boolean;
750
+ hasThirdArg: boolean;
751
+ isHook: boolean;
752
+ bodyTypeName?: string;
764
753
  };
765
754
  type ClientBuilder = (verbOptions: GeneratorVerbOptions, options: GeneratorOptions, outputClient: OutputClient | OutputClientFunc, output?: NormalizedOutputOptions) => GeneratorClient | Promise<GeneratorClient>;
766
755
  type ClientFileBuilder = {
767
- path: string;
768
- content: string;
756
+ path: string;
757
+ content: string;
769
758
  };
770
759
  type ClientExtraFilesBuilder = (verbOptions: Record<string, GeneratorVerbOptions>, output: NormalizedOutputOptions, context: ContextSpecs) => Promise<ClientFileBuilder[]>;
771
760
  type ClientHeaderBuilder = (params: {
772
- title: string;
773
- isRequestOptions: boolean;
774
- isMutator: boolean;
775
- noFunction?: boolean;
776
- isGlobalMutator: boolean;
777
- provideIn: boolean | 'root' | 'any';
778
- hasAwaitedType: boolean;
779
- output: NormalizedOutputOptions;
780
- verbOptions: Record<string, GeneratorVerbOptions>;
781
- tag?: string;
782
- clientImplementation: string;
761
+ title: string;
762
+ isRequestOptions: boolean;
763
+ isMutator: boolean;
764
+ noFunction?: boolean;
765
+ isGlobalMutator: boolean;
766
+ provideIn: boolean | 'root' | 'any';
767
+ hasAwaitedType: boolean;
768
+ output: NormalizedOutputOptions;
769
+ verbOptions: Record<string, GeneratorVerbOptions>;
770
+ tag?: string;
771
+ clientImplementation: string;
783
772
  }) => string;
784
773
  type ClientFooterBuilder = (params: {
785
- noFunction?: boolean | undefined;
786
- operationNames: string[];
787
- title?: string;
788
- hasAwaitedType: boolean;
789
- hasMutator: boolean;
774
+ noFunction?: boolean | undefined;
775
+ operationNames: string[];
776
+ title?: string;
777
+ hasAwaitedType: boolean;
778
+ hasMutator: boolean;
790
779
  }) => string;
791
780
  type ClientTitleBuilder = (title: string) => string;
792
781
  type ClientDependenciesBuilder = (hasGlobalMutator: boolean, hasParamsSerializerOptions: boolean, packageJson?: PackageJson, httpClient?: OutputHttpClient, hasTagsMutator?: boolean, override?: NormalizedOverrideOutput) => GeneratorDependency[];
793
782
  type ClientMockGeneratorImplementation = {
794
- function: string;
795
- handlerName: string;
796
- handler: string;
783
+ function: string;
784
+ handlerName: string;
785
+ handler: string;
797
786
  };
798
787
  type ClientMockGeneratorBuilder = {
799
- imports: GeneratorImport[];
800
- implementation: ClientMockGeneratorImplementation;
788
+ imports: GeneratorImport[];
789
+ implementation: ClientMockGeneratorImplementation;
801
790
  };
802
791
  type ClientMockBuilder = (verbOptions: GeneratorVerbOptions, generatorOptions: GeneratorOptions) => ClientMockGeneratorBuilder;
803
792
  interface ClientGeneratorsBuilder {
804
- client: ClientBuilder;
805
- header?: ClientHeaderBuilder;
806
- dependencies?: ClientDependenciesBuilder;
807
- footer?: ClientFooterBuilder;
808
- title?: ClientTitleBuilder;
809
- extraFiles?: ClientExtraFilesBuilder;
793
+ client: ClientBuilder;
794
+ header?: ClientHeaderBuilder;
795
+ dependencies?: ClientDependenciesBuilder;
796
+ footer?: ClientFooterBuilder;
797
+ title?: ClientTitleBuilder;
798
+ extraFiles?: ClientExtraFilesBuilder;
810
799
  }
811
800
  type GeneratorClients = Record<OutputClient, ClientGeneratorsBuilder>;
812
801
  type GetterResponse = {
813
- imports: GeneratorImport[];
814
- definition: {
815
- success: string;
816
- errors: string;
817
- };
818
- isBlob: boolean;
819
- types: {
820
- success: ResReqTypesValue[];
821
- errors: ResReqTypesValue[];
822
- };
823
- contentTypes: string[];
824
- schemas: GeneratorSchema[];
825
- originalSchema?: ResponsesObject;
802
+ imports: GeneratorImport[];
803
+ definition: {
804
+ success: string;
805
+ errors: string;
806
+ };
807
+ isBlob: boolean;
808
+ types: {
809
+ success: ResReqTypesValue[];
810
+ errors: ResReqTypesValue[];
811
+ };
812
+ contentTypes: string[];
813
+ schemas: GeneratorSchema[];
814
+ originalSchema?: ResponsesObject;
826
815
  };
827
816
  type GetterBody = {
828
- originalSchema: ReferenceObject | RequestBodyObject;
829
- imports: GeneratorImport[];
830
- definition: string;
831
- implementation: string;
832
- schemas: GeneratorSchema[];
833
- formData?: string;
834
- formUrlEncoded?: string;
835
- contentType: string;
836
- isOptional: boolean;
817
+ originalSchema: ReferenceObject | RequestBodyObject;
818
+ imports: GeneratorImport[];
819
+ definition: string;
820
+ implementation: string;
821
+ schemas: GeneratorSchema[];
822
+ formData?: string;
823
+ formUrlEncoded?: string;
824
+ contentType: string;
825
+ isOptional: boolean;
837
826
  };
838
827
  type GetterParameters = {
839
- query: {
840
- parameter: ParameterObject;
841
- imports: GeneratorImport[];
842
- }[];
843
- path: {
844
- parameter: ParameterObject;
845
- imports: GeneratorImport[];
846
- }[];
847
- header: {
848
- parameter: ParameterObject;
849
- imports: GeneratorImport[];
850
- }[];
828
+ query: {
829
+ parameter: ParameterObject;
830
+ imports: GeneratorImport[];
831
+ }[];
832
+ path: {
833
+ parameter: ParameterObject;
834
+ imports: GeneratorImport[];
835
+ }[];
836
+ header: {
837
+ parameter: ParameterObject;
838
+ imports: GeneratorImport[];
839
+ }[];
851
840
  };
852
841
  type GetterParam = {
853
- name: string;
854
- definition: string;
855
- implementation: string;
856
- default: boolean;
857
- required: boolean;
858
- imports: GeneratorImport[];
842
+ name: string;
843
+ definition: string;
844
+ implementation: string;
845
+ default: boolean;
846
+ required: boolean;
847
+ imports: GeneratorImport[];
859
848
  };
860
849
  type GetterParams = GetterParam[];
861
850
  type GetterQueryParam = {
862
- schema: GeneratorSchema;
863
- deps: GeneratorSchema[];
864
- isOptional: boolean;
865
- originalSchema?: SchemaObject;
851
+ schema: GeneratorSchema;
852
+ deps: GeneratorSchema[];
853
+ isOptional: boolean;
854
+ originalSchema?: SchemaObject;
866
855
  };
867
856
  type GetterPropType = 'param' | 'body' | 'queryParam' | 'header' | 'namedPathParams';
868
857
  declare const GetterPropType: {
869
- readonly PARAM: "param";
870
- readonly NAMED_PATH_PARAMS: "namedPathParams";
871
- readonly BODY: "body";
872
- readonly QUERY_PARAM: "queryParam";
873
- readonly HEADER: "header";
858
+ readonly PARAM: "param";
859
+ readonly NAMED_PATH_PARAMS: "namedPathParams";
860
+ readonly BODY: "body";
861
+ readonly QUERY_PARAM: "queryParam";
862
+ readonly HEADER: "header";
874
863
  };
875
864
  type GetterPropBase = {
876
- name: string;
877
- definition: string;
878
- implementation: string;
879
- default: boolean;
880
- required: boolean;
865
+ name: string;
866
+ definition: string;
867
+ implementation: string;
868
+ default: boolean;
869
+ required: boolean;
881
870
  };
882
871
  type GetterProp = GetterPropBase & ({
883
- type: 'namedPathParams';
884
- destructured: string;
885
- schema: GeneratorSchema;
872
+ type: 'namedPathParams';
873
+ destructured: string;
874
+ schema: GeneratorSchema;
886
875
  } | {
887
- type: Exclude<GetterPropType, 'namedPathParams'>;
876
+ type: Exclude<GetterPropType, 'namedPathParams'>;
888
877
  });
889
878
  type GetterProps = GetterProp[];
890
879
  type SchemaType = 'integer' | 'number' | 'string' | 'boolean' | 'object' | 'null' | 'array' | 'enum' | 'unknown';
891
880
  declare const SchemaType: {
892
- integer: string;
893
- number: string;
894
- string: string;
895
- boolean: string;
896
- object: string;
897
- null: string;
898
- array: string;
899
- enum: string;
900
- unknown: string;
881
+ integer: string;
882
+ number: string;
883
+ string: string;
884
+ boolean: string;
885
+ object: string;
886
+ null: string;
887
+ array: string;
888
+ enum: string;
889
+ unknown: string;
901
890
  };
902
891
  type ScalarValue = {
903
- value: string;
904
- isEnum: boolean;
905
- hasReadonlyProps: boolean;
906
- type: SchemaType;
907
- imports: GeneratorImport[];
908
- schemas: GeneratorSchema[];
909
- isRef: boolean;
910
- example?: any;
911
- examples?: Record<string, any>;
892
+ value: string;
893
+ isEnum: boolean;
894
+ hasReadonlyProps: boolean;
895
+ type: SchemaType;
896
+ imports: GeneratorImport[];
897
+ schemas: GeneratorSchema[];
898
+ isRef: boolean;
899
+ example?: any;
900
+ examples?: Record<string, any>;
912
901
  };
913
902
  type ResolverValue = ScalarValue & {
914
- originalSchema: SchemaObject;
903
+ originalSchema: SchemaObject;
915
904
  };
916
905
  type ResReqTypesValue = ScalarValue & {
917
- formData?: string;
918
- formUrlEncoded?: string;
919
- isRef?: boolean;
920
- hasReadonlyProps?: boolean;
921
- key: string;
922
- contentType: string;
923
- originalSchema?: SchemaObject;
906
+ formData?: string;
907
+ formUrlEncoded?: string;
908
+ isRef?: boolean;
909
+ hasReadonlyProps?: boolean;
910
+ key: string;
911
+ contentType: string;
912
+ originalSchema?: SchemaObject;
924
913
  };
925
914
  type WriteSpecsBuilder = {
926
- operations: GeneratorOperations;
927
- schemas: Record<string, GeneratorSchema[]>;
928
- verbOptions: Record<string, GeneratorVerbOptions>;
929
- title: GeneratorClientTitle;
930
- header: GeneratorClientHeader;
931
- footer: GeneratorClientFooter;
932
- imports: GeneratorClientImports;
933
- importsMock: GenerateMockImports;
934
- extraFiles: ClientFileBuilder[];
935
- info: InfoObject;
936
- target: string;
915
+ operations: GeneratorOperations;
916
+ schemas: Record<string, GeneratorSchema[]>;
917
+ verbOptions: Record<string, GeneratorVerbOptions>;
918
+ title: GeneratorClientTitle;
919
+ header: GeneratorClientHeader;
920
+ footer: GeneratorClientFooter;
921
+ imports: GeneratorClientImports;
922
+ importsMock: GenerateMockImports;
923
+ extraFiles: ClientFileBuilder[];
924
+ info: InfoObject;
925
+ target: string;
937
926
  };
938
927
  type WriteModeProps = {
939
- builder: WriteSpecsBuilder;
940
- output: NormalizedOutputOptions;
941
- workspace: string;
942
- specsName: Record<string, string>;
943
- header: string;
944
- needSchema: boolean;
928
+ builder: WriteSpecsBuilder;
929
+ output: NormalizedOutputOptions;
930
+ workspace: string;
931
+ specsName: Record<string, string>;
932
+ header: string;
933
+ needSchema: boolean;
945
934
  };
946
935
  type GeneratorApiOperations = {
947
- verbOptions: Record<string, GeneratorVerbOptions>;
948
- operations: GeneratorOperations;
949
- schemas: GeneratorSchema[];
936
+ verbOptions: Record<string, GeneratorVerbOptions>;
937
+ operations: GeneratorOperations;
938
+ schemas: GeneratorSchema[];
950
939
  };
951
940
  type GeneratorClientExtra = {
952
- implementation: string;
953
- implementationMock: string;
941
+ implementation: string;
942
+ implementationMock: string;
954
943
  };
955
944
  type GeneratorClientTitle = (data: {
956
- outputClient?: OutputClient | OutputClientFunc;
957
- title: string;
958
- customTitleFunc?: (title: string) => string;
959
- output: NormalizedOutputOptions;
945
+ outputClient?: OutputClient | OutputClientFunc;
946
+ title: string;
947
+ customTitleFunc?: (title: string) => string;
948
+ output: NormalizedOutputOptions;
960
949
  }) => GeneratorClientExtra;
961
950
  type GeneratorClientHeader = (data: {
962
- outputClient?: OutputClient | OutputClientFunc;
963
- isRequestOptions: boolean;
964
- isMutator: boolean;
965
- isGlobalMutator: boolean;
966
- provideIn: boolean | 'root' | 'any';
967
- hasAwaitedType: boolean;
968
- titles: GeneratorClientExtra;
969
- output: NormalizedOutputOptions;
970
- verbOptions: Record<string, GeneratorVerbOptions>;
971
- tag?: string;
972
- clientImplementation: string;
951
+ outputClient?: OutputClient | OutputClientFunc;
952
+ isRequestOptions: boolean;
953
+ isMutator: boolean;
954
+ isGlobalMutator: boolean;
955
+ provideIn: boolean | 'root' | 'any';
956
+ hasAwaitedType: boolean;
957
+ titles: GeneratorClientExtra;
958
+ output: NormalizedOutputOptions;
959
+ verbOptions: Record<string, GeneratorVerbOptions>;
960
+ tag?: string;
961
+ clientImplementation: string;
973
962
  }) => GeneratorClientExtra;
974
963
  type GeneratorClientFooter = (data: {
975
- outputClient: OutputClient | OutputClientFunc;
976
- operationNames: string[];
977
- hasMutator: boolean;
978
- hasAwaitedType: boolean;
979
- titles: GeneratorClientExtra;
980
- output: NormalizedOutputOptions;
964
+ outputClient: OutputClient | OutputClientFunc;
965
+ operationNames: string[];
966
+ hasMutator: boolean;
967
+ hasAwaitedType: boolean;
968
+ titles: GeneratorClientExtra;
969
+ output: NormalizedOutputOptions;
981
970
  }) => GeneratorClientExtra;
982
971
  type GeneratorClientImports = (data: {
983
- client: OutputClient | OutputClientFunc;
984
- implementation: string;
985
- imports: {
986
- exports: GeneratorImport[];
987
- dependency: string;
988
- }[];
989
- specsName: Record<string, string>;
990
- hasSchemaDir: boolean;
991
- isAllowSyntheticDefaultImports: boolean;
992
- hasGlobalMutator: boolean;
993
- hasTagsMutator: boolean;
994
- hasParamsSerializerOptions: boolean;
995
- packageJson?: PackageJson;
996
- output: NormalizedOutputOptions;
972
+ client: OutputClient | OutputClientFunc;
973
+ implementation: string;
974
+ imports: {
975
+ exports: GeneratorImport[];
976
+ dependency: string;
977
+ }[];
978
+ specsName: Record<string, string>;
979
+ hasSchemaDir: boolean;
980
+ isAllowSyntheticDefaultImports: boolean;
981
+ hasGlobalMutator: boolean;
982
+ hasTagsMutator: boolean;
983
+ hasParamsSerializerOptions: boolean;
984
+ packageJson?: PackageJson;
985
+ output: NormalizedOutputOptions;
997
986
  }) => string;
998
987
  type GenerateMockImports = (data: {
999
- implementation: string;
1000
- imports: {
1001
- exports: GeneratorImport[];
1002
- dependency: string;
1003
- }[];
1004
- specsName: Record<string, string>;
1005
- hasSchemaDir: boolean;
1006
- isAllowSyntheticDefaultImports: boolean;
1007
- options?: GlobalMockOptions;
988
+ implementation: string;
989
+ imports: {
990
+ exports: GeneratorImport[];
991
+ dependency: string;
992
+ }[];
993
+ specsName: Record<string, string>;
994
+ hasSchemaDir: boolean;
995
+ isAllowSyntheticDefaultImports: boolean;
996
+ options?: GlobalMockOptions;
1008
997
  }) => string;
1009
998
  type GeneratorApiBuilder = GeneratorApiOperations & {
1010
- title: GeneratorClientTitle;
1011
- header: GeneratorClientHeader;
1012
- footer: GeneratorClientFooter;
1013
- imports: GeneratorClientImports;
1014
- importsMock: GenerateMockImports;
1015
- extraFiles: ClientFileBuilder[];
999
+ title: GeneratorClientTitle;
1000
+ header: GeneratorClientHeader;
1001
+ footer: GeneratorClientFooter;
1002
+ imports: GeneratorClientImports;
1003
+ importsMock: GenerateMockImports;
1004
+ extraFiles: ClientFileBuilder[];
1016
1005
  };
1017
1006
  interface SchemaWithConst extends SchemaObject {
1018
- const: string;
1007
+ const: string;
1019
1008
  }
1020
-
1009
+ declare class ErrorWithTag extends Error {
1010
+ tag: string;
1011
+ constructor(message: string, tag: string, options?: ErrorOptions);
1012
+ }
1013
+ //#endregion
1014
+ //#region src/constants.d.ts
1021
1015
  declare const generalJSTypes: string[];
1022
1016
  declare const generalJSTypesWithArray: string[];
1023
1017
  declare const VERBS_WITH_BODY: Verbs[];
1024
1018
  declare const URL_REGEX: RegExp;
1025
1019
  declare const TEMPLATE_TAG_REGEX: RegExp;
1026
-
1020
+ //#endregion
1021
+ //#region src/generators/component-definition.d.ts
1027
1022
  declare const generateComponentDefinition: (responses: ComponentsObject["responses"] | ComponentsObject["requestBodies"], context: ContextSpecs, suffix: string) => GeneratorSchema[];
1028
-
1029
- declare const generateImports: ({ imports, target, isRootKey, specsName, specKey: currentSpecKey, namingConvention, }: {
1030
- imports: GeneratorImport[];
1031
- target: string;
1032
- isRootKey: boolean;
1033
- specsName: Record<string, string>;
1034
- specKey: string;
1035
- namingConvention?: NamingConvention;
1023
+ //#endregion
1024
+ //#region src/generators/imports.d.ts
1025
+ declare const generateImports: ({
1026
+ imports,
1027
+ target,
1028
+ isRootKey,
1029
+ specsName,
1030
+ specKey: currentSpecKey,
1031
+ namingConvention
1032
+ }: {
1033
+ imports: GeneratorImport[];
1034
+ target: string;
1035
+ isRootKey: boolean;
1036
+ specsName: Record<string, string>;
1037
+ specKey: string;
1038
+ namingConvention?: NamingConvention;
1036
1039
  }) => string;
1037
- declare const generateMutatorImports: ({ mutators, implementation, oneMore, }: {
1038
- mutators: GeneratorMutator[];
1039
- implementation?: string;
1040
- oneMore?: boolean;
1040
+ declare const generateMutatorImports: ({
1041
+ mutators,
1042
+ implementation,
1043
+ oneMore
1044
+ }: {
1045
+ mutators: GeneratorMutator[];
1046
+ implementation?: string;
1047
+ oneMore?: boolean;
1041
1048
  }) => string;
1042
- declare const addDependency: ({ implementation, exports, dependency, specsName, hasSchemaDir, isAllowSyntheticDefaultImports, }: {
1043
- implementation: string;
1044
- exports: GeneratorImport[];
1045
- dependency: string;
1046
- specsName: Record<string, string>;
1047
- hasSchemaDir: boolean;
1048
- isAllowSyntheticDefaultImports: boolean;
1049
+ declare const addDependency: ({
1050
+ implementation,
1051
+ exports,
1052
+ dependency,
1053
+ specsName,
1054
+ hasSchemaDir,
1055
+ isAllowSyntheticDefaultImports
1056
+ }: {
1057
+ implementation: string;
1058
+ exports: GeneratorImport[];
1059
+ dependency: string;
1060
+ specsName: Record<string, string>;
1061
+ hasSchemaDir: boolean;
1062
+ isAllowSyntheticDefaultImports: boolean;
1049
1063
  }) => string | undefined;
1050
1064
  declare const generateDependencyImports: (implementation: string, imports: {
1051
- exports: GeneratorImport[];
1052
- dependency: string;
1065
+ exports: GeneratorImport[];
1066
+ dependency: string;
1053
1067
  }[], specsName: Record<string, string>, hasSchemaDir: boolean, isAllowSyntheticDefaultImports: boolean) => string;
1054
- declare const generateVerbImports: ({ response, body, queryParams, props, headers, params, }: GeneratorVerbOptions) => GeneratorImport[];
1055
-
1068
+ declare const generateVerbImports: ({
1069
+ response,
1070
+ body,
1071
+ queryParams,
1072
+ props,
1073
+ headers,
1074
+ params
1075
+ }: GeneratorVerbOptions) => GeneratorImport[];
1076
+ //#endregion
1077
+ //#region src/generators/models-inline.d.ts
1056
1078
  declare const generateModelInline: (acc: string, model: string) => string;
1057
1079
  declare const generateModelsInline: (obj: Record<string, GeneratorSchema[]>) => string;
1058
-
1080
+ //#endregion
1081
+ //#region src/generators/mutator.d.ts
1059
1082
  declare const BODY_TYPE_NAME = "BodyType";
1060
- declare const generateMutator: ({ output, mutator, name, workspace, tsconfig, }: {
1061
- output?: string;
1062
- mutator?: NormalizedMutator;
1063
- name: string;
1064
- workspace: string;
1065
- tsconfig?: Tsconfig;
1083
+ declare const generateMutator: ({
1084
+ output,
1085
+ mutator,
1086
+ name,
1087
+ workspace,
1088
+ tsconfig
1089
+ }: {
1090
+ output?: string;
1091
+ mutator?: NormalizedMutator;
1092
+ name: string;
1093
+ workspace: string;
1094
+ tsconfig?: Tsconfig;
1066
1095
  }) => Promise<GeneratorMutator | undefined>;
1067
-
1096
+ //#endregion
1097
+ //#region src/generators/options.d.ts
1068
1098
  declare const generateBodyOptions: (body: GetterBody, isFormData: boolean, isFormUrlEncoded: boolean) => string;
1069
- declare const generateAxiosOptions: ({ response, isExactOptionalPropertyTypes, queryParams, headers, requestOptions, hasSignal, isVue, paramsSerializer, paramsSerializerOptions, }: {
1070
- response: GetterResponse;
1071
- isExactOptionalPropertyTypes: boolean;
1072
- queryParams?: GeneratorSchema;
1073
- headers?: GeneratorSchema;
1074
- requestOptions?: object | boolean;
1075
- hasSignal: boolean;
1076
- isVue: boolean;
1077
- paramsSerializer?: GeneratorMutator;
1078
- paramsSerializerOptions?: ParamsSerializerOptions;
1099
+ declare const generateAxiosOptions: ({
1100
+ response,
1101
+ isExactOptionalPropertyTypes,
1102
+ queryParams,
1103
+ headers,
1104
+ requestOptions,
1105
+ hasSignal,
1106
+ isVue,
1107
+ isAngular,
1108
+ paramsSerializer,
1109
+ paramsSerializerOptions
1110
+ }: {
1111
+ response: GetterResponse;
1112
+ isExactOptionalPropertyTypes: boolean;
1113
+ queryParams?: GeneratorSchema;
1114
+ headers?: GeneratorSchema;
1115
+ requestOptions?: object | boolean;
1116
+ hasSignal: boolean;
1117
+ isVue: boolean;
1118
+ isAngular: boolean;
1119
+ paramsSerializer?: GeneratorMutator;
1120
+ paramsSerializerOptions?: ParamsSerializerOptions;
1079
1121
  }) => string;
1080
- declare const generateOptions: ({ route, body, headers, queryParams, response, verb, requestOptions, isFormData, isFormUrlEncoded, isAngular, isExactOptionalPropertyTypes, hasSignal, isVue, paramsSerializer, paramsSerializerOptions, }: {
1081
- route: string;
1082
- body: GetterBody;
1083
- headers?: GetterQueryParam;
1084
- queryParams?: GetterQueryParam;
1085
- response: GetterResponse;
1086
- verb: Verbs;
1087
- requestOptions?: object | boolean;
1088
- isFormData: boolean;
1089
- isFormUrlEncoded: boolean;
1090
- isAngular?: boolean;
1091
- isExactOptionalPropertyTypes: boolean;
1092
- hasSignal: boolean;
1093
- isVue?: boolean;
1094
- paramsSerializer?: GeneratorMutator;
1095
- paramsSerializerOptions?: ParamsSerializerOptions;
1122
+ declare const generateOptions: ({
1123
+ route,
1124
+ body,
1125
+ headers,
1126
+ queryParams,
1127
+ response,
1128
+ verb,
1129
+ requestOptions,
1130
+ isFormData,
1131
+ isFormUrlEncoded,
1132
+ isAngular,
1133
+ isExactOptionalPropertyTypes,
1134
+ hasSignal,
1135
+ isVue,
1136
+ paramsSerializer,
1137
+ paramsSerializerOptions
1138
+ }: {
1139
+ route: string;
1140
+ body: GetterBody;
1141
+ headers?: GetterQueryParam;
1142
+ queryParams?: GetterQueryParam;
1143
+ response: GetterResponse;
1144
+ verb: Verbs;
1145
+ requestOptions?: object | boolean;
1146
+ isFormData: boolean;
1147
+ isFormUrlEncoded: boolean;
1148
+ isAngular?: boolean;
1149
+ isExactOptionalPropertyTypes: boolean;
1150
+ hasSignal: boolean;
1151
+ isVue?: boolean;
1152
+ paramsSerializer?: GeneratorMutator;
1153
+ paramsSerializerOptions?: ParamsSerializerOptions;
1096
1154
  }) => string;
1097
1155
  declare const generateBodyMutatorConfig: (body: GetterBody, isFormData: boolean, isFormUrlEncoded: boolean) => string;
1098
1156
  declare const generateQueryParamsAxiosConfig: (response: GetterResponse, isVue: boolean, queryParams?: GetterQueryParam) => string;
1099
- declare const generateMutatorConfig: ({ route, body, headers, queryParams, response, verb, isFormData, isFormUrlEncoded, hasSignal, isExactOptionalPropertyTypes, isVue, }: {
1100
- route: string;
1101
- body: GetterBody;
1102
- headers?: GetterQueryParam;
1103
- queryParams?: GetterQueryParam;
1104
- response: GetterResponse;
1105
- verb: Verbs;
1106
- isFormData: boolean;
1107
- isFormUrlEncoded: boolean;
1108
- hasSignal: boolean;
1109
- isExactOptionalPropertyTypes: boolean;
1110
- isVue?: boolean;
1157
+ declare const generateMutatorConfig: ({
1158
+ route,
1159
+ body,
1160
+ headers,
1161
+ queryParams,
1162
+ response,
1163
+ verb,
1164
+ isFormData,
1165
+ isFormUrlEncoded,
1166
+ hasSignal,
1167
+ isExactOptionalPropertyTypes,
1168
+ isVue
1169
+ }: {
1170
+ route: string;
1171
+ body: GetterBody;
1172
+ headers?: GetterQueryParam;
1173
+ queryParams?: GetterQueryParam;
1174
+ response: GetterResponse;
1175
+ verb: Verbs;
1176
+ isFormData: boolean;
1177
+ isFormUrlEncoded: boolean;
1178
+ hasSignal: boolean;
1179
+ isExactOptionalPropertyTypes: boolean;
1180
+ isVue?: boolean;
1111
1181
  }) => string;
1112
1182
  declare const generateMutatorRequestOptions: (requestOptions: boolean | object | undefined, hasSecondArgument: boolean) => string;
1113
- declare const generateFormDataAndUrlEncodedFunction: ({ body, formData, formUrlEncoded, isFormData, isFormUrlEncoded, }: {
1114
- body: GetterBody;
1115
- formData?: GeneratorMutator;
1116
- formUrlEncoded?: GeneratorMutator;
1117
- isFormData: boolean;
1118
- isFormUrlEncoded: boolean;
1183
+ declare const generateFormDataAndUrlEncodedFunction: ({
1184
+ body,
1185
+ formData,
1186
+ formUrlEncoded,
1187
+ isFormData,
1188
+ isFormUrlEncoded
1189
+ }: {
1190
+ body: GetterBody;
1191
+ formData?: GeneratorMutator;
1192
+ formUrlEncoded?: GeneratorMutator;
1193
+ isFormData: boolean;
1194
+ isFormUrlEncoded: boolean;
1119
1195
  }) => string;
1120
-
1196
+ //#endregion
1197
+ //#region src/generators/parameter-definition.d.ts
1121
1198
  declare const generateParameterDefinition: (parameters: ComponentsObject["parameters"], context: ContextSpecs, suffix: string) => GeneratorSchema[];
1122
-
1199
+ //#endregion
1200
+ //#region src/generators/schema-definition.d.ts
1123
1201
  /**
1124
1202
  * Extract all types from #/components/schemas
1125
1203
  *
1126
1204
  * @param schemas
1127
1205
  */
1128
1206
  declare const generateSchemasDefinition: (schemas: SchemasObject | undefined, context: ContextSpecs, suffix: string, filters?: InputFiltersOption) => GeneratorSchema[];
1129
-
1130
- declare const generateVerbsOptions: ({ verbs, input, output, route, pathRoute, context, }: {
1131
- verbs: PathItemObject;
1132
- input: NormalizedInputOptions;
1133
- output: NormalizedOutputOptions;
1134
- route: string;
1135
- pathRoute: string;
1136
- context: ContextSpecs;
1207
+ //#endregion
1208
+ //#region src/generators/verbs-options.d.ts
1209
+ declare const generateVerbsOptions: ({
1210
+ verbs,
1211
+ input,
1212
+ output,
1213
+ route,
1214
+ pathRoute,
1215
+ context
1216
+ }: {
1217
+ verbs: PathItemObject;
1218
+ input: NormalizedInputOptions;
1219
+ output: NormalizedOutputOptions;
1220
+ route: string;
1221
+ pathRoute: string;
1222
+ context: ContextSpecs;
1137
1223
  }) => Promise<GeneratorVerbsOptions>;
1138
1224
  declare const _filteredVerbs: (verbs: PathItemObject, filters: NormalizedInputOptions["filters"]) => [string, any][];
1139
-
1225
+ //#endregion
1226
+ //#region src/getters/array.d.ts
1140
1227
  /**
1141
1228
  * Return the output type from an array
1142
1229
  *
1143
1230
  * @param item item with type === "array"
1144
1231
  */
1145
- declare const getArray: ({ schema, name, context, }: {
1146
- schema: SchemaObject;
1147
- name?: string;
1148
- context: ContextSpecs;
1232
+ declare const getArray: ({
1233
+ schema,
1234
+ name,
1235
+ context
1236
+ }: {
1237
+ schema: SchemaObject;
1238
+ name?: string;
1239
+ context: ContextSpecs;
1149
1240
  }) => ScalarValue;
1150
-
1151
- declare const getBody: ({ requestBody, operationName, context, contentType, }: {
1152
- requestBody: ReferenceObject | RequestBodyObject;
1153
- operationName: string;
1154
- context: ContextSpecs;
1155
- contentType?: OverrideOutputContentType;
1241
+ //#endregion
1242
+ //#region src/getters/body.d.ts
1243
+ declare const getBody: ({
1244
+ requestBody,
1245
+ operationName,
1246
+ context,
1247
+ contentType
1248
+ }: {
1249
+ requestBody: ReferenceObject | RequestBodyObject;
1250
+ operationName: string;
1251
+ context: ContextSpecs;
1252
+ contentType?: OverrideOutputContentType;
1156
1253
  }) => GetterBody;
1157
-
1254
+ //#endregion
1255
+ //#region src/getters/combine.d.ts
1158
1256
  type Separator = 'allOf' | 'anyOf' | 'oneOf';
1159
- declare const combineSchemas: ({ name, schema, separator, context, nullable, }: {
1160
- name?: string;
1161
- schema: SchemaObject;
1162
- separator: Separator;
1163
- context: ContextSpecs;
1164
- nullable: string;
1257
+ declare const combineSchemas: ({
1258
+ name,
1259
+ schema,
1260
+ separator,
1261
+ context,
1262
+ nullable
1263
+ }: {
1264
+ name?: string;
1265
+ schema: SchemaObject;
1266
+ separator: Separator;
1267
+ context: ContextSpecs;
1268
+ nullable: string;
1165
1269
  }) => ScalarValue;
1166
-
1270
+ //#endregion
1271
+ //#region src/getters/discriminators.d.ts
1167
1272
  declare const resolveDiscriminators: (schemas: SchemasObject, context: ContextSpecs) => SchemasObject;
1168
-
1169
- declare const getEnumNames: (schemaObject: SchemaObject$1 | undefined) => any;
1170
- declare const getEnumDescriptions: (schemaObject: SchemaObject$1 | undefined) => any;
1273
+ //#endregion
1274
+ //#region src/getters/enum.d.ts
1275
+ declare const getEnumNames: (schemaObject: SchemaObject | undefined) => any;
1276
+ declare const getEnumDescriptions: (schemaObject: SchemaObject | undefined) => any;
1171
1277
  declare const getEnum: (value: string, enumName: string, names: string[] | undefined, enumGenerationType: EnumGeneration, descriptions?: string[], enumNamingConvention?: NamingConvention) => string;
1172
1278
  declare const getEnumImplementation: (value: string, names?: string[], descriptions?: string[], enumNamingConvention?: NamingConvention) => string;
1173
-
1279
+ //#endregion
1280
+ //#region src/getters/keys.d.ts
1174
1281
  declare const getKey: (key: string) => string;
1175
-
1282
+ //#endregion
1283
+ //#region src/getters/object.d.ts
1176
1284
  /**
1177
1285
  * Return the output type from an object
1178
1286
  *
1179
1287
  * @param item item with type === "object"
1180
1288
  */
1181
- declare const getObject: ({ item, name, context, nullable, }: {
1182
- item: SchemaObject;
1183
- name?: string;
1184
- context: ContextSpecs;
1185
- nullable: string;
1289
+ declare const getObject: ({
1290
+ item,
1291
+ name,
1292
+ context,
1293
+ nullable
1294
+ }: {
1295
+ item: SchemaObject;
1296
+ name?: string;
1297
+ context: ContextSpecs;
1298
+ nullable: string;
1186
1299
  }) => ScalarValue;
1187
-
1300
+ //#endregion
1301
+ //#region src/getters/operation.d.ts
1188
1302
  declare const getOperationId: (operation: OperationObject, route: string, verb: Verbs) => string;
1189
-
1190
- declare const getParameters: ({ parameters, context, }: {
1191
- parameters: (ReferenceObject | ParameterObject)[];
1192
- context: ContextSpecs;
1303
+ //#endregion
1304
+ //#region src/getters/parameters.d.ts
1305
+ declare const getParameters: ({
1306
+ parameters,
1307
+ context
1308
+ }: {
1309
+ parameters: (ReferenceObject | ParameterObject)[];
1310
+ context: ContextSpecs;
1193
1311
  }) => GetterParameters;
1194
-
1312
+ //#endregion
1313
+ //#region src/getters/params.d.ts
1195
1314
  /**
1196
1315
  * Return every params in a path
1197
1316
  *
@@ -1203,43 +1322,64 @@ declare const getParameters: ({ parameters, context, }: {
1203
1322
  * @param path
1204
1323
  */
1205
1324
  declare const getParamsInPath: (path: string) => string[];
1206
- declare const getParams: ({ route, pathParams, operationId, context, output, }: {
1207
- route: string;
1208
- pathParams?: GetterParameters["query"];
1209
- operationId: string;
1210
- context: ContextSpecs;
1211
- output: NormalizedOutputOptions;
1325
+ declare const getParams: ({
1326
+ route,
1327
+ pathParams,
1328
+ operationId,
1329
+ context,
1330
+ output
1331
+ }: {
1332
+ route: string;
1333
+ pathParams?: GetterParameters["query"];
1334
+ operationId: string;
1335
+ context: ContextSpecs;
1336
+ output: NormalizedOutputOptions;
1212
1337
  }) => GetterParams;
1213
-
1214
- declare const getProps: ({ body, queryParams, params, operationName, headers, context, }: {
1215
- body: GetterBody;
1216
- queryParams?: GetterQueryParam;
1217
- params: GetterParams;
1218
- operationName: string;
1219
- headers?: GetterQueryParam;
1220
- context: ContextSpecs;
1338
+ //#endregion
1339
+ //#region src/getters/props.d.ts
1340
+ declare const getProps: ({
1341
+ body,
1342
+ queryParams,
1343
+ params,
1344
+ operationName,
1345
+ headers,
1346
+ context
1347
+ }: {
1348
+ body: GetterBody;
1349
+ queryParams?: GetterQueryParam;
1350
+ params: GetterParams;
1351
+ operationName: string;
1352
+ headers?: GetterQueryParam;
1353
+ context: ContextSpecs;
1221
1354
  }) => GetterProps;
1222
-
1223
- declare const getQueryParams: ({ queryParams, operationName, context, suffix, }: {
1224
- queryParams: GetterParameters["query"];
1225
- operationName: string;
1226
- context: ContextSpecs;
1227
- suffix?: string;
1355
+ //#endregion
1356
+ //#region src/getters/query-params.d.ts
1357
+ declare const getQueryParams: ({
1358
+ queryParams,
1359
+ operationName,
1360
+ context,
1361
+ suffix
1362
+ }: {
1363
+ queryParams: GetterParameters["query"];
1364
+ operationName: string;
1365
+ context: ContextSpecs;
1366
+ suffix?: string;
1228
1367
  }) => GetterQueryParam | undefined;
1229
-
1368
+ //#endregion
1369
+ //#region src/getters/ref.d.ts
1230
1370
  type RefComponent = 'schemas' | 'responses' | 'parameters' | 'requestBodies';
1231
1371
  declare const RefComponent: {
1232
- schemas: RefComponent;
1233
- responses: RefComponent;
1234
- parameters: RefComponent;
1235
- requestBodies: RefComponent;
1372
+ schemas: RefComponent;
1373
+ responses: RefComponent;
1374
+ parameters: RefComponent;
1375
+ requestBodies: RefComponent;
1236
1376
  };
1237
1377
  declare const RefComponentSuffix: Record<RefComponent, string>;
1238
1378
  interface RefInfo {
1239
- name: string;
1240
- originalName: string;
1241
- refPaths?: string[];
1242
- specKey?: string;
1379
+ name: string;
1380
+ originalName: string;
1381
+ refPaths?: string[];
1382
+ specKey?: string;
1243
1383
  }
1244
1384
  /**
1245
1385
  * Return the output type from the $ref
@@ -1247,54 +1387,80 @@ interface RefInfo {
1247
1387
  * @param $ref
1248
1388
  */
1249
1389
  declare const getRefInfo: ($ref: ReferenceObject["$ref"], context: ContextSpecs) => RefInfo;
1250
-
1251
- declare const getResReqTypes: (responsesOrRequests: Array<[string, ResponseObject | ReferenceObject | RequestBodyObject]>, name: string, context: ContextSpecs, defaultType?: string, uniqueKey?: ValueIteratee<ResReqTypesValue>) => ResReqTypesValue[];
1252
-
1253
- declare const getResponse: ({ responses, operationName, context, contentType, }: {
1254
- responses: ResponsesObject;
1255
- operationName: string;
1256
- context: ContextSpecs;
1257
- contentType?: OverrideOutputContentType;
1390
+ //#endregion
1391
+ //#region src/getters/res-req-types.d.ts
1392
+ declare const getResReqTypes: (responsesOrRequests: [string, ResponseObject | ReferenceObject | RequestBodyObject][], name: string, context: ContextSpecs, defaultType?: string, uniqueKey?: ValueIteratee<ResReqTypesValue>) => ResReqTypesValue[];
1393
+ //#endregion
1394
+ //#region src/getters/response.d.ts
1395
+ declare const getResponse: ({
1396
+ responses,
1397
+ operationName,
1398
+ context,
1399
+ contentType
1400
+ }: {
1401
+ responses: ResponsesObject;
1402
+ operationName: string;
1403
+ context: ContextSpecs;
1404
+ contentType?: OverrideOutputContentType;
1258
1405
  }) => GetterResponse;
1259
-
1406
+ //#endregion
1407
+ //#region src/getters/route.d.ts
1260
1408
  declare const getRoute: (route: string) => string;
1261
1409
  declare const getFullRoute: (route: string, servers: ServerObject[] | undefined, baseUrl: string | BaseUrlFromConstant | BaseUrlFromSpec | undefined) => string;
1262
1410
  declare const getRouteAsArray: (route: string) => string;
1263
-
1411
+ //#endregion
1412
+ //#region src/getters/scalar.d.ts
1264
1413
  /**
1265
1414
  * Return the typescript equivalent of open-api data type
1266
1415
  *
1267
1416
  * @param item
1268
1417
  * @ref https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.1.md#data-types
1269
1418
  */
1270
- declare const getScalar: ({ item, name, context, }: {
1271
- item: SchemaObject;
1272
- name?: string;
1273
- context: ContextSpecs;
1419
+ declare const getScalar: ({
1420
+ item,
1421
+ name,
1422
+ context
1423
+ }: {
1424
+ item: SchemaObject;
1425
+ name?: string;
1426
+ context: ContextSpecs;
1274
1427
  }) => ScalarValue;
1275
-
1276
- declare const resolveObject: ({ schema, propName, combined, context, }: {
1277
- schema: SchemaObject | ReferenceObject;
1278
- propName?: string;
1279
- combined?: boolean;
1280
- context: ContextSpecs;
1428
+ //#endregion
1429
+ //#region src/resolvers/object.d.ts
1430
+ declare const resolveObject: ({
1431
+ schema,
1432
+ propName,
1433
+ combined,
1434
+ context
1435
+ }: {
1436
+ schema: SchemaObject | ReferenceObject;
1437
+ propName?: string;
1438
+ combined?: boolean;
1439
+ context: ContextSpecs;
1281
1440
  }) => ResolverValue;
1282
-
1441
+ //#endregion
1442
+ //#region src/resolvers/ref.d.ts
1283
1443
  type ComponentObject = SchemaObject | ResponseObject | ParameterObject | RequestBodyObject | ReferenceObject;
1284
1444
  declare const resolveRef: <Schema extends ComponentObject = ComponentObject>(schema: ComponentObject, context: ContextSpecs, imports?: GeneratorImport[]) => {
1285
- schema: Schema;
1286
- imports: GeneratorImport[];
1445
+ schema: Schema;
1446
+ imports: GeneratorImport[];
1287
1447
  };
1288
1448
  type Example = ExampleObject | ReferenceObject;
1289
1449
  type Examples = Example[] | Record<string, Example> | undefined;
1290
1450
  declare const resolveExampleRefs: (examples: Examples, context: ContextSpecs) => Examples;
1291
-
1292
- declare const resolveValue: ({ schema, name, context, }: {
1293
- schema: SchemaObject | ReferenceObject;
1294
- name?: string;
1295
- context: ContextSpecs;
1451
+ //#endregion
1452
+ //#region src/resolvers/value.d.ts
1453
+ declare const resolveValue: ({
1454
+ schema,
1455
+ name,
1456
+ context
1457
+ }: {
1458
+ schema: SchemaObject | ReferenceObject;
1459
+ name?: string;
1460
+ context: ContextSpecs;
1296
1461
  }) => ResolverValue;
1297
-
1462
+ //#endregion
1463
+ //#region src/utils/assertion.d.ts
1298
1464
  /**
1299
1465
  * Discriminator helper for `ReferenceObject`
1300
1466
  *
@@ -1313,177 +1479,180 @@ declare function isUndefined(x: any): x is undefined;
1313
1479
  declare function isNull(x: any): x is null;
1314
1480
  declare function isSchema(x: any): x is SchemaObject;
1315
1481
  declare const isVerb: (verb: string) => verb is Verbs;
1316
- declare const isRootKey: (specKey: string, target: string) => boolean;
1482
+ declare const isRootKey$1: (specKey: string, target: string) => boolean;
1317
1483
  declare const isUrl: (str: string) => boolean;
1318
-
1484
+ //#endregion
1485
+ //#region src/utils/async-reduce.d.ts
1319
1486
  declare function asyncReduce<IterationItem, AccValue>(array: IterationItem[], reducer: (accumulate: AccValue, current: IterationItem) => AccValue | Promise<AccValue>, initValue: AccValue): Promise<AccValue>;
1320
-
1487
+ //#endregion
1488
+ //#region src/utils/case.d.ts
1321
1489
  declare const pascal: (s: string) => string;
1322
1490
  declare const camel: (s: string) => string;
1323
1491
  declare const snake: (s: string) => string;
1324
1492
  declare const kebab: (s: string) => string;
1325
1493
  declare const upper: (s: string, fillWith: string, isDeapostrophe?: boolean) => string;
1326
1494
  declare const conventionName: (name: string, convention: NamingConvention) => string;
1327
-
1495
+ //#endregion
1496
+ //#region src/utils/compare-version.d.ts
1328
1497
  declare const compareVersions: (firstVersion: string, secondVersions: string, operator?: CompareOperator) => boolean;
1329
-
1498
+ //#endregion
1499
+ //#region src/utils/debug.d.ts
1330
1500
  interface DebuggerOptions {
1331
- onlyWhenFocused?: boolean | string;
1501
+ onlyWhenFocused?: boolean | string;
1332
1502
  }
1333
1503
  declare function createDebugger(ns: string, options?: DebuggerOptions): debug.Debugger['log'];
1334
-
1504
+ //#endregion
1505
+ //#region src/utils/deep-non-nullable.d.ts
1506
+ type DeepNonNullable<T> = T extends Function ? T : T extends readonly (infer U)[] ? DeepNonNullable<NonNullable<U>>[] : T extends object ? { [K in keyof T]: DeepNonNullable<NonNullable<T[K]>> } : NonNullable<T>;
1507
+ //#endregion
1508
+ //#region src/utils/doc.d.ts
1335
1509
  declare function jsDoc(schema: {
1336
- description?: string[] | string;
1337
- deprecated?: boolean;
1338
- summary?: string;
1339
- minLength?: number;
1340
- maxLength?: number;
1341
- minimum?: number;
1342
- maximum?: number;
1343
- exclusiveMinimum?: boolean;
1344
- exclusiveMaximum?: boolean;
1345
- minItems?: number;
1346
- maxItems?: number;
1347
- nullable?: boolean;
1348
- pattern?: string;
1510
+ description?: string[] | string;
1511
+ deprecated?: boolean;
1512
+ summary?: string;
1513
+ minLength?: number;
1514
+ maxLength?: number;
1515
+ minimum?: number;
1516
+ maximum?: number;
1517
+ exclusiveMinimum?: boolean;
1518
+ exclusiveMaximum?: boolean;
1519
+ minItems?: number;
1520
+ maxItems?: number;
1521
+ nullable?: boolean;
1522
+ pattern?: string;
1349
1523
  }, tryOneLine?: boolean, context?: ContextSpecs): string;
1350
1524
  declare function keyValuePairsToJsDoc(keyValues: {
1351
- key: string;
1352
- value: string;
1525
+ key: string;
1526
+ value: string;
1353
1527
  }[]): string;
1354
-
1528
+ //#endregion
1529
+ //#region src/utils/dynamic-import.d.ts
1355
1530
  declare const dynamicImport: <T>(toImport: T | string, from?: string, takeDefault?: boolean) => Promise<T>;
1356
-
1531
+ //#endregion
1532
+ //#region src/utils/extension.d.ts
1357
1533
  declare const getExtension: (path: string) => "yaml" | "json";
1358
-
1359
- declare const log: {
1360
- (...data: any[]): void;
1361
- (message?: any, ...optionalParams: any[]): void;
1362
- };
1363
- declare const startMessage: ({ name, version, description, }: {
1364
- name: string;
1365
- version: string;
1366
- description: string;
1367
- }) => void;
1534
+ //#endregion
1535
+ //#region src/utils/logger.d.ts
1536
+ declare const log: (message?: any, ...optionalParams: any[]) => void;
1537
+ declare const startMessage: ({
1538
+ name,
1539
+ version,
1540
+ description
1541
+ }: {
1542
+ name: string;
1543
+ version: string;
1544
+ description: string;
1545
+ }) => string;
1368
1546
  declare const logError: (err: unknown, tag?: string) => void;
1369
1547
  declare const mismatchArgsMessage: (mismatchArgs: string[]) => void;
1370
1548
  declare const createSuccessMessage: (backend?: string) => void;
1371
1549
  declare const ibmOpenapiValidatorWarnings: (warnings: {
1372
- path: string[];
1373
- message: string;
1550
+ path: string[];
1551
+ message: string;
1374
1552
  }[]) => void;
1375
1553
  declare const ibmOpenapiValidatorErrors: (errors: {
1376
- path: string[];
1377
- message: string;
1554
+ path: string[];
1555
+ message: string;
1378
1556
  }[]) => void;
1379
1557
  type LogType = 'error' | 'warn' | 'info';
1380
1558
  type LogLevel = LogType | 'silent';
1381
1559
  interface Logger {
1382
- info(msg: string, options?: LogOptions): void;
1383
- warn(msg: string, options?: LogOptions): void;
1384
- warnOnce(msg: string, options?: LogOptions): void;
1385
- error(msg: string, options?: LogOptions): void;
1386
- clearScreen(type: LogType): void;
1387
- hasWarned: boolean;
1560
+ info(msg: string, options?: LogOptions): void;
1561
+ warn(msg: string, options?: LogOptions): void;
1562
+ warnOnce(msg: string, options?: LogOptions): void;
1563
+ error(msg: string, options?: LogOptions): void;
1564
+ clearScreen(type: LogType): void;
1565
+ hasWarned: boolean;
1388
1566
  }
1389
1567
  interface LogOptions {
1390
- clear?: boolean;
1391
- timestamp?: boolean;
1568
+ clear?: boolean;
1569
+ timestamp?: boolean;
1392
1570
  }
1393
1571
  declare const LogLevels: Record<LogLevel, number>;
1394
1572
  interface LoggerOptions {
1395
- prefix?: string;
1396
- allowClearScreen?: boolean;
1573
+ prefix?: string;
1574
+ allowClearScreen?: boolean;
1397
1575
  }
1398
1576
  declare function createLogger(level?: LogLevel, options?: LoggerOptions): Logger;
1399
-
1400
- declare const getFileInfo: (target?: string, { backupFilename, extension, }?: {
1401
- backupFilename?: string;
1402
- extension?: string;
1577
+ //#endregion
1578
+ //#region src/utils/file.d.ts
1579
+ declare const getFileInfo: (target?: string, {
1580
+ backupFilename,
1581
+ extension
1582
+ }?: {
1583
+ backupFilename?: string;
1584
+ extension?: string;
1403
1585
  }) => {
1404
- path: string;
1405
- pathWithoutExtension: string;
1406
- extension: string;
1407
- isDirectory: boolean;
1408
- dirname: string;
1409
- filename: string;
1586
+ path: string;
1587
+ pathWithoutExtension: string;
1588
+ extension: string;
1589
+ isDirectory: boolean;
1590
+ dirname: string;
1591
+ filename: string;
1410
1592
  };
1411
1593
  declare function loadFile<File = any>(filePath?: string, options?: {
1412
- root?: string;
1413
- defaultFileName?: string;
1414
- logLevel?: LogLevel;
1415
- isDefault?: boolean;
1416
- alias?: Record<string, string>;
1417
- tsconfig?: Tsconfig;
1418
- load?: boolean;
1594
+ root?: string;
1595
+ defaultFileName?: string;
1596
+ logLevel?: LogLevel;
1597
+ isDefault?: boolean;
1598
+ alias?: Record<string, string>;
1599
+ tsconfig?: Tsconfig;
1600
+ load?: boolean;
1419
1601
  }): Promise<{
1420
- path: string;
1421
- file?: File;
1422
- error?: any;
1423
- cached?: boolean;
1602
+ path: string;
1603
+ file?: File;
1604
+ error?: any;
1605
+ cached?: boolean;
1424
1606
  }>;
1425
- declare function removeFiles(patterns: string[], dir: string): Promise<void>;
1426
-
1607
+ declare function removeFilesAndEmptyFolders(patterns: string[], dir: string): Promise<void>;
1608
+ //#endregion
1609
+ //#region src/utils/file-extensions.d.ts
1427
1610
  declare const getMockFileExtensionByTypeName: (mock: GlobalMockOptions | ClientMockBuilder) => string;
1428
-
1611
+ //#endregion
1612
+ //#region src/utils/is-body-verb.d.ts
1613
+ declare const getIsBodyVerb: (verb: Verbs) => boolean;
1614
+ //#endregion
1615
+ //#region src/utils/merge-deep.d.ts
1429
1616
  declare function mergeDeep<T extends Record<string, any>, U extends Record<string, any>>(source: T, target: U): T & U;
1430
-
1617
+ //#endregion
1618
+ //#region src/utils/occurrence.d.ts
1431
1619
  declare const count: (str: string | undefined, key: string) => number;
1432
-
1433
- declare const openApiConverter: (schema: any, options: swagger2openapi.Options | undefined, specKey: string) => Promise<OpenAPIObject>;
1434
-
1435
- declare const join: (...paths: string[]) => string;
1436
- declare const resolve: (...paths: string[]) => string;
1437
- declare const extname: (path: string) => string;
1438
- declare const dirname: (path: string) => string;
1439
- declare const basename: (path: string, suffix?: string) => string;
1440
- declare const isAbsolute: (path: string) => boolean;
1441
-
1620
+ //#endregion
1621
+ //#region src/utils/open-api-converter.d.ts
1622
+ declare const openApiConverter: (schema: any, options: Partial<ConvertInputOptions> | undefined, specKey: string) => Promise<OpenAPIObject>;
1623
+ declare namespace path_d_exports {
1624
+ export { basename, dirname, extname, getSchemaFileName, getSpecName, isAbsolute, join, joinSafe, normalizeSafe, relativeSafe, resolve, separator$1 as separator };
1625
+ }
1626
+ declare const join: (...paths: string[]) => string, resolve: (...paths: string[]) => string, extname: (path: string) => string, dirname: (path: string) => string, basename: (path: string, suffix?: string) => string, isAbsolute: (path: string) => boolean;
1442
1627
  /**
1443
1628
  * Behaves exactly like `path.relative(from, to)`, but keeps the first meaningful "./"
1444
1629
  */
1445
1630
  declare const relativeSafe: (from: string, to: string) => string;
1446
1631
  declare const getSpecName: (specKey: string, target: string) => string;
1447
1632
  declare const getSchemaFileName: (path: string) => string;
1448
- declare const separator = "/";
1633
+ declare const separator$1 = "/";
1449
1634
  declare const normalizeSafe: (value: string) => string;
1450
1635
  declare const joinSafe: (...values: string[]) => string;
1451
-
1452
- declare const path_basename: typeof basename;
1453
- declare const path_dirname: typeof dirname;
1454
- declare const path_extname: typeof extname;
1455
- declare const path_getSchemaFileName: typeof getSchemaFileName;
1456
- declare const path_getSpecName: typeof getSpecName;
1457
- declare const path_isAbsolute: typeof isAbsolute;
1458
- declare const path_join: typeof join;
1459
- declare const path_joinSafe: typeof joinSafe;
1460
- declare const path_normalizeSafe: typeof normalizeSafe;
1461
- declare const path_relativeSafe: typeof relativeSafe;
1462
- declare const path_resolve: typeof resolve;
1463
- declare const path_separator: typeof separator;
1464
- declare namespace path {
1465
- export { path_basename as basename, path_dirname as dirname, path_extname as extname, path_getSchemaFileName as getSchemaFileName, path_getSpecName as getSpecName, path_isAbsolute as isAbsolute, path_join as join, path_joinSafe as joinSafe, path_normalizeSafe as normalizeSafe, path_relativeSafe as relativeSafe, path_resolve as resolve, path_separator as separator };
1466
- }
1467
-
1636
+ //#endregion
1637
+ //#region src/utils/sort.d.ts
1468
1638
  declare const sortByPriority: <T>(arr: (T & {
1469
- default?: boolean;
1470
- required?: boolean;
1639
+ default?: boolean;
1640
+ required?: boolean;
1471
1641
  })[]) => (T & {
1472
- default?: boolean;
1473
- required?: boolean;
1642
+ default?: boolean;
1643
+ required?: boolean;
1474
1644
  })[];
1475
-
1476
- declare const stringify: (data?: string | any[] | {
1477
- [key: string]: any;
1478
- }) => string | undefined;
1645
+ //#endregion
1646
+ //#region src/utils/string.d.ts
1647
+ declare const stringify: (data?: string | any[] | Record<string, any>) => string | undefined;
1479
1648
  declare const sanitize: (value: string, options?: {
1480
- whitespace?: string | true;
1481
- underscore?: string | true;
1482
- dot?: string | true;
1483
- dash?: string | true;
1484
- es5keyword?: boolean;
1485
- es5IdentifierName?: boolean;
1486
- special?: boolean;
1649
+ whitespace?: string | true;
1650
+ underscore?: string | true;
1651
+ dot?: string | true;
1652
+ dash?: string | true;
1653
+ es5keyword?: boolean;
1654
+ es5IdentifierName?: boolean;
1655
+ special?: boolean;
1487
1656
  }) => string;
1488
1657
  declare const toObjectString: <T>(props: T[], path?: keyof T) => string;
1489
1658
  declare const getNumberWord: (num: number) => string;
@@ -1498,57 +1667,111 @@ declare const escape: (str: string | null, char?: string) => string | undefined;
1498
1667
  * @param input String to escape
1499
1668
  */
1500
1669
  declare const jsStringEscape: (input: string) => string;
1501
-
1670
+ //#endregion
1671
+ //#region src/utils/tsconfig.d.ts
1502
1672
  declare const isSyntheticDefaultImportsAllow: (config?: Tsconfig) => boolean;
1503
-
1673
+ //#endregion
1674
+ //#region src/utils/validator.d.ts
1504
1675
  /**
1505
1676
  * Validate the spec with ibm-openapi-validator (with a custom pretty logger).
1506
1677
  * More information: https://github.com/IBM/openapi-validator/#configuration
1507
1678
  * @param specs openAPI spec
1508
1679
  */
1509
1680
  declare const ibmOpenapiValidator: (specs: OpenAPIObject, validation: boolean | object) => Promise<void>;
1510
-
1511
- declare const getIsBodyVerb: (verb: Verbs) => boolean;
1512
-
1681
+ //#endregion
1682
+ //#region src/writers/schemas.d.ts
1513
1683
  declare const writeModelInline: (acc: string, model: string) => string;
1514
1684
  declare const writeModelsInline: (array: GeneratorSchema[]) => string;
1515
- declare const writeSchema: ({ path, schema, target, namingConvention, fileExtension, specKey, isRootKey, specsName, header, }: {
1516
- path: string;
1517
- schema: GeneratorSchema;
1518
- target: string;
1519
- namingConvention: NamingConvention;
1520
- fileExtension: string;
1521
- specKey: string;
1522
- isRootKey: boolean;
1523
- specsName: Record<string, string>;
1524
- header: string;
1685
+ declare const writeSchema: ({
1686
+ path,
1687
+ schema,
1688
+ target,
1689
+ namingConvention,
1690
+ fileExtension,
1691
+ specKey,
1692
+ isRootKey,
1693
+ specsName,
1694
+ header
1695
+ }: {
1696
+ path: string;
1697
+ schema: GeneratorSchema;
1698
+ target: string;
1699
+ namingConvention: NamingConvention;
1700
+ fileExtension: string;
1701
+ specKey: string;
1702
+ isRootKey: boolean;
1703
+ specsName: Record<string, string>;
1704
+ header: string;
1525
1705
  }) => Promise<void>;
1526
- declare const writeSchemas: ({ schemaPath, schemas, target, namingConvention, fileExtension, specKey, isRootKey, specsName, header, indexFiles, }: {
1527
- schemaPath: string;
1528
- schemas: GeneratorSchema[];
1529
- target: string;
1530
- namingConvention: NamingConvention;
1531
- fileExtension: string;
1532
- specKey: string;
1533
- isRootKey: boolean;
1534
- specsName: Record<string, string>;
1535
- header: string;
1536
- indexFiles: boolean;
1706
+ declare const writeSchemas: ({
1707
+ schemaPath,
1708
+ schemas,
1709
+ target,
1710
+ namingConvention,
1711
+ fileExtension,
1712
+ specKey,
1713
+ isRootKey,
1714
+ specsName,
1715
+ header,
1716
+ indexFiles
1717
+ }: {
1718
+ schemaPath: string;
1719
+ schemas: GeneratorSchema[];
1720
+ target: string;
1721
+ namingConvention: NamingConvention;
1722
+ fileExtension: string;
1723
+ specKey: string;
1724
+ isRootKey: boolean;
1725
+ specsName: Record<string, string>;
1726
+ header: string;
1727
+ indexFiles: boolean;
1537
1728
  }) => Promise<void>;
1538
-
1539
- declare const getOrvalGeneratedTypes: () => string;
1540
- declare const getTypedResponse: () => string;
1541
-
1542
- declare const writeSingleMode: ({ builder, output, specsName, header, needSchema, }: WriteModeProps) => Promise<string[]>;
1543
-
1544
- declare const writeSplitMode: ({ builder, output, specsName, header, needSchema, }: WriteModeProps) => Promise<string[]>;
1545
-
1546
- declare const writeSplitTagsMode: ({ builder, output, specsName, header, needSchema, }: WriteModeProps) => Promise<string[]>;
1547
-
1548
- declare const writeTagsMode: ({ builder, output, specsName, header, needSchema, }: WriteModeProps) => Promise<string[]>;
1549
-
1729
+ //#endregion
1730
+ //#region src/writers/single-mode.d.ts
1731
+ declare const writeSingleMode: ({
1732
+ builder,
1733
+ output,
1734
+ specsName,
1735
+ header,
1736
+ needSchema
1737
+ }: WriteModeProps) => Promise<string[]>;
1738
+ //#endregion
1739
+ //#region src/writers/split-mode.d.ts
1740
+ declare const writeSplitMode: ({
1741
+ builder,
1742
+ output,
1743
+ specsName,
1744
+ header,
1745
+ needSchema
1746
+ }: WriteModeProps) => Promise<string[]>;
1747
+ //#endregion
1748
+ //#region src/writers/split-tags-mode.d.ts
1749
+ declare const writeSplitTagsMode: ({
1750
+ builder,
1751
+ output,
1752
+ specsName,
1753
+ header,
1754
+ needSchema
1755
+ }: WriteModeProps) => Promise<string[]>;
1756
+ //#endregion
1757
+ //#region src/writers/tags-mode.d.ts
1758
+ declare const writeTagsMode: ({
1759
+ builder,
1760
+ output,
1761
+ specsName,
1762
+ header,
1763
+ needSchema
1764
+ }: WriteModeProps) => Promise<string[]>;
1765
+ //#endregion
1766
+ //#region src/writers/target.d.ts
1550
1767
  declare const generateTarget: (builder: WriteSpecsBuilder, options: NormalizedOutputOptions) => GeneratorTarget;
1551
-
1768
+ //#endregion
1769
+ //#region src/writers/target-tags.d.ts
1552
1770
  declare const generateTargetForTags: (builder: WriteSpecsBuilder, options: NormalizedOutputOptions) => Record<string, GeneratorTarget>;
1553
-
1554
- export { type AngularOptions, BODY_TYPE_NAME, type BaseUrlFromConstant, type BaseUrlFromSpec, type ClientBuilder, type ClientDependenciesBuilder, type ClientExtraFilesBuilder, type ClientFileBuilder, type ClientFooterBuilder, type ClientGeneratorsBuilder, type ClientHeaderBuilder, type ClientMockBuilder, type ClientMockGeneratorBuilder, type ClientMockGeneratorImplementation, type ClientTitleBuilder, type Config, type ConfigExternal, type ConfigFn, type ContextSpecs, EnumGeneration, type FetchOptions, FormDataArrayHandling, type FormDataType, type GenerateMockImports, type GeneratorApiBuilder, type GeneratorApiOperations, type GeneratorApiResponse, type GeneratorClient, type GeneratorClientExtra, type GeneratorClientFooter, type GeneratorClientHeader, type GeneratorClientImports, type GeneratorClientTitle, type GeneratorClients, type GeneratorDependency, type GeneratorImport, type GeneratorMutator, type GeneratorMutatorParsingInfo, type GeneratorOperation, type GeneratorOperations, type GeneratorOptions, type GeneratorSchema, type GeneratorTarget, type GeneratorTargetFull, type GeneratorVerbOptions, type GeneratorVerbsOptions, type GetterBody, type GetterParam, type GetterParameters, type GetterParams, type GetterProp, GetterPropType, type GetterProps, type GetterQueryParam, type GetterResponse, type GlobalMockOptions, type GlobalOptions, type HonoOptions, type Hook, type HookCommand, type HookFunction, type HookOption, type HooksOptions, type ImportOpenApi, type InputFiltersOption, type InputOptions, type InputTransformerFn, type JsDocOptions, type LogLevel, LogLevels, type LogOptions, type LogType, type Logger, type LoggerOptions, type MockData, type MockDataArray, type MockDataArrayFn, type MockDataObject, type MockDataObjectFn, type MockOptions, type MockProperties, type MockPropertiesObject, type MockPropertiesObjectFn, type Mutator, type MutatorObject, NamingConvention, type NormalizedConfig, type NormalizedFormDataType, type NormalizedHonoOptions, type NormalizedHookCommand, type NormalizedHookOptions, type NormalizedInputOptions, type NormalizedJsDocOptions, type NormalizedMutator, type NormalizedOperationOptions, type NormalizedOptions, type NormalizedOutputOptions, type NormalizedOverrideOutput, type NormalizedParamsSerializerOptions, type NormalizedQueryOptions, type NormalizedZodOptions, type OperationOptions, type Options, type OptionsExport, type OptionsFn, OutputClient, type OutputClientFunc, type OutputDocsOptions, OutputHttpClient, OutputMockType, OutputMode, type OutputOptions, type OverrideInput, type OverrideMockOptions, type OverrideOutput, type OverrideOutputContentType, type PackageJson, type ParamsSerializerOptions, PropertySortOrder, type QueryOptions, RefComponentSuffix, type RefInfo, type ResReqTypesValue, type ResolverValue, type ScalarValue, SchemaType, type SchemaWithConst, type SwaggerParserOptions, type SwrOptions, TEMPLATE_TAG_REGEX, type TsConfigTarget, type Tsconfig, URL_REGEX, VERBS_WITH_BODY, Verbs, type WriteModeProps, type WriteSpecsBuilder, type ZodCoerceType, type ZodDateTimeOptions, type ZodOptions, type ZodTimeOptions, _filteredVerbs, addDependency, asyncReduce, camel, combineSchemas, compareVersions, conventionName, count, createDebugger, createLogger, createSuccessMessage, dynamicImport, escape, generalJSTypes, generalJSTypesWithArray, generateAxiosOptions, generateBodyMutatorConfig, generateBodyOptions, generateComponentDefinition, generateDependencyImports, generateFormDataAndUrlEncodedFunction, generateImports, generateModelInline, generateModelsInline, generateMutator, generateMutatorConfig, generateMutatorImports, generateMutatorRequestOptions, generateOptions, generateParameterDefinition, generateQueryParamsAxiosConfig, generateSchemasDefinition, generateTarget, generateTargetForTags, generateVerbImports, generateVerbsOptions, getArray, getBody, getEnum, getEnumDescriptions, getEnumImplementation, getEnumNames, getExtension, getFileInfo, getFullRoute, getIsBodyVerb, getKey, getMockFileExtensionByTypeName, getNumberWord, getObject, getOperationId, getOrvalGeneratedTypes, getParameters, getParams, getParamsInPath, getProps, getQueryParams, getRefInfo, getResReqTypes, getResponse, getRoute, getRouteAsArray, getScalar, getTypedResponse, ibmOpenapiValidator, ibmOpenapiValidatorErrors, ibmOpenapiValidatorWarnings, isBoolean, isDirectory, isFunction, isModule, isNull, isNumber, isNumeric, isObject, isReference, isRootKey, isSchema, isString, isSyntheticDefaultImportsAllow, isUndefined, isUrl, isVerb, jsDoc, jsStringEscape, kebab, keyValuePairsToJsDoc, loadFile, log, logError, mergeDeep, mismatchArgsMessage, openApiConverter, pascal, removeFiles, resolveDiscriminators, resolveExampleRefs, resolveObject, resolveRef, resolveValue, sanitize, snake, sortByPriority, startMessage, stringify, toObjectString, path as upath, upper, writeModelInline, writeModelsInline, writeSchema, writeSchemas, writeSingleMode, writeSplitMode, writeSplitTagsMode, writeTagsMode };
1771
+ //#endregion
1772
+ //#region src/writers/types.d.ts
1773
+ declare const getOrvalGeneratedTypes: () => string;
1774
+ declare const getTypedResponse: () => string;
1775
+ //#endregion
1776
+ export { AngularOptions, BODY_TYPE_NAME, BaseUrlFromConstant, BaseUrlFromSpec, ClientBuilder, ClientDependenciesBuilder, ClientExtraFilesBuilder, ClientFileBuilder, ClientFooterBuilder, ClientGeneratorsBuilder, ClientHeaderBuilder, ClientMockBuilder, ClientMockGeneratorBuilder, ClientMockGeneratorImplementation, ClientTitleBuilder, Config, ConfigExternal, ConfigFn, ContextSpecs, DeepNonNullable, EnumGeneration, ErrorWithTag, FetchOptions, FormDataArrayHandling, FormDataType, GenerateMockImports, GeneratorApiBuilder, GeneratorApiOperations, GeneratorApiResponse, GeneratorClient, GeneratorClientExtra, GeneratorClientFooter, GeneratorClientHeader, GeneratorClientImports, GeneratorClientTitle, GeneratorClients, GeneratorDependency, GeneratorImport, GeneratorMutator, GeneratorMutatorParsingInfo, GeneratorOperation, GeneratorOperations, GeneratorOptions, GeneratorSchema, GeneratorTarget, GeneratorTargetFull, GeneratorVerbOptions, GeneratorVerbsOptions, GetterBody, GetterParam, GetterParameters, GetterParams, GetterProp, GetterPropType, GetterProps, GetterQueryParam, GetterResponse, GlobalMockOptions, GlobalOptions, HonoOptions, Hook, HookCommand, HookFunction, HookOption, HooksOptions, ImportOpenApi, InputFiltersOption, InputOptions, InputTransformerFn, JsDocOptions, LogLevel, LogLevels, LogOptions, LogType, Logger, LoggerOptions, MockData, MockDataArray, MockDataArrayFn, MockDataObject, MockDataObjectFn, MockOptions, MockProperties, MockPropertiesObject, MockPropertiesObjectFn, Mutator, MutatorObject, NamingConvention, NormalizedConfig, NormalizedFetchOptions, NormalizedFormDataType, NormalizedHonoOptions, NormalizedHookCommand, NormalizedHookOptions, NormalizedInputOptions, NormalizedJsDocOptions, NormalizedMutator, NormalizedOperationOptions, NormalizedOptions, NormalizedOutputOptions, NormalizedOverrideOutput, NormalizedParamsSerializerOptions, NormalizedQueryOptions, NormalizedZodOptions, OperationOptions, Options, OptionsExport, OptionsFn, OutputClient, OutputClientFunc, OutputDocsOptions, OutputHttpClient, OutputMockType, OutputMode, OutputOptions, OverrideInput, OverrideMockOptions, OverrideOutput, OverrideOutputContentType, PackageJson, ParamsSerializerOptions, PropertySortOrder, QueryOptions, RefComponentSuffix, RefInfo, ResReqTypesValue, ResolverValue, ScalarValue, SchemaType, SchemaWithConst, SwaggerParserOptions, SwrOptions, TEMPLATE_TAG_REGEX, TsConfigTarget, Tsconfig, URL_REGEX, VERBS_WITH_BODY, Verbs, WriteModeProps, WriteSpecsBuilder, ZodCoerceType, ZodDateTimeOptions, ZodOptions, ZodTimeOptions, _filteredVerbs, addDependency, asyncReduce, camel, combineSchemas, compareVersions, conventionName, count, createDebugger, createLogger, createSuccessMessage, dynamicImport, escape, generalJSTypes, generalJSTypesWithArray, generateAxiosOptions, generateBodyMutatorConfig, generateBodyOptions, generateComponentDefinition, generateDependencyImports, generateFormDataAndUrlEncodedFunction, generateImports, generateModelInline, generateModelsInline, generateMutator, generateMutatorConfig, generateMutatorImports, generateMutatorRequestOptions, generateOptions, generateParameterDefinition, generateQueryParamsAxiosConfig, generateSchemasDefinition, generateTarget, generateTargetForTags, generateVerbImports, generateVerbsOptions, getArray, getBody, getEnum, getEnumDescriptions, getEnumImplementation, getEnumNames, getExtension, getFileInfo, getFullRoute, getIsBodyVerb, getKey, getMockFileExtensionByTypeName, getNumberWord, getObject, getOperationId, getOrvalGeneratedTypes, getParameters, getParams, getParamsInPath, getProps, getQueryParams, getRefInfo, getResReqTypes, getResponse, getRoute, getRouteAsArray, getScalar, getTypedResponse, ibmOpenapiValidator, ibmOpenapiValidatorErrors, ibmOpenapiValidatorWarnings, isBoolean, isDirectory, isFunction, isModule, isNull, isNumber, isNumeric, isObject, isReference, isRootKey$1 as isRootKey, isSchema, isString, isSyntheticDefaultImportsAllow, isUndefined, isUrl, isVerb, jsDoc, jsStringEscape, kebab, keyValuePairsToJsDoc, loadFile, log, logError, mergeDeep, mismatchArgsMessage, openApiConverter, pascal, removeFilesAndEmptyFolders, resolveDiscriminators, resolveExampleRefs, resolveObject, resolveRef, resolveValue, sanitize, snake, sortByPriority, startMessage, stringify, toObjectString, path_d_exports as upath, upper, writeModelInline, writeModelsInline, writeSchema, writeSchemas, writeSingleMode, writeSplitMode, writeSplitTagsMode, writeTagsMode };
1777
+ //# sourceMappingURL=index.d.ts.map