@scalar/oas-utils 0.2.122 → 0.2.123
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/CHANGELOG.md +11 -0
- package/dist/entities/cookie/cookie.d.ts +4 -4
- package/dist/entities/cookie/cookie.js +1 -1
- package/dist/entities/cookie/index.d.ts +1 -1
- package/dist/entities/cookie/index.d.ts.map +1 -1
- package/dist/entities/environment/environment.d.ts +2 -2
- package/dist/entities/environment/environment.js +1 -1
- package/dist/entities/environment/index.d.ts +1 -1
- package/dist/entities/environment/index.d.ts.map +1 -1
- package/dist/entities/hotkeys/index.d.ts +1 -1
- package/dist/entities/hotkeys/index.d.ts.map +1 -1
- package/dist/entities/shared/index.d.ts +1 -1
- package/dist/entities/shared/index.d.ts.map +1 -1
- package/dist/entities/shared/index.js +1 -1
- package/dist/entities/shared/utility.d.ts +0 -16
- package/dist/entities/shared/utility.d.ts.map +1 -1
- package/dist/entities/shared/utility.js +1 -8
- package/dist/entities/spec/collection.d.ts +24 -24
- package/dist/entities/spec/collection.d.ts.map +1 -1
- package/dist/entities/spec/collection.js +3 -2
- package/dist/entities/spec/index.d.ts +10 -11
- package/dist/entities/spec/index.d.ts.map +1 -1
- package/dist/entities/spec/index.js +8 -8
- package/dist/entities/spec/operation.d.ts +23 -23
- package/dist/entities/spec/operation.d.ts.map +1 -1
- package/dist/entities/spec/parameters.d.ts +6 -6
- package/dist/entities/spec/request-examples.d.ts +244 -244
- package/dist/entities/spec/request-examples.d.ts.map +1 -1
- package/dist/entities/spec/request-examples.js +6 -71
- package/dist/entities/spec/requests.d.ts +47 -47
- package/dist/entities/spec/requests.d.ts.map +1 -1
- package/dist/entities/spec/requests.js +3 -2
- package/dist/entities/spec/security.d.ts +39 -39
- package/dist/entities/spec/security.d.ts.map +1 -1
- package/dist/entities/spec/security.js +4 -4
- package/dist/entities/spec/server.d.ts +99 -28
- package/dist/entities/spec/server.d.ts.map +1 -1
- package/dist/entities/spec/server.js +1 -1
- package/dist/entities/spec/spec-objects.d.ts +3 -3
- package/dist/entities/spec/spec-objects.js +1 -1
- package/dist/entities/spec/x-scalar-environments.d.ts +9 -9
- package/dist/entities/spec/x-scalar-secrets.d.ts +4 -4
- package/dist/entities/workspace/index.d.ts +1 -1
- package/dist/entities/workspace/index.d.ts.map +1 -1
- package/dist/entities/workspace/workspace.d.ts +18 -18
- package/dist/entities/workspace/workspace.js +1 -1
- package/dist/helpers/{createHash.d.ts → create-hash.d.ts} +1 -1
- package/dist/helpers/create-hash.d.ts.map +1 -0
- package/dist/helpers/ensure-protocol.js +1 -1
- package/dist/helpers/{fetchSpecFromUrl.d.ts → fetch-spec-from-url.d.ts} +1 -1
- package/dist/helpers/fetch-spec-from-url.d.ts.map +1 -0
- package/dist/helpers/{fetchSpecFromUrl.js → fetch-spec-from-url.js} +1 -1
- package/dist/helpers/{fetchWithProxyFallback.d.ts → fetch-with-proxy-fallback.d.ts} +1 -1
- package/dist/helpers/fetch-with-proxy-fallback.d.ts.map +1 -0
- package/dist/helpers/{fetchWithProxyFallback.js → fetch-with-proxy-fallback.js} +1 -1
- package/dist/helpers/find-variables.d.ts +5 -0
- package/dist/helpers/find-variables.d.ts.map +1 -0
- package/dist/helpers/{findVariables.js → find-variables.js} +1 -1
- package/dist/helpers/{httpMethods.d.ts → http-methods.d.ts} +2 -2
- package/dist/helpers/http-methods.d.ts.map +1 -0
- package/dist/helpers/{httpStatusCodes.d.ts → http-status-codes.d.ts} +1 -1
- package/dist/helpers/http-status-codes.d.ts.map +1 -0
- package/dist/helpers/index.d.ts +27 -26
- package/dist/helpers/index.d.ts.map +1 -1
- package/dist/helpers/index.js +21 -20
- package/dist/helpers/{isLocalUrl.d.ts → is-local-url.d.ts} +1 -1
- package/dist/helpers/is-local-url.d.ts.map +1 -0
- package/dist/helpers/{isValidUrl.d.ts → is-valid-url.d.ts} +1 -1
- package/dist/helpers/is-valid-url.d.ts.map +1 -0
- package/dist/helpers/{iterateTitle.d.ts → iterate-title.d.ts} +1 -1
- package/dist/helpers/iterate-title.d.ts.map +1 -0
- package/dist/helpers/{makeUrlAbsolute.d.ts → make-url-absolute.d.ts} +1 -1
- package/dist/helpers/make-url-absolute.d.ts.map +1 -0
- package/dist/helpers/merge-urls.d.ts.map +1 -1
- package/dist/helpers/merge-urls.js +2 -2
- package/dist/helpers/{normalizeMimeTypeObject.d.ts → normalize-mime-type-object.d.ts} +1 -1
- package/dist/helpers/normalize-mime-type-object.d.ts.map +1 -0
- package/dist/helpers/{normalizeMimeTypeObject.js → normalize-mime-type-object.js} +1 -1
- package/dist/helpers/{normalizeMimeType.d.ts → normalize-mime-type.d.ts} +1 -1
- package/dist/helpers/normalize-mime-type.d.ts.map +1 -0
- package/dist/helpers/parse.js +1 -1
- package/dist/helpers/{prettyPrintJson.d.ts → pretty-print-json.d.ts} +1 -1
- package/dist/helpers/pretty-print-json.d.ts.map +1 -0
- package/dist/helpers/{redirectToProxy.d.ts → redirect-to-proxy.d.ts} +1 -1
- package/dist/helpers/redirect-to-proxy.d.ts.map +1 -0
- package/dist/helpers/{redirectToProxy.js → redirect-to-proxy.js} +2 -2
- package/dist/helpers/{regexHelpers.d.ts → regex-helpers.d.ts} +1 -1
- package/dist/helpers/regex-helpers.d.ts.map +1 -0
- package/dist/helpers/{replaceVariables.d.ts → replace-variables.d.ts} +1 -1
- package/dist/helpers/replace-variables.d.ts.map +1 -0
- package/dist/helpers/{shouldIgnoreEntity.d.ts → should-ignore-entity.d.ts} +3 -2
- package/dist/helpers/should-ignore-entity.d.ts.map +1 -0
- package/dist/helpers/{ssrState.d.ts → ssr-state.d.ts} +1 -1
- package/dist/helpers/ssr-state.d.ts.map +1 -0
- package/dist/helpers/string.d.ts.map +1 -1
- package/dist/helpers/string.js +1 -1
- package/dist/migrations/index.d.ts +3 -3
- package/dist/migrations/index.d.ts.map +1 -1
- package/dist/migrations/local-storage.d.ts +1 -1
- package/dist/migrations/local-storage.d.ts.map +1 -1
- package/dist/migrations/migrator.d.ts +1 -1
- package/dist/migrations/migrator.d.ts.map +1 -1
- package/dist/migrations/semver.js +1 -1
- package/dist/migrations/v-2.1.0/migration.d.ts +2 -2
- package/dist/migrations/v-2.1.0/migration.d.ts.map +1 -1
- package/dist/migrations/v-2.1.0/migration.js +1 -1
- package/dist/migrations/v-2.2.0/migration.d.ts +2 -2
- package/dist/migrations/v-2.2.0/migration.d.ts.map +1 -1
- package/dist/migrations/v-2.3.0/migration.d.ts +2 -2
- package/dist/migrations/v-2.3.0/migration.d.ts.map +1 -1
- package/dist/migrations/v-2.4.0/migration.d.ts +2 -2
- package/dist/migrations/v-2.4.0/migration.d.ts.map +1 -1
- package/dist/migrations/v-2.5.0/migration.d.ts +2 -2
- package/dist/migrations/v-2.5.0/migration.d.ts.map +1 -1
- package/dist/migrations/v-2.5.0/migration.js +2 -3
- package/dist/migrations/v-2.5.0/types.generated.d.ts +9 -4
- package/dist/migrations/v-2.5.0/types.generated.d.ts.map +1 -1
- package/dist/spec-getters/{getExampleFromSchema.d.ts → get-example-from-schema.d.ts} +1 -1
- package/dist/spec-getters/get-example-from-schema.d.ts.map +1 -0
- package/dist/spec-getters/{getParametersFromOperation.d.ts → get-parameters-from-operation.d.ts} +1 -1
- package/dist/spec-getters/get-parameters-from-operation.d.ts.map +1 -0
- package/dist/spec-getters/{getParametersFromOperation.js → get-parameters-from-operation.js} +1 -1
- package/dist/spec-getters/{getRequestBodyFromOperation.d.ts → get-request-body-from-operation.d.ts} +2 -2
- package/dist/spec-getters/get-request-body-from-operation.d.ts.map +1 -0
- package/dist/spec-getters/{getRequestBodyFromOperation.js → get-request-body-from-operation.js} +7 -7
- package/dist/spec-getters/{getServerVariableExamples.d.ts → get-server-variable-examples.d.ts} +2 -2
- package/dist/spec-getters/get-server-variable-examples.d.ts.map +1 -0
- package/dist/spec-getters/index.d.ts +4 -4
- package/dist/spec-getters/index.d.ts.map +1 -1
- package/dist/spec-getters/index.js +4 -4
- package/dist/transforms/import-spec.d.ts +7 -3
- package/dist/transforms/import-spec.d.ts.map +1 -1
- package/dist/transforms/import-spec.js +35 -26
- package/dist/transforms/index.d.ts +1 -1
- package/dist/transforms/index.d.ts.map +1 -1
- package/dist/transforms/index.js +1 -1
- package/package.json +5 -43
- package/dist/diff/diff.d.ts +0 -13
- package/dist/diff/diff.d.ts.map +0 -1
- package/dist/diff/diff.js +0 -41
- package/dist/diff/index.d.ts +0 -2
- package/dist/diff/index.d.ts.map +0 -1
- package/dist/diff/index.js +0 -1
- package/dist/entities/index.d.ts +0 -2
- package/dist/entities/index.d.ts.map +0 -1
- package/dist/entities/index.js +0 -1
- package/dist/helpers/createHash.d.ts.map +0 -1
- package/dist/helpers/fetchSpecFromUrl.d.ts.map +0 -1
- package/dist/helpers/fetchWithProxyFallback.d.ts.map +0 -1
- package/dist/helpers/findVariables.d.ts +0 -5
- package/dist/helpers/findVariables.d.ts.map +0 -1
- package/dist/helpers/httpMethods.d.ts.map +0 -1
- package/dist/helpers/httpStatusCodes.d.ts.map +0 -1
- package/dist/helpers/isLocalUrl.d.ts.map +0 -1
- package/dist/helpers/isValidUrl.d.ts.map +0 -1
- package/dist/helpers/iterateTitle.d.ts.map +0 -1
- package/dist/helpers/makeUrlAbsolute.d.ts.map +0 -1
- package/dist/helpers/normalizeMimeType.d.ts.map +0 -1
- package/dist/helpers/normalizeMimeTypeObject.d.ts.map +0 -1
- package/dist/helpers/prettyPrintJson.d.ts.map +0 -1
- package/dist/helpers/redirectToProxy.d.ts.map +0 -1
- package/dist/helpers/regexHelpers.d.ts.map +0 -1
- package/dist/helpers/replaceVariables.d.ts.map +0 -1
- package/dist/helpers/shouldIgnoreEntity.d.ts.map +0 -1
- package/dist/helpers/ssrState.d.ts.map +0 -1
- package/dist/migrations/v-0.0.0/index.d.ts +0 -2
- package/dist/migrations/v-0.0.0/index.d.ts.map +0 -1
- package/dist/migrations/v-0.0.0/index.js +0 -1
- package/dist/migrations/v-2.1.0/index.d.ts +0 -3
- package/dist/migrations/v-2.1.0/index.d.ts.map +0 -1
- package/dist/migrations/v-2.1.0/index.js +0 -1
- package/dist/migrations/v-2.2.0/index.d.ts +0 -3
- package/dist/migrations/v-2.2.0/index.d.ts.map +0 -1
- package/dist/migrations/v-2.2.0/index.js +0 -1
- package/dist/migrations/v-2.3.0/index.d.ts +0 -3
- package/dist/migrations/v-2.3.0/index.d.ts.map +0 -1
- package/dist/migrations/v-2.3.0/index.js +0 -1
- package/dist/migrations/v-2.4.0/index.d.ts +0 -3
- package/dist/migrations/v-2.4.0/index.d.ts.map +0 -1
- package/dist/migrations/v-2.4.0/index.js +0 -1
- package/dist/migrations/v-2.5.0/index.d.ts +0 -3
- package/dist/migrations/v-2.5.0/index.d.ts.map +0 -1
- package/dist/migrations/v-2.5.0/index.js +0 -1
- package/dist/spec-getters/getExampleFromSchema.d.ts.map +0 -1
- package/dist/spec-getters/getParametersFromOperation.d.ts.map +0 -1
- package/dist/spec-getters/getRequestBodyFromOperation.d.ts.map +0 -1
- package/dist/spec-getters/getServerVariableExamples.d.ts.map +0 -1
- /package/dist/helpers/{createHash.js → create-hash.js} +0 -0
- /package/dist/helpers/{httpMethods.js → http-methods.js} +0 -0
- /package/dist/helpers/{httpStatusCodes.js → http-status-codes.js} +0 -0
- /package/dist/helpers/{isLocalUrl.js → is-local-url.js} +0 -0
- /package/dist/helpers/{isValidUrl.js → is-valid-url.js} +0 -0
- /package/dist/helpers/{iterateTitle.js → iterate-title.js} +0 -0
- /package/dist/helpers/{makeUrlAbsolute.js → make-url-absolute.js} +0 -0
- /package/dist/helpers/{normalizeMimeType.js → normalize-mime-type.js} +0 -0
- /package/dist/helpers/{prettyPrintJson.js → pretty-print-json.js} +0 -0
- /package/dist/helpers/{regexHelpers.js → regex-helpers.js} +0 -0
- /package/dist/helpers/{replaceVariables.js → replace-variables.js} +0 -0
- /package/dist/helpers/{shouldIgnoreEntity.js → should-ignore-entity.js} +0 -0
- /package/dist/helpers/{ssrState.js → ssr-state.js} +0 -0
- /package/dist/spec-getters/{getExampleFromSchema.js → get-example-from-schema.js} +0 -0
- /package/dist/spec-getters/{getServerVariableExamples.js → get-server-variable-examples.js} +0 -0
|
@@ -15,21 +15,21 @@ export declare const securityApiKeySchema: z.ZodObject<z.objectUtil.extendShape<
|
|
|
15
15
|
}>, {
|
|
16
16
|
value: z.ZodDefault<z.ZodString>;
|
|
17
17
|
}>, "strip", z.ZodTypeAny, {
|
|
18
|
-
type: "apiKey";
|
|
19
|
-
value: string;
|
|
20
18
|
uid: string & z.BRAND<"securityScheme">;
|
|
21
19
|
name: string;
|
|
22
|
-
|
|
20
|
+
value: string;
|
|
21
|
+
type: "apiKey";
|
|
23
22
|
in: "cookie" | "query" | "header";
|
|
23
|
+
nameKey: string;
|
|
24
24
|
description?: string | undefined;
|
|
25
25
|
}, {
|
|
26
26
|
type: "apiKey";
|
|
27
|
-
value?: string | undefined;
|
|
28
27
|
uid?: string | undefined;
|
|
29
28
|
name?: string | undefined;
|
|
29
|
+
value?: string | undefined;
|
|
30
30
|
description?: string | undefined;
|
|
31
|
-
nameKey?: string | undefined;
|
|
32
31
|
in?: "cookie" | "query" | "header" | undefined;
|
|
32
|
+
nameKey?: string | undefined;
|
|
33
33
|
}>;
|
|
34
34
|
export type SecuritySchemeApiKey = z.infer<typeof securityApiKeySchema>;
|
|
35
35
|
export declare const securityHttpSchema: z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
@@ -56,24 +56,24 @@ export declare const securityHttpSchema: z.ZodObject<z.objectUtil.extendShape<z.
|
|
|
56
56
|
password: z.ZodDefault<z.ZodString>;
|
|
57
57
|
token: z.ZodDefault<z.ZodString>;
|
|
58
58
|
}>, "strip", z.ZodTypeAny, {
|
|
59
|
-
type: "http";
|
|
60
59
|
uid: string & z.BRAND<"securityScheme">;
|
|
60
|
+
type: "http";
|
|
61
|
+
password: string;
|
|
61
62
|
nameKey: string;
|
|
62
63
|
scheme: "basic" | "bearer";
|
|
63
64
|
bearerFormat: string;
|
|
64
65
|
username: string;
|
|
65
|
-
password: string;
|
|
66
66
|
token: string;
|
|
67
67
|
description?: string | undefined;
|
|
68
68
|
}, {
|
|
69
69
|
type: "http";
|
|
70
70
|
uid?: string | undefined;
|
|
71
71
|
description?: string | undefined;
|
|
72
|
+
password?: string | undefined;
|
|
72
73
|
nameKey?: string | undefined;
|
|
73
74
|
scheme?: string | undefined;
|
|
74
75
|
bearerFormat?: string | undefined;
|
|
75
76
|
username?: string | undefined;
|
|
76
|
-
password?: string | undefined;
|
|
77
77
|
token?: string | undefined;
|
|
78
78
|
}>;
|
|
79
79
|
export type SecuritySchemaHttp = z.infer<typeof securityHttpSchema>;
|
|
@@ -91,8 +91,8 @@ export declare const securityOpenIdSchema: z.ZodObject<z.objectUtil.extendShape<
|
|
|
91
91
|
/** The name key that links a security requirement to a security object */
|
|
92
92
|
nameKey: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
93
93
|
}>, "strip", z.ZodTypeAny, {
|
|
94
|
-
type: "openIdConnect";
|
|
95
94
|
uid: string & z.BRAND<"securityScheme">;
|
|
95
|
+
type: "openIdConnect";
|
|
96
96
|
nameKey: string;
|
|
97
97
|
openIdConnectUrl: string;
|
|
98
98
|
description?: string | undefined;
|
|
@@ -175,8 +175,8 @@ export declare const securityOauthSchema: z.ZodObject<z.objectUtil.extendShape<z
|
|
|
175
175
|
password: z.ZodDefault<z.ZodString>;
|
|
176
176
|
}>, "strip", z.ZodTypeAny, {
|
|
177
177
|
type: "password";
|
|
178
|
-
username: string;
|
|
179
178
|
password: string;
|
|
179
|
+
username: string;
|
|
180
180
|
token: string;
|
|
181
181
|
refreshUrl: string;
|
|
182
182
|
scopes: Record<string, string>;
|
|
@@ -186,8 +186,8 @@ export declare const securityOauthSchema: z.ZodObject<z.objectUtil.extendShape<z
|
|
|
186
186
|
clientSecret: string;
|
|
187
187
|
}, {
|
|
188
188
|
type: "password";
|
|
189
|
-
username?: string | undefined;
|
|
190
189
|
password?: string | undefined;
|
|
190
|
+
username?: string | undefined;
|
|
191
191
|
token?: string | undefined;
|
|
192
192
|
refreshUrl?: string | undefined;
|
|
193
193
|
scopes?: unknown;
|
|
@@ -291,8 +291,8 @@ export declare const securityOauthSchema: z.ZodObject<z.objectUtil.extendShape<z
|
|
|
291
291
|
}, "strip", z.ZodTypeAny, {
|
|
292
292
|
password?: {
|
|
293
293
|
type: "password";
|
|
294
|
-
username: string;
|
|
295
294
|
password: string;
|
|
295
|
+
username: string;
|
|
296
296
|
token: string;
|
|
297
297
|
refreshUrl: string;
|
|
298
298
|
scopes: Record<string, string>;
|
|
@@ -337,8 +337,8 @@ export declare const securityOauthSchema: z.ZodObject<z.objectUtil.extendShape<z
|
|
|
337
337
|
}, {
|
|
338
338
|
password?: {
|
|
339
339
|
type: "password";
|
|
340
|
-
username?: string | undefined;
|
|
341
340
|
password?: string | undefined;
|
|
341
|
+
username?: string | undefined;
|
|
342
342
|
token?: string | undefined;
|
|
343
343
|
refreshUrl?: string | undefined;
|
|
344
344
|
scopes?: unknown;
|
|
@@ -386,14 +386,14 @@ export declare const securityOauthSchema: z.ZodObject<z.objectUtil.extendShape<z
|
|
|
386
386
|
/** The name key that links a security requirement to a security object */
|
|
387
387
|
nameKey: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
388
388
|
}>, "strip", z.ZodTypeAny, {
|
|
389
|
-
type: "oauth2";
|
|
390
389
|
uid: string & z.BRAND<"securityScheme">;
|
|
390
|
+
type: "oauth2";
|
|
391
391
|
nameKey: string;
|
|
392
392
|
flows: {
|
|
393
393
|
password?: {
|
|
394
394
|
type: "password";
|
|
395
|
-
username: string;
|
|
396
395
|
password: string;
|
|
396
|
+
username: string;
|
|
397
397
|
token: string;
|
|
398
398
|
refreshUrl: string;
|
|
399
399
|
scopes: Record<string, string>;
|
|
@@ -445,8 +445,8 @@ export declare const securityOauthSchema: z.ZodObject<z.objectUtil.extendShape<z
|
|
|
445
445
|
flows?: {
|
|
446
446
|
password?: {
|
|
447
447
|
type: "password";
|
|
448
|
-
username?: string | undefined;
|
|
449
448
|
password?: string | undefined;
|
|
449
|
+
username?: string | undefined;
|
|
450
450
|
token?: string | undefined;
|
|
451
451
|
refreshUrl?: string | undefined;
|
|
452
452
|
scopes?: unknown;
|
|
@@ -516,8 +516,8 @@ export declare const oasSecuritySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUt
|
|
|
516
516
|
/** REQUIRED. The location of the API key. Valid values are "query", "header" or "cookie". */
|
|
517
517
|
in: z.ZodDefault<z.ZodOptional<z.ZodEnum<["query", "header", "cookie"]>>>;
|
|
518
518
|
}>, "strip", z.ZodTypeAny, {
|
|
519
|
-
type: "apiKey";
|
|
520
519
|
name: string;
|
|
520
|
+
type: "apiKey";
|
|
521
521
|
in: "cookie" | "query" | "header";
|
|
522
522
|
description?: string | undefined;
|
|
523
523
|
}, {
|
|
@@ -619,8 +619,8 @@ export declare const oasSecuritySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUt
|
|
|
619
619
|
password: z.ZodDefault<z.ZodString>;
|
|
620
620
|
}>, "strip", z.ZodTypeAny, {
|
|
621
621
|
type: "password";
|
|
622
|
-
username: string;
|
|
623
622
|
password: string;
|
|
623
|
+
username: string;
|
|
624
624
|
token: string;
|
|
625
625
|
refreshUrl: string;
|
|
626
626
|
scopes: Record<string, string>;
|
|
@@ -630,8 +630,8 @@ export declare const oasSecuritySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUt
|
|
|
630
630
|
clientSecret: string;
|
|
631
631
|
}, {
|
|
632
632
|
type: "password";
|
|
633
|
-
username?: string | undefined;
|
|
634
633
|
password?: string | undefined;
|
|
634
|
+
username?: string | undefined;
|
|
635
635
|
token?: string | undefined;
|
|
636
636
|
refreshUrl?: string | undefined;
|
|
637
637
|
scopes?: unknown;
|
|
@@ -735,8 +735,8 @@ export declare const oasSecuritySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUt
|
|
|
735
735
|
}, "strip", z.ZodTypeAny, {
|
|
736
736
|
password?: {
|
|
737
737
|
type: "password";
|
|
738
|
-
username: string;
|
|
739
738
|
password: string;
|
|
739
|
+
username: string;
|
|
740
740
|
token: string;
|
|
741
741
|
refreshUrl: string;
|
|
742
742
|
scopes: Record<string, string>;
|
|
@@ -781,8 +781,8 @@ export declare const oasSecuritySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUt
|
|
|
781
781
|
}, {
|
|
782
782
|
password?: {
|
|
783
783
|
type: "password";
|
|
784
|
-
username?: string | undefined;
|
|
785
784
|
password?: string | undefined;
|
|
785
|
+
username?: string | undefined;
|
|
786
786
|
token?: string | undefined;
|
|
787
787
|
refreshUrl?: string | undefined;
|
|
788
788
|
scopes?: unknown;
|
|
@@ -830,8 +830,8 @@ export declare const oasSecuritySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUt
|
|
|
830
830
|
flows: {
|
|
831
831
|
password?: {
|
|
832
832
|
type: "password";
|
|
833
|
-
username: string;
|
|
834
833
|
password: string;
|
|
834
|
+
username: string;
|
|
835
835
|
token: string;
|
|
836
836
|
refreshUrl: string;
|
|
837
837
|
scopes: Record<string, string>;
|
|
@@ -881,8 +881,8 @@ export declare const oasSecuritySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUt
|
|
|
881
881
|
flows?: {
|
|
882
882
|
password?: {
|
|
883
883
|
type: "password";
|
|
884
|
-
username?: string | undefined;
|
|
885
884
|
password?: string | undefined;
|
|
885
|
+
username?: string | undefined;
|
|
886
886
|
token?: string | undefined;
|
|
887
887
|
refreshUrl?: string | undefined;
|
|
888
888
|
scopes?: unknown;
|
|
@@ -959,21 +959,21 @@ export declare const securitySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUtil.
|
|
|
959
959
|
}>, {
|
|
960
960
|
value: z.ZodDefault<z.ZodString>;
|
|
961
961
|
}>, "strip", z.ZodTypeAny, {
|
|
962
|
-
type: "apiKey";
|
|
963
|
-
value: string;
|
|
964
962
|
uid: string & z.BRAND<"securityScheme">;
|
|
965
963
|
name: string;
|
|
966
|
-
|
|
964
|
+
value: string;
|
|
965
|
+
type: "apiKey";
|
|
967
966
|
in: "cookie" | "query" | "header";
|
|
967
|
+
nameKey: string;
|
|
968
968
|
description?: string | undefined;
|
|
969
969
|
}, {
|
|
970
970
|
type: "apiKey";
|
|
971
|
-
value?: string | undefined;
|
|
972
971
|
uid?: string | undefined;
|
|
973
972
|
name?: string | undefined;
|
|
973
|
+
value?: string | undefined;
|
|
974
974
|
description?: string | undefined;
|
|
975
|
-
nameKey?: string | undefined;
|
|
976
975
|
in?: "cookie" | "query" | "header" | undefined;
|
|
976
|
+
nameKey?: string | undefined;
|
|
977
977
|
}>, z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
978
978
|
description: z.ZodOptional<z.ZodString>;
|
|
979
979
|
}, {
|
|
@@ -998,24 +998,24 @@ export declare const securitySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUtil.
|
|
|
998
998
|
password: z.ZodDefault<z.ZodString>;
|
|
999
999
|
token: z.ZodDefault<z.ZodString>;
|
|
1000
1000
|
}>, "strip", z.ZodTypeAny, {
|
|
1001
|
-
type: "http";
|
|
1002
1001
|
uid: string & z.BRAND<"securityScheme">;
|
|
1002
|
+
type: "http";
|
|
1003
|
+
password: string;
|
|
1003
1004
|
nameKey: string;
|
|
1004
1005
|
scheme: "basic" | "bearer";
|
|
1005
1006
|
bearerFormat: string;
|
|
1006
1007
|
username: string;
|
|
1007
|
-
password: string;
|
|
1008
1008
|
token: string;
|
|
1009
1009
|
description?: string | undefined;
|
|
1010
1010
|
}, {
|
|
1011
1011
|
type: "http";
|
|
1012
1012
|
uid?: string | undefined;
|
|
1013
1013
|
description?: string | undefined;
|
|
1014
|
+
password?: string | undefined;
|
|
1014
1015
|
nameKey?: string | undefined;
|
|
1015
1016
|
scheme?: string | undefined;
|
|
1016
1017
|
bearerFormat?: string | undefined;
|
|
1017
1018
|
username?: string | undefined;
|
|
1018
|
-
password?: string | undefined;
|
|
1019
1019
|
token?: string | undefined;
|
|
1020
1020
|
}>, z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
1021
1021
|
description: z.ZodOptional<z.ZodString>;
|
|
@@ -1031,8 +1031,8 @@ export declare const securitySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUtil.
|
|
|
1031
1031
|
/** The name key that links a security requirement to a security object */
|
|
1032
1032
|
nameKey: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
1033
1033
|
}>, "strip", z.ZodTypeAny, {
|
|
1034
|
-
type: "openIdConnect";
|
|
1035
1034
|
uid: string & z.BRAND<"securityScheme">;
|
|
1035
|
+
type: "openIdConnect";
|
|
1036
1036
|
nameKey: string;
|
|
1037
1037
|
openIdConnectUrl: string;
|
|
1038
1038
|
description?: string | undefined;
|
|
@@ -1111,8 +1111,8 @@ export declare const securitySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUtil.
|
|
|
1111
1111
|
password: z.ZodDefault<z.ZodString>;
|
|
1112
1112
|
}>, "strip", z.ZodTypeAny, {
|
|
1113
1113
|
type: "password";
|
|
1114
|
-
username: string;
|
|
1115
1114
|
password: string;
|
|
1115
|
+
username: string;
|
|
1116
1116
|
token: string;
|
|
1117
1117
|
refreshUrl: string;
|
|
1118
1118
|
scopes: Record<string, string>;
|
|
@@ -1122,8 +1122,8 @@ export declare const securitySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUtil.
|
|
|
1122
1122
|
clientSecret: string;
|
|
1123
1123
|
}, {
|
|
1124
1124
|
type: "password";
|
|
1125
|
-
username?: string | undefined;
|
|
1126
1125
|
password?: string | undefined;
|
|
1126
|
+
username?: string | undefined;
|
|
1127
1127
|
token?: string | undefined;
|
|
1128
1128
|
refreshUrl?: string | undefined;
|
|
1129
1129
|
scopes?: unknown;
|
|
@@ -1227,8 +1227,8 @@ export declare const securitySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUtil.
|
|
|
1227
1227
|
}, "strip", z.ZodTypeAny, {
|
|
1228
1228
|
password?: {
|
|
1229
1229
|
type: "password";
|
|
1230
|
-
username: string;
|
|
1231
1230
|
password: string;
|
|
1231
|
+
username: string;
|
|
1232
1232
|
token: string;
|
|
1233
1233
|
refreshUrl: string;
|
|
1234
1234
|
scopes: Record<string, string>;
|
|
@@ -1273,8 +1273,8 @@ export declare const securitySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUtil.
|
|
|
1273
1273
|
}, {
|
|
1274
1274
|
password?: {
|
|
1275
1275
|
type: "password";
|
|
1276
|
-
username?: string | undefined;
|
|
1277
1276
|
password?: string | undefined;
|
|
1277
|
+
username?: string | undefined;
|
|
1278
1278
|
token?: string | undefined;
|
|
1279
1279
|
refreshUrl?: string | undefined;
|
|
1280
1280
|
scopes?: unknown;
|
|
@@ -1322,14 +1322,14 @@ export declare const securitySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUtil.
|
|
|
1322
1322
|
/** The name key that links a security requirement to a security object */
|
|
1323
1323
|
nameKey: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
1324
1324
|
}>, "strip", z.ZodTypeAny, {
|
|
1325
|
-
type: "oauth2";
|
|
1326
1325
|
uid: string & z.BRAND<"securityScheme">;
|
|
1326
|
+
type: "oauth2";
|
|
1327
1327
|
nameKey: string;
|
|
1328
1328
|
flows: {
|
|
1329
1329
|
password?: {
|
|
1330
1330
|
type: "password";
|
|
1331
|
-
username: string;
|
|
1332
1331
|
password: string;
|
|
1332
|
+
username: string;
|
|
1333
1333
|
token: string;
|
|
1334
1334
|
refreshUrl: string;
|
|
1335
1335
|
scopes: Record<string, string>;
|
|
@@ -1381,8 +1381,8 @@ export declare const securitySchemeSchema: z.ZodUnion<[z.ZodObject<z.objectUtil.
|
|
|
1381
1381
|
flows?: {
|
|
1382
1382
|
password?: {
|
|
1383
1383
|
type: "password";
|
|
1384
|
-
username?: string | undefined;
|
|
1385
1384
|
password?: string | undefined;
|
|
1385
|
+
username?: string | undefined;
|
|
1386
1386
|
token?: string | undefined;
|
|
1387
1387
|
refreshUrl?: string | undefined;
|
|
1388
1388
|
scopes?: unknown;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"security.d.ts","sourceRoot":"","sources":["../../../src/entities/spec/security.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;
|
|
1
|
+
{"version":3,"file":"security.d.ts","sourceRoot":"","sources":["../../../src/entities/spec/security.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { nanoidSchema } from '
|
|
2
|
+
import { nanoidSchema } from '@scalar/types/utils';
|
|
3
3
|
|
|
4
4
|
// ---------------------------------------------------------------------------
|
|
5
5
|
// COMMON PROPS FOR ALL SECURITY SCHEMES
|
|
@@ -160,9 +160,9 @@ const securityOauthSchema = oasSecuritySchemeOauth2.merge(extendedSecuritySchema
|
|
|
160
160
|
*
|
|
161
161
|
* @see https://spec.openapis.org/oas/latest.html#security-requirement-object
|
|
162
162
|
*/
|
|
163
|
-
|
|
163
|
+
z.record(z.string(), z.array(z.string()).optional().default([]));
|
|
164
164
|
/** OAS Compliant security schemes */
|
|
165
|
-
|
|
165
|
+
z.union([
|
|
166
166
|
oasSecuritySchemeApiKey,
|
|
167
167
|
oasSecuritySchemeHttp,
|
|
168
168
|
oasSecuritySchemeOauth2,
|
|
@@ -176,4 +176,4 @@ const securitySchemeSchema = z.union([
|
|
|
176
176
|
securityOauthSchema,
|
|
177
177
|
]);
|
|
178
178
|
|
|
179
|
-
export {
|
|
179
|
+
export { pkceOptions, securityApiKeySchema, securityHttpSchema, securityOauthSchema, securityOpenIdSchema, securitySchemeApiKeyIn, securitySchemeSchema };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { type ZodSchema, z } from 'zod';
|
|
1
|
+
import { z } from 'zod';
|
|
3
2
|
/**
|
|
4
3
|
* Server Variable Object
|
|
5
4
|
*
|
|
@@ -23,12 +22,12 @@ export declare const oasServerVariableSchema: z.ZodObject<{
|
|
|
23
22
|
*/
|
|
24
23
|
description: z.ZodOptional<z.ZodString>;
|
|
25
24
|
}, "strip", z.ZodTypeAny, {
|
|
26
|
-
default?: string | undefined;
|
|
27
25
|
description?: string | undefined;
|
|
26
|
+
default?: string | undefined;
|
|
28
27
|
enum?: string[] | undefined;
|
|
29
28
|
}, {
|
|
30
|
-
default?: string | undefined;
|
|
31
29
|
description?: string | undefined;
|
|
30
|
+
default?: string | undefined;
|
|
32
31
|
enum?: string[] | undefined;
|
|
33
32
|
}>;
|
|
34
33
|
/**
|
|
@@ -51,26 +50,62 @@ export declare const oasServerSchema: z.ZodObject<{
|
|
|
51
50
|
*/
|
|
52
51
|
description: z.ZodOptional<z.ZodString>;
|
|
53
52
|
/** A map between a variable name and its value. The value is used for substitution in the server's URL template. */
|
|
54
|
-
variables: z.ZodOptional<z.ZodRecord<z.ZodString,
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
enum
|
|
59
|
-
|
|
53
|
+
variables: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodEffects<z.ZodObject<z.objectUtil.extendShape<{
|
|
54
|
+
/**
|
|
55
|
+
* An enumeration of string values to be used if the substitution options are from a limited set. The array MUST NOT be empty.
|
|
56
|
+
*/
|
|
57
|
+
enum: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
58
|
+
/**
|
|
59
|
+
* REQUIRED. The default value to use for substitution, which SHALL be sent if an alternate value is not supplied.
|
|
60
|
+
* Note this behavior is different than the Schema Object's treatment of default values, because in those cases
|
|
61
|
+
* parameter values are optional. If the enum is defined, the value MUST exist in the enum's values.
|
|
62
|
+
*/
|
|
63
|
+
default: z.ZodOptional<z.ZodString>;
|
|
64
|
+
/**
|
|
65
|
+
* An optional description for the server variable. CommonMark syntax MAY be used for rich text representation.
|
|
66
|
+
*/
|
|
67
|
+
description: z.ZodOptional<z.ZodString>;
|
|
68
|
+
}, {
|
|
69
|
+
/** The value of the variable */
|
|
70
|
+
value: z.ZodOptional<z.ZodString>;
|
|
71
|
+
}>, "strip", z.ZodTypeAny, {
|
|
72
|
+
value?: string | undefined;
|
|
73
|
+
description?: string | undefined;
|
|
74
|
+
default?: string | undefined;
|
|
75
|
+
enum?: string[] | undefined;
|
|
76
|
+
}, {
|
|
77
|
+
value?: string | undefined;
|
|
78
|
+
description?: string | undefined;
|
|
79
|
+
default?: string | undefined;
|
|
80
|
+
enum?: string[] | undefined;
|
|
81
|
+
}>, {
|
|
82
|
+
value?: string | undefined;
|
|
83
|
+
description?: string | undefined;
|
|
84
|
+
default?: string | undefined;
|
|
85
|
+
enum?: string[] | undefined;
|
|
86
|
+
}, {
|
|
87
|
+
value?: string | undefined;
|
|
88
|
+
description?: string | undefined;
|
|
89
|
+
default?: string | undefined;
|
|
90
|
+
enum?: string[] | undefined;
|
|
60
91
|
}>>>;
|
|
61
92
|
}, "strip", z.ZodTypeAny, {
|
|
62
93
|
url: string;
|
|
63
94
|
description?: string | undefined;
|
|
64
|
-
variables?: Record<string,
|
|
65
|
-
|
|
66
|
-
|
|
95
|
+
variables?: Record<string, {
|
|
96
|
+
value?: string | undefined;
|
|
97
|
+
description?: string | undefined;
|
|
98
|
+
default?: string | undefined;
|
|
99
|
+
enum?: string[] | undefined;
|
|
67
100
|
}> | undefined;
|
|
68
101
|
}, {
|
|
69
102
|
url: string;
|
|
70
103
|
description?: string | undefined;
|
|
71
|
-
variables?: Record<string,
|
|
72
|
-
|
|
73
|
-
|
|
104
|
+
variables?: Record<string, {
|
|
105
|
+
value?: string | undefined;
|
|
106
|
+
description?: string | undefined;
|
|
107
|
+
default?: string | undefined;
|
|
108
|
+
enum?: string[] | undefined;
|
|
74
109
|
}> | undefined;
|
|
75
110
|
}>;
|
|
76
111
|
export declare const serverSchema: z.ZodObject<z.objectUtil.extendShape<{
|
|
@@ -86,12 +121,44 @@ export declare const serverSchema: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
86
121
|
*/
|
|
87
122
|
description: z.ZodOptional<z.ZodString>;
|
|
88
123
|
/** A map between a variable name and its value. The value is used for substitution in the server's URL template. */
|
|
89
|
-
variables: z.ZodOptional<z.ZodRecord<z.ZodString,
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
enum
|
|
94
|
-
|
|
124
|
+
variables: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodEffects<z.ZodObject<z.objectUtil.extendShape<{
|
|
125
|
+
/**
|
|
126
|
+
* An enumeration of string values to be used if the substitution options are from a limited set. The array MUST NOT be empty.
|
|
127
|
+
*/
|
|
128
|
+
enum: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
129
|
+
/**
|
|
130
|
+
* REQUIRED. The default value to use for substitution, which SHALL be sent if an alternate value is not supplied.
|
|
131
|
+
* Note this behavior is different than the Schema Object's treatment of default values, because in those cases
|
|
132
|
+
* parameter values are optional. If the enum is defined, the value MUST exist in the enum's values.
|
|
133
|
+
*/
|
|
134
|
+
default: z.ZodOptional<z.ZodString>;
|
|
135
|
+
/**
|
|
136
|
+
* An optional description for the server variable. CommonMark syntax MAY be used for rich text representation.
|
|
137
|
+
*/
|
|
138
|
+
description: z.ZodOptional<z.ZodString>;
|
|
139
|
+
}, {
|
|
140
|
+
/** The value of the variable */
|
|
141
|
+
value: z.ZodOptional<z.ZodString>;
|
|
142
|
+
}>, "strip", z.ZodTypeAny, {
|
|
143
|
+
value?: string | undefined;
|
|
144
|
+
description?: string | undefined;
|
|
145
|
+
default?: string | undefined;
|
|
146
|
+
enum?: string[] | undefined;
|
|
147
|
+
}, {
|
|
148
|
+
value?: string | undefined;
|
|
149
|
+
description?: string | undefined;
|
|
150
|
+
default?: string | undefined;
|
|
151
|
+
enum?: string[] | undefined;
|
|
152
|
+
}>, {
|
|
153
|
+
value?: string | undefined;
|
|
154
|
+
description?: string | undefined;
|
|
155
|
+
default?: string | undefined;
|
|
156
|
+
enum?: string[] | undefined;
|
|
157
|
+
}, {
|
|
158
|
+
value?: string | undefined;
|
|
159
|
+
description?: string | undefined;
|
|
160
|
+
default?: string | undefined;
|
|
161
|
+
enum?: string[] | undefined;
|
|
95
162
|
}>>>;
|
|
96
163
|
}, {
|
|
97
164
|
uid: z.ZodBranded<z.ZodDefault<z.ZodOptional<z.ZodString>>, "server">;
|
|
@@ -99,17 +166,21 @@ export declare const serverSchema: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
99
166
|
uid: string & z.BRAND<"server">;
|
|
100
167
|
url: string;
|
|
101
168
|
description?: string | undefined;
|
|
102
|
-
variables?: Record<string,
|
|
103
|
-
|
|
104
|
-
|
|
169
|
+
variables?: Record<string, {
|
|
170
|
+
value?: string | undefined;
|
|
171
|
+
description?: string | undefined;
|
|
172
|
+
default?: string | undefined;
|
|
173
|
+
enum?: string[] | undefined;
|
|
105
174
|
}> | undefined;
|
|
106
175
|
}, {
|
|
107
176
|
url: string;
|
|
108
177
|
uid?: string | undefined;
|
|
109
178
|
description?: string | undefined;
|
|
110
|
-
variables?: Record<string,
|
|
111
|
-
|
|
112
|
-
|
|
179
|
+
variables?: Record<string, {
|
|
180
|
+
value?: string | undefined;
|
|
181
|
+
description?: string | undefined;
|
|
182
|
+
default?: string | undefined;
|
|
183
|
+
enum?: string[] | undefined;
|
|
113
184
|
}> | undefined;
|
|
114
185
|
}>;
|
|
115
186
|
export type Server = z.infer<typeof serverSchema>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../../src/entities/spec/server.ts"],"names":[],"mappings":"AACA,OAAO,
|
|
1
|
+
{"version":3,"file":"server.d.ts","sourceRoot":"","sources":["../../../src/entities/spec/server.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB;;;;;;GAMG;AACH,eAAO,MAAM,uBAAuB;IAClC;;OAEG;;IAEH;;;;OAIG;;IAEH;;OAEG;;;;;;;;;;EAEH,CAAA;AAsBF;;;;;;GAMG;AACH,eAAO,MAAM,eAAe;IAC1B;;;;OAIG;;IAEH;;;OAGG;;IAEH,oHAAoH;;QAvDpH;;WAEG;;QAEH;;;;WAIG;;QAEH;;WAEG;;;QAOD,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAsClC,CAAA;AAEF,eAAO,MAAM,YAAY;IAfvB;;;;OAIG;;IAEH;;;OAGG;;IAEH,oHAAoH;;QAvDpH;;WAEG;;QAEH;;;;WAIG;;QAEH;;WAEG;;;QAOD,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA0ClC,CAAA;AAEF,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAA;AACjD,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAA"}
|
|
@@ -272,8 +272,8 @@ export declare const oasTagSchema: z.ZodObject<{
|
|
|
272
272
|
'x-internal': z.ZodOptional<z.ZodBoolean>;
|
|
273
273
|
'x-scalar-ignore': z.ZodOptional<z.ZodBoolean>;
|
|
274
274
|
}, "strip", z.ZodTypeAny, {
|
|
275
|
-
type: "tag";
|
|
276
275
|
name: string;
|
|
276
|
+
type: "tag";
|
|
277
277
|
description?: string | undefined;
|
|
278
278
|
externalDocs?: {
|
|
279
279
|
url: string;
|
|
@@ -340,9 +340,9 @@ export declare const tagSchema: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
340
340
|
uid: z.ZodBranded<z.ZodDefault<z.ZodOptional<z.ZodString>>, "tag">;
|
|
341
341
|
children: z.ZodDefault<z.ZodArray<z.ZodUnion<[z.ZodBranded<z.ZodString, "operation">, z.ZodBranded<z.ZodString, "tag">]>, "many">>;
|
|
342
342
|
}>, "strip", z.ZodTypeAny, {
|
|
343
|
-
type: "tag";
|
|
344
343
|
uid: string & z.BRAND<"tag">;
|
|
345
344
|
name: string;
|
|
345
|
+
type: "tag";
|
|
346
346
|
children: ((string & z.BRAND<"tag">) | (string & z.BRAND<"operation">))[];
|
|
347
347
|
description?: string | undefined;
|
|
348
348
|
externalDocs?: {
|
|
@@ -356,8 +356,8 @@ export declare const tagSchema: z.ZodObject<z.objectUtil.extendShape<{
|
|
|
356
356
|
'x-scalar-ignore'?: boolean | undefined;
|
|
357
357
|
}, {
|
|
358
358
|
name: string;
|
|
359
|
-
type?: "tag" | undefined;
|
|
360
359
|
uid?: string | undefined;
|
|
360
|
+
type?: "tag" | undefined;
|
|
361
361
|
description?: unknown;
|
|
362
362
|
externalDocs?: {
|
|
363
363
|
url: string;
|
|
@@ -7,8 +7,8 @@ export declare const xScalarEnvVarSchema: z.ZodUnion<[z.ZodObject<{
|
|
|
7
7
|
default: string;
|
|
8
8
|
description?: string | undefined;
|
|
9
9
|
}, {
|
|
10
|
-
default?: string | undefined;
|
|
11
10
|
description?: string | undefined;
|
|
11
|
+
default?: string | undefined;
|
|
12
12
|
}>, z.ZodString]>;
|
|
13
13
|
export declare const xScalarEnvironmentSchema: z.ZodObject<{
|
|
14
14
|
description: z.ZodOptional<z.ZodString>;
|
|
@@ -21,23 +21,23 @@ export declare const xScalarEnvironmentSchema: z.ZodObject<{
|
|
|
21
21
|
default: string;
|
|
22
22
|
description?: string | undefined;
|
|
23
23
|
}, {
|
|
24
|
-
default?: string | undefined;
|
|
25
24
|
description?: string | undefined;
|
|
25
|
+
default?: string | undefined;
|
|
26
26
|
}>, z.ZodString]>>;
|
|
27
27
|
}, "strip", z.ZodTypeAny, {
|
|
28
28
|
variables: Record<string, string | {
|
|
29
29
|
default: string;
|
|
30
30
|
description?: string | undefined;
|
|
31
31
|
}>;
|
|
32
|
-
description?: string | undefined;
|
|
33
32
|
color?: string | undefined;
|
|
33
|
+
description?: string | undefined;
|
|
34
34
|
}, {
|
|
35
35
|
variables: Record<string, string | {
|
|
36
|
-
default?: string | undefined;
|
|
37
36
|
description?: string | undefined;
|
|
37
|
+
default?: string | undefined;
|
|
38
38
|
}>;
|
|
39
|
-
description?: string | undefined;
|
|
40
39
|
color?: string | undefined;
|
|
40
|
+
description?: string | undefined;
|
|
41
41
|
}>;
|
|
42
42
|
/** A map of environments by name */
|
|
43
43
|
export declare const xScalarEnvironmentsSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
@@ -51,23 +51,23 @@ export declare const xScalarEnvironmentsSchema: z.ZodRecord<z.ZodString, z.ZodOb
|
|
|
51
51
|
default: string;
|
|
52
52
|
description?: string | undefined;
|
|
53
53
|
}, {
|
|
54
|
-
default?: string | undefined;
|
|
55
54
|
description?: string | undefined;
|
|
55
|
+
default?: string | undefined;
|
|
56
56
|
}>, z.ZodString]>>;
|
|
57
57
|
}, "strip", z.ZodTypeAny, {
|
|
58
58
|
variables: Record<string, string | {
|
|
59
59
|
default: string;
|
|
60
60
|
description?: string | undefined;
|
|
61
61
|
}>;
|
|
62
|
-
description?: string | undefined;
|
|
63
62
|
color?: string | undefined;
|
|
63
|
+
description?: string | undefined;
|
|
64
64
|
}, {
|
|
65
65
|
variables: Record<string, string | {
|
|
66
|
-
default?: string | undefined;
|
|
67
66
|
description?: string | undefined;
|
|
67
|
+
default?: string | undefined;
|
|
68
68
|
}>;
|
|
69
|
-
description?: string | undefined;
|
|
70
69
|
color?: string | undefined;
|
|
70
|
+
description?: string | undefined;
|
|
71
71
|
}>>;
|
|
72
72
|
export type XScalarEnvironment = z.infer<typeof xScalarEnvironmentSchema>;
|
|
73
73
|
export type XScalarEnvironments = z.infer<typeof xScalarEnvironmentsSchema>;
|