@scalar/oas-utils 0.2.121 → 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.
Files changed (202) hide show
  1. package/CHANGELOG.md +20 -0
  2. package/dist/entities/cookie/cookie.d.ts +4 -4
  3. package/dist/entities/cookie/cookie.js +1 -1
  4. package/dist/entities/cookie/index.d.ts +1 -1
  5. package/dist/entities/cookie/index.d.ts.map +1 -1
  6. package/dist/entities/environment/environment.d.ts +2 -2
  7. package/dist/entities/environment/environment.js +1 -1
  8. package/dist/entities/environment/index.d.ts +1 -1
  9. package/dist/entities/environment/index.d.ts.map +1 -1
  10. package/dist/entities/hotkeys/index.d.ts +1 -1
  11. package/dist/entities/hotkeys/index.d.ts.map +1 -1
  12. package/dist/entities/shared/index.d.ts +1 -1
  13. package/dist/entities/shared/index.d.ts.map +1 -1
  14. package/dist/entities/shared/index.js +1 -1
  15. package/dist/entities/shared/utility.d.ts +0 -16
  16. package/dist/entities/shared/utility.d.ts.map +1 -1
  17. package/dist/entities/shared/utility.js +1 -8
  18. package/dist/entities/spec/collection.d.ts +24 -24
  19. package/dist/entities/spec/collection.d.ts.map +1 -1
  20. package/dist/entities/spec/collection.js +3 -2
  21. package/dist/entities/spec/index.d.ts +10 -11
  22. package/dist/entities/spec/index.d.ts.map +1 -1
  23. package/dist/entities/spec/index.js +8 -8
  24. package/dist/entities/spec/operation.d.ts +23 -23
  25. package/dist/entities/spec/operation.d.ts.map +1 -1
  26. package/dist/entities/spec/parameters.d.ts +6 -6
  27. package/dist/entities/spec/request-examples.d.ts +244 -244
  28. package/dist/entities/spec/request-examples.d.ts.map +1 -1
  29. package/dist/entities/spec/request-examples.js +6 -71
  30. package/dist/entities/spec/requests.d.ts +47 -47
  31. package/dist/entities/spec/requests.d.ts.map +1 -1
  32. package/dist/entities/spec/requests.js +3 -2
  33. package/dist/entities/spec/security.d.ts +39 -39
  34. package/dist/entities/spec/security.d.ts.map +1 -1
  35. package/dist/entities/spec/security.js +4 -4
  36. package/dist/entities/spec/server.d.ts +99 -28
  37. package/dist/entities/spec/server.d.ts.map +1 -1
  38. package/dist/entities/spec/server.js +1 -1
  39. package/dist/entities/spec/spec-objects.d.ts +3 -3
  40. package/dist/entities/spec/spec-objects.js +1 -1
  41. package/dist/entities/spec/x-scalar-environments.d.ts +9 -9
  42. package/dist/entities/spec/x-scalar-secrets.d.ts +4 -4
  43. package/dist/entities/workspace/index.d.ts +1 -1
  44. package/dist/entities/workspace/index.d.ts.map +1 -1
  45. package/dist/entities/workspace/workspace.d.ts +18 -18
  46. package/dist/entities/workspace/workspace.js +1 -1
  47. package/dist/helpers/{createHash.d.ts → create-hash.d.ts} +1 -1
  48. package/dist/helpers/create-hash.d.ts.map +1 -0
  49. package/dist/helpers/ensure-protocol.js +1 -1
  50. package/dist/helpers/{fetchSpecFromUrl.d.ts → fetch-spec-from-url.d.ts} +1 -1
  51. package/dist/helpers/fetch-spec-from-url.d.ts.map +1 -0
  52. package/dist/helpers/{fetchSpecFromUrl.js → fetch-spec-from-url.js} +1 -1
  53. package/dist/helpers/{fetchWithProxyFallback.d.ts → fetch-with-proxy-fallback.d.ts} +1 -1
  54. package/dist/helpers/fetch-with-proxy-fallback.d.ts.map +1 -0
  55. package/dist/helpers/{fetchWithProxyFallback.js → fetch-with-proxy-fallback.js} +1 -1
  56. package/dist/helpers/find-variables.d.ts +5 -0
  57. package/dist/helpers/find-variables.d.ts.map +1 -0
  58. package/dist/helpers/{findVariables.js → find-variables.js} +1 -1
  59. package/dist/helpers/{httpMethods.d.ts → http-methods.d.ts} +2 -2
  60. package/dist/helpers/http-methods.d.ts.map +1 -0
  61. package/dist/helpers/{httpStatusCodes.d.ts → http-status-codes.d.ts} +1 -1
  62. package/dist/helpers/http-status-codes.d.ts.map +1 -0
  63. package/dist/helpers/index.d.ts +27 -26
  64. package/dist/helpers/index.d.ts.map +1 -1
  65. package/dist/helpers/index.js +21 -20
  66. package/dist/helpers/{isLocalUrl.d.ts → is-local-url.d.ts} +1 -1
  67. package/dist/helpers/is-local-url.d.ts.map +1 -0
  68. package/dist/helpers/{isValidUrl.d.ts → is-valid-url.d.ts} +1 -1
  69. package/dist/helpers/is-valid-url.d.ts.map +1 -0
  70. package/dist/helpers/{iterateTitle.d.ts → iterate-title.d.ts} +1 -1
  71. package/dist/helpers/iterate-title.d.ts.map +1 -0
  72. package/dist/helpers/{makeUrlAbsolute.d.ts → make-url-absolute.d.ts} +1 -1
  73. package/dist/helpers/make-url-absolute.d.ts.map +1 -0
  74. package/dist/helpers/merge-urls.d.ts.map +1 -1
  75. package/dist/helpers/merge-urls.js +2 -2
  76. package/dist/helpers/{normalizeMimeTypeObject.d.ts → normalize-mime-type-object.d.ts} +1 -1
  77. package/dist/helpers/normalize-mime-type-object.d.ts.map +1 -0
  78. package/dist/helpers/{normalizeMimeTypeObject.js → normalize-mime-type-object.js} +1 -1
  79. package/dist/helpers/{normalizeMimeType.d.ts → normalize-mime-type.d.ts} +1 -1
  80. package/dist/helpers/normalize-mime-type.d.ts.map +1 -0
  81. package/dist/helpers/parse.js +1 -1
  82. package/dist/helpers/{prettyPrintJson.d.ts → pretty-print-json.d.ts} +1 -1
  83. package/dist/helpers/pretty-print-json.d.ts.map +1 -0
  84. package/dist/helpers/{redirectToProxy.d.ts → redirect-to-proxy.d.ts} +1 -1
  85. package/dist/helpers/redirect-to-proxy.d.ts.map +1 -0
  86. package/dist/helpers/{redirectToProxy.js → redirect-to-proxy.js} +2 -2
  87. package/dist/helpers/{regexHelpers.d.ts → regex-helpers.d.ts} +1 -1
  88. package/dist/helpers/regex-helpers.d.ts.map +1 -0
  89. package/dist/helpers/{replaceVariables.d.ts → replace-variables.d.ts} +1 -1
  90. package/dist/helpers/replace-variables.d.ts.map +1 -0
  91. package/dist/helpers/{shouldIgnoreEntity.d.ts → should-ignore-entity.d.ts} +3 -2
  92. package/dist/helpers/should-ignore-entity.d.ts.map +1 -0
  93. package/dist/helpers/{ssrState.d.ts → ssr-state.d.ts} +1 -1
  94. package/dist/helpers/ssr-state.d.ts.map +1 -0
  95. package/dist/helpers/string.d.ts.map +1 -1
  96. package/dist/helpers/string.js +1 -1
  97. package/dist/migrations/index.d.ts +3 -3
  98. package/dist/migrations/index.d.ts.map +1 -1
  99. package/dist/migrations/local-storage.d.ts +1 -1
  100. package/dist/migrations/local-storage.d.ts.map +1 -1
  101. package/dist/migrations/migrator.d.ts +1 -1
  102. package/dist/migrations/migrator.d.ts.map +1 -1
  103. package/dist/migrations/semver.js +1 -1
  104. package/dist/migrations/v-2.1.0/migration.d.ts +2 -2
  105. package/dist/migrations/v-2.1.0/migration.d.ts.map +1 -1
  106. package/dist/migrations/v-2.1.0/migration.js +1 -1
  107. package/dist/migrations/v-2.2.0/migration.d.ts +2 -2
  108. package/dist/migrations/v-2.2.0/migration.d.ts.map +1 -1
  109. package/dist/migrations/v-2.3.0/migration.d.ts +2 -2
  110. package/dist/migrations/v-2.3.0/migration.d.ts.map +1 -1
  111. package/dist/migrations/v-2.4.0/migration.d.ts +2 -2
  112. package/dist/migrations/v-2.4.0/migration.d.ts.map +1 -1
  113. package/dist/migrations/v-2.5.0/migration.d.ts +2 -2
  114. package/dist/migrations/v-2.5.0/migration.d.ts.map +1 -1
  115. package/dist/migrations/v-2.5.0/migration.js +2 -3
  116. package/dist/migrations/v-2.5.0/types.generated.d.ts +9 -4
  117. package/dist/migrations/v-2.5.0/types.generated.d.ts.map +1 -1
  118. package/dist/spec-getters/{getExampleFromSchema.d.ts → get-example-from-schema.d.ts} +1 -1
  119. package/dist/spec-getters/get-example-from-schema.d.ts.map +1 -0
  120. package/dist/spec-getters/{getParametersFromOperation.d.ts → get-parameters-from-operation.d.ts} +1 -1
  121. package/dist/spec-getters/get-parameters-from-operation.d.ts.map +1 -0
  122. package/dist/spec-getters/{getParametersFromOperation.js → get-parameters-from-operation.js} +1 -1
  123. package/dist/spec-getters/{getRequestBodyFromOperation.d.ts → get-request-body-from-operation.d.ts} +2 -2
  124. package/dist/spec-getters/get-request-body-from-operation.d.ts.map +1 -0
  125. package/dist/spec-getters/{getRequestBodyFromOperation.js → get-request-body-from-operation.js} +7 -7
  126. package/dist/spec-getters/{getServerVariableExamples.d.ts → get-server-variable-examples.d.ts} +2 -2
  127. package/dist/spec-getters/get-server-variable-examples.d.ts.map +1 -0
  128. package/dist/spec-getters/index.d.ts +4 -4
  129. package/dist/spec-getters/index.d.ts.map +1 -1
  130. package/dist/spec-getters/index.js +4 -4
  131. package/dist/transforms/import-spec.d.ts +7 -3
  132. package/dist/transforms/import-spec.d.ts.map +1 -1
  133. package/dist/transforms/import-spec.js +35 -26
  134. package/dist/transforms/index.d.ts +1 -1
  135. package/dist/transforms/index.d.ts.map +1 -1
  136. package/dist/transforms/index.js +1 -1
  137. package/package.json +7 -45
  138. package/dist/diff/diff.d.ts +0 -13
  139. package/dist/diff/diff.d.ts.map +0 -1
  140. package/dist/diff/diff.js +0 -41
  141. package/dist/diff/index.d.ts +0 -2
  142. package/dist/diff/index.d.ts.map +0 -1
  143. package/dist/diff/index.js +0 -1
  144. package/dist/entities/index.d.ts +0 -2
  145. package/dist/entities/index.d.ts.map +0 -1
  146. package/dist/entities/index.js +0 -1
  147. package/dist/helpers/createHash.d.ts.map +0 -1
  148. package/dist/helpers/fetchSpecFromUrl.d.ts.map +0 -1
  149. package/dist/helpers/fetchWithProxyFallback.d.ts.map +0 -1
  150. package/dist/helpers/findVariables.d.ts +0 -5
  151. package/dist/helpers/findVariables.d.ts.map +0 -1
  152. package/dist/helpers/httpMethods.d.ts.map +0 -1
  153. package/dist/helpers/httpStatusCodes.d.ts.map +0 -1
  154. package/dist/helpers/isLocalUrl.d.ts.map +0 -1
  155. package/dist/helpers/isValidUrl.d.ts.map +0 -1
  156. package/dist/helpers/iterateTitle.d.ts.map +0 -1
  157. package/dist/helpers/makeUrlAbsolute.d.ts.map +0 -1
  158. package/dist/helpers/normalizeMimeType.d.ts.map +0 -1
  159. package/dist/helpers/normalizeMimeTypeObject.d.ts.map +0 -1
  160. package/dist/helpers/prettyPrintJson.d.ts.map +0 -1
  161. package/dist/helpers/redirectToProxy.d.ts.map +0 -1
  162. package/dist/helpers/regexHelpers.d.ts.map +0 -1
  163. package/dist/helpers/replaceVariables.d.ts.map +0 -1
  164. package/dist/helpers/shouldIgnoreEntity.d.ts.map +0 -1
  165. package/dist/helpers/ssrState.d.ts.map +0 -1
  166. package/dist/migrations/v-0.0.0/index.d.ts +0 -2
  167. package/dist/migrations/v-0.0.0/index.d.ts.map +0 -1
  168. package/dist/migrations/v-0.0.0/index.js +0 -1
  169. package/dist/migrations/v-2.1.0/index.d.ts +0 -3
  170. package/dist/migrations/v-2.1.0/index.d.ts.map +0 -1
  171. package/dist/migrations/v-2.1.0/index.js +0 -1
  172. package/dist/migrations/v-2.2.0/index.d.ts +0 -3
  173. package/dist/migrations/v-2.2.0/index.d.ts.map +0 -1
  174. package/dist/migrations/v-2.2.0/index.js +0 -1
  175. package/dist/migrations/v-2.3.0/index.d.ts +0 -3
  176. package/dist/migrations/v-2.3.0/index.d.ts.map +0 -1
  177. package/dist/migrations/v-2.3.0/index.js +0 -1
  178. package/dist/migrations/v-2.4.0/index.d.ts +0 -3
  179. package/dist/migrations/v-2.4.0/index.d.ts.map +0 -1
  180. package/dist/migrations/v-2.4.0/index.js +0 -1
  181. package/dist/migrations/v-2.5.0/index.d.ts +0 -3
  182. package/dist/migrations/v-2.5.0/index.d.ts.map +0 -1
  183. package/dist/migrations/v-2.5.0/index.js +0 -1
  184. package/dist/spec-getters/getExampleFromSchema.d.ts.map +0 -1
  185. package/dist/spec-getters/getParametersFromOperation.d.ts.map +0 -1
  186. package/dist/spec-getters/getRequestBodyFromOperation.d.ts.map +0 -1
  187. package/dist/spec-getters/getServerVariableExamples.d.ts.map +0 -1
  188. /package/dist/helpers/{createHash.js → create-hash.js} +0 -0
  189. /package/dist/helpers/{httpMethods.js → http-methods.js} +0 -0
  190. /package/dist/helpers/{httpStatusCodes.js → http-status-codes.js} +0 -0
  191. /package/dist/helpers/{isLocalUrl.js → is-local-url.js} +0 -0
  192. /package/dist/helpers/{isValidUrl.js → is-valid-url.js} +0 -0
  193. /package/dist/helpers/{iterateTitle.js → iterate-title.js} +0 -0
  194. /package/dist/helpers/{makeUrlAbsolute.js → make-url-absolute.js} +0 -0
  195. /package/dist/helpers/{normalizeMimeType.js → normalize-mime-type.js} +0 -0
  196. /package/dist/helpers/{prettyPrintJson.js → pretty-print-json.js} +0 -0
  197. /package/dist/helpers/{regexHelpers.js → regex-helpers.js} +0 -0
  198. /package/dist/helpers/{replaceVariables.js → replace-variables.js} +0 -0
  199. /package/dist/helpers/{shouldIgnoreEntity.js → should-ignore-entity.js} +0 -0
  200. /package/dist/helpers/{ssrState.js → ssr-state.js} +0 -0
  201. /package/dist/spec-getters/{getExampleFromSchema.js → get-example-from-schema.js} +0 -0
  202. /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
