@scalar/oas-utils 0.2.123 → 0.2.124

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 CHANGED
@@ -1,5 +1,11 @@
1
1
  # @scalar/oas-utils
2
2
 
3
+ ## 0.2.124
4
+
5
+ ### Patch Changes
6
+
7
+ - 0de80ae: feat: added auth to collection page
8
+
3
9
  ## 0.2.123
4
10
 
5
11
  ### Patch Changes
@@ -274,6 +274,12 @@ export declare const extendedCollectionSchema: z.ZodObject<{
274
274
  watchMode: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
275
275
  /** Keeps track of which integration is associated with the specific collection */
276
276
  integration: z.ZodOptional<z.ZodNullable<z.ZodString>>;
277
+ /**
278
+ * Selected authentication will be set at the collection level instead of the request level
279
+ *
280
+ * @default false
281
+ */
282
+ useCollectionSecurity: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
277
283
  /**
278
284
  * Status of the watcher from above
279
285
  *
@@ -289,6 +295,7 @@ export declare const extendedCollectionSchema: z.ZodObject<{
289
295
  requests: (string & z.BRAND<"operation">)[];
290
296
  tags: (string & z.BRAND<"tag">)[];
291
297
  watchMode: boolean;
298
+ useCollectionSecurity: boolean;
292
299
  watchModeStatus: "IDLE" | "WATCHING" | "ERROR";
293
300
  selectedServerUid?: (string & z.BRAND<"server">) | undefined;
294
301
  documentUrl?: string | undefined;
@@ -305,6 +312,7 @@ export declare const extendedCollectionSchema: z.ZodObject<{
305
312
  documentUrl?: string | undefined;
306
313
  watchMode?: boolean | undefined;
307
314
  integration?: string | null | undefined;
315
+ useCollectionSecurity?: boolean | undefined;
308
316
  watchModeStatus?: "IDLE" | "WATCHING" | "ERROR" | undefined;
309
317
  }>;
310
318
  export declare const collectionSchema: z.ZodObject<z.objectUtil.extendShape<{
@@ -513,6 +521,12 @@ export declare const collectionSchema: z.ZodObject<z.objectUtil.extendShape<{
513
521
  watchMode: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
514
522
  /** Keeps track of which integration is associated with the specific collection */
515
523
  integration: z.ZodOptional<z.ZodNullable<z.ZodString>>;
524
+ /**
525
+ * Selected authentication will be set at the collection level instead of the request level
526
+ *
527
+ * @default false
528
+ */
529
+ useCollectionSecurity: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
516
530
  /**
517
531
  * Status of the watcher from above
518
532
  *
@@ -549,6 +563,7 @@ export declare const collectionSchema: z.ZodObject<z.objectUtil.extendShape<{
549
563
  requests: (string & z.BRAND<"operation">)[];
550
564
  tags: (string & z.BRAND<"tag">)[];
551
565
  watchMode: boolean;
566
+ useCollectionSecurity: boolean;
552
567
  watchModeStatus: "IDLE" | "WATCHING" | "ERROR";
553
568
  externalDocs?: {
554
569
  url: string;
@@ -610,6 +625,7 @@ export declare const collectionSchema: z.ZodObject<z.objectUtil.extendShape<{
610
625
  documentUrl?: string | undefined;
611
626
  watchMode?: boolean | undefined;
612
627
  integration?: string | null | undefined;
628
+ useCollectionSecurity?: boolean | undefined;
613
629
  watchModeStatus?: "IDLE" | "WATCHING" | "ERROR" | undefined;
614
630
  }>;
615
631
  export type Collection = z.infer<typeof collectionSchema>;
@@ -1 +1 @@
1
- {"version":3,"file":"collection.d.ts","sourceRoot":"","sources":["../../../src/entities/spec/collection.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,eAAO,MAAM,mBAAmB;IAC9B;;;;OAIG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAWH;;;;;;OAMG;;;;;;;;;;;;;;;;;;IAGH,uBAAuB;;IAEvB,uBAAuB;;IAEvB,gDAAgD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;EAI8E,CAAA;AACnF,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAA;AACzD,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAA"}
@@ -81,6 +81,12 @@ const extendedCollectionSchema = z.object({
81
81
  watchMode: z.boolean().optional().default(false),
82
82
  /** Keeps track of which integration is associated with the specific collection */
83
83
  integration: z.string().nullable().optional(),
84
+ /**
85
+ * Selected authentication will be set at the collection level instead of the request level
86
+ *
87
+ * @default false
88
+ */
89
+ useCollectionSecurity: z.boolean().optional().default(false),
84
90
  /**
85
91
  * Status of the watcher from above
86
92
  *
@@ -1 +1 @@
1
- {"version":3,"file":"migration.d.ts","sourceRoot":"","sources":["../../../src/migrations/v-2.5.0/migration.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,yCAAyC,CAAA;AACtE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAA;AAEnD,mCAAmC;AACnC,eAAO,MAAM,eAAe,SAAU,OAAO,CAAC,UAAU,KAAG,OAAO,CAAC,YAAY,CAiK9E,CAAA"}
1
+ {"version":3,"file":"migration.d.ts","sourceRoot":"","sources":["../../../src/migrations/v-2.5.0/migration.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,yCAAyC,CAAA;AACtE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAA;AAEnD,mCAAmC;AACnC,eAAO,MAAM,eAAe,SAAU,OAAO,CAAC,UAAU,KAAG,OAAO,CAAC,YAAY,CAkK9E,CAAA"}
@@ -22,6 +22,7 @@ const migrate_v_2_5_0 = (data) => {
22
22
  requests: collection.requests.map((uid) => uid),
23
23
  children: collection.children.map((uid) => uid),
24
24
  selectedServerUid: collection.selectedServerUid,
25
+ useCollectionSecurity: false,
25
26
  };
26
27
  return acc;
27
28
  }, {});
@@ -25,7 +25,7 @@ export declare const getSelectedSecuritySchemeUids: (securityRequirements: (stri
25
25
  export declare const getSlugUid: (slug: string) => Collection["uid"];
26
26
  export type ImportSpecToWorkspaceArgs = Pick<CollectionPayload, 'documentUrl' | 'watchMode'> & Pick<ApiReferenceConfiguration, 'authentication' | 'baseServerURL' | 'servers' | 'slug'> & {
27
27
  /** Sets the preferred security scheme on the collection instead of the requests */
28
- setCollectionSecurity?: boolean;
28
+ useCollectionSecurity?: boolean;
29
29
  /** Call the load step from the parser */
30
30
  shouldLoad?: boolean;
31
31
  };
