@scalar/api-client 2.3.17 → 2.3.19

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 (33) hide show
  1. package/CHANGELOG.md +26 -0
  2. package/dist/components/CommandPalette/CommandPaletteImport.vue.js +9 -9
  3. package/dist/components/SideNav/SideHelp.vue.js +1 -1
  4. package/dist/hooks/useClientConfig.d.ts +69 -0
  5. package/dist/hooks/useClientConfig.d.ts.map +1 -0
  6. package/dist/hooks/useClientConfig.js +7 -0
  7. package/dist/layouts/App/create-api-client-app.d.ts +34 -34
  8. package/dist/layouts/Modal/create-api-client-modal.d.ts +68 -68
  9. package/dist/layouts/Web/create-api-client-web.d.ts +34 -34
  10. package/dist/libs/create-client.d.ts +34 -34
  11. package/dist/libs/create-client.d.ts.map +1 -1
  12. package/dist/libs/create-client.js +63 -62
  13. package/dist/libs/hot-keys.d.ts +1 -1
  14. package/dist/store/collections.d.ts +4 -4
  15. package/dist/store/request-example.d.ts +2 -2
  16. package/dist/store/requests.d.ts +4 -4
  17. package/dist/store/security-schemes.d.ts +10 -10
  18. package/dist/store/servers.d.ts +4 -4
  19. package/dist/store/store.d.ts +34 -34
  20. package/dist/store/tags.d.ts +2 -2
  21. package/dist/store/workspace.d.ts +4 -4
  22. package/dist/style.css +1 -1
  23. package/dist/views/Request/RequestRoot.vue.d.ts.map +1 -1
  24. package/dist/views/Request/RequestRoot.vue.js +1 -1
  25. package/dist/views/Request/RequestRoot.vue2.js +67 -66
  26. package/dist/views/Request/RequestSection/RequestBody.vue.js +2 -2
  27. package/dist/views/Request/RequestSection/RequestBody.vue2.js +1 -1
  28. package/dist/views/Request/RequestSection/RequestCodeExample.vue.js +2 -2
  29. package/dist/views/Request/RequestSection/RequestCodeExample.vue2.js +1 -1
  30. package/dist/views/Request/RequestSection/RequestTable.vue.js +2 -2
  31. package/dist/views/Request/RequestSection/RequestTable.vue2.js +5 -5
  32. package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +1 -1
  33. package/package.json +13 -13
@@ -3,11 +3,11 @@ import { type Collection, type SecurityScheme, type SecuritySchemePayload } from
3
3
  /** Create storage entities for security schemes */
