@postman/sdk-config 0.5.0 → 0.5.1

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.
@@ -1240,10 +1240,16 @@ function finishOutputMapping(mapping, outputMode, sourcePath, state, index) {
1240
1240
  for (const path of collectLeafPaths(outputMode, sourcePath)) {
1241
1241
  if (path[path.length - 1] === "_visit") consume(state, path);
1242
1242
  }
1243
+ const legacyGenerateFullProject = isObject(outputMode) ? outputMode.generateFullProject : void 0;
1244
+ const generationShape = typeof legacyGenerateFullProject === "boolean" ? { generation: { ...mapping.generation, generateFullProject: legacyGenerateFullProject } } : {};
1245
+ if (typeof legacyGenerateFullProject === "boolean") {
1246
+ consume(state, [...sourcePath, "generateFullProject"]);
1247
+ }
1243
1248
  const unsupported = collectUnsupported(outputMode, sourcePath, state);
1244
1249
  const hasCredentials = unsupported.some((diagnostic) => isCredentialPath(diagnostic.path));
1245
1250
  return {
1246
1251
  ...mapping,
1252
+ ...generationShape,
1247
1253
  unsupportedFields: [
1248
1254
  ...state.credentialDiagnostics ?? [],
1249
1255
  ...hasCredentials ? [
@@ -1425,6 +1431,8 @@ var generationConfigOverrideShape = {
1425
1431
  inferServiceNames: z.boolean().optional(),
1426
1432
  includeDeprecatedOperations: z.boolean().optional(),
1427
1433
  multipleResponses: z.boolean().optional(),
1434
+ /** Generate the entire SDK project, including package manifests and publishable artifacts. */
1435
+ generateFullProject: z.boolean().optional(),
1428
1436
  devContainer: z.boolean().optional(),
1429
1437
  allowMockClient: z.boolean().optional(),
1430
1438
  ignoreFiles: z.array(nonEmptyStringSchema).optional(),
@@ -1453,6 +1461,7 @@ var sdkConfigV1GenerationConfigSchema = z.strictObject({
1453
1461
  inferServiceNames: z.boolean().default(false),
1454
1462
  includeDeprecatedOperations: z.boolean().default(true),
1455
1463
  multipleResponses: z.boolean().default(false),
1464
+ generateFullProject: z.boolean().default(false),
1456
1465
  devContainer: z.boolean().default(false),
1457
1466
  allowMockClient: z.boolean().default(false)
1458
1467
  });
@@ -2057,7 +2066,14 @@ function mapFernConfigToSdkConfigV1(input) {
2057
2066
  api.audiences = [...input.group.audiences.audiences];
2058
2067
  }
2059
2068
  const targets = mapped.map(
2060
- ({ generator, invocation, language, output, package: outputPackage }, index) => {
2069
+ ({
2070
+ generator,
2071
+ invocation,
2072
+ language,
2073
+ output,
2074
+ package: outputPackage,
2075
+ generation: outputGeneration
2076
+ }, index) => {
2061
2077
  const target = {
2062
2078
  language,
2063
2079
  output,
@@ -2071,6 +2087,7 @@ function mapFernConfigToSdkConfigV1(input) {
2071
2087
  }
2072
2088
  const targetGeneration = {
2073
2089
  ...generations.targetOverrides[index],
2090
+ ...outputGeneration,
2074
2091
  ...invocation.targetGeneration
2075
2092
  };
2076
2093
  if (Object.keys(targetGeneration).length > 0) {
@@ -2248,6 +2265,9 @@ function mapInvocation(generator, language, activeLanguages, index) {
2248
2265
  if (generator.keywords?.length) {
2249
2266
  generation.reservedKeywords = [...generator.keywords];
2250
2267
  }
2268
+ if (generator.generateFullProject !== void 0) {
2269
+ generation.generateFullProject = generator.generateFullProject;
2270
+ }
2251
2271
  const settings = isObject(generator.settings) ? generator.settings : void 0;
2252
2272
  if (settings) {
2253
2273
  const inlinePathParameters = takeBoolean(settings, ["inlinePathParameters"], state, [
@@ -2390,6 +2410,8 @@ function mapCommonConfig(language, config, state, client, generation, packageCon
2390
2410
  basePath
2391
2411
  );
2392
2412
  if (webSockets !== void 0) generation.webSockets = webSockets;
2413
+ const generateFullProject = takeBoolean(config, ["generateFullProject"], state, basePath);
2414
+ if (generateFullProject !== void 0) generation.generateFullProject = generateFullProject;
2393
2415
  const inlineTypes = takeBoolean(config, ["enableInlineTypes"], state, basePath);
2394
2416
  const omitUndefined = takeBoolean(config, ["omitUndefined"], state, basePath);
2395
2417
  const forwardEnums = takeBoolean(config, ["enableForwardCompatibleEnums"], state, basePath);