@@ -42,7 +42,7 @@ export type ImportSpecToWorkspaceArgs = Pick<CollectionPayload, 'documentUrl' |
42
42
  * - Proper linking between related components
43
43
  * - Easy lookup and reference of dependent entities
44
44
  */
45
- export declare function importSpecToWorkspace(spec: string | UnknownObject, { authentication, baseServerURL, documentUrl, servers: configuredServers, setCollectionSecurity, slug, shouldLoad, watchMode, }?: ImportSpecToWorkspaceArgs): Promise<{
45
+ export declare function importSpecToWorkspace(spec: string | UnknownObject, { authentication, baseServerURL, documentUrl, servers: configuredServers, useCollectionSecurity, slug, shouldLoad, watchMode, }?: ImportSpecToWorkspaceArgs): Promise<{
46
46
  error: false;
47
47
  collection: Collection;
48
48
  requests: Request[];
@@ -1 +1 @@
1
- {"version":3,"file":"import-spec.d.ts","sourceRoot":"","sources":["../../src/transforms/import-spec.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAA;AACxD,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,6BAA6B,CAAA;AAE5E,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAA;AAGxD,OAAO,KAAK,EAAE,0BAA0B,EAAE,MAAM,8BAA8B,CAAA;AAC9E,OAAO,EAAE,KAAK,UAAU,EAAE,KAAK,iBAAiB,EAAoB,MAAM,+BAA+B,CAAA;AAEzG,OAAO,EAAE,KAAK,c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AE,GAAG,EAAE,CAAA;IACX,eAAe,EAAE,cAAc,EAAE,CAAA;CAClC,GACD;IAAE,KAAK,EAAE,IAAI,CAAC;IAAC,cAAc,EAAE,MAAM,EAAE,CAAC;IAAC,UAAU,EAAE,SAAS,CAAA;CAAE,CACnE,CAyWA;AAED;;GAEG;AACH,wBAAgB,6BAA6B,CAC3C,OAAO,EAAE,WAAW,CAAC,YAAY,EAAE,GAAG,SAAS,EAC/C,EAAE,aAAa,EAAE,GAAE,IAAI,CAAC,yBAAyB,EAAE,eAAe,CAAM,GACvE,MAAM,EAAE,CA0CV"}
@@ -76,7 +76,7 @@ const getSlugUid = (slug) => `slug-uid-${slug}`;
76
76
  * - Proper linking between related components
77
77
  * - Easy lookup and reference of dependent entities
78
78
  */
79
- async function importSpecToWorkspace(spec, { authentication, baseServerURL, documentUrl, servers: configuredServers, setCollectionSecurity = false, slug, shouldLoad, watchMode = false, } = {}) {
79
+ async function importSpecToWorkspace(spec, { authentication, baseServerURL, documentUrl, servers: configuredServers, useCollectionSecurity = false, slug, shouldLoad, watchMode = false, } = {}) {
80
80
  const { schema, errors } = await parseSchema(spec, { shouldLoad });
81
81
  const importWarnings = [...errors.map((e) => e.message)];
82
82
  if (!schema) {
@@ -226,7 +226,7 @@ async function importSpecToWorkspace(spec, { authentication, baseServerURL, docu
226
226
  return securityRequirements.includes(name);
227
227
  });
228
228
  // Set the initially selected security scheme
229
- const selectedSecuritySchemeUids = securityRequirements.length && !setCollectionSecurity
229
+ const selectedSecuritySchemeUids = securityRequirements.length && !useCollectionSecurity
230
230
  ? getSelectedSecuritySchemeUids(securityRequirements, preferredSecurityNames, securitySchemeMap)
231
231
  : [];
232
232
  const requestPayload = {
@@ -332,7 +332,7 @@ async function importSpecToWorkspace(spec, { authentication, baseServerURL, docu
332
332
  // Here we do not filter these as we let the preferredSecurityScheme override the requirements
333
333
  const preferredSecurityNames = [authentication?.preferredSecurityScheme ?? []].flat();
334
334
  // Set the initially selected security scheme
335
- const selectedSecuritySchemeUids = (securityRequirements.length || preferredSecurityNames?.length) && setCollectionSecurity
335
+ const selectedSecuritySchemeUids = (securityRequirements.length || preferredSecurityNames?.length) && useCollectionSecurity
336
336
  ? getSelectedSecuritySchemeUids(securityRequirements, preferredSecurityNames, securitySchemeMap)
337
337
  : [];
338
338
  // Set the uid as a prefixed slug if we have one
@@ -342,6 +342,7 @@ async function importSpecToWorkspace(spec, { authentication, baseServerURL, docu
342
342
  ...schema,
343
343
  watchMode,
344
344
  documentUrl,
345
+ useCollectionSecurity,
345
346
  requests: requests.map((r) => r.uid),
346
347
  servers: servers.map((s) => s.uid),
347
348
  tags: tags.map((t) => t.uid),
package/package.json CHANGED
@@ -16,7 +16,7 @@
16
16
  "specification",
17
17
  "yaml"
18
18
  ],
19
- "version": "0.2.123",
19
+ "version": "0.2.124",
20
20
  "engines": {
21
21
  "node": ">=18"
22
22
  },