@postman/sdk-config 0.12.0 → 0.13.0
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/README.md +18 -6
- package/dist/index.cjs +158 -15
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +158 -15
- package/dist/index.js.map +1 -1
- package/dist/sdk-config/index.cjs +156 -14
- package/dist/sdk-config/index.cjs.map +1 -1
- package/dist/sdk-config/index.d.cts +1 -1
- package/dist/sdk-config/index.d.ts +1 -1
- package/dist/sdk-config/index.js +156 -14
- package/dist/sdk-config/index.js.map +1 -1
- package/dist/sdk-config/v1/index.cjs +156 -14
- package/dist/sdk-config/v1/index.cjs.map +1 -1
- package/dist/sdk-config/v1/index.d.cts +400 -31
- package/dist/sdk-config/v1/index.d.ts +400 -31
- package/dist/sdk-config/v1/index.js +156 -14
- package/dist/sdk-config/v1/index.js.map +1 -1
- package/dist/sdk-config-ir/index.cjs +18 -5
- package/dist/sdk-config-ir/index.cjs.map +1 -1
- package/dist/sdk-config-ir/index.d.cts +1 -1
- package/dist/sdk-config-ir/index.d.ts +1 -1
- package/dist/sdk-config-ir/index.js +18 -5
- package/dist/sdk-config-ir/index.js.map +1 -1
- package/dist/sdk-config-ir/v1/index.cjs +18 -5
- package/dist/sdk-config-ir/v1/index.cjs.map +1 -1
- package/dist/sdk-config-ir/v1/index.d.cts +27 -4
- package/dist/sdk-config-ir/v1/index.d.ts +27 -4
- package/dist/sdk-config-ir/v1/index.js +18 -5
- package/dist/sdk-config-ir/v1/index.js.map +1 -1
- package/dist/{typescript-Byhn4MqL.d.cts → typescript-BFRxjAah.d.cts} +1 -0
- package/dist/{typescript-Byhn4MqL.d.ts → typescript-BFRxjAah.d.ts} +1 -0
- package/package.json +1 -1
- package/src/sdk-config/v1/README.md +32 -11
- package/src/sdk-config-ir/v1/README.md +36 -29
|
@@ -514,7 +514,10 @@ var cliDistributionConfigSchema = zod.z.strictObject({
|
|
|
514
514
|
"A GitHub App used to mint short-lived tokens for every channel without its own tokenSecretName."
|
|
515
515
|
),
|
|
516
516
|
homebrew: cliDistributionHomebrewSchema.optional().describe("Publishes a Homebrew formula to a tap repository on each tagged release."),
|
|
517
|
-
scoop: cliDistributionScoopSchema.optional().describe("Publishes a Scoop manifest to a bucket repository on each tagged release.")
|
|
517
|
+
scoop: cliDistributionScoopSchema.optional().describe("Publishes a Scoop manifest to a bucket repository on each tagged release."),
|
|
518
|
+
githubAttestations: zod.z.union([zod.z.literal("auto"), zod.z.boolean()], { error: 'must be "auto", true, or false' }).optional().describe(
|
|
519
|
+
'Whether the generated release workflow attests build provenance. "auto" (the generator default) attests only on public repositories; true always attests, for private repositories on GitHub Enterprise Cloud; false omits the attestation step and its permissions.'
|
|
520
|
+
)
|
|
518
521
|
}).superRefine((distribution, context) => {
|
|
519
522
|
if (distribution.homebrew !== void 0 || distribution.scoop !== void 0) {
|
|
520
523
|
return;
|
|
@@ -527,6 +530,9 @@ var cliDistributionConfigSchema = zod.z.strictObject({
|
|
|
527
530
|
});
|
|
528
531
|
return;
|
|
529
532
|
}
|
|
533
|
+
if (distribution.githubAttestations !== void 0) {
|
|
534
|
+
return;
|
|
535
|
+
}
|
|
530
536
|
context.addIssue({
|
|
531
537
|
code: "custom",
|
|
532
538
|
message: "distribution must configure at least one channel: homebrew or scoop"
|
|
@@ -538,14 +544,17 @@ var CLI_DISTRIBUTION_NON_RELEASE_MODE_CODE = "CLI_DISTRIBUTION_NON_RELEASE_MODE"
|
|
|
538
544
|
var nonReleaseGithubModes = /* @__PURE__ */ new Set(["pull-request", "push", "commit"]);
|
|
539
545
|
function cliDistributionModeDiagnostic(output, outputPath) {
|
|
540
546
|
const mode = output?.github?.mode;
|
|
541
|
-
|
|
547
|
+
const distribution = output?.distribution;
|
|
548
|
+
if (distribution === void 0 || mode === void 0 || !nonReleaseGithubModes.has(mode)) {
|
|
542
549
|
return void 0;
|
|
543
550
|
}
|
|
551
|
+
const hasChannel = distribution.homebrew !== void 0 || distribution.scoop !== void 0;
|
|
552
|
+
const consequence = hasChannel ? "Homebrew and Scoop publish only after a semantic-version tag is pushed to the repository." : "the release workflow, including its githubAttestations setting, runs only after a semantic-version tag is pushed to the repository.";
|
|
544
553
|
return {
|
|
545
554
|
code: CLI_DISTRIBUTION_NON_RELEASE_MODE_CODE,
|
|
546
555
|
severity: "warning",
|
|
547
556
|
path: [...outputPath, "github", "mode"],
|
|
548
|
-
reason: `GitHub mode "${mode}" does not create a release tag, so
|
|
557
|
+
reason: `GitHub mode "${mode}" does not create a release tag, so ${consequence}`,
|
|
549
558
|
suggestedAction: 'Use mode "release" or "commit-and-release", or push a version tag after merging generated changes.'
|
|
550
559
|
};
|
|
551
560
|
}
|
|
@@ -980,6 +989,7 @@ var DISTRIBUTION_KEYS = {
|
|
|
980
989
|
homebrew: { tap: "tap", formula: "formula", tokenEnvironmentVariable: "tokenSecretName" },
|
|
981
990
|
scoop: { bucket: "bucket", tokenEnvironmentVariable: "tokenSecretName" }
|
|
982
991
|
};
|
|
992
|
+
var DISTRIBUTION_SCALAR_KEYS = ["githubAttestations"];
|
|
983
993
|
function mapCliDistribution(config, state, basePath, targetIndex) {
|
|
984
994
|
if (!Object.hasOwn(config, "distribution")) return;
|
|
985
995
|
const raw = config.distribution;
|
|
@@ -1026,6 +1036,11 @@ function translateDistribution(distribution, path) {
|
|
|
1026
1036
|
}
|
|
1027
1037
|
value[block] = translatedBlock;
|
|
1028
1038
|
}
|
|
1039
|
+
for (const key of DISTRIBUTION_SCALAR_KEYS) {
|
|
1040
|
+
if (!Object.hasOwn(distribution, key)) continue;
|
|
1041
|
+
value[key] = distribution[key];
|
|
1042
|
+
consumedPaths.push([...path, key]);
|
|
1043
|
+
}
|
|
1029
1044
|
return { value, consumedPaths, legacyKeys };
|
|
1030
1045
|
}
|
|
1031
1046
|
function invalidDistributionDiagnostic(issue, path, legacyKeys, targetIndex) {
|
|
@@ -1165,6 +1180,7 @@ function mapOutput(generator, language, index) {
|
|
|
1165
1180
|
output.publishV2,
|
|
1166
1181
|
rawOutput,
|
|
1167
1182
|
language,
|
|
1183
|
+
"zip",
|
|
1168
1184
|
[...outputPath, "publishV2"],
|
|
1169
1185
|
state,
|
|
1170
1186
|
index
|
|
@@ -1186,6 +1202,7 @@ function mapOutput(generator, language, index) {
|
|
|
1186
1202
|
output.registryOverrides,
|
|
1187
1203
|
rawOutput,
|
|
1188
1204
|
language,
|
|
1205
|
+
"zip",
|
|
1189
1206
|
[...outputPath, "registryOverrides"],
|
|
1190
1207
|
state,
|
|
1191
1208
|
index
|
|
@@ -1213,7 +1230,14 @@ function mapOutput(generator, language, index) {
|
|
|
1213
1230
|
}
|
|
1214
1231
|
}
|
|
1215
1232
|
function sanitizeNormalizedOutput(output, rawOutput, state, index) {
|
|
1216
|
-
const publish = output.publish ? sanitizePublishConfig(
|
|
1233
|
+
const publish = output.publish ? sanitizePublishConfig(
|
|
1234
|
+
output.publish,
|
|
1235
|
+
output.publish,
|
|
1236
|
+
rawOutput,
|
|
1237
|
+
output.delivery,
|
|
1238
|
+
state,
|
|
1239
|
+
index
|
|
1240
|
+
) : void 0;
|
|
1217
1241
|
const publishShape = publish ? { publish } : {};
|
|
1218
1242
|
if (output.delivery !== "github") return { ...output, ...publishShape };
|
|
1219
1243
|
const { credentials, ...github } = output.github;
|
|
@@ -1240,7 +1264,15 @@ function githubOutput(value, publishInfo, rawOutput, language, sourcePath, state
|
|
|
1240
1264
|
);
|
|
1241
1265
|
consume(state, [...sourcePath, "owner"]);
|
|
1242
1266
|
consume(state, [...sourcePath, "repo"]);
|
|
1243
|
-
const publication = publishInfo ? mapPublication(
|
|
1267
|
+
const publication = publishInfo ? mapPublication(
|
|
1268
|
+
publishInfo,
|
|
1269
|
+
rawOutput,
|
|
1270
|
+
language,
|
|
1271
|
+
"github",
|
|
1272
|
+
[...sourcePath, "publishInfo"],
|
|
1273
|
+
state,
|
|
1274
|
+
index
|
|
1275
|
+
) : void 0;
|
|
1244
1276
|
const type = stringValue(value.type);
|
|
1245
1277
|
const licensePackage = mapGithubLicense(value.license, [...sourcePath, "license"], state);
|
|
1246
1278
|
const reviewers = mapReviewers(value.reviewers, [...sourcePath, "reviewers"], state);
|
|
@@ -1333,7 +1365,7 @@ function reviewerNames(value, expectedType, sourcePath, state) {
|
|
|
1333
1365
|
});
|
|
1334
1366
|
return names.length ? names : void 0;
|
|
1335
1367
|
}
|
|
1336
|
-
function mapPublication(value, rawOutput, language, sourcePath, state, index) {
|
|
1368
|
+
function mapPublication(value, rawOutput, language, delivery, sourcePath, state, index) {
|
|
1337
1369
|
if (!isObject(value))
|
|
1338
1370
|
fail(
|
|
1339
1371
|
"FERN_PUBLICATION_INVALID",
|
|
@@ -1354,6 +1386,7 @@ function mapPublication(value, rawOutput, language, sourcePath, state, index) {
|
|
|
1354
1386
|
compact({ registry, url: registryUrl }),
|
|
1355
1387
|
nested,
|
|
1356
1388
|
rawOutput,
|
|
1389
|
+
delivery,
|
|
1357
1390
|
state,
|
|
1358
1391
|
index
|
|
1359
1392
|
);
|
|
@@ -1374,7 +1407,7 @@ function mapPublication(value, rawOutput, language, sourcePath, state, index) {
|
|
|
1374
1407
|
...packageName || Object.keys(metadata).length ? { package: { ...optional("packageName", packageName), ...metadata } } : {}
|
|
1375
1408
|
};
|
|
1376
1409
|
}
|
|
1377
|
-
function sanitizePublishConfig(publish, resolvedPublication, rawOutput, state, index) {
|
|
1410
|
+
function sanitizePublishConfig(publish, resolvedPublication, rawOutput, delivery, state, index) {
|
|
1378
1411
|
const rawPublication = rawOutput?.location === publish.registry ? rawOutput : void 0;
|
|
1379
1412
|
const rawPath = ["group", "generators", index, "output"];
|
|
1380
1413
|
if (publish.registry === "npm" || publish.registry === "crates") {
|
|
@@ -1470,6 +1503,33 @@ function sanitizePublishConfig(publish, resolvedPublication, rawOutput, state, i
|
|
|
1470
1503
|
signature
|
|
1471
1504
|
});
|
|
1472
1505
|
}
|
|
1506
|
+
if (publish.registry === "nuget" || publish.registry === "rubygems") {
|
|
1507
|
+
const apiKey = mapApiKeyExpression(
|
|
1508
|
+
publish.registry,
|
|
1509
|
+
rawPublication,
|
|
1510
|
+
resolvedPublication,
|
|
1511
|
+
rawPath,
|
|
1512
|
+
state,
|
|
1513
|
+
index,
|
|
1514
|
+
fernDefaultApiKey(publish.registry, rawOutput, delivery)
|
|
1515
|
+
);
|
|
1516
|
+
warnForUnexpectedCredentialFields(
|
|
1517
|
+
rawPublication,
|
|
1518
|
+
resolvedPublication,
|
|
1519
|
+
["apiKey"],
|
|
1520
|
+
rawPath,
|
|
1521
|
+
state,
|
|
1522
|
+
index
|
|
1523
|
+
);
|
|
1524
|
+
return compact({
|
|
1525
|
+
registry: publish.registry,
|
|
1526
|
+
url: publish.url,
|
|
1527
|
+
releaseBranch: publish.releaseBranch,
|
|
1528
|
+
tolerateRepublish: publish.tolerateRepublish,
|
|
1529
|
+
apiKey,
|
|
1530
|
+
trustedPublishing: usesTrustedPublishing(rawPublication) || void 0
|
|
1531
|
+
});
|
|
1532
|
+
}
|
|
1473
1533
|
warnForUnrepresentableCredentials(rawPublication, resolvedPublication, rawPath, state, index);
|
|
1474
1534
|
return compact({
|
|
1475
1535
|
registry: publish.registry,
|
|
@@ -1478,11 +1538,19 @@ function sanitizePublishConfig(publish, resolvedPublication, rawOutput, state, i
|
|
|
1478
1538
|
tolerateRepublish: publish.tolerateRepublish
|
|
1479
1539
|
});
|
|
1480
1540
|
}
|
|
1481
|
-
function mapLegacyPublication(value, rawOutput, language, sourcePath, state, index) {
|
|
1541
|
+
function mapLegacyPublication(value, rawOutput, language, delivery, sourcePath, state, index) {
|
|
1482
1542
|
const registry = defaultRegistry(language, sourcePath, index);
|
|
1483
1543
|
const overrides = isObject(value) ? value : {};
|
|
1484
1544
|
const override = isObject(overrides[registry]) ? overrides[registry] : {};
|
|
1485
|
-
return mapPublication(
|
|
1545
|
+
return mapPublication(
|
|
1546
|
+
override,
|
|
1547
|
+
rawOutput,
|
|
1548
|
+
language,
|
|
1549
|
+
delivery,
|
|
1550
|
+
[...sourcePath, registry],
|
|
1551
|
+
state,
|
|
1552
|
+
index
|
|
1553
|
+
);
|
|
1486
1554
|
}
|
|
1487
1555
|
function mapCredentialExpression(rawPublication, resolvedPublication, field, rawPath, state, index) {
|
|
1488
1556
|
const rawValue = rawPublication?.[field];
|
|
@@ -1497,6 +1565,45 @@ function mapCredentialExpression(rawPublication, resolvedPublication, field, raw
|
|
|
1497
1565
|
}
|
|
1498
1566
|
return void 0;
|
|
1499
1567
|
}
|
|
1568
|
+
var TRUSTED_PUBLISHING_VALUES = /* @__PURE__ */ new Set(["OIDC", "<USE_OIDC>"]);
|
|
1569
|
+
function rawApiKeyValue(raw) {
|
|
1570
|
+
return raw?.apiKey ?? raw?.["api-key"];
|
|
1571
|
+
}
|
|
1572
|
+
function usesTrustedPublishing(rawPublication) {
|
|
1573
|
+
const rawValue = rawApiKeyValue(rawPublication);
|
|
1574
|
+
return typeof rawValue === "string" && TRUSTED_PUBLISHING_VALUES.has(rawValue);
|
|
1575
|
+
}
|
|
1576
|
+
function mapApiKeyExpression(registry, rawPublication, resolvedPublication, rawPath, state, index, defaultSecretName) {
|
|
1577
|
+
const rawValue = rawApiKeyValue(rawPublication);
|
|
1578
|
+
if (isEnvironmentExpression(rawValue)) return rawValue;
|
|
1579
|
+
if (usesTrustedPublishing(rawPublication)) return void 0;
|
|
1580
|
+
if (defaultSecretName !== void 0) return defaultSecretName;
|
|
1581
|
+
if (rawValue === void 0 && !hasResolvedCredential(resolvedPublication, "apiKey")) {
|
|
1582
|
+
return void 0;
|
|
1583
|
+
}
|
|
1584
|
+
addCredentialDiagnostic(
|
|
1585
|
+
state,
|
|
1586
|
+
[...rawPath, "apiKey"],
|
|
1587
|
+
["targets", index, "output", "publish", "apiKey"],
|
|
1588
|
+
apiKeyOmissionReason(registry)
|
|
1589
|
+
);
|
|
1590
|
+
return void 0;
|
|
1591
|
+
}
|
|
1592
|
+
function apiKeyOmissionReason(registry) {
|
|
1593
|
+
const label = registry === "nuget" ? "NuGet" : "RubyGems";
|
|
1594
|
+
return `Fern ${label} apiKey is not an exact environment expression naming a secret`;
|
|
1595
|
+
}
|
|
1596
|
+
var FERN_DEFAULT_NUGET_API_KEY = "${NUGET_API_TOKEN}";
|
|
1597
|
+
function fernDefaultApiKey(registry, rawOutput, delivery) {
|
|
1598
|
+
if (registry !== "nuget" || delivery !== "github" || rawOutput?.location !== "nuget") {
|
|
1599
|
+
return void 0;
|
|
1600
|
+
}
|
|
1601
|
+
const rawApiKey = rawApiKeyValue(rawOutput);
|
|
1602
|
+
if (typeof rawApiKey === "string" && TRUSTED_PUBLISHING_VALUES.has(rawApiKey)) {
|
|
1603
|
+
return void 0;
|
|
1604
|
+
}
|
|
1605
|
+
return FERN_DEFAULT_NUGET_API_KEY;
|
|
1606
|
+
}
|
|
1500
1607
|
function mapPypiCredentialExpressions(rawPublication, resolvedPublication, rawPath, state, index) {
|
|
1501
1608
|
const rawToken = rawPublication?.token;
|
|
1502
1609
|
if (isEnvironmentExpression(rawToken)) {
|
|
@@ -2200,6 +2307,29 @@ var mavenSignatureSchema = zod.z.strictObject({
|
|
|
2200
2307
|
"The armored secret key, or an environment expression that resolves to it."
|
|
2201
2308
|
)
|
|
2202
2309
|
});
|
|
2310
|
+
function apiKeySecretSchema(registry, example) {
|
|
2311
|
+
return nonEmptyStringSchema.regex(
|
|
2312
|
+
/^\$\{[A-Za-z_][A-Za-z0-9_]*\}$/,
|
|
2313
|
+
`${registry} apiKey must be an environment expression naming a secret, such as ${example}`
|
|
2314
|
+
);
|
|
2315
|
+
}
|
|
2316
|
+
function apiKeySecretDescription(registry, example) {
|
|
2317
|
+
return `An environment expression naming the repository secret that the generated release workflow reads the ${registry} API key from, such as ${example}. This is a secret name, never the key itself.`;
|
|
2318
|
+
}
|
|
2319
|
+
function trustedPublishingSchema(registry) {
|
|
2320
|
+
return zod.z.boolean().optional().describe(
|
|
2321
|
+
`Whether ${registry} publication uses trusted publishing (OIDC) instead of an API key secret.`
|
|
2322
|
+
);
|
|
2323
|
+
}
|
|
2324
|
+
function refineApiKeyAgainstTrustedPublishing(publish, context) {
|
|
2325
|
+
if (publish.trustedPublishing === true && publish.apiKey !== void 0) {
|
|
2326
|
+
context.addIssue({
|
|
2327
|
+
code: "custom",
|
|
2328
|
+
message: "apiKey must be omitted when trustedPublishing is true",
|
|
2329
|
+
path: ["apiKey"]
|
|
2330
|
+
});
|
|
2331
|
+
}
|
|
2332
|
+
}
|
|
2203
2333
|
var commonPublishShape = {
|
|
2204
2334
|
url: nonEmptyStringSchema.optional().describe("A custom package registry URL."),
|
|
2205
2335
|
releaseBranch: nonEmptyStringSchema.optional().describe("The branch used by generated package release workflows."),
|
|
@@ -2235,12 +2365,16 @@ var sdkConfigV1PublishConfigSchema = zod.z.discriminatedUnion("registry", [
|
|
|
2235
2365
|
}),
|
|
2236
2366
|
zod.z.strictObject({
|
|
2237
2367
|
registry: zod.z.literal("nuget").describe("Publishes the package to a NuGet-compatible registry."),
|
|
2368
|
+
apiKey: apiKeySecretSchema("NuGet", "${NUGET_API_KEY}").optional().describe(apiKeySecretDescription("NuGet", "${NUGET_API_KEY}")),
|
|
2369
|
+
trustedPublishing: trustedPublishingSchema("NuGet"),
|
|
2238
2370
|
...commonPublishShape
|
|
2239
|
-
}),
|
|
2371
|
+
}).superRefine(refineApiKeyAgainstTrustedPublishing),
|
|
2240
2372
|
zod.z.strictObject({
|
|
2241
2373
|
registry: zod.z.literal("rubygems").describe("Publishes the package to a RubyGems-compatible registry."),
|
|
2374
|
+
apiKey: apiKeySecretSchema("RubyGems", "${RUBYGEMS_API_KEY}").optional().describe(apiKeySecretDescription("RubyGems", "${RUBYGEMS_API_KEY}")),
|
|
2375
|
+
trustedPublishing: trustedPublishingSchema("RubyGems"),
|
|
2242
2376
|
...commonPublishShape
|
|
2243
|
-
}),
|
|
2377
|
+
}).superRefine(refineApiKeyAgainstTrustedPublishing),
|
|
2244
2378
|
zod.z.strictObject({
|
|
2245
2379
|
registry: zod.z.literal("crates").describe("Publishes the crate to a Cargo-compatible registry."),
|
|
2246
2380
|
token: nonEmptyStringSchema.optional().describe("The Cargo registry token, or an environment expression that resolves to it."),
|
|
@@ -2298,7 +2432,7 @@ var sdkConfigV1OutputConfigSchema = zod.z.discriminatedUnion(
|
|
|
2298
2432
|
);
|
|
2299
2433
|
var cliDistributionShape = {
|
|
2300
2434
|
distribution: cliDistributionConfigSchema.optional().describe(
|
|
2301
|
-
"CLI release channels
|
|
2435
|
+
"CLI release channels and build attestation settings for the generated release workflow; credentials are GitHub Actions secret names."
|
|
2302
2436
|
)
|
|
2303
2437
|
};
|
|
2304
2438
|
function rejectDistributionWithoutGithub(output, context) {
|
|
@@ -2344,6 +2478,9 @@ var apiImportSettingsSchema = zod.z.strictObject({
|
|
|
2344
2478
|
discriminatedUnionV2: zod.z.boolean().optional().describe("Whether oneOf and anyOf schemas use the newer discriminator inference rules."),
|
|
2345
2479
|
undiscriminatedUnionsWithLiterals: zod.z.boolean().optional().describe("Whether literal-bearing unions remain undiscriminated during import."),
|
|
2346
2480
|
inlineAllOfSchemas: zod.z.boolean().optional().describe("Whether schemas composed with allOf are inlined when possible."),
|
|
2481
|
+
inferDiscriminatedUnionBaseProperties: zod.z.boolean().optional().describe(
|
|
2482
|
+
"Whether properties every discriminated-union variant shares are lifted onto the union."
|
|
2483
|
+
),
|
|
2347
2484
|
resolveSchemaCollisions: zod.z.boolean().optional().describe("Whether colliding imported schema names are resolved automatically."),
|
|
2348
2485
|
asyncApiMessageNaming: zod.z.enum(["v1", "v2"]).optional().describe("The naming strategy used for messages imported from AsyncAPI."),
|
|
2349
2486
|
defaultIntegerFormat: zod.z.enum(["int32", "int64", "uint32", "uint64"]).optional().describe("The integer format used when a schema does not declare one.")
|
|
@@ -2562,7 +2699,7 @@ var pythonGenerationConfigSchema = zod.z.strictObject({
|
|
|
2562
2699
|
additionalInitExports: zod.z.array(additionalInitExportSchema).optional().describe("Additional names re-exported from the package initializer.")
|
|
2563
2700
|
});
|
|
2564
2701
|
var rubyGenerationConfigSchema = zod.z.strictObject({
|
|
2565
|
-
requirePaths: zod.z.array(nonEmptyStringSchema).optional().describe("
|
|
2702
|
+
requirePaths: zod.z.array(nonEmptyStringSchema).optional().describe("Files the generated entry file loads with `require`.")
|
|
2566
2703
|
});
|
|
2567
2704
|
var rustGenerationConfigSchema = zod.z.strictObject({
|
|
2568
2705
|
/**
|
|
@@ -3293,7 +3430,12 @@ function mapCommonConfig(language, config, state, client, generation, packageCon
|
|
|
3293
3430
|
}
|
|
3294
3431
|
const pythonClient = language === "python" ? takeObject(config, ["client"], state, basePath) : void 0;
|
|
3295
3432
|
const typescriptNaming = language === "typescript" || language === "mcp" ? takeObject(config, ["naming"], state, basePath) : void 0;
|
|
3296
|
-
const directClientName = takeString(
|
|
3433
|
+
const directClientName = takeString(
|
|
3434
|
+
config,
|
|
3435
|
+
language === "ruby" ? ["clientName"] : ["clientName", "clientClassName"],
|
|
3436
|
+
state,
|
|
3437
|
+
basePath
|
|
3438
|
+
);
|
|
3297
3439
|
const nestedClientName = pythonClient ? takeString(pythonClient.value, ["className"], state, pythonClient.path) : typescriptNaming ? takeString(typescriptNaming.value, ["client"], state, typescriptNaming.path) : language === "ruby" ? (
|
|
3298
3440
|
// Fern's Ruby generator renames the root client class (`Auth0::Management`) with it.
|
|
3299
3441
|
takeString(config, ["clientModuleName"], state, basePath)
|