@fern-api/fern-api-dev 5.44.13 → 5.44.14
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/cli.cjs +62 -35
- package/package.json +1 -1
package/cli.cjs
CHANGED
|
@@ -669566,7 +669566,7 @@ var AccessTokenPosthogManager = class {
|
|
|
669566
669566
|
properties: {
|
|
669567
669567
|
...event,
|
|
669568
669568
|
...event.properties,
|
|
669569
|
-
version: "5.44.
|
|
669569
|
+
version: "5.44.14",
|
|
669570
669570
|
usingAccessToken: true,
|
|
669571
669571
|
...getRunIdProperties()
|
|
669572
669572
|
}
|
|
@@ -669630,7 +669630,7 @@ var UserPosthogManager = class {
|
|
|
669630
669630
|
distinctId: this.userId ?? await this.getPersistedDistinctId(),
|
|
669631
669631
|
event: "CLI",
|
|
669632
669632
|
properties: {
|
|
669633
|
-
version: "5.44.
|
|
669633
|
+
version: "5.44.14",
|
|
669634
669634
|
...event,
|
|
669635
669635
|
...event.properties,
|
|
669636
669636
|
usingAccessToken: false,
|
|
@@ -861371,7 +861371,7 @@ var LOCAL_STORAGE_FOLDER4 = ".fern-dev";
|
|
|
861371
861371
|
var LOGS_FOLDER_NAME = "logs";
|
|
861372
861372
|
var MAX_LOGS_DIR_SIZE_BYTES = 100 * 1024 * 1024;
|
|
861373
861373
|
function getCliSource() {
|
|
861374
|
-
const version7 = "5.44.
|
|
861374
|
+
const version7 = "5.44.14";
|
|
861375
861375
|
return `cli@${version7}`;
|
|
861376
861376
|
}
|
|
861377
861377
|
var DebugLogger = class {
|
|
@@ -892463,7 +892463,7 @@ var LegacyDocsPublisher = class {
|
|
|
892463
892463
|
previewId,
|
|
892464
892464
|
disableTemplates: void 0,
|
|
892465
892465
|
skipUpload,
|
|
892466
|
-
cliVersion: "5.44.
|
|
892466
|
+
cliVersion: "5.44.14",
|
|
892467
892467
|
loginCommand: "fern auth login"
|
|
892468
892468
|
});
|
|
892469
892469
|
if (taskContext.getResult() === TaskResult.Failure) {
|
|
@@ -923897,7 +923897,7 @@ var DynamicTypeLiteralMapper2 = class {
|
|
|
923897
923897
|
name: this.context.getClassName(discriminatedUnion2.declaration.name),
|
|
923898
923898
|
namespace: this.context.getTypesNamespace(discriminatedUnion2.declaration.fernFilepath)
|
|
923899
923899
|
}),
|
|
923900
|
-
method: this.context.
|
|
923900
|
+
method: this.context.getPropertyName(unionVariant.discriminantValue.name),
|
|
923901
923901
|
arguments_: this.convertDiscriminatedUnionVariantArgs({
|
|
923902
923902
|
discriminatedUnionTypeInstance,
|
|
923903
923903
|
unionVariant,
|
|
@@ -923942,12 +923942,14 @@ var DynamicTypeLiteralMapper2 = class {
|
|
|
923942
923942
|
}
|
|
923943
923943
|
];
|
|
923944
923944
|
}
|
|
923945
|
+
const wireValue = unionVariant.discriminantValue.wireValue;
|
|
923946
|
+
const singlePropertyValue = record23[wireValue] ?? record23["value"];
|
|
923945
923947
|
return [
|
|
923946
923948
|
{
|
|
923947
923949
|
name: this.context.getPropertyName(unionVariant.discriminantValue.name),
|
|
923948
923950
|
value: this.convert({
|
|
923949
923951
|
typeReference: unionVariant.typeReference,
|
|
923950
|
-
value:
|
|
923952
|
+
value: singlePropertyValue
|
|
923951
923953
|
})
|
|
923952
923954
|
}
|
|
923953
923955
|
];
|
|
@@ -923962,20 +923964,14 @@ var DynamicTypeLiteralMapper2 = class {
|
|
|
923962
923964
|
}
|
|
923963
923965
|
}
|
|
923964
923966
|
convertDiscriminatedUnionVariantArgs({ discriminatedUnionTypeInstance, unionVariant, unionProperties }) {
|
|
923965
|
-
const
|
|
923967
|
+
const { required: requiredBaseFields, optional: optionalBaseFields } = this.getBaseFields({
|
|
923966
923968
|
discriminatedUnionTypeInstance,
|
|
923967
923969
|
singleDiscriminatedUnionType: unionVariant
|
|
923968
923970
|
});
|
|
923969
923971
|
if (unionVariant.type === "singleProperty") {
|
|
923970
|
-
const
|
|
923971
|
-
if (
|
|
923972
|
-
return [
|
|
923973
|
-
...baseFields,
|
|
923974
|
-
this.convert({
|
|
923975
|
-
typeReference: unionVariant.typeReference,
|
|
923976
|
-
value: discriminatedUnionTypeInstance.value
|
|
923977
|
-
})
|
|
923978
|
-
];
|
|
923972
|
+
const singleProperty = unionProperties[0];
|
|
923973
|
+
if (singleProperty != null) {
|
|
923974
|
+
return [...requiredBaseFields, singleProperty.value, ...optionalBaseFields];
|
|
923979
923975
|
}
|
|
923980
923976
|
}
|
|
923981
923977
|
if (unionVariant.type === "samePropertiesAsObject") {
|
|
@@ -923986,17 +923982,18 @@ var DynamicTypeLiteralMapper2 = class {
|
|
|
923986
923982
|
return [];
|
|
923987
923983
|
}
|
|
923988
923984
|
return [
|
|
923989
|
-
...
|
|
923985
|
+
...requiredBaseFields,
|
|
923990
923986
|
php_exports.TypeLiteral.class_({
|
|
923991
923987
|
reference: php_exports.classReference({
|
|
923992
923988
|
name: this.context.getClassName(named.declaration.name),
|
|
923993
923989
|
namespace: this.context.getTypesNamespace(named.declaration.fernFilepath)
|
|
923994
923990
|
}),
|
|
923995
923991
|
fields: unionProperties
|
|
923996
|
-
})
|
|
923992
|
+
}),
|
|
923993
|
+
...optionalBaseFields
|
|
923997
923994
|
];
|
|
923998
923995
|
}
|
|
923999
|
-
return
|
|
923996
|
+
return [...requiredBaseFields, ...optionalBaseFields];
|
|
924000
923997
|
}
|
|
924001
923998
|
getBaseFields({ discriminatedUnionTypeInstance, singleDiscriminatedUnionType }) {
|
|
924002
923999
|
const properties7 = this.context.associateByWireValue({
|
|
@@ -924006,14 +924003,22 @@ var DynamicTypeLiteralMapper2 = class {
|
|
|
924006
924003
|
// are handled by the union variant.
|
|
924007
924004
|
ignoreMissingParameters: true
|
|
924008
924005
|
});
|
|
924009
|
-
|
|
924006
|
+
const required6 = [];
|
|
924007
|
+
const optional23 = [];
|
|
924008
|
+
for (const property24 of properties7) {
|
|
924010
924009
|
this.context.errors.scope(property24.name.wireValue);
|
|
924011
924010
|
try {
|
|
924012
|
-
|
|
924011
|
+
const converted = this.convert(property24);
|
|
924012
|
+
if (this.isOptionalOrNullable(property24.typeReference)) {
|
|
924013
|
+
optional23.push(converted);
|
|
924014
|
+
} else {
|
|
924015
|
+
required6.push(converted);
|
|
924016
|
+
}
|
|
924013
924017
|
} finally {
|
|
924014
924018
|
this.context.errors.unscope();
|
|
924015
924019
|
}
|
|
924016
|
-
}
|
|
924020
|
+
}
|
|
924021
|
+
return { required: required6, optional: optional23 };
|
|
924017
924022
|
}
|
|
924018
924023
|
convertObject({ object_, value: value2 }) {
|
|
924019
924024
|
const record23 = this.context.getRecord(value2) ?? {};
|
|
@@ -957624,7 +957629,7 @@ function getAutomationContextFromEnv() {
|
|
|
957624
957629
|
config_branch: process.env.FERN_CONFIG_BRANCH,
|
|
957625
957630
|
config_pr_number: process.env.FERN_CONFIG_PR_NUMBER,
|
|
957626
957631
|
trigger: process.env.GITHUB_EVENT_NAME,
|
|
957627
|
-
cli_version: "5.44.
|
|
957632
|
+
cli_version: "5.44.14"
|
|
957628
957633
|
};
|
|
957629
957634
|
}
|
|
957630
957635
|
function isAutomationMode() {
|
|
@@ -958450,7 +958455,7 @@ var CliContext = class _CliContext {
|
|
|
958450
958455
|
if (false) {
|
|
958451
958456
|
this.logger.error("CLI_VERSION is not defined");
|
|
958452
958457
|
}
|
|
958453
|
-
return "5.44.
|
|
958458
|
+
return "5.44.14";
|
|
958454
958459
|
}
|
|
958455
958460
|
getCliName() {
|
|
958456
958461
|
if (false) {
|
|
@@ -968478,10 +968483,11 @@ function convertHttpEndpoint4({
|
|
|
968478
968483
|
if (url3 == null) {
|
|
968479
968484
|
throw new CliError({ message: "No URL defined for " + baseUrlId, code: CliError.Code.InternalError });
|
|
968480
968485
|
}
|
|
968481
|
-
const
|
|
968482
|
-
|
|
968483
|
-
|
|
968484
|
-
|
|
968486
|
+
const envName = getOriginalName(environment2.name);
|
|
968487
|
+
const server = {
|
|
968488
|
+
url: url3,
|
|
968489
|
+
description: environment2.docs != null ? `${envName} (${environment2.docs})` : envName
|
|
968490
|
+
};
|
|
968485
968491
|
return server;
|
|
968486
968492
|
});
|
|
968487
968493
|
}
|
|
@@ -969156,13 +969162,34 @@ function convertIrToOpenApi({
|
|
|
969156
969162
|
securitySchemes: constructSecuritySchemes(ir11.auth)
|
|
969157
969163
|
}
|
|
969158
969164
|
};
|
|
969159
|
-
if (ir11.environments != null
|
|
969160
|
-
|
|
969161
|
-
|
|
969162
|
-
|
|
969163
|
-
|
|
969164
|
-
|
|
969165
|
-
|
|
969165
|
+
if (ir11.environments != null) {
|
|
969166
|
+
const envs = ir11.environments.environments;
|
|
969167
|
+
if (envs.type === "singleBaseUrl") {
|
|
969168
|
+
openAPISpec.servers = envs.environments.map((environment2) => {
|
|
969169
|
+
return {
|
|
969170
|
+
url: environment2.url,
|
|
969171
|
+
description: environment2.docs != null ? `${getOriginalName(environment2.name)} (${environment2.docs})` : getOriginalName(environment2.name)
|
|
969172
|
+
};
|
|
969173
|
+
});
|
|
969174
|
+
} else if (envs.type === "multipleBaseUrls") {
|
|
969175
|
+
const servers = [];
|
|
969176
|
+
for (const environment2 of envs.environments) {
|
|
969177
|
+
const envName = getOriginalName(environment2.name);
|
|
969178
|
+
for (const baseUrlDef of envs.baseUrls) {
|
|
969179
|
+
const url3 = environment2.urls[baseUrlDef.id];
|
|
969180
|
+
if (url3 != null) {
|
|
969181
|
+
const urlName = getOriginalName(baseUrlDef.name);
|
|
969182
|
+
servers.push({
|
|
969183
|
+
url: url3,
|
|
969184
|
+
description: environment2.docs != null ? `${envName} - ${urlName} (${environment2.docs})` : `${envName} (${urlName})`
|
|
969185
|
+
});
|
|
969186
|
+
}
|
|
969187
|
+
}
|
|
969188
|
+
}
|
|
969189
|
+
if (servers.length > 0) {
|
|
969190
|
+
openAPISpec.servers = servers;
|
|
969191
|
+
}
|
|
969192
|
+
}
|
|
969166
969193
|
}
|
|
969167
969194
|
return openAPISpec;
|
|
969168
969195
|
}
|
package/package.json
CHANGED