@nestia/sdk 1.2.5 → 1.2.6-dev.20230512-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/lib/INestiaConfig.d.ts +10 -0
- package/lib/executable/internal/NestiaSdkConfig.js +105 -69
- package/lib/executable/internal/NestiaSdkConfig.js.map +1 -1
- package/lib/generates/SwaggerGenerator.js +1922 -24
- package/lib/generates/SwaggerGenerator.js.map +1 -1
- package/lib/structures/ISwaggerDocument.d.ts +2 -1
- package/lib/utils/FileRetriever.d.ts +4 -0
- package/lib/utils/FileRetriever.js +28 -0
- package/lib/utils/FileRetriever.js.map +1 -0
- package/package.json +1 -1
- package/src/INestiaConfig.ts +12 -0
- package/src/generates/SwaggerGenerator.ts +83 -24
- package/src/structures/ISwaggerDocument.ts +2 -1
- package/src/utils/FileRetriever.ts +22 -0
package/lib/INestiaConfig.d.ts
CHANGED
|
@@ -136,6 +136,16 @@ export declare namespace INestiaConfig {
|
|
|
136
136
|
* `swagger.json` file would be renamed to it.
|
|
137
137
|
*/
|
|
138
138
|
output: string;
|
|
139
|
+
/**
|
|
140
|
+
* API information.
|
|
141
|
+
*
|
|
142
|
+
* If omitted, `package.json` content would be used instead.
|
|
143
|
+
*/
|
|
144
|
+
info?: Partial<ISwaggerDocument.IInfo>;
|
|
145
|
+
/**
|
|
146
|
+
* List of server addresses.
|
|
147
|
+
*/
|
|
148
|
+
servers?: ISwaggerDocument.IServer[];
|
|
139
149
|
/**
|
|
140
150
|
* Security schemes.
|
|
141
151
|
*/
|
|
@@ -68,9 +68,11 @@ var NestiaSdkConfig;
|
|
|
68
68
|
const $join = typia_1.assert.join;
|
|
69
69
|
const $is_custom = typia_1.assert.is_custom;
|
|
70
70
|
const __is = input => {
|
|
71
|
-
const $io0 = input => (undefined === input.swagger || "object" === typeof input.swagger && null !== input.swagger && $io1(input.swagger)) && (null !== input.input && undefined !== input.input && ("string" === typeof input.input || (Array.isArray(input.input) && input.input.every(elem => "string" === typeof elem) || "object" === typeof input.input && null !== input.input && $
|
|
72
|
-
const $io1 = input => "string" === typeof input.output && (undefined === input.security || "object" === typeof input.security && null !== input.security && false === Array.isArray(input.security) && $
|
|
73
|
-
const $io2 = input =>
|
|
71
|
+
const $io0 = input => (undefined === input.swagger || "object" === typeof input.swagger && null !== input.swagger && $io1(input.swagger)) && (null !== input.input && undefined !== input.input && ("string" === typeof input.input || (Array.isArray(input.input) && input.input.every(elem => "string" === typeof elem) || "object" === typeof input.input && null !== input.input && $io15(input.input)))) && (undefined === input.output || "string" === typeof input.output) && (undefined === input.distribute || "string" === typeof input.distribute) && (undefined === input.e2e || "string" === typeof input.e2e) && (undefined === input.compilerOptions || "object" === typeof input.compilerOptions && null !== input.compilerOptions && false === Array.isArray(input.compilerOptions) && $io16(input.compilerOptions)) && (undefined === input.assert || "boolean" === typeof input.assert) && (undefined === input.json || "boolean" === typeof input.json) && (undefined === input.primitive || "boolean" === typeof input.primitive);
|
|
72
|
+
const $io1 = input => "string" === typeof input.output && (undefined === input.info || "object" === typeof input.info && null !== input.info && false === Array.isArray(input.info) && $io2(input.info)) && (undefined === input.servers || Array.isArray(input.servers) && input.servers.every(elem => "object" === typeof elem && null !== elem && $io3(elem))) && (undefined === input.security || "object" === typeof input.security && null !== input.security && false === Array.isArray(input.security) && $io4(input.security));
|
|
73
|
+
const $io2 = input => (undefined === input.version || "string" === typeof input.version) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description);
|
|
74
|
+
const $io3 = input => "string" === typeof input.url && (undefined === input.description || "string" === typeof input.description);
|
|
75
|
+
const $io4 = input => Object.keys(input).every(key => {
|
|
74
76
|
const value = input[key];
|
|
75
77
|
if (undefined === value)
|
|
76
78
|
return true;
|
|
@@ -78,13 +80,13 @@ var NestiaSdkConfig;
|
|
|
78
80
|
return "object" === typeof value && null !== value && $iu0(value);
|
|
79
81
|
return true;
|
|
80
82
|
});
|
|
81
|
-
const $
|
|
82
|
-
const $
|
|
83
|
-
const $
|
|
84
|
-
const $
|
|
85
|
-
const $
|
|
86
|
-
const $
|
|
87
|
-
const $
|
|
83
|
+
const $io5 = input => "http" === input.type && "basic" === input.schema;
|
|
84
|
+
const $io6 = input => "http" === input.type && "bearer" === input.scheme && (undefined === input.bearerFormat || "string" === typeof input.bearerFormat);
|
|
85
|
+
const $io7 = input => "openIdConnect" === input.type && "string" === typeof input.openIdConnectUrl;
|
|
86
|
+
const $io8 = input => "oauth2" === input.type && ("object" === typeof input.flows && null !== input.flows && false === Array.isArray(input.flows) && $io9(input.flows)) && (undefined === input.description || "string" === typeof input.description);
|
|
87
|
+
const $io9 = input => (undefined === input.authorizationCode || "object" === typeof input.authorizationCode && null !== input.authorizationCode && $io10(input.authorizationCode)) && (undefined === input.implicit || "object" === typeof input.implicit && null !== input.implicit && $io12(input.implicit)) && (undefined === input.password || "object" === typeof input.password && null !== input.password && $io13(input.password)) && (undefined === input.clientCredentials || "object" === typeof input.clientCredentials && null !== input.clientCredentials && $io13(input.clientCredentials));
|
|
88
|
+
const $io10 = input => "string" === typeof input.authorizationUrl && "string" === typeof input.tokenUrl && "string" === typeof input.refreshUrl && (undefined === input.scopes || "object" === typeof input.scopes && null !== input.scopes && false === Array.isArray(input.scopes) && $io11(input.scopes));
|
|
89
|
+
const $io11 = input => Object.keys(input).every(key => {
|
|
88
90
|
const value = input[key];
|
|
89
91
|
if (undefined === value)
|
|
90
92
|
return true;
|
|
@@ -92,11 +94,11 @@ var NestiaSdkConfig;
|
|
|
92
94
|
return "string" === typeof value;
|
|
93
95
|
return true;
|
|
94
96
|
});
|
|
95
|
-
const $
|
|
96
|
-
const $
|
|
97
|
-
const $
|
|
98
|
-
const $
|
|
99
|
-
const $
|
|
97
|
+
const $io12 = input => "string" === typeof input.authorizationUrl && "string" === typeof input.refreshUrl && (undefined === input.scopes || "object" === typeof input.scopes && null !== input.scopes && false === Array.isArray(input.scopes) && $io11(input.scopes));
|
|
98
|
+
const $io13 = input => "string" === typeof input.tokenUrl && "string" === typeof input.refreshUrl && (undefined === input.scopes || "object" === typeof input.scopes && null !== input.scopes && false === Array.isArray(input.scopes) && $io11(input.scopes));
|
|
99
|
+
const $io14 = input => "apiKey" === input.type && (undefined === input["in"] || "header" === input["in"] || "query" === input["in"] || "cookie" === input["in"]) && (undefined === input.name || "string" === typeof input.name && $is_custom("default", "string", "Authorization", input.name));
|
|
100
|
+
const $io15 = input => Array.isArray(input.include) && input.include.every(elem => "string" === typeof elem) && (undefined === input.exclude || Array.isArray(input.exclude) && input.exclude.every(elem => "string" === typeof elem));
|
|
101
|
+
const $io16 = input => (undefined === input.allowJs || "boolean" === typeof input.allowJs) && (undefined === input.allowSyntheticDefaultImports || "boolean" === typeof input.allowSyntheticDefaultImports) && (undefined === input.allowUmdGlobalAccess || "boolean" === typeof input.allowUmdGlobalAccess) && (undefined === input.allowUnreachableCode || "boolean" === typeof input.allowUnreachableCode) && (undefined === input.allowUnusedLabels || "boolean" === typeof input.allowUnusedLabels) && (undefined === input.alwaysStrict || "boolean" === typeof input.alwaysStrict) && (undefined === input.baseUrl || "string" === typeof input.baseUrl) && (undefined === input.charset || "string" === typeof input.charset) && (undefined === input.checkJs || "boolean" === typeof input.checkJs) && (undefined === input.declaration || "boolean" === typeof input.declaration) && (undefined === input.declarationMap || "boolean" === typeof input.declarationMap) && (undefined === input.emitDeclarationOnly || "boolean" === typeof input.emitDeclarationOnly) && (undefined === input.declarationDir || "string" === typeof input.declarationDir) && (undefined === input.disableSizeLimit || "boolean" === typeof input.disableSizeLimit) && (undefined === input.disableSourceOfProjectReferenceRedirect || "boolean" === typeof input.disableSourceOfProjectReferenceRedirect) && (undefined === input.disableSolutionSearching || "boolean" === typeof input.disableSolutionSearching) && (undefined === input.disableReferencedProjectLoad || "boolean" === typeof input.disableReferencedProjectLoad) && (undefined === input.downlevelIteration || "boolean" === typeof input.downlevelIteration) && (undefined === input.emitBOM || "boolean" === typeof input.emitBOM) && (undefined === input.emitDecoratorMetadata || "boolean" === typeof input.emitDecoratorMetadata) && (undefined === input.exactOptionalPropertyTypes || "boolean" === typeof input.exactOptionalPropertyTypes) && (undefined === input.experimentalDecorators || "boolean" === typeof input.experimentalDecorators) && (undefined === input.forceConsistentCasingInFileNames || "boolean" === typeof input.forceConsistentCasingInFileNames) && (undefined === input.importHelpers || "boolean" === typeof input.importHelpers) && true && (undefined === input.inlineSourceMap || "boolean" === typeof input.inlineSourceMap) && (undefined === input.inlineSources || "boolean" === typeof input.inlineSources) && (undefined === input.isolatedModules || "boolean" === typeof input.isolatedModules) && true && (undefined === input.keyofStringsOnly || "boolean" === typeof input.keyofStringsOnly) && (undefined === input.lib || Array.isArray(input.lib) && input.lib.every(elem => "string" === typeof elem)) && (undefined === input.locale || "string" === typeof input.locale) && (undefined === input.mapRoot || "string" === typeof input.mapRoot) && true && true && true && (undefined === input.moduleSuffixes || Array.isArray(input.moduleSuffixes) && input.moduleSuffixes.every(elem => "string" === typeof elem)) && true && true && (undefined === input.noEmit || "boolean" === typeof input.noEmit) && (undefined === input.noEmitHelpers || "boolean" === typeof input.noEmitHelpers) && (undefined === input.noEmitOnError || "boolean" === typeof input.noEmitOnError) && (undefined === input.noErrorTruncation || "boolean" === typeof input.noErrorTruncation) && (undefined === input.noFallthroughCasesInSwitch || "boolean" === typeof input.noFallthroughCasesInSwitch) && (undefined === input.noImplicitAny || "boolean" === typeof input.noImplicitAny) && (undefined === input.noImplicitReturns || "boolean" === typeof input.noImplicitReturns) && (undefined === input.noImplicitThis || "boolean" === typeof input.noImplicitThis) && (undefined === input.noStrictGenericChecks || "boolean" === typeof input.noStrictGenericChecks) && (undefined === input.noUnusedLocals || "boolean" === typeof input.noUnusedLocals) && (undefined === input.noUnusedParameters || "boolean" === typeof input.noUnusedParameters) && (undefined === input.noImplicitUseStrict || "boolean" === typeof input.noImplicitUseStrict) && (undefined === input.noPropertyAccessFromIndexSignature || "boolean" === typeof input.noPropertyAccessFromIndexSignature) && (undefined === input.assumeChangesOnlyAffectDirectDependencies || "boolean" === typeof input.assumeChangesOnlyAffectDirectDependencies) && (undefined === input.noLib || "boolean" === typeof input.noLib) && (undefined === input.noResolve || "boolean" === typeof input.noResolve) && (undefined === input.noUncheckedIndexedAccess || "boolean" === typeof input.noUncheckedIndexedAccess) && (undefined === input.out || "string" === typeof input.out) && (undefined === input.outDir || "string" === typeof input.outDir) && (undefined === input.outFile || "string" === typeof input.outFile) && (undefined === input.paths || "object" === typeof input.paths && null !== input.paths && false === Array.isArray(input.paths) && $io17(input.paths)) && (undefined === input.preserveConstEnums || "boolean" === typeof input.preserveConstEnums) && (undefined === input.noImplicitOverride || "boolean" === typeof input.noImplicitOverride) && (undefined === input.preserveSymlinks || "boolean" === typeof input.preserveSymlinks) && (undefined === input.preserveValueImports || "boolean" === typeof input.preserveValueImports) && (undefined === input.project || "string" === typeof input.project) && (undefined === input.reactNamespace || "string" === typeof input.reactNamespace) && (undefined === input.jsxFactory || "string" === typeof input.jsxFactory) && (undefined === input.jsxFragmentFactory || "string" === typeof input.jsxFragmentFactory) && (undefined === input.jsxImportSource || "string" === typeof input.jsxImportSource) && (undefined === input.composite || "boolean" === typeof input.composite) && (undefined === input.incremental || "boolean" === typeof input.incremental) && (undefined === input.tsBuildInfoFile || "string" === typeof input.tsBuildInfoFile) && (undefined === input.removeComments || "boolean" === typeof input.removeComments) && (undefined === input.rootDir || "string" === typeof input.rootDir) && (undefined === input.rootDirs || Array.isArray(input.rootDirs) && input.rootDirs.every(elem => "string" === typeof elem)) && (undefined === input.skipLibCheck || "boolean" === typeof input.skipLibCheck) && (undefined === input.skipDefaultLibCheck || "boolean" === typeof input.skipDefaultLibCheck) && (undefined === input.sourceMap || "boolean" === typeof input.sourceMap) && (undefined === input.sourceRoot || "string" === typeof input.sourceRoot) && (undefined === input.strict || "boolean" === typeof input.strict) && (undefined === input.strictFunctionTypes || "boolean" === typeof input.strictFunctionTypes) && (undefined === input.strictBindCallApply || "boolean" === typeof input.strictBindCallApply) && (undefined === input.strictNullChecks || "boolean" === typeof input.strictNullChecks) && (undefined === input.strictPropertyInitialization || "boolean" === typeof input.strictPropertyInitialization) && (undefined === input.stripInternal || "boolean" === typeof input.stripInternal) && (undefined === input.suppressExcessPropertyErrors || "boolean" === typeof input.suppressExcessPropertyErrors) && (undefined === input.suppressImplicitAnyIndexErrors || "boolean" === typeof input.suppressImplicitAnyIndexErrors) && true && (undefined === input.traceResolution || "boolean" === typeof input.traceResolution) && (undefined === input.useUnknownInCatchVariables || "boolean" === typeof input.useUnknownInCatchVariables) && (undefined === input.resolveJsonModule || "boolean" === typeof input.resolveJsonModule) && (undefined === input.types || Array.isArray(input.types) && input.types.every(elem => "string" === typeof elem)) && (undefined === input.typeRoots || Array.isArray(input.typeRoots) && input.typeRoots.every(elem => "string" === typeof elem)) && (undefined === input.esModuleInterop || "boolean" === typeof input.esModuleInterop) && (undefined === input.useDefineForClassFields || "boolean" === typeof input.useDefineForClassFields) && Object.keys(input).every(key => {
|
|
100
102
|
const value = input[key];
|
|
101
103
|
if (undefined === value)
|
|
102
104
|
return true;
|
|
@@ -104,7 +106,7 @@ var NestiaSdkConfig;
|
|
|
104
106
|
return true;
|
|
105
107
|
return true;
|
|
106
108
|
});
|
|
107
|
-
const $
|
|
109
|
+
const $io17 = input => Object.keys(input).every(key => {
|
|
108
110
|
const value = input[key];
|
|
109
111
|
if (undefined === value)
|
|
110
112
|
return true;
|
|
@@ -114,15 +116,15 @@ var NestiaSdkConfig;
|
|
|
114
116
|
});
|
|
115
117
|
const $iu0 = input => (() => {
|
|
116
118
|
if (undefined !== input.schema)
|
|
117
|
-
return $
|
|
119
|
+
return $io5(input);
|
|
118
120
|
if (undefined !== input.scheme)
|
|
119
|
-
return $
|
|
121
|
+
return $io6(input);
|
|
120
122
|
if ("openIdConnect" === input.type)
|
|
121
|
-
return $
|
|
123
|
+
return $io7(input);
|
|
122
124
|
if ("oauth2" === input.type)
|
|
123
|
-
return $
|
|
125
|
+
return $io8(input);
|
|
124
126
|
if ("apiKey" === input.type)
|
|
125
|
-
return $
|
|
127
|
+
return $io14(input);
|
|
126
128
|
return false;
|
|
127
129
|
})();
|
|
128
130
|
return "object" === typeof input && null !== input && $io0(input);
|
|
@@ -145,7 +147,7 @@ var NestiaSdkConfig;
|
|
|
145
147
|
path: _path + ".input[" + _index1 + "]",
|
|
146
148
|
expected: "string",
|
|
147
149
|
value: elem
|
|
148
|
-
})) || "object" === typeof input.input && null !== input.input && $
|
|
150
|
+
})) || "object" === typeof input.input && null !== input.input && $ao15(input.input, _path + ".input", true && _exceptionable)))) && (undefined === input.output || "string" === typeof input.output || $guard(_exceptionable, {
|
|
149
151
|
path: _path + ".output",
|
|
150
152
|
expected: "(string | undefined)",
|
|
151
153
|
value: input.output
|
|
@@ -161,7 +163,7 @@ var NestiaSdkConfig;
|
|
|
161
163
|
path: _path + ".compilerOptions",
|
|
162
164
|
expected: "(StripEnums<ts.CompilerOptions> | undefined)",
|
|
163
165
|
value: input.compilerOptions
|
|
164
|
-
})) && $
|
|
166
|
+
})) && $ao16(input.compilerOptions, _path + ".compilerOptions", true && _exceptionable)) && (undefined === input.assert || "boolean" === typeof input.assert || $guard(_exceptionable, {
|
|
165
167
|
path: _path + ".assert",
|
|
166
168
|
expected: "(boolean | undefined)",
|
|
167
169
|
value: input.assert
|
|
@@ -178,12 +180,46 @@ var NestiaSdkConfig;
|
|
|
178
180
|
path: _path + ".output",
|
|
179
181
|
expected: "string",
|
|
180
182
|
value: input.output
|
|
181
|
-
})) && (undefined === input.
|
|
183
|
+
})) && (undefined === input.info || ("object" === typeof input.info && null !== input.info && false === Array.isArray(input.info) || $guard(_exceptionable, {
|
|
184
|
+
path: _path + ".info",
|
|
185
|
+
expected: "(Partial<ISwaggerDocument.IInfo> | undefined)",
|
|
186
|
+
value: input.info
|
|
187
|
+
})) && $ao2(input.info, _path + ".info", true && _exceptionable)) && (undefined === input.servers || (Array.isArray(input.servers) || $guard(_exceptionable, {
|
|
188
|
+
path: _path + ".servers",
|
|
189
|
+
expected: "(Array<ISwaggerDocument.IServer> | undefined)",
|
|
190
|
+
value: input.servers
|
|
191
|
+
})) && input.servers.every((elem, _index2) => ("object" === typeof elem && null !== elem || $guard(_exceptionable, {
|
|
192
|
+
path: _path + ".servers[" + _index2 + "]",
|
|
193
|
+
expected: "ISwaggerDocument.IServer",
|
|
194
|
+
value: elem
|
|
195
|
+
})) && $ao3(elem, _path + ".servers[" + _index2 + "]", true && _exceptionable))) && (undefined === input.security || ("object" === typeof input.security && null !== input.security && false === Array.isArray(input.security) || $guard(_exceptionable, {
|
|
182
196
|
path: _path + ".security",
|
|
183
197
|
expected: "(Record<string, INestiaConfig.ISwaggerConfig.ISecurityScheme> | undefined)",
|
|
184
198
|
value: input.security
|
|
185
|
-
})) && $
|
|
186
|
-
const $ao2 = (input, _path, _exceptionable = true) =>
|
|
199
|
+
})) && $ao4(input.security, _path + ".security", true && _exceptionable));
|
|
200
|
+
const $ao2 = (input, _path, _exceptionable = true) => (undefined === input.version || "string" === typeof input.version || $guard(_exceptionable, {
|
|
201
|
+
path: _path + ".version",
|
|
202
|
+
expected: "(string | undefined)",
|
|
203
|
+
value: input.version
|
|
204
|
+
})) && (undefined === input.title || "string" === typeof input.title || $guard(_exceptionable, {
|
|
205
|
+
path: _path + ".title",
|
|
206
|
+
expected: "(string | undefined)",
|
|
207
|
+
value: input.title
|
|
208
|
+
})) && (undefined === input.description || "string" === typeof input.description || $guard(_exceptionable, {
|
|
209
|
+
path: _path + ".description",
|
|
210
|
+
expected: "(string | undefined)",
|
|
211
|
+
value: input.description
|
|
212
|
+
}));
|
|
213
|
+
const $ao3 = (input, _path, _exceptionable = true) => ("string" === typeof input.url || $guard(_exceptionable, {
|
|
214
|
+
path: _path + ".url",
|
|
215
|
+
expected: "string",
|
|
216
|
+
value: input.url
|
|
217
|
+
})) && (undefined === input.description || "string" === typeof input.description || $guard(_exceptionable, {
|
|
218
|
+
path: _path + ".description",
|
|
219
|
+
expected: "(string | undefined)",
|
|
220
|
+
value: input.description
|
|
221
|
+
}));
|
|
222
|
+
const $ao4 = (input, _path, _exceptionable = true) => false === _exceptionable || Object.keys(input).every(key => {
|
|
187
223
|
const value = input[key];
|
|
188
224
|
if (undefined === value)
|
|
189
225
|
return true;
|
|
@@ -195,7 +231,7 @@ var NestiaSdkConfig;
|
|
|
195
231
|
})) && $au0(value, _path + $join(key), true && _exceptionable);
|
|
196
232
|
return true;
|
|
197
233
|
});
|
|
198
|
-
const $
|
|
234
|
+
const $ao5 = (input, _path, _exceptionable = true) => ("http" === input.type || $guard(_exceptionable, {
|
|
199
235
|
path: _path + ".type",
|
|
200
236
|
expected: "\"http\"",
|
|
201
237
|
value: input.type
|
|
@@ -204,7 +240,7 @@ var NestiaSdkConfig;
|
|
|
204
240
|
expected: "\"basic\"",
|
|
205
241
|
value: input.schema
|
|
206
242
|
}));
|
|
207
|
-
const $
|
|
243
|
+
const $ao6 = (input, _path, _exceptionable = true) => ("http" === input.type || $guard(_exceptionable, {
|
|
208
244
|
path: _path + ".type",
|
|
209
245
|
expected: "\"http\"",
|
|
210
246
|
value: input.type
|
|
@@ -217,7 +253,7 @@ var NestiaSdkConfig;
|
|
|
217
253
|
expected: "(string | undefined)",
|
|
218
254
|
value: input.bearerFormat
|
|
219
255
|
}));
|
|
220
|
-
const $
|
|
256
|
+
const $ao7 = (input, _path, _exceptionable = true) => ("openIdConnect" === input.type || $guard(_exceptionable, {
|
|
221
257
|
path: _path + ".type",
|
|
222
258
|
expected: "\"openIdConnect\"",
|
|
223
259
|
value: input.type
|
|
@@ -226,7 +262,7 @@ var NestiaSdkConfig;
|
|
|
226
262
|
expected: "string",
|
|
227
263
|
value: input.openIdConnectUrl
|
|
228
264
|
}));
|
|
229
|
-
const $
|
|
265
|
+
const $ao8 = (input, _path, _exceptionable = true) => ("oauth2" === input.type || $guard(_exceptionable, {
|
|
230
266
|
path: _path + ".type",
|
|
231
267
|
expected: "\"oauth2\"",
|
|
232
268
|
value: input.type
|
|
@@ -234,29 +270,29 @@ var NestiaSdkConfig;
|
|
|
234
270
|
path: _path + ".flows",
|
|
235
271
|
expected: "ISwaggerDocument.ISecurityScheme.IOAuth2.IFlowSet",
|
|
236
272
|
value: input.flows
|
|
237
|
-
})) && $
|
|
273
|
+
})) && $ao9(input.flows, _path + ".flows", true && _exceptionable)) && (undefined === input.description || "string" === typeof input.description || $guard(_exceptionable, {
|
|
238
274
|
path: _path + ".description",
|
|
239
275
|
expected: "(string | undefined)",
|
|
240
276
|
value: input.description
|
|
241
277
|
}));
|
|
242
|
-
const $
|
|
278
|
+
const $ao9 = (input, _path, _exceptionable = true) => (undefined === input.authorizationCode || ("object" === typeof input.authorizationCode && null !== input.authorizationCode || $guard(_exceptionable, {
|
|
243
279
|
path: _path + ".authorizationCode",
|
|
244
280
|
expected: "(ISwaggerDocument.ISecurityScheme.IOAuth2.IFlow | undefined)",
|
|
245
281
|
value: input.authorizationCode
|
|
246
|
-
})) && $
|
|
282
|
+
})) && $ao10(input.authorizationCode, _path + ".authorizationCode", true && _exceptionable)) && (undefined === input.implicit || ("object" === typeof input.implicit && null !== input.implicit || $guard(_exceptionable, {
|
|
247
283
|
path: _path + ".implicit",
|
|
248
284
|
expected: "(Omit<ISwaggerDocument.ISecurityScheme.IOAuth2.IFlow, \"tokenUrl\"> | undefined)",
|
|
249
285
|
value: input.implicit
|
|
250
|
-
})) && $
|
|
286
|
+
})) && $ao12(input.implicit, _path + ".implicit", true && _exceptionable)) && (undefined === input.password || ("object" === typeof input.password && null !== input.password || $guard(_exceptionable, {
|
|
251
287
|
path: _path + ".password",
|
|
252
288
|
expected: "(Omit<ISwaggerDocument.ISecurityScheme.IOAuth2.IFlow, \"authorizationUrl\"> | undefined)",
|
|
253
289
|
value: input.password
|
|
254
|
-
})) && $
|
|
290
|
+
})) && $ao13(input.password, _path + ".password", true && _exceptionable)) && (undefined === input.clientCredentials || ("object" === typeof input.clientCredentials && null !== input.clientCredentials || $guard(_exceptionable, {
|
|
255
291
|
path: _path + ".clientCredentials",
|
|
256
292
|
expected: "(Omit<ISwaggerDocument.ISecurityScheme.IOAuth2.IFlow, \"authorizationUrl\"> | undefined)",
|
|
257
293
|
value: input.clientCredentials
|
|
258
|
-
})) && $
|
|
259
|
-
const $
|
|
294
|
+
})) && $ao13(input.clientCredentials, _path + ".clientCredentials", true && _exceptionable));
|
|
295
|
+
const $ao10 = (input, _path, _exceptionable = true) => ("string" === typeof input.authorizationUrl || $guard(_exceptionable, {
|
|
260
296
|
path: _path + ".authorizationUrl",
|
|
261
297
|
expected: "string",
|
|
262
298
|
value: input.authorizationUrl
|
|
@@ -272,8 +308,8 @@ var NestiaSdkConfig;
|
|
|
272
308
|
path: _path + ".scopes",
|
|
273
309
|
expected: "(Record<string, string> | undefined)",
|
|
274
310
|
value: input.scopes
|
|
275
|
-
})) && $
|
|
276
|
-
const $
|
|
311
|
+
})) && $ao11(input.scopes, _path + ".scopes", true && _exceptionable));
|
|
312
|
+
const $ao11 = (input, _path, _exceptionable = true) => false === _exceptionable || Object.keys(input).every(key => {
|
|
277
313
|
const value = input[key];
|
|
278
314
|
if (undefined === value)
|
|
279
315
|
return true;
|
|
@@ -285,7 +321,7 @@ var NestiaSdkConfig;
|
|
|
285
321
|
});
|
|
286
322
|
return true;
|
|
287
323
|
});
|
|
288
|
-
const $
|
|
324
|
+
const $ao12 = (input, _path, _exceptionable = true) => ("string" === typeof input.authorizationUrl || $guard(_exceptionable, {
|
|
289
325
|
path: _path + ".authorizationUrl",
|
|
290
326
|
expected: "string",
|
|
291
327
|
value: input.authorizationUrl
|
|
@@ -297,8 +333,8 @@ var NestiaSdkConfig;
|
|
|
297
333
|
path: _path + ".scopes",
|
|
298
334
|
expected: "(Record<string, string> | undefined)",
|
|
299
335
|
value: input.scopes
|
|
300
|
-
})) && $
|
|
301
|
-
const $
|
|
336
|
+
})) && $ao11(input.scopes, _path + ".scopes", true && _exceptionable));
|
|
337
|
+
const $ao13 = (input, _path, _exceptionable = true) => ("string" === typeof input.tokenUrl || $guard(_exceptionable, {
|
|
302
338
|
path: _path + ".tokenUrl",
|
|
303
339
|
expected: "string",
|
|
304
340
|
value: input.tokenUrl
|
|
@@ -310,8 +346,8 @@ var NestiaSdkConfig;
|
|
|
310
346
|
path: _path + ".scopes",
|
|
311
347
|
expected: "(Record<string, string> | undefined)",
|
|
312
348
|
value: input.scopes
|
|
313
|
-
})) && $
|
|
314
|
-
const $
|
|
349
|
+
})) && $ao11(input.scopes, _path + ".scopes", true && _exceptionable));
|
|
350
|
+
const $ao14 = (input, _path, _exceptionable = true) => ("apiKey" === input.type || $guard(_exceptionable, {
|
|
315
351
|
path: _path + ".type",
|
|
316
352
|
expected: "\"apiKey\"",
|
|
317
353
|
value: input.type
|
|
@@ -328,24 +364,24 @@ var NestiaSdkConfig;
|
|
|
328
364
|
expected: "(string | undefined)",
|
|
329
365
|
value: input.name
|
|
330
366
|
}));
|
|
331
|
-
const $
|
|
367
|
+
const $ao15 = (input, _path, _exceptionable = true) => (Array.isArray(input.include) || $guard(_exceptionable, {
|
|
332
368
|
path: _path + ".include",
|
|
333
369
|
expected: "Array<string>",
|
|
334
370
|
value: input.include
|
|
335
|
-
})) && input.include.every((elem,
|
|
336
|
-
path: _path + ".include[" +
|
|
371
|
+
})) && input.include.every((elem, _index3) => "string" === typeof elem || $guard(_exceptionable, {
|
|
372
|
+
path: _path + ".include[" + _index3 + "]",
|
|
337
373
|
expected: "string",
|
|
338
374
|
value: elem
|
|
339
375
|
})) && (undefined === input.exclude || (Array.isArray(input.exclude) || $guard(_exceptionable, {
|
|
340
376
|
path: _path + ".exclude",
|
|
341
377
|
expected: "(Array<string> | undefined)",
|
|
342
378
|
value: input.exclude
|
|
343
|
-
})) && input.exclude.every((elem,
|
|
344
|
-
path: _path + ".exclude[" +
|
|
379
|
+
})) && input.exclude.every((elem, _index4) => "string" === typeof elem || $guard(_exceptionable, {
|
|
380
|
+
path: _path + ".exclude[" + _index4 + "]",
|
|
345
381
|
expected: "string",
|
|
346
382
|
value: elem
|
|
347
383
|
})));
|
|
348
|
-
const $
|
|
384
|
+
const $ao16 = (input, _path, _exceptionable = true) => (undefined === input.allowJs || "boolean" === typeof input.allowJs || $guard(_exceptionable, {
|
|
349
385
|
path: _path + ".allowJs",
|
|
350
386
|
expected: "(boolean | undefined)",
|
|
351
387
|
value: input.allowJs
|
|
@@ -461,8 +497,8 @@ var NestiaSdkConfig;
|
|
|
461
497
|
path: _path + ".lib",
|
|
462
498
|
expected: "(Array<string> | undefined)",
|
|
463
499
|
value: input.lib
|
|
464
|
-
})) && input.lib.every((elem,
|
|
465
|
-
path: _path + ".lib[" +
|
|
500
|
+
})) && input.lib.every((elem, _index5) => "string" === typeof elem || $guard(_exceptionable, {
|
|
501
|
+
path: _path + ".lib[" + _index5 + "]",
|
|
466
502
|
expected: "string",
|
|
467
503
|
value: elem
|
|
468
504
|
}))) && (undefined === input.locale || "string" === typeof input.locale || $guard(_exceptionable, {
|
|
@@ -477,8 +513,8 @@ var NestiaSdkConfig;
|
|
|
477
513
|
path: _path + ".moduleSuffixes",
|
|
478
514
|
expected: "(Array<string> | undefined)",
|
|
479
515
|
value: input.moduleSuffixes
|
|
480
|
-
})) && input.moduleSuffixes.every((elem,
|
|
481
|
-
path: _path + ".moduleSuffixes[" +
|
|
516
|
+
})) && input.moduleSuffixes.every((elem, _index6) => "string" === typeof elem || $guard(_exceptionable, {
|
|
517
|
+
path: _path + ".moduleSuffixes[" + _index6 + "]",
|
|
482
518
|
expected: "string",
|
|
483
519
|
value: elem
|
|
484
520
|
}))) && true && true && (undefined === input.noEmit || "boolean" === typeof input.noEmit || $guard(_exceptionable, {
|
|
@@ -565,7 +601,7 @@ var NestiaSdkConfig;
|
|
|
565
601
|
path: _path + ".paths",
|
|
566
602
|
expected: "(ts.MapLike<Array<string>> | undefined)",
|
|
567
603
|
value: input.paths
|
|
568
|
-
})) && $
|
|
604
|
+
})) && $ao17(input.paths, _path + ".paths", true && _exceptionable)) && (undefined === input.preserveConstEnums || "boolean" === typeof input.preserveConstEnums || $guard(_exceptionable, {
|
|
569
605
|
path: _path + ".preserveConstEnums",
|
|
570
606
|
expected: "(boolean | undefined)",
|
|
571
607
|
value: input.preserveConstEnums
|
|
@@ -625,8 +661,8 @@ var NestiaSdkConfig;
|
|
|
625
661
|
path: _path + ".rootDirs",
|
|
626
662
|
expected: "(Array<string> | undefined)",
|
|
627
663
|
value: input.rootDirs
|
|
628
|
-
})) && input.rootDirs.every((elem,
|
|
629
|
-
path: _path + ".rootDirs[" +
|
|
664
|
+
})) && input.rootDirs.every((elem, _index7) => "string" === typeof elem || $guard(_exceptionable, {
|
|
665
|
+
path: _path + ".rootDirs[" + _index7 + "]",
|
|
630
666
|
expected: "string",
|
|
631
667
|
value: elem
|
|
632
668
|
}))) && (undefined === input.skipLibCheck || "boolean" === typeof input.skipLibCheck || $guard(_exceptionable, {
|
|
@@ -693,16 +729,16 @@ var NestiaSdkConfig;
|
|
|
693
729
|
path: _path + ".types",
|
|
694
730
|
expected: "(Array<string> | undefined)",
|
|
695
731
|
value: input.types
|
|
696
|
-
})) && input.types.every((elem,
|
|
697
|
-
path: _path + ".types[" +
|
|
732
|
+
})) && input.types.every((elem, _index8) => "string" === typeof elem || $guard(_exceptionable, {
|
|
733
|
+
path: _path + ".types[" + _index8 + "]",
|
|
698
734
|
expected: "string",
|
|
699
735
|
value: elem
|
|
700
736
|
}))) && (undefined === input.typeRoots || (Array.isArray(input.typeRoots) || $guard(_exceptionable, {
|
|
701
737
|
path: _path + ".typeRoots",
|
|
702
738
|
expected: "(Array<string> | undefined)",
|
|
703
739
|
value: input.typeRoots
|
|
704
|
-
})) && input.typeRoots.every((elem,
|
|
705
|
-
path: _path + ".typeRoots[" +
|
|
740
|
+
})) && input.typeRoots.every((elem, _index9) => "string" === typeof elem || $guard(_exceptionable, {
|
|
741
|
+
path: _path + ".typeRoots[" + _index9 + "]",
|
|
706
742
|
expected: "string",
|
|
707
743
|
value: elem
|
|
708
744
|
}))) && (undefined === input.esModuleInterop || "boolean" === typeof input.esModuleInterop || $guard(_exceptionable, {
|
|
@@ -721,7 +757,7 @@ var NestiaSdkConfig;
|
|
|
721
757
|
return true;
|
|
722
758
|
return true;
|
|
723
759
|
}));
|
|
724
|
-
const $
|
|
760
|
+
const $ao17 = (input, _path, _exceptionable = true) => false === _exceptionable || Object.keys(input).every(key => {
|
|
725
761
|
const value = input[key];
|
|
726
762
|
if (undefined === value)
|
|
727
763
|
return true;
|
|
@@ -730,8 +766,8 @@ var NestiaSdkConfig;
|
|
|
730
766
|
path: _path + $join(key),
|
|
731
767
|
expected: "Array<string>",
|
|
732
768
|
value: value
|
|
733
|
-
})) && value.every((elem,
|
|
734
|
-
path: _path + $join(key) + "[" +
|
|
769
|
+
})) && value.every((elem, _index10) => "string" === typeof elem || $guard(_exceptionable, {
|
|
770
|
+
path: _path + $join(key) + "[" + _index10 + "]",
|
|
735
771
|
expected: "string",
|
|
736
772
|
value: elem
|
|
737
773
|
}));
|
|
@@ -739,15 +775,15 @@ var NestiaSdkConfig;
|
|
|
739
775
|
});
|
|
740
776
|
const $au0 = (input, _path, _exceptionable = true) => (() => {
|
|
741
777
|
if (undefined !== input.schema)
|
|
742
|
-
return $
|
|
778
|
+
return $ao5(input, _path, true && _exceptionable);
|
|
743
779
|
if (undefined !== input.scheme)
|
|
744
|
-
return $
|
|
780
|
+
return $ao6(input, _path, true && _exceptionable);
|
|
745
781
|
if ("openIdConnect" === input.type)
|
|
746
|
-
return $
|
|
782
|
+
return $ao7(input, _path, true && _exceptionable);
|
|
747
783
|
if ("oauth2" === input.type)
|
|
748
|
-
return $
|
|
784
|
+
return $ao8(input, _path, true && _exceptionable);
|
|
749
785
|
if ("apiKey" === input.type)
|
|
750
|
-
return $
|
|
786
|
+
return $ao14(input, _path, true && _exceptionable);
|
|
751
787
|
return $guard(_exceptionable, {
|
|
752
788
|
path: _path,
|
|
753
789
|
expected: "(ISwaggerDocument.ISecurityScheme.IHttpBasic | ISwaggerDocument.ISecurityScheme.IHttpBearer | ISwaggerDocument.ISecurityScheme.IOpenId | ISwaggerDocument.ISecurityScheme.IOAuth2 | INestiaConfig.ISwaggerConfig.IApiKey)",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NestiaSdkConfig.js","sourceRoot":"","sources":["../../../src/executable/internal/NestiaSdkConfig.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,4CAAoB;AACpB,gDAAwB;AACxB,gDAAkC;AAClC,qDAAkD;AAElD,iCAA+B;AAI/B,IAAiB,eAAe,CA0B/B;AA1BD,WAAiB,eAAe;IAC5B,SAAgB,GAAG;QACf,OAAO,SAAS,CAAC,GAAG,EAAE,CAAC;IAC3B,CAAC;IAFe,mBAAG,MAElB,CAAA;IAED,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,GAAS,EAAE;;QACvC,IAAI,YAAE,CAAC,UAAU,CAAC,kBAAkB,CAAC,KAAK,KAAK;YAAE,OAAO,IAAI,CAAC;QAE7D,MAAM,CAAC,QAAQ,CAAC;YACZ,IAAI,EAAE,KAAK;YACX,eAAe,EAAE;gBACb,MAAM,EAAE,UAAU;gBAClB,MAAM,EAAE,IAAI;aACf;SACJ,CAAC,CAAC;QAEH,MAAM,MAAM,GACR,YAAa,cAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC,0DAAC,CAAC;QACnD,IAAI,OAAO,MAAM,KAAK,QAAQ;YAC1B,MAAM,IAAI,KAAK,CAAC,kDAAkD,CAAC,CAAC;QAExE,MAAM,MAAM,GACR,OAAO,MAAM,CAAC,OAAO,KAAK,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC;QACjE,MAAM,MAAM,GAAkB,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC;QACjE;2BAAO,cAAM;0BAAN,cAAM;+BAAN,cAAM
|
|
1
|
+
{"version":3,"file":"NestiaSdkConfig.js","sourceRoot":"","sources":["../../../src/executable/internal/NestiaSdkConfig.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,4CAAoB;AACpB,gDAAwB;AACxB,gDAAkC;AAClC,qDAAkD;AAElD,iCAA+B;AAI/B,IAAiB,eAAe,CA0B/B;AA1BD,WAAiB,eAAe;IAC5B,SAAgB,GAAG;QACf,OAAO,SAAS,CAAC,GAAG,EAAE,CAAC;IAC3B,CAAC;IAFe,mBAAG,MAElB,CAAA;IAED,MAAM,SAAS,GAAG,IAAI,qBAAS,CAAC,GAAS,EAAE;;QACvC,IAAI,YAAE,CAAC,UAAU,CAAC,kBAAkB,CAAC,KAAK,KAAK;YAAE,OAAO,IAAI,CAAC;QAE7D,MAAM,CAAC,QAAQ,CAAC;YACZ,IAAI,EAAE,KAAK;YACX,eAAe,EAAE;gBACb,MAAM,EAAE,UAAU;gBAClB,MAAM,EAAE,IAAI;aACf;SACJ,CAAC,CAAC;QAEH,MAAM,MAAM,GACR,YAAa,cAAI,CAAC,OAAO,CAAC,kBAAkB,CAAC,0DAAC,CAAC;QACnD,IAAI,OAAO,MAAM,KAAK,QAAQ;YAC1B,MAAM,IAAI,KAAK,CAAC,kDAAkD,CAAC,CAAC;QAExE,MAAM,MAAM,GACR,OAAO,MAAM,CAAC,OAAO,KAAK,QAAQ,CAAC,CAAC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC;QACjE,MAAM,MAAM,GAAkB,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,CAAC;QACjE;2BAAO,cAAM;0BAAN,cAAM;+BAAN,cAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;WAAC,MAAM,EAAE;IAC1B,CAAC,CAAA,CAAC,CAAC;AACP,CAAC,EA1BgB,eAAe,GAAf,uBAAe,KAAf,uBAAe,QA0B/B"}
|