- nameKey: string;
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
- nameKey: string;
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;AAuBvB,eAAO,MAAM,sBAAsB,wCAAyC,CAAA;AAc5E,eAAO,MAAM,oBAAoB;;;;IAV/B,8EAA8E;;IAE9E,6FAA6F;;;;IAb7F,0EAA0E;;;;;;;;;;;;;;;;;;;;EAqBsC,CAAA;AAClH,MAAM,MAAM,oBAAoB,GAAG,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;;;YAbrB;;;eAGG;;YAEH;;;eAGG;;;YAGH,oEAAoE;;YAEpE,qBAAqB;;;;;YAwCf;;;;eAIG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAlJT,0EAA0E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IA2M1E,CAAA;AAEF;;;;GAIG;AACH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAA;AACjE,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAA"}
@@ -1,5 +1,5 @@
1
1
  import { z } from 'zod';
2
- import { nanoidSchema } from '../shared/utility.js';
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
- const oasSecurityRequirementSchema = z.record(z.string(), z.array(z.string()).optional().default([]));
163
+ z.record(z.string(), z.array(z.string()).optional().default([]));
164
164
  /** OAS Compliant security schemes */
165
- const oasSecuritySchemeSchema = z.union([
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 { oasSecurityRequirementSchema, oasSecuritySchemeSchema, pkceOptions, securityApiKeySchema, securityHttpSchema, securityOauthSchema, securityOpenIdSchema, securitySchemeApiKeyIn, securitySchemeSchema };
179
+ export { pkceOptions, securityApiKeySchema, securityHttpSchema, securityOauthSchema, securityOpenIdSchema, securitySchemeApiKeyIn, securitySchemeSchema };
@@ -1,5 +1,4 @@
1
- import type { OpenAPIV3_1 } from '@scalar/openapi-types';
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, ZodSchema<Omit<OpenAPIV3_1.ServerVariableObject, "enum"> & {
55
- enum?: [string, ...string[]];
56
- value?: string;
57
- }, z.ZodTypeDef, Omit<OpenAPIV3_1.ServerVariableObject, "enum"> & {
58
- enum?: [string, ...string[]];
59
- value?: string;
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, Omit<OpenAPIV3_1.ServerVariableObject, "enum"> & {
65
- enum?: [string, ...string[]];
66
- value?: string;
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, Omit<OpenAPIV3_1.ServerVariableObject, "enum"> & {
72
- enum?: [string, ...string[]];
73
- value?: string;
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, ZodSchema<Omit<OpenAPIV3_1.ServerVariableObject, "enum"> & {
90
- enum?: [string, ...string[]];
91
- value?: string;
92
- }, z.ZodTypeDef, Omit<OpenAPIV3_1.ServerVariableObject, "enum"> & {
93
- enum?: [string, ...string[]];
94
- value?: string;
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, Omit<OpenAPIV3_1.ServerVariableObject, "enum"> & {
103
- enum?: [string, ...string[]];
104
- value?: string;
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, Omit<OpenAPIV3_1.ServerVariableObject, "enum"> & {
111
- enum?: [string, ...string[]];
112
- value?: string;
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,KAAK,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAA;AACxD,OAAO,EAAE,KAAK,SAAS,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvC;;;;;;GAMG;AACH,eAAO,MAAM,uBAAuB;IAClC;;OAEG;;IAEH;;;;OAIG;;IAEH;;OAEG;;;;;;;;;;EAEH,CAAA;AA2BF;;;;;;GAMG;AACH,eAAO,MAAM,eAAe;IAC1B;;;;OAIG;;IAEH;;;OAGG;;IAEH,oHAAoH;;eAxB3G,CAAC,MAAM,EAAE,GAAG,MAAM,EAAE,CAAC;gBACpB,MAAM;;eADP,CAAC,MAAM,EAAE,GAAG,MAAM,EAAE,CAAC;gBACpB,MAAM;;;;;;eADP,CAAC,MAAM,EAAE,GAAG,MAAM,EAAE,CAAC;gBACpB,MAAM;;;;;;eADP,CAAC,MAAM,EAAE,GAAG,MAAM,EAAE,CAAC;gBACpB,MAAM;;EAyB8B,CAAA;AAEhD,eAAO,MAAM,YAAY;IAfvB;;;;OAIG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,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAA"}
@@ -1,4 +1,4 @@
1
- import { nanoidSchema } from '../shared/utility.js';
1
+ import { nanoidSchema } from '@scalar/types/utils';
2
2
  import { z } from 'zod';
3
3
 
4
4
  /**
@@ -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;
@@ -1,4 +1,4 @@
1
- import { nanoidSchema } from '../shared/utility.js';
1
+ import { nanoidSchema } from '@scalar/types/utils';
2
2
  import { z } from 'zod';
3
3
 
4
4
  /**
@@ -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>;