@fern-api/fern-api-dev 5.7.0 → 5.7.1-10-g7c1556603e5
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 +144 -120
- package/package.json +1 -1
package/cli.cjs
CHANGED
|
@@ -489185,6 +489185,7 @@ var ObjectProperty = schemas_exports3.objectWithoutOptionalProperties({
|
|
|
489185
489185
|
name: NameAndWireValueOrString,
|
|
489186
489186
|
valueType: schemas_exports3.lazy(() => TypeReference3),
|
|
489187
489187
|
propertyAccess: ObjectPropertyAccess5.optional(),
|
|
489188
|
+
defaultValue: schemas_exports3.unknown().optional(),
|
|
489188
489189
|
v2Examples: V2SchemaExamples.optional()
|
|
489189
489190
|
}).extend(Declaration);
|
|
489190
489191
|
|
|
@@ -489254,6 +489255,7 @@ var QueryParameter = schemas_exports3.objectWithoutOptionalProperties({
|
|
|
489254
489255
|
valueType: schemas_exports3.lazy(() => TypeReference3),
|
|
489255
489256
|
allowMultiple: schemas_exports3.boolean(),
|
|
489256
489257
|
clientDefault: Literal2.optional(),
|
|
489258
|
+
defaultValue: schemas_exports3.unknown().optional(),
|
|
489257
489259
|
v2Examples: V2SchemaExamples.optional(),
|
|
489258
489260
|
explode: schemas_exports3.boolean().optional()
|
|
489259
489261
|
}).extend(Declaration);
|
|
@@ -490594,6 +490596,7 @@ var HttpHeader = schemas_exports3.objectWithoutOptionalProperties({
|
|
|
490594
490596
|
valueType: schemas_exports3.lazy(() => TypeReference3),
|
|
490595
490597
|
env: schemas_exports3.string().optional(),
|
|
490596
490598
|
clientDefault: Literal2.optional(),
|
|
490599
|
+
defaultValue: schemas_exports3.unknown().optional(),
|
|
490597
490600
|
v2Examples: V2SchemaExamples.optional()
|
|
490598
490601
|
}).extend(Declaration);
|
|
490599
490602
|
|
|
@@ -491670,6 +491673,7 @@ var FileUploadBodyPropertyEncoding2 = schemas_exports3.enum_(["exploded", "json"
|
|
|
491670
491673
|
var InlinedRequestBodyProperty = schemas_exports3.objectWithoutOptionalProperties({
|
|
491671
491674
|
name: NameAndWireValueOrString,
|
|
491672
491675
|
valueType: schemas_exports3.lazy(() => TypeReference3),
|
|
491676
|
+
defaultValue: schemas_exports3.unknown().optional(),
|
|
491673
491677
|
v2Examples: V2SchemaExamples.optional(),
|
|
491674
491678
|
propertyAccess: ObjectPropertyAccess5.optional()
|
|
491675
491679
|
}).extend(WithDocsAndAvailability);
|
|
@@ -494717,7 +494721,7 @@ function visitEndpoint({ endpointId, endpoint: endpoint3, service, visitor, node
|
|
|
494717
494721
|
availability: noop2,
|
|
494718
494722
|
type: (type8) => {
|
|
494719
494723
|
visitTypeReference(type8, [...nodePathForQueryParameter, "type"], {
|
|
494720
|
-
_default: queryParameter.default,
|
|
494724
|
+
_default: shouldSkipDefaultValidation(queryParameter) ? void 0 : queryParameter.default,
|
|
494721
494725
|
validation: queryParameter.validation
|
|
494722
494726
|
});
|
|
494723
494727
|
},
|
|
@@ -495080,6 +495084,9 @@ function visitHeaders({ headers: headers2, visitor, nodePath }) {
|
|
|
495080
495084
|
}
|
|
495081
495085
|
}
|
|
495082
495086
|
}
|
|
495087
|
+
function shouldSkipDefaultValidation(queryParameter) {
|
|
495088
|
+
return queryParameter["allow-multiple"] === true && Array.isArray(queryParameter.default);
|
|
495089
|
+
}
|
|
495083
495090
|
|
|
495084
495091
|
// ../fern-definition/validator/lib/ast/visitors/visitErrorDeclarations.js
|
|
495085
495092
|
init_lib4();
|
|
@@ -512005,7 +512012,6 @@ __export(schemas_exports7, {
|
|
|
512005
512012
|
HeaderPosition: () => HeaderPosition2,
|
|
512006
512013
|
HttpSnippetLanguage: () => HttpSnippetLanguage2,
|
|
512007
512014
|
JsScriptStrategy: () => JsScriptStrategy2,
|
|
512008
|
-
Language: () => Language2,
|
|
512009
512015
|
LanguageSwitcherThemeConfig: () => LanguageSwitcherThemeConfig2,
|
|
512010
512016
|
LibraryLanguage: () => LibraryLanguage2,
|
|
512011
512017
|
OgDynamicLogoColor: () => OgDynamicLogoColor,
|
|
@@ -512048,7 +512054,6 @@ __export(api_exports2, {
|
|
|
512048
512054
|
HeaderPosition: () => HeaderPosition2,
|
|
512049
512055
|
HttpSnippetLanguage: () => HttpSnippetLanguage2,
|
|
512050
512056
|
JsScriptStrategy: () => JsScriptStrategy2,
|
|
512051
|
-
Language: () => Language2,
|
|
512052
512057
|
LanguageSwitcherThemeConfig: () => LanguageSwitcherThemeConfig2,
|
|
512053
512058
|
LibraryLanguage: () => LibraryLanguage2,
|
|
512054
512059
|
OgDynamicLogoColor: () => OgDynamicLogoColor,
|
|
@@ -512088,7 +512093,6 @@ __export(docs_exports, {
|
|
|
512088
512093
|
HeaderPosition: () => HeaderPosition2,
|
|
512089
512094
|
HttpSnippetLanguage: () => HttpSnippetLanguage2,
|
|
512090
512095
|
JsScriptStrategy: () => JsScriptStrategy2,
|
|
512091
|
-
Language: () => Language2,
|
|
512092
512096
|
LanguageSwitcherThemeConfig: () => LanguageSwitcherThemeConfig2,
|
|
512093
512097
|
LibraryLanguage: () => LibraryLanguage2,
|
|
512094
512098
|
OgDynamicLogoColor: () => OgDynamicLogoColor,
|
|
@@ -512214,25 +512218,6 @@ var JsScriptStrategy2 = {
|
|
|
512214
512218
|
LazyOnload: "lazyOnload"
|
|
512215
512219
|
};
|
|
512216
512220
|
|
|
512217
|
-
// ../configuration/lib/docs-yml/schemas/sdk/api/resources/docs/types/Language.js
|
|
512218
|
-
var Language2 = {
|
|
512219
|
-
En: "en",
|
|
512220
|
-
Es: "es",
|
|
512221
|
-
Fr: "fr",
|
|
512222
|
-
De: "de",
|
|
512223
|
-
It: "it",
|
|
512224
|
-
Pt: "pt",
|
|
512225
|
-
Ja: "ja",
|
|
512226
|
-
Zh: "zh",
|
|
512227
|
-
Ko: "ko",
|
|
512228
|
-
El: "el",
|
|
512229
|
-
No: "no",
|
|
512230
|
-
Pl: "pl",
|
|
512231
|
-
Ru: "ru",
|
|
512232
|
-
Sv: "sv",
|
|
512233
|
-
Tr: "tr"
|
|
512234
|
-
};
|
|
512235
|
-
|
|
512236
512221
|
// ../configuration/lib/docs-yml/schemas/sdk/api/resources/docs/types/LanguageSwitcherThemeConfig.js
|
|
512237
512222
|
var LanguageSwitcherThemeConfig2 = {
|
|
512238
512223
|
Default: "default",
|
|
@@ -512644,7 +512629,7 @@ __export(serialization_exports3, {
|
|
|
512644
512629
|
JsFileConfigSettings: () => JsFileConfigSettings2,
|
|
512645
512630
|
JsRemoteConfig: () => JsRemoteConfig2,
|
|
512646
512631
|
JsScriptStrategy: () => JsScriptStrategy3,
|
|
512647
|
-
Language: () =>
|
|
512632
|
+
Language: () => Language2,
|
|
512648
512633
|
LanguageSwitcherThemeConfig: () => LanguageSwitcherThemeConfig3,
|
|
512649
512634
|
LayoutConfig: () => LayoutConfig2,
|
|
512650
512635
|
LibraryConfig: () => LibraryConfig,
|
|
@@ -512798,7 +512783,7 @@ __export(docs_exports2, {
|
|
|
512798
512783
|
JsFileConfigSettings: () => JsFileConfigSettings2,
|
|
512799
512784
|
JsRemoteConfig: () => JsRemoteConfig2,
|
|
512800
512785
|
JsScriptStrategy: () => JsScriptStrategy3,
|
|
512801
|
-
Language: () =>
|
|
512786
|
+
Language: () => Language2,
|
|
512802
512787
|
LanguageSwitcherThemeConfig: () => LanguageSwitcherThemeConfig3,
|
|
512803
512788
|
LayoutConfig: () => LayoutConfig2,
|
|
512804
512789
|
LibraryConfig: () => LibraryConfig,
|
|
@@ -514771,23 +514756,7 @@ var HttpSnippetsConfig2 = schemas_exports6.undiscriminatedUnion([
|
|
|
514771
514756
|
]);
|
|
514772
514757
|
|
|
514773
514758
|
// ../configuration/lib/docs-yml/schemas/sdk/serialization/resources/docs/types/Language.js
|
|
514774
|
-
var
|
|
514775
|
-
"en",
|
|
514776
|
-
"es",
|
|
514777
|
-
"fr",
|
|
514778
|
-
"de",
|
|
514779
|
-
"it",
|
|
514780
|
-
"pt",
|
|
514781
|
-
"ja",
|
|
514782
|
-
"zh",
|
|
514783
|
-
"ko",
|
|
514784
|
-
"el",
|
|
514785
|
-
"no",
|
|
514786
|
-
"pl",
|
|
514787
|
-
"ru",
|
|
514788
|
-
"sv",
|
|
514789
|
-
"tr"
|
|
514790
|
-
]);
|
|
514759
|
+
var Language2 = schemas_exports6.string();
|
|
514791
514760
|
|
|
514792
514761
|
// ../configuration/lib/docs-yml/schemas/sdk/serialization/resources/docs/types/TitleSource.js
|
|
514793
514762
|
var TitleSource3 = schemas_exports6.enum_(["frontmatter", "filename"]);
|
|
@@ -514807,7 +514776,7 @@ var DocsSettingsConfig2 = schemas_exports6.object({
|
|
|
514807
514776
|
disableExplorerProxy: schemas_exports6.property("disable-explorer-proxy", schemas_exports6.boolean().optional()),
|
|
514808
514777
|
disableEnvironmentEditing: schemas_exports6.property("disable-environment-editing", schemas_exports6.boolean().optional()),
|
|
514809
514778
|
disableAnalytics: schemas_exports6.property("disable-analytics", schemas_exports6.boolean().optional()),
|
|
514810
|
-
language:
|
|
514779
|
+
language: Language2.optional(),
|
|
514811
514780
|
folderTitleSource: schemas_exports6.property("folder-title-source", TitleSource3.optional()),
|
|
514812
514781
|
substituteEnvVars: schemas_exports6.property("substitute-env-vars", schemas_exports6.boolean().optional()),
|
|
514813
514782
|
websocketOneofDisplay: schemas_exports6.property("websocket-oneof-display", WebSocketOneofDisplay2.optional())
|
|
@@ -515267,12 +515236,12 @@ var ThemeConfig2 = schemas_exports6.object({
|
|
|
515267
515236
|
|
|
515268
515237
|
// ../configuration/lib/docs-yml/schemas/sdk/serialization/resources/docs/types/TranslationConfigObject.js
|
|
515269
515238
|
var TranslationConfigObject2 = schemas_exports6.object({
|
|
515270
|
-
lang:
|
|
515239
|
+
lang: Language2,
|
|
515271
515240
|
default: schemas_exports6.boolean().optional()
|
|
515272
515241
|
});
|
|
515273
515242
|
|
|
515274
515243
|
// ../configuration/lib/docs-yml/schemas/sdk/serialization/resources/docs/types/TranslationConfig.js
|
|
515275
|
-
var TranslationConfig2 = schemas_exports6.undiscriminatedUnion([
|
|
515244
|
+
var TranslationConfig2 = schemas_exports6.undiscriminatedUnion([Language2, TranslationConfigObject2]);
|
|
515276
515245
|
|
|
515277
515246
|
// ../configuration/lib/docs-yml/schemas/sdk/serialization/resources/docs/types/DocsConfiguration.js
|
|
515278
515247
|
var DocsConfiguration2 = schemas_exports6.object({
|
|
@@ -515425,7 +515394,7 @@ __export(generators_yml_exports, {
|
|
|
515425
515394
|
GithubCommitAndReleaseMode: () => GithubCommitAndReleaseMode,
|
|
515426
515395
|
GithubLicenseType: () => GithubLicenseType,
|
|
515427
515396
|
GithubSelfhostedMode: () => GithubSelfhostedMode,
|
|
515428
|
-
Language: () =>
|
|
515397
|
+
Language: () => Language3,
|
|
515429
515398
|
MessageNamingSettingsSchema: () => MessageNamingSettingsSchema,
|
|
515430
515399
|
ModelProvider: () => ModelProvider,
|
|
515431
515400
|
MultiServerStrategy: () => MultiServerStrategy,
|
|
@@ -515607,7 +515576,7 @@ __export(generators_exports, {
|
|
|
515607
515576
|
DefaultIntegerFormat: () => DefaultIntegerFormat,
|
|
515608
515577
|
ExampleStyle: () => ExampleStyle3,
|
|
515609
515578
|
FormParameterEncoding: () => FormParameterEncoding,
|
|
515610
|
-
Language: () =>
|
|
515579
|
+
Language: () => Language3,
|
|
515611
515580
|
MessageNamingSettingsSchema: () => MessageNamingSettingsSchema,
|
|
515612
515581
|
MultiServerStrategy: () => MultiServerStrategy,
|
|
515613
515582
|
PathParameterOrder: () => PathParameterOrder,
|
|
@@ -515643,7 +515612,7 @@ var FormParameterEncoding = {
|
|
|
515643
515612
|
};
|
|
515644
515613
|
|
|
515645
515614
|
// ../configuration/lib/generators-yml/schemas/api/resources/generators/types/Language.js
|
|
515646
|
-
var
|
|
515615
|
+
var Language3 = {
|
|
515647
515616
|
Java: "java",
|
|
515648
515617
|
Python: "python",
|
|
515649
515618
|
Go: "go",
|
|
@@ -515769,7 +515738,7 @@ __export(serialization_exports4, {
|
|
|
515769
515738
|
GithubSelfhostedMode: () => GithubSelfhostedMode2,
|
|
515770
515739
|
GithubSelfhostedSchema: () => GithubSelfhostedSchema,
|
|
515771
515740
|
GraphQlSpecSchema: () => GraphQlSpecSchema,
|
|
515772
|
-
Language: () =>
|
|
515741
|
+
Language: () => Language4,
|
|
515773
515742
|
LocalFileSystemOutputLocationSchema: () => LocalFileSystemOutputLocationSchema,
|
|
515774
515743
|
MavenOutputLocationSchema: () => MavenOutputLocationSchema,
|
|
515775
515744
|
MavenOutputSignatureSchema: () => MavenOutputSignatureSchema,
|
|
@@ -517749,7 +517718,7 @@ __export(generators_exports2, {
|
|
|
517749
517718
|
GeneratorsOpenApiObjectSchema: () => GeneratorsOpenApiObjectSchema,
|
|
517750
517719
|
GeneratorsOpenApiSchema: () => GeneratorsOpenApiSchema,
|
|
517751
517720
|
GraphQlSpecSchema: () => GraphQlSpecSchema,
|
|
517752
|
-
Language: () =>
|
|
517721
|
+
Language: () => Language4,
|
|
517753
517722
|
MessageNamingSettingsSchema: () => MessageNamingSettingsSchema2,
|
|
517754
517723
|
MultiServerStrategy: () => MultiServerStrategy2,
|
|
517755
517724
|
NamespacedApiConfigurationSchema: () => NamespacedApiConfigurationSchema,
|
|
@@ -518279,12 +518248,12 @@ var GeneratorsOpenApiObjectSchema = schemas_exports8.object({
|
|
|
518279
518248
|
var GeneratorsOpenApiSchema = schemas_exports8.undiscriminatedUnion([GeneratorsOpenApiObjectSchema, schemas_exports8.string()]);
|
|
518280
518249
|
|
|
518281
518250
|
// ../configuration/lib/generators-yml/schemas/serialization/resources/generators/types/Language.js
|
|
518282
|
-
var
|
|
518251
|
+
var Language4 = schemas_exports8.enum_(["java", "python", "go", "ruby", "csharp", "typescript", "php", "rust", "swift"]);
|
|
518283
518252
|
|
|
518284
518253
|
// ../configuration/lib/generators-yml/schemas/serialization/resources/generators/types/ReadmeCustomSectionSchema.js
|
|
518285
518254
|
var ReadmeCustomSectionSchema = schemas_exports8.object({
|
|
518286
518255
|
title: schemas_exports8.string(),
|
|
518287
|
-
language:
|
|
518256
|
+
language: Language4,
|
|
518288
518257
|
content: schemas_exports8.string()
|
|
518289
518258
|
});
|
|
518290
518259
|
|
|
@@ -520809,24 +520778,22 @@ function stringifyValidationError5(error50) {
|
|
|
520809
520778
|
}
|
|
520810
520779
|
|
|
520811
520780
|
// ../api-importers/openapi/openapi-ir/lib/sdk/core/schemas/builders/schema-utils/JsonError.js
|
|
520812
|
-
var JsonError5 = class extends Error {
|
|
520781
|
+
var JsonError5 = class _JsonError extends Error {
|
|
520813
520782
|
errors;
|
|
520814
520783
|
constructor(errors4) {
|
|
520815
520784
|
super(errors4.map(stringifyValidationError5).join("; "));
|
|
520816
520785
|
this.errors = errors4;
|
|
520817
|
-
Object.setPrototypeOf(this,
|
|
520818
|
-
this.name = this.constructor.name;
|
|
520786
|
+
Object.setPrototypeOf(this, _JsonError.prototype);
|
|
520819
520787
|
}
|
|
520820
520788
|
};
|
|
520821
520789
|
|
|
520822
520790
|
// ../api-importers/openapi/openapi-ir/lib/sdk/core/schemas/builders/schema-utils/ParseError.js
|
|
520823
|
-
var ParseError5 = class extends Error {
|
|
520791
|
+
var ParseError5 = class _ParseError extends Error {
|
|
520824
520792
|
errors;
|
|
520825
520793
|
constructor(errors4) {
|
|
520826
520794
|
super(errors4.map(stringifyValidationError5).join("; "));
|
|
520827
520795
|
this.errors = errors4;
|
|
520828
|
-
Object.setPrototypeOf(this,
|
|
520829
|
-
this.name = this.constructor.name;
|
|
520796
|
+
Object.setPrototypeOf(this, _ParseError.prototype);
|
|
520830
520797
|
}
|
|
520831
520798
|
};
|
|
520832
520799
|
|
|
@@ -522657,7 +522624,8 @@ var AllOfPropertyConflict = schemas_exports9.objectWithoutOptionalProperties({
|
|
|
522657
522624
|
var ArraySchema = schemas_exports9.objectWithoutOptionalProperties({
|
|
522658
522625
|
value: schemas_exports9.lazy(() => Schema2),
|
|
522659
522626
|
minItems: schemas_exports9.number().optional(),
|
|
522660
|
-
maxItems: schemas_exports9.number().optional()
|
|
522627
|
+
maxItems: schemas_exports9.number().optional(),
|
|
522628
|
+
default: schemas_exports9.unknown().optional()
|
|
522661
522629
|
}).extend(WithSdkGroupName).extend(WithNamespace).extend(WithName3).extend(WithDescription).extend(WithAvailability3).extend(WithTitle).extend(WithInline);
|
|
522662
522630
|
|
|
522663
522631
|
// ../api-importers/openapi/openapi-ir/lib/sdk/serialization/resources/finalIr/types/AsymmetricAlgorithm.js
|
|
@@ -523628,7 +523596,8 @@ var ArraySchemaWithExample = schemas_exports9.objectWithoutOptionalProperties({
|
|
|
523628
523596
|
value: schemas_exports9.lazy(() => SchemaWithExample2),
|
|
523629
523597
|
minItems: schemas_exports9.number().optional(),
|
|
523630
523598
|
maxItems: schemas_exports9.number().optional(),
|
|
523631
|
-
example: schemas_exports9.list(schemas_exports9.unknown()).optional()
|
|
523599
|
+
example: schemas_exports9.list(schemas_exports9.unknown()).optional(),
|
|
523600
|
+
default: schemas_exports9.unknown().optional()
|
|
523632
523601
|
}).extend(WithSdkGroupName).extend(WithNamespace).extend(WithName3).extend(WithDescription).extend(WithAvailability3).extend(WithTitle).extend(WithInline);
|
|
523633
523602
|
|
|
523634
523603
|
// ../api-importers/openapi/openapi-ir/lib/sdk/serialization/resources/parseIr/types/Base64WithExample.js
|
|
@@ -524905,12 +524874,13 @@ function buildArrayTypeReference({ schema: schema2, fileContainingReference, dec
|
|
|
524905
524874
|
variant
|
|
524906
524875
|
});
|
|
524907
524876
|
const type8 = `list<${getTypeFromTypeReference(item)}>`;
|
|
524908
|
-
if (schema2.description == null && schema2.title == null) {
|
|
524877
|
+
if (schema2.description == null && schema2.title == null && schema2.default == null) {
|
|
524909
524878
|
return type8;
|
|
524910
524879
|
}
|
|
524911
524880
|
return {
|
|
524912
524881
|
...schema2.description != null ? { docs: schema2.description } : {},
|
|
524913
524882
|
...schema2.availability != null ? { availability: convertAvailability(schema2.availability) } : {},
|
|
524883
|
+
...schema2.default != null ? { default: schema2.default } : {},
|
|
524914
524884
|
type: type8
|
|
524915
524885
|
};
|
|
524916
524886
|
}
|
|
@@ -525962,9 +525932,10 @@ function buildHeader({ header, context: context3, fileContainingReference, names
|
|
|
525962
525932
|
declarationDepth: 0
|
|
525963
525933
|
});
|
|
525964
525934
|
const headerType = getTypeFromTypeReference(typeReference2);
|
|
525935
|
+
const headerDefault = getDefaultFromTypeReference(typeReference2);
|
|
525965
525936
|
const headerWithoutXPrefix = header.name.replace(/^x-|^X-/, "");
|
|
525966
525937
|
const headerVariableName = header.parameterNameOverride != null ? header.parameterNameOverride : camelCase_default(headerWithoutXPrefix);
|
|
525967
|
-
if (header.description == null && header.name === headerVariableName && header.env == null && header.availability == null && header.clientDefault == null) {
|
|
525938
|
+
if (header.description == null && header.name === headerVariableName && header.env == null && header.availability == null && header.clientDefault == null && headerDefault == null) {
|
|
525968
525939
|
return headerType;
|
|
525969
525940
|
}
|
|
525970
525941
|
const headerSchema = {
|
|
@@ -525985,6 +525956,9 @@ function buildHeader({ header, context: context3, fileContainingReference, names
|
|
|
525985
525956
|
if (header.clientDefault != null) {
|
|
525986
525957
|
headerSchema["client-default"] = header.clientDefault;
|
|
525987
525958
|
}
|
|
525959
|
+
if (headerDefault != null) {
|
|
525960
|
+
headerSchema.default = headerDefault;
|
|
525961
|
+
}
|
|
525988
525962
|
return headerSchema;
|
|
525989
525963
|
}
|
|
525990
525964
|
|
|
@@ -526030,7 +526004,7 @@ function buildQueryParameter({ queryParameter, context: context3, fileContaining
|
|
|
526030
526004
|
return void 0;
|
|
526031
526005
|
}
|
|
526032
526006
|
let queryParameterType = getTypeFromTypeReference(typeReference2.value);
|
|
526033
|
-
const queryParameterDefault = getDefaultFromTypeReference(typeReference2.value);
|
|
526007
|
+
const queryParameterDefault = getDefaultFromOpenApiIrSchema(queryParameter.schema, context3, namespace) ?? getDefaultFromTypeReference(typeReference2.value);
|
|
526034
526008
|
if (queryParameterType === "unknown") {
|
|
526035
526009
|
queryParameterType = "string";
|
|
526036
526010
|
} else if (queryParameterType === "optional<unknown>") {
|
|
@@ -526466,6 +526440,21 @@ function getQueryParameterTypeReference({ schema: schema2, context: context3, fi
|
|
|
526466
526440
|
};
|
|
526467
526441
|
}
|
|
526468
526442
|
}
|
|
526443
|
+
function getDefaultFromOpenApiIrSchema(schema2, context3, namespace) {
|
|
526444
|
+
if (schema2.type === "array") {
|
|
526445
|
+
return schema2.default ?? void 0;
|
|
526446
|
+
}
|
|
526447
|
+
if (schema2.type === "optional" || schema2.type === "nullable") {
|
|
526448
|
+
return getDefaultFromOpenApiIrSchema(schema2.value, context3, namespace);
|
|
526449
|
+
}
|
|
526450
|
+
if (schema2.type === "reference") {
|
|
526451
|
+
const resolved = context3.getSchema(schema2.schema, namespace);
|
|
526452
|
+
if (resolved != null) {
|
|
526453
|
+
return getDefaultFromOpenApiIrSchema(resolved, context3, namespace);
|
|
526454
|
+
}
|
|
526455
|
+
}
|
|
526456
|
+
return void 0;
|
|
526457
|
+
}
|
|
526469
526458
|
function hasSamePrimitiveValueType({ array: array3, primitive }) {
|
|
526470
526459
|
return array3?.type === "array" && array3.value.type === "primitive" && primitive?.type === "primitive" && array3.value.schema.type === primitive.schema.type;
|
|
526471
526460
|
}
|
|
@@ -531280,7 +531269,8 @@ function getSchemaFromFernType({ fernType, nameOverride, generatedName, title: t
|
|
|
531280
531269
|
example: void 0,
|
|
531281
531270
|
inline: void 0,
|
|
531282
531271
|
minItems: void 0,
|
|
531283
|
-
maxItems: void 0
|
|
531272
|
+
maxItems: void 0,
|
|
531273
|
+
default: void 0
|
|
531284
531274
|
}) : void 0,
|
|
531285
531275
|
optional: (itemType) => itemType != null ? SchemaWithExample.optional({
|
|
531286
531276
|
nameOverride,
|
|
@@ -531316,7 +531306,8 @@ function getSchemaFromFernType({ fernType, nameOverride, generatedName, title: t
|
|
|
531316
531306
|
example: void 0,
|
|
531317
531307
|
inline: void 0,
|
|
531318
531308
|
minItems: void 0,
|
|
531319
|
-
maxItems: void 0
|
|
531309
|
+
maxItems: void 0,
|
|
531310
|
+
default: void 0
|
|
531320
531311
|
}) : void 0,
|
|
531321
531312
|
literal: (literal3) => SchemaWithExample.literal({
|
|
531322
531313
|
nameOverride,
|
|
@@ -531593,7 +531584,7 @@ function getAdditionalPropertiesAnyMetadata(additionalProperties7) {
|
|
|
531593
531584
|
}
|
|
531594
531585
|
|
|
531595
531586
|
// ../api-importers/openapi/openapi-ir-parser/lib/schema/convertArray.js
|
|
531596
|
-
function convertArray({ nameOverride, generatedName, title: title2, breadcrumbs, item, description, availability, wrapAsOptional, wrapAsNullable, context: context3, namespace, groupName, example, source: source2, minItems, maxItems }) {
|
|
531587
|
+
function convertArray({ nameOverride, generatedName, title: title2, breadcrumbs, item, description, availability, wrapAsOptional, wrapAsNullable, context: context3, namespace, groupName, example, source: source2, minItems, maxItems, default: defaultValue }) {
|
|
531597
531588
|
const itemSchema = item == null ? SchemaWithExample.unknown({
|
|
531598
531589
|
nameOverride,
|
|
531599
531590
|
generatedName,
|
|
@@ -531617,10 +531608,11 @@ function convertArray({ nameOverride, generatedName, title: title2, breadcrumbs,
|
|
|
531617
531608
|
availability,
|
|
531618
531609
|
example,
|
|
531619
531610
|
minItems,
|
|
531620
|
-
maxItems
|
|
531611
|
+
maxItems,
|
|
531612
|
+
default: defaultValue
|
|
531621
531613
|
});
|
|
531622
531614
|
}
|
|
531623
|
-
function wrapArray({ nameOverride, generatedName, title: title2, itemSchema, wrapAsOptional, wrapAsNullable, description, availability, namespace, groupName, example, minItems, maxItems }) {
|
|
531615
|
+
function wrapArray({ nameOverride, generatedName, title: title2, itemSchema, wrapAsOptional, wrapAsNullable, description, availability, namespace, groupName, example, minItems, maxItems, default: defaultValue }) {
|
|
531624
531616
|
let result = SchemaWithExample.array({
|
|
531625
531617
|
nameOverride,
|
|
531626
531618
|
generatedName,
|
|
@@ -531633,7 +531625,8 @@ function wrapArray({ nameOverride, generatedName, title: title2, itemSchema, wra
|
|
|
531633
531625
|
example,
|
|
531634
531626
|
inline: void 0,
|
|
531635
531627
|
minItems,
|
|
531636
|
-
maxItems
|
|
531628
|
+
maxItems,
|
|
531629
|
+
default: defaultValue
|
|
531637
531630
|
});
|
|
531638
531631
|
if (wrapAsNullable) {
|
|
531639
531632
|
result = SchemaWithExample.nullable({
|
|
@@ -531871,7 +531864,8 @@ function convertSchemaWithExampleToSchema(schema2) {
|
|
|
531871
531864
|
groupName: schema2.groupName,
|
|
531872
531865
|
inline: schema2.inline,
|
|
531873
531866
|
minItems: schema2.minItems,
|
|
531874
|
-
maxItems: schema2.maxItems
|
|
531867
|
+
maxItems: schema2.maxItems,
|
|
531868
|
+
default: schema2.default
|
|
531875
531869
|
});
|
|
531876
531870
|
case "enum":
|
|
531877
531871
|
return Schema.enum({
|
|
@@ -534028,7 +534022,8 @@ function convertSchemaObject(schema2, wrapAsOptional, wrapAsNullable, context3,
|
|
|
534028
534022
|
example: getExampleAsArray({ schema: schema2, logger: context3.logger, fallback: fallback2 }),
|
|
534029
534023
|
source: source2,
|
|
534030
534024
|
minItems: schema2.minItems,
|
|
534031
|
-
maxItems: schema2.maxItems
|
|
534025
|
+
maxItems: schema2.maxItems,
|
|
534026
|
+
default: schema2.default
|
|
534032
534027
|
});
|
|
534033
534028
|
}
|
|
534034
534029
|
if (schema2.additionalProperties != null && schema2.additionalProperties !== false && hasNoProperties(schema2) && hasNoAllOf(schema2)) {
|
|
@@ -536028,7 +536023,8 @@ function convertSchemaToSchemaWithExample(schema2) {
|
|
|
536028
536023
|
example: void 0,
|
|
536029
536024
|
inline: void 0,
|
|
536030
536025
|
minItems: schema2.minItems,
|
|
536031
|
-
maxItems: schema2.maxItems
|
|
536026
|
+
maxItems: schema2.maxItems,
|
|
536027
|
+
default: schema2.default
|
|
536032
536028
|
});
|
|
536033
536029
|
case "enum":
|
|
536034
536030
|
return SchemaWithExample.enum({
|
|
@@ -559129,6 +559125,7 @@ function getObjectPropertiesFromRawObjectSchema(object23, file4) {
|
|
|
559129
559125
|
}),
|
|
559130
559126
|
valueType: file4.parseTypeReference(propertyDefinition),
|
|
559131
559127
|
propertyAccess: getPropertyAccess2({ property: propertyDefinition }),
|
|
559128
|
+
defaultValue: typeof propertyDefinition !== "string" ? propertyDefinition.default : void 0,
|
|
559132
559129
|
v2Examples: {
|
|
559133
559130
|
userSpecifiedExamples: {},
|
|
559134
559131
|
autogeneratedExamples: {}
|
|
@@ -559294,6 +559291,7 @@ function convertInlinedRequestProperty({ propertyKey, propertyDefinition, docs:
|
|
|
559294
559291
|
name: getPropertyName({ propertyKey, property: propertyDefinition }).name
|
|
559295
559292
|
}),
|
|
559296
559293
|
valueType: file4.parseTypeReference(propertyDefinition),
|
|
559294
|
+
defaultValue: typeof propertyDefinition !== "string" ? propertyDefinition.default : void 0,
|
|
559297
559295
|
v2Examples: {
|
|
559298
559296
|
userSpecifiedExamples: {},
|
|
559299
559297
|
autogeneratedExamples: {}
|
|
@@ -559821,6 +559819,7 @@ function convertDiscriminatedUnionTypeDeclaration({ union: union23, file: file4,
|
|
|
559821
559819
|
}),
|
|
559822
559820
|
valueType: file4.parseTypeReference(propertyDefinition),
|
|
559823
559821
|
propertyAccess: getPropertyAccess2({ property: propertyDefinition }),
|
|
559822
|
+
defaultValue: typeof propertyDefinition !== "string" ? propertyDefinition.default : void 0,
|
|
559824
559823
|
v2Examples: {
|
|
559825
559824
|
userSpecifiedExamples: {},
|
|
559826
559825
|
autogeneratedExamples: {}
|
|
@@ -561654,8 +561653,10 @@ function convertSingleUnionType({ rawValueType, rawSingleUnionType, fileContaini
|
|
|
561654
561653
|
// ../generation/ir-generator/lib/converters/services/convertQueryParameter.js
|
|
561655
561654
|
function convertQueryParameter({ file: file4, queryParameterKey, queryParameter }) {
|
|
561656
561655
|
const { name: name2 } = getQueryParameterName({ queryParameterKey, queryParameter });
|
|
561657
|
-
const valueType = file4.parseTypeReference(queryParameter);
|
|
561658
561656
|
const clientDefaultValue = typeof queryParameter !== "string" ? queryParameter["client-default"] : void 0;
|
|
561657
|
+
const defaultValue = typeof queryParameter !== "string" ? queryParameter.default : void 0;
|
|
561658
|
+
const queryParameterForType = typeof queryParameter !== "string" && queryParameter["allow-multiple"] === true && Array.isArray(queryParameter.default) ? { ...queryParameter, default: void 0 } : queryParameter;
|
|
561659
|
+
const valueType = file4.parseTypeReference(queryParameterForType);
|
|
561659
561660
|
return {
|
|
561660
561661
|
...convertDeclaration(queryParameter),
|
|
561661
561662
|
name: file4.casingsGenerator.generateNameAndWireValue({
|
|
@@ -561665,6 +561666,7 @@ function convertQueryParameter({ file: file4, queryParameterKey, queryParameter
|
|
|
561665
561666
|
valueType,
|
|
561666
561667
|
allowMultiple: typeof queryParameter !== "string" && queryParameter["allow-multiple"] != null ? queryParameter["allow-multiple"] : false,
|
|
561667
561668
|
clientDefault: convertDefaultToLiteral(clientDefaultValue),
|
|
561669
|
+
defaultValue,
|
|
561668
561670
|
v2Examples: {
|
|
561669
561671
|
userSpecifiedExamples: {},
|
|
561670
561672
|
autogeneratedExamples: {}
|
|
@@ -562808,6 +562810,7 @@ function convertHttpMethod(method8) {
|
|
|
562808
562810
|
function convertHttpHeader({ headerKey, header, file: file4 }) {
|
|
562809
562811
|
const { name: name2 } = getHeaderName3({ headerKey, header });
|
|
562810
562812
|
const clientDefaultValue = typeof header !== "string" ? header["client-default"] : void 0;
|
|
562813
|
+
const defaultValue = typeof header !== "string" ? header.default : void 0;
|
|
562811
562814
|
return {
|
|
562812
562815
|
...convertDeclaration(header),
|
|
562813
562816
|
name: file4.casingsGenerator.generateNameAndWireValue({
|
|
@@ -562817,6 +562820,7 @@ function convertHttpHeader({ headerKey, header, file: file4 }) {
|
|
|
562817
562820
|
valueType: file4.parseTypeReference(header),
|
|
562818
562821
|
env: typeof header === "string" ? void 0 : header.env,
|
|
562819
562822
|
clientDefault: convertDefaultToLiteral(clientDefaultValue),
|
|
562823
|
+
defaultValue,
|
|
562820
562824
|
v2Examples: {
|
|
562821
562825
|
userSpecifiedExamples: {},
|
|
562822
562826
|
autogeneratedExamples: {}
|
|
@@ -564401,6 +564405,7 @@ function convertChannel({ channel: channel3, typeResolver, exampleResolver, vari
|
|
|
564401
564405
|
valueType,
|
|
564402
564406
|
allowMultiple: typeof queryParameter !== "string" && queryParameter["allow-multiple"] != null ? queryParameter["allow-multiple"] : false,
|
|
564403
564407
|
clientDefault: void 0,
|
|
564408
|
+
defaultValue: typeof queryParameter !== "string" ? queryParameter.default : void 0,
|
|
564404
564409
|
v2Examples: {
|
|
564405
564410
|
userSpecifiedExamples: {},
|
|
564406
564411
|
autogeneratedExamples: {}
|
|
@@ -565401,6 +565406,7 @@ function convertUndiscriminatedUnionTypeDeclaration({ union: union23, file: file
|
|
|
565401
565406
|
}),
|
|
565402
565407
|
valueType: file4.parseTypeReference(propertyDefinition),
|
|
565403
565408
|
propertyAccess: getPropertyAccess2({ property: propertyDefinition }),
|
|
565409
|
+
defaultValue: typeof propertyDefinition !== "string" ? propertyDefinition.default : void 0,
|
|
565404
565410
|
v2Examples: {
|
|
565405
565411
|
userSpecifiedExamples: {},
|
|
565406
565412
|
autogeneratedExamples: {}
|
|
@@ -571595,6 +571601,21 @@ function validateResolvedType({ resolvedType, _default: _default4, validation: v
|
|
|
571595
571601
|
validation: validation2
|
|
571596
571602
|
});
|
|
571597
571603
|
}
|
|
571604
|
+
if (resolvedType._type === "container" && (resolvedType.container._type === "list" || resolvedType.container._type === "set")) {
|
|
571605
|
+
if (_default4 != null && !Array.isArray(_default4)) {
|
|
571606
|
+
violations.push({
|
|
571607
|
+
message: `Default value for ${resolvedType.container._type} type must be an array`,
|
|
571608
|
+
severity: "fatal"
|
|
571609
|
+
});
|
|
571610
|
+
}
|
|
571611
|
+
if (validation2 != null) {
|
|
571612
|
+
violations.push({
|
|
571613
|
+
message: `Validation rules are not supported for the ${resolvedType.container._type} type`,
|
|
571614
|
+
severity: "fatal"
|
|
571615
|
+
});
|
|
571616
|
+
}
|
|
571617
|
+
return violations;
|
|
571618
|
+
}
|
|
571598
571619
|
let typeName = resolvedType._type;
|
|
571599
571620
|
if (resolvedType._type === "primitive") {
|
|
571600
571621
|
switch (resolvedType.primitive.v1) {
|
|
@@ -604313,6 +604334,11 @@ function convertProperties({ properties: properties7, required: required6, bread
|
|
|
604313
604334
|
});
|
|
604314
604335
|
const convertedProperty = propertySchemaConverter.convert();
|
|
604315
604336
|
if (convertedProperty != null) {
|
|
604337
|
+
const resolvedPropertySchema = context3.resolveMaybeReference({
|
|
604338
|
+
schemaOrReference: propertySchema,
|
|
604339
|
+
breadcrumbs: propertyBreadcrumbs,
|
|
604340
|
+
skipErrorCollector: true
|
|
604341
|
+
});
|
|
604316
604342
|
convertedProperties.push({
|
|
604317
604343
|
name: context3.casingsGenerator.generateNameAndWireValue({
|
|
604318
604344
|
name: propertyName,
|
|
@@ -604322,6 +604348,7 @@ function convertProperties({ properties: properties7, required: required6, bread
|
|
|
604322
604348
|
docs: propertySchema.description,
|
|
604323
604349
|
availability: convertedProperty.availability,
|
|
604324
604350
|
propertyAccess: context3.getPropertyAccess(propertySchema),
|
|
604351
|
+
defaultValue: resolvedPropertySchema?.default,
|
|
604325
604352
|
v2Examples: convertedProperty.schema?.typeDeclaration?.v2Examples ?? generatePropertyV2Examples({
|
|
604326
604353
|
propertySchema,
|
|
604327
604354
|
breadcrumbs: propertyBreadcrumbs,
|
|
@@ -606201,6 +606228,7 @@ var AbstractParameterConverter = class extends AbstractConverter {
|
|
|
606201
606228
|
const parameterSchemaWithExampleOverride = this.getParameterSchemaWithExampleOverride({
|
|
606202
606229
|
schema: resolvedParameterSchema
|
|
606203
606230
|
});
|
|
606231
|
+
const parameterDefaultValue = resolvedParameterSchema?.default;
|
|
606204
606232
|
switch (this.parameter.in) {
|
|
606205
606233
|
case "query":
|
|
606206
606234
|
return {
|
|
@@ -606214,6 +606242,7 @@ var AbstractParameterConverter = class extends AbstractConverter {
|
|
|
606214
606242
|
valueType: typeReference2 ?? AbstractConverter.OPTIONAL_STRING,
|
|
606215
606243
|
allowMultiple: this.parameter.explode ?? false,
|
|
606216
606244
|
clientDefault: void 0,
|
|
606245
|
+
defaultValue: parameterDefaultValue,
|
|
606217
606246
|
v2Examples: this.convertParameterExamples({
|
|
606218
606247
|
schema: parameterSchemaWithExampleOverride ?? schema2
|
|
606219
606248
|
}),
|
|
@@ -606234,6 +606263,7 @@ var AbstractParameterConverter = class extends AbstractConverter {
|
|
|
606234
606263
|
valueType: typeReference2 ?? AbstractConverter.OPTIONAL_STRING,
|
|
606235
606264
|
env: void 0,
|
|
606236
606265
|
clientDefault: void 0,
|
|
606266
|
+
defaultValue: parameterDefaultValue,
|
|
606237
606267
|
v2Examples: this.convertParameterExamples({
|
|
606238
606268
|
schema: parameterSchemaWithExampleOverride ?? schema2
|
|
606239
606269
|
}),
|
|
@@ -608573,7 +608603,8 @@ function convertGlobalHeaderOverrides({ globalHeaderOverrides, context: context3
|
|
|
608573
608603
|
},
|
|
608574
608604
|
availability: void 0,
|
|
608575
608605
|
docs: void 0,
|
|
608576
|
-
clientDefault: void 0
|
|
608606
|
+
clientDefault: void 0,
|
|
608607
|
+
defaultValue: void 0
|
|
608577
608608
|
});
|
|
608578
608609
|
} else {
|
|
608579
608610
|
const name2 = headerSchema.name ?? headerKey;
|
|
@@ -608590,7 +608621,8 @@ function convertGlobalHeaderOverrides({ globalHeaderOverrides, context: context3
|
|
|
608590
608621
|
},
|
|
608591
608622
|
availability: void 0,
|
|
608592
608623
|
docs: headerSchema.docs,
|
|
608593
|
-
clientDefault: convertDefaultToLiteral2(headerSchema.default)
|
|
608624
|
+
clientDefault: convertDefaultToLiteral2(headerSchema.default),
|
|
608625
|
+
defaultValue: headerSchema.default
|
|
608594
608626
|
});
|
|
608595
608627
|
}
|
|
608596
608628
|
}
|
|
@@ -608621,7 +608653,8 @@ function convertGlobalHeadersExtension({ globalHeaders, context: context3 }) {
|
|
|
608621
608653
|
v2Examples: header.optional ? void 0 : constructGlobalHeaderExample({ header, context: context3 }),
|
|
608622
608654
|
availability: void 0,
|
|
608623
608655
|
docs: void 0,
|
|
608624
|
-
clientDefault: convertDefaultToLiteral3(header["x-fern-default"])
|
|
608656
|
+
clientDefault: convertDefaultToLiteral3(header["x-fern-default"]),
|
|
608657
|
+
defaultValue: void 0
|
|
608625
608658
|
}));
|
|
608626
608659
|
}
|
|
608627
608660
|
function constructGlobalHeaderExample({ header, context: context3 }) {
|
|
@@ -610267,8 +610300,9 @@ var ResponseBodyConverter = class extends converters_exports.AbstractConverters.
|
|
|
610267
610300
|
}
|
|
610268
610301
|
const headerSchema = resolvedHeader.schema;
|
|
610269
610302
|
let valueType = AbstractConverter.OPTIONAL_STRING;
|
|
610303
|
+
let resolvedSchema;
|
|
610270
610304
|
if (headerSchema != null) {
|
|
610271
|
-
|
|
610305
|
+
resolvedSchema = this.context.resolveMaybeReference({
|
|
610272
610306
|
schemaOrReference: headerSchema,
|
|
610273
610307
|
breadcrumbs: [...this.breadcrumbs, "headers", headerName, "schema"]
|
|
610274
610308
|
});
|
|
@@ -610301,7 +610335,8 @@ var ResponseBodyConverter = class extends converters_exports.AbstractConverters.
|
|
|
610301
610335
|
env: void 0,
|
|
610302
610336
|
v2Examples,
|
|
610303
610337
|
availability: void 0,
|
|
610304
|
-
clientDefault: void 0
|
|
610338
|
+
clientDefault: void 0,
|
|
610339
|
+
defaultValue: resolvedSchema?.default
|
|
610305
610340
|
});
|
|
610306
610341
|
}
|
|
610307
610342
|
return headers2;
|
|
@@ -610542,8 +610577,9 @@ var ResponseErrorConverter = class extends converters_exports.AbstractConverters
|
|
|
610542
610577
|
}
|
|
610543
610578
|
const headerSchema = resolvedHeader.schema;
|
|
610544
610579
|
let valueType = AbstractConverter.OPTIONAL_STRING;
|
|
610580
|
+
let resolvedSchema;
|
|
610545
610581
|
if (headerSchema != null) {
|
|
610546
|
-
|
|
610582
|
+
resolvedSchema = this.context.resolveMaybeReference({
|
|
610547
610583
|
schemaOrReference: headerSchema,
|
|
610548
610584
|
breadcrumbs: [...this.breadcrumbs, "headers", headerName, "schema"]
|
|
610549
610585
|
});
|
|
@@ -610576,7 +610612,8 @@ var ResponseErrorConverter = class extends converters_exports.AbstractConverters
|
|
|
610576
610612
|
env: void 0,
|
|
610577
610613
|
v2Examples,
|
|
610578
610614
|
availability: void 0,
|
|
610579
|
-
clientDefault: void 0
|
|
610615
|
+
clientDefault: void 0,
|
|
610616
|
+
defaultValue: resolvedSchema?.default
|
|
610580
610617
|
});
|
|
610581
610618
|
}
|
|
610582
610619
|
return headers2;
|
|
@@ -611100,7 +611137,8 @@ var OperationConverter = class _OperationConverter extends AbstractOperationConv
|
|
|
611100
611137
|
docs: void 0,
|
|
611101
611138
|
env: void 0,
|
|
611102
611139
|
v2Examples: void 0,
|
|
611103
|
-
clientDefault: void 0
|
|
611140
|
+
clientDefault: void 0,
|
|
611141
|
+
defaultValue: void 0
|
|
611104
611142
|
};
|
|
611105
611143
|
switch (authScheme.type) {
|
|
611106
611144
|
case "bearer":
|
|
@@ -612388,6 +612426,7 @@ var MethodConverter = class extends AbstractConverter {
|
|
|
612388
612426
|
wireValue: resolvedParam.name
|
|
612389
612427
|
}),
|
|
612390
612428
|
valueType: schema2.type,
|
|
612429
|
+
defaultValue: resolvedParam.schema != null && typeof resolvedParam.schema === "object" ? resolvedParam.schema.default : void 0,
|
|
612391
612430
|
v2Examples: schema2.schema?.typeDeclaration.v2Examples,
|
|
612392
612431
|
propertyAccess: void 0
|
|
612393
612432
|
});
|
|
@@ -622565,7 +622604,7 @@ var AccessTokenPosthogManager = class {
|
|
|
622565
622604
|
properties: {
|
|
622566
622605
|
...event,
|
|
622567
622606
|
...event.properties,
|
|
622568
|
-
version: "5.7.
|
|
622607
|
+
version: "5.7.1-10-g7c1556603e5",
|
|
622569
622608
|
usingAccessToken: true
|
|
622570
622609
|
}
|
|
622571
622610
|
});
|
|
@@ -622619,7 +622658,7 @@ var UserPosthogManager = class {
|
|
|
622619
622658
|
distinctId: this.userId ?? await this.getPersistedDistinctId(),
|
|
622620
622659
|
event: "CLI",
|
|
622621
622660
|
properties: {
|
|
622622
|
-
version: "5.7.
|
|
622661
|
+
version: "5.7.1-10-g7c1556603e5",
|
|
622623
622662
|
...event,
|
|
622624
622663
|
...event.properties,
|
|
622625
622664
|
usingAccessToken: false,
|
|
@@ -810342,7 +810381,7 @@ function convertTypeShape(irType) {
|
|
|
810342
810381
|
properties: object23.properties.map((property24) => ({
|
|
810343
810382
|
description: property24.docs ?? void 0,
|
|
810344
810383
|
key: FdrAPI_exports.PropertyKey(getWireValue(property24.name)),
|
|
810345
|
-
valueType: convertTypeReference3(property24.valueType),
|
|
810384
|
+
valueType: convertTypeReference3(property24.valueType, property24.defaultValue),
|
|
810346
810385
|
availability: convertIrAvailability(property24.availability),
|
|
810347
810386
|
propertyAccess: property24.propertyAccess
|
|
810348
810387
|
})),
|
|
@@ -810353,7 +810392,7 @@ function convertTypeShape(irType) {
|
|
|
810353
810392
|
const baseProperties = union23.baseProperties.map((baseProperty2) => {
|
|
810354
810393
|
return {
|
|
810355
810394
|
key: FdrAPI_exports.PropertyKey(getWireValue(baseProperty2.name)),
|
|
810356
|
-
valueType: convertTypeReference3(baseProperty2.valueType),
|
|
810395
|
+
valueType: convertTypeReference3(baseProperty2.valueType, baseProperty2.defaultValue),
|
|
810357
810396
|
availability: convertIrAvailability(baseProperty2.availability),
|
|
810358
810397
|
description: baseProperty2.docs,
|
|
810359
810398
|
propertyAccess: baseProperty2.propertyAccess
|
|
@@ -810429,7 +810468,7 @@ function convertTypeShape(irType) {
|
|
|
810429
810468
|
}
|
|
810430
810469
|
});
|
|
810431
810470
|
}
|
|
810432
|
-
function convertTypeReference3(irTypeReference) {
|
|
810471
|
+
function convertTypeReference3(irTypeReference, documentationDefault) {
|
|
810433
810472
|
return irTypeReference._visit({
|
|
810434
810473
|
container: (container) => {
|
|
810435
810474
|
return api_exports.types.ContainerType._visit(container, {
|
|
@@ -810454,7 +810493,7 @@ function convertTypeReference3(irTypeReference) {
|
|
|
810454
810493
|
return {
|
|
810455
810494
|
type: "optional",
|
|
810456
810495
|
itemType: convertTypeReference3(itemType),
|
|
810457
|
-
defaultValue:
|
|
810496
|
+
defaultValue: documentationDefault
|
|
810458
810497
|
};
|
|
810459
810498
|
},
|
|
810460
810499
|
nullable: (itemType) => {
|
|
@@ -810739,7 +810778,7 @@ function convertWebhookGroup4(webhookGroup) {
|
|
|
810739
810778
|
headers: webhook.headers.map((header) => ({
|
|
810740
810779
|
description: header.docs ?? void 0,
|
|
810741
810780
|
key: getWireValue(header.name),
|
|
810742
|
-
type: convertTypeReference3(header.valueType),
|
|
810781
|
+
type: convertTypeReference3(header.valueType, header.defaultValue),
|
|
810743
810782
|
availability: convertIrAvailability(header.availability)
|
|
810744
810783
|
})),
|
|
810745
810784
|
payload: convertWebhookPayloadWithFileUpload(webhook.payload, webhook.fileUploadPayload),
|
|
@@ -810871,20 +810910,20 @@ function convertService(irService, ir11) {
|
|
|
810871
810910
|
queryParameters: irEndpoint.queryParameters.map((queryParameter) => ({
|
|
810872
810911
|
description: queryParameter.docs ?? void 0,
|
|
810873
810912
|
key: getWireValue(queryParameter.name),
|
|
810874
|
-
type: convertTypeReference3(queryParameter.valueType),
|
|
810913
|
+
type: convertTypeReference3(queryParameter.valueType, queryParameter.defaultValue),
|
|
810875
810914
|
availability: convertIrAvailability(queryParameter.availability),
|
|
810876
810915
|
explode: queryParameter.explode
|
|
810877
810916
|
})),
|
|
810878
810917
|
headers: [...irService.headers, ...irEndpoint.headers].map((header) => ({
|
|
810879
810918
|
description: header.docs ?? void 0,
|
|
810880
810919
|
key: getWireValue(header.name),
|
|
810881
|
-
type: convertTypeReference3(header.valueType),
|
|
810920
|
+
type: convertTypeReference3(header.valueType, header.defaultValue),
|
|
810882
810921
|
availability: convertIrAvailability(header.availability)
|
|
810883
810922
|
})),
|
|
810884
810923
|
responseHeaders: irEndpoint.responseHeaders?.map((header) => ({
|
|
810885
810924
|
description: header.docs ?? void 0,
|
|
810886
810925
|
key: getWireValue(header.name),
|
|
810887
|
-
type: convertTypeReference3(header.valueType),
|
|
810926
|
+
type: convertTypeReference3(header.valueType, header.defaultValue),
|
|
810888
810927
|
availability: convertIrAvailability(header.availability)
|
|
810889
810928
|
})),
|
|
810890
810929
|
request: irEndpoint.requestBody != null ? convertRequestBody3(irEndpoint.requestBody) : void 0,
|
|
@@ -810980,14 +811019,14 @@ function convertWebSocketChannel(channel3, ir11) {
|
|
|
810980
811019
|
},
|
|
810981
811020
|
headers: channel3.headers.map((header) => ({
|
|
810982
811021
|
key: getWireValue(header.name),
|
|
810983
|
-
type: convertTypeReference3(header.valueType),
|
|
811022
|
+
type: convertTypeReference3(header.valueType, header.defaultValue),
|
|
810984
811023
|
description: header.docs,
|
|
810985
811024
|
availability: convertIrAvailability(header.availability)
|
|
810986
811025
|
})),
|
|
810987
811026
|
queryParameters: channel3.queryParameters.map((queryParameter) => ({
|
|
810988
811027
|
description: queryParameter.docs ?? void 0,
|
|
810989
811028
|
key: getWireValue(queryParameter.name),
|
|
810990
|
-
type: convertTypeReference3(queryParameter.valueType),
|
|
811029
|
+
type: convertTypeReference3(queryParameter.valueType, queryParameter.defaultValue),
|
|
810991
811030
|
availability: convertIrAvailability(queryParameter.availability),
|
|
810992
811031
|
explode: queryParameter.explode
|
|
810993
811032
|
})),
|
|
@@ -811193,7 +811232,7 @@ function convertRequestBody3(irRequest) {
|
|
|
811193
811232
|
properties: inlinedRequestBody.properties.map((property24) => ({
|
|
811194
811233
|
description: property24.docs ?? void 0,
|
|
811195
811234
|
key: FdrAPI_exports.PropertyKey(getWireValue(property24.name)),
|
|
811196
|
-
valueType: convertTypeReference3(property24.valueType),
|
|
811235
|
+
valueType: convertTypeReference3(property24.valueType, property24.defaultValue),
|
|
811197
811236
|
availability: convertIrAvailability(property24.availability),
|
|
811198
811237
|
propertyAccess: property24.propertyAccess
|
|
811199
811238
|
})),
|
|
@@ -811251,7 +811290,7 @@ function convertRequestBody3(irRequest) {
|
|
|
811251
811290
|
bodyProperty: (bodyProperty) => ({
|
|
811252
811291
|
type: "bodyProperty",
|
|
811253
811292
|
key: FdrAPI_exports.PropertyKey(getWireValue(bodyProperty.name)),
|
|
811254
|
-
valueType: convertTypeReference3(bodyProperty.valueType),
|
|
811293
|
+
valueType: convertTypeReference3(bodyProperty.valueType, bodyProperty.defaultValue),
|
|
811255
811294
|
contentType: bodyProperty.contentType,
|
|
811256
811295
|
description: bodyProperty.docs ?? void 0,
|
|
811257
811296
|
availability: convertIrAvailability(bodyProperty.availability),
|
|
@@ -811376,7 +811415,7 @@ function convertResponseErrorsV2(irResponseErrors, ir11) {
|
|
|
811376
811415
|
headers: errorDeclaration.headers != null && errorDeclaration.headers.length > 0 ? errorDeclaration.headers.map((header) => ({
|
|
811377
811416
|
description: header.docs ?? void 0,
|
|
811378
811417
|
key: getWireValue(header.name),
|
|
811379
|
-
type: convertTypeReference3(header.valueType),
|
|
811418
|
+
type: convertTypeReference3(header.valueType, header.defaultValue),
|
|
811380
811419
|
availability: convertIrAvailability(header.availability)
|
|
811381
811420
|
})) : void 0
|
|
811382
811421
|
});
|
|
@@ -811432,7 +811471,7 @@ function convertResponseErrorsV2(irResponseErrors, ir11) {
|
|
|
811432
811471
|
headers: errorDeclaration.headers != null && errorDeclaration.headers.length > 0 ? errorDeclaration.headers.map((header) => ({
|
|
811433
811472
|
description: header.docs ?? void 0,
|
|
811434
811473
|
key: getWireValue(header.name),
|
|
811435
|
-
type: convertTypeReference3(header.valueType),
|
|
811474
|
+
type: convertTypeReference3(header.valueType, header.defaultValue),
|
|
811436
811475
|
availability: convertIrAvailability(header.availability)
|
|
811437
811476
|
})) : void 0
|
|
811438
811477
|
});
|
|
@@ -811818,7 +811857,7 @@ function convertWebhookPayloadWithFileUpload(irWebhookPayload, fileUploadPayload
|
|
|
811818
811857
|
bodyProperty: (bodyProperty) => ({
|
|
811819
811858
|
type: "bodyProperty",
|
|
811820
811859
|
key: FdrAPI_exports.PropertyKey(getWireValue(bodyProperty.name)),
|
|
811821
|
-
valueType: convertTypeReference3(bodyProperty.valueType),
|
|
811860
|
+
valueType: convertTypeReference3(bodyProperty.valueType, bodyProperty.defaultValue),
|
|
811822
811861
|
contentType: bodyProperty.contentType,
|
|
811823
811862
|
description: bodyProperty.docs ?? void 0,
|
|
811824
811863
|
availability: convertIrAvailability(bodyProperty.availability),
|
|
@@ -811976,7 +812015,7 @@ function convertIrToFdrApi({ ir: ir11, snippetsConfig, playgroundConfig, graphql
|
|
|
811976
812015
|
availability: convertIrAvailability(header.availability),
|
|
811977
812016
|
description: header.docs ?? void 0,
|
|
811978
812017
|
key: getWireValue(header.name),
|
|
811979
|
-
type: convertTypeReference3(header.valueType)
|
|
812018
|
+
type: convertTypeReference3(header.valueType, header.defaultValue)
|
|
811980
812019
|
})),
|
|
811981
812020
|
navigation: void 0
|
|
811982
812021
|
};
|
|
@@ -846979,7 +847018,7 @@ var LOCAL_STORAGE_FOLDER4 = ".fern-dev";
|
|
|
846979
847018
|
var LOGS_FOLDER_NAME = "logs";
|
|
846980
847019
|
var MAX_LOGS_DIR_SIZE_BYTES = 100 * 1024 * 1024;
|
|
846981
847020
|
function getCliSource() {
|
|
846982
|
-
const version7 = "5.7.
|
|
847021
|
+
const version7 = "5.7.1-10-g7c1556603e5";
|
|
846983
847022
|
return `cli@${version7}`;
|
|
846984
847023
|
}
|
|
846985
847024
|
var DebugLogger = class {
|
|
@@ -855093,24 +855132,7 @@ var definitions6 = {
|
|
|
855093
855132
|
]
|
|
855094
855133
|
},
|
|
855095
855134
|
"docs.Language": {
|
|
855096
|
-
type: "string"
|
|
855097
|
-
enum: [
|
|
855098
|
-
"en",
|
|
855099
|
-
"es",
|
|
855100
|
-
"fr",
|
|
855101
|
-
"de",
|
|
855102
|
-
"it",
|
|
855103
|
-
"pt",
|
|
855104
|
-
"ja",
|
|
855105
|
-
"zh",
|
|
855106
|
-
"ko",
|
|
855107
|
-
"el",
|
|
855108
|
-
"no",
|
|
855109
|
-
"pl",
|
|
855110
|
-
"ru",
|
|
855111
|
-
"sv",
|
|
855112
|
-
"tr"
|
|
855113
|
-
]
|
|
855135
|
+
type: "string"
|
|
855114
855136
|
},
|
|
855115
855137
|
"docs.TranslationConfigObject": {
|
|
855116
855138
|
type: "object",
|
|
@@ -859551,7 +859573,7 @@ var LegacyDocsPublisher = class {
|
|
|
859551
859573
|
previewId,
|
|
859552
859574
|
disableTemplates: void 0,
|
|
859553
859575
|
skipUpload,
|
|
859554
|
-
cliVersion: "5.7.
|
|
859576
|
+
cliVersion: "5.7.1-10-g7c1556603e5",
|
|
859555
859577
|
loginCommand: "fern auth login"
|
|
859556
859578
|
});
|
|
859557
859579
|
if (taskContext.getResult() === TaskResult.Failure) {
|
|
@@ -930075,6 +930097,7 @@ function convertFields({ fields, breadcrumbs, context: context3, sourceCodeInfoP
|
|
|
930075
930097
|
docs: context3.getCommentForPath([...sourceCodeInfoPath, PATH_FIELD_NUMBERS.MESSAGE.FIELD, index3]),
|
|
930076
930098
|
availability: convertedField.availability,
|
|
930077
930099
|
propertyAccess: void 0,
|
|
930100
|
+
defaultValue: void 0,
|
|
930078
930101
|
v2Examples: void 0
|
|
930079
930102
|
};
|
|
930080
930103
|
const hasOneofIndex = Object.hasOwn(field5, "oneofIndex");
|
|
@@ -930245,6 +930268,7 @@ var MessageConverter = class extends AbstractConverter {
|
|
|
930245
930268
|
docs: void 0,
|
|
930246
930269
|
availability: convertedOneOfField.availability,
|
|
930247
930270
|
propertyAccess: void 0,
|
|
930271
|
+
defaultValue: void 0,
|
|
930248
930272
|
v2Examples: void 0
|
|
930249
930273
|
});
|
|
930250
930274
|
inlinedTypes = {
|
|
@@ -933974,7 +933998,7 @@ var CliContext = class _CliContext {
|
|
|
933974
933998
|
if (false) {
|
|
933975
933999
|
this.logger.error("CLI_VERSION is not defined");
|
|
933976
934000
|
}
|
|
933977
|
-
return "5.7.
|
|
934001
|
+
return "5.7.1-10-g7c1556603e5";
|
|
933978
934002
|
}
|
|
933979
934003
|
getCliName() {
|
|
933980
934004
|
if (false) {
|
package/package.json
CHANGED