4
4
  export declare function createStoreSecuritySchemes(useLocalStorage: boolean): {
5
5
  securitySchemes: Record<string, {
6
+ name: string;
6
7
  type: "apiKey";
7
8
  value: string;
8
9
  uid: string & import("zod").BRAND<"securityScheme">;
9
10
  nameKey: string;
10
- name: string;
11
11
  in: "cookie" | "query" | "header";
12
12
  description?: string | undefined;
13
13
  } | {
@@ -82,11 +82,11 @@ export declare function createStoreSecuritySchemes(useLocalStorage: boolean): {
82
82
  }>;
83
83
  securitySchemeMutators: {
84
84
  add: (item: {
85
+ name: string;
85
86
  type: "apiKey";
86
87
  value: string;
87
88
  uid: string & import("zod").BRAND<"securityScheme">;
88
89
  nameKey: string;
89
- name: string;
90
90
  in: "cookie" | "query" | "header";
91
91
  description?: string | undefined;
92
92
  } | {
@@ -161,11 +161,11 @@ export declare function createStoreSecuritySchemes(useLocalStorage: boolean): {
161
161
  }) => void;
162
162
  delete: (uid: (string & import("zod").BRAND<"securityScheme">) | null | undefined) => void;
163
163
  set: (item: {
164
+ name: string;
164
165
  type: "apiKey";
165
166
  value: string;
166
167
  uid: string & import("zod").BRAND<"securityScheme">;
167
168
  nameKey: string;
168
- name: string;
169
169
  in: "cookie" | "query" | "header";
170
170
  description?: string | undefined;
171
171
  } | {
@@ -239,27 +239,27 @@ export declare function createStoreSecuritySchemes(useLocalStorage: boolean): {
239
239
  'x-default-scopes'?: string | string[] | undefined;
240
240
  }) => void;
241
241
  edit: <P extends "value" | "description" | "type" | "name" | "in" | "uid" | "nameKey" | "scheme" | "bearerFormat" | "openIdConnectUrl" | "x-default-scopes" | "flows" | "password" | "username" | "token" | `x-default-scopes.${number}` | "flows.password" | "flows.implicit" | "flows.clientCredentials" | "flows.authorizationCode" | "flows.password.type" | "flows.password.password" | "flows.password.username" | "flows.password.token" | "flows.password.refreshUrl" | "flows.password.scopes" | "flows.password.selectedScopes" | "flows.password.x-scalar-client-id" | "flows.password.tokenUrl" | "flows.password.clientSecret" | `flows.password.scopes.${string}` | `flows.password.selectedScopes.${number}` | "flows.implicit.type" | "flows.implicit.token" | "flows.implicit.refreshUrl" | "flows.implicit.scopes" | "flows.implicit.selectedScopes" | "flows.implicit.x-scalar-client-id" | `flows.implicit.scopes.${string}` | `flows.implicit.selectedScopes.${number}` | "flows.implicit.authorizationUrl" | "flows.implicit.x-scalar-redirect-uri" | "flows.clientCredentials.type" | "flows.clientCredentials.token" | "flows.clientCredentials.refreshUrl" | "flows.clientCredentials.scopes" | "flows.clientCredentials.selectedScopes" | "flows.clientCredentials.x-scalar-client-id" | "flows.clientCredentials.tokenUrl" | "flows.clientCredentials.clientSecret" | `flows.clientCredentials.scopes.${string}` | `flows.clientCredentials.selectedScopes.${number}` | "flows.authorizationCode.type" | "flows.authorizationCode.token" | "flows.authorizationCode.refreshUrl" | "flows.authorizationCode.scopes" | "flows.authorizationCode.selectedScopes" | "flows.authorizationCode.x-scalar-client-id" | "flows.authorizationCode.tokenUrl" | "flows.authorizationCode.clientSecret" | `flows.authorizationCode.scopes.${string}` | `flows.authorizationCode.selectedScopes.${number}` | "flows.authorizationCode.authorizationUrl" | "flows.authorizationCode.x-scalar-redirect-uri" | "flows.authorizationCode.x-usePkce">(uid: (string & import("zod").BRAND<"securityScheme">) | null | undefined, path: P, value: (P extends "value" | "description" | "type" | "name" | "in" | "uid" | "nameKey" ? {
242
+ name: string;
242
243
  type: "apiKey";
243
244
  value: string;
244
245
  uid: string & import("zod").BRAND<"securityScheme">;
245
246
  nameKey: string;
246
- name: string;
247
247
  in: "cookie" | "query" | "header";
248
248
  description?: string | undefined;
249
249
  }[P] : P extends `${infer K}.${infer R}` ? K extends "value" | "description" | "type" | "name" | "in" | "uid" | "nameKey" ? R extends import("@scalar/object-utils/nested").Path<{
250
+ name: string;
250
251
  type: "apiKey";
251
252
  value: string;
252
253
  uid: string & import("zod").BRAND<"securityScheme">;
253
254
  nameKey: string;
254
- name: string;
255
255
  in: "cookie" | "query" | "header";
256
256
  description?: string | undefined;
257
257
  }[K]> ? import("@scalar/object-utils/nested").PathValue<{
258
+ name: string;
258
259
  type: "apiKey";
259
260
  value: string;
260
261
  uid: string & import("zod").BRAND<"securityScheme">;
261
262
  nameKey: string;
262
- name: string;
263
263
  in: "cookie" | "query" | "header";
264
264
  description?: string | undefined;
265
265
  }[K], R> : never : K extends `${number}` ? never : never : P extends `${number}` ? never : never) | (P extends "description" | "type" | "uid" | "nameKey" | "scheme" | "bearerFormat" | "password" | "username" | "token" ? {
@@ -471,27 +471,27 @@ export declare function createStoreSecuritySchemes(useLocalStorage: boolean): {
471
471
  'x-default-scopes'?: string | string[] | undefined;
472
472
  }[K], R> : never : K extends `${number}` ? never : never : P extends `${number}` ? never : never)) => void;
473
473
  untrackedEdit: <P extends "value" | "description" | "type" | "name" | "in" | "uid" | "nameKey" | "scheme" | "bearerFormat" | "openIdConnectUrl" | "x-default-scopes" | "flows" | "password" | "username" | "token" | `x-default-scopes.${number}` | "flows.password" | "flows.implicit" | "flows.clientCredentials" | "flows.authorizationCode" | "flows.password.type" | "flows.password.password" | "flows.password.username" | "flows.password.token" | "flows.password.refreshUrl" | "flows.password.scopes" | "flows.password.selectedScopes" | "flows.password.x-scalar-client-id" | "flows.password.tokenUrl" | "flows.password.clientSecret" | `flows.password.scopes.${string}` | `flows.password.selectedScopes.${number}` | "flows.implicit.type" | "flows.implicit.token" | "flows.implicit.refreshUrl" | "flows.implicit.scopes" | "flows.implicit.selectedScopes" | "flows.implicit.x-scalar-client-id" | `flows.implicit.scopes.${string}` | `flows.implicit.selectedScopes.${number}` | "flows.implicit.authorizationUrl" | "flows.implicit.x-scalar-redirect-uri" | "flows.clientCredentials.type" | "flows.clientCredentials.token" | "flows.clientCredentials.refreshUrl" | "flows.clientCredentials.scopes" | "flows.clientCredentials.selectedScopes" | "flows.clientCredentials.x-scalar-client-id" | "flows.clientCredentials.tokenUrl" | "flows.clientCredentials.clientSecret" | `flows.clientCredentials.scopes.${string}` | `flows.clientCredentials.selectedScopes.${number}` | "flows.authorizationCode.type" | "flows.authorizationCode.token" | "flows.authorizationCode.refreshUrl" | "flows.authorizationCode.scopes" | "flows.authorizationCode.selectedScopes" | "flows.authorizationCode.x-scalar-client-id" | "flows.authorizationCode.tokenUrl" | "flows.authorizationCode.clientSecret" | `flows.authorizationCode.scopes.${string}` | `flows.authorizationCode.selectedScopes.${number}` | "flows.authorizationCode.authorizationUrl" | "flows.authorizationCode.x-scalar-redirect-uri" | "flows.authorizationCode.x-usePkce">(uid: string & import("zod").BRAND<"securityScheme">, path: P, value: (P extends "value" | "description" | "type" | "name" | "in" | "uid" | "nameKey" ? {
474
+ name: string;
474
475
  type: "apiKey";
475
476
  value: string;
476
477
  uid: string & import("zod").BRAND<"securityScheme">;
477
478
  nameKey: string;
478
- name: string;
479
479
  in: "cookie" | "query" | "header";
480
480
  description?: string | undefined;
481
481
  }[P] : P extends `${infer K}.${infer R}` ? K extends "value" | "description" | "type" | "name" | "in" | "uid" | "nameKey" ? R extends import("@scalar/object-utils/nested").Path<{
482
+ name: string;
482
483
  type: "apiKey";
483
484
  value: string;
484
485
  uid: string & import("zod").BRAND<"securityScheme">;
485
486
  nameKey: string;
486
- name: string;
487
487
  in: "cookie" | "query" | "header";
488
488
  description?: string | undefined;
489
489
  }[K]> ? import("@scalar/object-utils/nested").PathValue<{
490
+ name: string;
490
491
  type: "apiKey";
491
492
  value: string;
492
493
  uid: string & import("zod").BRAND<"securityScheme">;
493
494
  nameKey: string;
494
- name: string;
495
495
  in: "cookie" | "query" | "header";
496
496
  description?: string | undefined;
497
497
  }[K], R> : never : K extends `${number}` ? never : never : P extends `${number}` ? never : never) | (P extends "description" | "type" | "uid" | "nameKey" | "scheme" | "bearerFormat" | "password" | "username" | "token" ? {
@@ -710,11 +710,11 @@ export declare function createStoreSecuritySchemes(useLocalStorage: boolean): {
710
710
  /** Extended mutators and data for security schemas */
711
711
  export declare function extendedSecurityDataFactory({ securitySchemeMutators, collectionMutators, collections, requests, requestMutators, }: StoreContext): {
712
712
  addSecurityScheme: (payload: SecuritySchemePayload, collectionUid: Collection["uid"]) => {
713
+ name: string;
713
714
  type: "apiKey";
714
715
  value: string;
715
716
  uid: string & import("zod").BRAND<"securityScheme">;
716
717
  nameKey: string;
717
- name: string;
718
718
  in: "cookie" | "query" | "header";
719
719
  description?: string | undefined;
720
720
  } | {
@@ -37,7 +37,7 @@ export declare function createStoreServers(useLocalStorage: boolean): {
37
37
  enum?: string[] | undefined;
38
38
  }> | undefined;
39
39
  }) => void;
40
- edit: <P extends "description" | "uid" | "url" | "variables" | `variables.${string}`>(uid: (string & import("zod").BRAND<"server">) | null | undefined, path: P, value: P extends "description" | "uid" | "url" | "variables" ? {
40
+ edit: <P extends "url" | "description" | "uid" | "variables" | `variables.${string}`>(uid: (string & import("zod").BRAND<"server">) | null | undefined, path: P, value: P extends "url" | "description" | "uid" | "variables" ? {
41
41
  uid: string & import("zod").BRAND<"server">;
42
42
  url: string;
43
43
  description?: string | undefined;
@@ -47,7 +47,7 @@ export declare function createStoreServers(useLocalStorage: boolean): {
47
47
  default?: string | undefined;
48
48
  enum?: string[] | undefined;
49
49
  }> | undefined;
50
- }[P] : P extends `${infer K}.${infer R}` ? K extends "description" | "uid" | "url" | "variables" ? R extends import("@scalar/object-utils/nested").Path<{
50
+ }[P] : P extends `${infer K}.${infer R}` ? K extends "url" | "description" | "uid" | "variables" ? R extends import("@scalar/object-utils/nested").Path<{
51
51
  uid: string & import("zod").BRAND<"server">;
52
52
  url: string;
53
53
  description?: string | undefined;
@@ -68,7 +68,7 @@ export declare function createStoreServers(useLocalStorage: boolean): {
68
68
  enum?: string[] | undefined;
69
69
  }> | undefined;
70
70
  }[K], R> : never : K extends `${number}` ? never : never : P extends `${number}` ? never : never) => void;
71
- untrackedEdit: <P extends "description" | "uid" | "url" | "variables" | `variables.${string}`>(uid: string & import("zod").BRAND<"server">, path: P, value: P extends "description" | "uid" | "url" | "variables" ? {
71
+ untrackedEdit: <P extends "url" | "description" | "uid" | "variables" | `variables.${string}`>(uid: string & import("zod").BRAND<"server">, path: P, value: P extends "url" | "description" | "uid" | "variables" ? {
72
72
  uid: string & import("zod").BRAND<"server">;
73
73
  url: string;
74
74
  description?: string | undefined;
@@ -78,7 +78,7 @@ export declare function createStoreServers(useLocalStorage: boolean): {
78
78
  default?: string | undefined;
79
79
  enum?: string[] | undefined;
80
80
  }> | undefined;
81
- }[P] : P extends `${infer K}.${infer R}` ? K extends "description" | "uid" | "url" | "variables" ? R extends import("@scalar/object-utils/nested").Path<{
81
+ }[P] : P extends `${infer K}.${infer R}` ? K extends "url" | "description" | "uid" | "variables" ? R extends import("@scalar/object-utils/nested").Path<{
82
82
  uid: string & import("zod").BRAND<"server">;
83
83
  url: string;
84
84
  description?: string | undefined;