@scalar/api-client 2.1.32 → 2.1.34
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 +28 -0
- package/dist/components/CodeInput/CodeInput.vue.js +2 -2
- package/dist/components/ScalarHotkey.vue.d.ts +5 -6
- package/dist/components/ScalarHotkey.vue.d.ts.map +1 -1
- package/dist/components/ScalarHotkey.vue.js +9 -18
- package/dist/components/Sidebar/SidebarButton.vue.d.ts +4 -0
- package/dist/components/Sidebar/SidebarButton.vue.d.ts.map +1 -1
- package/dist/components/Sidebar/SidebarButton.vue.js +19 -17
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -8
- package/dist/layouts/App/ApiClientApp.vue.d.ts.map +1 -1
- package/dist/layouts/App/ApiClientApp.vue.js +35 -29
- package/dist/layouts/App/create-api-client-app.d.ts +257 -45
- package/dist/layouts/App/create-api-client-app.d.ts.map +1 -1
- package/dist/layouts/App/create-api-client-app.js +10 -10
- package/dist/layouts/App/hotkeys.js +1 -1
- package/dist/layouts/Modal/create-api-client-modal.d.ts +514 -90
- package/dist/layouts/Modal/create-api-client-modal.d.ts.map +1 -1
- package/dist/layouts/Modal/create-api-client-modal.js +24 -22
- package/dist/layouts/Web/ApiClientWeb.vue.d.ts.map +1 -1
- package/dist/layouts/Web/ApiClientWeb.vue.js +33 -27
- package/dist/layouts/Web/create-api-client-web.d.ts +258 -46
- package/dist/layouts/Web/create-api-client-web.d.ts.map +1 -1
- package/dist/layouts/Web/create-api-client-web.js +9 -9
- package/dist/libs/create-client.d.ts +280 -50
- package/dist/libs/create-client.d.ts.map +1 -1
- package/dist/libs/create-client.js +25 -24
- package/dist/libs/hot-keys.d.ts +1 -1
- package/dist/libs/local-storage.d.ts +2 -2
- package/dist/libs/local-storage.d.ts.map +1 -1
- package/dist/libs/send-request.d.ts +2 -1
- package/dist/libs/send-request.d.ts.map +1 -1
- package/dist/libs/send-request.js +98 -97
- package/dist/router.d.ts +5 -5
- package/dist/router.d.ts.map +1 -1
- package/dist/router.js +32 -32
- package/dist/store/collections.d.ts +14 -4
- package/dist/store/collections.d.ts.map +1 -1
- package/dist/store/events.d.ts +1 -1
- package/dist/store/import-spec.d.ts +16 -31
- package/dist/store/import-spec.d.ts.map +1 -1
- package/dist/store/import-spec.js +43 -56
- package/dist/store/requests.d.ts +14 -14
- package/dist/store/store.d.ts +514 -90
- package/dist/store/store.d.ts.map +1 -1
- package/dist/store/store.js +43 -43
- package/dist/store/workspace.d.ts +10 -10
- package/dist/store/workspace.d.ts.map +1 -1
- package/dist/style.css +1 -1
- package/dist/views/Cookies/Cookies.vue.d.ts +5 -1
- package/dist/views/Cookies/Cookies.vue.d.ts.map +1 -1
- package/dist/views/Cookies/Cookies.vue2.js +64 -55
- package/dist/views/Environment/Environment.vue.d.ts +5 -1
- package/dist/views/Environment/Environment.vue.d.ts.map +1 -1
- package/dist/views/Environment/Environment.vue2.js +75 -66
- package/dist/views/Request/Request.vue.d.ts.map +1 -1
- package/dist/views/Request/Request.vue.js +1 -1
- package/dist/views/Request/Request.vue2.js +98 -91
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts +2 -0
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue.js +2 -2
- package/dist/views/Request/RequestSection/RequestAuth/RequestAuth.vue2.js +104 -111
- package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.d.ts +5 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestAuth/RequestExampleAuth.vue.js +37 -34
- package/dist/views/Request/RequestSection/RequestSection.vue.d.ts +5 -1
- package/dist/views/Request/RequestSection/RequestSection.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSection/RequestSection.vue.js +43 -37
- package/dist/views/Request/RequestSidebar.vue.d.ts.map +1 -1
- package/dist/views/Request/RequestSidebar.vue.js +4 -4
- package/dist/views/Request/RequestSidebar.vue2.js +43 -42
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.d.ts.map +1 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue.js +1 -1
- package/dist/views/Request/ResponseSection/ResponseEmpty.vue2.js +27 -26
- package/dist/views/Settings/SettingsGeneral.vue.js +3 -3
- package/dist/views/Settings/SettingsGeneralMode.vue.js +3 -3
- package/package.json +9 -9
package/dist/router.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { createRouter as
|
|
1
|
+
import { createRouter as r, createWebHistory as u, createWebHashHistory as i, createMemoryHistory as m } from "vue-router";
|
|
2
2
|
var f = /* @__PURE__ */ ((e) => (e.Request = "request", e.Examples = "examples", e.Cookies = "cookies", e.Collection = "collection", e.Schema = "schema", e.Environment = "environment", e.Servers = "servers", e.Workspace = "workspace", e.Settings = "settings", e))(f || {});
|
|
3
|
-
const
|
|
3
|
+
const c = [
|
|
4
4
|
{
|
|
5
5
|
path: "",
|
|
6
6
|
redirect: (e) => `${e.fullPath.replace(/\/$/, "")}/request/default`
|
|
@@ -30,21 +30,21 @@ const n = [
|
|
|
30
30
|
},
|
|
31
31
|
{
|
|
32
32
|
path: "/workspace/:workspace",
|
|
33
|
-
children:
|
|
33
|
+
children: c
|
|
34
34
|
}
|
|
35
|
-
],
|
|
35
|
+
], n = [
|
|
36
36
|
{
|
|
37
37
|
path: "/",
|
|
38
|
-
redirect:
|
|
38
|
+
redirect: o
|
|
39
39
|
},
|
|
40
40
|
{
|
|
41
41
|
path: "/workspace",
|
|
42
|
-
redirect:
|
|
42
|
+
redirect: o
|
|
43
43
|
},
|
|
44
44
|
{
|
|
45
45
|
path: "/workspace/:workspace",
|
|
46
46
|
children: [
|
|
47
|
-
...
|
|
47
|
+
...c,
|
|
48
48
|
// {
|
|
49
49
|
// path: 'collection',
|
|
50
50
|
// redirect: (to) =>
|
|
@@ -111,41 +111,41 @@ const n = [
|
|
|
111
111
|
}
|
|
112
112
|
]
|
|
113
113
|
}
|
|
114
|
-
],
|
|
115
|
-
history:
|
|
116
|
-
routes:
|
|
117
|
-
}),
|
|
114
|
+
], k = () => r({
|
|
115
|
+
history: u(),
|
|
116
|
+
routes: n
|
|
117
|
+
}), d = () => r({
|
|
118
118
|
history: i(),
|
|
119
|
-
routes:
|
|
120
|
-
}),
|
|
119
|
+
routes: n
|
|
120
|
+
}), v = () => r({
|
|
121
121
|
history: m(),
|
|
122
122
|
routes: h
|
|
123
|
-
}),
|
|
124
|
-
function
|
|
125
|
-
const
|
|
126
|
-
|
|
123
|
+
}), p = "activeWorkspace";
|
|
124
|
+
function w(e) {
|
|
125
|
+
const t = e.params.workspace;
|
|
126
|
+
t && localStorage.setItem(p, `${t}`);
|
|
127
127
|
}
|
|
128
|
-
function
|
|
129
|
-
return `/workspace/${localStorage.getItem(
|
|
128
|
+
function o() {
|
|
129
|
+
return `/workspace/${localStorage.getItem(p) ?? "default"}/request/default`;
|
|
130
130
|
}
|
|
131
|
-
function
|
|
132
|
-
var
|
|
133
|
-
|
|
134
|
-
!
|
|
135
|
-
|
|
131
|
+
function q(e, t, l) {
|
|
132
|
+
var a, s;
|
|
133
|
+
e.currentRoute.value && // If the item is missing then we know the UID is no longer in use and redirect to the default
|
|
134
|
+
!l && ((a = e.currentRoute.value) != null && a.params[t]) && ((s = e.currentRoute.value) == null ? void 0 : s.params[t]) !== "default" && // We only redirect if the key is missing for the matching route
|
|
135
|
+
e.currentRoute.value.path.includes(t) && e.push({
|
|
136
136
|
params: {
|
|
137
|
-
...
|
|
138
|
-
[
|
|
137
|
+
...e.currentRoute.value.params,
|
|
138
|
+
[t]: "default"
|
|
139
139
|
}
|
|
140
140
|
});
|
|
141
141
|
}
|
|
142
142
|
export {
|
|
143
143
|
f as PathId,
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
144
|
+
v as createModalRouter,
|
|
145
|
+
d as createWebHashRouter,
|
|
146
|
+
k as createWebHistoryRouter,
|
|
147
|
+
q as fallbackMissingParams,
|
|
147
148
|
h as modalRoutes,
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
v as saveWorkspace
|
|
149
|
+
o as redirectToDefaultWorkspace,
|
|
150
|
+
w as saveWorkspace
|
|
151
151
|
};
|
|
@@ -11,6 +11,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
11
11
|
security: Record<string, string[]>[];
|
|
12
12
|
'x-scalar-icon': string;
|
|
13
13
|
securitySchemes: string[];
|
|
14
|
+
selectedSecuritySchemeUids: string[];
|
|
14
15
|
selectedServerUid: string;
|
|
15
16
|
servers: string[];
|
|
16
17
|
requests: string[];
|
|
@@ -79,6 +80,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
79
80
|
security: Record<string, string[]>[];
|
|
80
81
|
'x-scalar-icon': string;
|
|
81
82
|
securitySchemes: string[];
|
|
83
|
+
selectedSecuritySchemeUids: string[];
|
|
82
84
|
selectedServerUid: string;
|
|
83
85
|
servers: string[];
|
|
84
86
|
requests: string[];
|
|
@@ -147,6 +149,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
147
149
|
security: Record<string, string[]>[];
|
|
148
150
|
'x-scalar-icon': string;
|
|
149
151
|
securitySchemes: string[];
|
|
152
|
+
selectedSecuritySchemeUids: string[];
|
|
150
153
|
selectedServerUid: string;
|
|
151
154
|
servers: string[];
|
|
152
155
|
requests: string[];
|
|
@@ -206,7 +209,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
206
209
|
webhooks?: Record<string, unknown> | undefined;
|
|
207
210
|
documentUrl?: string | undefined;
|
|
208
211
|
}) => void;
|
|
209
|
-
edit: <P extends "type" | "children" | "info" | "servers" | "uid" | "auth" | "securitySchemes" | "tags" | "requests" | "
|
|
212
|
+
edit: <P extends "type" | "children" | "info" | "servers" | "uid" | "auth" | "securitySchemes" | "selectedSecuritySchemeUids" | "tags" | "requests" | "documentUrl" | "watchForChanges" | "components" | "openapi" | "security" | "externalDocs" | "webhooks" | "jsonSchemaDialect" | "selectedServerUid" | `servers.${number}` | `selectedSecuritySchemeUids.${number}` | `tags.${number}` | `security.${number}` | `security.${number}.${string}` | "externalDocs.url" | "externalDocs.description" | "x-scalar-icon" | "watchForChangesStatus" | `children.${number}` | "info.summary" | "info.title" | "info.description" | "info.termsOfService" | "info.contact" | "info.license" | "info.version" | "info.contact.url" | "info.contact.name" | "info.contact.email" | "info.license.url" | "info.license.name" | "info.license.identifier" | `auth.${string}` | `securitySchemes.${number}` | `requests.${number}` | `components.${string}` | `webhooks.${string}`>(uid: string, path: P, value: P extends "type" | "children" | "info" | "servers" | "uid" | "auth" | "securitySchemes" | "selectedSecuritySchemeUids" | "tags" | "requests" | "documentUrl" | "watchForChanges" | "components" | "openapi" | "security" | "externalDocs" | "webhooks" | "jsonSchemaDialect" | "selectedServerUid" | "x-scalar-icon" | "watchForChangesStatus" ? {
|
|
210
213
|
type: "collection";
|
|
211
214
|
uid: string;
|
|
212
215
|
children: string[];
|
|
@@ -214,6 +217,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
214
217
|
security: Record<string, string[]>[];
|
|
215
218
|
'x-scalar-icon': string;
|
|
216
219
|
securitySchemes: string[];
|
|
220
|
+
selectedSecuritySchemeUids: string[];
|
|
217
221
|
selectedServerUid: string;
|
|
218
222
|
servers: string[];
|
|
219
223
|
requests: string[];
|
|
@@ -272,7 +276,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
272
276
|
components?: Record<string, unknown> | undefined;
|
|
273
277
|
webhooks?: Record<string, unknown> | undefined;
|
|
274
278
|
documentUrl?: string | undefined;
|
|
275
|
-
}[P] : P extends `${infer K}.${infer R}` ? K extends "type" | "children" | "info" | "servers" | "uid" | "auth" | "securitySchemes" | "tags" | "requests" | "
|
|
279
|
+
}[P] : P extends `${infer K}.${infer R}` ? K extends "type" | "children" | "info" | "servers" | "uid" | "auth" | "securitySchemes" | "selectedSecuritySchemeUids" | "tags" | "requests" | "documentUrl" | "watchForChanges" | "components" | "openapi" | "security" | "externalDocs" | "webhooks" | "jsonSchemaDialect" | "selectedServerUid" | "x-scalar-icon" | "watchForChangesStatus" ? R extends import("@scalar/object-utils/nested").Path<{
|
|
276
280
|
type: "collection";
|
|
277
281
|
uid: string;
|
|
278
282
|
children: string[];
|
|
@@ -280,6 +284,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
280
284
|
security: Record<string, string[]>[];
|
|
281
285
|
'x-scalar-icon': string;
|
|
282
286
|
securitySchemes: string[];
|
|
287
|
+
selectedSecuritySchemeUids: string[];
|
|
283
288
|
selectedServerUid: string;
|
|
284
289
|
servers: string[];
|
|
285
290
|
requests: string[];
|
|
@@ -346,6 +351,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
346
351
|
security: Record<string, string[]>[];
|
|
347
352
|
'x-scalar-icon': string;
|
|
348
353
|
securitySchemes: string[];
|
|
354
|
+
selectedSecuritySchemeUids: string[];
|
|
349
355
|
selectedServerUid: string;
|
|
350
356
|
servers: string[];
|
|
351
357
|
requests: string[];
|
|
@@ -405,7 +411,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
405
411
|
webhooks?: Record<string, unknown> | undefined;
|
|
406
412
|
documentUrl?: string | undefined;
|
|
407
413
|
}[K], R> : never : K extends `${number}` ? never : never : P extends `${number}` ? never : never) => void;
|
|
408
|
-
untrackedEdit: <P extends "type" | "children" | "info" | "servers" | "uid" | "auth" | "securitySchemes" | "tags" | "requests" | "
|
|
414
|
+
untrackedEdit: <P extends "type" | "children" | "info" | "servers" | "uid" | "auth" | "securitySchemes" | "selectedSecuritySchemeUids" | "tags" | "requests" | "documentUrl" | "watchForChanges" | "components" | "openapi" | "security" | "externalDocs" | "webhooks" | "jsonSchemaDialect" | "selectedServerUid" | `servers.${number}` | `selectedSecuritySchemeUids.${number}` | `tags.${number}` | `security.${number}` | `security.${number}.${string}` | "externalDocs.url" | "externalDocs.description" | "x-scalar-icon" | "watchForChangesStatus" | `children.${number}` | "info.summary" | "info.title" | "info.description" | "info.termsOfService" | "info.contact" | "info.license" | "info.version" | "info.contact.url" | "info.contact.name" | "info.contact.email" | "info.license.url" | "info.license.name" | "info.license.identifier" | `auth.${string}` | `securitySchemes.${number}` | `requests.${number}` | `components.${string}` | `webhooks.${string}`>(uid: string, path: P, value: P extends "type" | "children" | "info" | "servers" | "uid" | "auth" | "securitySchemes" | "selectedSecuritySchemeUids" | "tags" | "requests" | "documentUrl" | "watchForChanges" | "components" | "openapi" | "security" | "externalDocs" | "webhooks" | "jsonSchemaDialect" | "selectedServerUid" | "x-scalar-icon" | "watchForChangesStatus" ? {
|
|
409
415
|
type: "collection";
|
|
410
416
|
uid: string;
|
|
411
417
|
children: string[];
|
|
@@ -413,6 +419,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
413
419
|
security: Record<string, string[]>[];
|
|
414
420
|
'x-scalar-icon': string;
|
|
415
421
|
securitySchemes: string[];
|
|
422
|
+
selectedSecuritySchemeUids: string[];
|
|
416
423
|
selectedServerUid: string;
|
|
417
424
|
servers: string[];
|
|
418
425
|
requests: string[];
|
|
@@ -471,7 +478,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
471
478
|
components?: Record<string, unknown> | undefined;
|
|
472
479
|
webhooks?: Record<string, unknown> | undefined;
|
|
473
480
|
documentUrl?: string | undefined;
|
|
474
|
-
}[P] : P extends `${infer K}.${infer R}` ? K extends "type" | "children" | "info" | "servers" | "uid" | "auth" | "securitySchemes" | "tags" | "requests" | "
|
|
481
|
+
}[P] : P extends `${infer K}.${infer R}` ? K extends "type" | "children" | "info" | "servers" | "uid" | "auth" | "securitySchemes" | "selectedSecuritySchemeUids" | "tags" | "requests" | "documentUrl" | "watchForChanges" | "components" | "openapi" | "security" | "externalDocs" | "webhooks" | "jsonSchemaDialect" | "selectedServerUid" | "x-scalar-icon" | "watchForChangesStatus" ? R extends import("@scalar/object-utils/nested").Path<{
|
|
475
482
|
type: "collection";
|
|
476
483
|
uid: string;
|
|
477
484
|
children: string[];
|
|
@@ -479,6 +486,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
479
486
|
security: Record<string, string[]>[];
|
|
480
487
|
'x-scalar-icon': string;
|
|
481
488
|
securitySchemes: string[];
|
|
489
|
+
selectedSecuritySchemeUids: string[];
|
|
482
490
|
selectedServerUid: string;
|
|
483
491
|
servers: string[];
|
|
484
492
|
requests: string[];
|
|
@@ -545,6 +553,7 @@ export declare function createStoreCollections(useLocalStorage: boolean): {
|
|
|
545
553
|
security: Record<string, string[]>[];
|
|
546
554
|
'x-scalar-icon': string;
|
|
547
555
|
securitySchemes: string[];
|
|
556
|
+
selectedSecuritySchemeUids: string[];
|
|
548
557
|
selectedServerUid: string;
|
|
549
558
|
servers: string[];
|
|
550
559
|
requests: string[];
|
|
@@ -618,6 +627,7 @@ export declare function extendedCollectionDataFactory({ requests, requestMutator
|
|
|
618
627
|
security: Record<string, string[]>[];
|
|
619
628
|
'x-scalar-icon': string;
|
|
620
629
|
securitySchemes: string[];
|
|
630
|
+
selectedSecuritySchemeUids: string[];
|
|
621
631
|
selectedServerUid: string;
|
|
622
632
|
servers: string[];
|
|
623
633
|
requests: string[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collections.d.ts","sourceRoot":"","sources":["../../src/store/collections.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAA;AACzD,OAAO,EACL,KAAK,UAAU,EACf,KAAK,iBAAiB,EAEvB,MAAM,iCAAiC,CAAA;AACxC,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,sCAAsC,CAAA;AAKrE,yCAAyC;AACzC,wBAAgB,sBAAsB,CAAC,eAAe,EAAE,OAAO
|
|
1
|
+
{"version":3,"file":"collections.d.ts","sourceRoot":"","sources":["../../src/store/collections.ts"],"names":[],"mappings":"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"}
|
package/dist/store/events.d.ts
CHANGED
|
@@ -24,6 +24,6 @@ export declare function createStoreEvents(): {
|
|
|
24
24
|
/**
|
|
25
25
|
* Event bus for handling hot keys
|
|
26
26
|
*/
|
|
27
|
-
hotKeys: import("../libs/event-bus.js").EventBus<Partial<Record<"closeModal" | "navigateSearchResultsDown" | "selectSearchResult" | "navigateSearchResultsUp" | "openCommandPalette" | "
|
|
27
|
+
hotKeys: import("../libs/event-bus.js").EventBus<Partial<Record<"closeModal" | "navigateSearchResultsDown" | "selectSearchResult" | "navigateSearchResultsUp" | "openCommandPalette" | "createNew" | "toggleSidebar" | "addTopNav" | "closeTopNav" | "navigateTopNavLeft" | "navigateTopNavRight" | "focusAddressBar" | "jumpToTab" | "jumpToLastTab" | "focusRequestSearch", KeyboardEvent>>>;
|
|
28
28
|
};
|
|
29
29
|
//# sourceMappingURL=events.d.ts.map
|
|
@@ -1,26 +1,24 @@
|
|
|
1
|
-
import { type
|
|
1
|
+
import { type ErrorResponse } from '../libs/index.js';
|
|
2
2
|
import type { StoreContext } from '../store/store-context';
|
|
3
|
+
import { type ImportSpecToWorkspaceArgs } from '@scalar/oas-utils/transforms';
|
|
3
4
|
import type { OpenAPIV3, OpenAPIV3_1 } from '@scalar/openapi-types';
|
|
4
|
-
import type { Spec } from '@scalar/types/legacy';
|
|
5
|
+
import type { ReferenceConfiguration, Spec } from '@scalar/types/legacy';
|
|
5
6
|
/** Maps the specs by URL */
|
|
6
7
|
export declare const specDictionary: Record<string, {
|
|
7
8
|
hash: number;
|
|
8
9
|
schema: OpenAPIV3.Document | OpenAPIV3_1.Document;
|
|
9
10
|
}>;
|
|
11
|
+
type ImportSpecFileArgs = ImportSpecToWorkspaceArgs & {
|
|
12
|
+
/**
|
|
13
|
+
* TODO: What do these look like?
|
|
14
|
+
* Ideally we reference some existing UIDs in the store and
|
|
15
|
+
* attach those as needed to entities below
|
|
16
|
+
*/
|
|
17
|
+
overloadServers?: Spec['servers'];
|
|
18
|
+
};
|
|
10
19
|
/** Generate the import functions from a store context */
|
|
11
20
|
export declare function importSpecFileFactory({ requestMutators, collectionMutators, serverMutators, tagMutators, securitySchemeMutators, requestExampleMutators, workspaceMutators, workspaces, }: StoreContext): {
|
|
12
|
-
importSpecFile: (_spec: string | Record<string, any>, workspaceUid: string, {
|
|
13
|
-
/** To store the documentUrl, used for watchForChanges */
|
|
14
|
-
documentUrl?: string;
|
|
15
|
-
watchForChanges?: boolean;
|
|
16
|
-
/**
|
|
17
|
-
* TODO: What do these look like?
|
|
18
|
-
* Ideally we reference some existing UIDs in the store and
|
|
19
|
-
* attach those as needed to entities below
|
|
20
|
-
*/
|
|
21
|
-
overloadServers?: Spec["servers"];
|
|
22
|
-
preferredSecurityScheme?: ClientConfiguration["preferredSecurityScheme"];
|
|
23
|
-
}) => Promise<{
|
|
21
|
+
importSpecFile: (_spec: string | Record<string, any>, workspaceUid: string, { overloadServers, ...options }?: ImportSpecFileArgs) => Promise<{
|
|
24
22
|
type: "collection";
|
|
25
23
|
uid: string;
|
|
26
24
|
children: string[];
|
|
@@ -28,6 +26,7 @@ export declare function importSpecFileFactory({ requestMutators, collectionMutat
|
|
|
28
26
|
security: Record<string, string[]>[];
|
|
29
27
|
'x-scalar-icon': string;
|
|
30
28
|
securitySchemes: string[];
|
|
29
|
+
selectedSecuritySchemeUids: string[];
|
|
31
30
|
selectedServerUid: string;
|
|
32
31
|
servers: string[];
|
|
33
32
|
requests: string[];
|
|
@@ -87,23 +86,7 @@ export declare function importSpecFileFactory({ requestMutators, collectionMutat
|
|
|
87
86
|
webhooks?: Record<string, unknown> | undefined;
|
|
88
87
|
documentUrl?: string | undefined;
|
|
89
88
|
} | undefined>;
|
|
90
|
-
importSpecFromUrl: (url: string, workspaceUid: string, { proxy,
|
|
91
|
-
watchForChanges?: boolean;
|
|
92
|
-
overloadServers?: Spec["servers"];
|
|
93
|
-
preferredSecurityScheme?: ClientConfiguration["preferredSecurityScheme"];
|
|
94
|
-
proxy?: string;
|
|
95
|
-
}) => Promise<ErrorResponse<Awaited<ReturnType<(_spec: string | Record<string, any>, workspaceUid: string, { documentUrl, watchForChanges, overloadServers, preferredSecurityScheme, }?: {
|
|
96
|
-
/** To store the documentUrl, used for watchForChanges */
|
|
97
|
-
documentUrl?: string;
|
|
98
|
-
watchForChanges?: boolean;
|
|
99
|
-
/**
|
|
100
|
-
* TODO: What do these look like?
|
|
101
|
-
* Ideally we reference some existing UIDs in the store and
|
|
102
|
-
* attach those as needed to entities below
|
|
103
|
-
*/
|
|
104
|
-
overloadServers?: Spec["servers"];
|
|
105
|
-
preferredSecurityScheme?: ClientConfiguration["preferredSecurityScheme"];
|
|
106
|
-
}) => Promise<{
|
|
89
|
+
importSpecFromUrl: (url: string, workspaceUid: string, { proxy, ...options }?: Omit<ImportSpecFileArgs, "documentUrl"> & Pick<ReferenceConfiguration, "proxy">) => Promise<ErrorResponse<Awaited<ReturnType<(_spec: string | Record<string, any>, workspaceUid: string, { overloadServers, ...options }?: ImportSpecFileArgs) => Promise<{
|
|
107
90
|
type: "collection";
|
|
108
91
|
uid: string;
|
|
109
92
|
children: string[];
|
|
@@ -111,6 +94,7 @@ export declare function importSpecFileFactory({ requestMutators, collectionMutat
|
|
|
111
94
|
security: Record<string, string[]>[];
|
|
112
95
|
'x-scalar-icon': string;
|
|
113
96
|
securitySchemes: string[];
|
|
97
|
+
selectedSecuritySchemeUids: string[];
|
|
114
98
|
selectedServerUid: string;
|
|
115
99
|
servers: string[];
|
|
116
100
|
requests: string[];
|
|
@@ -171,4 +155,5 @@ export declare function importSpecFileFactory({ requestMutators, collectionMutat
|
|
|
171
155
|
documentUrl?: string | undefined;
|
|
172
156
|
} | undefined>>>>>;
|
|
173
157
|
};
|
|
158
|
+
export {};
|
|
174
159
|
//# sourceMappingURL=import-spec.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"import-spec.d.ts","sourceRoot":"","sources":["../../src/store/import-spec.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"import-spec.d.ts","sourceRoot":"","sources":["../../src/store/import-spec.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,aAAa,EAAkB,MAAM,QAAQ,CAAA;AAC3D,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAA;AAEzD,OAAO,EACL,KAAK,yBAAyB,EAE/B,MAAM,8BAA8B,CAAA;AACrC,OAAO,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAA;AACnE,OAAO,KAAK,EAAE,sBAAsB,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAA;AAGxE,4BAA4B;AAC5B,eAAO,MAAM,cAAc,EAAE,MAAM,CACjC,MAAM,EACN;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,MAAM,EAAE,SAAS,CAAC,QAAQ,GAAG,WAAW,CAAC,QAAQ,CAAA;CAAE,CAC/D,CAAA;AAEN,KAAK,kBAAkB,GAAG,yBAAyB,GAAG;IACpD;;;;OAIG;IACH,eAAe,CAAC,EAAE,IAAI,CAAC,SAAS,CAAC,CAAA;CAClC,CAAA;AAED,yDAAyD;AACzD,wBAAgB,qBAAqB,CAAC,EACpC,eAAe,EACf,kBAAkB,EAClB,cAAc,EACd,WAAW,EACX,sBAAsB,EACtB,sBAAsB,EACtB,iBAAiB,EACjB,UAAU,GACX,EAAE,YAAY;4BAEJ,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,gBACrB,MAAM,oCACa,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uBAiF6ga,CAAC;;;;;;uBAAqK,CAAC;mBAAqC,CAAC;0BAA4C,CAAC;mBAAqC,CAAC;oBAAoB,CAAC;mBAAqC,CAAC;qBAAuC,CAAC;;mBAA4D,CAAC;;0BAAoD,CAAC;mBAAqC,CAAC;;;;;;;6BA7Btlb,MAAM,gBACG,MAAM,0BAIjB,IAAI,CAAC,kBAAkB,EAAE,aAAa,CAAC,GACxC,IAAI,CAAC,sBAAsB,EAAE,OAAO,CAAC,KACtC,OAAO,CAAC,aAAa,CAAC,OAAO,CAAC,UAAU,SA7DlC,MAAM,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,gBACrB,MAAM,oCACa,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uBAiF6ga,CAAC;;;;;;uBAAqK,CAAC;mBAAqC,CAAC;0BAA4C,CAAC;mBAAqC,CAAC;oBAAoB,CAAC;mBAAqC,CAAC;qBAAuC,CAAC;;mBAA4D,CAAC;;0BAAoD,CAAC;mBAAqC,CAAC;;;;;;mBAtB3hb,CAAC,CAAC,CAAC;EAqBtE"}
|
|
@@ -1,73 +1,60 @@
|
|
|
1
|
-
import { createHash as
|
|
2
|
-
import { importSpecToWorkspace as
|
|
3
|
-
import { toRaw as
|
|
4
|
-
import { normalizeError as
|
|
5
|
-
const
|
|
6
|
-
function
|
|
7
|
-
requestMutators:
|
|
8
|
-
collectionMutators:
|
|
9
|
-
serverMutators:
|
|
10
|
-
tagMutators:
|
|
11
|
-
securitySchemeMutators:
|
|
12
|
-
requestExampleMutators:
|
|
13
|
-
workspaceMutators:
|
|
14
|
-
workspaces:
|
|
1
|
+
import { createHash as g, fetchSpecFromUrl as F } from "@scalar/oas-utils/helpers";
|
|
2
|
+
import { importSpecToWorkspace as R } from "@scalar/oas-utils/transforms";
|
|
3
|
+
import { toRaw as w } from "vue";
|
|
4
|
+
import { normalizeError as U } from "../libs/errors.js";
|
|
5
|
+
const x = {};
|
|
6
|
+
function b({
|
|
7
|
+
requestMutators: m,
|
|
8
|
+
collectionMutators: l,
|
|
9
|
+
serverMutators: p,
|
|
10
|
+
tagMutators: f,
|
|
11
|
+
securitySchemeMutators: h,
|
|
12
|
+
requestExampleMutators: u,
|
|
13
|
+
workspaceMutators: d,
|
|
14
|
+
workspaces: E
|
|
15
15
|
}) {
|
|
16
|
-
const
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
const t = O(i);
|
|
24
|
-
r != null && r.length && typeof t == "object" && (t.servers = r);
|
|
25
|
-
const o = await x(t, {
|
|
26
|
-
documentUrl: e,
|
|
27
|
-
preferredSecurityScheme: s,
|
|
28
|
-
watchForChanges: a
|
|
29
|
-
});
|
|
30
|
-
if (o.error) {
|
|
31
|
-
console.group("IMPORT ERRORS"), o.importWarnings.forEach((c) => console.warn(c)), console.groupEnd();
|
|
16
|
+
const a = async (n, i, { overloadServers: t, ...e } = {}) => {
|
|
17
|
+
var s;
|
|
18
|
+
const r = w(n);
|
|
19
|
+
t != null && t.length && typeof r == "object" && (r.servers = t);
|
|
20
|
+
const c = await R(r, e);
|
|
21
|
+
if (c.error) {
|
|
22
|
+
console.group("IMPORT ERRORS"), c.importWarnings.forEach((o) => console.warn(o)), console.groupEnd();
|
|
32
23
|
return;
|
|
33
24
|
}
|
|
34
|
-
return e && typeof
|
|
35
|
-
hash:
|
|
36
|
-
schema:
|
|
37
|
-
}),
|
|
38
|
-
(
|
|
39
|
-
),
|
|
40
|
-
...((
|
|
41
|
-
|
|
42
|
-
]),
|
|
25
|
+
return e.documentUrl && typeof r == "string" && (x[e.documentUrl] = {
|
|
26
|
+
hash: g(r),
|
|
27
|
+
schema: c.schema
|
|
28
|
+
}), c.examples.forEach((o) => u.add(o)), c.requests.forEach((o) => m.add(o)), c.tags.forEach((o) => f.add(o)), c.servers.forEach((o) => p.add(o)), c.securitySchemes.forEach(
|
|
29
|
+
(o) => h.add(o)
|
|
30
|
+
), l.add(c.collection), d.edit(i, "collections", [
|
|
31
|
+
...((s = E[i]) == null ? void 0 : s.collections) ?? [],
|
|
32
|
+
c.collection.uid
|
|
33
|
+
]), c.collection;
|
|
43
34
|
};
|
|
44
|
-
async function
|
|
45
|
-
proxy:
|
|
46
|
-
|
|
47
|
-
watchForChanges: r = !1,
|
|
48
|
-
preferredSecurityScheme: s
|
|
35
|
+
async function y(n, i, {
|
|
36
|
+
proxy: t,
|
|
37
|
+
...e
|
|
49
38
|
} = {}) {
|
|
50
39
|
try {
|
|
51
|
-
const
|
|
40
|
+
const r = await F(n, t);
|
|
52
41
|
return [
|
|
53
42
|
null,
|
|
54
|
-
await
|
|
55
|
-
documentUrl:
|
|
56
|
-
|
|
57
|
-
watchForChanges: r,
|
|
58
|
-
preferredSecurityScheme: s
|
|
43
|
+
await a(r, i, {
|
|
44
|
+
documentUrl: n,
|
|
45
|
+
...e
|
|
59
46
|
})
|
|
60
47
|
];
|
|
61
|
-
} catch (
|
|
62
|
-
return console.error("Failed to fetch spec from URL:",
|
|
48
|
+
} catch (r) {
|
|
49
|
+
return console.error("Failed to fetch spec from URL:", r), [U(r), null];
|
|
63
50
|
}
|
|
64
51
|
}
|
|
65
52
|
return {
|
|
66
|
-
importSpecFile:
|
|
67
|
-
importSpecFromUrl:
|
|
53
|
+
importSpecFile: a,
|
|
54
|
+
importSpecFromUrl: y
|
|
68
55
|
};
|
|
69
56
|
}
|
|
70
57
|
export {
|
|
71
|
-
|
|
72
|
-
|
|
58
|
+
b as importSpecFileFactory,
|
|
59
|
+
x as specDictionary
|
|
73
60
|
};
|
package/dist/store/requests.d.ts
CHANGED
|
@@ -7,11 +7,11 @@ export declare function createStoreRequests(useLocalStorage: boolean): {
|
|
|
7
7
|
path: string;
|
|
8
8
|
type: "request";
|
|
9
9
|
uid: string;
|
|
10
|
+
selectedSecuritySchemeUids: string[];
|
|
10
11
|
selectedServerUid: string;
|
|
11
12
|
servers: string[];
|
|
12
13
|
examples: string[];
|
|
13
14
|
method: "options" | "delete" | "get" | "connect" | "head" | "patch" | "post" | "put" | "trace";
|
|
14
|
-
selectedSecuritySchemeUids: string[];
|
|
15
15
|
description?: string | undefined;
|
|
16
16
|
summary?: string | undefined;
|
|
17
17
|
externalDocs?: {
|
|
@@ -40,11 +40,11 @@ export declare function createStoreRequests(useLocalStorage: boolean): {
|
|
|
40
40
|
path: string;
|
|
41
41
|
type: "request";
|
|
42
42
|
uid: string;
|
|
43
|
+
selectedSecuritySchemeUids: string[];
|
|
43
44
|
selectedServerUid: string;
|
|
44
45
|
servers: string[];
|
|
45
46
|
examples: string[];
|
|
46
47
|
method: "options" | "delete" | "get" | "connect" | "head" | "patch" | "post" | "put" | "trace";
|
|
47
|
-
selectedSecuritySchemeUids: string[];
|
|
48
48
|
description?: string | undefined;
|
|
49
49
|
summary?: string | undefined;
|
|
50
50
|
externalDocs?: {
|
|
@@ -73,11 +73,11 @@ export declare function createStoreRequests(useLocalStorage: boolean): {
|
|
|
73
73
|
path: string;
|
|
74
74
|
type: "request";
|
|
75
75
|
uid: string;
|
|
76
|
+
selectedSecuritySchemeUids: string[];
|
|
76
77
|
selectedServerUid: string;
|
|
77
78
|
servers: string[];
|
|
78
79
|
examples: string[];
|
|
79
80
|
method: "options" | "delete" | "get" | "connect" | "head" | "patch" | "post" | "put" | "trace";
|
|
80
|
-
selectedSecuritySchemeUids: string[];
|
|
81
81
|
description?: string | undefined;
|
|
82
82
|
summary?: string | undefined;
|
|
83
83
|
externalDocs?: {
|
|
@@ -101,15 +101,15 @@ export declare function createStoreRequests(useLocalStorage: boolean): {
|
|
|
101
101
|
requestBody?: any;
|
|
102
102
|
responses?: Record<string, any> | undefined;
|
|
103
103
|
}) => void;
|
|
104
|
-
edit: <P extends "method" | "type" | "summary" | "path" | "servers" | "description" | "deprecated" | "parameters" | "uid" | "tags" | "examples" | "security" | "externalDocs" | "selectedServerUid" | "
|
|
104
|
+
edit: <P extends "method" | "type" | "summary" | "path" | "servers" | "description" | "deprecated" | "parameters" | "uid" | "selectedSecuritySchemeUids" | "tags" | "examples" | "security" | "externalDocs" | "selectedServerUid" | "operationId" | "requestBody" | "responses" | `servers.${number}` | `parameters.${number}` | `parameters.${number}.required` | `parameters.${number}.description` | `parameters.${number}.style` | `parameters.${number}.deprecated` | `parameters.${number}.content` | `parameters.${number}.name` | `parameters.${number}.in` | `parameters.${number}.schema` | `selectedSecuritySchemeUids.${number}` | `tags.${number}` | `examples.${number}` | `security.${number}` | `security.${number}.${string}` | "externalDocs.url" | "externalDocs.description" | `requestBody.${string}` | `responses.${string}`>(uid: string, path: P, value: P extends "method" | "type" | "summary" | "path" | "servers" | "description" | "deprecated" | "parameters" | "uid" | "selectedSecuritySchemeUids" | "tags" | "examples" | "security" | "externalDocs" | "selectedServerUid" | "operationId" | "requestBody" | "responses" ? {
|
|
105
105
|
path: string;
|
|
106
106
|
type: "request";
|
|
107
107
|
uid: string;
|
|
108
|
+
selectedSecuritySchemeUids: string[];
|
|
108
109
|
selectedServerUid: string;
|
|
109
110
|
servers: string[];
|
|
110
111
|
examples: string[];
|
|
111
112
|
method: "options" | "delete" | "get" | "connect" | "head" | "patch" | "post" | "put" | "trace";
|
|
112
|
-
selectedSecuritySchemeUids: string[];
|
|
113
113
|
description?: string | undefined;
|
|
114
114
|
summary?: string | undefined;
|
|
115
115
|
externalDocs?: {
|
|
@@ -132,15 +132,15 @@ export declare function createStoreRequests(useLocalStorage: boolean): {
|
|
|
132
132
|
}[] | undefined;
|
|
133
133
|
requestBody?: any;
|
|
134
134
|
responses?: Record<string, any> | undefined;
|
|
135
|
-
}[P] : P extends `${infer K}.${infer R}` ? K extends "method" | "type" | "summary" | "path" | "servers" | "description" | "deprecated" | "parameters" | "uid" | "tags" | "examples" | "security" | "externalDocs" | "selectedServerUid" | "
|
|
135
|
+
}[P] : P extends `${infer K}.${infer R}` ? K extends "method" | "type" | "summary" | "path" | "servers" | "description" | "deprecated" | "parameters" | "uid" | "selectedSecuritySchemeUids" | "tags" | "examples" | "security" | "externalDocs" | "selectedServerUid" | "operationId" | "requestBody" | "responses" ? R extends import("@scalar/object-utils/nested").Path<{
|
|
136
136
|
path: string;
|
|
137
137
|
type: "request";
|
|
138
138
|
uid: string;
|
|
139
|
+
selectedSecuritySchemeUids: string[];
|
|
139
140
|
selectedServerUid: string;
|
|
140
141
|
servers: string[];
|
|
141
142
|
examples: string[];
|
|
142
143
|
method: "options" | "delete" | "get" | "connect" | "head" | "patch" | "post" | "put" | "trace";
|
|
143
|
-
selectedSecuritySchemeUids: string[];
|
|
144
144
|
description?: string | undefined;
|
|
145
145
|
summary?: string | undefined;
|
|
146
146
|
externalDocs?: {
|
|
@@ -167,11 +167,11 @@ export declare function createStoreRequests(useLocalStorage: boolean): {
|
|
|
167
167
|
path: string;
|
|
168
168
|
type: "request";
|
|
169
169
|
uid: string;
|
|
170
|
+
selectedSecuritySchemeUids: string[];
|
|
170
171
|
selectedServerUid: string;
|
|
171
172
|
servers: string[];
|
|
172
173
|
examples: string[];
|
|
173
174
|
method: "options" | "delete" | "get" | "connect" | "head" | "patch" | "post" | "put" | "trace";
|
|
174
|
-
selectedSecuritySchemeUids: string[];
|
|
175
175
|
description?: string | undefined;
|
|
176
176
|
summary?: string | undefined;
|
|
177
177
|
externalDocs?: {
|
|
@@ -195,15 +195,15 @@ export declare function createStoreRequests(useLocalStorage: boolean): {
|
|
|
195
195
|
requestBody?: any;
|
|
196
196
|
responses?: Record<string, any> | undefined;
|
|
197
197
|
}[K], R> : never : K extends `${number}` ? never : never : P extends `${number}` ? never : never) => void;
|
|
198
|
-
untrackedEdit: <P extends "method" | "type" | "summary" | "path" | "servers" | "description" | "deprecated" | "parameters" | "uid" | "tags" | "examples" | "security" | "externalDocs" | "selectedServerUid" | "
|
|
198
|
+
untrackedEdit: <P extends "method" | "type" | "summary" | "path" | "servers" | "description" | "deprecated" | "parameters" | "uid" | "selectedSecuritySchemeUids" | "tags" | "examples" | "security" | "externalDocs" | "selectedServerUid" | "operationId" | "requestBody" | "responses" | `servers.${number}` | `parameters.${number}` | `parameters.${number}.required` | `parameters.${number}.description` | `parameters.${number}.style` | `parameters.${number}.deprecated` | `parameters.${number}.content` | `parameters.${number}.name` | `parameters.${number}.in` | `parameters.${number}.schema` | `selectedSecuritySchemeUids.${number}` | `tags.${number}` | `examples.${number}` | `security.${number}` | `security.${number}.${string}` | "externalDocs.url" | "externalDocs.description" | `requestBody.${string}` | `responses.${string}`>(uid: string, path: P, value: P extends "method" | "type" | "summary" | "path" | "servers" | "description" | "deprecated" | "parameters" | "uid" | "selectedSecuritySchemeUids" | "tags" | "examples" | "security" | "externalDocs" | "selectedServerUid" | "operationId" | "requestBody" | "responses" ? {
|
|
199
199
|
path: string;
|
|
200
200
|
type: "request";
|
|
201
201
|
uid: string;
|
|
202
|
+
selectedSecuritySchemeUids: string[];
|
|
202
203
|
selectedServerUid: string;
|
|
203
204
|
servers: string[];
|
|
204
205
|
examples: string[];
|
|
205
206
|
method: "options" | "delete" | "get" | "connect" | "head" | "patch" | "post" | "put" | "trace";
|
|
206
|
-
selectedSecuritySchemeUids: string[];
|
|
207
207
|
description?: string | undefined;
|
|
208
208
|
summary?: string | undefined;
|
|
209
209
|
externalDocs?: {
|
|
@@ -226,15 +226,15 @@ export declare function createStoreRequests(useLocalStorage: boolean): {
|
|
|
226
226
|
}[] | undefined;
|
|
227
227
|
requestBody?: any;
|
|
228
228
|
responses?: Record<string, any> | undefined;
|
|
229
|
-
}[P] : P extends `${infer K}.${infer R}` ? K extends "method" | "type" | "summary" | "path" | "servers" | "description" | "deprecated" | "parameters" | "uid" | "tags" | "examples" | "security" | "externalDocs" | "selectedServerUid" | "
|
|
229
|
+
}[P] : P extends `${infer K}.${infer R}` ? K extends "method" | "type" | "summary" | "path" | "servers" | "description" | "deprecated" | "parameters" | "uid" | "selectedSecuritySchemeUids" | "tags" | "examples" | "security" | "externalDocs" | "selectedServerUid" | "operationId" | "requestBody" | "responses" ? R extends import("@scalar/object-utils/nested").Path<{
|
|
230
230
|
path: string;
|
|
231
231
|
type: "request";
|
|
232
232
|
uid: string;
|
|
233
|
+
selectedSecuritySchemeUids: string[];
|
|
233
234
|
selectedServerUid: string;
|
|
234
235
|
servers: string[];
|
|
235
236
|
examples: string[];
|
|
236
237
|
method: "options" | "delete" | "get" | "connect" | "head" | "patch" | "post" | "put" | "trace";
|
|
237
|
-
selectedSecuritySchemeUids: string[];
|
|
238
238
|
description?: string | undefined;
|
|
239
239
|
summary?: string | undefined;
|
|
240
240
|
externalDocs?: {
|
|
@@ -261,11 +261,11 @@ export declare function createStoreRequests(useLocalStorage: boolean): {
|
|
|
261
261
|
path: string;
|
|
262
262
|
type: "request";
|
|
263
263
|
uid: string;
|
|
264
|
+
selectedSecuritySchemeUids: string[];
|
|
264
265
|
selectedServerUid: string;
|
|
265
266
|
servers: string[];
|
|
266
267
|
examples: string[];
|
|
267
268
|
method: "options" | "delete" | "get" | "connect" | "head" | "patch" | "post" | "put" | "trace";
|
|
268
|
-
selectedSecuritySchemeUids: string[];
|
|
269
269
|
description?: string | undefined;
|
|
270
270
|
summary?: string | undefined;
|
|
271
271
|
externalDocs?: {
|
|
@@ -302,11 +302,11 @@ export declare function extendedRequestDataFactory({ requestExamples, requestExa
|
|
|
302
302
|
path: string;
|
|
303
303
|
type: "request";
|
|
304
304
|
uid: string;
|
|
305
|
+
selectedSecuritySchemeUids: string[];
|
|
305
306
|
selectedServerUid: string;
|
|
306
307
|
servers: string[];
|
|
307
308
|
examples: string[];
|
|
308
309
|
method: "options" | "delete" | "get" | "connect" | "head" | "patch" | "post" | "put" | "trace";
|
|
309
|
-
selectedSecuritySchemeUids: string[];
|
|
310
310
|
description?: string | undefined;
|
|
311
311
|
summary?: string | undefined;
|
|
312
312
|
externalDocs?: {
|