diff --git a/.eslintrc.js b/.eslintrc.js index 3aba8b6ca73..1b18e45c8d1 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -67,12 +67,7 @@ module.exports = { ignoreRestSiblings: true } ], - "@typescript-eslint/no-namespace": [ - "error", - { - allowDeclarations: true - } - ], + "@typescript-eslint/no-namespace": "off", "@typescript-eslint/explicit-module-boundary-types": [ "error", { @@ -129,7 +124,7 @@ module.exports = { { files: ['**/*.test.ts', '**/*.spec.ts'], rules: { - 'no-console': 'off' + 'no-console': 'off' } } ] diff --git a/fern/pages/changelogs/cli/2024-12-05.mdx b/fern/pages/changelogs/cli/2024-12-05.mdx index 8dbf596d6c6..4aa53ac1300 100644 --- a/fern/pages/changelogs/cli/2024-12-05.mdx +++ b/fern/pages/changelogs/cli/2024-12-05.mdx @@ -1,4 +1,4 @@ ## 0.45.3 -**`(fix):`** Unknown schemas are no longer incorrectly marked as `additionalProperties: true`. +**`(fix):`** Unknown schemas are no longer incorrectly marked as `additionalProperties: true`. diff --git a/fern/pages/changelogs/cli/2024-12-10.mdx b/fern/pages/changelogs/cli/2024-12-10.mdx index 0aeadc17414..dfceddb4453 100644 --- a/fern/pages/changelogs/cli/2024-12-10.mdx +++ b/fern/pages/changelogs/cli/2024-12-10.mdx @@ -1,4 +1,4 @@ ## 0.45.4-rc1 -**`(chore):`** Bumped Java IR to latest (v53) +**`(chore):`** Unknown schemas are no longer incorrectly marked as `additionalProperties: true`. diff --git a/generators/typescript/codegen/package.json b/generators/typescript/codegen/package.json index 15b70ad5af8..8dc1b2687d7 100644 --- a/generators/typescript/codegen/package.json +++ b/generators/typescript/codegen/package.json @@ -28,7 +28,7 @@ "devDependencies": { "@fern-api/core-utils": "workspace:*", "@fern-api/base-generator": "workspace:*", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@types/jest": "^29.5.12", "@types/node": "18.7.18", "depcheck": "^1.4.6", diff --git a/generators/typescript/express/cli/package.json b/generators/typescript/express/cli/package.json index 83bd0cde9d4..5a0ebd5b3db 100644 --- a/generators/typescript/express/cli/package.json +++ b/generators/typescript/express/cli/package.json @@ -31,7 +31,7 @@ }, "devDependencies": { "@fern-fern/generator-exec-sdk": "^0.0.898", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/abstract-generator-cli": "workspace:*", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", diff --git a/generators/typescript/express/cli/src/ExpressGeneratorCli.ts b/generators/typescript/express/cli/src/ExpressGeneratorCli.ts index 35389879eec..315a099a3b1 100644 --- a/generators/typescript/express/cli/src/ExpressGeneratorCli.ts +++ b/generators/typescript/express/cli/src/ExpressGeneratorCli.ts @@ -5,7 +5,6 @@ import { NpmPackage, PersistedTypescriptProject } from "@fern-typescript/commons import { GeneratorContext } from "@fern-typescript/contexts"; import { ExpressGenerator } from "@fern-typescript/express-generator"; import { camelCase, upperFirst } from "lodash-es"; -import { custom } from "zod"; import { ExpressCustomConfig } from "./custom-config/ExpressCustomConfig"; import { ExpressCustomConfigSchema } from "./custom-config/schema/ExpressCustomConfigSchema"; @@ -13,6 +12,7 @@ export class ExpressGeneratorCli extends AbstractGeneratorCli { + return this.intermediateRepresentation.types; + } + private generateTypeDeclarations() { - for (const typeDeclaration of Object.values(this.intermediateRepresentation.types)) { + for (const typeDeclaration of Object.values(this.getTypesToGenerate())) { this.withSourceFile({ filepath: this.typeDeclarationReferencer.getExportedFilepath(typeDeclaration.name), run: ({ sourceFile, importsManager }) => { - const context = this.generateExpressContext({ sourceFile, importsManager }); + const context = this.generateExpressContext({ + logger: this.context.logger, + sourceFile, + importsManager + }); context.type.getGeneratedType(typeDeclaration.name).writeToFile(context); } }); @@ -289,11 +299,15 @@ export class ExpressGenerator { } private generateTypeSchemas() { - for (const typeDeclaration of Object.values(this.intermediateRepresentation.types)) { + for (const typeDeclaration of Object.values(this.getTypesToGenerate())) { this.withSourceFile({ filepath: this.typeSchemaDeclarationReferencer.getExportedFilepath(typeDeclaration.name), run: ({ sourceFile, importsManager }) => { - const context = this.generateExpressContext({ sourceFile, importsManager }); + const context = this.generateExpressContext({ + logger: this.context.logger, + sourceFile, + importsManager + }); context.typeSchema.getGeneratedTypeSchema(typeDeclaration.name).writeToFile(context); } }); @@ -305,7 +319,11 @@ export class ExpressGenerator { this.withSourceFile({ filepath: this.expressErrorDeclarationReferencer.getExportedFilepath(errorDeclaration.name), run: ({ sourceFile, importsManager }) => { - const context = this.generateExpressContext({ sourceFile, importsManager }); + const context = this.generateExpressContext({ + logger: this.context.logger, + sourceFile, + importsManager + }); context.expressError.getGeneratedExpressError(errorDeclaration.name).writeToFile(context); } }); @@ -317,7 +335,11 @@ export class ExpressGenerator { this.withSourceFile({ filepath: this.expressErrorSchemaDeclarationReferencer.getExportedFilepath(errorDeclaration.name), run: ({ sourceFile, importsManager }) => { - const context = this.generateExpressContext({ sourceFile, importsManager }); + const context = this.generateExpressContext({ + logger: this.context.logger, + sourceFile, + importsManager + }); context.expressErrorSchema .getGeneratedExpressErrorSchema(errorDeclaration.name) ?.writeToFile(context); @@ -336,7 +358,11 @@ export class ExpressGenerator { endpoint }), run: ({ sourceFile, importsManager }) => { - const context = this.generateExpressContext({ sourceFile, importsManager }); + const context = this.generateExpressContext({ + logger: this.context.logger, + sourceFile, + importsManager + }); context.expressInlinedRequestBody .getGeneratedInlinedRequestBody(packageId, endpoint.name) .writeToFile(context); @@ -357,7 +383,11 @@ export class ExpressGenerator { endpoint }), run: ({ sourceFile, importsManager }) => { - const context = this.generateExpressContext({ sourceFile, importsManager }); + const context = this.generateExpressContext({ + logger: this.context.logger, + sourceFile, + importsManager + }); context.expressInlinedRequestBodySchema .getGeneratedInlinedRequestBodySchema(packageId, endpoint.name) .writeToFile(context); @@ -377,7 +407,11 @@ export class ExpressGenerator { endpoint }), run: ({ sourceFile, importsManager }) => { - const context = this.generateExpressContext({ sourceFile, importsManager }); + const context = this.generateExpressContext({ + logger: this.context.logger, + sourceFile, + importsManager + }); context.expressEndpointTypeSchemas .getGeneratedEndpointTypeSchemas(packageId, endpoint.name) .writeToFile(context); @@ -392,7 +426,11 @@ export class ExpressGenerator { this.withSourceFile({ filepath: this.expressServiceDeclarationReferencer.getExportedFilepath(packageId), run: ({ sourceFile, importsManager }) => { - const context = this.generateExpressContext({ sourceFile, importsManager }); + const context = this.generateExpressContext({ + logger: this.context.logger, + sourceFile, + importsManager + }); context.expressService.getGeneratedExpressService(packageId).writeToFile(context); } }); @@ -403,7 +441,11 @@ export class ExpressGenerator { this.withSourceFile({ filepath: this.expressRegisterDeclarationReferencer.getExportedFilepath(), run: ({ sourceFile, importsManager }) => { - const context = this.generateExpressContext({ sourceFile, importsManager }); + const context = this.generateExpressContext({ + logger: this.context.logger, + sourceFile, + importsManager + }); context.expressRegister.getGeneratedExpressRegister()?.writeToFile(context); } }); @@ -413,7 +455,11 @@ export class ExpressGenerator { this.withSourceFile({ filepath: this.genericApiExpressErrorDeclarationReferencer.getExportedFilepath(), run: ({ sourceFile, importsManager }) => { - const context = this.generateExpressContext({ sourceFile, importsManager }); + const context = this.generateExpressContext({ + logger: this.context.logger, + sourceFile, + importsManager + }); context.genericAPIExpressError.getGeneratedGenericAPIExpressError().writeToFile(context); } }); @@ -470,13 +516,16 @@ export class ExpressGenerator { } private generateExpressContext({ + logger, sourceFile, importsManager }: { + logger: Logger; sourceFile: SourceFile; importsManager: ImportsManager; }): ExpressContextImpl { return new ExpressContextImpl({ + logger, sourceFile, coreUtilitiesManager: this.coreUtilitiesManager, dependencyManager: this.dependencyManager, @@ -509,7 +558,8 @@ export class ExpressGenerator { expressErrorSchemaGenerator: this.expressErrorSchemaGenerator, includeSerdeLayer: this.config.includeSerdeLayer, retainOriginalCasing: this.config.retainOriginalCasing, - useBigInt: this.config.useBigInt + useBigInt: this.config.useBigInt, + enableInlineTypes: false }); } } diff --git a/generators/typescript/express/generator/src/contexts/ExpressContextImpl.ts b/generators/typescript/express/generator/src/contexts/ExpressContextImpl.ts index 8e1513d8dcb..e3a21c2957d 100644 --- a/generators/typescript/express/generator/src/contexts/ExpressContextImpl.ts +++ b/generators/typescript/express/generator/src/contexts/ExpressContextImpl.ts @@ -26,6 +26,7 @@ import { TypeGenerator } from "@fern-typescript/type-generator"; import { TypeReferenceExampleGenerator } from "@fern-typescript/type-reference-example-generator"; import { TypeSchemaGenerator } from "@fern-typescript/type-schema-generator"; import { SourceFile } from "ts-morph"; +import { Logger } from "@fern-api/logger"; import { EndpointDeclarationReferencer } from "../declaration-referencers/EndpointDeclarationReferencer"; import { ExpressErrorDeclarationReferencer } from "../declaration-referencers/ExpressErrorDeclarationReferencer"; import { ExpressInlinedRequestBodyDeclarationReferencer } from "../declaration-referencers/ExpressInlinedRequestBodyDeclarationReferencer"; @@ -45,6 +46,7 @@ import { TypeContextImpl } from "./type/TypeContextImpl"; export declare namespace ExpressContextImpl { export interface Init { + logger: Logger; sourceFile: SourceFile; importsManager: ImportsManager; dependencyManager: DependencyManager; @@ -78,10 +80,12 @@ export declare namespace ExpressContextImpl { includeSerdeLayer: boolean; retainOriginalCasing: boolean; useBigInt: boolean; + enableInlineTypes: boolean; } } export class ExpressContextImpl implements ExpressContext { + public readonly logger: Logger; public readonly sourceFile: SourceFile; public readonly externalDependencies: ExternalDependencies; public readonly coreUtilities: CoreUtilities; @@ -101,6 +105,7 @@ export class ExpressContextImpl implements ExpressContext { public readonly expressErrorSchema: ExpressErrorSchemaContext; constructor({ + logger, typeResolver, typeGenerator, typeDeclarationReferencer, @@ -132,8 +137,10 @@ export class ExpressContextImpl implements ExpressContext { expressErrorSchemaGenerator, includeSerdeLayer, retainOriginalCasing, + enableInlineTypes, useBigInt }: ExpressContextImpl.Init) { + this.logger = logger; this.includeSerdeLayer = includeSerdeLayer; this.sourceFile = sourceFile; this.externalDependencies = createExternalDependencies({ @@ -156,7 +163,9 @@ export class ExpressContextImpl implements ExpressContext { treatUnknownAsAny, includeSerdeLayer, retainOriginalCasing, - useBigInt + useBigInt, + enableInlineTypes, + context: this }); this.typeSchema = new TypeSchemaContextImpl({ sourceFile, @@ -170,7 +179,8 @@ export class ExpressContextImpl implements ExpressContext { treatUnknownAsAny, includeSerdeLayer, retainOriginalCasing, - useBigInt + useBigInt, + enableInlineTypes }); this.expressInlinedRequestBody = new ExpressInlinedRequestBodyContextImpl({ diff --git a/generators/typescript/express/generator/src/contexts/type-schema/TypeSchemaContextImpl.ts b/generators/typescript/express/generator/src/contexts/type-schema/TypeSchemaContextImpl.ts index e79c44acd7e..817c3595b76 100644 --- a/generators/typescript/express/generator/src/contexts/type-schema/TypeSchemaContextImpl.ts +++ b/generators/typescript/express/generator/src/contexts/type-schema/TypeSchemaContextImpl.ts @@ -9,7 +9,7 @@ import { TypeReferenceToSchemaConverter } from "@fern-typescript/type-reference-converters"; import { TypeSchemaGenerator } from "@fern-typescript/type-schema-generator"; -import { SourceFile } from "ts-morph"; +import { SourceFile, ts } from "ts-morph"; import { TypeDeclarationReferencer } from "../../declaration-referencers/TypeDeclarationReferencer"; import { getSchemaImportStrategy } from "../getSchemaImportStrategy"; @@ -27,6 +27,7 @@ export declare namespace TypeSchemaContextImpl { includeSerdeLayer: boolean; retainOriginalCasing: boolean; useBigInt: boolean; + enableInlineTypes: boolean; } } @@ -56,17 +57,20 @@ export class TypeSchemaContextImpl implements TypeSchemaContext { treatUnknownAsAny, includeSerdeLayer, retainOriginalCasing, - useBigInt + useBigInt, + enableInlineTypes }: TypeSchemaContextImpl.Init) { this.sourceFile = sourceFile; this.coreUtilities = coreUtilities; this.importsManager = importsManager; this.typeReferenceToRawTypeNodeConverter = new TypeReferenceToRawTypeNodeConverter({ getReferenceToNamedType: (typeName) => this.getReferenceToRawNamedType(typeName).getEntityName(), + generateForInlineUnion: (typeName) => this.generateForInlineUnion(typeName), typeResolver, treatUnknownAsAny, includeSerdeLayer, - useBigInt + useBigInt, + enableInlineTypes }); this.typeReferenceToSchemaConverter = new TypeReferenceToSchemaConverter({ getSchemaOfNamedType: (typeName) => this.getSchemaOfNamedType(typeName, { isGeneratingSchema: true }), @@ -74,7 +78,8 @@ export class TypeSchemaContextImpl implements TypeSchemaContext { typeResolver, treatUnknownAsAny, includeSerdeLayer, - useBigInt + useBigInt, + enableInlineTypes }); this.typeDeclarationReferencer = typeDeclarationReferencer; this.typeSchemaDeclarationReferencer = typeSchemaDeclarationReferencer; @@ -104,7 +109,8 @@ export class TypeSchemaContextImpl implements TypeSchemaContext { typeName: this.typeDeclarationReferencer.getExportedName(typeDeclaration.name), getReferenceToSelf: (context) => context.type.getReferenceToNamedType(typeName), includeSerdeLayer: this.includeSerdeLayer, - retainOriginalCasing: this.retainOriginalCasing + retainOriginalCasing: this.retainOriginalCasing, + inline: typeDeclaration.inline ?? false }), getReferenceToGeneratedType: () => this.typeDeclarationReferencer @@ -129,7 +135,7 @@ export class TypeSchemaContextImpl implements TypeSchemaContext { } public getReferenceToRawType(typeReference: TypeReference): TypeReferenceNode { - return this.typeReferenceToRawTypeNodeConverter.convert(typeReference); + return this.typeReferenceToRawTypeNodeConverter.convert({ typeReference }); } public getReferenceToRawNamedType(typeName: DeclaredTypeName): Reference { @@ -146,8 +152,12 @@ export class TypeSchemaContextImpl implements TypeSchemaContext { }); } + private generateForInlineUnion(typeName: DeclaredTypeName): ts.TypeNode { + throw new Error("Inline unions are not supported in Express Schemas"); + } + public getSchemaOfTypeReference(typeReference: TypeReference): Zurg.Schema { - return this.typeReferenceToSchemaConverter.convert(typeReference); + return this.typeReferenceToSchemaConverter.convert({ typeReference }); } public getSchemaOfNamedType( diff --git a/generators/typescript/express/generator/src/contexts/type/TypeContextImpl.ts b/generators/typescript/express/generator/src/contexts/type/TypeContextImpl.ts index 00f71925f04..e2b627d0ec1 100644 --- a/generators/typescript/express/generator/src/contexts/type/TypeContextImpl.ts +++ b/generators/typescript/express/generator/src/contexts/type/TypeContextImpl.ts @@ -1,12 +1,13 @@ import { DeclaredTypeName, ExampleTypeReference, + ObjectProperty, ResolvedTypeReference, TypeDeclaration, TypeReference } from "@fern-fern/ir-sdk/api"; import { ImportsManager, Reference, TypeReferenceNode } from "@fern-typescript/commons"; -import { GeneratedType, GeneratedTypeReferenceExample, TypeContext } from "@fern-typescript/contexts"; +import { BaseContext, GeneratedType, GeneratedTypeReferenceExample, TypeContext } from "@fern-typescript/contexts"; import { TypeResolver } from "@fern-typescript/resolvers"; import { TypeGenerator } from "@fern-typescript/type-generator"; import { @@ -29,6 +30,8 @@ export declare namespace TypeContextImpl { includeSerdeLayer: boolean; retainOriginalCasing: boolean; useBigInt: boolean; + context: BaseContext; + enableInlineTypes: boolean; } } @@ -43,6 +46,7 @@ export class TypeContextImpl implements TypeContext { private typeReferenceExampleGenerator: TypeReferenceExampleGenerator; private includeSerdeLayer: boolean; private retainOriginalCasing: boolean; + private context: BaseContext; constructor({ sourceFile, @@ -54,7 +58,9 @@ export class TypeContextImpl implements TypeContext { treatUnknownAsAny, includeSerdeLayer, retainOriginalCasing, - useBigInt + useBigInt, + enableInlineTypes, + context }: TypeContextImpl.Init) { this.sourceFile = sourceFile; this.importsManager = importsManager; @@ -64,24 +70,61 @@ export class TypeContextImpl implements TypeContext { this.typeReferenceExampleGenerator = typeReferenceExampleGenerator; this.includeSerdeLayer = includeSerdeLayer; this.retainOriginalCasing = retainOriginalCasing; + this.context = context; this.typeReferenceToParsedTypeNodeConverter = new TypeReferenceToParsedTypeNodeConverter({ getReferenceToNamedType: (typeName) => this.getReferenceToNamedType(typeName).getEntityName(), + generateForInlineUnion: (typeName) => this.generateForInlineUnion(typeName), typeResolver, treatUnknownAsAny, includeSerdeLayer, - useBigInt + useBigInt, + enableInlineTypes }); this.typeReferenceToStringExpressionConverter = new TypeReferenceToStringExpressionConverter({ typeResolver, treatUnknownAsAny, includeSerdeLayer, - useBigInt + useBigInt, + enableInlineTypes }); } public getReferenceToType(typeReference: TypeReference): TypeReferenceNode { - return this.typeReferenceToParsedTypeNodeConverter.convert(typeReference); + return this.typeReferenceToParsedTypeNodeConverter.convert({ typeReference }); + } + + public getReferenceToInlinePropertyType( + typeReference: TypeReference, + parentTypeName: string, + propertyName: string + ): TypeReferenceNode { + return this.typeReferenceToParsedTypeNodeConverter.convert({ + typeReference, + type: "inlinePropertyParams", + parentTypeName, + propertyName + }); + } + + public getReferenceToInlineAliasType(typeReference: TypeReference, aliasTypeName: string): TypeReferenceNode { + return this.typeReferenceToParsedTypeNodeConverter.convert({ + typeReference, + type: "inlineAliasParams", + aliasTypeName + }); + } + + public generateForInlineUnion(typeName: DeclaredTypeName): ts.TypeNode { + const generatedType = this.getGeneratedType(typeName); + return generatedType.generateForInlineUnion(this.context); + } + + public getReferenceToTypeForInlineUnion(typeReference: TypeReference): TypeReferenceNode { + return this.typeReferenceToParsedTypeNodeConverter.convert({ + typeReference, + type: "forInlineUnionParams" + }); } public getTypeDeclaration(typeName: DeclaredTypeName): TypeDeclaration { @@ -110,7 +153,7 @@ export class TypeContextImpl implements TypeContext { return this.getGeneratedType(typeDeclaration.name); } - public getGeneratedType(typeName: DeclaredTypeName): GeneratedType { + public getGeneratedType(typeName: DeclaredTypeName, typeNameOverride?: string): GeneratedType { const typeDeclaration = this.typeResolver.getTypeDeclarationFromName(typeName); const examples = typeDeclaration.userProvidedExamples; if (examples.length === 0) { @@ -120,12 +163,13 @@ export class TypeContextImpl implements TypeContext { return this.typeGenerator.generateType({ shape: typeDeclaration.shape, docs: typeDeclaration.docs ?? undefined, - typeName: this.typeDeclarationReferencer.getExportedName(typeDeclaration.name), + typeName: typeNameOverride ?? this.typeDeclarationReferencer.getExportedName(typeDeclaration.name), examples, fernFilepath: typeDeclaration.name.fernFilepath, getReferenceToSelf: (context) => context.type.getReferenceToNamedType(typeName), includeSerdeLayer: this.includeSerdeLayer, - retainOriginalCasing: this.retainOriginalCasing + retainOriginalCasing: this.retainOriginalCasing, + inline: typeDeclaration.inline ?? false }); } @@ -135,11 +179,13 @@ export class TypeContextImpl implements TypeContext { { includeNullCheckIfOptional }: { includeNullCheckIfOptional: boolean } ): ts.Expression { if (includeNullCheckIfOptional) { - return this.typeReferenceToStringExpressionConverter.convertWithNullCheckIfOptional(valueType)( - valueToStringify - ); + return this.typeReferenceToStringExpressionConverter.convertWithNullCheckIfOptional({ + typeReference: valueType + })(valueToStringify); } else { - return this.typeReferenceToStringExpressionConverter.convert(valueType)(valueToStringify); + return this.typeReferenceToStringExpressionConverter.convert({ + typeReference: valueType + })(valueToStringify); } } diff --git a/generators/typescript/model/type-generator/package.json b/generators/typescript/model/type-generator/package.json index afa139c4c1a..c7b904b8884 100644 --- a/generators/typescript/model/type-generator/package.json +++ b/generators/typescript/model/type-generator/package.json @@ -27,7 +27,7 @@ "depcheck": "depcheck" }, "dependencies": { - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", "@fern-typescript/union-generator": "workspace:*", diff --git a/generators/typescript/model/type-generator/src/AbstractGeneratedType.ts b/generators/typescript/model/type-generator/src/AbstractGeneratedType.ts index a3050ec5a2c..8529b489ae5 100644 --- a/generators/typescript/model/type-generator/src/AbstractGeneratedType.ts +++ b/generators/typescript/model/type-generator/src/AbstractGeneratedType.ts @@ -1,7 +1,7 @@ import { ExampleType, ExampleTypeShape, FernFilepath } from "@fern-fern/ir-sdk/api"; import { GetReferenceOpts, getTextOfTsNode, Reference } from "@fern-typescript/commons"; -import { BaseGeneratedType } from "@fern-typescript/contexts"; -import { ts } from "ts-morph"; +import { BaseContext, BaseGeneratedType } from "@fern-typescript/contexts"; +import { ModuleDeclarationStructure, StatementStructures, ts, WriterFunction } from "ts-morph"; export declare namespace AbstractGeneratedType { export interface Init { @@ -14,12 +14,14 @@ export declare namespace AbstractGeneratedType { includeSerdeLayer: boolean; noOptionalProperties: boolean; retainOriginalCasing: boolean; + /** Whether inline types should be inlined */ + enableInlineTypes: boolean; } } const EXAMPLE_PREFIX = " "; -export abstract class AbstractGeneratedType implements BaseGeneratedType { +export abstract class AbstractGeneratedType implements BaseGeneratedType { protected typeName: string; protected shape: Shape; protected examples: ExampleType[]; @@ -28,6 +30,7 @@ export abstract class AbstractGeneratedType implements BaseGener protected includeSerdeLayer: boolean; protected noOptionalProperties: boolean; protected retainOriginalCasing: boolean; + protected enableInlineTypes: boolean; private docs: string | undefined; @@ -40,7 +43,8 @@ export abstract class AbstractGeneratedType implements BaseGener fernFilepath, includeSerdeLayer, noOptionalProperties, - retainOriginalCasing + retainOriginalCasing, + enableInlineTypes }: AbstractGeneratedType.Init) { this.typeName = typeName; this.shape = shape; @@ -51,6 +55,7 @@ export abstract class AbstractGeneratedType implements BaseGener this.includeSerdeLayer = includeSerdeLayer; this.noOptionalProperties = noOptionalProperties; this.retainOriginalCasing = retainOriginalCasing; + this.enableInlineTypes = enableInlineTypes; } protected getDocs(context: Context): string | undefined { @@ -72,6 +77,14 @@ export abstract class AbstractGeneratedType implements BaseGener return groups.join("\n\n"); } - public abstract writeToFile(context: Context): void; + public writeToFile(context: Context): void { + context.sourceFile.addStatements(this.generateStatements(context)); + } + + public abstract generateStatements( + context: Context + ): string | WriterFunction | (string | WriterFunction | StatementStructures)[]; + public abstract generateForInlineUnion(context: Context): ts.TypeNode; + public abstract generateModule(context: Context): ModuleDeclarationStructure | undefined; public abstract buildExample(example: ExampleTypeShape, context: Context, opts: GetReferenceOpts): ts.Expression; } diff --git a/generators/typescript/model/type-generator/src/TypeGenerator.ts b/generators/typescript/model/type-generator/src/TypeGenerator.ts index 2c18dac5794..82791705f42 100644 --- a/generators/typescript/model/type-generator/src/TypeGenerator.ts +++ b/generators/typescript/model/type-generator/src/TypeGenerator.ts @@ -17,7 +17,7 @@ import { GeneratedType, GeneratedUndiscriminatedUnionType, GeneratedUnionType, - ModelContext + BaseContext } from "@fern-typescript/contexts"; import { GeneratedAliasTypeImpl } from "./alias/GeneratedAliasTypeImpl"; import { GeneratedBrandedStringAliasImpl } from "./alias/GeneratedBrandedStringAliasImpl"; @@ -34,6 +34,7 @@ export declare namespace TypeGenerator { includeSerdeLayer: boolean; noOptionalProperties: boolean; retainOriginalCasing: boolean; + enableInlineTypes: boolean; } export namespace generateType { @@ -46,17 +47,19 @@ export declare namespace TypeGenerator { getReferenceToSelf: (context: Context) => Reference; includeSerdeLayer: boolean; retainOriginalCasing: boolean; + inline: boolean; } } } -export class TypeGenerator { +export class TypeGenerator { private useBrandedStringAliases: boolean; private includeUtilsOnUnionMembers: boolean; private includeOtherInUnionTypes: boolean; private includeSerdeLayer: boolean; private noOptionalProperties: boolean; private retainOriginalCasing: boolean; + private enableInlineTypes: boolean; constructor({ useBrandedStringAliases, @@ -64,7 +67,8 @@ export class TypeGenerator { includeOtherInUnionTypes, includeSerdeLayer, noOptionalProperties, - retainOriginalCasing + retainOriginalCasing, + enableInlineTypes }: TypeGenerator.Init) { this.useBrandedStringAliases = useBrandedStringAliases; this.includeUtilsOnUnionMembers = includeUtilsOnUnionMembers; @@ -72,6 +76,7 @@ export class TypeGenerator { this.includeSerdeLayer = includeSerdeLayer; this.noOptionalProperties = noOptionalProperties; this.retainOriginalCasing = retainOriginalCasing; + this.enableInlineTypes = enableInlineTypes; } public generateType({ @@ -80,10 +85,12 @@ export class TypeGenerator { typeName, docs, fernFilepath, - getReferenceToSelf + getReferenceToSelf, + inline }: TypeGenerator.generateType.Args): GeneratedType { return Type._visit>(shape, { - union: (shape) => this.generateUnion({ typeName, shape, examples, docs, fernFilepath, getReferenceToSelf }), + union: (shape) => + this.generateUnion({ typeName, shape, examples, docs, fernFilepath, getReferenceToSelf, inline }), undiscriminatedUnion: (shape) => this.generateUndiscriminatedUnion({ typeName, @@ -135,7 +142,8 @@ export class TypeGenerator { getReferenceToSelf, includeSerdeLayer: this.includeSerdeLayer, noOptionalProperties: this.noOptionalProperties, - retainOriginalCasing: this.retainOriginalCasing + retainOriginalCasing: this.retainOriginalCasing, + enableInlineTypes: this.enableInlineTypes }); } @@ -145,7 +153,8 @@ export class TypeGenerator { examples, docs, fernFilepath, - getReferenceToSelf + getReferenceToSelf, + inline }: { typeName: string; shape: UnionTypeDeclaration; @@ -153,6 +162,7 @@ export class TypeGenerator { docs: string | undefined; fernFilepath: FernFilepath; getReferenceToSelf: (context: Context) => Reference; + inline: boolean; }): GeneratedUnionType { return new GeneratedUnionTypeImpl({ typeName, @@ -165,7 +175,9 @@ export class TypeGenerator { includeOtherInUnionTypes: this.includeOtherInUnionTypes, includeSerdeLayer: this.includeSerdeLayer, noOptionalProperties: this.noOptionalProperties, - retainOriginalCasing: this.retainOriginalCasing + retainOriginalCasing: this.retainOriginalCasing, + enableInlineTypes: this.enableInlineTypes, + inline }); } @@ -193,7 +205,8 @@ export class TypeGenerator { getReferenceToSelf, includeSerdeLayer: this.includeSerdeLayer, noOptionalProperties: this.noOptionalProperties, - retainOriginalCasing: this.retainOriginalCasing + retainOriginalCasing: this.retainOriginalCasing, + enableInlineTypes: this.enableInlineTypes }); } @@ -222,7 +235,8 @@ export class TypeGenerator { includeSerdeLayer: this.includeSerdeLayer, noOptionalProperties: this.noOptionalProperties, includeEnumUtils: this.includeUtilsOnUnionMembers, - retainOriginalCasing: this.retainOriginalCasing + retainOriginalCasing: this.retainOriginalCasing, + enableInlineTypes: this.enableInlineTypes }); } @@ -251,7 +265,8 @@ export class TypeGenerator { getReferenceToSelf, includeSerdeLayer: this.includeSerdeLayer, noOptionalProperties: this.noOptionalProperties, - retainOriginalCasing: this.retainOriginalCasing + retainOriginalCasing: this.retainOriginalCasing, + enableInlineTypes: this.enableInlineTypes }) : new GeneratedAliasTypeImpl({ typeName, @@ -262,7 +277,8 @@ export class TypeGenerator { getReferenceToSelf, includeSerdeLayer: this.includeSerdeLayer, noOptionalProperties: this.noOptionalProperties, - retainOriginalCasing: this.retainOriginalCasing + retainOriginalCasing: this.retainOriginalCasing, + enableInlineTypes: this.enableInlineTypes }); } } diff --git a/generators/typescript/model/type-generator/src/alias/GeneratedAliasTypeImpl.ts b/generators/typescript/model/type-generator/src/alias/GeneratedAliasTypeImpl.ts index 487ed372ddd..873abd928e3 100644 --- a/generators/typescript/model/type-generator/src/alias/GeneratedAliasTypeImpl.ts +++ b/generators/typescript/model/type-generator/src/alias/GeneratedAliasTypeImpl.ts @@ -1,33 +1,72 @@ import { ExampleTypeShape, TypeReference } from "@fern-fern/ir-sdk/api"; -import { GetReferenceOpts, getTextOfTsNode, maybeAddDocs } from "@fern-typescript/commons"; -import { ModelContext, NotBrandedGeneratedAliasType } from "@fern-typescript/contexts"; -import { ts } from "ts-morph"; +import { + generateInlineAliasModule, + GetReferenceOpts, + getTextOfTsNode, + maybeAddDocsStructure +} from "@fern-typescript/commons"; +import { BaseContext, NotBrandedGeneratedAliasType } from "@fern-typescript/contexts"; +import { + ModuleDeclarationStructure, + StatementStructures, + StructureKind, + ts, + TypeAliasDeclarationStructure, + WriterFunction +} from "ts-morph"; import { AbstractGeneratedType } from "../AbstractGeneratedType"; -export class GeneratedAliasTypeImpl +export class GeneratedAliasTypeImpl extends AbstractGeneratedType implements NotBrandedGeneratedAliasType { public readonly type = "alias"; public readonly isBranded = false; - public writeToFile(context: Context): void { - this.writeTypeAlias(context); + public generateStatements( + context: Context + ): string | WriterFunction | (string | WriterFunction | StatementStructures)[] { + const statements: StatementStructures[] = [this.generateTypeAlias(context)]; + const module = this.generateModule(context); + if (module) { + statements.push(module); + } + return statements; } - public buildExample(example: ExampleTypeShape, context: Context, opts: GetReferenceOpts): ts.Expression { - if (example.type !== "alias") { - throw new Error("Example is not for an alias"); - } - return context.type.getGeneratedExample(example.value).build(context, opts); + public generateForInlineUnion(context: Context): ts.TypeNode { + return context.type.getReferenceToType(this.shape).typeNode; } - private writeTypeAlias(context: Context) { - const typeAlias = context.sourceFile.addTypeAlias({ + private generateTypeAlias(context: Context): TypeAliasDeclarationStructure { + const typeAlias: TypeAliasDeclarationStructure = { + kind: StructureKind.TypeAlias, name: this.typeName, - type: getTextOfTsNode(context.type.getReferenceToType(this.shape).typeNode), + type: getTextOfTsNode(context.type.getReferenceToInlineAliasType(this.shape, this.typeName).typeNode), isExported: true + }; + maybeAddDocsStructure(typeAlias, this.getDocs(context)); + return typeAlias; + } + + public generateModule(context: Context): ModuleDeclarationStructure | undefined { + if (!this.enableInlineTypes) { + return undefined; + } + + return generateInlineAliasModule({ + aliasTypeName: this.typeName, + typeReference: this.shape, + generateStatements: (typeName, typeNameOverride) => + context.type.getGeneratedType(typeName, typeNameOverride).generateStatements(context), + getTypeDeclaration: (namedType) => context.type.getTypeDeclaration(namedType) }); - maybeAddDocs(typeAlias, this.getDocs(context)); + } + + public buildExample(example: ExampleTypeShape, context: Context, opts: GetReferenceOpts): ts.Expression { + if (example.type !== "alias") { + throw new Error("Example is not for an alias"); + } + return context.type.getGeneratedExample(example.value).build(context, opts); } } diff --git a/generators/typescript/model/type-generator/src/alias/GeneratedBrandedStringAliasImpl.ts b/generators/typescript/model/type-generator/src/alias/GeneratedBrandedStringAliasImpl.ts index 895b95f3991..e700272c7aa 100644 --- a/generators/typescript/model/type-generator/src/alias/GeneratedBrandedStringAliasImpl.ts +++ b/generators/typescript/model/type-generator/src/alias/GeneratedBrandedStringAliasImpl.ts @@ -1,19 +1,44 @@ import { ExampleTypeShape, TypeReference } from "@fern-fern/ir-sdk/api"; -import { GetReferenceOpts, getTextOfTsKeyword, getTextOfTsNode, maybeAddDocs } from "@fern-typescript/commons"; -import { BrandedGeneratedAliasType, ModelContext } from "@fern-typescript/contexts"; -import { ts } from "ts-morph"; +import { + GetReferenceOpts, + getTextOfTsKeyword, + getTextOfTsNode, + maybeAddDocsNode, + maybeAddDocsStructure, + writerToString +} from "@fern-typescript/commons"; +import { BrandedGeneratedAliasType, BaseContext } from "@fern-typescript/contexts"; +import { + FunctionDeclarationStructure, + ModuleDeclarationStructure, + StatementStructures, + StructureKind, + ts, + TypeAliasDeclarationStructure, + WriterFunction +} from "ts-morph"; import { AbstractGeneratedType } from "../AbstractGeneratedType"; -export class GeneratedBrandedStringAliasImpl +export class GeneratedBrandedStringAliasImpl extends AbstractGeneratedType implements BrandedGeneratedAliasType { public readonly type = "alias"; public readonly isBranded = true; - public writeToFile(context: Context): void { - this.writeTypeAlias(context); - this.writeBuilder(context); + public generateStatements( + context: Context + ): string | WriterFunction | (string | WriterFunction | StatementStructures)[] { + return [this.generateTypeAliasStructure(context), this.generateBuilderFunction(context)]; + } + + public generateForInlineUnion(context: Context): ts.TypeNode { + const type = writerToString(this.generateTypeAliasStructure(context).type); + return ts.factory.createTypeReferenceNode(type); + } + + public generateModule(): ModuleDeclarationStructure | undefined { + return undefined; } public getReferenceToCreator(context: Context, opts?: GetReferenceOpts): ts.Expression { @@ -29,10 +54,11 @@ export class GeneratedBrandedStringAliasImpl ]); } - private writeTypeAlias(context: Context) { + private generateTypeAliasStructure(context: Context): TypeAliasDeclarationStructure { const referenceToAliasedType = context.type.getReferenceToType(this.shape).typeNode; - const typeAlias = context.sourceFile.addTypeAlias({ + const typeAlias: TypeAliasDeclarationStructure = { name: this.typeName, + kind: StructureKind.TypeAlias, type: getTextOfTsNode( ts.factory.createIntersectionTypeNode([ referenceToAliasedType, @@ -47,13 +73,15 @@ export class GeneratedBrandedStringAliasImpl ]) ), isExported: true - }); - maybeAddDocs(typeAlias, this.getDocs(context)); + }; + maybeAddDocsStructure(typeAlias, this.getDocs(context)); + return typeAlias; } - private writeBuilder(context: Context) { + private generateBuilderFunction(context: Context): FunctionDeclarationStructure { const VALUE_PARAMETER_NAME = "value"; - context.sourceFile.addFunction({ + const builderFunction: FunctionDeclarationStructure = { + kind: StructureKind.Function, name: this.typeName, parameters: [ { @@ -76,7 +104,8 @@ export class GeneratedBrandedStringAliasImpl ) ], isExported: true - }); + }; + return builderFunction; } private getStringBrand(): string { diff --git a/generators/typescript/model/type-generator/src/enum/GeneratedEnumTypeImpl.ts b/generators/typescript/model/type-generator/src/enum/GeneratedEnumTypeImpl.ts index 4405053cb5b..e5dda9347b3 100644 --- a/generators/typescript/model/type-generator/src/enum/GeneratedEnumTypeImpl.ts +++ b/generators/typescript/model/type-generator/src/enum/GeneratedEnumTypeImpl.ts @@ -3,10 +3,23 @@ import { GetReferenceOpts, getTextOfTsNode, getWriterForMultiLineUnionType, - maybeAddDocs + maybeAddDocsNode, + maybeAddDocsStructure } from "@fern-typescript/commons"; import { BaseContext, GeneratedEnumType } from "@fern-typescript/contexts"; -import { OptionalKind, PropertySignatureStructure, ts, VariableDeclarationKind } from "ts-morph"; +import { + ModuleDeclarationStructure, + OptionalKind, + PropertySignatureStructure, + StatementStructures, + StructureKind, + ts, + TypeAliasDeclarationStructure, + VariableDeclarationKind, + VariableStatementStructure, + WriterFunction, + WriterFunctionOrValue +} from "ts-morph"; import { AbstractGeneratedType } from "../AbstractGeneratedType"; export declare namespace GeneratedEnumTypeImpl { @@ -34,28 +47,48 @@ export class GeneratedEnumTypeImpl this.includeEnumUtils = includeEnumUtils; } - public writeToFile(context: Context): void { - const type = context.sourceFile.addTypeAlias({ + private generateEnumType(context: Context): TypeAliasDeclarationStructure { + const type: TypeAliasDeclarationStructure = { + kind: StructureKind.TypeAlias, name: this.typeName, isExported: true, type: getWriterForMultiLineUnionType( this.shape.values.map((value) => ({ docs: value.docs, - node: ts.factory.createLiteralTypeNode(ts.factory.createStringLiteral(value.name.wireValue)) + node: ts.factory.createStringLiteral(value.name.wireValue) })) ) - }); + }; + + maybeAddDocsStructure(type, this.getDocs(context)); + return type; + } - maybeAddDocs(type, this.getDocs(context)); + public generateForInlineUnion(context: Context): ts.TypeNode { + return ts.factory.createParenthesizedType( + ts.factory.createUnionTypeNode( + this.shape.values.map((value) => + ts.factory.createLiteralTypeNode(ts.factory.createStringLiteral(value.name.wireValue)) + ) + ) + ); + } - this.addConst(context); + public generateStatements( + context: Context + ): string | WriterFunction | (string | WriterFunction | StatementStructures)[] { + const statements: (string | WriterFunction | StatementStructures)[] = [ + this.generateEnumType(context), + this.generateConst(context) + ]; if (this.includeEnumUtils) { - this.addModule(context); + statements.push(this.generateModule()); } + return statements; } - private addConst(context: Context) { + private generateConst(context: Context): VariableStatementStructure { const constProperties = this.shape.values.map((value) => ts.factory.createPropertyAssignment( ts.factory.createIdentifier(this.getEnumValueName(value)), @@ -160,7 +193,8 @@ export class GeneratedEnumTypeImpl ); } - context.sourceFile.addVariableStatement({ + return { + kind: StructureKind.VariableStatement, declarationKind: VariableDeclarationKind.Const, isExported: true, declarations: [ @@ -174,50 +208,55 @@ export class GeneratedEnumTypeImpl ) } ] - }); + }; } - private addModule(context: Context) { - const enumModule = context.sourceFile.addModule({ + public generateModule(): ModuleDeclarationStructure { + const enumModule: ModuleDeclarationStructure = { + kind: StructureKind.Module, name: this.typeName, isExported: true, - hasDeclareKeyword: true - }); - - enumModule.addInterface({ - name: GeneratedEnumTypeImpl.VISITOR_INTERFACE_NAME, - typeParameters: [GeneratedEnumTypeImpl.VISITOR_RETURN_TYPE_PARAMETER], - properties: [ - ...this.shape.values.map( - (enumValue): OptionalKind => ({ - name: this.getEnumValueVisitPropertyName(enumValue), - type: getTextOfTsNode( - ts.factory.createFunctionTypeNode( - undefined, - [], - ts.factory.createTypeReferenceNode( - GeneratedEnumTypeImpl.VISITOR_RETURN_TYPE_PARAMETER, - undefined - ) - ) - ) - }) - ), + hasDeclareKeyword: false, + statements: [ { - name: GeneratedEnumTypeImpl.OTHER_VISITOR_METHOD_NAME, - type: getTextOfTsNode( - ts.factory.createFunctionTypeNode( - undefined, - [], - ts.factory.createTypeReferenceNode( - GeneratedEnumTypeImpl.VISITOR_RETURN_TYPE_PARAMETER, - undefined + kind: StructureKind.Interface, + name: GeneratedEnumTypeImpl.VISITOR_INTERFACE_NAME, + typeParameters: [GeneratedEnumTypeImpl.VISITOR_RETURN_TYPE_PARAMETER], + properties: [ + ...this.shape.values.map( + (enumValue): OptionalKind => ({ + name: this.getEnumValueVisitPropertyName(enumValue), + type: getTextOfTsNode( + ts.factory.createFunctionTypeNode( + undefined, + [], + ts.factory.createTypeReferenceNode( + GeneratedEnumTypeImpl.VISITOR_RETURN_TYPE_PARAMETER, + undefined + ) + ) + ) + }) + ), + { + name: GeneratedEnumTypeImpl.OTHER_VISITOR_METHOD_NAME, + type: getTextOfTsNode( + ts.factory.createFunctionTypeNode( + undefined, + [], + ts.factory.createTypeReferenceNode( + GeneratedEnumTypeImpl.VISITOR_RETURN_TYPE_PARAMETER, + undefined + ) + ) ) - ) - ) + } + ] } ] - }); + }; + + return enumModule; } public buildExample(example: ExampleTypeShape, context: Context, opts: GetReferenceOpts): ts.Expression { diff --git a/generators/typescript/model/type-generator/src/object/GeneratedObjectTypeImpl.ts b/generators/typescript/model/type-generator/src/object/GeneratedObjectTypeImpl.ts index 3d1fcefb8c1..7582ae5bac9 100644 --- a/generators/typescript/model/type-generator/src/object/GeneratedObjectTypeImpl.ts +++ b/generators/typescript/model/type-generator/src/object/GeneratedObjectTypeImpl.ts @@ -1,50 +1,129 @@ import { ExampleTypeShape, ObjectProperty, ObjectTypeDeclaration, TypeReference } from "@fern-fern/ir-sdk/api"; -import { GetReferenceOpts, getTextOfTsNode, maybeAddDocs } from "@fern-typescript/commons"; -import { GeneratedObjectType, ModelContext } from "@fern-typescript/contexts"; -import { OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; +import { + generateInlinePropertiesModule, + GetReferenceOpts, + getTextOfTsNode, + maybeAddDocsStructure, + TypeReferenceNode +} from "@fern-typescript/commons"; +import { GeneratedObjectType, BaseContext } from "@fern-typescript/contexts"; +import { + InterfaceDeclarationStructure, + ModuleDeclarationStructure, + PropertySignatureStructure, + StatementStructures, + StructureKind, + ts, + WriterFunction +} from "ts-morph"; import { AbstractGeneratedType } from "../AbstractGeneratedType"; -export class GeneratedObjectTypeImpl +interface Property { + name: string; + type: ts.TypeNode; + hasQuestionToken: boolean; + docs: string | undefined; + irProperty: ObjectProperty | undefined; +} + +export class GeneratedObjectTypeImpl extends AbstractGeneratedType implements GeneratedObjectType { public readonly type = "object"; - public writeToFile(context: Context): void { - const interfaceNode = context.sourceFile.addInterface({ - name: this.typeName, - properties: [ - ...this.shape.properties.map((property) => { - const value = context.type.getReferenceToType(property.valueType); - const propertyNode: OptionalKind = { - name: `"${this.getPropertyKeyFromProperty(property)}"`, - type: getTextOfTsNode( - this.noOptionalProperties ? value.typeNode : value.typeNodeWithoutUndefined - ), - hasQuestionToken: !this.noOptionalProperties && value.isOptional, - docs: property.docs != null ? [{ description: property.docs }] : undefined - }; - - return propertyNode; - }), - ...(this.shape.extraProperties - ? [ - { - name: "[key: string]", // This is the simpler way to add an index signature - type: "any", - docs: [{ description: "Accepts any additional properties" }] - } - ] - : []) - ], - isExported: true + public generateStatements( + context: Context + ): string | WriterFunction | (string | WriterFunction | StatementStructures)[] { + const statements: (string | WriterFunction | StatementStructures)[] = [this.generateInterface(context)]; + const iModule = this.generateModule(context); + if (iModule) { + statements.push(iModule); + } + return statements; + } + + public generateForInlineUnion(context: Context): ts.TypeNode { + return ts.factory.createTypeLiteralNode( + this.generatePropertiesInternal(context).map(({ name, type, hasQuestionToken, docs, irProperty }) => { + let propertyValue: ts.TypeNode = type; + if (irProperty) { + const inlineUnionRef = context.type.getReferenceToTypeForInlineUnion(irProperty.valueType); + propertyValue = hasQuestionToken + ? inlineUnionRef.typeNode + : inlineUnionRef.typeNodeWithoutUndefined; + } + return ts.factory.createPropertySignature( + undefined, + ts.factory.createIdentifier(name), + hasQuestionToken ? ts.factory.createToken(ts.SyntaxKind.QuestionToken) : undefined, + propertyValue + ); + }) + ); + } + + public generateProperties(context: Context): PropertySignatureStructure[] { + return this.generatePropertiesInternal(context).map(({ name, type, hasQuestionToken, docs }) => { + const propertyNode: PropertySignatureStructure = { + kind: StructureKind.PropertySignature, + name, + type: getTextOfTsNode(type), + hasQuestionToken, + docs: docs != null ? [{ description: docs }] : undefined + }; + + return propertyNode; }); + } - maybeAddDocs(interfaceNode, this.getDocs(context)); + private generatePropertiesInternal(context: Context): Property[] { + const props = this.shape.properties.map((property) => { + const value = this.getTypeForObjectProperty(context, property); + const propertyNode: Property = { + name: `"${this.getPropertyKeyFromProperty(property)}"`, + type: this.noOptionalProperties ? value.typeNode : value.typeNodeWithoutUndefined, + hasQuestionToken: !this.noOptionalProperties && value.isOptional, + docs: property.docs, + irProperty: property + }; + return propertyNode; + }); + if (this.shape.extraProperties) { + props.push({ + name: "[key: string]", // This is the simpler way to add an index signature + type: ts.factory.createTypeReferenceNode("any"), + hasQuestionToken: false, + docs: "Accepts any additional properties", + irProperty: undefined + }); + } + return props; + } + + public generateInterface(context: Context): InterfaceDeclarationStructure { + const interfaceNode: InterfaceDeclarationStructure = { + kind: StructureKind.Interface, + name: this.typeName, + properties: [...this.generateProperties(context)], + isExported: true + }; + maybeAddDocsStructure(interfaceNode, this.getDocs(context)); + const iExtends = []; for (const extension of this.shape.extends) { - interfaceNode.addExtends(getTextOfTsNode(context.type.getReferenceToNamedType(extension).getTypeNode())); + iExtends.push(getTextOfTsNode(context.type.getReferenceToNamedType(extension).getTypeNode())); } + interfaceNode.extends = iExtends; + return interfaceNode; + } + + private getTypeForObjectProperty(context: Context, property: ObjectProperty): TypeReferenceNode { + return context.type.getReferenceToInlinePropertyType( + property.valueType, + this.typeName, + property.name.name.pascalCase.safeName + ); } public getPropertyKey({ propertyWireKey }: { propertyWireKey: string }): string { @@ -125,4 +204,20 @@ export class GeneratedObjectTypeImpl }) ]; } + + public generateModule(context: Context): ModuleDeclarationStructure | undefined { + if (!this.enableInlineTypes) { + return undefined; + } + return generateInlinePropertiesModule({ + parentTypeName: this.typeName, + properties: this.shape.properties.map((prop) => ({ + propertyName: prop.name.name.pascalCase.safeName, + typeReference: prop.valueType + })), + generateStatements: (typeName, typeNameOverride) => + context.type.getGeneratedType(typeName, typeNameOverride).generateStatements(context), + getTypeDeclaration: (namedType) => context.type.getTypeDeclaration(namedType) + }); + } } diff --git a/generators/typescript/model/type-generator/src/undiscriminated-union/GeneratedUndiscriminatedUnionTypeImpl.ts b/generators/typescript/model/type-generator/src/undiscriminated-union/GeneratedUndiscriminatedUnionTypeImpl.ts index 94a347ab875..655d8e0dd3a 100644 --- a/generators/typescript/model/type-generator/src/undiscriminated-union/GeneratedUndiscriminatedUnionTypeImpl.ts +++ b/generators/typescript/model/type-generator/src/undiscriminated-union/GeneratedUndiscriminatedUnionTypeImpl.ts @@ -1,28 +1,66 @@ -import { ExampleTypeShape, UndiscriminatedUnionTypeDeclaration } from "@fern-fern/ir-sdk/api"; -import { GetReferenceOpts, getWriterForMultiLineUnionType, maybeAddDocs } from "@fern-typescript/commons"; -import { GeneratedUndiscriminatedUnionType, ModelContext } from "@fern-typescript/contexts"; -import { ts } from "ts-morph"; +import { + ExampleTypeShape, + UndiscriminatedUnionMember, + UndiscriminatedUnionTypeDeclaration +} from "@fern-fern/ir-sdk/api"; +import { + GetReferenceOpts, + getWriterForMultiLineUnionType, + maybeAddDocsNode, + maybeAddDocsStructure +} from "@fern-typescript/commons"; +import { GeneratedUndiscriminatedUnionType, BaseContext } from "@fern-typescript/contexts"; +import { + ModuleDeclarationStructure, + StatementStructures, + StructureKind, + ts, + TypeAliasDeclarationStructure, + WriterFunction +} from "ts-morph"; import { AbstractGeneratedType } from "../AbstractGeneratedType"; -export class GeneratedUndiscriminatedUnionTypeImpl +export class GeneratedUndiscriminatedUnionTypeImpl extends AbstractGeneratedType implements GeneratedUndiscriminatedUnionType { public readonly type = "undiscriminatedUnion"; - public writeToFile(context: Context): void { - const type = context.sourceFile.addTypeAlias({ + public generateStatements( + context: Context + ): string | WriterFunction | (string | WriterFunction | StatementStructures)[] { + const statements: StatementStructures[] = [this.generateTypeAlias(context)]; + return statements; + } + + public generateForInlineUnion(context: Context): ts.TypeNode { + return ts.factory.createUnionTypeNode(this.shape.members.map((value) => this.getTypeNode(context, value))); + } + + public generateModule(): ModuleDeclarationStructure | undefined { + return undefined; + } + + private generateTypeAlias(context: Context): TypeAliasDeclarationStructure { + const alias: TypeAliasDeclarationStructure = { name: this.typeName, + kind: StructureKind.TypeAlias, isExported: true, type: getWriterForMultiLineUnionType( - this.shape.members.map((value) => ({ - docs: value.docs, - node: context.type.getReferenceToType(value.type).typeNode - })) + this.shape.members.map((value) => { + return { + docs: value.docs, + node: this.getTypeNode(context, value) + }; + }) ) - }); + }; + maybeAddDocsStructure(alias, this.getDocs(context)); + return alias; + } - maybeAddDocs(type, this.getDocs(context)); + private getTypeNode(context: Context, member: UndiscriminatedUnionMember): ts.TypeNode { + return context.type.getReferenceToTypeForInlineUnion(member.type).typeNode; } public buildExample(example: ExampleTypeShape, context: Context, opts: GetReferenceOpts): ts.Expression { diff --git a/generators/typescript/model/type-generator/src/union/GeneratedUnionTypeImpl.ts b/generators/typescript/model/type-generator/src/union/GeneratedUnionTypeImpl.ts index 5757e2c358a..90c632d2360 100644 --- a/generators/typescript/model/type-generator/src/union/GeneratedUnionTypeImpl.ts +++ b/generators/typescript/model/type-generator/src/union/GeneratedUnionTypeImpl.ts @@ -5,36 +5,40 @@ import { UnionTypeDeclaration } from "@fern-fern/ir-sdk/api"; import { GetReferenceOpts } from "@fern-typescript/commons"; -import { GeneratedUnion, GeneratedUnionType, ModelContext } from "@fern-typescript/contexts"; +import { GeneratedUnion, GeneratedUnionType, BaseContext } from "@fern-typescript/contexts"; import { GeneratedUnionImpl } from "@fern-typescript/union-generator"; -import { ts } from "ts-morph"; +import { ModuleDeclarationStructure, StatementStructures, ts, WriterFunction } from "ts-morph"; import { AbstractGeneratedType } from "../AbstractGeneratedType"; import { ParsedSingleUnionTypeForUnion } from "./ParsedSingleUnionTypeForUnion"; import { UnknownSingleUnionType } from "./UnknownSingleUnionType"; import { UnknownSingleUnionTypeGenerator } from "./UnknownSingleUnionTypeGenerator"; export declare namespace GeneratedUnionTypeImpl { - export interface Init + export interface Init extends AbstractGeneratedType.Init { includeUtilsOnUnionMembers: boolean; includeOtherInUnionTypes: boolean; + inline: boolean; } } -export class GeneratedUnionTypeImpl +export class GeneratedUnionTypeImpl extends AbstractGeneratedType implements GeneratedUnionType { public readonly type = "union"; private generatedUnion: GeneratedUnionImpl; + private readonly inline: boolean; constructor({ includeUtilsOnUnionMembers, includeOtherInUnionTypes, + inline, ...superInit }: GeneratedUnionTypeImpl.Init) { super(superInit); + this.inline = inline; const parsedSingleUnionTypes = this.shape.types.map( (singleUnionType) => @@ -44,7 +48,8 @@ export class GeneratedUnionTypeImpl includeUtilsOnUnionMembers, includeSerdeLayer: this.includeSerdeLayer, retainOriginalCasing: this.retainOriginalCasing, - noOptionalProperties: this.noOptionalProperties + noOptionalProperties: this.noOptionalProperties, + enableInlineTypes: this.enableInlineTypes }) ); @@ -67,12 +72,24 @@ export class GeneratedUnionTypeImpl baseProperties: this.shape.baseProperties, includeSerdeLayer: this.includeSerdeLayer, retainOriginalCasing: this.retainOriginalCasing, - noOptionalProperties: this.noOptionalProperties + noOptionalProperties: this.noOptionalProperties, + inline: this.inline, + enableInlineTypes: this.enableInlineTypes }); } - public writeToFile(context: Context): void { - this.generatedUnion.writeToFile(context); + public generateStatements( + context: Context + ): string | WriterFunction | (string | WriterFunction | StatementStructures)[] { + return this.generatedUnion.generateStatements(context); + } + + public generateForInlineUnion(context: Context): ts.TypeNode { + return this.generatedUnion.generateForInlineUnion(context); + } + + public generateModule(): ModuleDeclarationStructure | undefined { + return undefined; } public getGeneratedUnion(): GeneratedUnion { diff --git a/generators/typescript/model/type-generator/src/union/ParsedSingleUnionTypeForUnion.ts b/generators/typescript/model/type-generator/src/union/ParsedSingleUnionTypeForUnion.ts index 36da8b43008..4c456fdbdba 100644 --- a/generators/typescript/model/type-generator/src/union/ParsedSingleUnionTypeForUnion.ts +++ b/generators/typescript/model/type-generator/src/union/ParsedSingleUnionTypeForUnion.ts @@ -5,7 +5,7 @@ import { SingleUnionTypeProperty, UnionTypeDeclaration } from "@fern-fern/ir-sdk/api"; -import { ModelContext } from "@fern-typescript/contexts"; +import { BaseContext } from "@fern-typescript/contexts"; import { AbstractKnownSingleUnionType, NoPropertiesSingleUnionTypeGenerator, @@ -22,10 +22,11 @@ export declare namespace ParsedSingleUnionTypeForUnion { includeSerdeLayer: boolean; retainOriginalCasing: boolean; noOptionalProperties: boolean; + enableInlineTypes: boolean; } } -export class ParsedSingleUnionTypeForUnion extends AbstractKnownSingleUnionType { +export class ParsedSingleUnionTypeForUnion extends AbstractKnownSingleUnionType { private singleUnionTypeFromUnion: SingleUnionType; private includeSerdeLayer: boolean; private retainOriginalCasing: boolean; @@ -37,7 +38,8 @@ export class ParsedSingleUnionTypeForUnion extends includeUtilsOnUnionMembers, includeSerdeLayer, retainOriginalCasing, - noOptionalProperties + noOptionalProperties, + enableInlineTypes }: ParsedSingleUnionTypeForUnion.Init) { super({ singleUnionType: SingleUnionTypeProperties._visit>( @@ -45,7 +47,7 @@ export class ParsedSingleUnionTypeForUnion extends { noProperties: () => new NoPropertiesSingleUnionTypeGenerator(), samePropertiesAsObject: (extended) => - new SamePropertiesAsObjectSingleUnionTypeGenerator({ extended }), + new SamePropertiesAsObjectSingleUnionTypeGenerator({ extended, enableInlineTypes }), singleProperty: (singleProperty) => new SinglePropertySingleUnionTypeGenerator({ propertyName: ParsedSingleUnionTypeForUnion.getSinglePropertyKey(singleProperty, { @@ -54,7 +56,10 @@ export class ParsedSingleUnionTypeForUnion extends }), getReferenceToPropertyType: (context) => context.type.getReferenceToType(singleProperty.type), - noOptionalProperties + getReferenceToPropertyTypeForInlineUnion: (context) => + context.type.getReferenceToTypeForInlineUnion(singleProperty.type), + noOptionalProperties, + enableInlineTypes }), _other: () => { throw new Error("Unknown SingleUnionTypeProperties: " + singleUnionType.shape.propertiesType); diff --git a/generators/typescript/model/type-generator/src/union/SamePropertiesAsObjectSingleUnionTypeGenerator.ts b/generators/typescript/model/type-generator/src/union/SamePropertiesAsObjectSingleUnionTypeGenerator.ts index 7c62f2b5e14..3ffa593082e 100644 --- a/generators/typescript/model/type-generator/src/union/SamePropertiesAsObjectSingleUnionTypeGenerator.ts +++ b/generators/typescript/model/type-generator/src/union/SamePropertiesAsObjectSingleUnionTypeGenerator.ts @@ -1,29 +1,69 @@ import { DeclaredTypeName } from "@fern-fern/ir-sdk/api"; -import { ModelContext } from "@fern-typescript/contexts"; +import { BaseContext } from "@fern-typescript/contexts"; import { SingleUnionTypeGenerator } from "@fern-typescript/union-generator"; -import { OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; +import { ModuleDeclarationStructure, OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; export declare namespace SamePropertiesAsObjectSingleUnionTypeGenerator { export interface Init { extended: DeclaredTypeName; + enableInlineTypes: boolean; } } -export class SamePropertiesAsObjectSingleUnionTypeGenerator +export class SamePropertiesAsObjectSingleUnionTypeGenerator implements SingleUnionTypeGenerator { private static BUILDER_PARAMETER_NAME = "value"; private extended: DeclaredTypeName; + private enableInlineTypes: boolean; - constructor({ extended }: SamePropertiesAsObjectSingleUnionTypeGenerator.Init) { + constructor({ extended, enableInlineTypes }: SamePropertiesAsObjectSingleUnionTypeGenerator.Init) { this.extended = extended; + this.enableInlineTypes = enableInlineTypes; + } + + public generateForInlineUnion(context: Context): ts.TypeNode { + const typeDeclaration = context.type.getTypeDeclaration(this.extended); + if (typeDeclaration.inline) { + const type = context.type.getGeneratedType(typeDeclaration.name); + return type.generateForInlineUnion(context); + } + return context.type.getReferenceToNamedType(this.extended).getTypeNode(); } public getExtendsForInterface(context: Context): ts.TypeNode[] { + const typeDeclaration = context.type.getTypeDeclaration(this.extended); + if (this.enableInlineTypes && typeDeclaration.inline) { + // inline types don't inherit the properties from the interface, but have the properties directly on the parent interface + return []; + } return [context.type.getReferenceToNamedType(this.extended).getTypeNode()]; } + public getDiscriminantPropertiesForInterface(context: Context): OptionalKind[] { + const typeDeclaration = context.type.getTypeDeclaration(this.extended); + if (this.enableInlineTypes && typeDeclaration.inline) { + const type = context.type.getGeneratedType(typeDeclaration.name); + if (type.type === "object") { + return type.generateProperties(context); + } + } + return []; + } + + public generateModule(context: Context): ModuleDeclarationStructure | undefined { + if (!this.enableInlineTypes) { + return undefined; + } + const typeDeclaration = context.type.getTypeDeclaration(this.extended); + if (!typeDeclaration.inline) { + return undefined; + } + const type = context.type.getGeneratedType(typeDeclaration.name); + return type.generateModule(context); + } + public getNonDiscriminantPropertiesForInterface(): OptionalKind[] { return []; } diff --git a/generators/typescript/model/type-generator/src/union/UnknownSingleUnionType.ts b/generators/typescript/model/type-generator/src/union/UnknownSingleUnionType.ts index 87fe64ae931..8f8cb0725bb 100644 --- a/generators/typescript/model/type-generator/src/union/UnknownSingleUnionType.ts +++ b/generators/typescript/model/type-generator/src/union/UnknownSingleUnionType.ts @@ -1,7 +1,7 @@ -import { ModelContext } from "@fern-typescript/contexts"; +import { BaseContext } from "@fern-typescript/contexts"; import { AbstractUnknownSingleUnionType } from "@fern-typescript/union-generator"; -export class UnknownSingleUnionType extends AbstractUnknownSingleUnionType { +export class UnknownSingleUnionType extends AbstractUnknownSingleUnionType { public getDocs(): string | null | undefined { return undefined; } diff --git a/generators/typescript/model/type-generator/src/union/UnknownSingleUnionTypeGenerator.ts b/generators/typescript/model/type-generator/src/union/UnknownSingleUnionTypeGenerator.ts index b003385945e..75697b73ae3 100644 --- a/generators/typescript/model/type-generator/src/union/UnknownSingleUnionTypeGenerator.ts +++ b/generators/typescript/model/type-generator/src/union/UnknownSingleUnionTypeGenerator.ts @@ -1,14 +1,26 @@ -import { ModelContext } from "@fern-typescript/contexts"; +import { BaseContext } from "@fern-typescript/contexts"; import { SingleUnionTypeGenerator } from "@fern-typescript/union-generator"; -import { OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; +import { ModuleDeclarationStructure, OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; -export class UnknownSingleUnionTypeGenerator implements SingleUnionTypeGenerator { +export class UnknownSingleUnionTypeGenerator implements SingleUnionTypeGenerator { private static BUILDER_PARAMETER_NAME = "value"; + public generateForInlineUnion(context: BaseContext): ts.TypeNode { + return ts.factory.createKeywordTypeNode(ts.SyntaxKind.AnyKeyword); + } + public getExtendsForInterface(): ts.TypeNode[] { return []; } + public getDiscriminantPropertiesForInterface(): OptionalKind[] { + return []; + } + + public generateModule(context: BaseContext): ModuleDeclarationStructure | undefined { + return undefined; + } + public getNonDiscriminantPropertiesForInterface(): OptionalKind[] { return []; } @@ -22,7 +34,7 @@ export class UnknownSingleUnionTypeGenerator implements SingleUnionTypeGenerator } public getVisitMethodParameterType( - _context: ModelContext, + _context: BaseContext, { discriminant }: { discriminant: string } ): ts.TypeNode | undefined { return ts.factory.createTypeLiteralNode([ @@ -36,7 +48,7 @@ export class UnknownSingleUnionTypeGenerator implements SingleUnionTypeGenerator } public getParametersForBuilder( - _context: ModelContext, + _context: BaseContext, { discriminant }: { discriminant: string } ): ts.ParameterDeclaration[] { return [ diff --git a/generators/typescript/model/type-reference-converters/package.json b/generators/typescript/model/type-reference-converters/package.json index b19dd645d68..e5405ede708 100644 --- a/generators/typescript/model/type-reference-converters/package.json +++ b/generators/typescript/model/type-reference-converters/package.json @@ -27,7 +27,8 @@ "depcheck": "depcheck" }, "dependencies": { - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", + "@fern-api/core-utils": "workspace:*", "@fern-typescript/commons": "workspace:*", "@fern-typescript/resolvers": "workspace:*", "ts-morph": "^15.1.0" diff --git a/generators/typescript/model/type-reference-converters/src/AbstractTypeReferenceConverter.ts b/generators/typescript/model/type-reference-converters/src/AbstractTypeReferenceConverter.ts index d191e53c8d5..e698ff62e20 100644 --- a/generators/typescript/model/type-reference-converters/src/AbstractTypeReferenceConverter.ts +++ b/generators/typescript/model/type-reference-converters/src/AbstractTypeReferenceConverter.ts @@ -18,63 +18,129 @@ export declare namespace AbstractTypeReferenceConverter { treatUnknownAsAny: boolean; includeSerdeLayer: boolean; useBigInt: boolean; + enableInlineTypes: boolean; } } +export type ConvertTypeReferenceParams = + | ConvertTypeReferenceParams.DefaultParams + | ConvertTypeReferenceParams.InlinePropertyTypeParams + | ConvertTypeReferenceParams.InlineAliasTypeParams + | ConvertTypeReferenceParams.ForInlineUnionTypeParams; + +export namespace ConvertTypeReferenceParams { + export function isInlinePropertyParams(params: ConvertTypeReferenceParams): params is InlinePropertyTypeParams { + return params.type === "inlinePropertyParams"; + } + export function isInlineAliasParams(params: ConvertTypeReferenceParams): params is InlineAliasTypeParams { + return params.type === "inlineAliasParams"; + } + export function isForInlineUnionParams(params: ConvertTypeReferenceParams): params is ForInlineUnionTypeParams { + return params.type === "forInlineUnionParams"; + } + export function hasGenericIn( + params: ConvertTypeReferenceParams + ): params is InlinePropertyTypeParams | InlineAliasTypeParams { + return isInlinePropertyParams(params) || isInlineAliasParams(params); + } + + export interface DefaultParams extends WithTypeReference { + type?: undefined; + } + + /** + * Metadata for converting inline types + */ + export interface InlinePropertyTypeParams extends WithGenericIn, WithTypeReference { + type: "inlinePropertyParams"; + parentTypeName: string; + propertyName: string; + } + + export interface InlineAliasTypeParams extends WithGenericIn, WithTypeReference { + type: "inlineAliasParams"; + aliasTypeName: string; + } + + export interface ForInlineUnionTypeParams extends WithTypeReference { + type: "forInlineUnionParams"; + } + + export interface WithGenericIn { + genericIn?: GenericIn; + } + + export interface WithTypeReference { + typeReference: TypeReference; + } + + export const GenericIn = { + List: "list", + Map: "map", + Set: "set" + } as const; + export type GenericIn = typeof GenericIn[keyof typeof GenericIn]; +} + +const genericIn = ConvertTypeReferenceParams.GenericIn; + export abstract class AbstractTypeReferenceConverter { protected typeResolver: TypeResolver; protected treatUnknownAsAny: boolean; protected includeSerdeLayer: boolean; protected useBigInt: boolean; + protected enableInlineTypes: boolean; constructor({ typeResolver, treatUnknownAsAny, includeSerdeLayer, - useBigInt + useBigInt, + enableInlineTypes }: AbstractTypeReferenceConverter.Init) { this.typeResolver = typeResolver; this.treatUnknownAsAny = treatUnknownAsAny; this.includeSerdeLayer = includeSerdeLayer; this.useBigInt = useBigInt; + this.enableInlineTypes = enableInlineTypes; } - public convert(typeReference: TypeReference): T { - return TypeReference._visit(typeReference, { - named: this.named.bind(this), - primitive: this.primitive.bind(this), - container: this.container.bind(this), - unknown: this.treatUnknownAsAny ? this.any.bind(this) : this.unknown.bind(this), + public convert(params: ConvertTypeReferenceParams): T { + return TypeReference._visit(params.typeReference, { + named: (type) => this.named(type, params), + primitive: (type) => this.primitive(type), + container: (type) => this.container(type, params), + unknown: () => (this.treatUnknownAsAny ? this.any() : this.unknown()), _other: () => { - throw new Error("Unexpected type reference: " + typeReference.type); + throw new Error("Unexpected type reference: " + params.typeReference.type); } }); } - protected container(container: ContainerType): T { + protected container(container: ContainerType, params: ConvertTypeReferenceParams): T { return ContainerType._visit(container, { - map: this.map.bind(this), - list: this.list.bind(this), - set: this.set.bind(this), - optional: this.optional.bind(this), - literal: this.literal.bind(this), + map: (type) => this.map(type, setGenericIn(params, genericIn.Map)), + list: (type) => this.list(type, setGenericIn(params, genericIn.List)), + set: (type) => this.set(type, setGenericIn(params, genericIn.Set)), + optional: (type) => this.optional(type, params), + literal: (type) => this.literal(type, params), _other: () => { throw new Error("Unexpected container type: " + container.type); } }); } - protected abstract named(typeName: DeclaredTypeName): T; + protected abstract named(typeName: DeclaredTypeName, params: ConvertTypeReferenceParams): T; protected abstract string(): T; protected abstract number(): T; protected abstract long(): T; protected abstract bigInteger(): T; protected abstract boolean(): T; protected abstract dateTime(): T; - protected abstract list(itemType: TypeReference): T; - protected abstract set(itemType: TypeReference): T; - protected abstract optional(itemType: TypeReference): T; - protected abstract literal(literal: Literal): T; + protected abstract list(itemType: TypeReference, params: ConvertTypeReferenceParams): T; + protected abstract set(itemType: TypeReference, params: ConvertTypeReferenceParams): T; + protected abstract optional(itemType: TypeReference, params: ConvertTypeReferenceParams): T; + protected abstract literal(literal: Literal, params: ConvertTypeReferenceParams): T; protected abstract unknown(): T; protected abstract any(): T; @@ -99,17 +165,17 @@ export abstract class AbstractTypeReferenceConverter { }); } - protected map(mapType: MapType): T { + protected map(mapType: MapType, params: ConvertTypeReferenceParams): T { const resolvdKeyType = this.typeResolver.resolveTypeReference(mapType.keyType); if (resolvdKeyType.type === "named" && resolvdKeyType.shape === ShapeType.Enum) { - return this.mapWithEnumKeys(mapType); + return this.mapWithEnumKeys(mapType, params); } else { - return this.mapWithNonEnumKeys(mapType); + return this.mapWithNonEnumKeys(mapType, params); } } - protected abstract mapWithEnumKeys(mapType: MapType): T; - protected abstract mapWithNonEnumKeys(mapType: MapType): T; + protected abstract mapWithEnumKeys(mapType: MapType, params: ConvertTypeReferenceParams): T; + protected abstract mapWithNonEnumKeys(mapType: MapType, params: ConvertTypeReferenceParams): T; protected isTypeReferencePrimitive(typeReference: TypeReference): boolean { const resolvedType = this.typeResolver.resolveTypeReference(typeReference); @@ -130,3 +196,16 @@ export abstract class AbstractTypeReferenceConverter { }; } } + +function setGenericIn( + params: ConvertTypeReferenceParams, + genericIn: ConvertTypeReferenceParams.GenericIn +): ConvertTypeReferenceParams { + if (ConvertTypeReferenceParams.hasGenericIn(params)) { + params = { + ...params, + genericIn + }; + } + return params; +} diff --git a/generators/typescript/model/type-reference-converters/src/AbstractTypeReferenceToTypeNodeConverter.ts b/generators/typescript/model/type-reference-converters/src/AbstractTypeReferenceToTypeNodeConverter.ts index 5651e791176..b49c7aeed11 100644 --- a/generators/typescript/model/type-reference-converters/src/AbstractTypeReferenceToTypeNodeConverter.ts +++ b/generators/typescript/model/type-reference-converters/src/AbstractTypeReferenceToTypeNodeConverter.ts @@ -1,26 +1,38 @@ import { DeclaredTypeName, Literal, MapType, ResolvedTypeReference, TypeReference } from "@fern-fern/ir-sdk/api"; import { TypeReferenceNode } from "@fern-typescript/commons"; import { ts } from "ts-morph"; -import { AbstractTypeReferenceConverter } from "./AbstractTypeReferenceConverter"; +import { assertNever } from "@fern-api/core-utils"; +import { AbstractTypeReferenceConverter, ConvertTypeReferenceParams } from "./AbstractTypeReferenceConverter"; +import { InlineConsts } from "@fern-typescript/commons/src/codegen-utils/inlineConsts"; export declare namespace AbstractTypeReferenceToTypeNodeConverter { export interface Init extends AbstractTypeReferenceConverter.Init { - getReferenceToNamedType: (typeName: DeclaredTypeName) => ts.EntityName; + getReferenceToNamedType: (typeName: DeclaredTypeName, params: ConvertTypeReferenceParams) => ts.EntityName; + generateForInlineUnion(typeName: DeclaredTypeName): ts.TypeNode; } } export abstract class AbstractTypeReferenceToTypeNodeConverter extends AbstractTypeReferenceConverter { - protected getReferenceToNamedType: (typeName: DeclaredTypeName) => ts.EntityName; - - constructor({ getReferenceToNamedType, ...superInit }: AbstractTypeReferenceToTypeNodeConverter.Init) { + protected getReferenceToNamedType: ( + typeName: DeclaredTypeName, + params: ConvertTypeReferenceParams + ) => ts.EntityName; + protected generateForInlineUnion: (typeName: DeclaredTypeName) => ts.TypeNode; + + constructor({ + getReferenceToNamedType, + generateForInlineUnion, + ...superInit + }: AbstractTypeReferenceToTypeNodeConverter.Init) { super(superInit); this.getReferenceToNamedType = getReferenceToNamedType; + this.generateForInlineUnion = generateForInlineUnion; } - protected override named(typeName: DeclaredTypeName): TypeReferenceNode { + protected override named(typeName: DeclaredTypeName, params: ConvertTypeReferenceParams): TypeReferenceNode { const resolvedType = this.typeResolver.resolveTypeName(typeName); const isOptional = ResolvedTypeReference._visit(resolvedType, { - container: (container) => this.container(container).isOptional, + container: (container) => this.container(container, params).isOptional, primitive: (primitive) => this.primitive(primitive).isOptional, named: () => false, unknown: () => this.unknown().isOptional, @@ -29,7 +41,26 @@ export abstract class AbstractTypeReferenceToTypeNodeConverter extends AbstractT } }); - const typeNodeWithoutUndefined = ts.factory.createTypeReferenceNode(this.getReferenceToNamedType(typeName)); + let typeNodeWithoutUndefined: ts.TypeNode; + const typeDeclaration = this.typeResolver.getTypeDeclarationFromName(typeName); + if (this.enableInlineTypes && typeDeclaration.inline) { + if (ConvertTypeReferenceParams.isInlinePropertyParams(params)) { + typeNodeWithoutUndefined = this.createTypeRefenceForInlinePropertyNamedType(params); + } else if (ConvertTypeReferenceParams.isInlineAliasParams(params)) { + typeNodeWithoutUndefined = this.createTypeRefenceForInlineAliasNamedType(typeName, params); + } else if (ConvertTypeReferenceParams.isForInlineUnionParams(params)) { + typeNodeWithoutUndefined = this.createTypeRefenceForInlineNamedTypeForInlineUnion(typeName); + } else { + typeNodeWithoutUndefined = ts.factory.createTypeReferenceNode( + this.getReferenceToNamedType(typeName, params) + ); + } + } else { + typeNodeWithoutUndefined = ts.factory.createTypeReferenceNode( + this.getReferenceToNamedType(typeName, params) + ); + } + if (!isOptional) { return this.generateNonOptionalTypeReferenceNode(typeNodeWithoutUndefined); } else { @@ -41,6 +72,60 @@ export abstract class AbstractTypeReferenceToTypeNodeConverter extends AbstractT } } + private createTypeRefenceForInlineNamedTypeForInlineUnion(typeName: DeclaredTypeName): ts.TypeNode { + return this.generateForInlineUnion(typeName); + } + + private createTypeRefenceForInlineAliasNamedType( + typeName: DeclaredTypeName, + params: ConvertTypeReferenceParams.InlineAliasTypeParams + ): ts.TypeNode { + let name: ts.EntityName = ts.factory.createIdentifier(params.aliasTypeName); + switch (params.genericIn) { + case "list": + name = ts.factory.createQualifiedName(name, InlineConsts.LIST_ITEM_TYPE_NAME); + break; + case "map": + name = ts.factory.createQualifiedName(name, InlineConsts.MAP_VALUE_TYPE_NAME); + break; + case "set": + name = ts.factory.createQualifiedName(name, InlineConsts.LIST_ITEM_TYPE_NAME); + break; + default: + return ts.factory.createTypeReferenceNode(this.getReferenceToNamedType(typeName, params)); + } + + return ts.factory.createTypeReferenceNode(name); + } + + private createTypeRefenceForInlinePropertyNamedType({ + parentTypeName, + propertyName, + genericIn + }: ConvertTypeReferenceParams.InlinePropertyTypeParams): ts.TypeNode { + let name = ts.factory.createQualifiedName( + ts.factory.createIdentifier(parentTypeName), + ts.factory.createIdentifier(propertyName) + ); + switch (genericIn) { + case "list": + name = ts.factory.createQualifiedName(name, InlineConsts.LIST_ITEM_TYPE_NAME); + break; + case "map": + name = ts.factory.createQualifiedName(name, InlineConsts.MAP_VALUE_TYPE_NAME); + break; + case "set": + name = ts.factory.createQualifiedName(name, InlineConsts.LIST_ITEM_TYPE_NAME); + break; + case undefined: + break; + default: + assertNever(genericIn); + } + + return ts.factory.createTypeReferenceNode(name); + } + protected override string(): TypeReferenceNode { return this.generateNonOptionalTypeReferenceNode(ts.factory.createKeywordTypeNode(ts.SyntaxKind.StringKeyword)); } @@ -73,8 +158,8 @@ export abstract class AbstractTypeReferenceToTypeNodeConverter extends AbstractT return this.generateNonOptionalTypeReferenceNode(ts.factory.createKeywordTypeNode(ts.SyntaxKind.StringKeyword)); } - protected override optional(itemType: TypeReference): TypeReferenceNode { - const referencedToValueType = this.convert(itemType).typeNode; + protected override optional(itemType: TypeReference, params: ConvertTypeReferenceParams): TypeReferenceNode { + const referencedToValueType = this.convert({ ...params, typeReference: itemType }).typeNode; return { isOptional: true, typeNode: this.addUndefinedToTypeNode(referencedToValueType), @@ -107,9 +192,9 @@ export abstract class AbstractTypeReferenceToTypeNodeConverter extends AbstractT }; } - protected override list(itemType: TypeReference): TypeReferenceNode { + protected override list(itemType: TypeReference, params: ConvertTypeReferenceParams): TypeReferenceNode { return this.generateNonOptionalTypeReferenceNode( - ts.factory.createArrayTypeNode(this.convert(itemType).typeNode) + ts.factory.createArrayTypeNode(this.convert({ ...params, typeReference: itemType }).typeNode) ); } @@ -139,25 +224,25 @@ export abstract class AbstractTypeReferenceToTypeNodeConverter extends AbstractT }); } - protected override mapWithEnumKeys(map: MapType): TypeReferenceNode { - return this.mapWithOptionalValues(map); + protected override mapWithEnumKeys(map: MapType, params: ConvertTypeReferenceParams): TypeReferenceNode { + return this.mapWithOptionalValues(map, params); } - protected override mapWithNonEnumKeys(map: MapType): TypeReferenceNode { + protected override mapWithNonEnumKeys(map: MapType, params: ConvertTypeReferenceParams): TypeReferenceNode { return this.generateNonOptionalTypeReferenceNode( ts.factory.createTypeReferenceNode("Record", [ - this.convert(map.keyType).typeNode, - this.convert(map.valueType).typeNode + this.convert({ ...params, typeReference: map.keyType }).typeNode, + this.convert({ ...params, typeReference: map.valueType }).typeNode ]) ); } - protected mapWithOptionalValues(map: MapType): TypeReferenceNode { - const valueType = this.convert(map.valueType); + protected mapWithOptionalValues(map: MapType, params: ConvertTypeReferenceParams): TypeReferenceNode { + const valueType = this.convert({ ...params, typeReference: map.valueType }); return this.generateNonOptionalTypeReferenceNode( ts.factory.createTypeReferenceNode("Record", [ - this.convert(map.keyType).typeNode, - (valueType.isOptional ? valueType : this.optional(map.valueType)).typeNode + this.convert({ ...params, typeReference: map.keyType }).typeNode, + (valueType.isOptional ? valueType : this.optional(map.valueType, params)).typeNode ]) ); } diff --git a/generators/typescript/model/type-reference-converters/src/TypeReferenceToParsedTypeNodeConverter.ts b/generators/typescript/model/type-reference-converters/src/TypeReferenceToParsedTypeNodeConverter.ts index 7de607125bc..343fabec135 100644 --- a/generators/typescript/model/type-reference-converters/src/TypeReferenceToParsedTypeNodeConverter.ts +++ b/generators/typescript/model/type-reference-converters/src/TypeReferenceToParsedTypeNodeConverter.ts @@ -1,6 +1,7 @@ import { TypeReference } from "@fern-fern/ir-sdk/api"; import { TypeReferenceNode } from "@fern-typescript/commons"; import { ts } from "ts-morph"; +import { ConvertTypeReferenceParams } from "./AbstractTypeReferenceConverter"; import { AbstractTypeReferenceToTypeNodeConverter } from "./AbstractTypeReferenceToTypeNodeConverter"; export declare namespace TypeReferenceToParsedTypeNodeConverter { @@ -8,12 +9,12 @@ export declare namespace TypeReferenceToParsedTypeNodeConverter { } export class TypeReferenceToParsedTypeNodeConverter extends AbstractTypeReferenceToTypeNodeConverter { - protected override set(itemType: TypeReference): TypeReferenceNode { + protected override set(itemType: TypeReference, params: ConvertTypeReferenceParams): TypeReferenceNode { if (this.includeSerdeLayer && this.isTypeReferencePrimitive(itemType)) { - const itemTypeNode = this.convert(itemType).typeNode; + const itemTypeNode = this.convert({ ...params, typeReference: itemType }).typeNode; return this.generateNonOptionalTypeReferenceNode(ts.factory.createTypeReferenceNode("Set", [itemTypeNode])); } else { - return this.list(itemType); + return this.list(itemType, params); } } diff --git a/generators/typescript/model/type-reference-converters/src/TypeReferenceToRawTypeNodeConverter.ts b/generators/typescript/model/type-reference-converters/src/TypeReferenceToRawTypeNodeConverter.ts index 4bb04a41297..aeb0d6ae57a 100644 --- a/generators/typescript/model/type-reference-converters/src/TypeReferenceToRawTypeNodeConverter.ts +++ b/generators/typescript/model/type-reference-converters/src/TypeReferenceToRawTypeNodeConverter.ts @@ -1,17 +1,18 @@ import { TypeReference } from "@fern-fern/ir-sdk/api"; import { TypeReferenceNode } from "@fern-typescript/commons"; import { ts } from "ts-morph"; +import { ConvertTypeReferenceParams } from "./AbstractTypeReferenceConverter"; import { AbstractTypeReferenceToTypeNodeConverter } from "./AbstractTypeReferenceToTypeNodeConverter"; export class TypeReferenceToRawTypeNodeConverter extends AbstractTypeReferenceToTypeNodeConverter { - protected override set(itemType: TypeReference): TypeReferenceNode { + protected override set(itemType: TypeReference, params: ConvertTypeReferenceParams): TypeReferenceNode { return this.generateNonOptionalTypeReferenceNode( - ts.factory.createArrayTypeNode(this.convert(itemType).typeNode) + ts.factory.createArrayTypeNode(this.convert({ ...params, typeReference: itemType }).typeNode) ); } - protected override optional(itemType: TypeReference): TypeReferenceNode { - const referencedToValueType = this.convert(itemType).typeNode; + protected override optional(itemType: TypeReference, params: ConvertTypeReferenceParams): TypeReferenceNode { + const referencedToValueType = this.convert({ ...params, typeReference: itemType }).typeNode; return { isOptional: true, typeNode: ts.factory.createUnionTypeNode([ diff --git a/generators/typescript/model/type-reference-converters/src/TypeReferenceToSchemaConverter.ts b/generators/typescript/model/type-reference-converters/src/TypeReferenceToSchemaConverter.ts index 2c826715b6d..e3f96b82cea 100644 --- a/generators/typescript/model/type-reference-converters/src/TypeReferenceToSchemaConverter.ts +++ b/generators/typescript/model/type-reference-converters/src/TypeReferenceToSchemaConverter.ts @@ -1,6 +1,6 @@ import { DeclaredTypeName, Literal, MapType, TypeReference } from "@fern-fern/ir-sdk/api"; import { Zurg } from "@fern-typescript/commons"; -import { AbstractTypeReferenceConverter } from "./AbstractTypeReferenceConverter"; +import { AbstractTypeReferenceConverter, ConvertTypeReferenceParams } from "./AbstractTypeReferenceConverter"; export declare namespace TypeReferenceToSchemaConverter { export interface Init extends AbstractTypeReferenceConverter.Init { @@ -19,7 +19,7 @@ export class TypeReferenceToSchemaConverter extends AbstractTypeReferenceConvert this.zurg = zurg; } - protected override named(typeName: DeclaredTypeName): Zurg.Schema { + protected override named(typeName: DeclaredTypeName, params: ConvertTypeReferenceParams): Zurg.Schema { return this.getSchemaOfNamedType(typeName); } @@ -53,8 +53,8 @@ export class TypeReferenceToSchemaConverter extends AbstractTypeReferenceConvert return this.zurg.date(); } - protected override optional(itemType: TypeReference): Zurg.Schema { - return this.convert(itemType).optional(); + protected override optional(itemType: TypeReference, params: ConvertTypeReferenceParams): Zurg.Schema { + return this.convert({ ...params, typeReference: itemType }).optional(); } protected override unknown(): Zurg.Schema { @@ -65,8 +65,8 @@ export class TypeReferenceToSchemaConverter extends AbstractTypeReferenceConvert return this.zurg.any(); } - protected override list(itemType: TypeReference): Zurg.Schema { - return this.zurg.list(this.convert(itemType)); + protected override list(itemType: TypeReference, params: ConvertTypeReferenceParams): Zurg.Schema { + return this.zurg.list(this.convert({ ...params, typeReference: itemType })); } protected override literal(literal: Literal): Zurg.Schema { @@ -79,30 +79,33 @@ export class TypeReferenceToSchemaConverter extends AbstractTypeReferenceConvert }); } - protected override mapWithEnumKeys(map: MapType): Zurg.Schema { - return this.mapWithOptionalValues(map); + protected override mapWithEnumKeys(map: MapType, params: ConvertTypeReferenceParams): Zurg.Schema { + return this.mapWithOptionalValues(map, params); } - protected override mapWithNonEnumKeys({ keyType, valueType }: MapType): Zurg.Schema { + protected override mapWithNonEnumKeys( + { keyType, valueType }: MapType, + params: ConvertTypeReferenceParams + ): Zurg.Schema { return this.zurg.record({ - keySchema: this.convert(keyType), - valueSchema: this.convert(valueType) + keySchema: this.convert({ ...params, typeReference: keyType }), + valueSchema: this.convert({ ...params, typeReference: valueType }) }); } - protected mapWithOptionalValues({ keyType, valueType }: MapType): Zurg.Schema { - const valueSchema = this.convert(valueType); + protected mapWithOptionalValues({ keyType, valueType }: MapType, params: ConvertTypeReferenceParams): Zurg.Schema { + const valueSchema = this.convert({ ...params, typeReference: valueType }); return this.zurg.record({ - keySchema: this.convert(keyType), + keySchema: this.convert({ ...params, typeReference: keyType }), valueSchema: valueSchema.isOptional ? valueSchema : valueSchema.optional() }); } - protected override set(itemType: TypeReference): Zurg.Schema { + protected override set(itemType: TypeReference, params: ConvertTypeReferenceParams): Zurg.Schema { if (this.isTypeReferencePrimitive(itemType)) { - return this.zurg.set(this.convert(itemType)); + return this.zurg.set(this.convert({ ...params, typeReference: itemType })); } else { - return this.list(itemType); + return this.list(itemType, params); } } } diff --git a/generators/typescript/model/type-reference-converters/src/TypeReferenceToStringExpressionConverter.ts b/generators/typescript/model/type-reference-converters/src/TypeReferenceToStringExpressionConverter.ts index 6fbdaec0fbd..9effd39cfcf 100644 --- a/generators/typescript/model/type-reference-converters/src/TypeReferenceToStringExpressionConverter.ts +++ b/generators/typescript/model/type-reference-converters/src/TypeReferenceToStringExpressionConverter.ts @@ -7,7 +7,7 @@ import { TypeReference } from "@fern-fern/ir-sdk/api"; import { ts } from "ts-morph"; -import { AbstractTypeReferenceConverter } from "./AbstractTypeReferenceConverter"; +import { AbstractTypeReferenceConverter, ConvertTypeReferenceParams } from "./AbstractTypeReferenceConverter"; export declare namespace TypeReferenceToStringExpressionConverter { export interface Init extends AbstractTypeReferenceConverter.Init {} @@ -16,7 +16,10 @@ export declare namespace TypeReferenceToStringExpressionConverter { export class TypeReferenceToStringExpressionConverter extends AbstractTypeReferenceConverter< (reference: ts.Expression) => ts.Expression > { - public convertWithNullCheckIfOptional(type: TypeReference): (reference: ts.Expression) => ts.Expression { + public convertWithNullCheckIfOptional( + params: ConvertTypeReferenceParams + ): (reference: ts.Expression) => ts.Expression { + const type = params.typeReference; const isNullable = TypeReference._visit(type, { named: (typeName) => { const resolvedType = this.typeResolver.resolveTypeName(typeName); @@ -31,7 +34,7 @@ export class TypeReferenceToStringExpressionConverter extends AbstractTypeRefere }); if (!isNullable) { - return this.convert(type); + return this.convert(params); } return (reference) => @@ -42,21 +45,24 @@ export class TypeReferenceToStringExpressionConverter extends AbstractTypeRefere ts.factory.createNull() ), ts.factory.createToken(ts.SyntaxKind.QuestionToken), - this.convert(type)(reference), + this.convert(params)(reference), ts.factory.createToken(ts.SyntaxKind.ColonToken), ts.factory.createIdentifier("undefined") ); } - protected override named(typeName: DeclaredTypeName): (reference: ts.Expression) => ts.Expression { + protected override named( + typeName: DeclaredTypeName, + params: ConvertTypeReferenceParams + ): (reference: ts.Expression) => ts.Expression { const resolvedType = this.typeResolver.resolveTypeName(typeName); return ResolvedTypeReference._visit<(reference: ts.Expression) => ts.Expression>(resolvedType, { container: (containerType) => ContainerType._visit(containerType, { list: this.list.bind(this), - optional: this.optional.bind(this), + optional: (optionalType) => this.optional(optionalType, params), set: this.set.bind(this), - map: this.map.bind(this), + map: (mapType) => this.map(mapType, params), literal: this.literal.bind(this), _other: () => { throw new Error("Unknown ContainerType: " + containerType.type); @@ -137,8 +143,11 @@ export class TypeReferenceToStringExpressionConverter extends AbstractTypeRefere return (reference) => reference; } - protected override optional(itemType: TypeReference): (reference: ts.Expression) => ts.Expression { - return (reference) => this.convert(itemType)(reference); + protected override optional( + itemType: TypeReference, + params: ConvertTypeReferenceParams + ): (reference: ts.Expression) => ts.Expression { + return (reference) => this.convert({ ...params, typeReference: itemType })(reference); } protected override unknown(): (reference: ts.Expression) => ts.Expression { diff --git a/generators/typescript/model/type-reference-example-generator/package.json b/generators/typescript/model/type-reference-example-generator/package.json index 9249695b5d0..bb2b78f0016 100644 --- a/generators/typescript/model/type-reference-example-generator/package.json +++ b/generators/typescript/model/type-reference-example-generator/package.json @@ -28,7 +28,7 @@ }, "dependencies": { "@fern-api/core-utils": "workspace:*", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", "ts-morph": "^15.1.0" diff --git a/generators/typescript/model/type-reference-example-generator/src/GeneratedTypeReferenceExampleImpl.ts b/generators/typescript/model/type-reference-example-generator/src/GeneratedTypeReferenceExampleImpl.ts index 3319b62b028..ae783aafa9b 100644 --- a/generators/typescript/model/type-reference-example-generator/src/GeneratedTypeReferenceExampleImpl.ts +++ b/generators/typescript/model/type-reference-example-generator/src/GeneratedTypeReferenceExampleImpl.ts @@ -6,7 +6,7 @@ import { ExampleTypeReferenceShape } from "@fern-fern/ir-sdk/api"; import { GetReferenceOpts } from "@fern-typescript/commons"; -import { GeneratedTypeReferenceExample, ModelContext } from "@fern-typescript/contexts"; +import { GeneratedTypeReferenceExample, BaseContext } from "@fern-typescript/contexts"; import { ts } from "ts-morph"; export declare namespace GeneratedTypeReferenceExampleImpl { @@ -22,7 +22,7 @@ export class GeneratedTypeReferenceExampleImpl implements GeneratedTypeReference this.example = example; } - public build(context: ModelContext, opts: GetReferenceOpts): ts.Expression { + public build(context: BaseContext, opts: GetReferenceOpts): ts.Expression { return this.buildExample({ example: this.example, context, opts }); } @@ -32,7 +32,7 @@ export class GeneratedTypeReferenceExampleImpl implements GeneratedTypeReference opts }: { example: ExampleTypeReference; - context: ModelContext; + context: BaseContext; opts: GetReferenceOpts; }): ts.Expression { return ExampleTypeReferenceShape._visit(example.shape, { @@ -164,7 +164,7 @@ export class GeneratedTypeReferenceExampleImpl implements GeneratedTypeReference opts }: { example: ExampleTypeReference; - context: ModelContext; + context: BaseContext; opts: GetReferenceOpts; }): ts.PropertyName { return ExampleTypeReferenceShape._visit(example.shape, { diff --git a/generators/typescript/model/type-schema-generator/package.json b/generators/typescript/model/type-schema-generator/package.json index 5042bb162e0..b44d9777503 100644 --- a/generators/typescript/model/type-schema-generator/package.json +++ b/generators/typescript/model/type-schema-generator/package.json @@ -27,7 +27,7 @@ "depcheck": "depcheck" }, "dependencies": { - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/abstract-schema-generator": "workspace:*", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", diff --git a/generators/typescript/model/union-generator/package.json b/generators/typescript/model/union-generator/package.json index 5d836bdadc8..74042f0e321 100644 --- a/generators/typescript/model/union-generator/package.json +++ b/generators/typescript/model/union-generator/package.json @@ -28,7 +28,7 @@ }, "dependencies": { "@fern-api/core-utils": "workspace:*", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", "ts-morph": "^15.1.0" diff --git a/generators/typescript/model/union-generator/src/GeneratedUnionImpl.ts b/generators/typescript/model/union-generator/src/GeneratedUnionImpl.ts index 2e3de6daa38..8f02e7436c2 100644 --- a/generators/typescript/model/union-generator/src/GeneratedUnionImpl.ts +++ b/generators/typescript/model/union-generator/src/GeneratedUnionImpl.ts @@ -3,17 +3,23 @@ import { FernWriters, getTextOfTsNode, getWriterForMultiLineUnionType, - maybeAddDocs, + maybeAddDocsStructure, ObjectWriter, Reference } from "@fern-typescript/commons"; import { GeneratedUnion, ModelContext } from "@fern-typescript/contexts"; import { InterfaceDeclarationStructure, + ModuleDeclarationStructure, OptionalKind, PropertySignatureStructure, + StatementStructures, + StructureKind, ts, - VariableDeclarationKind + TypeAliasDeclarationStructure, + VariableDeclarationKind, + VariableStatementStructure, + WriterFunction } from "ts-morph"; import { KnownSingleUnionType } from "./known-single-union-type/KnownSingleUnionType"; import { ParsedSingleUnionType } from "./parsed-single-union-type/ParsedSingleUnionType"; @@ -36,6 +42,8 @@ export declare namespace GeneratedUnionImpl { includeSerdeLayer: boolean; retainOriginalCasing: boolean; noOptionalProperties: boolean; + inline: boolean; + enableInlineTypes: boolean; } } @@ -64,6 +72,8 @@ export class GeneratedUnionImpl implements Generat private retainOriginalCasing: boolean; private includeConstBuilders: boolean; private noOptionalProperties: boolean; + private inline: boolean; + private enableInlineTypes: boolean; constructor({ typeName, @@ -78,7 +88,9 @@ export class GeneratedUnionImpl implements Generat baseProperties = [], includeSerdeLayer, retainOriginalCasing, - noOptionalProperties + noOptionalProperties, + inline, + enableInlineTypes }: GeneratedUnionImpl.Init) { this.getReferenceToUnion = getReferenceToUnion; this.discriminant = discriminant; @@ -93,14 +105,35 @@ export class GeneratedUnionImpl implements Generat this.retainOriginalCasing = retainOriginalCasing; this.includeConstBuilders = includeConstBuilders; this.noOptionalProperties = noOptionalProperties; + this.inline = inline; + this.enableInlineTypes = enableInlineTypes; } - public writeToFile(context: Context): void { - this.writeTypeAlias(context); - this.writeModule(context); + public generateStatements( + context: Context + ): string | WriterFunction | (string | WriterFunction | StatementStructures)[] { + const statements: (string | WriterFunction | StatementStructures)[] = [ + this.generateTypeAlias(context), + this.generateModule(context) + ]; + if (this.includeConstBuilders) { - this.writeConst(context); + const consts = this.generateConst(context); + if (consts) { + statements.push(consts); + } } + return statements; + } + + public generateForInlineUnion(context: Context): ts.TypeNode { + return ts.factory.createParenthesizedType( + ts.factory.createUnionTypeNode( + this.getAllSingleUnionTypesForAlias().map((singleUnionType) => + singleUnionType.generateForInlineUnion(context, this) + ) + ) + ); } public getReferenceTo(context: Context): ts.TypeNode { @@ -234,8 +267,9 @@ export class GeneratedUnionImpl implements Generat * TYPE ALIAS * **************/ - private writeTypeAlias(context: Context): void { - const typeAlias = context.sourceFile.addTypeAlias({ + private generateTypeAlias(context: Context): TypeAliasDeclarationStructure { + const typeAlias: TypeAliasDeclarationStructure = { + kind: StructureKind.TypeAlias, name: this.typeName, type: getWriterForMultiLineUnionType( this.getAllSingleUnionTypesForAlias().map((singleUnionType) => ({ @@ -244,16 +278,23 @@ export class GeneratedUnionImpl implements Generat })) ), isExported: true - }); - if (this.getDocs != null) { - maybeAddDocs(typeAlias, this.getDocs(context)); - } + }; + maybeAddDocsStructure(typeAlias, this.getDocs?.(context)); + return typeAlias; } public getReferenceToSingleUnionType( singleUnionType: ParsedSingleUnionType, context: Context ): ts.TypeNode { + if (this.enableInlineTypes && this.inline) { + return ts.factory.createTypeReferenceNode( + ts.factory.createQualifiedName( + ts.factory.createIdentifier(this.typeName), + singleUnionType.getInterfaceName() + ) + ); + } return ts.factory.createTypeReferenceNode( ts.factory.createQualifiedName( this.getReferenceToUnion(context).getEntityName(), @@ -266,25 +307,29 @@ export class GeneratedUnionImpl implements Generat * MODULE * **********/ - private writeModule(context: Context): void { - const module = context.sourceFile.addModule({ + private generateModule(context: Context): ModuleDeclarationStructure { + const module: ModuleDeclarationStructure = { + kind: StructureKind.Module, name: this.typeName, isExported: true, - hasDeclareKeyword: true - }); - module.addInterfaces(this.getSingleUnionTypeInterfaces(context)); + hasDeclareKeyword: false + }; + const statements = [...this.getSingleUnionTypeInterfaces(context)]; if (this.includeUtilsOnUnionMembers) { - module.addInterface(this.getUtilsInterface(context)); + statements.push(this.getUtilsInterface(context)); } if (this.includeUtilsOnUnionMembers || this.includeConstBuilders) { - module.addInterface(this.getVisitorInterface(context)); + statements.push(this.getVisitorInterface(context)); } if (this.hasBaseInterface()) { - module.addInterface(this.getBaseInterface(context)); + statements.push(this.getBaseInterface(context)); } + module.statements = statements; + return module; } - private getSingleUnionTypeInterfaces(context: Context): OptionalKind[] { + private getSingleUnionTypeInterfaces(context: Context): StatementStructures[] { + const statements: StatementStructures[] = []; const interfaces = this.getAllSingleUnionTypesForAlias().map((singleUnionType) => singleUnionType.getInterfaceDeclaration(context, this) ); @@ -298,15 +343,24 @@ export class GeneratedUnionImpl implements Generat } } - return interfaces.map((interface_) => ({ - name: interface_.name, - extends: interface_.extends.map(getTextOfTsNode), - properties: interface_.jsonProperties - })); + for (const interface_ of interfaces) { + statements.push({ + kind: StructureKind.Interface, + name: interface_.name, + isExported: true, + extends: interface_.extends.map(getTextOfTsNode), + properties: interface_.properties + }); + if (interface_.module) { + statements.push(interface_.module); + } + } + return statements; } - private getUtilsInterface(context: Context): OptionalKind { + private getUtilsInterface(context: Context): InterfaceDeclarationStructure { return { + kind: StructureKind.Interface, name: GeneratedUnionImpl.UTILS_INTERFACE_NAME, properties: [ { @@ -317,8 +371,9 @@ export class GeneratedUnionImpl implements Generat }; } - private getBaseInterface(context: Context): OptionalKind { + private getBaseInterface(context: Context): InterfaceDeclarationStructure { return { + kind: StructureKind.Interface, name: GeneratedUnionImpl.BASE_INTERFACE_NAME, properties: this.baseProperties.map((property) => { const type = context.type.getReferenceToType(property.valueType); @@ -359,8 +414,9 @@ export class GeneratedUnionImpl implements Generat ); } - private getVisitorInterface(context: Context): OptionalKind { + private getVisitorInterface(context: Context): InterfaceDeclarationStructure { return { + kind: StructureKind.Interface, name: GeneratedUnionImpl.VISITOR_INTERFACE_NAME, typeParameters: [ { @@ -390,7 +446,7 @@ export class GeneratedUnionImpl implements Generat * CONST * *********/ - private writeConst(context: Context): void { + private generateConst(context: Context): VariableStatementStructure | undefined { const writer = FernWriters.object.writer({ asConst: true }); this.addBuilderProperties(context, writer); @@ -400,7 +456,8 @@ export class GeneratedUnionImpl implements Generat return; } - context.sourceFile.addVariableStatement({ + return { + kind: StructureKind.VariableStatement, declarationKind: VariableDeclarationKind.Const, declarations: [ { @@ -409,7 +466,7 @@ export class GeneratedUnionImpl implements Generat } ], isExported: true - }); + }; } private addBuilderProperties(context: Context, writer: ObjectWriter) { diff --git a/generators/typescript/model/union-generator/src/parsed-single-union-type/AbstractParsedSingleUnionType.ts b/generators/typescript/model/union-generator/src/parsed-single-union-type/AbstractParsedSingleUnionType.ts index a376e7ec874..45a77a93ef3 100644 --- a/generators/typescript/model/union-generator/src/parsed-single-union-type/AbstractParsedSingleUnionType.ts +++ b/generators/typescript/model/union-generator/src/parsed-single-union-type/AbstractParsedSingleUnionType.ts @@ -32,16 +32,22 @@ export abstract class AbstractParsedSingleUnionType): ts.TypeNode { + return this.singleUnionType.generateForInlineUnion(context); + } + public getBuilder(context: Context, generatedUnion: GeneratedUnionImpl): ts.ArrowFunction { const referenceToBuiltType = generatedUnion.getReferenceToSingleUnionType(this, context); diff --git a/generators/typescript/model/union-generator/src/parsed-single-union-type/ParsedSingleUnionType.ts b/generators/typescript/model/union-generator/src/parsed-single-union-type/ParsedSingleUnionType.ts index 2445a287572..bc6c380516d 100644 --- a/generators/typescript/model/union-generator/src/parsed-single-union-type/ParsedSingleUnionType.ts +++ b/generators/typescript/model/union-generator/src/parsed-single-union-type/ParsedSingleUnionType.ts @@ -1,5 +1,5 @@ import { ModelContext } from "@fern-typescript/contexts"; -import { OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; +import { ModuleDeclarationStructure, OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; import { GeneratedUnionImpl } from "../GeneratedUnionImpl"; export interface ParsedSingleUnionType { @@ -13,6 +13,7 @@ export interface ParsedSingleUnionType { context: Context, generatedUnion: GeneratedUnionImpl ): ParsedSingleUnionType.InterfaceDeclaration; + generateForInlineUnion(context: Context, generatedUnion: GeneratedUnionImpl): ts.TypeNode; getBuilder(context: Context, generatedUnion: GeneratedUnionImpl): ts.ArrowFunction; getBuilderName(): string; getBuilderArgsFromExistingValue(existingValue: ts.Expression): ts.Expression[]; @@ -29,6 +30,7 @@ export declare namespace ParsedSingleUnionType { export interface InterfaceDeclaration { name: string; extends: ts.TypeNode[]; - jsonProperties: OptionalKind[]; + properties: OptionalKind[]; + module: ModuleDeclarationStructure | undefined; } } diff --git a/generators/typescript/model/union-generator/src/single-union-type-generator/SingleUnionTypeGenerator.ts b/generators/typescript/model/union-generator/src/single-union-type-generator/SingleUnionTypeGenerator.ts index feacc726caf..94c17b8ebbb 100644 --- a/generators/typescript/model/union-generator/src/single-union-type-generator/SingleUnionTypeGenerator.ts +++ b/generators/typescript/model/union-generator/src/single-union-type-generator/SingleUnionTypeGenerator.ts @@ -1,6 +1,9 @@ -import { OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; +import { ModuleDeclarationStructure, OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; export interface SingleUnionTypeGenerator { + generateForInlineUnion(context: Context): ts.TypeNode; + getDiscriminantPropertiesForInterface(context: Context): OptionalKind[]; + generateModule(context: Context): ModuleDeclarationStructure | undefined; getExtendsForInterface(context: Context): ts.TypeNode[]; getNonDiscriminantPropertiesForInterface(context: Context): OptionalKind[]; getVisitorArguments(args: { localReferenceToUnionValue: ts.Expression }): ts.Expression[]; diff --git a/generators/typescript/model/union-generator/src/single-union-type-generator/common/NoPropertiesSingleUnionTypeGenerator.ts b/generators/typescript/model/union-generator/src/single-union-type-generator/common/NoPropertiesSingleUnionTypeGenerator.ts index 57289922414..4c54e02ad50 100644 --- a/generators/typescript/model/union-generator/src/single-union-type-generator/common/NoPropertiesSingleUnionTypeGenerator.ts +++ b/generators/typescript/model/union-generator/src/single-union-type-generator/common/NoPropertiesSingleUnionTypeGenerator.ts @@ -1,11 +1,23 @@ -import { OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; +import { ModuleDeclarationStructure, OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; import { SingleUnionTypeGenerator } from "../SingleUnionTypeGenerator"; export class NoPropertiesSingleUnionTypeGenerator implements SingleUnionTypeGenerator { + public generateForInlineUnion(context: Context): ts.TypeNode { + return ts.factory.createTypeLiteralNode([]); + } + public getExtendsForInterface(): ts.TypeNode[] { return []; } + public getDiscriminantPropertiesForInterface(context: Context): OptionalKind[] { + return []; + } + + public generateModule(context: Context): ModuleDeclarationStructure | undefined { + return undefined; + } + public getNonDiscriminantPropertiesForInterface(): OptionalKind[] { return []; } diff --git a/generators/typescript/model/union-generator/src/single-union-type-generator/common/SinglePropertySingleUnionTypeGenerator.ts b/generators/typescript/model/union-generator/src/single-union-type-generator/common/SinglePropertySingleUnionTypeGenerator.ts index ebe4c29e57a..2ed14dec8e2 100644 --- a/generators/typescript/model/union-generator/src/single-union-type-generator/common/SinglePropertySingleUnionTypeGenerator.ts +++ b/generators/typescript/model/union-generator/src/single-union-type-generator/common/SinglePropertySingleUnionTypeGenerator.ts @@ -1,36 +1,67 @@ +import { assertNever } from "@fern-api/core-utils"; +import { NamedType, ObjectProperty, SingleUnionTypeProperty, TypeReference } from "@fern-fern/ir-sdk/api"; import { getTextOfTsNode, TypeReferenceNode } from "@fern-typescript/commons"; -import { OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; +import { ModelContext } from "@fern-typescript/contexts"; +import { ModuleDeclarationStructure, OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; import { SingleUnionTypeGenerator } from "../SingleUnionTypeGenerator"; export declare namespace SinglePropertySingleUnionTypeGenerator { export interface Init { propertyName: string; getReferenceToPropertyType: (context: Context) => TypeReferenceNode; + getReferenceToPropertyTypeForInlineUnion: (context: Context) => TypeReferenceNode; noOptionalProperties: boolean; + enableInlineTypes: boolean; } } -export class SinglePropertySingleUnionTypeGenerator implements SingleUnionTypeGenerator { +export class SinglePropertySingleUnionTypeGenerator + implements SingleUnionTypeGenerator +{ private static BUILDER_PARAMETER_NAME = "value"; private propertyName: string; private getReferenceToPropertyType: (context: Context) => TypeReferenceNode; + private getReferenceToPropertyTypeForInlineUnion: (context: Context) => TypeReferenceNode; private noOptionalProperties: boolean; constructor({ propertyName, getReferenceToPropertyType, + getReferenceToPropertyTypeForInlineUnion, noOptionalProperties }: SinglePropertySingleUnionTypeGenerator.Init) { this.propertyName = propertyName; this.getReferenceToPropertyType = getReferenceToPropertyType; + this.getReferenceToPropertyTypeForInlineUnion = getReferenceToPropertyTypeForInlineUnion; this.noOptionalProperties = noOptionalProperties; } + public generateForInlineUnion(context: Context): ts.TypeNode { + const typeReference = this.getReferenceToPropertyTypeForInlineUnion(context); + const hasOptionalToken = !this.noOptionalProperties && typeReference.isOptional; + return ts.factory.createTypeLiteralNode([ + ts.factory.createPropertySignature( + undefined, + this.propertyName, + hasOptionalToken ? ts.factory.createToken(ts.SyntaxKind.QuestionToken) : undefined, + this.noOptionalProperties ? typeReference.typeNode : typeReference.typeNodeWithoutUndefined + ) + ]); + } + public getExtendsForInterface(): ts.TypeNode[] { return []; } + public getDiscriminantPropertiesForInterface(context: Context): OptionalKind[] { + return []; + } + + public generateModule(context: Context): ModuleDeclarationStructure | undefined { + return undefined; + } + public getNonDiscriminantPropertiesForInterface(context: Context): OptionalKind[] { const type = this.getReferenceToPropertyType(context); return [ diff --git a/generators/typescript/model/union-schema-generator/package.json b/generators/typescript/model/union-schema-generator/package.json index 74dfc158309..ee09125bf07 100644 --- a/generators/typescript/model/union-schema-generator/package.json +++ b/generators/typescript/model/union-schema-generator/package.json @@ -27,7 +27,7 @@ "depcheck": "depcheck" }, "dependencies": { - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/abstract-schema-generator": "workspace:*", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", diff --git a/generators/typescript/sdk/CHANGELOG.md b/generators/typescript/sdk/CHANGELOG.md index 7f363a08e37..5b7cc0f5cd1 100644 --- a/generators/typescript/sdk/CHANGELOG.md +++ b/generators/typescript/sdk/CHANGELOG.md @@ -5,15 +5,73 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [0.43.0] - 2024-12-11 + +- Feature: Generate inline types for inline schemas by setting `enableInlineTypes` to `true` in the generator config. + When enabled, the inline schemas will be generated as nested types in TypeScript. + This results in cleaner type names and a more intuitive developer experience. + + Before: + + ```ts + // MyRootType.ts + import * as MySdk from "..."; + + export interface MyRootType { + foo: MySdk.MyRootTypeFoo; + } + + // MyRootTypeFoo.ts + import * as MySdk from "..."; + + export interface MyRootTypeFoo { + bar: MySdk.MyRootTypeFooBar; + } + + // MyRootTypeFooBar.ts + import * as MySdk from "..."; + + export interface MyRootTypeFooBar {} + ``` + + After: + + ```ts + // MyRootType.ts + import * as MySdk from "..."; + + export interface MyRootType { + foo: MyRootType.Foo; + } + + export namespace MyRootType { + export interface Foo { + bar: Foo.Bar; + } + + export namespace Foo { + export interface Bar {} + } + } + ``` + + Now users can get the deep nested `Bar` type as follows: + + ```ts + import { MyRootType } from MySdk; + + const bar: MyRootType.Foo.Bar = {}; + ``` + ## [0.42.7] - 2024-12-03 -- Feature: Support `additionalProperties` in OpenAPI or `extra-properties` in the Fern Defnition. Now - an object that has additionalProperties marked as true will generate the following interface: +- Feature: Support `additionalProperties` in OpenAPI or `extra-properties` in the Fern Defnition. Now + an object that has additionalProperties marked as true will generate the following interface: ```ts interface User { - propertyOne: string - [key: string]: any + propertyOne: string; + [key: string]: any; } ``` diff --git a/generators/typescript/sdk/VERSION b/generators/typescript/sdk/VERSION index 6028e3fe54d..8298bb08b2d 100644 --- a/generators/typescript/sdk/VERSION +++ b/generators/typescript/sdk/VERSION @@ -1 +1 @@ -0.42.7 +0.43.0 diff --git a/generators/typescript/sdk/cli/package.json b/generators/typescript/sdk/cli/package.json index 22ae8a4290b..f730baa59db 100644 --- a/generators/typescript/sdk/cli/package.json +++ b/generators/typescript/sdk/cli/package.json @@ -35,7 +35,7 @@ "devDependencies": { "@fern-api/fs-utils": "workspace:*", "@fern-api/base-generator": "workspace:*", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/abstract-generator-cli": "workspace:*", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", diff --git a/generators/typescript/sdk/cli/src/SdkGeneratorCli.ts b/generators/typescript/sdk/cli/src/SdkGeneratorCli.ts index 6d9c4510e45..1356425e8df 100644 --- a/generators/typescript/sdk/cli/src/SdkGeneratorCli.ts +++ b/generators/typescript/sdk/cli/src/SdkGeneratorCli.ts @@ -54,6 +54,7 @@ export class SdkGeneratorCli extends AbstractGeneratorCli { retainOriginalCasing: parsed?.retainOriginalCasing ?? false, allowExtraFields: parsed?.allowExtraFields ?? false, inlineFileProperties: parsed?.inlineFileProperties ?? false, + enableInlineTypes: parsed?.enableInlineTypes ?? false, packageJson: parsed?.packageJson, publishToJsr: parsed?.publishToJsr ?? false, omitUndefined: parsed?.omitUndefined ?? false, @@ -135,7 +136,8 @@ export class SdkGeneratorCli extends AbstractGeneratorCli { packageJson: customConfig.packageJson, outputJsr: customConfig.publishToJsr ?? false, omitUndefined: customConfig.omitUndefined ?? false, - useBigInt: customConfig.useBigInt ?? false + useBigInt: customConfig.useBigInt ?? false, + enableInlineTypes: customConfig.enableInlineTypes ?? false } }); const typescriptProject = await sdkGenerator.generate(); diff --git a/generators/typescript/sdk/cli/src/custom-config/SdkCustomConfig.ts b/generators/typescript/sdk/cli/src/custom-config/SdkCustomConfig.ts index 0752a2cc3a8..81d6e6faed5 100644 --- a/generators/typescript/sdk/cli/src/custom-config/SdkCustomConfig.ts +++ b/generators/typescript/sdk/cli/src/custom-config/SdkCustomConfig.ts @@ -28,6 +28,7 @@ export interface SdkCustomConfig { retainOriginalCasing: boolean | undefined; allowExtraFields: boolean | undefined; inlineFileProperties: boolean | undefined; + enableInlineTypes: boolean | undefined; packageJson: Record | undefined; publishToJsr: boolean | undefined; omitUndefined: boolean | undefined; diff --git a/generators/typescript/sdk/cli/src/custom-config/schema/SdkCustomConfigSchema.ts b/generators/typescript/sdk/cli/src/custom-config/schema/SdkCustomConfigSchema.ts index 0f02543b4cf..21915edec84 100644 --- a/generators/typescript/sdk/cli/src/custom-config/schema/SdkCustomConfigSchema.ts +++ b/generators/typescript/sdk/cli/src/custom-config/schema/SdkCustomConfigSchema.ts @@ -33,6 +33,7 @@ export const SdkCustomConfigSchema = z.strictObject({ retainOriginalCasing: z.optional(z.boolean()), allowExtraFields: z.optional(z.boolean()), inlineFileProperties: z.optional(z.boolean()), + enableInlineTypes: z.optional(z.boolean()), generateWireTests: z.optional(z.boolean()), noScripts: z.optional(z.boolean()), diff --git a/generators/typescript/sdk/client-class-generator/package.json b/generators/typescript/sdk/client-class-generator/package.json index b3c5d25577d..52afab49d26 100644 --- a/generators/typescript/sdk/client-class-generator/package.json +++ b/generators/typescript/sdk/client-class-generator/package.json @@ -28,7 +28,7 @@ }, "dependencies": { "@fern-api/core-utils": "workspace:*", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", "@fern-typescript/resolvers": "workspace:*", diff --git a/generators/typescript/sdk/client-class-generator/src/GeneratedSdkClientClassImpl.ts b/generators/typescript/sdk/client-class-generator/src/GeneratedSdkClientClassImpl.ts index 06e33d31718..22923cff469 100644 --- a/generators/typescript/sdk/client-class-generator/src/GeneratedSdkClientClassImpl.ts +++ b/generators/typescript/sdk/client-class-generator/src/GeneratedSdkClientClassImpl.ts @@ -1,4 +1,4 @@ -import { assertNever } from "@fern-api/core-utils"; +import { assertNever, SetRequired } from "@fern-api/core-utils"; import { AuthScheme, BasicAuthScheme, @@ -19,13 +19,24 @@ import { getTextOfTsNode, ImportsManager, JavaScriptRuntime, - maybeAddDocs, + maybeAddDocsStructure, NpmPackage, PackageId } from "@fern-typescript/commons"; import { GeneratedEndpointImplementation, GeneratedSdkClientClass, SdkContext } from "@fern-typescript/contexts"; import { ErrorResolver, PackageResolver } from "@fern-typescript/resolvers"; -import { InterfaceDeclarationStructure, OptionalKind, PropertySignatureStructure, Scope, ts } from "ts-morph"; +import { + ClassDeclarationStructure, + InterfaceDeclarationStructure, + MethodDeclarationStructure, + ModuleDeclarationStructure, + OptionalKind, + PropertyDeclarationStructure, + PropertySignatureStructure, + Scope, + StructureKind, + ts +} from "ts-morph"; import { code } from "ts-poet"; import { GeneratedBytesEndpointRequest } from "./endpoint-request/GeneratedBytesEndpointRequest"; import { GeneratedDefaultEndpointRequest } from "./endpoint-request/GeneratedDefaultEndpointRequest"; @@ -425,23 +436,34 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { } public writeToFile(context: SdkContext): void { - const serviceModule = context.sourceFile.addModule({ + const serviceModule: ModuleDeclarationStructure = { + kind: StructureKind.Module, name: this.serviceClassName, isExported: true, hasDeclareKeyword: true - }); + }; - const optionsInterface = serviceModule.addInterface(this.generateOptionsInterface(context)); - serviceModule.addInterface(this.generateRequestOptionsInterface(context)); + const optionsInterface = this.generateOptionsInterface(context); + serviceModule.statements = [optionsInterface, this.generateRequestOptionsInterface(context)]; + context.sourceFile.addModule(serviceModule); - const serviceClass = context.sourceFile.addClass({ + const serviceClass: SetRequired< + ClassDeclarationStructure, + "properties" | "ctors" | "methods" | "getAccessors" + > = { + kind: StructureKind.Class, name: this.serviceClassName, - isExported: true - }); - maybeAddDocs(serviceClass, this.package_.docs); + isExported: true, + properties: [], + getAccessors: [], + ctors: [], + methods: [] + }; + maybeAddDocsStructure(serviceClass, this.package_.docs); if (this.isRoot && context.generateOAuthClients) { - serviceClass.addProperty({ + serviceClass.properties.push({ + kind: StructureKind.Property, name: OAuthTokenProviderGenerator.OAUTH_TOKEN_PROVIDER_PROPERTY_NAME, type: getTextOfTsNode(context.coreUtilities.auth.OAuthTokenProvider._getReferenceToType()), scope: Scope.Private, @@ -509,8 +531,8 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { type: getTextOfTsNode( ts.factory.createTypeReferenceNode( ts.factory.createQualifiedName( - ts.factory.createIdentifier(serviceModule.getName()), - ts.factory.createIdentifier(optionsInterface.getName()) + ts.factory.createIdentifier(serviceModule.name), + ts.factory.createIdentifier(optionsInterface.name) ) ) ) @@ -567,12 +589,12 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { }), }); `; - serviceClass.addConstructor({ + serviceClass.ctors.push({ parameters, statements: statements.toString({ dprintOptions: { indentWidth: 4 } }) }); } else { - serviceClass.addConstructor({ + serviceClass.ctors.push({ parameters: [ { name: GeneratedSdkClientClassImpl.OPTIONS_PRIVATE_MEMBER, @@ -581,12 +603,12 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { type: getTextOfTsNode( ts.factory.createTypeReferenceNode( ts.factory.createQualifiedName( - ts.factory.createIdentifier(serviceModule.getName()), - ts.factory.createIdentifier(optionsInterface.getName()) + ts.factory.createIdentifier(serviceModule.name), + ts.factory.createIdentifier(optionsInterface.name) ) ) ), - initializer: optionsInterface.getProperties().every((property) => property.hasQuestionToken()) + initializer: optionsInterface.properties?.every((property) => property.hasQuestionToken) ? "{}" : undefined } @@ -608,7 +630,8 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { const statements = endpoint.getStatements(context); // const returnsAPIPromise = !context.neverThrowErrors && !endpoint.isPaginated(context); - const method = serviceClass.addMethod({ + const method: MethodDeclarationStructure = { + kind: StructureKind.Method, name: endpoint.endpoint.name.camelCase.unsafeName, parameters: signature.parameters, returnType: getTextOfTsNode( @@ -624,15 +647,16 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { ts.factory.createTypeReferenceNode("Promise", [overload.returnTypeWithoutPromise]) ) })) - }); + }; + serviceClass.methods.push(method); if (overloads.length === 0) { - maybeAddDocs(method, docs); + maybeAddDocsStructure(method, docs); } } if (isIdempotent) { - serviceModule.addInterface(this.generateIdempotentRequestOptionsInterface(context)); + serviceModule.statements.push(this.generateIdempotentRequestOptionsInterface(context)); } for (const wrappedService of this.generatedWrappedServices) { @@ -657,7 +681,7 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { ts.factory.createKeywordTypeNode(ts.SyntaxKind.StringKeyword) ]); - serviceClass.addMethod({ + serviceClass.methods.push({ scope: Scope.Protected, isAsync: true, name: GeneratedSdkClientClassImpl.AUTHORIZATION_HEADER_HELPER_METHOD_NAME, @@ -667,13 +691,15 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { } if (this.shouldGenerateCustomAuthorizationHeaderHelperMethod()) { - serviceClass.addMethod({ + serviceClass.methods.push({ scope: Scope.Protected, isAsync: true, name: GeneratedSdkClientClassImpl.CUSTOM_AUTHORIZATION_HEADER_HELPER_METHOD_NAME, statements: this.getCustomAuthorizationHeaderStatements(context).map(getTextOfTsNode) }); } + + context.sourceFile.addClass(serviceClass); } private shouldGenerateAuthorizationHeaderHelperMethod(): boolean { @@ -932,8 +958,9 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { : `${this.serviceClassName}.${GeneratedSdkClientClassImpl.REQUEST_OPTIONS_INTERFACE_NAME}`; } - private generateRequestOptionsInterface(context: SdkContext): OptionalKind { - const requestOptions = { + private generateRequestOptionsInterface(context: SdkContext): InterfaceDeclarationStructure { + const requestOptions: SetRequired = { + kind: StructureKind.Interface, name: GeneratedSdkClientClassImpl.REQUEST_OPTIONS_INTERFACE_NAME, properties: [ { @@ -988,9 +1015,7 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { * IDEMPOTENT REQUEST OPTIONS * ******************************/ - private generateIdempotentRequestOptionsInterface( - context: SdkContext - ): OptionalKind { + private generateIdempotentRequestOptionsInterface(context: SdkContext): InterfaceDeclarationStructure { const properties: OptionalKind[] = []; for (const header of this.intermediateRepresentation.idempotencyHeaders) { if (!isLiteralHeader(header, context)) { @@ -1003,6 +1028,7 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { } } return { + kind: StructureKind.Interface, name: GeneratedSdkClientClassImpl.IDEMPOTENT_REQUEST_OPTIONS_INTERFACE_NAME, extends: [GeneratedSdkClientClassImpl.REQUEST_OPTIONS_INTERFACE_NAME], properties @@ -1107,7 +1133,7 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { return properties; } - private generateOptionsInterface(context: SdkContext): OptionalKind { + private generateOptionsInterface(context: SdkContext): InterfaceDeclarationStructure { const properties: OptionalKind[] = []; if (!this.requireDefaultEnvironment) { @@ -1304,6 +1330,7 @@ export class GeneratedSdkClientClassImpl implements GeneratedSdkClientClass { } return { + kind: StructureKind.Interface, name: GeneratedSdkClientClassImpl.OPTIONS_INTERFACE_NAME, properties }; diff --git a/generators/typescript/sdk/client-class-generator/src/GeneratedWrappedService.ts b/generators/typescript/sdk/client-class-generator/src/GeneratedWrappedService.ts index a8d49851de1..3b75ce4aa79 100644 --- a/generators/typescript/sdk/client-class-generator/src/GeneratedWrappedService.ts +++ b/generators/typescript/sdk/client-class-generator/src/GeneratedWrappedService.ts @@ -1,7 +1,8 @@ import { Subpackage, SubpackageId } from "@fern-fern/ir-sdk/api"; import { getTextOfTsNode, Reference } from "@fern-typescript/commons"; +import { SetRequired } from "@fern-api/core-utils"; import { SdkContext } from "@fern-typescript/contexts"; -import { ClassDeclaration, Scope, ts } from "ts-morph"; +import { ClassDeclarationStructure, Scope, ts } from "ts-morph"; import { GeneratedSdkClientClassImpl } from "./GeneratedSdkClientClassImpl"; import { OAuthTokenProviderGenerator } from "./oauth-generator/OAuthTokenProviderGenerator"; @@ -30,7 +31,7 @@ export class GeneratedWrappedService { context }: { isRoot: boolean; - class_: ClassDeclaration; + class_: SetRequired; context: SdkContext; }): void { const referenceToWrapped = this.getReferenceToWrappedService(class_, context); @@ -39,7 +40,7 @@ export class GeneratedWrappedService { subpackageId: this.wrappedSubpackageId }); - class_.addProperty({ + class_.properties.push({ name: this.getCachedMemberName(), scope: Scope.Protected, type: getTextOfTsNode( @@ -51,7 +52,7 @@ export class GeneratedWrappedService { }); if (isRoot && context.generateOAuthClients) { - class_.addGetAccessor({ + class_.getAccessors.push({ name: this.getGetterName(), returnType: getTextOfTsNode(referenceToWrapped.getTypeNode()), scope: Scope.Public, @@ -112,7 +113,7 @@ export class GeneratedWrappedService { }); return; } - class_.addGetAccessor({ + class_.getAccessors.push({ name: this.getGetterName(), returnType: getTextOfTsNode(referenceToWrapped.getTypeNode()), scope: Scope.Public, @@ -151,7 +152,10 @@ export class GeneratedWrappedService { return lastFernFilepathPart.camelCase.unsafeName; } - private getReferenceToWrappedService(serviceClass: ClassDeclaration, context: SdkContext): Reference { + private getReferenceToWrappedService( + serviceClass: SetRequired, + context: SdkContext + ): Reference { const reference = context.sdkClientClass.getReferenceToClientClass({ isRoot: false, subpackageId: this.wrappedSubpackageId @@ -163,7 +167,7 @@ export class GeneratedWrappedService { }) ); - if (wrappedServiceClassName !== serviceClass.getName()) { + if (wrappedServiceClassName !== serviceClass.name) { return reference; } else { return context.sdkClientClass.getReferenceToClientClass( diff --git a/generators/typescript/sdk/endpoint-error-union-generator/package.json b/generators/typescript/sdk/endpoint-error-union-generator/package.json index 78c69f89171..75a75dccf9e 100644 --- a/generators/typescript/sdk/endpoint-error-union-generator/package.json +++ b/generators/typescript/sdk/endpoint-error-union-generator/package.json @@ -27,7 +27,7 @@ "depcheck": "depcheck" }, "dependencies": { - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", "@fern-typescript/resolvers": "workspace:*", diff --git a/generators/typescript/sdk/endpoint-error-union-generator/src/EndpointErrorUnionGenerator.ts b/generators/typescript/sdk/endpoint-error-union-generator/src/EndpointErrorUnionGenerator.ts index 33ffffc072a..7f20e8286d9 100644 --- a/generators/typescript/sdk/endpoint-error-union-generator/src/EndpointErrorUnionGenerator.ts +++ b/generators/typescript/sdk/endpoint-error-union-generator/src/EndpointErrorUnionGenerator.ts @@ -11,6 +11,7 @@ export declare namespace EndpointErrorUnionGenerator { includeSerdeLayer: boolean; retainOriginalCasing: boolean; noOptionalProperties: boolean; + enableInlineTypes: boolean; } export namespace generateEndpointErrorUnion { @@ -27,19 +28,22 @@ export class EndpointErrorUnionGenerator { private includeSerdeLayer: boolean; private retainOriginalCasing: boolean; private noOptionalProperties: boolean; + private enableInlineTypes: boolean; constructor({ intermediateRepresentation, errorResolver, includeSerdeLayer, retainOriginalCasing, - noOptionalProperties + noOptionalProperties, + enableInlineTypes }: EndpointErrorUnionGenerator.Init) { this.intermediateRepresentation = intermediateRepresentation; this.errorResolver = errorResolver; this.includeSerdeLayer = includeSerdeLayer; this.retainOriginalCasing = retainOriginalCasing; this.noOptionalProperties = noOptionalProperties; + this.enableInlineTypes = enableInlineTypes; } public generateEndpointErrorUnion({ @@ -53,7 +57,8 @@ export class EndpointErrorUnionGenerator { errorDiscriminationStrategy: this.intermediateRepresentation.errorDiscriminationStrategy, includeSerdeLayer: this.includeSerdeLayer, retainOriginalCasing: this.retainOriginalCasing, - noOptionalProperties: this.noOptionalProperties + noOptionalProperties: this.noOptionalProperties, + enableInlineTypes: this.enableInlineTypes }); } } diff --git a/generators/typescript/sdk/endpoint-error-union-generator/src/GeneratedEndpointErrorUnionImpl.ts b/generators/typescript/sdk/endpoint-error-union-generator/src/GeneratedEndpointErrorUnionImpl.ts index aebb8f7d7b7..b8b173c9415 100644 --- a/generators/typescript/sdk/endpoint-error-union-generator/src/GeneratedEndpointErrorUnionImpl.ts +++ b/generators/typescript/sdk/endpoint-error-union-generator/src/GeneratedEndpointErrorUnionImpl.ts @@ -16,6 +16,7 @@ export declare namespace GeneratedEndpointErrorUnionImpl { includeSerdeLayer: boolean; noOptionalProperties: boolean; retainOriginalCasing: boolean; + enableInlineTypes: boolean; } } @@ -33,7 +34,8 @@ export class GeneratedEndpointErrorUnionImpl implements GeneratedEndpointErrorUn errorDiscriminationStrategy, includeSerdeLayer, noOptionalProperties, - retainOriginalCasing + retainOriginalCasing, + enableInlineTypes }: GeneratedEndpointErrorUnionImpl.Init) { this.endpoint = endpoint; @@ -57,7 +59,8 @@ export class GeneratedEndpointErrorUnionImpl implements GeneratedEndpointErrorUn errorDiscriminationStrategy, includeUtilsOnUnionMembers, noOptionalProperties, - retainOriginalCasing + retainOriginalCasing, + enableInlineTypes }) ), getReferenceToUnion: (context) => @@ -73,7 +76,10 @@ export class GeneratedEndpointErrorUnionImpl implements GeneratedEndpointErrorUn includeOtherInUnionTypes: true, includeSerdeLayer, noOptionalProperties, - retainOriginalCasing + retainOriginalCasing, + enableInlineTypes, + // generate separate root types for errors in union + inline: false }); } @@ -95,7 +101,7 @@ export class GeneratedEndpointErrorUnionImpl implements GeneratedEndpointErrorUn } public writeToFile(context: SdkContext): void { - this.errorUnion.writeToFile(context); + context.sourceFile.addStatements(this.errorUnion.generateStatements(context)); } public getErrorUnion(): GeneratedUnion { diff --git a/generators/typescript/sdk/endpoint-error-union-generator/src/error/ParsedSingleUnionTypeForError.ts b/generators/typescript/sdk/endpoint-error-union-generator/src/error/ParsedSingleUnionTypeForError.ts index eebf8449cad..c1a23e6cc40 100644 --- a/generators/typescript/sdk/endpoint-error-union-generator/src/error/ParsedSingleUnionTypeForError.ts +++ b/generators/typescript/sdk/endpoint-error-union-generator/src/error/ParsedSingleUnionTypeForError.ts @@ -16,6 +16,7 @@ export declare namespace ParsedSingleUnionTypeForError { includeUtilsOnUnionMembers: boolean; noOptionalProperties: boolean; retainOriginalCasing: boolean; + enableInlineTypes: boolean; } } @@ -31,7 +32,8 @@ export class ParsedSingleUnionTypeForError extends AbstractKnownSingleUnionType< errorResolver, includeUtilsOnUnionMembers, noOptionalProperties, - retainOriginalCasing + retainOriginalCasing, + enableInlineTypes }: ParsedSingleUnionTypeForError.Init) { const errorDeclaration = errorResolver.getErrorDeclarationFromName(error.error); super({ @@ -39,7 +41,8 @@ export class ParsedSingleUnionTypeForError extends AbstractKnownSingleUnionType< errorDiscriminationStrategy, errorDeclaration, noOptionalProperties, - retainOriginalCasing + retainOriginalCasing, + enableInlineTypes }), includeUtilsOnUnionMembers }); @@ -87,12 +90,14 @@ function getSingleUnionTypeGenerator({ errorDiscriminationStrategy, errorDeclaration, noOptionalProperties, - retainOriginalCasing + retainOriginalCasing, + enableInlineTypes }: { errorDiscriminationStrategy: ErrorDiscriminationStrategy; errorDeclaration: ErrorDeclaration; noOptionalProperties: boolean; retainOriginalCasing: boolean; + enableInlineTypes: boolean; }): SingleUnionTypeGenerator { if (errorDeclaration.type == null) { return new NoPropertiesSingleUnionTypeGenerator(); @@ -111,6 +116,8 @@ function getSingleUnionTypeGenerator({ return new SinglePropertySingleUnionTypeGenerator({ propertyName, getReferenceToPropertyType: (context) => context.type.getReferenceToType(type), - noOptionalProperties + getReferenceToPropertyTypeForInlineUnion: (context) => context.type.getReferenceToTypeForInlineUnion(type), + noOptionalProperties, + enableInlineTypes }); } diff --git a/generators/typescript/sdk/endpoint-error-union-generator/src/error/UnknownErrorSingleUnionTypeGenerator.ts b/generators/typescript/sdk/endpoint-error-union-generator/src/error/UnknownErrorSingleUnionTypeGenerator.ts index c71c1cba103..9e5ccc5538d 100644 --- a/generators/typescript/sdk/endpoint-error-union-generator/src/error/UnknownErrorSingleUnionTypeGenerator.ts +++ b/generators/typescript/sdk/endpoint-error-union-generator/src/error/UnknownErrorSingleUnionTypeGenerator.ts @@ -1,7 +1,7 @@ import { getTextOfTsNode } from "@fern-typescript/commons"; import { SdkContext } from "@fern-typescript/contexts"; import { SingleUnionTypeGenerator } from "@fern-typescript/union-generator"; -import { OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; +import { ModuleDeclarationStructure, OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; export declare namespace UnknownErrorSingleUnionTypeGenerator { export interface Init { @@ -19,10 +19,29 @@ export class UnknownErrorSingleUnionTypeGenerator implements SingleUnionTypeGene this.discriminant = discriminant; } + public generateForInlineUnion(context: SdkContext): ts.TypeNode { + return ts.factory.createTypeLiteralNode([ + ts.factory.createPropertySignature( + undefined, + UnknownErrorSingleUnionTypeGenerator.CONTENT_PROPERTY_NAME, + undefined, + context.coreUtilities.fetcher.Fetcher.Error._getReferenceToType() + ) + ]); + } + public getExtendsForInterface(): ts.TypeNode[] { return []; } + public getDiscriminantPropertiesForInterface(): OptionalKind[] { + return []; + } + + public generateModule(): ModuleDeclarationStructure | undefined { + return undefined; + } + public getNonDiscriminantPropertiesForInterface(context: SdkContext): OptionalKind[] { return [ { diff --git a/generators/typescript/sdk/environments-generator/package.json b/generators/typescript/sdk/environments-generator/package.json index eab64d97613..658ecfc5e0a 100644 --- a/generators/typescript/sdk/environments-generator/package.json +++ b/generators/typescript/sdk/environments-generator/package.json @@ -27,7 +27,7 @@ "depcheck": "depcheck" }, "dependencies": { - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", "ts-morph": "^15.1.0" diff --git a/generators/typescript/sdk/generator/package.json b/generators/typescript/sdk/generator/package.json index 9fa358cc545..99c86f0016d 100644 --- a/generators/typescript/sdk/generator/package.json +++ b/generators/typescript/sdk/generator/package.json @@ -34,7 +34,7 @@ "@fern-api/logger": "workspace:*", "@fern-fern/generator-cli-sdk": "0.0.17", "@fern-fern/generator-exec-sdk": "^0.0.898", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-fern/snippet-sdk": "^0.0.5526", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", diff --git a/generators/typescript/sdk/generator/src/SdkGenerator.ts b/generators/typescript/sdk/generator/src/SdkGenerator.ts index bed1ab1ff30..2a2efd7df7a 100644 --- a/generators/typescript/sdk/generator/src/SdkGenerator.ts +++ b/generators/typescript/sdk/generator/src/SdkGenerator.ts @@ -7,7 +7,9 @@ import { HttpEndpoint, HttpService, IntermediateRepresentation, - OAuthScheme + OAuthScheme, + TypeDeclaration, + TypeId } from "@fern-fern/ir-sdk/api"; import { FdrSnippetTemplate, FdrSnippetTemplateClient, FdrSnippetTemplateEnvironment } from "@fern-fern/snippet-sdk"; import { @@ -119,6 +121,7 @@ export declare namespace SdkGenerator { allowExtraFields: boolean; writeUnitTests: boolean; inlineFileProperties: boolean; + enableInlineTypes: boolean; omitUndefined: boolean; executionEnvironment: "local" | "dev" | "prod"; organization: string; @@ -298,7 +301,8 @@ export class SdkGenerator { includeOtherInUnionTypes: config.includeOtherInUnionTypes, includeSerdeLayer: config.includeSerdeLayer, noOptionalProperties: config.noOptionalProperties, - retainOriginalCasing: config.retainOriginalCasing + retainOriginalCasing: config.retainOriginalCasing, + enableInlineTypes: config.enableInlineTypes }); this.typeSchemaGenerator = new TypeSchemaGenerator({ includeUtilsOnUnionMembers: config.includeUtilsOnUnionMembers, @@ -317,7 +321,8 @@ export class SdkGenerator { intermediateRepresentation, includeSerdeLayer: config.includeSerdeLayer, retainOriginalCasing: config.retainOriginalCasing, - noOptionalProperties: config.noOptionalProperties + noOptionalProperties: config.noOptionalProperties, + enableInlineTypes: config.enableInlineTypes }); this.sdkEndpointTypeSchemasGenerator = new SdkEndpointTypeSchemasGenerator({ errorResolver: this.errorResolver, @@ -540,6 +545,17 @@ export class SdkGenerator { }); } + private getTypesToGenerate(): Record { + if (this.config.enableInlineTypes) { + return Object.fromEntries( + Object.entries(this.intermediateRepresentation.types).filter( + ([_, typeDeclaration]) => !typeDeclaration.inline + ) + ); + } + return this.intermediateRepresentation.types; + } + public async copyCoreUtilities({ pathToSrc, pathToRoot @@ -551,7 +567,7 @@ export class SdkGenerator { } private generateTypeDeclarations() { - for (const typeDeclaration of Object.values(this.intermediateRepresentation.types)) { + for (const typeDeclaration of Object.values(this.getTypesToGenerate())) { this.withSourceFile({ filepath: this.typeDeclarationReferencer.getExportedFilepath(typeDeclaration.name), run: ({ sourceFile, importsManager }) => { @@ -564,7 +580,7 @@ export class SdkGenerator { private generateTypeSchemas(): { generated: boolean } { let generated = false; - for (const typeDeclaration of Object.values(this.intermediateRepresentation.types)) { + for (const typeDeclaration of Object.values(this.getTypesToGenerate())) { this.withSourceFile({ filepath: this.typeSchemaDeclarationReferencer.getExportedFilepath(typeDeclaration.name), run: ({ sourceFile, importsManager }) => { @@ -1281,6 +1297,7 @@ export class SdkGenerator { retainOriginalCasing: this.config.retainOriginalCasing, targetRuntime: this.config.targetRuntime, inlineFileProperties: this.config.inlineFileProperties, + enableInlineTypes: this.config.enableInlineTypes, generateOAuthClients: this.generateOAuthClients, omitUndefined: this.config.omitUndefined, useBigInt: this.config.useBigInt, diff --git a/generators/typescript/sdk/generator/src/contexts/SdkContextImpl.ts b/generators/typescript/sdk/generator/src/contexts/SdkContextImpl.ts index 023d2072cc1..7fb00b977a5 100644 --- a/generators/typescript/sdk/generator/src/contexts/SdkContextImpl.ts +++ b/generators/typescript/sdk/generator/src/contexts/SdkContextImpl.ts @@ -111,6 +111,7 @@ export declare namespace SdkContextImpl { retainOriginalCasing: boolean; generateOAuthClients: boolean; inlineFileProperties: boolean; + enableInlineTypes: boolean; omitUndefined: boolean; neverThrowErrors: boolean; useBigInt: boolean; @@ -203,7 +204,8 @@ export class SdkContextImpl implements SdkContext { generateOAuthClients, omitUndefined, useBigInt, - neverThrowErrors + neverThrowErrors, + enableInlineTypes }: SdkContextImpl.Init) { this.logger = logger; this.ir = ir; @@ -250,7 +252,9 @@ export class SdkContextImpl implements SdkContext { treatUnknownAsAny, includeSerdeLayer, retainOriginalCasing, - useBigInt + useBigInt, + enableInlineTypes, + context: this }); this.typeSchema = new TypeSchemaContextImpl({ sourceFile, @@ -264,7 +268,8 @@ export class SdkContextImpl implements SdkContext { treatUnknownAsAny, includeSerdeLayer, retainOriginalCasing, - useBigInt + useBigInt, + enableInlineTypes }); this.sdkError = new SdkErrorContextImpl({ sourceFile, @@ -296,7 +301,8 @@ export class SdkContextImpl implements SdkContext { importsManager, includeSerdeLayer, retainOriginalCasing, - inlineFileProperties + inlineFileProperties, + enableInlineTypes }); this.sdkInlinedRequestBodySchema = new SdkInlinedRequestBodySchemaContextImpl({ importsManager, diff --git a/generators/typescript/sdk/generator/src/contexts/base/BaseContextImpl.ts b/generators/typescript/sdk/generator/src/contexts/base/BaseContextImpl.ts index 09e3075fe3a..49cb2e6ec32 100644 --- a/generators/typescript/sdk/generator/src/contexts/base/BaseContextImpl.ts +++ b/generators/typescript/sdk/generator/src/contexts/base/BaseContextImpl.ts @@ -1,3 +1,4 @@ +import { Logger } from "@fern-api/logger"; import { Constants } from "@fern-fern/ir-sdk/api"; import { CoreUtilitiesManager, @@ -7,33 +8,50 @@ import { ImportsManager } from "@fern-typescript/commons"; import { CoreUtilities } from "@fern-typescript/commons/src/core-utilities/CoreUtilities"; -import { BaseContext } from "@fern-typescript/contexts"; +import { BaseContext, TypeContext, TypeSchemaContext } from "@fern-typescript/contexts"; import { SourceFile } from "ts-morph"; export declare namespace BaseContextImpl { export interface Init { + logger: Logger; sourceFile: SourceFile; importsManager: ImportsManager; dependencyManager: DependencyManager; coreUtilitiesManager: CoreUtilitiesManager; fernConstants: Constants; + type: TypeContext; + typeSchema: TypeSchemaContext; + includeSerdeLayer: boolean; } } export class BaseContextImpl implements BaseContext { + public readonly logger: Logger; public readonly sourceFile: SourceFile; public readonly externalDependencies: ExternalDependencies; public readonly coreUtilities: CoreUtilities; public readonly fernConstants: Constants; + public readonly type: TypeContext; + public readonly typeSchema: TypeSchemaContext; + public readonly includeSerdeLayer: boolean; constructor({ + logger, sourceFile, importsManager, dependencyManager, coreUtilitiesManager, - fernConstants + fernConstants, + type, + typeSchema, + includeSerdeLayer }: BaseContextImpl.Init) { + this.logger = logger; this.sourceFile = sourceFile; + this.fernConstants = fernConstants; + this.type = type; + this.typeSchema = typeSchema; + this.includeSerdeLayer = includeSerdeLayer; this.externalDependencies = createExternalDependencies({ dependencyManager, importsManager @@ -42,6 +60,5 @@ export class BaseContextImpl implements BaseContext { sourceFile, importsManager }); - this.fernConstants = fernConstants; } } diff --git a/generators/typescript/sdk/generator/src/contexts/request-wrapper/RequestWrapperContextImpl.ts b/generators/typescript/sdk/generator/src/contexts/request-wrapper/RequestWrapperContextImpl.ts index d8c9d9ea705..0146c4886a5 100644 --- a/generators/typescript/sdk/generator/src/contexts/request-wrapper/RequestWrapperContextImpl.ts +++ b/generators/typescript/sdk/generator/src/contexts/request-wrapper/RequestWrapperContextImpl.ts @@ -16,6 +16,7 @@ export declare namespace RequestWrapperContextImpl { includeSerdeLayer: boolean; retainOriginalCasing: boolean; inlineFileProperties: boolean; + enableInlineTypes: boolean; } } @@ -28,6 +29,7 @@ export class RequestWrapperContextImpl implements RequestWrapperContext { private includeSerdeLayer: boolean; private retainOriginalCasing: boolean; private inlineFileProperties: boolean; + private enableInlineTypes: boolean; constructor({ requestWrapperGenerator, @@ -37,7 +39,8 @@ export class RequestWrapperContextImpl implements RequestWrapperContext { sourceFile, includeSerdeLayer, retainOriginalCasing, - inlineFileProperties + inlineFileProperties, + enableInlineTypes }: RequestWrapperContextImpl.Init) { this.requestWrapperGenerator = requestWrapperGenerator; this.requestWrapperDeclarationReferencer = requestWrapperDeclarationReferencer; @@ -47,6 +50,7 @@ export class RequestWrapperContextImpl implements RequestWrapperContext { this.includeSerdeLayer = includeSerdeLayer; this.retainOriginalCasing = retainOriginalCasing; this.inlineFileProperties = inlineFileProperties; + this.enableInlineTypes = enableInlineTypes; } public getGeneratedRequestWrapper(packageId: PackageId, endpointName: Name): GeneratedRequestWrapper { @@ -67,7 +71,8 @@ export class RequestWrapperContextImpl implements RequestWrapperContext { }), includeSerdeLayer: this.includeSerdeLayer, retainOriginalCasing: this.retainOriginalCasing, - inlineFileProperties: this.inlineFileProperties + inlineFileProperties: this.inlineFileProperties, + enableInlineTypes: this.enableInlineTypes }); } diff --git a/generators/typescript/sdk/generator/src/contexts/type-schema/TypeSchemaContextImpl.ts b/generators/typescript/sdk/generator/src/contexts/type-schema/TypeSchemaContextImpl.ts index 8222e014e66..9cd2f1b1449 100644 --- a/generators/typescript/sdk/generator/src/contexts/type-schema/TypeSchemaContextImpl.ts +++ b/generators/typescript/sdk/generator/src/contexts/type-schema/TypeSchemaContextImpl.ts @@ -1,4 +1,4 @@ -import { DeclaredTypeName, ShapeType, TypeReference } from "@fern-fern/ir-sdk/api"; +import { DeclaredTypeName, ShapeType, TypeDeclaration, TypeReference } from "@fern-fern/ir-sdk/api"; import { ImportsManager, Reference, TypeReferenceNode, Zurg } from "@fern-typescript/commons"; import { CoreUtilities } from "@fern-typescript/commons/src/core-utilities/CoreUtilities"; import { GeneratedTypeSchema, TypeSchemaContext } from "@fern-typescript/contexts"; @@ -9,7 +9,7 @@ import { TypeReferenceToSchemaConverter } from "@fern-typescript/type-reference-converters"; import { TypeSchemaGenerator } from "@fern-typescript/type-schema-generator"; -import { SourceFile } from "ts-morph"; +import { ts, SourceFile } from "ts-morph"; import { TypeDeclarationReferencer } from "../../declaration-referencers/TypeDeclarationReferencer"; import { getSchemaImportStrategy } from "../getSchemaImportStrategy"; @@ -27,6 +27,7 @@ export declare namespace TypeSchemaContextImpl { includeSerdeLayer: boolean; retainOriginalCasing: boolean; useBigInt: boolean; + enableInlineTypes: boolean; } } @@ -56,17 +57,20 @@ export class TypeSchemaContextImpl implements TypeSchemaContext { treatUnknownAsAny, includeSerdeLayer, retainOriginalCasing, - useBigInt + useBigInt, + enableInlineTypes }: TypeSchemaContextImpl.Init) { this.sourceFile = sourceFile; this.coreUtilities = coreUtilities; this.importsManager = importsManager; this.typeReferenceToRawTypeNodeConverter = new TypeReferenceToRawTypeNodeConverter({ getReferenceToNamedType: (typeName) => this.getReferenceToRawNamedType(typeName).getEntityName(), + generateForInlineUnion: (typeName) => this.generateForInlineUnion(typeName), typeResolver, treatUnknownAsAny, includeSerdeLayer, - useBigInt + useBigInt, + enableInlineTypes }); this.typeReferenceToSchemaConverter = new TypeReferenceToSchemaConverter({ getSchemaOfNamedType: (typeName) => this.getSchemaOfNamedType(typeName, { isGeneratingSchema: true }), @@ -74,7 +78,8 @@ export class TypeSchemaContextImpl implements TypeSchemaContext { typeResolver, treatUnknownAsAny, includeSerdeLayer, - useBigInt + useBigInt, + enableInlineTypes }); this.typeDeclarationReferencer = typeDeclarationReferencer; this.typeSchemaDeclarationReferencer = typeSchemaDeclarationReferencer; @@ -101,10 +106,11 @@ export class TypeSchemaContextImpl implements TypeSchemaContext { docs: typeDeclaration.docs ?? undefined, examples, fernFilepath: typeDeclaration.name.fernFilepath, - typeName: this.typeDeclarationReferencer.getExportedName(typeDeclaration.name), + typeName: this.getTypeNameForDeclaration(typeDeclaration), getReferenceToSelf: (context) => context.type.getReferenceToNamedType(typeName), includeSerdeLayer: this.includeSerdeLayer, - retainOriginalCasing: this.retainOriginalCasing + retainOriginalCasing: this.retainOriginalCasing, + inline: typeDeclaration.inline ?? false }), getReferenceToGeneratedType: () => this.typeDeclarationReferencer @@ -130,8 +136,12 @@ export class TypeSchemaContextImpl implements TypeSchemaContext { }); } + private getTypeNameForDeclaration(typeDeclaration: TypeDeclaration): string { + return this.typeDeclarationReferencer.getExportedName(typeDeclaration.name); + } + public getReferenceToRawType(typeReference: TypeReference): TypeReferenceNode { - return this.typeReferenceToRawTypeNodeConverter.convert(typeReference); + return this.typeReferenceToRawTypeNodeConverter.convert({ typeReference }); } public getReferenceToRawNamedType(typeName: DeclaredTypeName): Reference { @@ -154,8 +164,12 @@ export class TypeSchemaContextImpl implements TypeSchemaContext { }); } + private generateForInlineUnion(typeName: DeclaredTypeName): ts.TypeNode { + throw new Error("Internal error; inline unions are not supported in schemas."); + } + public getSchemaOfTypeReference(typeReference: TypeReference): Zurg.Schema { - return this.typeReferenceToSchemaConverter.convert(typeReference); + return this.typeReferenceToSchemaConverter.convert({ typeReference }); } public getSchemaOfNamedType( diff --git a/generators/typescript/sdk/generator/src/contexts/type/TypeContextImpl.ts b/generators/typescript/sdk/generator/src/contexts/type/TypeContextImpl.ts index 74e3a28863d..8430bd866a1 100644 --- a/generators/typescript/sdk/generator/src/contexts/type/TypeContextImpl.ts +++ b/generators/typescript/sdk/generator/src/contexts/type/TypeContextImpl.ts @@ -1,18 +1,20 @@ import { DeclaredTypeName, ExampleTypeReference, + ObjectProperty, ResolvedTypeReference, TypeDeclaration, TypeReference } from "@fern-fern/ir-sdk/api"; import { ImportsManager, NpmPackage, Reference, TypeReferenceNode } from "@fern-typescript/commons"; -import { GeneratedType, GeneratedTypeReferenceExample, TypeContext } from "@fern-typescript/contexts"; +import { BaseContext, GeneratedType, GeneratedTypeReferenceExample, TypeContext } from "@fern-typescript/contexts"; import { TypeResolver } from "@fern-typescript/resolvers"; import { TypeGenerator } from "@fern-typescript/type-generator"; import { TypeReferenceToParsedTypeNodeConverter, TypeReferenceToStringExpressionConverter } from "@fern-typescript/type-reference-converters"; +import { ConvertTypeReferenceParams } from "@fern-typescript/type-reference-converters/src/AbstractTypeReferenceConverter"; import { TypeReferenceExampleGenerator } from "@fern-typescript/type-reference-example-generator"; import { SourceFile, ts } from "ts-morph"; import { TypeDeclarationReferencer } from "../../declaration-referencers/TypeDeclarationReferencer"; @@ -31,6 +33,8 @@ export declare namespace TypeContextImpl { includeSerdeLayer: boolean; retainOriginalCasing: boolean; useBigInt: boolean; + enableInlineTypes: boolean; + context: BaseContext; } } @@ -47,6 +51,7 @@ export class TypeContextImpl implements TypeContext { private retainOriginalCasing: boolean; private isForSnippet: boolean; private npmPackage: NpmPackage | undefined; + private context: BaseContext; constructor({ npmPackage, @@ -60,7 +65,9 @@ export class TypeContextImpl implements TypeContext { treatUnknownAsAny, includeSerdeLayer, retainOriginalCasing, - useBigInt + useBigInt, + enableInlineTypes, + context }: TypeContextImpl.Init) { this.npmPackage = npmPackage; this.isForSnippet = isForSnippet; @@ -72,24 +79,56 @@ export class TypeContextImpl implements TypeContext { this.typeReferenceExampleGenerator = typeReferenceExampleGenerator; this.includeSerdeLayer = includeSerdeLayer; this.retainOriginalCasing = retainOriginalCasing; + this.context = context; this.typeReferenceToParsedTypeNodeConverter = new TypeReferenceToParsedTypeNodeConverter({ getReferenceToNamedType: (typeName) => this.getReferenceToNamedType(typeName).getEntityName(), + generateForInlineUnion: (typeName) => this.generateForInlineUnion(typeName), typeResolver, treatUnknownAsAny, includeSerdeLayer, - useBigInt + useBigInt, + enableInlineTypes }); this.typeReferenceToStringExpressionConverter = new TypeReferenceToStringExpressionConverter({ typeResolver, treatUnknownAsAny, includeSerdeLayer, - useBigInt + useBigInt, + enableInlineTypes }); } public getReferenceToType(typeReference: TypeReference): TypeReferenceNode { - return this.typeReferenceToParsedTypeNodeConverter.convert(typeReference); + return this.typeReferenceToParsedTypeNodeConverter.convert({ typeReference }); + } + + public getReferenceToInlinePropertyType( + typeReference: TypeReference, + parentTypeName: string, + propertyName: string + ): TypeReferenceNode { + return this.typeReferenceToParsedTypeNodeConverter.convert({ + typeReference, + type: "inlinePropertyParams", + parentTypeName, + propertyName + }); + } + + public getReferenceToInlineAliasType(typeReference: TypeReference, aliasTypeName: string): TypeReferenceNode { + return this.typeReferenceToParsedTypeNodeConverter.convert({ + typeReference, + type: "inlineAliasParams", + aliasTypeName + }); + } + + public getReferenceToTypeForInlineUnion(typeReference: TypeReference): TypeReferenceNode { + return this.typeReferenceToParsedTypeNodeConverter.convert({ + typeReference, + type: "forInlineUnionParams" + }); } public getTypeDeclaration(typeName: DeclaredTypeName): TypeDeclaration { @@ -118,6 +157,11 @@ export class TypeContextImpl implements TypeContext { } } + public generateForInlineUnion(typeName: DeclaredTypeName): ts.TypeNode { + const generatedType = this.getGeneratedType(typeName); + return generatedType.generateForInlineUnion(this.context); + } + public resolveTypeReference(typeReference: TypeReference): ResolvedTypeReference { return this.typeResolver.resolveTypeReference(typeReference); } @@ -131,7 +175,7 @@ export class TypeContextImpl implements TypeContext { return this.getGeneratedType(typeDeclaration.name); } - public getGeneratedType(typeName: DeclaredTypeName): GeneratedType { + public getGeneratedType(typeName: DeclaredTypeName, typeNameOverride?: string): GeneratedType { const typeDeclaration = this.typeResolver.getTypeDeclarationFromName(typeName); const examples = typeDeclaration.userProvidedExamples; if (examples.length === 0) { @@ -140,12 +184,13 @@ export class TypeContextImpl implements TypeContext { return this.typeGenerator.generateType({ shape: typeDeclaration.shape, docs: typeDeclaration.docs ?? undefined, - typeName: this.typeDeclarationReferencer.getExportedName(typeDeclaration.name), + typeName: typeNameOverride ?? this.typeDeclarationReferencer.getExportedName(typeDeclaration.name), examples, fernFilepath: typeDeclaration.name.fernFilepath, getReferenceToSelf: (context) => context.type.getReferenceToNamedType(typeName), includeSerdeLayer: this.includeSerdeLayer, - retainOriginalCasing: this.retainOriginalCasing + retainOriginalCasing: this.retainOriginalCasing, + inline: typeDeclaration.inline ?? false }); } @@ -155,11 +200,13 @@ export class TypeContextImpl implements TypeContext { { includeNullCheckIfOptional }: { includeNullCheckIfOptional: boolean } ): ts.Expression { if (includeNullCheckIfOptional) { - return this.typeReferenceToStringExpressionConverter.convertWithNullCheckIfOptional(valueType)( - valueToStringify - ); + return this.typeReferenceToStringExpressionConverter.convertWithNullCheckIfOptional({ + typeReference: valueType + })(valueToStringify); } else { - return this.typeReferenceToStringExpressionConverter.convert(valueType)(valueToStringify); + return this.typeReferenceToStringExpressionConverter.convert({ + typeReference: valueType + })(valueToStringify); } } diff --git a/generators/typescript/sdk/generator/src/declaration-referencers/TypeDeclarationReferencer.ts b/generators/typescript/sdk/generator/src/declaration-referencers/TypeDeclarationReferencer.ts index 1f468479fb9..235f4d99453 100644 --- a/generators/typescript/sdk/generator/src/declaration-referencers/TypeDeclarationReferencer.ts +++ b/generators/typescript/sdk/generator/src/declaration-referencers/TypeDeclarationReferencer.ts @@ -1,5 +1,5 @@ import { RelativeFilePath } from "@fern-api/fs-utils"; -import { DeclaredTypeName } from "@fern-fern/ir-sdk/api"; +import { DeclaredTypeName, ObjectProperty, TypeDeclaration } from "@fern-fern/ir-sdk/api"; import { ExportedFilePath, getExportedDirectoriesForFernFilepath, Reference } from "@fern-typescript/commons"; import { AbstractDeclarationReferencer } from "./AbstractDeclarationReferencer"; import { DeclarationReferencer } from "./DeclarationReferencer"; diff --git a/generators/typescript/sdk/request-wrapper-generator/package.json b/generators/typescript/sdk/request-wrapper-generator/package.json index 4add7383b61..e4c0bd15f9b 100644 --- a/generators/typescript/sdk/request-wrapper-generator/package.json +++ b/generators/typescript/sdk/request-wrapper-generator/package.json @@ -28,7 +28,7 @@ }, "dependencies": { "@fern-api/core-utils": "workspace:*", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", "ts-morph": "^15.1.0" diff --git a/generators/typescript/sdk/request-wrapper-generator/src/GeneratedRequestWrapperImpl.ts b/generators/typescript/sdk/request-wrapper-generator/src/GeneratedRequestWrapperImpl.ts index 6c49dfa6363..c55c3c94767 100644 --- a/generators/typescript/sdk/request-wrapper-generator/src/GeneratedRequestWrapperImpl.ts +++ b/generators/typescript/sdk/request-wrapper-generator/src/GeneratedRequestWrapperImpl.ts @@ -1,7 +1,8 @@ -import { noop } from "@fern-api/core-utils"; +import { assertNever, noop } from "@fern-api/core-utils"; import { ExampleEndpointCall, FileProperty, + FileUploadRequest, FileUploadRequestProperty, HttpEndpoint, HttpHeader, @@ -10,14 +11,20 @@ import { InlinedRequestBody, InlinedRequestBodyProperty, NameAndWireValue, + NamedType, + ObjectProperty, QueryParameter, + TypeDeclaration, TypeReference } from "@fern-fern/ir-sdk/api"; import { + generateInlinePropertiesModule, getExampleEndpointCalls, getTextOfTsNode, - maybeAddDocs, + maybeAddDocsNode, + maybeAddDocsStructure, PackageId, + TypeReferenceNode, visitJavaScriptRuntime } from "@fern-typescript/commons"; import { @@ -26,7 +33,17 @@ import { RequestWrapperNonBodyProperty, SdkContext } from "@fern-typescript/contexts"; -import { OptionalKind, PropertySignatureStructure, ts } from "ts-morph"; +import { + ModuleDeclarationKind, + ModuleDeclarationStructure, + OptionalKind, + PropertySignatureStructure, + StatementStructures, + StructureKind, + ts, + TypeAliasDeclarationStructure, + WriterFunction +} from "ts-morph"; import { RequestWrapperExampleGenerator } from "./RequestWrapperExampleGenerator"; export declare namespace GeneratedRequestWrapperImpl { @@ -38,6 +55,7 @@ export declare namespace GeneratedRequestWrapperImpl { includeSerdeLayer: boolean; retainOriginalCasing: boolean; inlineFileProperties: boolean; + enableInlineTypes: boolean; } } @@ -51,6 +69,7 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { protected includeSerdeLayer: boolean; protected retainOriginalCasing: boolean; protected inlineFileProperties: boolean; + private enableInlineTypes: boolean; constructor({ service, @@ -59,7 +78,8 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { packageId, includeSerdeLayer, retainOriginalCasing, - inlineFileProperties + inlineFileProperties, + enableInlineTypes }: GeneratedRequestWrapperImpl.Init) { this.service = service; this.endpoint = endpoint; @@ -68,6 +88,7 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { this.includeSerdeLayer = includeSerdeLayer; this.retainOriginalCasing = retainOriginalCasing; this.inlineFileProperties = inlineFileProperties; + this.enableInlineTypes = enableInlineTypes; } public writeToFile(context: SdkContext): void { @@ -92,7 +113,7 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { ), hasQuestionToken: type.isOptional }); - maybeAddDocs(property, queryParameter.docs); + maybeAddDocsNode(property, queryParameter.docs); } for (const header of this.getAllNonLiteralHeaders(context)) { const type = context.type.getReferenceToType(header.valueType); @@ -101,7 +122,7 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { type: getTextOfTsNode(type.typeNodeWithoutUndefined), hasQuestionToken: type.isOptional }); - maybeAddDocs(property, header.docs); + maybeAddDocsNode(property, header.docs); } if (this.endpoint.requestBody != null) { HttpRequestBody._visit(this.endpoint.requestBody, { @@ -110,7 +131,11 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { inlinedRequestBody, context })) { - requestInterface.addProperty(this.getInlineProperty(property, context)); + requestInterface.addProperty(this.getInlineProperty(inlinedRequestBody, property, context)); + } + const iModule = this.generateModule(inlinedRequestBody, context); + if (iModule) { + context.sourceFile.addModule(iModule); } for (const extension of inlinedRequestBody.extends) { requestInterface.addExtends( @@ -125,7 +150,7 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { type: getTextOfTsNode(type.typeNodeWithoutUndefined), hasQuestionToken: type.isOptional }); - maybeAddDocs(property, referenceToRequestBody.docs); + maybeAddDocsNode(property, referenceToRequestBody.docs); }, fileUpload: (fileUploadRequest) => { for (const property of fileUploadRequest.properties) { @@ -141,7 +166,9 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { }); }, bodyProperty: (inlinedProperty) => { - requestInterface.addProperty(this.getInlineProperty(inlinedProperty, context)); + requestInterface.addProperty( + this.getInlineProperty(fileUploadRequest, inlinedProperty, context) + ); }, _other: () => { throw new Error("Unknown FileUploadRequestProperty: " + property.type); @@ -186,10 +213,11 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { } private getInlineProperty( + requestBody: InlinedRequestBody | FileUploadRequest, property: InlinedRequestBodyProperty, context: SdkContext ): OptionalKind { - const type = context.type.getReferenceToType(property.valueType); + const type = this.getTypeForBodyProperty(requestBody, property, context); return { name: `"${this.getInlinedRequestBodyPropertyKey(property)}"`, type: getTextOfTsNode(type.typeNodeWithoutUndefined), @@ -198,6 +226,36 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { }; } + private getTypeForBodyProperty( + requestBody: InlinedRequestBody | FileUploadRequest, + property: InlinedRequestBodyProperty, + context: SdkContext + ): TypeReferenceNode { + const propParentTypeName = requestBody.name.pascalCase.safeName; + const propName = property.name.name.pascalCase.safeName; + return context.type.getReferenceToInlinePropertyType(property.valueType, propParentTypeName, propName); + } + + private generateModule( + inlinedRequestBody: InlinedRequestBody, + context: SdkContext + ): ModuleDeclarationStructure | undefined { + if (!this.enableInlineTypes) { + return undefined; + } + + return generateInlinePropertiesModule({ + parentTypeName: this.wrapperName, + properties: inlinedRequestBody.properties.map((prop) => ({ + propertyName: prop.name.name.pascalCase.safeName, + typeReference: prop.valueType + })), + generateStatements: (typeName, typeNameOverride) => + context.type.getGeneratedType(typeName, typeNameOverride).generateStatements(context), + getTypeDeclaration: (namedType) => context.type.getTypeDeclaration(namedType) + }); + } + public areBodyPropertiesInlined(): boolean { return this.endpoint.requestBody != null && this.endpoint.requestBody.type === "inlinedRequestBody"; } @@ -498,3 +556,58 @@ export class GeneratedRequestWrapperImpl implements GeneratedRequestWrapper { return property.type === "fileArray" ? ts.factory.createArrayTypeNode(value) : value; } } +function generateTypeVisitor( + typeReference: TypeReference, + visitor: { + named: () => TOut; + list: () => TOut; + map: () => TOut; + set: () => TOut; + other: () => TOut; + } +): TOut { + return typeReference._visit({ + named: visitor.named, + primitive: visitor.other, + unknown: visitor.other, + container: (containerType) => + containerType._visit({ + list: visitor.list, + literal: visitor.other, + map: visitor.map, + set: visitor.set, + optional: (typeReference) => generateTypeVisitor(typeReference, visitor), + _other: visitor.other + }), + _other: visitor.other + }); +} + +function getNamedType(typeReference: TypeReference): NamedType | undefined { + switch (typeReference.type) { + case "named": + return typeReference; + case "container": + switch (typeReference.container.type) { + case "optional": + return getNamedType(typeReference.container.optional); + case "list": + return getNamedType(typeReference.container.list); + case "map": + return getNamedType(typeReference.container.valueType); + case "set": + return getNamedType(typeReference.container.set); + case "literal": + return undefined; + default: + assertNever(typeReference.container); + } + // fallthrough + case "primitive": + return undefined; + case "unknown": + return undefined; + default: + assertNever(typeReference); + } +} diff --git a/generators/typescript/sdk/request-wrapper-generator/src/RequestWrapperGenerator.ts b/generators/typescript/sdk/request-wrapper-generator/src/RequestWrapperGenerator.ts index e8e0da0f816..ec52071dcee 100644 --- a/generators/typescript/sdk/request-wrapper-generator/src/RequestWrapperGenerator.ts +++ b/generators/typescript/sdk/request-wrapper-generator/src/RequestWrapperGenerator.ts @@ -13,6 +13,7 @@ export declare namespace RequestWrapperGenerator { includeSerdeLayer: boolean; retainOriginalCasing: boolean; inlineFileProperties: boolean; + enableInlineTypes: boolean; } } } @@ -25,7 +26,8 @@ export class RequestWrapperGenerator { wrapperName, includeSerdeLayer, retainOriginalCasing, - inlineFileProperties + inlineFileProperties, + enableInlineTypes }: RequestWrapperGenerator.generateRequestWrapper.Args): GeneratedRequestWrapper { return new GeneratedRequestWrapperImpl({ packageId, @@ -34,7 +36,8 @@ export class RequestWrapperGenerator { wrapperName, includeSerdeLayer, retainOriginalCasing, - inlineFileProperties + inlineFileProperties, + enableInlineTypes }); } } diff --git a/generators/typescript/sdk/sdk-endpoint-type-schemas-generator/package.json b/generators/typescript/sdk/sdk-endpoint-type-schemas-generator/package.json index 835346fd208..5a1a40aecd3 100644 --- a/generators/typescript/sdk/sdk-endpoint-type-schemas-generator/package.json +++ b/generators/typescript/sdk/sdk-endpoint-type-schemas-generator/package.json @@ -28,7 +28,7 @@ }, "dependencies": { "@fern-api/core-utils": "workspace:*", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/abstract-schema-generator": "workspace:*", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", diff --git a/generators/typescript/sdk/sdk-error-generator/package.json b/generators/typescript/sdk/sdk-error-generator/package.json index ad385ac1098..bb35359c067 100644 --- a/generators/typescript/sdk/sdk-error-generator/package.json +++ b/generators/typescript/sdk/sdk-error-generator/package.json @@ -27,7 +27,7 @@ "depcheck": "depcheck" }, "dependencies": { - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/abstract-error-class-generator": "workspace:*", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", diff --git a/generators/typescript/sdk/sdk-error-schema-generator/package.json b/generators/typescript/sdk/sdk-error-schema-generator/package.json index 51605ff06aa..bffc0aedcb9 100644 --- a/generators/typescript/sdk/sdk-error-schema-generator/package.json +++ b/generators/typescript/sdk/sdk-error-schema-generator/package.json @@ -28,7 +28,7 @@ }, "dependencies": { "@fern-api/core-utils": "workspace:*", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/abstract-schema-generator": "workspace:*", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", diff --git a/generators/typescript/sdk/sdk-inlined-request-body-schema-generator/package.json b/generators/typescript/sdk/sdk-inlined-request-body-schema-generator/package.json index 480994c7341..f82ee155563 100644 --- a/generators/typescript/sdk/sdk-inlined-request-body-schema-generator/package.json +++ b/generators/typescript/sdk/sdk-inlined-request-body-schema-generator/package.json @@ -27,7 +27,7 @@ "depcheck": "depcheck" }, "dependencies": { - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/abstract-schema-generator": "workspace:*", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*", diff --git a/generators/typescript/utils/abstract-generator-cli/package.json b/generators/typescript/utils/abstract-generator-cli/package.json index 7fbec6d57f6..1c5701d62ba 100644 --- a/generators/typescript/utils/abstract-generator-cli/package.json +++ b/generators/typescript/utils/abstract-generator-cli/package.json @@ -31,7 +31,7 @@ "@fern-api/base-generator": "workspace:*", "@fern-api/logger": "workspace:*", "@fern-fern/generator-exec-sdk": "^0.0.898", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/commons": "workspace:*", "@fern-typescript/contexts": "workspace:*" }, diff --git a/generators/typescript/utils/commons/package.json b/generators/typescript/utils/commons/package.json index 612f7796015..0532c75b5ba 100644 --- a/generators/typescript/utils/commons/package.json +++ b/generators/typescript/utils/commons/package.json @@ -31,7 +31,7 @@ "@fern-api/fs-utils": "workspace:*", "@fern-api/logger": "workspace:*", "@fern-api/logging-execa": "workspace:*", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/fetcher": "workspace:*", "@fern-typescript/zurg": "workspace:*", "decompress": "^4.2.1", diff --git a/generators/typescript/utils/commons/src/codegen-utils/generateInlineModule.ts b/generators/typescript/utils/commons/src/codegen-utils/generateInlineModule.ts new file mode 100644 index 00000000000..af4728f0561 --- /dev/null +++ b/generators/typescript/utils/commons/src/codegen-utils/generateInlineModule.ts @@ -0,0 +1,251 @@ +import { assertNever } from "@fern-api/core-utils"; +import { TypeReference, TypeDeclaration, MapType, NamedType, DeclaredTypeName } from "@fern-fern/ir-sdk/api"; +import { + ModuleDeclarationKind, + ModuleDeclarationStructure, + StatementStructures, + StructureKind, + TypeAliasDeclarationStructure, + WriterFunction +} from "ts-morph"; +import { InlineConsts } from "./inlineConsts"; + +export function generateInlinePropertiesModule({ + generateStatements, + getTypeDeclaration, + parentTypeName, + properties +}: InlinePropertiesParams): ModuleDeclarationStructure | undefined { + const inlineProperties = getInlineProperties(properties, getTypeDeclaration); + if (inlineProperties.length === 0) { + return; + } + return { + kind: StructureKind.Module, + name: parentTypeName, + isExported: true, + hasDeclareKeyword: false, + declarationKind: ModuleDeclarationKind.Namespace, + statements: inlineProperties.flatMap( + ([propertyName, typeReference, typeDeclaration]: [string, TypeReference, TypeDeclaration]) => { + return generateTypeVisitor(typeReference, { + named: () => generateStatements(typeDeclaration.name, propertyName), + list: () => propertyListOrSetStatementGenerator(propertyName, typeDeclaration, generateStatements), + set: () => propertyListOrSetStatementGenerator(propertyName, typeDeclaration, generateStatements), + map: () => { + const statements: StatementStructures[] = []; + const mapModule: ModuleDeclarationStructure = { + kind: StructureKind.Module, + declarationKind: ModuleDeclarationKind.Namespace, + isExported: true, + hasDeclareKeyword: false, + name: propertyName, + statements: generateStatements(typeDeclaration.name, InlineConsts.MAP_VALUE_TYPE_NAME) + }; + + statements.push(mapModule); + return statements; + }, + other: () => { + throw new Error(`Only named, list, map, and set properties can be inlined. + Property: ${JSON.stringify(propertyName)}`); + } + }); + } + ) + }; +} + +function propertyListOrSetStatementGenerator( + propertyName: string, + typeDeclaration: TypeDeclaration, + generateStatements: GenerateStatements +) { + const statements: StatementStructures[] = []; + const listType: TypeAliasDeclarationStructure = { + kind: StructureKind.TypeAlias, + name: propertyName, + type: `${propertyName}.${InlineConsts.LIST_ITEM_TYPE_NAME}[]`, + isExported: true + }; + statements.push(listType); + + const listModule: ModuleDeclarationStructure = { + kind: StructureKind.Module, + declarationKind: ModuleDeclarationKind.Namespace, + isExported: true, + hasDeclareKeyword: false, + name: propertyName, + statements: generateStatements(typeDeclaration.name, InlineConsts.LIST_ITEM_TYPE_NAME) + }; + + statements.push(listModule); + return statements; +} + +export function generateInlineAliasModule({ + generateStatements, + getTypeDeclaration, + aliasTypeName, + typeReference +}: InlineAliasParams): ModuleDeclarationStructure | undefined { + const inlineModuleStatements = generateTypeVisitor(typeReference, { + list: (itemType) => aliasListOrSetStatementGenerator(itemType, generateStatements, getTypeDeclaration), + set: (itemType) => aliasListOrSetStatementGenerator(itemType, generateStatements, getTypeDeclaration), + map: (mapType: MapType) => { + const namedType = getNamedType(mapType.valueType); + if (!namedType) { + return undefined; + } + const typeDeclaration = getTypeDeclaration(namedType); + if (!typeDeclaration.inline) { + return undefined; + } + + return generateStatements(typeDeclaration.name, InlineConsts.MAP_VALUE_TYPE_NAME); + }, + named: () => undefined, + other: () => undefined + }); + if (!inlineModuleStatements) { + return undefined; + } + return { + kind: StructureKind.Module, + name: aliasTypeName, + isExported: true, + hasDeclareKeyword: false, + declarationKind: ModuleDeclarationKind.Namespace, + statements: inlineModuleStatements + }; +} + +function aliasListOrSetStatementGenerator( + listItemType: TypeReference, + generateStatements: GenerateStatements, + getTypeDeclaration: GetTypeDeclaration +): undefined | string | WriterFunction | (string | WriterFunction | StatementStructures)[] { + const namedType = getNamedType(listItemType); + if (!namedType) { + return undefined; + } + const typeDeclaration = getTypeDeclaration(namedType); + if (!typeDeclaration.inline) { + return undefined; + } + + return generateStatements(typeDeclaration.name, InlineConsts.LIST_ITEM_TYPE_NAME); +} + +function getInlineProperties( + properties: Property[], + getTypeDeclaration: GetTypeDeclaration +): [string, TypeReference, TypeDeclaration][] { + return properties + .map(({ propertyName, typeReference }): [string, TypeReference, TypeDeclaration] | undefined => { + const declaration = getInlineTypeDeclaration(typeReference, getTypeDeclaration); + if (!declaration) { + return undefined; + } + return [propertyName, typeReference, declaration]; + }) + .filter((x): x is [string, TypeReference, TypeDeclaration] => x !== undefined); +} + +function getInlineTypeDeclaration( + typeReference: TypeReference, + getTypeDeclaration: GetTypeDeclaration +): TypeDeclaration | undefined { + const namedType = getNamedType(typeReference); + if (!namedType) { + return undefined; + } + const typeDeclaration = getTypeDeclaration(namedType); + if (!typeDeclaration.inline) { + return undefined; + } + + return typeDeclaration; +} + +export interface InlinePropertiesParams { + generateStatements: GenerateStatements; + getTypeDeclaration: GetTypeDeclaration; + parentTypeName: string; + properties: Property[]; +} + +interface Property { + typeReference: TypeReference; + propertyName: string; +} + +export interface InlineAliasParams { + generateStatements: GenerateStatements; + getTypeDeclaration: GetTypeDeclaration; + typeReference: TypeReference; + aliasTypeName: string; +} + +type GenerateStatements = ( + typeName: DeclaredTypeName, + typeNameOverride?: string +) => string | WriterFunction | (string | WriterFunction | StatementStructures)[]; + +type GetTypeDeclaration = (namedType: NamedType) => TypeDeclaration; + +function generateTypeVisitor( + typeReference: TypeReference, + visitor: { + named: (namedType: NamedType) => TOut; + list: (itemType: TypeReference) => TOut; + map: (mapType: MapType) => TOut; + set: (itemType: TypeReference) => TOut; + other: () => TOut; + } +): TOut { + return typeReference._visit({ + named: visitor.named, + primitive: visitor.other, + unknown: visitor.other, + container: (containerType) => + containerType._visit({ + list: visitor.list, + literal: visitor.other, + map: visitor.map, + set: visitor.set, + optional: (typeReference) => generateTypeVisitor(typeReference, visitor), + _other: visitor.other + }), + _other: visitor.other + }); +} + +function getNamedType(typeReference: TypeReference): NamedType | undefined { + switch (typeReference.type) { + case "named": + return typeReference; + case "container": + switch (typeReference.container.type) { + case "optional": + return getNamedType(typeReference.container.optional); + case "list": + return getNamedType(typeReference.container.list); + case "map": + return getNamedType(typeReference.container.valueType); + case "set": + return getNamedType(typeReference.container.set); + case "literal": + return undefined; + default: + assertNever(typeReference.container); + } + // fallthrough + case "primitive": + return undefined; + case "unknown": + return undefined; + default: + assertNever(typeReference); + } +} diff --git a/generators/typescript/utils/commons/src/codegen-utils/inlineConsts.ts b/generators/typescript/utils/commons/src/codegen-utils/inlineConsts.ts new file mode 100644 index 00000000000..7a3a221e981 --- /dev/null +++ b/generators/typescript/utils/commons/src/codegen-utils/inlineConsts.ts @@ -0,0 +1,4 @@ +export const InlineConsts = { + MAP_VALUE_TYPE_NAME: "Value", + LIST_ITEM_TYPE_NAME: "Item" +} as const; diff --git a/generators/typescript/utils/commons/src/codegen-utils/maybeAddDocs.ts b/generators/typescript/utils/commons/src/codegen-utils/maybeAddDocs.ts index bbf8ccd6fcb..593d4f74296 100644 --- a/generators/typescript/utils/commons/src/codegen-utils/maybeAddDocs.ts +++ b/generators/typescript/utils/commons/src/codegen-utils/maybeAddDocs.ts @@ -1,8 +1,17 @@ -import { JSDocableNode } from "ts-morph"; +import { JSDocableNode, JSDocableNodeStructure } from "ts-morph"; -export function maybeAddDocs(node: JSDocableNode, docs: string | null | undefined): void { +export function maybeAddDocsNode(node: JSDocableNode, docs: string | null | undefined): void { if (docs != null) { + docs = "\n" + docs; + node.addJsDoc(docs); + } +} + +export function maybeAddDocsStructure(node: JSDocableNodeStructure, docs: string | null | undefined): void { + if (docs != null) { + docs = "\n" + docs; // add newline so ts-morph makes it a multiline comment - node.addJsDoc("\n" + docs); + node.docs = [docs]; + return; } } diff --git a/generators/typescript/utils/commons/src/codegen-utils/writerToString.ts b/generators/typescript/utils/commons/src/codegen-utils/writerToString.ts new file mode 100644 index 00000000000..e471579f852 --- /dev/null +++ b/generators/typescript/utils/commons/src/codegen-utils/writerToString.ts @@ -0,0 +1,12 @@ +import { CodeBlockWriter, WriterFunction } from "ts-morph"; + +export function writerToString(writer: WriterFunction | string): string { + if (typeof writer === "string") { + return writer; + } + // Create a minimal writer context that captures the output + const writerContext = new CodeBlockWriter(); + // Execute the writer with our context + writer(writerContext); + return writerContext.toString(); +} diff --git a/generators/typescript/utils/commons/src/index.ts b/generators/typescript/utils/commons/src/index.ts index a00948bf805..0ea330a99f7 100644 --- a/generators/typescript/utils/commons/src/index.ts +++ b/generators/typescript/utils/commons/src/index.ts @@ -3,7 +3,9 @@ export { getPropertyKey } from "./codegen-utils/getPropertyKey"; export { getSchemaOptions } from "./codegen-utils/getSchemaOptions"; export { getTextOfTsKeyword } from "./codegen-utils/getTextOfTsKeyword"; export { getTextOfTsNode } from "./codegen-utils/getTextOfTsNode"; -export { maybeAddDocs } from "./codegen-utils/maybeAddDocs"; +export { maybeAddDocsNode, maybeAddDocsStructure } from "./codegen-utils/maybeAddDocs"; +export { writerToString } from "./codegen-utils/writerToString"; +export { generateInlineAliasModule, generateInlinePropertiesModule } from "./codegen-utils/generateInlineModule"; export * from "./core-utilities"; export { type Zurg } from "./core-utilities/zurg/Zurg"; export { DependencyManager, DependencyType, type PackageDependencies } from "./dependency-manager/DependencyManager"; diff --git a/generators/typescript/utils/contexts/package.json b/generators/typescript/utils/contexts/package.json index 34f95fc84f8..2fc47911eeb 100644 --- a/generators/typescript/utils/contexts/package.json +++ b/generators/typescript/utils/contexts/package.json @@ -30,7 +30,7 @@ "@fern-api/logger": "workspace:*", "@fern-api/base-generator": "workspace:*", "@fern-fern/generator-exec-sdk": "^0.0.898", - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/commons": "workspace:*", "ts-morph": "^15.1.0" }, diff --git a/generators/typescript/utils/contexts/src/base-context/BaseContext.ts b/generators/typescript/utils/contexts/src/base-context/BaseContext.ts index 484a3ff08d8..619cbc43c02 100644 --- a/generators/typescript/utils/contexts/src/base-context/BaseContext.ts +++ b/generators/typescript/utils/contexts/src/base-context/BaseContext.ts @@ -1,11 +1,17 @@ +import { Logger } from "@fern-api/logger"; import { Constants } from "@fern-fern/ir-sdk/api"; import { ExternalDependencies } from "@fern-typescript/commons"; import { CoreUtilities } from "@fern-typescript/commons/src/core-utilities/CoreUtilities"; import { SourceFile } from "ts-morph"; +import { TypeContext, TypeSchemaContext } from "../model-context"; export interface BaseContext { + logger: Logger; sourceFile: SourceFile; externalDependencies: ExternalDependencies; coreUtilities: CoreUtilities; fernConstants: Constants; + type: TypeContext; + typeSchema: TypeSchemaContext; + includeSerdeLayer: boolean; } diff --git a/generators/typescript/utils/contexts/src/base-context/index.ts b/generators/typescript/utils/contexts/src/base-context/index.ts index fe9a97ab7b5..7e00204fc7d 100644 --- a/generators/typescript/utils/contexts/src/base-context/index.ts +++ b/generators/typescript/utils/contexts/src/base-context/index.ts @@ -1 +1,4 @@ export { type BaseContext } from "./BaseContext"; + +export * from "./type"; +export * from "./type-schema"; diff --git a/generators/typescript/utils/contexts/src/model-context/type-schema/BaseGeneratedTypeSchema.ts b/generators/typescript/utils/contexts/src/base-context/type-schema/BaseGeneratedTypeSchema.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type-schema/BaseGeneratedTypeSchema.ts rename to generators/typescript/utils/contexts/src/base-context/type-schema/BaseGeneratedTypeSchema.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedAliasTypeSchema.ts b/generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedAliasTypeSchema.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedAliasTypeSchema.ts rename to generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedAliasTypeSchema.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedEnumTypeSchema.ts b/generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedEnumTypeSchema.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedEnumTypeSchema.ts rename to generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedEnumTypeSchema.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedObjectTypeSchema.ts b/generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedObjectTypeSchema.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedObjectTypeSchema.ts rename to generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedObjectTypeSchema.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedTypeSchema.ts b/generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedTypeSchema.ts similarity index 84% rename from generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedTypeSchema.ts rename to generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedTypeSchema.ts index f1b00c475e6..55974a35891 100644 --- a/generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedTypeSchema.ts +++ b/generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedTypeSchema.ts @@ -1,11 +1,11 @@ -import { ModelContext } from "../ModelContext"; +import { BaseContext } from "../../base-context"; import { GeneratedAliasTypeSchema } from "./GeneratedAliasTypeSchema"; import { GeneratedEnumTypeSchema } from "./GeneratedEnumTypeSchema"; import { GeneratedObjectTypeSchema } from "./GeneratedObjectTypeSchema"; import { GeneratedUndiscriminatedUnionTypeSchema } from "./GeneratedUndiscriminatedUnionTypeSchema"; import { GeneratedUnionTypeSchema } from "./GeneratedUnionTypeSchema"; -export type GeneratedTypeSchema = +export type GeneratedTypeSchema = | GeneratedAliasTypeSchema | GeneratedEnumTypeSchema | GeneratedUnionTypeSchema diff --git a/generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedUndiscriminatedUnionTypeSchema.ts b/generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedUndiscriminatedUnionTypeSchema.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedUndiscriminatedUnionTypeSchema.ts rename to generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedUndiscriminatedUnionTypeSchema.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedUnionTypeSchema.ts b/generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedUnionTypeSchema.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type-schema/GeneratedUnionTypeSchema.ts rename to generators/typescript/utils/contexts/src/base-context/type-schema/GeneratedUnionTypeSchema.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type-schema/TypeSchemaContext.ts b/generators/typescript/utils/contexts/src/base-context/type-schema/TypeSchemaContext.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type-schema/TypeSchemaContext.ts rename to generators/typescript/utils/contexts/src/base-context/type-schema/TypeSchemaContext.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type-schema/index.ts b/generators/typescript/utils/contexts/src/base-context/type-schema/index.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type-schema/index.ts rename to generators/typescript/utils/contexts/src/base-context/type-schema/index.ts diff --git a/generators/typescript/utils/contexts/src/base-context/type/BaseGeneratedType.ts b/generators/typescript/utils/contexts/src/base-context/type/BaseGeneratedType.ts new file mode 100644 index 00000000000..f2a69f75d11 --- /dev/null +++ b/generators/typescript/utils/contexts/src/base-context/type/BaseGeneratedType.ts @@ -0,0 +1,15 @@ +import { ExampleTypeShape } from "@fern-fern/ir-sdk/api"; +import { GetReferenceOpts } from "@fern-typescript/commons"; +import { ts } from "ts-morph"; +import { GeneratedFile } from "../../commons"; +import { GeneratedModule } from "../../commons/GeneratedModule"; +import { GeneratedStatements } from "../../commons/GeneratedStatements"; +import { GeneratedUnionInlineMemberNode } from "../../commons/GeneratedUnionInlineMemberNode"; + +export interface BaseGeneratedType + extends GeneratedFile, + GeneratedStatements, + GeneratedModule, + GeneratedUnionInlineMemberNode { + buildExample: (example: ExampleTypeShape, context: Context, opts: GetReferenceOpts) => ts.Expression; +} diff --git a/generators/typescript/utils/contexts/src/model-context/type/GeneratedAliasType.ts b/generators/typescript/utils/contexts/src/base-context/type/GeneratedAliasType.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type/GeneratedAliasType.ts rename to generators/typescript/utils/contexts/src/base-context/type/GeneratedAliasType.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type/GeneratedEnumType.ts b/generators/typescript/utils/contexts/src/base-context/type/GeneratedEnumType.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type/GeneratedEnumType.ts rename to generators/typescript/utils/contexts/src/base-context/type/GeneratedEnumType.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type/GeneratedObjectType.ts b/generators/typescript/utils/contexts/src/base-context/type/GeneratedObjectType.ts similarity index 74% rename from generators/typescript/utils/contexts/src/model-context/type/GeneratedObjectType.ts rename to generators/typescript/utils/contexts/src/base-context/type/GeneratedObjectType.ts index 3213cb7955c..c9bc70c056a 100644 --- a/generators/typescript/utils/contexts/src/model-context/type/GeneratedObjectType.ts +++ b/generators/typescript/utils/contexts/src/base-context/type/GeneratedObjectType.ts @@ -1,6 +1,6 @@ import { ExampleTypeShape, TypeReference } from "@fern-fern/ir-sdk/api"; import { GetReferenceOpts } from "@fern-typescript/commons"; -import { ts } from "ts-morph"; +import { InterfaceDeclarationStructure, PropertySignatureStructure, ts } from "ts-morph"; import { BaseGeneratedType } from "./BaseGeneratedType"; export interface GeneratedObjectType extends BaseGeneratedType { @@ -8,6 +8,8 @@ export interface GeneratedObjectType extends BaseGeneratedType getAllPropertiesIncludingExtensions: ( context: Context ) => { wireKey: string; propertyKey: string; type: TypeReference }[]; + generateInterface(context: Context): InterfaceDeclarationStructure; + generateProperties(context: Context): PropertySignatureStructure[]; getPropertyKey: (args: { propertyWireKey: string }) => string; buildExampleProperties: ( example: ExampleTypeShape, diff --git a/generators/typescript/utils/contexts/src/model-context/type/GeneratedType.ts b/generators/typescript/utils/contexts/src/base-context/type/GeneratedType.ts similarity index 83% rename from generators/typescript/utils/contexts/src/model-context/type/GeneratedType.ts rename to generators/typescript/utils/contexts/src/base-context/type/GeneratedType.ts index 180f96670ad..c56d430872b 100644 --- a/generators/typescript/utils/contexts/src/model-context/type/GeneratedType.ts +++ b/generators/typescript/utils/contexts/src/base-context/type/GeneratedType.ts @@ -1,11 +1,11 @@ -import { ModelContext } from "../ModelContext"; +import { BaseContext } from "../../base-context"; import { GeneratedAliasType } from "./GeneratedAliasType"; import { GeneratedEnumType } from "./GeneratedEnumType"; import { GeneratedObjectType } from "./GeneratedObjectType"; import { GeneratedUndiscriminatedUnionType } from "./GeneratedUndiscriminatedUnionType"; import { GeneratedUnionType } from "./GeneratedUnionType"; -export type GeneratedType = +export type GeneratedType = | GeneratedAliasType | GeneratedEnumType | GeneratedObjectType diff --git a/generators/typescript/utils/contexts/src/model-context/type/GeneratedTypeReferenceExample.ts b/generators/typescript/utils/contexts/src/base-context/type/GeneratedTypeReferenceExample.ts similarity index 53% rename from generators/typescript/utils/contexts/src/model-context/type/GeneratedTypeReferenceExample.ts rename to generators/typescript/utils/contexts/src/base-context/type/GeneratedTypeReferenceExample.ts index 9a2fe5bf073..9df1addf9e8 100644 --- a/generators/typescript/utils/contexts/src/model-context/type/GeneratedTypeReferenceExample.ts +++ b/generators/typescript/utils/contexts/src/base-context/type/GeneratedTypeReferenceExample.ts @@ -1,7 +1,7 @@ import { GetReferenceOpts } from "@fern-typescript/commons"; import { ts } from "ts-morph"; -import { ModelContext } from "../ModelContext"; +import { BaseContext } from "../../base-context"; export interface GeneratedTypeReferenceExample { - build: (context: ModelContext, opts: GetReferenceOpts) => ts.Expression; + build: (context: BaseContext, opts: GetReferenceOpts) => ts.Expression; } diff --git a/generators/typescript/utils/contexts/src/model-context/type/GeneratedUndiscriminatedUnionType.ts b/generators/typescript/utils/contexts/src/base-context/type/GeneratedUndiscriminatedUnionType.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type/GeneratedUndiscriminatedUnionType.ts rename to generators/typescript/utils/contexts/src/base-context/type/GeneratedUndiscriminatedUnionType.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type/GeneratedUnionType.ts b/generators/typescript/utils/contexts/src/base-context/type/GeneratedUnionType.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type/GeneratedUnionType.ts rename to generators/typescript/utils/contexts/src/base-context/type/GeneratedUnionType.ts diff --git a/generators/typescript/utils/contexts/src/model-context/type/TypeContext.ts b/generators/typescript/utils/contexts/src/base-context/type/TypeContext.ts similarity index 70% rename from generators/typescript/utils/contexts/src/model-context/type/TypeContext.ts rename to generators/typescript/utils/contexts/src/base-context/type/TypeContext.ts index 9b5721b019a..0c7af1da023 100644 --- a/generators/typescript/utils/contexts/src/model-context/type/TypeContext.ts +++ b/generators/typescript/utils/contexts/src/base-context/type/TypeContext.ts @@ -1,6 +1,7 @@ import { DeclaredTypeName, ExampleTypeReference, + ObjectProperty, ResolvedTypeReference, TypeDeclaration, TypeId, @@ -13,6 +14,13 @@ import { GeneratedTypeReferenceExample } from "./GeneratedTypeReferenceExample"; export interface TypeContext { getReferenceToType: (typeReference: TypeReference) => TypeReferenceNode; + getReferenceToInlinePropertyType: ( + typeReference: TypeReference, + parentTypeName: string, + propertyName: string + ) => TypeReferenceNode; + getReferenceToInlineAliasType: (typeReference: TypeReference, aliasTypeName: string) => TypeReferenceNode; + getReferenceToTypeForInlineUnion: (typeReference: TypeReference) => TypeReferenceNode; stringify: ( valueToStringify: ts.Expression, valueType: TypeReference, @@ -22,7 +30,7 @@ export interface TypeContext { resolveTypeReference: (typeReference: TypeReference) => ResolvedTypeReference; resolveTypeName: (typeName: DeclaredTypeName) => ResolvedTypeReference; getTypeDeclaration: (typeName: DeclaredTypeName) => TypeDeclaration; - getGeneratedType: (typeName: DeclaredTypeName) => GeneratedType; + getGeneratedType: (typeName: DeclaredTypeName, typeNameOverride?: string) => GeneratedType; getGeneratedTypeById: (typeId: TypeId) => GeneratedType; getGeneratedExample: (example: ExampleTypeReference) => GeneratedTypeReferenceExample; } diff --git a/generators/typescript/utils/contexts/src/model-context/type/index.ts b/generators/typescript/utils/contexts/src/base-context/type/index.ts similarity index 100% rename from generators/typescript/utils/contexts/src/model-context/type/index.ts rename to generators/typescript/utils/contexts/src/base-context/type/index.ts diff --git a/generators/typescript/utils/contexts/src/commons/GeneratedModule.ts b/generators/typescript/utils/contexts/src/commons/GeneratedModule.ts new file mode 100644 index 00000000000..1dc5153afc9 --- /dev/null +++ b/generators/typescript/utils/contexts/src/commons/GeneratedModule.ts @@ -0,0 +1,5 @@ +import { ModuleDeclarationStructure } from "ts-morph"; + +export interface GeneratedModule { + generateModule(context: Context): ModuleDeclarationStructure | undefined; +} diff --git a/generators/typescript/utils/contexts/src/commons/GeneratedStatements.ts b/generators/typescript/utils/contexts/src/commons/GeneratedStatements.ts new file mode 100644 index 00000000000..13fa8fd2834 --- /dev/null +++ b/generators/typescript/utils/contexts/src/commons/GeneratedStatements.ts @@ -0,0 +1,7 @@ +import { StatementStructures, WriterFunction } from "ts-morph"; + +export interface GeneratedStatements { + generateStatements: ( + context: Context + ) => string | WriterFunction | string | WriterFunction | (string | WriterFunction | StatementStructures)[]; +} diff --git a/generators/typescript/utils/contexts/src/commons/GeneratedUnion.ts b/generators/typescript/utils/contexts/src/commons/GeneratedUnion.ts index b5e8a09c5e8..6250bd6355f 100644 --- a/generators/typescript/utils/contexts/src/commons/GeneratedUnion.ts +++ b/generators/typescript/utils/contexts/src/commons/GeneratedUnion.ts @@ -1,7 +1,6 @@ import { ts } from "ts-morph"; -import { GeneratedFile } from "./GeneratedFile"; -export interface GeneratedUnion extends GeneratedFile { +export interface GeneratedUnion { discriminant: string; visitPropertyName: string; getReferenceTo: (context: Context) => ts.TypeNode; diff --git a/generators/typescript/utils/contexts/src/commons/GeneratedUnionInlineMemberNode.ts b/generators/typescript/utils/contexts/src/commons/GeneratedUnionInlineMemberNode.ts new file mode 100644 index 00000000000..19c5d2c7445 --- /dev/null +++ b/generators/typescript/utils/contexts/src/commons/GeneratedUnionInlineMemberNode.ts @@ -0,0 +1,5 @@ +import { ts } from "ts-morph"; + +export interface GeneratedUnionInlineMemberNode { + generateForInlineUnion(context: Context): ts.TypeNode; +} diff --git a/generators/typescript/utils/contexts/src/express-context/ExpressContext.ts b/generators/typescript/utils/contexts/src/express-context/ExpressContext.ts index c6a6e1abcfa..7b4d3785955 100644 --- a/generators/typescript/utils/contexts/src/express-context/ExpressContext.ts +++ b/generators/typescript/utils/contexts/src/express-context/ExpressContext.ts @@ -1,4 +1,4 @@ -import { ModelContext } from "../model-context/ModelContext"; +import { BaseContext } from "../base-context"; import { ExpressEndpointTypeSchemasContext } from "./express-endpoint-type-schemas"; import { ExpressErrorContext } from "./express-error"; import { ExpressErrorSchemaContext } from "./express-error-schema"; @@ -8,7 +8,7 @@ import { ExpressRegisterContext } from "./express-register"; import { ExpressServiceContext } from "./express-service"; import { GenericAPIExpressErrorContext } from "./generic-api-express-error"; -export interface ExpressContext extends ModelContext { +export interface ExpressContext extends BaseContext { expressEndpointTypeSchemas: ExpressEndpointTypeSchemasContext; expressError: ExpressErrorContext; expressErrorSchema: ExpressErrorSchemaContext; diff --git a/generators/typescript/utils/contexts/src/model-context/ModelContext.ts b/generators/typescript/utils/contexts/src/model-context/ModelContext.ts index f4dddef8658..ff3676aed4c 100644 --- a/generators/typescript/utils/contexts/src/model-context/ModelContext.ts +++ b/generators/typescript/utils/contexts/src/model-context/ModelContext.ts @@ -1,9 +1,3 @@ import { BaseContext } from "../base-context"; -import { TypeContext } from "./type"; -import { TypeSchemaContext } from "./type-schema"; -export interface ModelContext extends BaseContext { - type: TypeContext; - typeSchema: TypeSchemaContext; - includeSerdeLayer: boolean; -} +export interface ModelContext extends BaseContext {} diff --git a/generators/typescript/utils/contexts/src/model-context/index.ts b/generators/typescript/utils/contexts/src/model-context/index.ts index e82e43cc427..e1eba561e55 100644 --- a/generators/typescript/utils/contexts/src/model-context/index.ts +++ b/generators/typescript/utils/contexts/src/model-context/index.ts @@ -1,3 +1,4 @@ export { type ModelContext } from "./ModelContext"; -export * from "./type"; -export * from "./type-schema"; + +export * from "../base-context/type"; +export * from "../base-context/type-schema"; diff --git a/generators/typescript/utils/contexts/src/model-context/type/BaseGeneratedType.ts b/generators/typescript/utils/contexts/src/model-context/type/BaseGeneratedType.ts deleted file mode 100644 index 8dd48ce23e3..00000000000 --- a/generators/typescript/utils/contexts/src/model-context/type/BaseGeneratedType.ts +++ /dev/null @@ -1,8 +0,0 @@ -import { ExampleTypeShape } from "@fern-fern/ir-sdk/api"; -import { GetReferenceOpts } from "@fern-typescript/commons"; -import { ts } from "ts-morph"; -import { GeneratedFile } from "../../commons/GeneratedFile"; - -export interface BaseGeneratedType extends GeneratedFile { - buildExample: (example: ExampleTypeShape, context: Context, opts: GetReferenceOpts) => ts.Expression; -} diff --git a/generators/typescript/utils/contexts/src/sdk-context/SdkContext.ts b/generators/typescript/utils/contexts/src/sdk-context/SdkContext.ts index c05084ab1ef..30b31c48c44 100644 --- a/generators/typescript/utils/contexts/src/sdk-context/SdkContext.ts +++ b/generators/typescript/utils/contexts/src/sdk-context/SdkContext.ts @@ -2,7 +2,6 @@ import { FernGeneratorExec } from "@fern-fern/generator-exec-sdk"; import { IntermediateRepresentation } from "@fern-fern/ir-sdk/api"; import { JavaScriptRuntime, NpmPackage } from "@fern-typescript/commons"; import { ts } from "ts-morph"; -import { ModelContext } from "../model-context/ModelContext"; import { EndpointErrorUnionContext } from "./endpoint-error-union"; import { EnvironmentsContext } from "./environments"; import { GenericAPISdkErrorContext } from "./generic-api-sdk-error"; @@ -16,8 +15,9 @@ import { TimeoutSdkErrorContext } from "./timeout-sdk-error"; import { VersionContext } from "./version"; import { GeneratorNotificationService } from "@fern-api/base-generator"; import { Logger } from "@fern-api/logger"; +import { BaseContext } from "../base-context"; -export interface SdkContext extends ModelContext { +export interface SdkContext extends BaseContext { logger: Logger; version: string | undefined; ir: IntermediateRepresentation; diff --git a/generators/typescript/utils/resolvers/package.json b/generators/typescript/utils/resolvers/package.json index 1dfcf57c5ba..a048167788f 100644 --- a/generators/typescript/utils/resolvers/package.json +++ b/generators/typescript/utils/resolvers/package.json @@ -27,7 +27,7 @@ "depcheck": "depcheck" }, "dependencies": { - "@fern-fern/ir-sdk": "53.8.0", + "@fern-fern/ir-sdk": "53.23.0", "@fern-typescript/commons": "workspace:*" }, "devDependencies": { diff --git a/package.json b/package.json index dce7ca97635..d4bfe10df9d 100644 --- a/package.json +++ b/package.json @@ -20,6 +20,7 @@ "lint:eslint:fix": "pnpm lint:eslint --fix", "lint:style": "stylelint 'packages/**/src/**/*.scss' --allow-empty-input --max-warnings 0", "lint:style:fix": "pnpm lint:style --fix", + "lint:staged": "lint-staged", "format": "prettier --write --ignore-unknown --ignore-path ./shared/.prettierignore \"**\"", "format:fix": "pnpm format --ignore-path ./shared/.prettierignore \"**\"", "format:check": "prettier --check --ignore-unknown --ignore-path ./shared/.prettierignore \"**\"", diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/ExampleEndpointFactory.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/ExampleEndpointFactory.ts index f8734c32635..de214f06683 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/ExampleEndpointFactory.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/ExampleEndpointFactory.ts @@ -586,6 +586,7 @@ function convertMultipartRequestToSchema(request: RequestWithExample.Multipart): groupName: undefined, additionalProperties: false, availability: undefined, - source: request.source + source: request.source, + inline: undefined }); } diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/convertSecurityScheme.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/convertSecurityScheme.ts index 5bac4362815..9fe924b0dfe 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/convertSecurityScheme.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/convertSecurityScheme.ts @@ -101,7 +101,8 @@ function getScopes(oauthSecurityScheme: OpenAPIV3.OAuth2SecurityScheme, source: wrapAsNullable: false, groupName: undefined, context: undefined, - source + source, + inline: undefined }); const schema = convertSchemaWithExampleToSchema(schemaWithExample); if (schema.type === "enum") { diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/endpoint/convertParameters.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/endpoint/convertParameters.ts index b0803ca4e08..eba3fb4b241 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/endpoint/convertParameters.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/converters/endpoint/convertParameters.ts @@ -126,7 +126,8 @@ export function convertParameters({ }), description: undefined, availability, - groupName: undefined + groupName: undefined, + inline: undefined }); if ( resolvedParameter.in === "header" && diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/extensions/getFernTypeExtension.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/extensions/getFernTypeExtension.ts index 7555b1183b7..97f9f942c70 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/extensions/getFernTypeExtension.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/openapi/v3/extensions/getFernTypeExtension.ts @@ -247,7 +247,8 @@ export function getSchemaFromFernType({ availability, groupName, encoding: undefined, - example: undefined + example: undefined, + inline: undefined }) : undefined, list: (itemType) => @@ -260,7 +261,8 @@ export function getSchemaFromFernType({ description, availability, groupName, - example: undefined + example: undefined, + inline: undefined }) : undefined, optional: (itemType) => @@ -272,7 +274,8 @@ export function getSchemaFromFernType({ value: itemType, description, availability, - groupName + groupName, + inline: undefined }) : undefined, set: (itemType) => @@ -285,7 +288,8 @@ export function getSchemaFromFernType({ description, availability, groupName, - example: undefined + example: undefined, + inline: undefined }) : undefined, literal: (literal) => diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertAdditionalProperties.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertAdditionalProperties.ts index 790388ebea1..c2da91f6167 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertAdditionalProperties.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertAdditionalProperties.ts @@ -1,3 +1,4 @@ +import { assertNever } from "@fern-api/core-utils"; import { Availability, Encoding, @@ -104,13 +105,21 @@ export function convertAdditionalProperties({ }), groupName: undefined }, - valueSchema: convertSchema( - additionalProperties, - context.options.optionalAdditionalProperties ? wrapAsNullable : false, - context, - [...breadcrumbs, "Value"], - source, - namespace + // Whether a type is inline is usually determined later by checking if a declaration is nested within another declaration, + // however this map is generated from the additionalProperties and thus is inline of the object (depending on the value type), + // so we allways add inline (depending on the value type). + valueSchema: addInline( + convertSchema( + additionalProperties, + context.options.optionalAdditionalProperties ? wrapAsNullable : false, + context, + [...breadcrumbs, "Value"], + source, + namespace, + undefined, + undefined, + undefined + ) ), groupName, example, @@ -118,6 +127,34 @@ export function convertAdditionalProperties({ }); } +function addInline(schema: SchemaWithExample): SchemaWithExample { + switch (schema.type) { + case "array": + case "enum": + case "map": + case "object": + schema.inline = true; + break; + case "literal": + case "primitive": + case "reference": + case "unknown": + break; + case "nullable": + case "optional": + schema.inline = true; + schema.value = addInline(schema.value); + break; + case "oneOf": + schema.value.inline = true; + break; + default: + assertNever(schema); + } + + return schema; +} + export function wrapMap({ nameOverride, generatedName, @@ -158,11 +195,13 @@ export function wrapMap({ value: valueSchema, groupName, encoding, - example + example, + inline: undefined }), description, availability, - groupName + groupName, + inline: undefined }); } return SchemaWithExample.map({ @@ -175,7 +214,8 @@ export function wrapMap({ value: valueSchema, groupName, encoding, - example + example, + inline: undefined }); } diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertArray.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertArray.ts index 8dfb49a657d..3e5acaf1f82 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertArray.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertArray.ts @@ -91,11 +91,13 @@ export function wrapArray({ description, availability, groupName, - example + example, + inline: undefined }), description, availability, - groupName + groupName, + inline: undefined }); } return SchemaWithExample.array({ @@ -106,6 +108,7 @@ export function wrapArray({ description, availability, groupName, - example + example, + inline: undefined }); } diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertDiscriminatedOneOf.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertDiscriminatedOneOf.ts index f36afe84672..c1606ce6d33 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertDiscriminatedOneOf.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertDiscriminatedOneOf.ts @@ -243,12 +243,14 @@ export function wrapDiscriminantedOneOf({ commonProperties: properties, groupName, encoding: undefined, - source + source, + inline: undefined }) ), groupName, description, - availability + availability, + inline: undefined }); } return SchemaWithExample.oneOf( @@ -263,7 +265,8 @@ export function wrapDiscriminantedOneOf({ commonProperties: properties, groupName, encoding: undefined, - source + source, + inline: undefined }) ); } diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertEnum.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertEnum.ts index a46952d5591..2127a32d556 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertEnum.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertEnum.ts @@ -23,7 +23,8 @@ export function convertEnum({ wrapAsNullable, groupName, context, - source + source, + inline }: { nameOverride: string | undefined; generatedName: string; @@ -38,6 +39,7 @@ export function convertEnum({ groupName: SdkGroupName | undefined; context: SchemaParserContext | undefined; source: Source; + inline: boolean | undefined; }): SchemaWithExample { const strippedEnumVarNames = stripCommonPrefix(enumVarNames ?? []); const uniqueValues = new Set(enumValues); @@ -80,7 +82,8 @@ export function convertEnum({ description, availability, groupName, - source + source, + inline }); } @@ -94,7 +97,8 @@ export function wrapEnum({ description, availability, groupName, - source + source, + inline }: { wrapAsNullable: boolean; nameOverride: string | undefined; @@ -106,6 +110,7 @@ export function wrapEnum({ availability: Availability | undefined; groupName: SdkGroupName | undefined; source: Source; + inline: boolean | undefined; }): SchemaWithExample { if (wrapAsNullable) { return SchemaWithExample.nullable({ @@ -122,11 +127,13 @@ export function wrapEnum({ availability, example: undefined, groupName, - source + source, + inline }), description, availability, - groupName + groupName, + inline }); } return SchemaWithExample.enum({ @@ -139,7 +146,8 @@ export function wrapEnum({ default: _default, example: undefined, groupName, - source + source, + inline }); } diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertLiteral.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertLiteral.ts index 341281bf377..3d9c34e4a74 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertLiteral.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertLiteral.ts @@ -46,7 +46,8 @@ export function convertLiteral({ }), description, availability, - groupName + groupName, + inline: undefined }); } return SchemaWithExample.literal({ diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertObject.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertObject.ts index 562df7f040f..aaabbcb1280 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertObject.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertObject.ts @@ -108,7 +108,8 @@ export function convertObject({ value: property.schema, description: undefined, availability: property.availability, - groupName: undefined + groupName: undefined, + inline: undefined }) }; } @@ -195,7 +196,8 @@ export function convertObject({ description: undefined, availability, value: convertSchema(propertySchema, false, context, propertyBreadcrumbs, source, namespace), - groupName + groupName, + inline: undefined }); const conflicts: Record = {}; @@ -304,11 +306,13 @@ export function wrapObject({ fullExamples, additionalProperties: isAdditionalPropertiesAny(additionalProperties), availability: undefined, - source + source, + inline: undefined }), description, availability, - groupName + groupName, + inline: undefined }); } return SchemaWithExample.object({ @@ -323,7 +327,8 @@ export function wrapObject({ fullExamples, additionalProperties: isAdditionalPropertiesAny(additionalProperties), availability, - source + source, + inline: undefined }); } diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertSchemas.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertSchemas.ts index 07de8a6f125..afdf1b27279 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertSchemas.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertSchemas.ts @@ -126,7 +126,8 @@ export function convertReferenceObject( value: referenceSchema, description: undefined, availability: undefined, - groupName: undefined + groupName: undefined, + inline: undefined }); } else { return referenceSchema; @@ -269,7 +270,8 @@ export function convertSchemaObject( wrapAsNullable, groupName, context, - source + source, + inline: undefined }); } @@ -299,7 +301,8 @@ export function convertSchemaObject( ), groupName, description: schema.description, - availability + availability, + inline: undefined }); } else if (secondElement === "null") { return SchemaWithExample.nullable({ @@ -323,7 +326,8 @@ export function convertSchemaObject( ), groupName, description: schema.description, - availability + availability, + inline: undefined }); } } @@ -666,7 +670,8 @@ export function convertSchemaObject( wrapAsNullable, groupName, context, - source + source, + inline: undefined }); } @@ -1000,7 +1005,8 @@ function maybeInjectDescriptionOrGroupName( value: schema.value, description, availability: schema.availability, - groupName + groupName, + inline: undefined }); } else if (schema.type === "nullable") { return SchemaWithExample.nullable({ @@ -1010,7 +1016,8 @@ function maybeInjectDescriptionOrGroupName( value: schema.value, description, availability: schema.availability, - groupName + groupName, + inline: undefined }); } return schema; @@ -1072,7 +1079,8 @@ export function wrapLiteral({ }), groupName, description, - availability + availability, + inline: undefined }); } return SchemaWithExample.literal({ @@ -1122,7 +1130,8 @@ export function wrapPrimitive({ }), groupName, description, - availability + availability, + inline: undefined }); } return SchemaWithExample.primitive({ diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertUndiscriminatedOneOf.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertUndiscriminatedOneOf.ts index 112ffd85f71..2a7392f9cb2 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertUndiscriminatedOneOf.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/convertUndiscriminatedOneOf.ts @@ -132,7 +132,8 @@ export function convertUndiscriminatedOneOf({ _default: undefined, groupName, context, - source + source, + inline: undefined }); } @@ -265,7 +266,8 @@ export function convertUndiscriminatedOneOfWithDiscriminant({ _default: undefined, groupName, context, - source + source, + inline: undefined }); } @@ -384,12 +386,14 @@ export function wrapUndiscriminantedOneOf({ schemas: subtypes, groupName, encoding, - source + source, + inline: undefined }) ), description, availability, - groupName + groupName, + inline: undefined }); } return SchemaWithExample.oneOf( @@ -402,7 +406,8 @@ export function wrapUndiscriminantedOneOf({ schemas: subtypes, groupName, encoding, - source + source, + inline: undefined }) ); } diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/utils/convertSchemaToSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/utils/convertSchemaToSchemaWithExample.ts index 5c15ae4f6d0..09d374a2688 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/utils/convertSchemaToSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/utils/convertSchemaToSchemaWithExample.ts @@ -25,7 +25,8 @@ export function convertSchemaToSchemaWithExample(schema: Schema): SchemaWithExam fullExamples: undefined, additionalProperties: schema.additionalProperties, availability: schema.availability, - source: schema.source + source: schema.source, + inline: undefined }); case "array": return SchemaWithExample.array({ @@ -36,7 +37,8 @@ export function convertSchemaToSchemaWithExample(schema: Schema): SchemaWithExam title: schema.title, nameOverride: schema.nameOverride, groupName: schema.groupName, - example: undefined + example: undefined, + inline: undefined }); case "enum": return SchemaWithExample.enum({ @@ -49,7 +51,8 @@ export function convertSchemaToSchemaWithExample(schema: Schema): SchemaWithExam default: schema.default, groupName: schema.groupName, example: undefined, - source: schema.source + source: schema.source, + inline: undefined }); case "literal": return SchemaWithExample.literal({ @@ -69,7 +72,8 @@ export function convertSchemaToSchemaWithExample(schema: Schema): SchemaWithExam description: schema.description, availability: schema.availability, value: convertSchemaToSchemaWithExample(schema.value), - groupName: schema.groupName + groupName: schema.groupName, + inline: undefined }); case "optional": return SchemaWithExample.optional({ @@ -79,7 +83,8 @@ export function convertSchemaToSchemaWithExample(schema: Schema): SchemaWithExam description: schema.description, availability: schema.availability, value: convertSchemaToSchemaWithExample(schema.value), - groupName: schema.groupName + groupName: schema.groupName, + inline: undefined }); case "primitive": return SchemaWithExample.primitive({ @@ -110,7 +115,8 @@ export function convertSchemaToSchemaWithExample(schema: Schema): SchemaWithExam title: schema.title, groupName: schema.groupName, encoding: schema.encoding, - example: undefined + example: undefined, + inline: undefined }); case "reference": return SchemaWithExample.reference({ @@ -150,7 +156,8 @@ export function convertSchemaWithExampleToOptionalSchema(schema: Schema): Schema description: undefined, availability: undefined, value: convertSchemaToSchemaWithExample(schema), - groupName: undefined + groupName: undefined, + inline: undefined }); case "object": case "array": @@ -167,7 +174,8 @@ export function convertSchemaWithExampleToOptionalSchema(schema: Schema): Schema description: undefined, availability: schema.availability, value: convertSchemaToSchemaWithExample(schema), - groupName: undefined + groupName: undefined, + inline: undefined }); case "optional": return SchemaWithExample.optional({ @@ -177,7 +185,8 @@ export function convertSchemaWithExampleToOptionalSchema(schema: Schema): Schema description: schema.description, availability: schema.availability, value: convertSchemaToSchemaWithExample(schema.value), - groupName: schema.groupName + groupName: schema.groupName, + inline: undefined }); case "oneOf": { const oneOfSchema = convertToOneOf(schema.value); @@ -188,7 +197,8 @@ export function convertSchemaWithExampleToOptionalSchema(schema: Schema): Schema description: oneOfSchema.description, availability: oneOfSchema.availability, value: SchemaWithExample.oneOf(convertToOneOf(schema.value)), - groupName: oneOfSchema.groupName + groupName: oneOfSchema.groupName, + inline: undefined }); } default: @@ -219,7 +229,8 @@ function convertToOneOf(oneOfSchema: OneOfSchema): OneOfSchemaWithExample { ), groupName: oneOfSchema.groupName, encoding: oneOfSchema.encoding, - source: oneOfSchema.source + source: oneOfSchema.source, + inline: undefined }); case "undisciminated": return OneOfSchemaWithExample.undisciminated({ @@ -231,7 +242,8 @@ function convertToOneOf(oneOfSchema: OneOfSchema): OneOfSchemaWithExample { schemas: oneOfSchema.schemas.map((oneOfSchema) => convertSchemaToSchemaWithExample(oneOfSchema)), groupName: oneOfSchema.groupName, encoding: oneOfSchema.encoding, - source: oneOfSchema.source + source: oneOfSchema.source, + inline: undefined }); default: assertNever(oneOfSchema); diff --git a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/utils/convertSchemaWithExampleToSchema.ts b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/utils/convertSchemaWithExampleToSchema.ts index 108ff6b3063..5fbee12bbd0 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/utils/convertSchemaWithExampleToSchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-parser/src/schema/utils/convertSchemaWithExampleToSchema.ts @@ -24,7 +24,8 @@ export function convertSchemaWithExampleToSchema(schema: SchemaWithExample): Sch groupName: schema.groupName, additionalProperties: schema.additionalProperties, availability: schema.availability, - source: schema.source + source: schema.source, + inline: schema.inline }); case "array": return Schema.array({ @@ -34,7 +35,8 @@ export function convertSchemaWithExampleToSchema(schema: SchemaWithExample): Sch generatedName: schema.generatedName, nameOverride: schema.nameOverride, title: schema.title, - groupName: schema.groupName + groupName: schema.groupName, + inline: schema.inline }); case "enum": return Schema.enum({ @@ -46,7 +48,8 @@ export function convertSchemaWithExampleToSchema(schema: SchemaWithExample): Sch values: schema.values, default: schema.default, groupName: schema.groupName, - source: schema.source + source: schema.source, + inline: schema.inline }); case "literal": return Schema.literal({ @@ -66,7 +69,8 @@ export function convertSchemaWithExampleToSchema(schema: SchemaWithExample): Sch description: schema.description, availability: schema.availability, value: convertSchemaWithExampleToSchema(schema.value), - groupName: schema.groupName + groupName: schema.groupName, + inline: schema.inline }); case "optional": return Schema.optional({ @@ -76,7 +80,8 @@ export function convertSchemaWithExampleToSchema(schema: SchemaWithExample): Sch description: schema.description, availability: schema.availability, value: convertSchemaWithExampleToSchema(schema.value), - groupName: schema.groupName + groupName: schema.groupName, + inline: schema.inline }); case "primitive": return Schema.primitive({ @@ -106,7 +111,8 @@ export function convertSchemaWithExampleToSchema(schema: SchemaWithExample): Sch title: schema.title, nameOverride: schema.nameOverride, groupName: schema.groupName, - encoding: schema.encoding + encoding: schema.encoding, + inline: schema.inline }); case "reference": return Schema.reference({ @@ -146,7 +152,8 @@ export function convertSchemaWithExampleToOptionalSchema(schema: SchemaWithExamp description: schema.description, availability: schema.availability, value: convertSchemaWithExampleToSchema(schema), - groupName: schema.groupName + groupName: schema.groupName, + inline: undefined }); case "optional": return Schema.optional({ @@ -156,7 +163,8 @@ export function convertSchemaWithExampleToOptionalSchema(schema: SchemaWithExamp description: schema.description, availability: schema.availability, value: convertSchemaWithExampleToSchema(schema.value), - groupName: schema.groupName + groupName: schema.groupName, + inline: schema.inline }); case "oneOf": { const oneOfSchema = convertToOneOf(schema.value); @@ -167,7 +175,8 @@ export function convertSchemaWithExampleToOptionalSchema(schema: SchemaWithExamp description: oneOfSchema.description, availability: oneOfSchema.availability, value: Schema.oneOf(convertToOneOf(schema.value)), - groupName: oneOfSchema.groupName + groupName: oneOfSchema.groupName, + inline: oneOfSchema.inline }); } default: @@ -198,7 +207,8 @@ function convertToOneOf(oneOfSchema: OneOfSchemaWithExample): OneOfSchema { ), groupName: oneOfSchema.groupName, encoding: oneOfSchema.encoding, - source: oneOfSchema.source + source: oneOfSchema.source, + inline: oneOfSchema.inline }); case "undisciminated": return OneOfSchema.undisciminated({ @@ -210,7 +220,8 @@ function convertToOneOf(oneOfSchema: OneOfSchemaWithExample): OneOfSchema { schemas: oneOfSchema.schemas.map((oneOfSchema) => convertSchemaWithExampleToSchema(oneOfSchema)), groupName: oneOfSchema.groupName, encoding: oneOfSchema.encoding, - source: oneOfSchema.source + source: oneOfSchema.source, + inline: oneOfSchema.inline }); default: assertNever(oneOfSchema); diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/apiture.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/apiture.json index e53655a955b..833115b805e 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/apiture.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/apiture.json @@ -4274,6 +4274,7 @@ This error response may have one of the following `type` values: "viewCards", "manageCards", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4447,6 +4448,7 @@ Account transfers are only allowed between `internal` and `external` accounts. A "external", "outside", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4607,6 +4609,7 @@ Account transfers are only allowed between `internal` and `external` accounts. A "float", "sameDay", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4667,6 +4670,7 @@ Account transfers are only allowed between `internal` and `external` accounts. A "tel", "web", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4889,6 +4893,7 @@ Account transfers are only allowed between `internal` and `external` accounts. A "securityQuestions", "authenticatorToken", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5031,6 +5036,7 @@ Account transfers are only allowed between `internal` and `external` accounts. A "externalTransfer", "billPay", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5157,6 +5163,7 @@ The client can use this value to localize the `items[].time` values to the local "microDeposits", "manual", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5286,6 +5293,7 @@ The client can use this value to localize the `items[].time` values to the local "swiftBicCode", "ibanAccountNumber", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5592,6 +5600,7 @@ The client can use this value to localize the `items[].time` values to the local "loan", "creditCard", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5786,6 +5795,7 @@ The client can use this value to localize the `items[].time` values to the local "credit", "debit", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6008,6 +6018,7 @@ The client can use this value to localize the `items[].time` values to the local "check", "other", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6043,6 +6054,7 @@ The client can use this value to localize the `items[].time` values to the local "debit", "credit", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6206,6 +6218,7 @@ The client can use this value to localize the `items[].time` values to the local "closure", "other", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6349,6 +6362,7 @@ The response may include dates prior to requested the start date, as that is use "semiyearly", "yearly", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6450,6 +6464,7 @@ The response may include dates prior to requested the start date, as that is use "fixed", "variable", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6538,6 +6553,7 @@ For recurring transfer schedules, `endsOn`, `count`, and `amountLimit` are mutua "credit", "both", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6638,6 +6654,7 @@ For recurring transfer schedules, `endsOn`, `count`, and `amountLimit` are mutua "failed", "other", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6687,6 +6704,7 @@ For recurring transfer schedules, `endsOn`, `count`, and `amountLimit` are mutua "domesticWireTransfer", "internationalWireTransfer", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13632,6 +13650,7 @@ Optionally, an agent can access a business customer's ACH accounts when acting o "internal", "external", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/aries.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/aries.json index 7c52fb1a7d7..ad8c91902c0 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/aries.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/aries.json @@ -427,6 +427,7 @@ "value": "present-proof", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -628,6 +629,7 @@ "manual", "auto", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -644,6 +646,7 @@ "value": "didexchange/1.0", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -655,6 +658,7 @@ "multi", "static", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -667,6 +671,7 @@ "active", "error", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -679,6 +684,7 @@ "inviter", "responder", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -865,6 +871,7 @@ "allowed", "disallowed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -875,6 +882,7 @@ "allowed", "disallowed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -885,6 +893,7 @@ "allowed", "disallowed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -895,6 +904,7 @@ "required", "preferred", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -954,6 +964,7 @@ "managed", "unmanaged", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1700,6 +1711,7 @@ "ed25519", "bls12381g2", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1710,6 +1722,7 @@ "ed25519", "bls12381g2", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1721,6 +1734,7 @@ "posted", "wallet_only", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2012,6 +2026,7 @@ "USER", "ROLE_REMOVE", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2428,6 +2443,7 @@ "GE", "GT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2596,6 +2612,7 @@ "value": ">", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2919,6 +2936,7 @@ "value": ">", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3765,6 +3783,7 @@ "add", "remove", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4259,6 +4278,7 @@ "sender", "receiver", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4286,6 +4306,7 @@ "done", "deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4481,6 +4502,7 @@ "value": "goal-code", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5051,6 +5073,7 @@ "TRANSACTION_ENDORSER", "reset", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5062,6 +5085,7 @@ "TRANSACTION_ENDORSER", "reset", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5463,6 +5487,7 @@ "self", "external", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5490,6 +5515,7 @@ "holder", "issuer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5668,6 +5694,7 @@ "self", "external", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5707,6 +5734,7 @@ "prover", "verifier", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5717,6 +5745,7 @@ "true", "false", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6062,6 +6091,7 @@ "self", "external", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6130,6 +6160,7 @@ "issuer", "holder", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6177,6 +6208,7 @@ "abandoned", "deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6680,6 +6712,7 @@ "self", "external", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6715,6 +6748,7 @@ "prover", "verifier", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6750,6 +6784,7 @@ "abandoned", "deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6760,6 +6795,7 @@ "true", "false", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7042,6 +7078,7 @@ "managed", "unmanaged", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7072,6 +7109,7 @@ "required", "preferred", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7082,6 +7120,7 @@ "ISSUANCE_ON_DEMAND", "ISSUANCE_BY_DEFAULT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7116,6 +7155,7 @@ "required", "preferred", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7134,6 +7174,7 @@ "all", "pick", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7394,6 +7435,7 @@ types: - value: present-proof name: PresentProof docs: Attachment type + inline: true source: openapi: ../openapi.yml AttachmentDef: @@ -7464,6 +7506,7 @@ types: - manual - auto docs: 'Connection acceptance: manual or auto' + inline: true source: openapi: ../openapi.yml ConnRecordConnectionProtocol: @@ -7473,6 +7516,7 @@ types: - value: didexchange/1.0 name: Didexchange10 docs: Connection protocol used + inline: true source: openapi: ../openapi.yml ConnRecordInvitationMode: @@ -7481,6 +7525,7 @@ types: - multi - static docs: Invitation mode + inline: true source: openapi: ../openapi.yml ConnRecordRoutingState: @@ -7490,6 +7535,7 @@ types: - active - error docs: Routing state of connection + inline: true source: openapi: ../openapi.yml ConnRecordTheirRole: @@ -7499,6 +7545,7 @@ types: - inviter - responder docs: Their role in the connection protocol + inline: true source: openapi: ../openapi.yml ConnRecord: @@ -7675,6 +7722,7 @@ types: - required - allowed - disallowed + inline: true source: openapi: ../openapi.yml ConstraintsStatusRevoked: @@ -7682,6 +7730,7 @@ types: - required - allowed - disallowed + inline: true source: openapi: ../openapi.yml ConstraintsStatusSuspended: @@ -7689,6 +7738,7 @@ types: - required - allowed - disallowed + inline: true source: openapi: ../openapi.yml ConstraintsSubjectIsIssuer: @@ -7696,6 +7746,7 @@ types: - required - preferred docs: SubjectIsIssuer + inline: true source: openapi: ../openapi.yml Constraints: @@ -7723,6 +7774,7 @@ types: - managed - unmanaged docs: Mode regarding management of wallet key + inline: true source: openapi: ../openapi.yml CreateWalletResponseSettings: @@ -8044,6 +8096,7 @@ types: - ed25519 - bls12381g2 docs: Key type associated with the DID + inline: true source: openapi: ../openapi.yml DidPosture: @@ -8054,6 +8107,7 @@ types: docs: >- Whether DID is current public DID, posted to ledger but not current public DID, or local to the wallet + inline: true source: openapi: ../openapi.yml DID: @@ -8090,6 +8144,7 @@ types: docs: >- Key type to use for the DID keypair. Validated with the chosen DID method's supported key types. + inline: true source: openapi: ../openapi.yml DIDCreateOptions: @@ -8143,6 +8198,7 @@ types: - required - preferred docs: Preference + inline: true source: openapi: ../openapi.yml DIFField: @@ -8167,6 +8223,7 @@ types: - required - preferred docs: Preference + inline: true source: openapi: ../openapi.yml DIFHolder: @@ -8392,6 +8449,7 @@ types: - USER - ROLE_REMOVE docs: Ledger role + inline: true source: openapi: ../openapi.yml GetNymRoleResponse: @@ -8630,6 +8688,7 @@ types: - GE - GT docs: Predicate type + inline: true source: openapi: ../openapi.yml IndyGEProofPred: @@ -8716,6 +8775,7 @@ types: - value: '>' name: GreaterThan docs: Predicate type ('<', '<=', '>=', or '>') + inline: true source: openapi: ../openapi.yml IndyPresPredSpec: @@ -8884,6 +8944,7 @@ types: - value: '>' name: GreaterThan docs: Predicate type ('<', '<=', '>=', or '>') + inline: true source: openapi: ../openapi.yml IndyProofReqPredSpec: @@ -9082,6 +9143,7 @@ types: - ISSUANCE_ON_DEMAND - ISSUANCE_BY_DEFAULT docs: Issuance type + inline: true source: openapi: ../openapi.yml IndyRevRegDefValue: @@ -9428,6 +9490,7 @@ types: - add - remove docs: Action for specific key + inline: true source: openapi: ../openapi.yml KeylistUpdateRule: @@ -9721,6 +9784,7 @@ types: - sender - receiver docs: OOB Role + inline: true source: openapi: ../openapi.yml OobRecordState: @@ -9737,6 +9801,7 @@ types: - done - deleted docs: Out of band message exchange state + inline: true source: openapi: ../openapi.yml OobRecord: @@ -9893,6 +9958,7 @@ types: - value: goal-code name: GoalCode docs: feature type + inline: true source: openapi: ../openapi.yml QueryItem: @@ -10147,6 +10213,7 @@ types: - all - pick docs: Selection + inline: true source: openapi: ../openapi.yml SubmissionRequirements: @@ -10226,6 +10293,7 @@ types: - TRANSACTION_ENDORSER - reset docs: My transaction related job + inline: true source: openapi: ../openapi.yml TransactionJobsTransactionTheirJob: @@ -10234,6 +10302,7 @@ types: - TRANSACTION_ENDORSER - reset docs: Their transaction related job + inline: true source: openapi: ../openapi.yml TransactionJobs: @@ -10381,6 +10450,7 @@ types: - self - external docs: 'Issue-credential exchange initiator: self or external' + inline: true source: openapi: ../openapi.yml V10CredentialExchangeRole: @@ -10388,6 +10458,7 @@ types: - holder - issuer docs: 'Issue-credential exchange role: holder or issuer' + inline: true source: openapi: ../openapi.yml V10CredentialExchange: @@ -10536,6 +10607,7 @@ types: - self - external docs: 'Present-proof exchange initiator: self or external' + inline: true source: openapi: ../openapi.yml V10PresentationExchangeRole: @@ -10543,6 +10615,7 @@ types: - prover - verifier docs: 'Present-proof exchange role: prover or verifier' + inline: true source: openapi: ../openapi.yml V10PresentationExchangeVerified: @@ -10550,6 +10623,7 @@ types: - 'true' - 'false' docs: 'Whether presentation is verified: true or false' + inline: true source: openapi: ../openapi.yml V10PresentationExchange: @@ -10664,6 +10738,7 @@ types: - self - external docs: 'Issue-credential exchange initiator: self or external' + inline: true source: openapi: ../openapi.yml V20CredExRecordRole: @@ -10671,6 +10746,7 @@ types: - issuer - holder docs: 'Issue-credential exchange role: holder or issuer' + inline: true source: openapi: ../openapi.yml V20CredExRecordState: @@ -10697,6 +10773,7 @@ types: - abandoned - deleted docs: Issue-credential exchange state + inline: true source: openapi: ../openapi.yml V20CredExRecord: @@ -11118,6 +11195,7 @@ types: - self - external docs: 'Present-proof exchange initiator: self or external' + inline: true source: openapi: ../openapi.yml V20PresExRecordRole: @@ -11125,6 +11203,7 @@ types: - prover - verifier docs: 'Present-proof exchange role: prover or verifier' + inline: true source: openapi: ../openapi.yml V20PresExRecordState: @@ -11145,6 +11224,7 @@ types: - abandoned - deleted docs: Present-proof exchange state + inline: true source: openapi: ../openapi.yml V20PresExRecordVerified: @@ -11152,6 +11232,7 @@ types: - 'true' - 'false' docs: 'Whether presentation is verified: ''true'' or ''false''' + inline: true source: openapi: ../openapi.yml V20PresExRecord: @@ -11374,6 +11455,7 @@ types: - managed - unmanaged docs: Mode regarding management of wallet key + inline: true source: openapi: ../openapi.yml WalletRecordSettings: @@ -13036,6 +13118,7 @@ docs: Simple messaging "value": "didexchange/1.0", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13052,6 +13135,7 @@ docs: Simple messaging "active", "completed", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13063,6 +13147,7 @@ docs: Simple messaging "inviter", "responder", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16700,6 +16785,7 @@ docs: Feature discovery v2 "TRANSACTION_ENDORSER", "reset", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -18414,6 +18500,7 @@ docs: Introduction of known parties "issuer", "holder", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -18432,6 +18519,7 @@ docs: Introduction of known parties "credential_revoked", "abandoned", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20316,6 +20404,7 @@ types: "issuer", "holder", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20361,6 +20450,7 @@ types: }, "abandoned", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -21702,6 +21792,7 @@ docs: Sign and verify json-ld data "Profile", "LinkedDomains", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -21714,6 +21805,7 @@ docs: Sign and verify json-ld data "NETWORK_MONITOR", "reset", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -22787,6 +22879,7 @@ docs: Interaction with ledger "client", "server", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -22797,6 +22890,7 @@ docs: Interaction with ledger "granted", "denied", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -23724,6 +23818,7 @@ types: "both", "base", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23735,6 +23830,7 @@ types: "ARGON2I_INT", "RAW", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23746,6 +23842,7 @@ types: "in_memory", "indy", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23757,6 +23854,7 @@ types: "both", "base", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23774,6 +23872,7 @@ types: Dispatch only to webhooks associated with this wallet. base - Dispatch only to webhooks associated with the base wallet. both - Dispatch to both webhook targets. + inline: true source: openapi: ../openapi.yml CreateWalletRequestWalletKeyDerivation: @@ -23782,6 +23881,7 @@ types: - ARGON2I_INT - RAW docs: Key derivation + inline: true source: openapi: ../openapi.yml CreateWalletRequestWalletType: @@ -23790,6 +23890,7 @@ types: - in_memory - indy docs: Type of the wallet to create + inline: true source: openapi: ../openapi.yml UpdateWalletRequestWalletDispatchType: @@ -23802,6 +23903,7 @@ types: Dispatch only to webhooks associated with this wallet. base - Dispatch only to webhooks associated with the base wallet. both - Dispatch to both webhook targets. + inline: true source: openapi: ../openapi.yml imports: @@ -25546,6 +25648,7 @@ docs: Out-of-band connections "prover", "verifier", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -25562,6 +25665,7 @@ docs: Out-of-band connections "presentation_acked", "abandoned", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -26906,6 +27010,7 @@ types: "prover", "verifier", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -26939,6 +27044,7 @@ types: "done", "abandoned", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -28633,6 +28739,7 @@ docs: did resolver interface. "active", "full", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -28643,6 +28750,7 @@ docs: did resolver interface. "v1_0", "v2_0", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -28655,6 +28763,7 @@ docs: did resolver interface. "active", "full", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -29406,6 +29515,7 @@ types: - v1_0 - v2_0 docs: Specify which version of the revocation notification should be sent + inline: true source: openapi: ../openapi.yml ", @@ -30609,6 +30719,7 @@ docs: Trust-ping over connection "Profile", "LinkedDomains", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30618,6 +30729,7 @@ docs: Trust-ping over connection "ed25519", "bls12381g2", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -30627,6 +30739,7 @@ docs: Trust-ping over connection "key", "sov", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -30637,6 +30750,7 @@ docs: Trust-ping over connection "posted", "wallet_only", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -30671,6 +30785,7 @@ docs: Trust-ping over connection docs: >- Endpoint type to set (default 'Endpoint'); affects only public or posted DIDs + inline: true source: openapi: ../openapi.yml imports: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/assembly.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/assembly.json index 28cf25bd848..d0ad7a97f3b 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/assembly.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/assembly.json @@ -1294,6 +1294,7 @@ "success", "unavailable", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1737,6 +1738,7 @@ Valid values are in the range [0, 1] inclusive. "value": "us_social_security_number", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1834,6 +1836,7 @@ Can be any value between 0.0 and 1.0 inclusive. "default", "basic", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2009,6 +2012,7 @@ Can be any value between 0.0 and 1.0 inclusive. "drivers_license", "banking_information", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2096,6 +2100,7 @@ Can be any value between 0.0 and 1.0 inclusive. "NEUTRAL", "NEGATIVE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2185,6 +2190,7 @@ Can be any value between 0.0 and 1.0 inclusive. "entity_type", "hash", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2195,6 +2201,7 @@ Can be any value between 0.0 and 1.0 inclusive. "srt", "vtt", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2207,6 +2214,7 @@ Can be any value between 0.0 and 1.0 inclusive. "conversational", "catchy", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2221,6 +2229,7 @@ Can be any value between 0.0 and 1.0 inclusive. "headline", "paragraph", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2554,6 +2563,7 @@ See [Speech recognition](https://www.assemblyai.com/docs/Models/speech_recogniti "default", "high", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2641,6 +2651,7 @@ The default value is 'en_us'. "uk", "vi", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2777,6 +2788,7 @@ The default value is 'en_us'. "value": "error", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6650,6 +6662,7 @@ docs: Real-time transcription "value": "error", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/axle.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/axle.json index c894a317c7d..a70148cc961 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/axle.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/axle.json @@ -87,6 +87,7 @@ "COLL", "COMP", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -184,6 +185,7 @@ "lessor", "interest", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -275,6 +277,7 @@ - UIMPD - COLL - COMP + inline: true source: openapi: ../openapi.yml Coverage: @@ -335,6 +338,7 @@ - lessor - interest default: interest + inline: true source: openapi: ../openapi.yml ThirdParty: @@ -536,6 +540,7 @@ "auto", "motorcycle", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -575,6 +580,7 @@ types: enum: - auto - motorcycle + inline: true source: openapi: ../openapi.yml Policy: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/belvo.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/belvo.json index f53e5699ea0..fa029dd0715 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/belvo.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/belvo.json @@ -6687,6 +6687,7 @@ In our documentation example, we use `{endpoint}` as a placeholder value. In pro "SUCCEEDED", "FAILED", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7781,6 +7782,7 @@ We return one of the following enum values: "INDIVIDUAL", "BUSINESS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -7800,6 +7802,7 @@ We return one of the following enum values: "SAVINGS", "SALARY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -7817,6 +7820,7 @@ Can be either: "LOAN_ACCOUNT", "SAVINGS_ACCOUNT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -7831,6 +7835,7 @@ Can be either: "INDIVIDUAL", "BUSINESS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -7955,6 +7960,7 @@ Can be either: "INFLOW", "OUTFLOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -7968,6 +7974,7 @@ Can be either: "CPF", "CNPJ", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -7984,6 +7991,7 @@ Can be either: "TI", "NIT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8001,6 +8009,7 @@ Can be either: "INDIVIDUAL", "BUSINESS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8015,6 +8024,7 @@ Can be either: "NSS", "CURP", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8026,6 +8036,7 @@ Can be either: "EMPLOYED", "UNEMPLOYED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8048,6 +8059,7 @@ Can be either: "ABSENCE", "SICK_LEAVE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8066,6 +8078,7 @@ You can send through one of the following values: "MEDIUM", "LOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8092,6 +8105,7 @@ We return one of the following enum values: "MEDIUM", "LOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8114,6 +8128,7 @@ We return one of the following enum values: "IRREGULAR", "SINGLE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8146,6 +8161,7 @@ We return one of the following enum values: "DEPOSIT", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8159,6 +8175,7 @@ Can be either: "CHECKING_ACCOUNT", "SAVINGS_ACCOUNT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8186,6 +8203,7 @@ Can be either: "credentials", "openbanking", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8197,6 +8215,7 @@ Can be either: "healthy", "down", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8213,6 +8232,7 @@ Can be either: "fiscal", "employment", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8239,6 +8259,7 @@ We return one of the following values: "PENSION", "STOCK", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8259,6 +8280,7 @@ We return one of the following values: "PENSION", "VARIABLE_INCOME", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8288,6 +8310,7 @@ You can send through one or more of the following values: "DEPOSIT", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8333,6 +8356,7 @@ For Mexico's SAT, we return one of the following values: "Pago", "Traslado", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8363,6 +8387,7 @@ For more information, see our [Links](https://developers.belvo.com/docs/links-an "single", "recurrent", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8404,6 +8429,7 @@ We return one of the following values: "unconfirmed", "token_required", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8420,6 +8446,7 @@ We return one of the following values: "INSURANCE_FEE", "OTHERS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8434,6 +8461,7 @@ We return one of the following values: "MONTHLY", "YEARLY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8444,6 +8472,7 @@ We return one of the following values: "INDIVIDUAL", "BUSINESS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8458,6 +8487,7 @@ We return one of the following values: "PROCESSING", "FAILED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8471,6 +8501,7 @@ We return one of the following values: "open_finance", "pse", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8486,6 +8517,7 @@ We return one of the following values: "belvo", "payments_way", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8501,6 +8533,7 @@ We return one of the following values: "ACTIVE", "INACTIVE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8514,6 +8547,7 @@ We return one of the following values: "INFLOW", "OUTFLOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8529,6 +8563,7 @@ We return one of the following values: "BRA", "COL", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8543,6 +8578,7 @@ We return one of the following values: "BRL", "COP", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8566,6 +8602,7 @@ We return one of the following values: "REVERTED", "UNCATEGORIZED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8615,6 +8652,7 @@ We return one of the following values: }, "Taxes", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8637,6 +8675,7 @@ We return one of the following values: "SUBSCRIPTION", "REGULAR", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8648,6 +8687,7 @@ We return one of the following values: "NEGATIVE", "NO_OBLIGATIONS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8661,6 +8701,7 @@ We return one of the following values: "PAID", "PROVISIONED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8674,6 +8715,7 @@ We return one of the following values: "NATIONAL", "FOREIGN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8688,6 +8730,7 @@ We return one of the following values: "OUTFLOW", "INFLOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -28189,6 +28232,7 @@ types: - FAILED docs: | The current status of the charge. + inline: true source: openapi: ../openapi.yml ChargePaymentMethodDetails: @@ -58602,6 +58646,7 @@ types: "value": "-created_at", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -58611,6 +58656,7 @@ types: "ACTIVE", "INACTIVE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/deel.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/deel.json index e9696a2567f..cb2f0dfb222 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/deel.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/deel.json @@ -7396,6 +7396,7 @@ "client", "contractor", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -7614,6 +7615,7 @@ "rejected", "waiting_for_client_payment", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8042,6 +8044,7 @@ "shield_msa", "hris_direct_employee", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8057,6 +8060,7 @@ "payg_tasks", "payg_milestones", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8068,6 +8072,7 @@ "client", "contractor", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8093,6 +8098,7 @@ "total", "status", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8220,6 +8226,7 @@ "SICK_LEAVE", "OTHER", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8930,6 +8937,7 @@ "STANDARD", "SPECIFIC", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8946,6 +8954,7 @@ "value": "Part-time", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8977,6 +8986,7 @@ "Skilled", "Unskilled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9080,6 +9090,7 @@ "ALLOWED_WITH_MAXIMUM_LIMITATION", "NOT_ALLOWED", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9128,6 +9139,7 @@ "STANDARD", "SPECIFIC", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9330,6 +9342,7 @@ "LIMITED_ROLLOVER", "UNSET", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -9565,6 +9578,7 @@ "CALENDAR_DAYS", "FULL_AMOUNT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9640,6 +9654,7 @@ "value": "image/png", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -9691,6 +9706,7 @@ "CALENDAR_DAYS", "FULL_AMOUNT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9909,6 +9925,7 @@ "ENABLED", "DISABLED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10397,6 +10414,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -10418,6 +10436,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -10623,6 +10642,7 @@ "withholding_tax", "work", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10640,6 +10660,7 @@ "time_off", "vat", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10676,6 +10697,7 @@ "failed", "refunded", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10744,6 +10766,7 @@ "failed", "refunded", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10768,6 +10791,7 @@ "SHIELD_DEPOSIT", "EOR_MANAGEMENT_FEE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10832,6 +10856,7 @@ "individual", "company", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10967,6 +10992,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11005,6 +11031,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11124,6 +11151,7 @@ "value": "tasks:write", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11474,6 +11502,7 @@ "mercury_wire", "bt_pay_pal", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11510,6 +11539,7 @@ "paid", "processing", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11843,6 +11873,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11871,6 +11902,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12084,6 +12116,7 @@ "CALENDAR_DAYS", "FULL_AMOUNT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12097,6 +12130,7 @@ "hris_direct_employee", "service_account", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12231,6 +12265,7 @@ "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12413,6 +12448,7 @@ "APPROVED", "REJECTED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12423,6 +12459,7 @@ "SICK_LEAVE", "OTHER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12537,6 +12574,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12558,6 +12596,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12814,6 +12853,7 @@ "enabled", "disabled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12839,6 +12879,7 @@ "Friday", "Saturday", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12850,6 +12891,7 @@ "DAY_OF_LAST_WEEK", "DAY_OF_MONTH", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12866,6 +12908,7 @@ "value": "calendar-month", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12877,6 +12920,7 @@ "REGULAR", "WITHIN_MONTH", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12892,6 +12936,7 @@ "semimonthly", "custom", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12907,6 +12952,7 @@ "semimonthly", "custom", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -14119,6 +14165,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml TimesheetReviewsToCreate: @@ -14146,6 +14193,7 @@ - approved - declined docs: Review status. + inline: true source: openapi: ../openapi.yml PgoTaskReviewsByIdToCreate: @@ -14163,6 +14211,7 @@ - approved - declined docs: Review status. + inline: true source: openapi: ../openapi.yml PgoTaskReviewsToCreate: @@ -14180,6 +14229,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml TimesheetReviewToCreate: @@ -14487,6 +14537,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml InvoiceAdjustmentReviewsToCreate: @@ -14509,6 +14560,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml InvoiceAdjustmentReviewToCreate: @@ -15090,6 +15142,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml MilestoneReviewsToCreate: @@ -15103,6 +15156,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml MilestoneReviewToCreate: @@ -15137,6 +15191,7 @@ - CALENDAR_DAYS - FULL_AMOUNT docs: Either works days or calendar days + inline: true source: openapi: ../openapi.yml EstimateFirstPaymentCompensationDetails: @@ -15185,6 +15240,7 @@ - CALENDAR_DAYS - FULL_AMOUNT docs: Either works days or calendar days + inline: true source: openapi: ../openapi.yml ProRata: @@ -15520,6 +15576,7 @@ - CALENDAR_DAYS - FULL_AMOUNT docs: Either works days or calendar days + inline: true source: openapi: ../openapi.yml FinalPaymentCalculated: @@ -15775,6 +15832,7 @@ - value: Part-time name: PartTime docs: Is it a full-time contract or a part-time contract? + inline: true source: openapi: ../openapi.yml EorContractToCreateEmploymentTimeOffType: @@ -15785,6 +15843,7 @@ If you want to use standard number of holidays for this employee, choose "STANDARD". If you want to enter a specific number of holidays, choose "SPECIFIC" and enter the number of days in the holidays field. + inline: true source: openapi: ../openapi.yml EorContractToCreateEmployment: @@ -15888,6 +15947,7 @@ - Skilled - Unskilled docs: Type of worker. + inline: true source: openapi: ../openapi.yml EorContractToCreateQuoteAdditionalFields: @@ -16054,6 +16114,7 @@ - PRORATED - STANDARD - SPECIFIC + inline: true source: openapi: ../openapi.yml EorCountryValidationsPartTimeHoliday: @@ -16138,6 +16199,7 @@ - ALLOWED_WITHOUT_LIMITATION - ALLOWED_WITH_MAXIMUM_LIMITATION - NOT_ALLOWED + inline: true source: openapi: ../openapi.yml EorCountryValidationsDefiniteContract: @@ -16497,6 +16559,7 @@ - SICK_LEAVE - OTHER docs: Time off type. + inline: true source: openapi: ../openapi.yml CreateTimeoff: @@ -16588,6 +16651,7 @@ - enabled - disabled docs: Status of webhook. + inline: true source: openapi: ../openapi.yml WebhookItem: @@ -24517,6 +24581,7 @@ docs: The Contracts resource lets you create, amend and, retrieve Deel contracts "CALENDAR_DAYS", "FULL_AMOUNT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -31888,6 +31953,7 @@ docs: >- "enabled", "disabled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31898,6 +31964,7 @@ docs: >- "enabled", "disabled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32157,6 +32224,7 @@ types: - enabled - disabled docs: Status of webhook. + inline: true source: openapi: ../openapi.yml PatchWebhookRequestStatus: @@ -32164,6 +32232,7 @@ types: - enabled - disabled docs: Status of webhook. + inline: true source: openapi: ../openapi.yml ", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/devrev.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/devrev.json index 76ca63cecdd..aa52b714290 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/devrev.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/devrev.json @@ -3910,6 +3910,7 @@ authentication connection. "disable", "enable", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3925,6 +3926,7 @@ for each authentication connection will depend on the type value. "social", "waad", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3981,6 +3983,7 @@ token. Only applicable for application access tokens. "value": "urn:ietf:params:oauth:grant-type:token-exchange", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4025,6 +4028,7 @@ token. Only applicable for application access tokens. "value": "urn:ietf:params:oauth:token-type:jwt", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4036,6 +4040,7 @@ token. Only applicable for application access tokens. "expired", "revoked", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4072,6 +4077,7 @@ token. Only applicable for application access tokens. "value": "urn:ietf:params:oauth:token-type:jwt", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4276,6 +4282,7 @@ authentication connections have different configuration parameters. "samlp", "waad", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4380,6 +4387,7 @@ that can be updated. "samlp", "waad", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4517,6 +4525,7 @@ sort order. If not set, then no prior elements exist. "parse_error", "value_not_permitted", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4884,6 +4893,7 @@ sort order. If not set, then no prior elements exist. "p2", "p3", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4899,6 +4909,7 @@ always be returned in the specified sort-by order. "after", "before", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4943,6 +4954,7 @@ always be returned in the specified sort-by order. "staging", "test", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5032,6 +5044,7 @@ always be returned in the specified sort-by order. "feature", "product", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5559,6 +5572,7 @@ sort order. If not set, then no prior elements exist. "low", "medium", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5596,6 +5610,7 @@ will appear in the response. "snap_kit", "text", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5870,6 +5885,7 @@ default visibility. "shadow", "unassigned", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5897,6 +5913,7 @@ default visibility. "rev_user", "sys_user", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6030,6 +6047,7 @@ be set for other request types. "work_deleted", "work_updated", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6060,6 +6078,7 @@ be set for other request types. "inactive", "unverified", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6111,6 +6130,7 @@ be set for other request types. "activate", "deactivate", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6204,6 +6224,7 @@ event types. Note this is mutually exclusive with 'add' and "issue", "ticket", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/enum-casing.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/enum-casing.json index f672a171260..5cbdda8189b 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/enum-casing.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/enum-casing.json @@ -60,6 +60,7 @@ "success", "failure", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -75,6 +76,7 @@ "value": "urn:ietf:params:oauth:grant-type:token-exchange", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -109,6 +111,7 @@ types: enum: - success - failure + inline: true source: openapi: ../openapi.yml ExampleResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/flagright.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/flagright.json index a680b8cbeb5..673bc9d5613 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/flagright.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/flagright.json @@ -2157,6 +2157,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "GATHERING", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2541,6 +2542,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "RUPAY", "JCB", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2552,6 +2554,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "DEBIT", "PREPAID", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2561,6 +2564,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "VIRTUAL", "PHYSICAL", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2707,6 +2711,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "CLOSED", "HIT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2719,6 +2724,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "DOCUMENTS_COLLECTED", "OTHER", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2766,6 +2772,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "REFUND", "DECLINED", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2841,6 +2848,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "LARGE", "UNKNOWN", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3231,6 +3239,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "value": "N/A", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3511,6 +3520,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "ZMW", "ZWL", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3910,6 +3920,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "IN_PROGRESS", "MANUAL_REVIEW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4105,6 +4116,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "IP_ADDRESS", "STRING", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4115,6 +4127,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "BLACKLIST", "FLAGRIGHT_LIBRARY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4172,6 +4185,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "BusinessPayment", "PromotionPayment", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4211,6 +4225,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "WALLET", "CHECK", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4308,6 +4323,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "LOW", "VERY_LOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4341,6 +4357,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "BLOCK", "SUSPEND", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4379,6 +4396,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "ORIGIN", "DESTINATION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4410,6 +4428,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "SANCTIONS_PEP", "SANCTIONS_PEP_ADVERSE_MEDIA", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4421,6 +4440,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "CTF", "SCREENING", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4525,6 +4545,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "PAYMENT_BENEFICIARY_NAME", "BANK_NAME", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4790,6 +4811,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "REFUNDED", "SUCCESSFUL", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4803,6 +4825,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "REFUND", "OTHER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5085,6 +5108,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "F", "NB", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5154,6 +5178,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "RETAIL", "PROFESSIONAL", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5163,6 +5188,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "REGISTERED", "UNREGISTERED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5180,6 +5206,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "SUSPENDED", "BLOCKED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5290,6 +5317,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "USER_STATE_UPDATED", "ALERT_CLOSED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5381,6 +5409,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu enum: - RETAIL - PROFESSIONAL + inline: true source: openapi: ../openapi.yml UserOptional: @@ -5937,6 +5966,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - F - NB docs: Gender of the individual - Male, Female or Non-Binary + inline: true source: openapi: ../openapi.yml UserDetails: @@ -5973,6 +6003,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - LARGE - UNKNOWN docs: Segmentation of the business user + inline: true source: openapi: ../openapi.yml CompanyGeneralDetails: @@ -6139,6 +6170,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - RUPAY - JCB docs: Brand of Card + inline: true source: openapi: ../openapi.yml CardDetailsCardFunding: @@ -6147,12 +6179,14 @@ In order to make individual events retrievable, you also need to pass in a uniqu - DEBIT - PREPAID docs: Funding of Card + inline: true source: openapi: ../openapi.yml CardDetailsCardType: enum: - VIRTUAL - PHYSICAL + inline: true source: openapi: ../openapi.yml CardDetails: @@ -6334,6 +6368,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - BusinessPayment - PromotionPayment docs: Type of transaction + inline: true source: openapi: ../openapi.yml MpesaDetails: @@ -6496,6 +6531,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - CLOSED - HIT docs: Status of a case. E.g. Open, Closed etc. + inline: true source: openapi: ../openapi.yml CaseManagementEventCaseStatusReason: @@ -6507,6 +6543,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu docs: >- Case status reason. E.g. Closed & False Positive, Closed & Investigation Completed etc. + inline: true source: openapi: ../openapi.yml CaseManagementEvent: @@ -6872,6 +6909,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - CANCELED - REFUND - DECLINED + inline: true source: openapi: ../openapi.yml CheckDetails: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/flexport.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/flexport.json index 7e7d2119f2d..29bcb63a483 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/flexport.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/flexport.json @@ -1052,6 +1052,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1425,6 +1426,7 @@ "requoted_quote", "archived_quote", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1464,6 +1466,7 @@ "booked", "shipment", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1561,6 +1564,7 @@ "contained_in_equipment", "contained_in_battery_powered_vehicles", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1634,6 +1638,7 @@ "reviewed", "complete", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2034,6 +2039,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2131,6 +2137,7 @@ "contained_in_equipment", "contained_in_battery_powered_vehicles", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2380,6 +2387,7 @@ "DAP", "DDP", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2392,6 +2400,7 @@ "sub_line", "component_line", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2429,6 +2438,7 @@ "gross_volume", "volume_weight", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2441,6 +2451,7 @@ "truck", "rail", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2584,6 +2595,7 @@ "YD", "Z3", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2647,6 +2659,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2764,6 +2777,7 @@ "freight_collect", "freight_prepaid", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2783,6 +2797,7 @@ "DAP", "DDP", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2797,6 +2812,7 @@ "delivery_order", "work_order", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2808,6 +2824,7 @@ "high", "standard", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2820,6 +2837,7 @@ "cancelled", "closed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2832,6 +2850,7 @@ "truck", "rail", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2891,6 +2910,7 @@ "buyers_agent", "sellers_agent", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2937,6 +2957,7 @@ "icao", "us_cbp", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3026,6 +3047,7 @@ "prs", "dpr", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3057,6 +3079,7 @@ "collect", "prepaid", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3172,6 +3195,7 @@ "customs_hold", "pending", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3222,6 +3246,7 @@ "km", "mi", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3430,6 +3455,7 @@ "terminal", "unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3462,6 +3488,7 @@ "door_to_door", "door_to_port", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3656,6 +3683,7 @@ "additional", "capital", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3711,6 +3739,7 @@ "paid", "payment_pending", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3721,6 +3750,7 @@ "Shipment", "Client", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3817,6 +3847,7 @@ "cm", "in", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3827,6 +3858,7 @@ "cm", "in", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3864,6 +3896,7 @@ "gross_volume", "volume_weight", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4219,6 +4252,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4356,6 +4390,7 @@ "buyers_agent", "sellers_agent", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4423,6 +4458,7 @@ "value": "/ocean/port", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4707,6 +4743,7 @@ "freight_collect", "freight_prepaid", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4726,6 +4763,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4858,6 +4896,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4883,6 +4922,7 @@ "sub_line", "component_line", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4962,6 +5002,7 @@ "W", "X", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4975,6 +5016,7 @@ "delivery_order", "work_order", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4984,6 +5026,7 @@ "standard", "high", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5080,6 +5123,7 @@ "closed", "cancelled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5350,6 +5394,7 @@ "fifty_three_ft", "fifty_three_ft_hc", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5367,6 +5412,7 @@ "bulk", "special", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5398,6 +5444,7 @@ "not_applicable", "misflagged", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5455,6 +5502,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5584,6 +5632,7 @@ "standard", "high", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5643,6 +5692,7 @@ "gated_out", "final_destination", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5772,6 +5822,7 @@ "truck_intl", "warehouse_storage", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5797,6 +5848,7 @@ "collect", "prepaid", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5823,6 +5875,7 @@ "drayage", "cartage", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5884,6 +5937,7 @@ "cbm", "cbft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5946,6 +6000,7 @@ "kg", "lbs", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6585,6 +6640,7 @@ - cbm - cbft docs: unit of measurement. "cbm" for cubic meters. "cbft" for cubic feet. + inline: true source: openapi: ../openapi.yml VolumeCreate: @@ -6602,6 +6658,7 @@ - kg - lbs docs: Required. Unit of measurement. "kg" for kilograms, "lbs" for pounds + inline: true source: openapi: ../openapi.yml WeightCreate: @@ -6619,6 +6676,7 @@ - cm - in docs: Required. Unit of measurement. "cm" for centimeters. "in" for inches. + inline: true source: openapi: ../openapi.yml LengthCreate: @@ -6666,6 +6724,7 @@ - packed_with_equipment - contained_in_equipment - contained_in_battery_powered_vehicles + inline: true source: openapi: ../openapi.yml CreateCargo: @@ -6836,6 +6895,7 @@ - cm - in docs: Required. Unit of measurement. "cm" for centimeters. "in" for inches. + inline: true source: openapi: ../openapi.yml Length: @@ -6893,6 +6953,7 @@ - packed_with_equipment - contained_in_equipment - contained_in_battery_powered_vehicles + inline: true source: openapi: ../openapi.yml Cargo: @@ -7136,6 +7197,7 @@ - value: /ocean/port name: OceanPort docs: Type of the object + inline: true source: openapi: ../openapi.yml Placeport: @@ -7213,6 +7275,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml OceanBookingDetail: @@ -7244,6 +7307,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml AirBookingDetail: @@ -7263,6 +7327,7 @@ enum: - collect - prepaid + inline: true source: openapi: ../openapi.yml TruckingBookingDetail: @@ -7296,6 +7361,7 @@ - submitted - booked - shipment + inline: true source: openapi: ../openapi.yml BookingQuoteStatus: @@ -7310,6 +7376,7 @@ - rejected_quote - requoted_quote - archived_quote + inline: true source: openapi: ../openapi.yml Booking: @@ -7398,6 +7465,7 @@ - DDP - DPU docs: Always required. The Incoterm of your shipment + inline: true source: openapi: ../openapi.yml CreateOceanBooking: @@ -7462,6 +7530,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml CreateAirBooking: @@ -7545,6 +7614,7 @@ docs: >- Whether the shipper or consignee is responsible for payment of trucking freight. This can be `collect` (consignee) or `prepaid` (shipper). + inline: true source: openapi: ../openapi.yml CreateTruckingBooking: @@ -7570,6 +7640,7 @@ - km - mi docs: Required. Unit of measurement. "km" for kilometers. "mi" for miles. + inline: true source: openapi: ../openapi.yml DistanceCreate: @@ -7706,6 +7777,7 @@ Status about if the digitization process for this commercial invoice is complete. If it is not complete, then the commercial invoice should be considered a draft that can change. + inline: true source: openapi: ../openapi.yml CommercialInvoice: @@ -7770,6 +7842,7 @@ - prs - dpr docs: Required. Unit of measurement. + inline: true source: openapi: ../openapi.yml CreateQuantity: @@ -7823,6 +7896,7 @@ - customs_hold - pending docs: The release status for this entry. + inline: true source: openapi: ../openapi.yml CustomsEntry: @@ -8008,6 +8082,7 @@ - denied - not_applicable - misflagged + inline: true source: openapi: ../openapi.yml ShipmentDangerousGoods: @@ -8160,6 +8235,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml ShipmentPriority: @@ -8167,6 +8243,7 @@ - standard - high docs: The level of attention Flexport should give to this shipment + inline: true source: openapi: ../openapi.yml Shipment: @@ -8435,6 +8512,7 @@ - ftl - drayage - cartage + inline: true source: openapi: ../openapi.yml TruckingShipmentLeg: @@ -8523,6 +8601,7 @@ - ventilated - bulk - special + inline: true source: openapi: ../openapi.yml ShipmentContainerContainerSize: @@ -8533,6 +8612,7 @@ - fourty_five_ft_hc - fifty_three_ft - fifty_three_ft_hc + inline: true source: openapi: ../openapi.yml ShipmentContainer: @@ -8590,6 +8670,7 @@ - terminal - unknown docs: The main reason for the exception as an identifier. + inline: true source: openapi: ../openapi.yml Exception: @@ -8683,6 +8764,7 @@ - additional - capital docs: Category of the charge. + inline: true source: openapi: ../openapi.yml InvoiceItem: @@ -8736,6 +8818,7 @@ - paid - payment_pending docs: Status of the invoice + inline: true source: openapi: ../openapi.yml InvoiceType: @@ -8745,6 +8828,7 @@ docs: >- What the invoice is being issued for. Shipment related charges are type `Shipment` and non-shipment related charges are type `Client` + inline: true source: openapi: ../openapi.yml Invoice: @@ -8990,6 +9074,7 @@ - gross_volume - volume_weight docs: The type of measure + inline: true source: openapi: ../openapi.yml LineItemMeasurement: @@ -9011,6 +9096,7 @@ - sub_line - component_line default: main_line + inline: true source: openapi: ../openapi.yml PurchaseOrderLineItemIncoterm: @@ -9027,6 +9113,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml PurchaseOrderLineItemUnitOfMeasure: @@ -9076,6 +9163,7 @@ - TDWB - W - X + inline: true source: openapi: ../openapi.yml PurchaseOrderLineItem: @@ -9140,6 +9228,7 @@ - buyers_agent - sellers_agent docs: The role that the party has + inline: true source: openapi: ../openapi.yml PartiesContactsItem: @@ -9201,6 +9290,7 @@ because they've finished shipping), while Cancelled POs denote POs that were mistakenly uploaded or that should not be used. default: open + inline: true source: openapi: ../openapi.yml PurchaseOrderIncoterm: @@ -9217,6 +9307,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml PurchaseOrderOrderClass: @@ -9227,18 +9318,21 @@ - delivery_order - work_order docs: Class of the purchase order. + inline: true source: openapi: ../openapi.yml PurchaseOrderFreightPaymnetTerms: enum: - freight_collect - freight_prepaid + inline: true source: openapi: ../openapi.yml PurchaseOrderPriority: enum: - standard - high + inline: true source: openapi: ../openapi.yml PurchaseOrder: @@ -9317,6 +9411,7 @@ - buyers_agent - sellers_agent docs: The role that the party has + inline: true source: openapi: ../openapi.yml CreatePartyContactsItem: @@ -9364,6 +9459,7 @@ - icao - us_cbp docs: The code type of the port + inline: true source: openapi: ../openapi.yml CreatePurchaseOrderPort: @@ -9449,6 +9545,7 @@ - gross_volume - volume_weight docs: The type of measure + inline: true source: openapi: ../openapi.yml CreateLineItemMeasurement: @@ -9474,6 +9571,7 @@ - truck - rail docs: Required if there is no transportation_mode in purchase order + inline: true source: openapi: ../openapi.yml CreateLineItemIncoterm: @@ -9492,6 +9590,7 @@ docs: >- Required if there is no incoterm in the line item's purchase order. The Incoterm of your line item. + inline: true source: openapi: ../openapi.yml CreateLineItemLineType: @@ -9501,6 +9600,7 @@ - component_line docs: type of the line item default: main_line + inline: true source: openapi: ../openapi.yml CreateLineItemUnitOfMeasure: @@ -9633,6 +9733,7 @@ - Z3 docs: The measurement per unit for this line item. default: EA + inline: true source: openapi: ../openapi.yml CreateLineItem: @@ -9731,6 +9832,7 @@ because they've finished shipping), while Cancelled POs denote POs that were mistakenly uploaded or that should not be used default: open + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrderFreightPaymentTerms: @@ -9738,6 +9840,7 @@ - freight_collect - freight_prepaid docs: The freight payment term for the purchase order + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrderTransportationMode: @@ -9747,6 +9850,7 @@ - truck - rail docs: Required if there is no transportation_mode in purchase order + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrderIncoterm: @@ -9765,6 +9869,7 @@ docs: >- Required if there is no incoterm in each line item. The incoterm of your purchase order. + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrderPriority: @@ -9773,6 +9878,7 @@ - standard docs: priority of the purchase order. default: standard + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrderOrderClass: @@ -9784,6 +9890,7 @@ - work_order docs: Class of the purchase order. default: purchase_order + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrder: @@ -11518,6 +11625,7 @@ errors: "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11527,6 +11635,7 @@ errors: "booked", "submitted", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11536,6 +11645,7 @@ errors: "cargo_ready_date", "created_at", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11573,6 +11683,7 @@ errors: "no", "notsure", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11626,6 +11737,7 @@ errors: contain goods subject to export control regulations? Export Control Regulations include dual use item control, Hong Kong strategic commodity control, US and EU export control, etc. + inline: true source: openapi: ../openapi.yml BookingCreateResponse: @@ -13366,6 +13478,7 @@ docs: >- "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13799,6 +13912,7 @@ docs: >- "belly_freighter", "unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13811,6 +13925,7 @@ docs: >- "truck", "rail", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13826,6 +13941,7 @@ docs: >- "airport_transfer", "air_cartage", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13844,6 +13960,7 @@ docs: >- `truck`, or `rail`. If `transportation_mode` is `truck`, `ocean`, or `rail`, `country_code` in both `origin_address` and `destination_address` is required. + inline: true source: openapi: ../openapi.yml CreateCarbonCalculationFlightType: @@ -13855,6 +13972,7 @@ docs: >- For `transportation_mode: air`, the type of plane used. One of `freighter`, `belly_freighter`, or `unknown`. Defaults to `unknown`. default: unknown + inline: true source: openapi: ../openapi.yml CreateCarbonCalculationTruckingServiceType: @@ -13870,6 +13988,7 @@ docs: >- For `transportation_mode: truck`, the type of service used. One of `ftl`, `ltl`, `drayage`, `cartage`, `last_mile`, `airport_transfer`, or `air_cartage`. + inline: true source: openapi: ../openapi.yml CarbonCalculationCreateResponse: @@ -19886,6 +20005,7 @@ docs: Endpoints relating to Document objects "value": "/shipment_leg", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20781,6 +20901,7 @@ Other details about this invoice", "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20792,6 +20913,7 @@ Other details about this invoice", "void", "paid", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -22385,6 +22507,7 @@ docs: Endpoints relating to Location objects "roadport", "seaport", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -24398,6 +24521,7 @@ docs: Endpoints relating to Product objects "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -24417,6 +24541,7 @@ docs: Endpoints relating to Product objects "buyers_agent", "sellers_agent", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -24427,6 +24552,7 @@ docs: Endpoints relating to Product objects "closed", "cancelled", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -25649,6 +25775,7 @@ docs: >- "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -27176,6 +27303,7 @@ docs: >- "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -27189,6 +27317,7 @@ docs: >- "updated_at", "archived_at", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hathora.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hathora.json index c4e0482b4e0..88fb55154ff 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hathora.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hathora.json @@ -1126,6 +1126,7 @@ "succeeded", "failed", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1260,6 +1261,7 @@ "public", "local", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1271,6 +1273,7 @@ "rate_egress", "total_egress", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1312,6 +1315,7 @@ "medium", "large", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1390,6 +1394,7 @@ "Sydney", "Sao_Paulo", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1430,6 +1435,7 @@ "suspended", "destroyed", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1461,6 +1467,7 @@ "udp", "tls", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2109,6 +2116,7 @@ types: - running - succeeded - failed + inline: true source: openapi: ../openapi.json Build: @@ -2139,6 +2147,7 @@ types: - private - public - local + inline: true source: openapi: ../openapi.json Lobby: @@ -4482,6 +4491,7 @@ service: "private", "local", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4818,6 +4828,7 @@ types: - public - private - local + inline: true source: openapi: ../openapi.json ", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hookdeck.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hookdeck.json index a5abcd54a1c..5ddbed65787 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hookdeck.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hookdeck.json @@ -2488,6 +2488,7 @@ "each_attempt", "last_attempt", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2566,6 +2567,7 @@ "SOCKET_CLOSED", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2578,6 +2580,7 @@ "COMPLETED", "HOLD", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2590,6 +2593,7 @@ "SUCCESSFUL", "HOLD", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2603,6 +2607,7 @@ "UNPAUSE", "AUTOMATIC", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2890,6 +2895,7 @@ "info", "debug", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3142,6 +3148,7 @@ "minute", "hour", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3417,6 +3424,7 @@ "SUCCESSFUL", "FAILED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3441,6 +3449,7 @@ "path", "query", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3462,6 +3471,7 @@ "sha256", "sha512", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3484,6 +3494,7 @@ "base64", "hex", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3512,6 +3523,7 @@ "TRANSFORMATION_FAILED", "CLI_DISCONNECTED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3605,6 +3617,7 @@ "HANDSHAKE", "POLLING", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3651,6 +3664,7 @@ "pipedrive", "sendgrid", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3690,6 +3704,7 @@ "ACKNOWLEDGED", "RESOLVED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3872,6 +3887,7 @@ "first_attempt", "final_attempt", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3910,6 +3926,7 @@ "transformation", "backpressure", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3945,6 +3962,7 @@ "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4101,6 +4119,7 @@ "NORMAL", "LOW", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4129,6 +4148,7 @@ "INGESTION_FATAL", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4179,6 +4199,7 @@ "linear", "exponential", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4313,6 +4334,7 @@ "minute", "second", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4499,6 +4521,7 @@ "value": "event.successful", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4645,6 +4668,7 @@ "error", "fatal", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -7060,6 +7084,7 @@ types: enum: - base64 - hex + inline: true source: openapi: ../openapi.yml HmacIntegrationConfigs: @@ -7091,6 +7116,7 @@ types: enum: - minute - second + inline: true source: openapi: ../openapi.yml ShopifyIntegrationConfigs: @@ -7263,6 +7289,7 @@ types: - warn - info - debug + inline: true source: openapi: ../openapi.yml ConsoleLine: @@ -7456,6 +7483,7 @@ types: - NORMAL - LOW docs: The priority attributed to the request when received + inline: true source: openapi: ../openapi.yml RequestDataParsedQueryOne: @@ -8792,6 +8820,7 @@ docs: An attempt is any request that Hookdeck makes on behalf of an event. "http", "cli", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8811,6 +8840,7 @@ docs: An attempt is any request that Hookdeck makes on behalf of an event. - http - cli docs: Bookmark target + inline: true source: openapi: ../openapi.yml imports: @@ -11957,6 +11987,7 @@ docs: '' "accepted", "rejected", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11998,6 +12029,7 @@ docs: '' enum: - accepted - rejected + inline: true source: openapi: ../openapi.yml CreateRequestBulkRetryRequestQueryRejectionCauseAny: @@ -13585,6 +13617,7 @@ docs: '' "minute", "hour", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13710,6 +13743,7 @@ docs: '' "minute", "hour", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13773,6 +13807,7 @@ docs: '' - minute - hour docs: Period to rate limit attempts + inline: true source: openapi: ../openapi.yml CreateConnectionRequestDestination: @@ -13834,6 +13869,7 @@ docs: '' - minute - hour docs: Period to rate limit attempts + inline: true source: openapi: ../openapi.yml UpsertConnectionRequestDestination: @@ -15161,6 +15197,7 @@ docs: >- "minute", "hour", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15183,6 +15220,7 @@ docs: >- "minute", "hour", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15194,6 +15232,7 @@ docs: >- "minute", "hour", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15214,6 +15253,7 @@ docs: >- - minute - hour docs: Period to rate limit attempts + inline: true source: openapi: ../openapi.yml UpsertDestinationRequestRateLimitPeriod: @@ -15222,6 +15262,7 @@ docs: >- - minute - hour docs: Period to rate limit attempts + inline: true source: openapi: ../openapi.yml UpdateDestinationRequestRateLimitPeriod: @@ -15230,6 +15271,7 @@ docs: >- - minute - hour docs: Period to rate limit attempts + inline: true source: openapi: ../openapi.yml imports: @@ -18470,6 +18512,7 @@ docs: >- "ACKNOWLEDGED", "RESOLVED", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18528,6 +18571,7 @@ docs: >- - ACKNOWLEDGED - RESOLVED docs: New status + inline: true source: openapi: ../openapi.yml imports: @@ -19577,6 +19621,7 @@ docs: Notifications let your team receive alerts anytime an issue changes. "accepted", "rejected", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/humanloop.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/humanloop.json index 3776a029cf4..02e49b11501 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/humanloop.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/humanloop.json @@ -864,6 +864,7 @@ in the Evaluation Report.", "system", "tool", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1206,6 +1207,7 @@ in the inheriting classes with documentation and appropriate Field definitions." "default", "other", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1422,6 +1424,7 @@ function.", "cancelled", "failed", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1483,6 +1486,7 @@ function.", "target_free", "target_required", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1629,6 +1633,7 @@ function.", "boolean", "number", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1641,6 +1646,7 @@ function.", "text", "number", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1652,6 +1658,7 @@ function.", "active", "inactive", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1728,6 +1735,7 @@ function.", "correction", "comment", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1913,6 +1921,7 @@ function.", "low", "auto", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1974,6 +1983,7 @@ Used by a File's PAPV (Positive Action Per View) metric.", "neutral", "unset", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2559,6 +2569,7 @@ Does not have things like the signature or setup schema.", "chat", "edit", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2577,6 +2588,7 @@ Does not have things like the signature or setup schema.", "google", "groq", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2631,6 +2643,7 @@ Does not have things like the signature or setup schema.", "active", "inactive", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2697,6 +2710,7 @@ Observability is implemented by running monitoring Evaluators on Logs.", "completed", "failed", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2804,6 +2818,7 @@ Observability is implemented by running monitoring Evaluators on Logs.", "supportadmin", "user", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2815,6 +2830,7 @@ Observability is implemented by running monitoring Evaluators on Logs.", "updated_at", "name", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3481,6 +3497,7 @@ Observability is implemented by running monitoring Evaluators on Logs.", "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3539,6 +3556,7 @@ Observability is implemented by running monitoring Evaluators on Logs.", "week", "month", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3823,6 +3841,7 @@ V4 uses organization and inline. Those are deprecated and will be removed in fav "organization", "inline", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3866,6 +3885,7 @@ V4 uses organization and inline. Those are deprecated and will be removed in fav "json_schema", "get_api_call", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3877,6 +3897,7 @@ V4 uses organization and inline. Those are deprecated and will be removed in fav "add", "remove", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4060,6 +4081,7 @@ V4 uses organization and inline. Those are deprecated and will be removed in fav "committed", "deleted", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5267,6 +5289,7 @@ types: Specify the detail level of the image provided to the model. For more details see: https://platform.openai.com/docs/guides/vision/low-or-high-fidelity-image-understanding + inline: true source: openapi: ../openapi.yml ImageUrl: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hume.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hume.json index 85e3504dc4d..525c50ba481 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hume.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/hume.json @@ -255,6 +255,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "tr", "uk", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, @@ -353,6 +354,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, @@ -555,6 +557,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "utterance", "conversational_turn", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, @@ -1068,6 +1071,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "started", "ended", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, @@ -1190,6 +1194,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "COMPLETED", "FAILED", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, @@ -1270,6 +1275,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "created_before", "created_after", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/inline-path-parameters.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/inline-path-parameters.json index 8a25286f6d0..80bde1edcc0 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/inline-path-parameters.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/inline-path-parameters.json @@ -213,6 +213,7 @@ types: "private", "public", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -235,6 +236,7 @@ types: - private - public docs: Access level + inline: true source: openapi: ../openapi.yml SearchResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/intercom.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/intercom.json index 4593cee2110..dac6ff60561 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/intercom.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/intercom.json @@ -4042,6 +4042,7 @@ "upfront_email_collection_change", "welcome_message_change", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4279,6 +4280,7 @@ "comment", "note", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4320,6 +4322,7 @@ "note", "quick_reply", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4477,6 +4480,7 @@ "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4730,6 +4734,7 @@ "admin", "team", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5735,6 +5740,7 @@ "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5880,6 +5886,7 @@ }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5922,7 +5929,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6636,6 +6643,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul }, "Unstable", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6692,6 +6700,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "ticket", "conversation", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6718,6 +6727,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "AND", "OR", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6788,6 +6798,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "draft", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6914,6 +6925,7 @@ Their responses are likely to contain a pages object that hosts pagination links "value": "conversation.list", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7175,6 +7187,7 @@ Their responses are likely to contain a pages object that hosts pagination links "value": "~", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7216,6 +7229,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "cancelled", "active", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7418,7 +7432,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7495,6 +7509,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "team", "user", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7571,6 +7586,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "comment", "quick_reply", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7583,7 +7599,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7814,6 +7830,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7865,6 +7882,7 @@ You can copy the `icon` property for your ticket type from [Twemoji Cheatsheet]( }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -10497,6 +10515,7 @@ types: - temporary_expectation_change - upfront_email_collection_change - welcome_message_change + inline: true source: openapi: ../openapi.yml ActivityLog: @@ -10617,6 +10636,7 @@ types: enum: - comment - note + inline: true source: openapi: ../openapi.yml AdminReplyConversationRequest: @@ -10654,6 +10674,7 @@ types: - comment - note - quick_reply + inline: true source: openapi: ../openapi.yml AdminReplyTicketRequestReplyOptionsItem: @@ -10796,6 +10817,7 @@ types: - published - draft docs: Whether the article is `published` or is a `draft` . + inline: true source: openapi: ../openapi.yml ArticleContent: @@ -11003,6 +11025,7 @@ types: enum: - admin - team + inline: true source: openapi: ../openapi.yml AssignConversationRequest: @@ -11784,6 +11807,7 @@ types: Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + inline: true source: openapi: ../openapi.yml CreateArticleRequest: @@ -11911,6 +11935,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml CreateTicketTypeRequest: @@ -11972,6 +11997,7 @@ types: - type: optional source: openapi: ../openapi.yml + inline: true CustomAttributes: type: map docs: >- @@ -12492,6 +12518,7 @@ types: - ticket - conversation docs: ticket or conversation + inline: true source: openapi: ../openapi.yml LinkedObject: @@ -12532,6 +12559,7 @@ types: - AND - OR docs: An operator to allow boolean inspection between multiple fields. + inline: true source: openapi: ../openapi.yml MultipleFilterSearchRequestValue: @@ -12561,6 +12589,7 @@ types: docs: >- News items will not be visible to your users in the assigned newsfeeds until they are set live. + inline: true source: openapi: ../openapi.yml NewsItemRequest: @@ -12660,6 +12689,7 @@ types: - value: conversation.list name: ConversationList docs: The type of object + inline: true source: openapi: ../openapi.yml PaginatedResponseDataItem: @@ -12832,6 +12862,7 @@ types: docs: >- The accepted operators you can use to define how you want to search for the value. + inline: true source: openapi: ../openapi.yml SingleFilterSearchRequest: @@ -12861,6 +12892,7 @@ types: - `hit`: If there’s at least one hit event in the underlying sla_events table, and no “missed” or “canceled” events for the conversation. - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. + inline: true source: openapi: ../openapi.yml SlaApplied: @@ -13019,6 +13051,7 @@ types: - type: File source: openapi: ../openapi.yml + inline: true TicketCustomAttributes: type: map docs: >- @@ -13048,6 +13081,7 @@ types: - team - user docs: The type of the author + inline: true source: openapi: ../openapi.yml TicketPartAuthor: @@ -13095,6 +13129,7 @@ types: - comment - quick_reply docs: Type of the part + inline: true source: openapi: ../openapi.yml TicketReply: @@ -13137,6 +13172,7 @@ types: - list source: openapi: ../openapi.yml + inline: true TicketRequestCustomAttributes: type: map docs: >- @@ -13292,6 +13328,7 @@ types: Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + inline: true source: openapi: ../openapi.yml UpdateArticleRequest: @@ -13343,6 +13380,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml UpdateTicketTypeRequest: @@ -14467,6 +14505,7 @@ types: "workflow_preview", "fin_preview", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14484,6 +14523,7 @@ types: docs: >- The type of the source that triggered AI Agent involvement in the conversation. + inline: true source: openapi: ../openapi.yml AiAgent: @@ -14562,6 +14602,7 @@ imports: "content_snippet", "workflow_connector_action", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14577,6 +14618,7 @@ imports: - content_snippet - workflow_connector_action docs: The type of the content source. + inline: true source: openapi: ../openapi.yml ContentSource: @@ -17183,6 +17225,7 @@ imports: "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17231,6 +17274,7 @@ imports: "highlight", "plain", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17258,6 +17302,7 @@ imports: "highlight", "plain", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19669,6 +19714,7 @@ types: Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. default: draft + inline: true source: openapi: ../openapi.yml Articles: @@ -19754,6 +19800,7 @@ types: - highlight - plain docs: The type of text - `highlight` or `plain`. + inline: true source: openapi: ../openapi.yml ArticleSearchHighlightsHighlightedTitleItem: @@ -19773,6 +19820,7 @@ types: - highlight - plain docs: The type of text - `highlight` or `plain`. + inline: true source: openapi: ../openapi.yml ArticleSearchHighlightsHighlightedSummaryItemItem: @@ -28608,6 +28656,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "priority", "not_priority", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -28619,6 +28668,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "closed", "snoozed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -28653,6 +28703,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "user", "contact", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31892,6 +31943,7 @@ types: - user - contact docs: The role associated to the contact - user or lead. + inline: true source: openapi: ../openapi.yml CreateConversationRequestFrom: @@ -31972,6 +32024,7 @@ types: - closed - snoozed docs: Can be set to "open", "closed" or "snoozed". + inline: true source: openapi: ../openapi.yml ConversationPriority: @@ -31979,6 +32032,7 @@ types: - priority - not_priority docs: If marked as priority, it will return priority or else not_priority. + inline: true source: openapi: ../openapi.yml Conversation: @@ -33032,6 +33086,7 @@ You can update a data attribute. "datetime", "date", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33042,6 +33097,7 @@ You can update a data attribute. "contact", "company", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33132,6 +33188,7 @@ You can update a data attribute. "boolean", "date", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33142,6 +33199,7 @@ You can update a data attribute. "contact", "company", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33152,6 +33210,7 @@ You can update a data attribute. "company", "conversation", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -33171,6 +33230,7 @@ You can update a data attribute. - contact - company docs: The model that the data attribute belongs to. + inline: true source: openapi: ../openapi.yml CreateDataAttributeRequestDataType: @@ -33182,6 +33242,7 @@ You can update a data attribute. - datetime - date docs: The type of data stored for this attribute. + inline: true source: openapi: ../openapi.yml DataAttributeModel: @@ -33191,6 +33252,7 @@ You can update a data attribute. docs: >- Value is `contact` for user/lead attributes and `company` for company attributes. + inline: true source: openapi: ../openapi.yml DataAttributeDataType: @@ -33201,6 +33263,7 @@ You can update a data attribute. - boolean - date docs: The data type of the attribute. + inline: true source: openapi: ../openapi.yml DataAttribute: @@ -34856,6 +34919,7 @@ Your exported message data will be streamed continuously back down to you in a g "no_data", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -35047,6 +35111,7 @@ types: - no_data - canceled docs: The current state of your job. + inline: true source: openapi: ../openapi.yml DataExport: @@ -38033,6 +38098,7 @@ This will return the Message model that has been created. "facebook", "twitter", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38210,6 +38276,7 @@ types: docs: >- The type of message that was sent. Can be email, inapp, facebook or twitter. + inline: true source: openapi: ../openapi.yml Message: @@ -38837,6 +38904,7 @@ types: "draft", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -39258,6 +39326,7 @@ types: docs: >- News items will not be visible to your users in the assigned newsfeeds until they are set live. + inline: true source: openapi: ../openapi.yml NewsItem: @@ -40262,6 +40331,7 @@ types: "contact", "user", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40356,6 +40426,7 @@ types: - contact - user docs: 'Type of the contact: contact (lead) or user.' + inline: true source: openapi: ../openapi.yml Segment: @@ -40712,6 +40783,7 @@ This will return a subscription type model for the subscription type that was ad "opt_out", "opt_in", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40721,6 +40793,7 @@ This will return a subscription type model for the subscription type that was ad "email", "sms_message", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40732,6 +40805,7 @@ This will return a subscription type model for the subscription type that was ad "draft", "archived", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40945,6 +41019,7 @@ types: - draft - archived docs: The state of the subscription type. + inline: true source: openapi: ../openapi.yml SubscriptionTypeConsentType: @@ -40952,12 +41027,14 @@ types: - opt_out - opt_in docs: Describes the type of consent. + inline: true source: openapi: ../openapi.yml SubscriptionTypeContentTypesItem: enum: - email - sms_message + inline: true source: openapi: ../openapi.yml SubscriptionType: @@ -43142,6 +43219,7 @@ types: "datetime", "files", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43159,6 +43237,7 @@ types: - datetime - files docs: The data type of the attribute + inline: true source: openapi: ../openapi.yml imports: @@ -45604,6 +45683,7 @@ The table below shows the operators you can use to define how you want to search }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45676,6 +45756,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45688,6 +45769,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45700,6 +45782,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45766,6 +45849,7 @@ The table below shows the operators you can use to define how you want to search }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45794,6 +45878,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45854,6 +45939,7 @@ types: - waiting_on_customer - resolved docs: The state of the ticket. + inline: true source: openapi: ../openapi.yml UpdateTicketRequestAssignment: @@ -45876,6 +45962,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket. + inline: true source: openapi: ../openapi.yml TicketTicketState: @@ -45885,6 +45972,7 @@ types: - waiting_on_customer - resolved docs: The state the ticket is currently in + inline: true source: openapi: ../openapi.yml Ticket: @@ -45970,6 +46058,7 @@ types: - waiting_on_customer - resolved docs: The previous state of the ticket. + inline: true source: openapi: ../openapi.yml TicketPartTicketState: @@ -45979,6 +46068,7 @@ types: - waiting_on_customer - resolved docs: The state of the ticket. + inline: true source: openapi: ../openapi.yml TicketPart: @@ -46033,6 +46123,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml TicketType: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/merge.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/merge.json index 5419f90792a..5fb5fc872e9 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/merge.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/merge.json @@ -105,6 +105,7 @@ View a list of your organization's `LinkedAccount` objects.", "INCOMPLETE", "RELINK_NEEDED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -183,6 +184,7 @@ View a list of your organization's `LinkedAccount` objects.", "SAVINGS", "CHECKING", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -368,6 +370,7 @@ Fetch from the `LIST Benefits` endpoint and filter by `ID` to show all benefits. "mktg", "filestorage", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -389,6 +392,7 @@ Fetch from the `LIST Benefits` endpoint and filter by `ID` to show all benefits. "mktg", "filestorage", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -530,6 +534,7 @@ Fetch from the `LIST Companies` endpoint and filter by `ID` to show all companie "STRING", "LIST_OF_STRINGS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1035,6 +1040,7 @@ Fetch from the `LIST Companies` endpoint and filter by `ID` to show all companie "ZM", "ZW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1246,6 +1252,7 @@ Fetch from the `LIST Earnings` endpoint and filter by `ID` to show all earnings. "OVERTIME", "BONUS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2223,6 +2230,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "PENDING", "INACTIVE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2240,6 +2248,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "CONTRACTOR", "FREELANCE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2251,6 +2260,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "READ", "WRITE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2264,6 +2274,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "BASE64", "GZIP_BASE64", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2374,6 +2385,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "WHITE", "PREFER_NOT_TO_DISCLOSE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2389,6 +2401,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "NONEXEMPT", "OWNER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2409,6 +2422,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "OTHER", "PREFER_NOT_TO_DISCLOSE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2510,6 +2524,7 @@ Fetch from the `LIST Employee` endpoint and expand groups to view an employee's "BUSINESS_UNIT", "GROUP", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2571,6 +2586,7 @@ Fetch from the `LIST Employee` endpoint and expand groups to view an employee's "ONGOING", "RESOLVED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3023,6 +3039,7 @@ Fetch from the `LIST Locations` endpoint and filter by `ID` to show all office l "HOME", "WORK", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3040,6 +3057,7 @@ Fetch from the `LIST Locations` endpoint and filter by `ID` to show all office l "HEAD_OF_HOUSEHOLD", "QUALIFYING_WIDOW_OR_WIDOWER_WITH_DEPENDENT_CHILD", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3075,6 +3093,7 @@ Fetch from the `LIST Locations` endpoint and filter by `ID` to show all office l "PATCH", "DELETE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3995,6 +4014,7 @@ Create a `MultipartFormField` to define a multipart form entry.", "ZWR", "ZWL", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4023,6 +4043,7 @@ Create a `MultipartFormField` to define a multipart form entry.", "PRO_RATA", "SEMIMONTHLY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4089,6 +4110,7 @@ Fetch from the `LIST PayGroup` endpoint and filter by `ID` to show all pay group "EVERY_SIX_MONTHS", "YEAR", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4177,6 +4199,7 @@ Fetch from the `LIST PayrollRuns` endpoint and filter by `ID` to show all payrol "VOLUNTEER", "BEREAVEMENT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4190,6 +4213,7 @@ Fetch from the `LIST PayrollRuns` endpoint and filter by `ID` to show all payrol "GDPR", "OTHER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4274,6 +4298,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "XML", "MULTIPART", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4293,6 +4318,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "VOLUNTEER", "BEREAVEMENT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4304,6 +4330,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "JSON", "BASE64_GZIP", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4321,6 +4348,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "FAILED", "CLOSED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4338,6 +4366,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "TERMINATION", "SIGN_ON_BONUS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4349,6 +4378,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "IN_NEXT_SYNC", "IN_LAST_SYNC", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4389,6 +4419,7 @@ View the `SyncStatus` for an account to see how recently its models were synced. "PAUSED", "PARTIALLY_SYNCED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4782,6 +4813,7 @@ Fetch from the `LIST TimeOffs` endpoint and filter by `ID` to show all time off "CANCELLED", "DELETED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4793,6 +4825,7 @@ Fetch from the `LIST TimeOffs` endpoint and filter by `ID` to show all time off "HOURS", "DAYS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10270,6 +10303,7 @@ service: "CHECKING", "SAVINGS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10285,6 +10319,7 @@ service: "value": "remote_created_at", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11524,6 +11559,7 @@ service: }, "payroll_run", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11537,6 +11573,7 @@ service: }, "payroll_run", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12362,6 +12399,7 @@ service: "INACTIVE", "PENDING", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13365,6 +13403,7 @@ service: "value": "work_location,team,pay_group", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13420,6 +13459,7 @@ service: }, "marital_status", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13475,6 +13515,7 @@ service: }, "marital_status", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -14478,6 +14519,7 @@ service: "value": "work_location,team,pay_group", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -14533,6 +14575,7 @@ service: }, "marital_status", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -14588,6 +14631,7 @@ service: }, "marital_status", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16386,6 +16430,7 @@ service: }, "pay_group", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16401,6 +16446,7 @@ service: "value": "effective_date", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16456,6 +16502,7 @@ service: }, "pay_period", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16511,6 +16558,7 @@ service: }, "pay_period", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16524,6 +16572,7 @@ service: }, "pay_group", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16579,6 +16628,7 @@ service: }, "pay_period", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16634,6 +16684,7 @@ service: }, "pay_period", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -17599,6 +17650,7 @@ service: "ONGOING", "RESOLVED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -17969,6 +18021,7 @@ service: "mktg", "ticketing", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -19079,6 +19132,7 @@ service: }, "run_type", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -19091,6 +19145,7 @@ service: "SIGN_ON_BONUS", "TERMINATION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -19104,6 +19159,7 @@ service: }, "run_type", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -19117,6 +19173,7 @@ service: }, "run_type", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -19130,6 +19187,7 @@ service: }, "run_type", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20515,6 +20573,7 @@ service: "value": "employee,approver", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20541,6 +20600,7 @@ service: }, "units", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20554,6 +20614,7 @@ service: "VACATION", "VOLUNTEER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20580,6 +20641,7 @@ service: }, "units", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20592,6 +20654,7 @@ service: "DELETED", "REQUESTED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20605,6 +20668,7 @@ service: "value": "employee,approver", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20631,6 +20695,7 @@ service: }, "units", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20657,6 +20722,7 @@ service: }, "units", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -21274,6 +21340,7 @@ service: "VACATION", "VOLUNTEER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/non-alphanumeric-characters.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/non-alphanumeric-characters.json index 0e93f21bc04..205a502067b 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/non-alphanumeric-characters.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/non-alphanumeric-characters.json @@ -66,6 +66,7 @@ "value": "", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/ntropy.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/ntropy.json index 58712f5011b..20a1c1a672a 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/ntropy.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/ntropy.json @@ -685,6 +685,7 @@ "consumer", "business", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -695,6 +696,7 @@ "consumer", "business", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -714,6 +716,7 @@ "financing", "taxes", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -853,6 +856,7 @@ "invalid_bank_statement", "internal_error", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -894,6 +898,7 @@ "completed", "error", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1025,6 +1030,7 @@ enriched transactions.", "completed", "error", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1054,6 +1060,7 @@ enriched transactions.", "low", "unknown", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1111,6 +1118,7 @@ enriched transactions.", "person", "organization", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1363,6 +1371,7 @@ enriched transactions.", "ZM", "ZW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1521,6 +1530,7 @@ enriched transactions.", "ZWL", "HRK", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1548,6 +1558,7 @@ enriched transactions.", "processed", "failed", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1562,6 +1573,7 @@ enriched transactions.", "person", "transaction_type", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1664,6 +1676,7 @@ enriched transactions.", "incoming", "outgoing", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2020,6 +2033,7 @@ enriched transactions.", "delivery_service", "payment_processor", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2377,6 +2391,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "yearly", "other", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2391,6 +2406,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "value": "one off", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2451,6 +2467,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "resolved", "rejected", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2610,6 +2627,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "account_holder_not_found", "internal_error", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2782,6 +2800,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "value": "batches.error", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2855,6 +2874,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "account_holder_id", "account_holder_name", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4488,6 +4508,7 @@ types: name: BatchesCompleted - value: batches.error name: BatchesError + inline: true source: openapi: ../openapi.yml Webhook: @@ -10586,6 +10607,7 @@ sdk.webhooks.create( "value": "batches.error", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -10621,6 +10643,7 @@ sdk.webhooks.create( "value": "batches.error", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -10954,6 +10977,7 @@ types: name: BatchesCompleted - value: batches.error name: BatchesError + inline: true source: openapi: ../openapi.yml WebhookPatchEventsItem: @@ -10972,6 +10996,7 @@ types: name: BatchesCompleted - value: batches.error name: BatchesError + inline: true source: openapi: ../openapi.yml ", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/oauth.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/oauth.json index 6e76ddae20f..253a8865cc2 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/oauth.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/oauth.json @@ -123,6 +123,7 @@ "refresh_token", "client_credentials", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -152,6 +153,7 @@ - refresh_token - client_credentials docs: The type of grant to request + inline: true source: openapi: ../openapi.yml AuthGetTokenResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/only-include-referenced-schemas.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/only-include-referenced-schemas.json index 06f4b3d0bf1..30726459099 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/only-include-referenced-schemas.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/only-include-referenced-schemas.json @@ -4041,6 +4041,7 @@ "upfront_email_collection_change", "welcome_message_change", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4278,6 +4279,7 @@ "comment", "note", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4319,6 +4321,7 @@ "note", "quick_reply", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4476,6 +4479,7 @@ "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4729,6 +4733,7 @@ "admin", "team", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5703,6 +5708,7 @@ "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5831,6 +5837,7 @@ }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5873,7 +5880,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6420,6 +6427,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "ticket", "conversation", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6446,6 +6454,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "AND", "OR", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6516,6 +6525,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "draft", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6642,6 +6652,7 @@ Their responses are likely to contain a pages object that hosts pagination links "value": "conversation.list", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6903,6 +6914,7 @@ Their responses are likely to contain a pages object that hosts pagination links "value": "~", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6944,6 +6956,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "cancelled", "active", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7146,7 +7159,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7223,6 +7236,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "team", "user", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7299,6 +7313,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "comment", "quick_reply", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7311,7 +7326,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7542,6 +7557,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7593,6 +7609,7 @@ You can copy the `icon` property for your ticket type from [Twemoji Cheatsheet]( }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -10204,6 +10221,7 @@ types: - temporary_expectation_change - upfront_email_collection_change - welcome_message_change + inline: true source: openapi: ../openapi.yml ActivityLog: @@ -10324,6 +10342,7 @@ types: enum: - comment - note + inline: true source: openapi: ../openapi.yml AdminReplyConversationRequest: @@ -10361,6 +10380,7 @@ types: - comment - note - quick_reply + inline: true source: openapi: ../openapi.yml AdminReplyTicketRequestReplyOptionsItem: @@ -10503,6 +10523,7 @@ types: - published - draft docs: Whether the article is `published` or is a `draft` . + inline: true source: openapi: ../openapi.yml ArticleContent: @@ -10710,6 +10731,7 @@ types: enum: - admin - team + inline: true source: openapi: ../openapi.yml AssignConversationRequest: @@ -11466,6 +11488,7 @@ types: Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + inline: true source: openapi: ../openapi.yml CreateArticleRequest: @@ -11586,6 +11609,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml CreateTicketTypeRequest: @@ -11647,6 +11671,7 @@ types: - type: optional source: openapi: ../openapi.yml + inline: true CustomAttributes: type: map docs: >- @@ -11993,6 +12018,7 @@ types: - ticket - conversation docs: ticket or conversation + inline: true source: openapi: ../openapi.yml LinkedObject: @@ -12033,6 +12059,7 @@ types: - AND - OR docs: An operator to allow boolean inspection between multiple fields. + inline: true source: openapi: ../openapi.yml MultipleFilterSearchRequestValue: @@ -12062,6 +12089,7 @@ types: docs: >- News items will not be visible to your users in the assigned newsfeeds until they are set live. + inline: true source: openapi: ../openapi.yml NewsItemRequest: @@ -12161,6 +12189,7 @@ types: - value: conversation.list name: ConversationList docs: The type of object + inline: true source: openapi: ../openapi.yml PaginatedResponseDataItem: @@ -12333,6 +12362,7 @@ types: docs: >- The accepted operators you can use to define how you want to search for the value. + inline: true source: openapi: ../openapi.yml SingleFilterSearchRequest: @@ -12362,6 +12392,7 @@ types: - `hit`: If there’s at least one hit event in the underlying sla_events table, and no “missed” or “canceled” events for the conversation. - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. + inline: true source: openapi: ../openapi.yml SlaApplied: @@ -12520,6 +12551,7 @@ types: - type: File source: openapi: ../openapi.yml + inline: true TicketCustomAttributes: type: map docs: >- @@ -12549,6 +12581,7 @@ types: - team - user docs: The type of the author + inline: true source: openapi: ../openapi.yml TicketPartAuthor: @@ -12596,6 +12629,7 @@ types: - comment - quick_reply docs: Type of the part + inline: true source: openapi: ../openapi.yml TicketReply: @@ -12638,6 +12672,7 @@ types: - list source: openapi: ../openapi.yml + inline: true TicketRequestCustomAttributes: type: map docs: >- @@ -12793,6 +12828,7 @@ types: Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + inline: true source: openapi: ../openapi.yml UpdateArticleRequest: @@ -12844,6 +12880,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml UpdateTicketTypeRequest: @@ -13953,6 +13990,7 @@ types: "workflow_preview", "fin_preview", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13970,6 +14008,7 @@ types: docs: >- The type of the source that triggered AI Agent involvement in the conversation. + inline: true source: openapi: ../openapi.yml AiAgent: @@ -14048,6 +14087,7 @@ imports: "content_snippet", "workflow_connector_action", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14063,6 +14103,7 @@ imports: - content_snippet - workflow_connector_action docs: The type of the content source. + inline: true source: openapi: ../openapi.yml ContentSource: @@ -16669,6 +16710,7 @@ imports: "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16717,6 +16759,7 @@ imports: "highlight", "plain", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16744,6 +16787,7 @@ imports: "highlight", "plain", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19155,6 +19199,7 @@ types: Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. default: draft + inline: true source: openapi: ../openapi.yml Articles: @@ -19240,6 +19285,7 @@ types: - highlight - plain docs: The type of text - `highlight` or `plain`. + inline: true source: openapi: ../openapi.yml ArticleSearchHighlightsHighlightedTitleItem: @@ -19259,6 +19305,7 @@ types: - highlight - plain docs: The type of text - `highlight` or `plain`. + inline: true source: openapi: ../openapi.yml ArticleSearchHighlightsHighlightedSummaryItemItem: @@ -28094,6 +28141,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "priority", "not_priority", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -28105,6 +28153,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "closed", "snoozed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -28139,6 +28188,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "user", "contact", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31378,6 +31428,7 @@ types: - user - contact docs: The role associated to the contact - user or lead. + inline: true source: openapi: ../openapi.yml CreateConversationRequestFrom: @@ -31458,6 +31509,7 @@ types: - closed - snoozed docs: Can be set to "open", "closed" or "snoozed". + inline: true source: openapi: ../openapi.yml ConversationPriority: @@ -31465,6 +31517,7 @@ types: - priority - not_priority docs: If marked as priority, it will return priority or else not_priority. + inline: true source: openapi: ../openapi.yml Conversation: @@ -32518,6 +32571,7 @@ You can update a data attribute. "datetime", "date", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32528,6 +32582,7 @@ You can update a data attribute. "contact", "company", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32618,6 +32673,7 @@ You can update a data attribute. "boolean", "date", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32628,6 +32684,7 @@ You can update a data attribute. "contact", "company", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32638,6 +32695,7 @@ You can update a data attribute. "company", "conversation", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -32657,6 +32715,7 @@ You can update a data attribute. - contact - company docs: The model that the data attribute belongs to. + inline: true source: openapi: ../openapi.yml CreateDataAttributeRequestDataType: @@ -32668,6 +32727,7 @@ You can update a data attribute. - datetime - date docs: The type of data stored for this attribute. + inline: true source: openapi: ../openapi.yml DataAttributeModel: @@ -32677,6 +32737,7 @@ You can update a data attribute. docs: >- Value is `contact` for user/lead attributes and `company` for company attributes. + inline: true source: openapi: ../openapi.yml DataAttributeDataType: @@ -32687,6 +32748,7 @@ You can update a data attribute. - boolean - date docs: The data type of the attribute. + inline: true source: openapi: ../openapi.yml DataAttribute: @@ -34266,6 +34328,7 @@ Your exported message data will be streamed continuously back down to you in a g "no_data", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34457,6 +34520,7 @@ types: - no_data - canceled docs: The current state of your job. + inline: true source: openapi: ../openapi.yml DataExport: @@ -37443,6 +37507,7 @@ This will return the Message model that has been created. "facebook", "twitter", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -37620,6 +37685,7 @@ types: docs: >- The type of message that was sent. Can be email, inapp, facebook or twitter. + inline: true source: openapi: ../openapi.yml Message: @@ -38247,6 +38313,7 @@ types: "draft", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38668,6 +38735,7 @@ types: docs: >- News items will not be visible to your users in the assigned newsfeeds until they are set live. + inline: true source: openapi: ../openapi.yml NewsItem: @@ -39672,6 +39740,7 @@ types: "contact", "user", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -39766,6 +39835,7 @@ types: - contact - user docs: 'Type of the contact: contact (lead) or user.' + inline: true source: openapi: ../openapi.yml Segment: @@ -40122,6 +40192,7 @@ This will return a subscription type model for the subscription type that was ad "opt_out", "opt_in", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40131,6 +40202,7 @@ This will return a subscription type model for the subscription type that was ad "email", "sms_message", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40142,6 +40214,7 @@ This will return a subscription type model for the subscription type that was ad "draft", "archived", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40355,6 +40428,7 @@ types: - draft - archived docs: The state of the subscription type. + inline: true source: openapi: ../openapi.yml SubscriptionTypeConsentType: @@ -40362,12 +40436,14 @@ types: - opt_out - opt_in docs: Describes the type of consent. + inline: true source: openapi: ../openapi.yml SubscriptionTypeContentTypesItem: enum: - email - sms_message + inline: true source: openapi: ../openapi.yml SubscriptionType: @@ -42552,6 +42628,7 @@ types: "datetime", "files", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42569,6 +42646,7 @@ types: - datetime - files docs: The data type of the attribute + inline: true source: openapi: ../openapi.yml imports: @@ -45014,6 +45092,7 @@ The table below shows the operators you can use to define how you want to search }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45086,6 +45165,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45098,6 +45178,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45110,6 +45191,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45176,6 +45258,7 @@ The table below shows the operators you can use to define how you want to search }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45204,6 +45287,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45264,6 +45348,7 @@ types: - waiting_on_customer - resolved docs: The state of the ticket. + inline: true source: openapi: ../openapi.yml UpdateTicketRequestAssignment: @@ -45286,6 +45371,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket. + inline: true source: openapi: ../openapi.yml TicketTicketState: @@ -45295,6 +45381,7 @@ types: - waiting_on_customer - resolved docs: The state the ticket is currently in + inline: true source: openapi: ../openapi.yml Ticket: @@ -45380,6 +45467,7 @@ types: - waiting_on_customer - resolved docs: The previous state of the ticket. + inline: true source: openapi: ../openapi.yml TicketPartTicketState: @@ -45389,6 +45477,7 @@ types: - waiting_on_customer - resolved docs: The state of the ticket. + inline: true source: openapi: ../openapi.yml TicketPart: @@ -45443,6 +45532,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml TicketType: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/openapi-filter.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/openapi-filter.json index c41e115db7d..b2011874205 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/openapi-filter.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/openapi-filter.json @@ -725,6 +725,7 @@ types: "contact", "user", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -737,6 +738,7 @@ types: - contact - user docs: 'Type of the contact: contact (lead) or user.' + inline: true source: openapi: ../openapi.yml Segment: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/permit.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/permit.json index 5afedc6c120..e9acecb4488 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/permit.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/permit.json @@ -1357,6 +1357,7 @@ "array", "json", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1569,6 +1570,7 @@ "userset", "resourceset", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1953,6 +1955,7 @@ "failed", "canceled", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1978,6 +1981,7 @@ "read", "no_access", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1989,6 +1993,7 @@ "project", "env", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2005,6 +2010,7 @@ "connect_sdk", "done", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -3845,6 +3851,7 @@ The actions represents the ways you can interact with a protected resource.", "active", "pending", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -9692,6 +9699,7 @@ allowed.", "fail", "overwrite", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -10158,6 +10166,7 @@ types: Action to take when detecting a conflict when copying. Only applies to copying into an existing environment default: fail + inline: true source: openapi: ../openapi.json ", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/query-params.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/query-params.json index 7805574f7b8..5d5571cd224 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/query-params.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/query-params.json @@ -92,6 +92,7 @@ "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/readonly.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/readonly.json index 82e436f7c5a..67eee6c06eb 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/readonly.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/readonly.json @@ -143,6 +143,7 @@ "suspended", "deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -253,6 +254,7 @@ types: - active - suspended - deleted + inline: true source: openapi: ../openapi.yml UserStatsRead: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/rightbrain.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/rightbrain.json index e3c61c58e6b..2e3b71ed47c 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/rightbrain.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/rightbrain.json @@ -5966,6 +5966,7 @@ "dropbox", "sharepoint", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6329,6 +6330,7 @@ "all", "viewable", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -7811,6 +7813,7 @@ Some entities, such as Organizations, may contain members that exist without any "prompt_policy", "pii_policy", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8139,6 +8142,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "italian", "german", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8375,6 +8379,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8462,6 +8467,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "prompt_policy", "pii_policy", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8500,6 +8506,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "user_defined", "zendesk", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8543,6 +8550,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "no_size", "site", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8552,6 +8560,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "file", "dir", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8665,6 +8674,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "pending", "accepted", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8769,6 +8779,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "joinable_by_domain", "joinable_by_invite", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -9837,6 +9848,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "dropbox", "sharepoint", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9863,6 +9875,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "RETRY", "PROGRESS", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9872,6 +9885,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "unverified", "verified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -10292,6 +10306,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -10306,6 +10321,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "integer", "list", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -10394,6 +10410,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "success", "validation", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15274,6 +15291,7 @@ types: - value: gemini-pro name: GeminiPro default: gpt-3.5-turbo + inline: true source: openapi: ../openapi.yml ChatConfig: @@ -15316,6 +15334,7 @@ types: - box - dropbox - sharepoint + inline: true source: openapi: ../openapi.yml ChatDocument: @@ -15384,6 +15403,7 @@ types: - source_validation - prompt_policy - pii_policy + inline: true source: openapi: ../openapi.yml Type: @@ -15392,6 +15412,7 @@ types: - error - success - validation + inline: true source: openapi: ../openapi.yml ChatGuardrail: @@ -15408,6 +15429,7 @@ types: enum: - prompt_policy - pii_policy + inline: true source: openapi: ../openapi.yml ChatModel: @@ -15492,6 +15514,7 @@ types: - italian - german default: english_british + inline: true source: openapi: ../openapi.yml ComposeInit: @@ -15626,6 +15649,7 @@ types: enum: - unverified - verified + inline: true source: openapi: ../openapi.yml DatasourceSyncRun: @@ -15657,6 +15681,7 @@ types: - FAILURE - RETRY - PROGRESS + inline: true source: openapi: ../openapi.yml DocumentCreateTask: @@ -16333,6 +16358,7 @@ types: - box - dropbox - sharepoint + inline: true source: openapi: ../openapi.yml SourceRow: @@ -16484,6 +16510,7 @@ types: - value: gemini-pro name: GeminiPro docs: The LLM model to use for the Task. + inline: true source: openapi: ../openapi.yml TaskRevisionOutputFormatValue: @@ -16495,6 +16522,7 @@ types: - int - integer - list + inline: true source: openapi: ../openapi.yml TaskRevision: @@ -17281,6 +17309,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -17291,6 +17320,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17301,6 +17331,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17318,6 +17349,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17374,6 +17406,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17849,6 +17882,7 @@ types: - value: gemini-pro name: GeminiPro default: gpt-3.5-turbo + inline: true source: openapi: ../openapi.yml ChatIamListMembersRequestType: @@ -17863,6 +17897,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml ChatIamMemberRoleUpdateRemoveItem: @@ -17870,6 +17905,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml ChatIamPermissionTestPermissionsItem: @@ -17884,6 +17920,7 @@ types: - remove_owner - view - view_members + inline: true source: openapi: ../openapi.yml ", @@ -18753,6 +18790,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -18763,6 +18801,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18773,6 +18812,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18794,6 +18834,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19439,6 +19480,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml CollectionIamMemberRoleUpdateRemoveItem: @@ -19446,6 +19488,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml CollectionIamPermissionTestPermissionsItem: @@ -19464,6 +19507,7 @@ types: - remove_owner - view - view_members + inline: true source: openapi: ../openapi.yml ", @@ -26559,6 +26603,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -26569,6 +26614,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26579,6 +26625,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26596,6 +26643,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26612,6 +26660,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "dropbox", "sharepoint", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -26644,6 +26693,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - editor - owner - viewer + inline: true source: openapi: ../openapi.yml DocumentIamMemberRoleUpdateRemoveItem: @@ -26651,6 +26701,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - editor - owner - viewer + inline: true source: openapi: ../openapi.yml DocumentIamPermissionTestPermissionsItem: @@ -26665,6 +26716,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - remove_owner - view - view_members + inline: true source: openapi: ../openapi.yml imports: @@ -28819,6 +28871,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -28829,6 +28882,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -28839,6 +28893,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -28856,6 +28911,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -28875,6 +28931,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - editor - owner - viewer + inline: true source: openapi: ../openapi.yml OrganizationIamMemberRoleUpdateRemoveItem: @@ -28882,6 +28939,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - editor - owner - viewer + inline: true source: openapi: ../openapi.yml OrganizationIamPermissionTestPermissionsItem: @@ -28896,6 +28954,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - remove_owner - view - view_members + inline: true source: openapi: ../openapi.yml imports: @@ -30171,6 +30230,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30181,6 +30241,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -30196,6 +30257,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "task_runner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30211,6 +30273,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "task_runner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30244,6 +30307,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view_data", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30748,6 +30812,7 @@ types: - value: gemini-pro name: GeminiPro default: gpt-3.5-turbo + inline: true source: openapi: ../openapi.yml ProjectIamListMembersRequestType: @@ -30767,6 +30832,7 @@ types: - task_creator - task_runner - viewer + inline: true source: openapi: ../openapi.yml ProjectIamMemberRoleUpdateRemoveItem: @@ -30779,6 +30845,7 @@ types: - task_creator - task_runner - viewer + inline: true source: openapi: ../openapi.yml ProjectIamPermissionTestPermissionsItem: @@ -30809,6 +30876,7 @@ types: - view - view_data - view_members + inline: true source: openapi: ../openapi.yml ", @@ -32953,6 +33021,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32967,6 +33036,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "integer", "list", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32977,6 +33047,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -32987,6 +33058,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32997,6 +33069,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33014,6 +33087,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33069,6 +33143,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33083,6 +33158,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "integer", "list", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33990,6 +34066,7 @@ types: - value: gemini-pro name: GeminiPro docs: The LLM model to use for the Task. + inline: true source: openapi: ../openapi.yml TaskCreateOutputFormatValue: @@ -34001,6 +34078,7 @@ types: - int - integer - list + inline: true source: openapi: ../openapi.yml TaskUpdateLlmModel: @@ -34029,6 +34107,7 @@ types: name: Gemini15ProLatest - value: gemini-pro name: GeminiPro + inline: true source: openapi: ../openapi.yml TaskUpdateOutputFormatValue: @@ -34040,6 +34119,7 @@ types: - int - integer - list + inline: true source: openapi: ../openapi.yml TaskIamListMembersRequestType: @@ -34054,6 +34134,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml TaskIamMemberRoleUpdateRemoveItem: @@ -34061,6 +34142,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml TaskIamPermissionTestPermissionsItem: @@ -34075,6 +34157,7 @@ types: - run_task - view - view_members + inline: true source: openapi: ../openapi.yml ", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/seam.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/seam.json index 2e4e18fb434..c77b97926f3 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/seam.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/seam.json @@ -1396,6 +1396,7 @@ "removing", "unknown", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1406,6 +1407,7 @@ "time_bound", "ongoing", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1479,6 +1481,7 @@ "salto_access_group", "brivo_group", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1490,6 +1493,7 @@ "salto_access_group", "brivo_group", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1585,6 +1589,7 @@ "card", "mobile_key", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1607,6 +1612,7 @@ "hid_credential", "visionline_card", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1723,6 +1729,7 @@ "guest", "staff", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1820,6 +1827,7 @@ "value": "common (PMS)", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1841,6 +1849,7 @@ "commonDoor", "touch", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1948,6 +1957,7 @@ "assa_abloy_credential_service", "latch_building", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1968,6 +1978,7 @@ "assa_abloy_credential_service", "latch_building", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -2079,6 +2090,7 @@ "salto_site_user", "latch_user", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3782,6 +3794,7 @@ "cool", "heat_cool", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3895,6 +3908,7 @@ "single", "multiple", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3905,6 +3919,7 @@ "failed", "authorized", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4058,6 +4073,7 @@ "battery", "phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4112,6 +4128,7 @@ "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4411,6 +4428,7 @@ "good", "full", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4455,6 +4473,7 @@ "name_length", "name_must_be_unique", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4481,6 +4500,7 @@ "at_least_three_unique_digits", "cannot_contain_089", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4811,6 +4831,7 @@ "indoor", "outdoor", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4874,6 +4895,7 @@ "bridge", "doorking", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -5000,6 +5022,7 @@ "honeywell_resideo", "latch", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -5012,6 +5035,7 @@ "noise_sensors", "access_control_systems", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -5307,6 +5331,7 @@ "battery", "phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -5329,6 +5354,7 @@ "android_phone", "ios_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -5422,6 +5448,7 @@ "degraded", "down", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -5489,6 +5516,7 @@ "time_bound", "ongoing", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -5570,6 +5598,7 @@ "battery", "phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -5611,6 +5640,7 @@ "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -5757,6 +5787,7 @@ "good", "full", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -6948,6 +6979,7 @@ types: Nature of the access code. Values are "ongoing" for access codes that are active continuously until deactivated manually or "time_bound" for access codes that have a specific duration. + inline: true source: openapi: ../openapi.json AccessCodeStatus: @@ -6961,6 +6993,7 @@ types: Current status of the access code within the operational lifecycle. Values are "setting," a transitional phase that indicates that the code is being configured or activated; "set", which indicates that the code is active and operational; "unset," which indicates a deactivated or unused state, either before activation or after deliberate deactivation; "removing," which indicates a transitional period in which the code is being deleted or made inactive; and "unknown," which indicates an indeterminate state, due to reasons such as system errors or incomplete data, that highlights a potential need for system review or troubleshooting. + inline: true source: openapi: ../openapi.json AccessCode: @@ -7064,6 +7097,7 @@ types: Nature of the access code. Values are "ongoing" for access codes that are active continuously until deactivated manually or "time_bound" for access codes that have a specific duration. + inline: true source: openapi: ../openapi.json UnmanagedAccessCode: @@ -8276,6 +8310,7 @@ types: - heat - cool - heat_cool + inline: true source: openapi: ../openapi.json ClimateSettingSchedule: @@ -8309,6 +8344,7 @@ types: - none - single - multiple + inline: true source: openapi: ../openapi.json ConnectWebviewStatus: @@ -8316,6 +8352,7 @@ types: - pending - failed - authorized + inline: true source: openapi: ../openapi.json ConnectWebviewCustomMetadataValue: @@ -8451,6 +8488,7 @@ types: - ios_phone - android_phone docs: Type of the device. + inline: true source: openapi: ../openapi.json DeviceCapabilitiesSupportedItem: @@ -8461,6 +8499,7 @@ types: - thermostat - battery - phone + inline: true source: openapi: ../openapi.json DevicePropertiesAccessoryKeypadBattery: @@ -8535,6 +8574,7 @@ types: - low - good - full + inline: true source: openapi: ../openapi.json DevicePropertiesBattery: @@ -8674,6 +8714,7 @@ types: enum: - indoor - outdoor + inline: true source: openapi: ../openapi.json DevicePropertiesNoiseawareMetadata: @@ -8774,6 +8815,7 @@ types: enum: - bridge - doorking + inline: true source: openapi: ../openapi.json DevicePropertiesSeamBridgeMetadata: @@ -8892,6 +8934,7 @@ types: - no_ascending_or_descending_sequence - at_least_three_unique_digits - cannot_contain_089 + inline: true source: openapi: ../openapi.json DevicePropertiesCodeConstraintsItemZero: @@ -8904,6 +8947,7 @@ types: enum: - name_length - name_must_be_unique + inline: true source: openapi: ../openapi.json DevicePropertiesCodeConstraintsItemMaxLength: @@ -9210,6 +9254,7 @@ types: - ios_phone - android_phone docs: Type of the device. + inline: true source: openapi: ../openapi.json UnmanagedDeviceCapabilitiesSupportedItem: @@ -9220,6 +9265,7 @@ types: - thermostat - battery - phone + inline: true source: openapi: ../openapi.json UnmanagedDeviceErrorsItem: @@ -9265,6 +9311,7 @@ types: - low - good - full + inline: true source: openapi: ../openapi.json UnmanagedDevicePropertiesBattery: @@ -9484,6 +9531,7 @@ types: - tedee - honeywell_resideo - latch + inline: true source: openapi: ../openapi.json DeviceProviderProviderCategoriesItem: @@ -9493,6 +9541,7 @@ types: - thermostats - noise_sensors - access_control_systems + inline: true source: openapi: ../openapi.json DeviceProvider: @@ -9568,6 +9617,7 @@ types: - healthy - degraded - down + inline: true source: openapi: ../openapi.json ServiceHealth: @@ -9614,6 +9664,7 @@ types: - visionline_system - assa_abloy_credential_service - latch_building + inline: true source: openapi: ../openapi.json AcsSystemSystemType: @@ -9632,6 +9683,7 @@ types: deprecated: use external_type --- + inline: true source: openapi: ../openapi.json AcsSystemErrorsItemSeamBridgeDisconnected: @@ -9714,6 +9766,7 @@ types: deprecated: use external_type --- + inline: true source: openapi: ../openapi.json AcsAccessGroupExternalType: @@ -9722,6 +9775,7 @@ types: - pti_access_level - salto_access_group - brivo_group + inline: true source: openapi: ../openapi.json AcsAccessGroup: @@ -9768,6 +9822,7 @@ types: - hid_credential_manager_user - salto_site_user - latch_user + inline: true source: openapi: ../openapi.json AcsUserAccessSchedule: @@ -9848,6 +9903,7 @@ types: - common - value: common (PMS) name: CommonPms + inline: true source: openapi: ../openapi.json AcsEntranceVisionlineMetadataProfilesItemVisionlineDoorProfileType: @@ -9855,6 +9911,7 @@ types: - BLE - commonDoor - touch + inline: true source: openapi: ../openapi.json AcsEntranceVisionlineMetadataProfilesItem: @@ -9938,6 +9995,7 @@ types: - code - card - mobile_key + inline: true source: openapi: ../openapi.json AcsCredentialExternalType: @@ -9946,6 +10004,7 @@ types: - brivo_credential - hid_credential - visionline_card + inline: true source: openapi: ../openapi.json AcsCredentialErrorsItem: @@ -9966,6 +10025,7 @@ types: enum: - guest - staff + inline: true source: openapi: ../openapi.json AcsCredentialVisionlineMetadata: @@ -10047,6 +10107,7 @@ types: enum: - android_phone - ios_phone + inline: true source: openapi: ../openapi.json PhoneCapabilitiesSupportedItem: @@ -10057,6 +10118,7 @@ types: - thermostat - battery - phone + inline: true source: openapi: ../openapi.json PhonePropertiesAssaAbloyCredentialServiceMetadataEndpointsItem: @@ -10977,6 +11039,7 @@ types: "throw", "create_random_code", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -11001,6 +11064,7 @@ types: "value": "1d", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -11036,6 +11100,7 @@ types: "value": "1d", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -11127,6 +11192,7 @@ types: "value": "1d", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -11136,6 +11202,7 @@ types: "ongoing", "time_bound", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -11165,6 +11232,7 @@ types: - value: 1d name: OneD default: 1hour + inline: true source: openapi: ../openapi.json AccessCodesCreateResponse: @@ -11179,6 +11247,7 @@ types: - throw - create_random_code default: throw + inline: true source: openapi: ../openapi.json AccessCodesCreateMultipleRequestMaxTimeRounding: @@ -11192,6 +11261,7 @@ types: - value: 1d name: OneD default: 1hour + inline: true source: openapi: ../openapi.json AccessCodesCreateMultipleResponse: @@ -11241,12 +11311,14 @@ types: - value: 1d name: OneD default: 1hour + inline: true source: openapi: ../openapi.json AccessCodesUpdateRequestType: enum: - ongoing - time_bound + inline: true source: openapi: ../openapi.json AccessCodesUpdateResponse: @@ -14300,6 +14372,7 @@ service: "card", "mobile_key", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -14342,6 +14415,7 @@ service: "TLCode", "rfid48", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -14352,6 +14426,7 @@ service: "guest", "staff", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -14448,12 +14523,14 @@ types: - code - card - mobile_key + inline: true source: openapi: ../openapi.json CredentialsCreateRequestVisionlineMetadataCardFormat: enum: - TLCode - rfid48 + inline: true source: openapi: ../openapi.json CredentialsCreateRequestVisionlineMetadataCardFunctionType: @@ -14461,6 +14538,7 @@ types: - guest - staff default: guest + inline: true source: openapi: ../openapi.json CredentialsCreateRequestVisionlineMetadata: @@ -18950,6 +19028,7 @@ service: "hid_cm", "google_nest", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -18982,6 +19061,7 @@ service: "single", "multiple", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -18995,6 +19075,7 @@ service: "access_control_systems", "internal_beta", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -19063,6 +19144,7 @@ service: - none - single - multiple + inline: true source: openapi: ../openapi.json ConnectWebviewsCreateRequestAcceptedProvidersItem: @@ -19107,6 +19189,7 @@ service: - yale_access - hid_cm - google_nest + inline: true source: openapi: ../openapi.json ConnectWebviewsCreateRequestProviderCategory: @@ -19117,6 +19200,7 @@ service: - noise_sensors - access_control_systems - internal_beta + inline: true source: openapi: ../openapi.json ConnectWebviewsCreateRequestCustomMetadataValue: @@ -20645,6 +20729,7 @@ service: "noise_sensors", "access_control_systems", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -20709,6 +20794,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -20749,6 +20835,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -20763,6 +20850,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -20777,6 +20865,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -20818,6 +20907,7 @@ service: "tedee", "honeywell_resideo", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -20924,6 +21014,7 @@ service: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json DevicesListRequestDeviceTypesItem: @@ -20961,6 +21052,7 @@ service: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json DevicesListRequestManufacturer: @@ -20999,6 +21091,7 @@ service: - dormakaba_oracode - tedee - honeywell_resideo + inline: true source: openapi: ../openapi.json DevicesListRequestCustomMetadataHasValue: @@ -21018,6 +21111,7 @@ service: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json DevicesListRequestExcludeIfItem: @@ -21029,6 +21123,7 @@ service: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json DevicesListResponse: @@ -21044,6 +21139,7 @@ service: - thermostats - noise_sensors - access_control_systems + inline: true source: openapi: ../openapi.json DevicesListDeviceProvidersResponse: @@ -22139,6 +22235,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -22179,6 +22276,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -22193,6 +22291,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -22207,6 +22306,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -22248,6 +22348,7 @@ service: "tedee", "honeywell_resideo", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -22319,6 +22420,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json UnmanagedListRequestDeviceTypesItem: @@ -22356,6 +22458,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json UnmanagedListRequestManufacturer: @@ -22394,6 +22497,7 @@ types: - dormakaba_oracode - tedee - honeywell_resideo + inline: true source: openapi: ../openapi.json UnmanagedListRequestCustomMetadataHasValue: @@ -22413,6 +22517,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json UnmanagedListRequestExcludeIfItem: @@ -22424,6 +22529,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json UnmanagedListResponse: @@ -23062,6 +23168,7 @@ service: "value": "action_attempt.unlock_door.failed", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -23301,6 +23408,7 @@ service: "value": "action_attempt.unlock_door.failed", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -23454,6 +23562,7 @@ types: name: ActionAttemptUnlockDoorSucceeded - value: action_attempt.unlock_door.failed name: ActionAttemptUnlockDoorFailed + inline: true source: openapi: ../openapi.json EventsListRequestEventTypesItem: @@ -23574,6 +23683,7 @@ types: name: ActionAttemptUnlockDoorSucceeded - value: action_attempt.unlock_door.failed name: ActionAttemptUnlockDoorFailed + inline: true source: openapi: ../openapi.json EventsListResponse: @@ -24625,6 +24735,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -24665,6 +24776,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -24679,6 +24791,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -24693,6 +24806,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -24734,6 +24848,7 @@ service: "tedee", "honeywell_resideo", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -24819,6 +24934,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json LocksListRequestDeviceTypesItem: @@ -24856,6 +24972,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json LocksListRequestManufacturer: @@ -24894,6 +25011,7 @@ types: - dormakaba_oracode - tedee - honeywell_resideo + inline: true source: openapi: ../openapi.json LocksListRequestCustomMetadataHasValue: @@ -24913,6 +25031,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json LocksListRequestExcludeIfItem: @@ -24924,6 +25043,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json LocksListResponse: @@ -27057,6 +27177,7 @@ service: "android", "ios", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -27080,6 +27201,7 @@ service: - android - ios default: android + inline: true source: openapi: ../openapi.json SimulateCreateSandboxPhoneRequestPhoneMetadata: @@ -28118,6 +28240,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -28158,6 +28281,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -28172,6 +28296,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -28186,6 +28311,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -28227,6 +28353,7 @@ service: "tedee", "honeywell_resideo", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -28258,6 +28385,7 @@ service: "auto", "on", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -28267,6 +28395,7 @@ service: "auto", "on", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -28306,6 +28435,7 @@ service: "cool", "heat_cool", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -28384,6 +28514,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json ThermostatsListRequestDeviceTypesItem: @@ -28421,6 +28552,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json ThermostatsListRequestManufacturer: @@ -28459,6 +28591,7 @@ types: - dormakaba_oracode - tedee - honeywell_resideo + inline: true source: openapi: ../openapi.json ThermostatsListRequestCustomMetadataHasValue: @@ -28478,6 +28611,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json ThermostatsListRequestExcludeIfItem: @@ -28489,6 +28623,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json ThermostatsListResponse: @@ -28507,12 +28642,14 @@ types: enum: - auto - 'on' + inline: true source: openapi: ../openapi.json ThermostatsSetFanModeRequestFanModeSetting: enum: - auto - 'on' + inline: true source: openapi: ../openapi.json ThermostatsSetFanModeResponse: @@ -28527,6 +28664,7 @@ types: - heat - cool - heat_cool + inline: true source: openapi: ../openapi.json ThermostatsUpdateRequestDefaultClimateSetting: @@ -29480,6 +29618,7 @@ service: "cool", "heat_cool", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -29534,6 +29673,7 @@ service: "cool", "heat_cool", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -29558,6 +29698,7 @@ service: - heat - cool - heat_cool + inline: true source: openapi: ../openapi.json ClimateSettingSchedulesCreateResponse: @@ -29589,6 +29730,7 @@ service: - heat - cool - heat_cool + inline: true source: openapi: ../openapi.json ClimateSettingSchedulesUpdateResponse: @@ -32811,6 +32953,7 @@ service: "circle", "square", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -32866,6 +33009,7 @@ service: enum: - circle - square + inline: true source: openapi: ../openapi.json WorkspacesCreateResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/squidex.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/squidex.json index a0153219d83..247a8055f29 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/squidex.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/squidex.json @@ -5435,6 +5435,7 @@ "User", "Group", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -5878,6 +5879,7 @@ "Path", "Items", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -5926,6 +5928,7 @@ "Image", "FileName", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -5982,6 +5985,7 @@ "Audio", "Video", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -6219,6 +6223,7 @@ "Checkbox", "Toggle", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -6281,6 +6286,7 @@ "Move", "Delete", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -6345,6 +6351,7 @@ "Update", "Validate", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -6962,6 +6969,7 @@ "Now", "Today", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -6972,6 +6980,7 @@ "Date", "DateTime", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -7519,6 +7528,7 @@ "Hide", "Require", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -7612,6 +7622,7 @@ "TIFF", "WEBP", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -7624,6 +7635,7 @@ "Completed", "Failed", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -7830,6 +7842,7 @@ "Dropdown", "Stars", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -8054,6 +8067,7 @@ "NoPermission", "ManagedByTeam", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -8135,6 +8149,7 @@ "Checkboxes", "Input", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -8220,6 +8235,7 @@ "Min", "Stretch", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -8618,6 +8634,7 @@ "TextArea", "Url", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -8631,6 +8648,7 @@ "Failed", "Cancelled", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -8643,6 +8661,7 @@ "Failed", "Timeout", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -8930,6 +8949,7 @@ "Singleton", "Component", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -9003,6 +9023,7 @@ "Rule", "Schema", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -9146,6 +9167,7 @@ "WrongEvent", "WrongEventForTrigger", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -9196,6 +9218,7 @@ "Ascending", "Descending", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -9251,6 +9274,7 @@ "Html", "Markdown", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -9269,6 +9293,7 @@ "StockPhoto", "TextArea", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -9365,6 +9390,7 @@ "Checkboxes", "Dropdown", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -9529,6 +9555,7 @@ "Unauthorized", "Failed", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -9940,6 +9967,7 @@ "DELETE", "PATCH", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/suger.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/suger.json index 72124106e57..d8bf6e9ae50 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/suger.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/suger.json @@ -509,6 +509,7 @@ "Monthly", "Annual", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -533,6 +534,7 @@ "Engineering", "ChannelManager", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -607,6 +609,7 @@ "StopSelling", "Terminated", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -729,6 +732,7 @@ "cspCustomer", "billingGroup", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -775,6 +779,7 @@ "percentage", "absolute", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -785,6 +790,7 @@ "FLAT_RATE", "PER_USER", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -794,6 +800,7 @@ "customerPromotion", "cspPromotion", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -816,6 +823,7 @@ "withdrawn", "deleted", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -825,6 +833,7 @@ "pendingAcceptance", "accepted", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -850,6 +859,7 @@ "month", "year", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -884,6 +894,7 @@ "resourceNotFound", "schemaValidationError", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -893,6 +904,7 @@ "informational", "warning", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -943,6 +955,7 @@ "perMarket", "usd", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1007,6 +1020,7 @@ "perMarket", "usd", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1027,6 +1041,7 @@ "Month", "Year", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1050,6 +1065,7 @@ "Recurring", "Usage", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1073,6 +1089,7 @@ "sharedcore", "transactions", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1162,6 +1179,7 @@ "Public", "Private", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1219,6 +1237,7 @@ "ListingImage", "ListingVideo", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1231,6 +1250,7 @@ "Processed", "ProcessFailed", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1305,6 +1325,7 @@ "value": "contact-me", }, ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1314,6 +1335,7 @@ "ListingOnly", "ListAndSell", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1344,6 +1366,7 @@ "Inprogress", "Published", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1359,6 +1382,7 @@ "Published", "InStore", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1428,6 +1452,7 @@ "AzureSkuVariant", "AzureTestDriveVariant", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1437,6 +1462,7 @@ "InActive", "Active", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1460,6 +1486,7 @@ "Days", "Months", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1471,6 +1498,7 @@ "TimedUsage", "Unlimited", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1667,6 +1695,7 @@ This member is required.", "InvalidQuantity", "BadArgument", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2168,6 +2197,7 @@ in the google.rpc.Status.details field, or localized by the client.", "CONFIRMED", "PENDING_CONFIRMATION", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2283,6 +2313,7 @@ in the google.rpc.Status.details field, or localized by the client.", "Update", "Delete", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -2292,6 +2323,7 @@ in the google.rpc.Status.details field, or localized by the client.", "None", "Csp", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -2301,6 +2333,7 @@ in the google.rpc.Status.details field, or localized by the client.", "None", "DryRun", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -2313,6 +2346,7 @@ in the google.rpc.Status.details field, or localized by the client.", "Suspended", "Unsubscribed", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2434,6 +2468,7 @@ in the google.rpc.Status.details field, or localized by the client.", "MONTH", "YEAR", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2443,6 +2478,7 @@ in the google.rpc.Status.details field, or localized by the client.", "FLAT_RATE", "PER_USER", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2567,6 +2603,7 @@ in the google.rpc.Status.details field, or localized by the client.", "QuantityChange", "Signup", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2593,6 +2630,7 @@ in the google.rpc.Status.details field, or localized by the client.", "ENTITLEMENT_TERM", "INTEGRATION", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2609,6 +2647,7 @@ in the google.rpc.Status.details field, or localized by the client.", "ISV", "CURRENT", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2714,6 +2753,7 @@ in the google.rpc.Status.details field, or localized by the client.", "USAGE", "SUBSCRIPTION_PLUS_USAGE", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3069,6 +3109,7 @@ This field is present only if the product has usage-based billing configured.", "value": "ENTITLEMENT_SUSPENDED", }, ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3138,6 +3179,7 @@ This field is present only if the product has usage-based billing configured.", "APPROVED", "REJECTED", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3153,6 +3195,7 @@ This field is present only if the product has usage-based billing configured.", "value": "ACCOUNT_ACTIVE", }, ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3273,6 +3316,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3301,6 +3345,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3311,6 +3356,7 @@ This field is present only if the product has usage-based billing configured.", "VERIFIED", "NOT_VERIFIED", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3589,6 +3635,7 @@ This field is present only if the product has usage-based billing configured.", "NOTIFY_CONTACTS", "TEST", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3604,6 +3651,7 @@ This field is present only if the product has usage-based billing configured.", "DONE", "FAILED", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3671,6 +3719,7 @@ This field is present only if the product has usage-based billing configured.", "PRIVATE", "PUBLIC", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3863,6 +3912,7 @@ This field is present only if the product has usage-based billing configured.", "CollectableAmount", "DisbursedAmount", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3984,6 +4034,7 @@ This field is present only if the product has usage-based billing configured.", "DISTRIBUTION", "MONEY", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -4025,6 +4076,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -4037,6 +4089,7 @@ This field is present only if the product has usage-based billing configured.", "PENDING_START", "UNKNOWN", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -4076,6 +4129,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -4123,6 +4177,7 @@ This field is present only if the product has usage-based billing configured.", "PRIVATE", "UNKNOWN", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -4133,6 +4188,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -4150,6 +4206,7 @@ This field is present only if the product has usage-based billing configured.", "CANCEL_FAILED", "CANCEL_SUCCESS", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -4183,6 +4240,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -4196,6 +4254,7 @@ This field is present only if the product has usage-based billing configured.", "PER_USER", "USAGE_BASED", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -4409,6 +4468,7 @@ the same customer, dimension, and time, but a different quantity.", "CustomerNotSubscribed", "DuplicateRecord", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -4738,6 +4798,7 @@ types: enum: - Monthly - Annual + inline: true source: openapi: ../swagger.json AzureIncludedBaseQuantity: @@ -4752,6 +4813,7 @@ types: - CustomerSupport - Engineering - ChannelManager + inline: true source: openapi: ../swagger.json AzureListingContact: @@ -4797,6 +4859,7 @@ types: - Enabled - StopSelling - Terminated + inline: true source: openapi: ../swagger.json AzureMarketState: @@ -4823,6 +4886,7 @@ types: enum: - customerPromotion - cspPromotion + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOfferState: @@ -4831,12 +4895,14 @@ types: - live - withdrawn - deleted + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOfferSubState: enum: - pendingAcceptance - accepted + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOffer: @@ -4905,6 +4971,7 @@ types: enum: - cspCustomer - billingGroup + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOfferBeneficiaryRecipient: @@ -4917,6 +4984,7 @@ types: enum: - percentage - absolute + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOfferPricingPlanType: @@ -4924,6 +4992,7 @@ types: - FLAT_RATE - PER_USER docs: The type of the plan, FLAT_RATE or PER_USER. + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOfferPricing: @@ -4964,6 +5033,7 @@ types: - week - month - year + inline: true source: openapi: ../swagger.json AzureMarketplaceTerm: @@ -4989,12 +5059,14 @@ types: - productLocked - resourceNotFound - schemaValidationError + inline: true source: openapi: ../swagger.json AzureMarketplaceValidationLevel: enum: - informational - warning + inline: true source: openapi: ../swagger.json AzureMarketplaceValidation: @@ -5026,6 +5098,7 @@ types: - perMarket - usd docs: default "usd" + inline: true source: openapi: ../swagger.json AzurePriceAndAvailabilityPrivateOfferCustomMeters: @@ -5059,6 +5132,7 @@ types: - perMarket - usd docs: default "usd" + inline: true source: openapi: ../swagger.json AzurePriceAndAvailabilityRecurrentPrice: @@ -5081,6 +5155,7 @@ types: enum: - Month - Year + inline: true source: openapi: ../swagger.json AzurePriceCadence: @@ -5094,6 +5169,7 @@ types: - Flat - Recurring - Usage + inline: true source: openapi: ../swagger.json AzurePriceSchedule: @@ -5108,6 +5184,7 @@ types: enum: - sharedcore - transactions + inline: true source: openapi: ../swagger.json AzurePricingUnit: @@ -5163,6 +5240,7 @@ types: enum: - Public - Private + inline: true source: openapi: ../swagger.json AzureProductFeatureAvailability: @@ -5210,6 +5288,7 @@ types: - ListingAsset - ListingImage - ListingVideo + inline: true source: openapi: ../swagger.json AzureProductListingAssetState: @@ -5219,6 +5298,7 @@ types: - InProcessing - Processed - ProcessFailed + inline: true source: openapi: ../swagger.json AzureProductListingAsset: @@ -5274,12 +5354,14 @@ types: name: FreeTrial - value: contact-me name: ContactMe + inline: true source: openapi: ../swagger.json AzureProductSetupSellingOption: enum: - ListingOnly - ListAndSell + inline: true source: openapi: ../swagger.json AzureProductSetup: @@ -5297,6 +5379,7 @@ types: enum: - Inprogress - Published + inline: true source: openapi: ../swagger.json AzureProductSubmissionSubState: @@ -5309,6 +5392,7 @@ types: - Publishing - Published - InStore + inline: true source: openapi: ../swagger.json AzureProductSubmission: @@ -5331,12 +5415,14 @@ types: enum: - AzureSkuVariant - AzureTestDriveVariant + inline: true source: openapi: ../swagger.json AzureProductVariantState: enum: - InActive - Active + inline: true source: openapi: ../swagger.json AzureProductVariant: @@ -5386,6 +5472,7 @@ types: - Minute - Days - Months + inline: true source: openapi: ../swagger.json AzureProductVariantTrialType: @@ -5394,6 +5481,7 @@ types: - TimedAccess - TimedUsage - Unlimited + inline: true source: openapi: ../swagger.json AzureProductVariantTrial: @@ -5992,18 +6080,21 @@ types: - Read - Update - Delete + inline: true source: openapi: ../swagger.json SharedAzureMarketplaceSubscriptionSandboxType: enum: - None - Csp + inline: true source: openapi: ../swagger.json SharedAzureMarketplaceSubscriptionSessionMode: enum: - None - DryRun + inline: true source: openapi: ../swagger.json SharedAzureMarketplaceSubscription: @@ -6787,6 +6878,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedIdentityBuyer: @@ -6807,6 +6899,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedIdentityIntegrationStatus: @@ -6814,6 +6907,7 @@ types: - CREATED - VERIFIED - NOT_VERIFIED + inline: true source: openapi: ../swagger.json SharedIdentityIntegration: @@ -7050,6 +7144,7 @@ types: - PRIVATE - PUBLIC docs: The default visibility of offer is PRIVATE. + inline: true source: openapi: ../swagger.json SharedOfferInfo: @@ -7340,6 +7435,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedWorkloadEntitlementStatus: @@ -7349,6 +7445,7 @@ types: - SUSPENDED - PENDING_START - UNKNOWN + inline: true source: openapi: ../swagger.json SharedWorkloadEntitlement: @@ -7381,6 +7478,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedWorkloadEntitlementTerm: @@ -7416,6 +7514,7 @@ types: - PER_USER - PRIVATE - UNKNOWN + inline: true source: openapi: ../swagger.json SharedWorkloadOfferPartner: @@ -7423,6 +7522,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedWorkloadOfferStatus: @@ -7437,6 +7537,7 @@ types: - PENDING_CANCEL - CANCEL_FAILED - CANCEL_SUCCESS + inline: true source: openapi: ../swagger.json SharedWorkloadOffer: @@ -7469,6 +7570,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedWorkloadProductProductType: @@ -7479,6 +7581,7 @@ types: - FLAT_RATE - PER_USER - USAGE_BASED + inline: true source: openapi: ../swagger.json SharedWorkloadProduct: @@ -8996,6 +9099,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -10480,6 +10584,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -10489,6 +10594,7 @@ service: "MARKETPLACE", "CRM", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -10499,6 +10605,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -10508,6 +10615,7 @@ service: "MARKETPLACE", "CRM", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -10518,6 +10626,7 @@ service: "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -10528,6 +10637,7 @@ service: "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -10538,6 +10648,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -10547,6 +10658,7 @@ service: "MARKETPLACE", "CRM", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -10557,6 +10669,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -10566,6 +10679,7 @@ service: "MARKETPLACE", "CRM", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -10985,6 +11099,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json GetIntegrationRequestPartner: @@ -11031,6 +11146,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json VerifyIntegrationRequestPartner: @@ -13146,6 +13262,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -14465,6 +14582,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -15210,6 +15328,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -15220,6 +15339,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -15231,6 +15351,7 @@ service: "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -15258,6 +15379,7 @@ service: - AZURE - GCP docs: Required. + inline: true source: openapi: ../swagger.json imports: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/switchboard.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/switchboard.json index a1ceab6b0ca..df185a8d563 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/switchboard.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/switchboard.json @@ -203,6 +203,7 @@ "partial_success", "failure", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -648,6 +649,7 @@ "running", "ended", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -815,6 +817,7 @@ types: - success - partial_success - failure + inline: true source: openapi: ../openapi.yml ExternalSessionAiResponseMetadata: @@ -1098,6 +1101,7 @@ types: - running - ended docs: Status of the session + inline: true source: openapi: ../openapi.yml StatusMessage: @@ -2484,6 +2488,7 @@ service: "running", "ended", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/uploadcare.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/uploadcare.json index d7619a2c760..6869002d6b3 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/uploadcare.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/uploadcare.json @@ -1505,6 +1505,7 @@ that are tool old (or that have not been created at all). "HSV", "LAB", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1838,6 +1839,7 @@ See [docs](https://uploadcare.com/docs/file-metadata/) and [REST API v0.7](/api- "HSV", "LAB", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1916,6 +1918,7 @@ change the value to `auto`. }, "auto", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2641,6 +2644,7 @@ change the value to `auto`. - HSV - LAB docs: Image color mode. + inline: true source: openapi: ../openapi.json ImageInfoGeoLocation: @@ -2765,6 +2769,7 @@ change the value to `auto`. - HSV - LAB docs: Image color mode. + inline: true source: openapi: ../openapi.json SchemasImageInfoGeoLocation: @@ -6177,6 +6182,7 @@ this request will return information about the already uploaded file. "value": "1", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -6196,6 +6202,7 @@ to the value of the `check_URL_duplicates` parameter. "value": "1", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -6289,6 +6296,7 @@ types: this request will return information about the already uploaded file. default: '0' + inline: true source: openapi: ../openapi.json FromUrlUploadRequestSaveUrlDuplicates: @@ -6301,6 +6309,7 @@ types: Determines if the requested `source_url` should be kept in the history of fetched/uploaded URLs. If the value is not defined explicitly, it is set to the value of the `check_URL_duplicates` parameter. + inline: true source: openapi: ../openapi.json FromUrlUploadResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/valtown.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/valtown.json index 9fe9e1bf06a..98f13da2cd0 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/valtown.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/valtown.json @@ -215,6 +215,7 @@ "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -230,6 +231,7 @@ "rpc", "httpnext", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -422,6 +424,7 @@ "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -437,6 +440,7 @@ "rpc", "httpnext", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -728,6 +732,7 @@ This value is not specified if the SQL statement was not an INSERT or if the tab docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml ExtendedValType: @@ -743,6 +748,7 @@ This value is not specified if the SQL statement was not an INSERT or if the tab The type of a val. HTTP can receive web requests, Email can receive emails, Cron runs periodically, and Script can be used for libraries or one-off calculations + inline: true source: openapi: ../openapi.yml ExtendedValLinks: @@ -841,6 +847,7 @@ This value is not specified if the SQL statement was not an INSERT or if the tab docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml BasicValType: @@ -856,6 +863,7 @@ This value is not specified if the SQL statement was not an INSERT or if the tab The type of a val. HTTP can receive web requests, Email can receive emails, Cron runs periodically, and Script can be used for libraries or one-off calculations + inline: true source: openapi: ../openapi.yml BasicValLinks: @@ -1277,6 +1285,7 @@ API endpoints", "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1292,6 +1301,7 @@ API endpoints", "rpc", "httpnext", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1390,6 +1400,7 @@ types: docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml AliasValResponseType: @@ -1405,6 +1416,7 @@ types: The type of a val. HTTP can receive web requests, Email can receive emails, Cron runs periodically, and Script can be used for libraries or one-off calculations + inline: true source: openapi: ../openapi.yml AliasValResponseLinks: @@ -2358,6 +2370,7 @@ give access to details and data from the requesting user.", "received", "given", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2484,6 +2497,7 @@ give access to details and data from the requesting user.", "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2569,6 +2583,7 @@ give access to details and data from the requesting user.", "free", "pro", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2705,6 +2720,7 @@ give access to details and data from the requesting user.", - free - pro docs: Your account tier + inline: true source: openapi: ../openapi.yml MeGetResponse: @@ -2775,6 +2791,7 @@ give access to details and data from the requesting user.", docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml MeCommentsResponseDataItemValAuthor: @@ -3471,6 +3488,7 @@ docs: Search "read", "deferred", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3608,6 +3626,7 @@ docs: Search - write - read - deferred + inline: true source: openapi: ../openapi.yml imports: @@ -4855,6 +4874,7 @@ let you get, create, and run vals.", "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4867,6 +4887,7 @@ let you get, create, and run vals.", "script", "email", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4878,6 +4899,7 @@ let you get, create, and run vals.", "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4890,6 +4912,7 @@ let you get, create, and run vals.", "script", "email", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4943,6 +4966,7 @@ let you get, create, and run vals.", "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4954,6 +4978,7 @@ let you get, create, and run vals.", "script", "email", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4989,6 +5014,7 @@ let you get, create, and run vals.", docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml ValsCreateRequestType: @@ -5000,6 +5026,7 @@ let you get, create, and run vals.", The type of the val you want to create. Note that this does not include interval vals, because they cannot be created through the API yet. default: script + inline: true source: openapi: ../openapi.yml ValsUpdateRequestPrivacy: @@ -5010,6 +5037,7 @@ let you get, create, and run vals.", docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml ValsUpdateRequestType: @@ -5020,6 +5048,7 @@ let you get, create, and run vals.", docs: >- The type of the val you want to update. Note that this does not include interval vals, because they cannot be created through the API yet. + inline: true source: openapi: ../openapi.yml ValsListResponseDataItem: @@ -5053,6 +5082,7 @@ let you get, create, and run vals.", docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml ValsCreateVersionRequestType: @@ -5064,6 +5094,7 @@ let you get, create, and run vals.", The type of the val you want to create. Note that this does not include interval vals, because they cannot be created through the API yet. default: script + inline: true source: openapi: ../openapi.yml ValsCancelResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/vellum.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/vellum.json index 55d38ec4f57..d76118da1db 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/vellum.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/vellum.json @@ -755,6 +755,7 @@ Used to submit feedback regarding the quality of previously generated completion "JINJA", "FUNCTION_DEFINITION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -792,6 +793,7 @@ Used to submit feedback regarding the quality of previously generated completion "USER", "FUNCTION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -823,6 +825,7 @@ Used to submit feedback regarding the quality of previously generated completion "STRING", "JSON", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -922,6 +925,7 @@ Used to submit feedback regarding the quality of previously generated completion "INACTIVE", "ARCHIVED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1069,6 +1073,7 @@ Used to submit feedback regarding the quality of previously generated completion "ACTIVE", "ARCHIVED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1126,6 +1131,7 @@ Used to submit feedback regarding the quality of previously generated completion "STAGING", "PRODUCTION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1165,6 +1171,7 @@ Used to submit feedback regarding the quality of previously generated completion "STOP", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1321,6 +1328,7 @@ Used to submit feedback regarding the quality of previously generated completion "INDEXED", "FAILED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1332,6 +1340,7 @@ Used to submit feedback regarding the quality of previously generated completion "ALL", "NONE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1343,6 +1352,7 @@ Used to submit feedback regarding the quality of previously generated completion "GENERATE", "CLASSIFY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1524,6 +1534,7 @@ Used to submit feedback regarding the quality of previously generated completion "CREATION_FAILED", "DISABLED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1625,6 +1636,7 @@ Used to submit feedback regarding the quality of previously generated completion "PROCESSED", "FAILED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1812,6 +1824,7 @@ Used to submit feedback regarding the quality of previously generated completion "OPENAI", "PYQ", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2083,6 +2096,7 @@ Used to submit feedback regarding the quality of previously generated completion "TEXT", "CHAT_HISTORY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2506,6 +2520,7 @@ Used to submit feedback regarding the quality of previously generated completion "WORKFLOW_INITIALIZATION", "NODE_EXECUTION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2579,6 +2594,7 @@ Used to submit feedback regarding the quality of previously generated completion "FULFILLED", "REJECTED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/webflow.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/webflow.json index 990b700a52c..4b4d4e67bf2 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/webflow.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/webflow.json @@ -4095,6 +4095,7 @@ "value": "site_config:write", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8919,6 +8920,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "value": "-CreatedOn", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11313,6 +11315,7 @@ service: "Color", "ExtFileRef", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11408,6 +11411,7 @@ service: "Color", "ExtFileRef", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11510,6 +11514,7 @@ service: - Color - ExtFileRef docs: Choose these appropriate field type for your collection data + inline: true source: openapi: ../openapi.yml CollectionsCreateResponseFieldsItem: @@ -11585,6 +11590,7 @@ service: - Color - ExtFileRef docs: Choose these appropriate field type for your collection data + inline: true source: openapi: ../openapi.yml CollectionsGetResponseFieldsItem: @@ -12042,6 +12048,7 @@ service: "Color", "File", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12100,6 +12107,7 @@ service: "Color", "ExtFileRef", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12158,6 +12166,7 @@ service: "Color", "ExtFileRef", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12181,6 +12190,7 @@ service: - Color - File docs: Choose these appropriate field type for your collection data + inline: true source: openapi: ../openapi.yml FieldsCreateResponseType: @@ -12199,6 +12209,7 @@ service: - Color - ExtFileRef docs: Choose these appropriate field type for your collection data + inline: true source: openapi: ../openapi.yml FieldsCreateResponse: @@ -12245,6 +12256,7 @@ service: - Color - ExtFileRef docs: Choose these appropriate field type for your collection data + inline: true source: openapi: ../openapi.yml FieldsUpdateResponse: @@ -13737,6 +13749,7 @@ service: "name", "slug", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13746,6 +13759,7 @@ service: "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13852,6 +13866,7 @@ service: "name", "slug", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13861,6 +13876,7 @@ service: "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16147,6 +16163,7 @@ service: "Phone", "Number", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16314,6 +16331,7 @@ service: "Phone", "Number", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16533,6 +16551,7 @@ service: - Phone - Number docs: The field type + inline: true source: openapi: ../openapi.yml FormsListResponseFormsItemFieldsValue: @@ -16645,6 +16664,7 @@ service: - Phone - Number docs: The field type + inline: true source: openapi: ../openapi.yml FormsGetResponseFieldsValue: @@ -17363,6 +17383,7 @@ Required scope | `ecommerce:write` "infinite", "finite", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17394,6 +17415,7 @@ Required scope | `ecommerce:write` "infinite", "finite", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17404,6 +17426,7 @@ Required scope | `ecommerce:write` "infinite", "finite", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17435,6 +17458,7 @@ Required scope | `ecommerce:write` "infinite", "finite", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17468,6 +17492,7 @@ Required scope | `ecommerce:write` - infinite - finite docs: infinite or finite + inline: true source: openapi: ../openapi.yml InventoryListResponse: @@ -17491,6 +17516,7 @@ Required scope | `ecommerce:write` - infinite - finite docs: infinite or finite + inline: true source: openapi: ../openapi.yml InventoryUpdateResponseInventoryType: @@ -17498,6 +17524,7 @@ Required scope | `ecommerce:write` - infinite - finite docs: infinite or finite + inline: true source: openapi: ../openapi.yml InventoryUpdateResponse: @@ -17521,6 +17548,7 @@ Required scope | `ecommerce:write` - infinite - finite docs: infinite or finite + inline: true source: openapi: ../openapi.yml EcommInventoryChangedPayload: @@ -20253,6 +20281,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20263,6 +20292,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20339,6 +20369,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20349,6 +20380,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20410,6 +20442,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20753,6 +20786,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20763,6 +20797,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20781,6 +20816,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20828,6 +20864,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20968,6 +21005,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21219,6 +21257,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21229,6 +21268,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21305,6 +21345,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21315,6 +21356,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21376,6 +21418,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21719,6 +21762,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21729,6 +21773,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21747,6 +21792,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21794,6 +21840,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21934,6 +21981,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22185,6 +22233,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22195,6 +22244,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22271,6 +22321,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22281,6 +22332,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22342,6 +22394,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22685,6 +22738,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22695,6 +22749,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22713,6 +22768,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22760,6 +22816,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22900,6 +22957,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22958,6 +23016,7 @@ Required scope | `ecommerce:write` "disputed", "unfulfilled", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -23184,6 +23243,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23194,6 +23254,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23270,6 +23331,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23280,6 +23342,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23341,6 +23404,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23684,6 +23748,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23694,6 +23759,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23712,6 +23778,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23759,6 +23826,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23899,6 +23967,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23973,6 +24042,7 @@ Required scope | `ecommerce:write` "fraudulent", "requested", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -24182,6 +24252,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -24192,6 +24263,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -24268,6 +24340,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -24278,6 +24351,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -24339,6 +24413,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -24682,6 +24757,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -24692,6 +24768,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -24710,6 +24787,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -24757,6 +24835,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -24897,6 +24976,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -25148,6 +25228,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -25158,6 +25239,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -25234,6 +25316,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -25244,6 +25327,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -25305,6 +25389,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -25648,6 +25733,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -25658,6 +25744,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -25676,6 +25763,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -25723,6 +25811,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -25863,6 +25952,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26114,6 +26204,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26124,6 +26215,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26200,6 +26292,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26210,6 +26303,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26271,6 +26365,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26614,6 +26709,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26624,6 +26720,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26642,6 +26739,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26689,6 +26787,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26829,6 +26928,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -27080,6 +27180,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -27090,6 +27191,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -27166,6 +27268,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -27176,6 +27279,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -27237,6 +27341,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -27580,6 +27685,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -27590,6 +27696,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -27608,6 +27715,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -27655,6 +27763,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -27795,6 +27904,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -28320,6 +28430,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemDisputeLastStatus: @@ -28335,6 +28446,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemCustomerPaid: @@ -28387,6 +28499,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemAllAddressesItemJapanType: @@ -28396,6 +28509,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemAllAddressesItem: @@ -28438,6 +28552,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemShippingAddressJapanType: @@ -28447,6 +28562,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemShippingAddress: @@ -28489,6 +28605,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemBillingAddressJapanType: @@ -28498,6 +28615,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemBillingAddress: @@ -28730,6 +28848,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemStripeCardExpires: @@ -28816,6 +28935,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemTotalsExtrasItemPrice: @@ -29071,6 +29191,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersGetResponseDisputeLastStatus: @@ -29086,6 +29207,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersGetResponseCustomerPaid: @@ -29138,6 +29260,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersGetResponseAllAddressesItemJapanType: @@ -29147,6 +29270,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersGetResponseAllAddressesItem: @@ -29189,6 +29313,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersGetResponseShippingAddressJapanType: @@ -29198,6 +29323,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersGetResponseShippingAddress: @@ -29240,6 +29366,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersGetResponseBillingAddressJapanType: @@ -29249,6 +29376,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersGetResponseBillingAddress: @@ -29481,6 +29609,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersGetResponseStripeCardExpires: @@ -29567,6 +29696,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersGetResponseTotalsExtrasItemPrice: @@ -29795,6 +29925,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseDisputeLastStatus: @@ -29810,6 +29941,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseCustomerPaid: @@ -29862,6 +29994,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseAllAddressesItemJapanType: @@ -29871,6 +30004,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseAllAddressesItem: @@ -29913,6 +30047,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseShippingAddressJapanType: @@ -29922,6 +30057,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseShippingAddress: @@ -29964,6 +30100,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseBillingAddressJapanType: @@ -29973,6 +30110,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseBillingAddress: @@ -30205,6 +30343,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseStripeCardExpires: @@ -30291,6 +30430,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseTotalsExtrasItemPrice: @@ -30519,6 +30659,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseDisputeLastStatus: @@ -30534,6 +30675,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseCustomerPaid: @@ -30586,6 +30728,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseAllAddressesItemJapanType: @@ -30595,6 +30738,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseAllAddressesItem: @@ -30637,6 +30781,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseShippingAddressJapanType: @@ -30646,6 +30791,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseShippingAddress: @@ -30688,6 +30834,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseBillingAddressJapanType: @@ -30697,6 +30844,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseBillingAddress: @@ -30929,6 +31077,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseStripeCardExpires: @@ -31015,6 +31164,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseTotalsExtrasItemPrice: @@ -31243,6 +31393,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseDisputeLastStatus: @@ -31258,6 +31409,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseCustomerPaid: @@ -31310,6 +31462,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseAllAddressesItemJapanType: @@ -31319,6 +31472,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseAllAddressesItem: @@ -31361,6 +31515,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseShippingAddressJapanType: @@ -31370,6 +31525,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseShippingAddress: @@ -31412,6 +31568,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseBillingAddressJapanType: @@ -31421,6 +31578,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseBillingAddress: @@ -31654,6 +31812,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseStripeCardExpires: @@ -31740,6 +31899,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseTotalsExtrasItemPrice: @@ -31963,6 +32123,7 @@ Required scope | `ecommerce:write` - fraudulent - requested docs: The reason for the refund + inline: true source: openapi: ../openapi.yml OrdersRefundResponseStatus: @@ -31976,6 +32137,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersRefundResponseDisputeLastStatus: @@ -31991,6 +32153,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersRefundResponseCustomerPaid: @@ -32043,6 +32206,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersRefundResponseAllAddressesItemJapanType: @@ -32052,6 +32216,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersRefundResponseAllAddressesItem: @@ -32094,6 +32259,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersRefundResponseShippingAddressJapanType: @@ -32103,6 +32269,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersRefundResponseShippingAddress: @@ -32145,6 +32312,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersRefundResponseBillingAddressJapanType: @@ -32154,6 +32322,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersRefundResponseBillingAddress: @@ -32386,6 +32555,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersRefundResponseStripeCardExpires: @@ -32472,6 +32642,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersRefundResponseTotalsExtrasItemPrice: @@ -32700,6 +32871,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadDisputeLastStatus: @@ -32715,6 +32887,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadCustomerPaid: @@ -32767,6 +32940,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadAllAddressesItemJapanType: @@ -32776,6 +32950,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadAllAddressesItem: @@ -32818,6 +32993,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadShippingAddressJapanType: @@ -32827,6 +33003,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadShippingAddress: @@ -32869,6 +33046,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadBillingAddressJapanType: @@ -32878,6 +33056,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadBillingAddress: @@ -33110,6 +33289,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadStripeCardExpires: @@ -33196,6 +33376,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadTotalsExtrasItemPrice: @@ -33424,6 +33605,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadDisputeLastStatus: @@ -33439,6 +33621,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadCustomerPaid: @@ -33491,6 +33674,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadAllAddressesItemJapanType: @@ -33500,6 +33684,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadAllAddressesItem: @@ -33542,6 +33727,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadShippingAddressJapanType: @@ -33551,6 +33737,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadShippingAddress: @@ -33593,6 +33780,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadBillingAddressJapanType: @@ -33602,6 +33790,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadBillingAddress: @@ -33834,6 +34023,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadStripeCardExpires: @@ -33920,6 +34110,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadTotalsExtrasItemPrice: @@ -36650,6 +36841,7 @@ Required scope | `pages:write` "text", "image", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -37578,6 +37770,7 @@ Required scope | `pages:write` enum: - text - image + inline: true source: openapi: ../openapi.yml PagesGetContentResponseNodesItemText: @@ -38445,6 +38638,7 @@ webhooks: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38482,6 +38676,7 @@ webhooks: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38540,6 +38735,7 @@ webhooks: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38555,6 +38751,7 @@ webhooks: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsGetCustomCodeResponseScriptsItem: @@ -38600,6 +38797,7 @@ webhooks: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsUpsertCustomCodeRequestScriptsItem: @@ -38632,6 +38830,7 @@ webhooks: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsUpsertCustomCodeResponseScriptsItem: @@ -39685,6 +39884,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -39848,6 +40048,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -39859,6 +40060,7 @@ Required scope | `ecommerce:write` "staging", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -39962,6 +40164,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -39996,6 +40199,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40028,6 +40232,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40162,6 +40367,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40325,6 +40531,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40428,6 +40635,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40462,6 +40670,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40494,6 +40703,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40522,6 +40732,7 @@ Required scope | `ecommerce:write` "staging", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40625,6 +40836,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40659,6 +40871,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40691,6 +40904,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40821,6 +41035,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40855,6 +41070,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40887,6 +41103,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41021,6 +41238,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41184,6 +41402,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41287,6 +41506,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41321,6 +41541,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41353,6 +41574,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41504,6 +41726,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41667,6 +41890,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41770,6 +41994,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41804,6 +42029,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41836,6 +42062,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41974,6 +42201,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42137,6 +42365,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42148,6 +42377,7 @@ Required scope | `ecommerce:write` "staging", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42251,6 +42481,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42285,6 +42516,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42317,6 +42549,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42434,6 +42667,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42597,6 +42831,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42608,6 +42843,7 @@ Required scope | `ecommerce:write` "staging", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42711,6 +42947,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42745,6 +42982,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42777,6 +43015,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42897,6 +43136,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42931,6 +43171,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42963,6 +43204,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43080,6 +43322,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsListResponseItemsItemProductFieldDataEcProductType: @@ -43093,6 +43336,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsListResponseItemsItemProductFieldData: @@ -43200,6 +43444,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsListResponseItemsItemSkusItemFieldDataEcSkuSubscriptionPlanInterval: @@ -43209,6 +43454,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsListResponseItemsItemSkusItemFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -43217,6 +43463,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsListResponseItemsItemSkusItemFieldDataEcSkuSubscriptionPlanPlansItem: @@ -43357,6 +43604,7 @@ Required scope | `ecommerce:write` - live docs: Indicate whether your Product should be set as "staging" or "live" default: staging + inline: true source: openapi: ../openapi.yml ProductsCreateRequestProductFieldDataSkuPropertiesItemEnumItem: @@ -43451,6 +43699,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsCreateRequestProductFieldDataEcProductType: @@ -43464,6 +43713,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsCreateRequestProductFieldData: @@ -43547,6 +43797,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsCreateRequestSkuFieldDataEcSkuSubscriptionPlanInterval: @@ -43556,6 +43807,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsCreateRequestSkuFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -43564,6 +43816,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsCreateRequestSkuFieldDataEcSkuSubscriptionPlanPlansItem: @@ -43748,6 +44001,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsCreateResponseProductFieldDataEcProductType: @@ -43761,6 +44015,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsCreateResponseProductFieldData: @@ -43868,6 +44123,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsCreateResponseSkusItemFieldDataEcSkuSubscriptionPlanInterval: @@ -43877,6 +44133,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsCreateResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -43885,6 +44142,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsCreateResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItem: @@ -44080,6 +44338,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsGetResponseProductFieldDataEcProductType: @@ -44093,6 +44352,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsGetResponseProductFieldData: @@ -44199,6 +44459,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsGetResponseSkusItemFieldDataEcSkuSubscriptionPlanInterval: @@ -44208,6 +44469,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsGetResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -44216,6 +44478,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsGetResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItem: @@ -44325,6 +44588,7 @@ Required scope | `ecommerce:write` - live docs: Indicate whether your Product should be set as "staging" or "live" default: staging + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestProductFieldDataSkuPropertiesItemEnumItem: @@ -44419,6 +44683,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestProductFieldDataEcProductType: @@ -44432,6 +44697,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestProductFieldData: @@ -44538,6 +44804,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestSkuFieldDataEcSkuSubscriptionPlanInterval: @@ -44547,6 +44814,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestSkuFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -44555,6 +44823,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestSkuFieldDataEcSkuSubscriptionPlanPlansItem: @@ -44739,6 +45008,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsUpdateResponseFieldDataEcProductType: @@ -44752,6 +45022,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsUpdateResponseFieldData: @@ -44834,6 +45105,7 @@ Required scope | `ecommerce:write` - live docs: Indicate whether your Product should be set as "staging" or "live" default: staging + inline: true source: openapi: ../openapi.yml ProductsCreateSkuRequestSkusItemFieldDataPrice: @@ -44865,6 +45137,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsCreateSkuRequestSkusItemFieldDataEcSkuSubscriptionPlanInterval: @@ -44874,6 +45147,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsCreateSkuRequestSkusItemFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -44882,6 +45156,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsCreateSkuRequestSkusItemFieldDataEcSkuSubscriptionPlanPlansItem: @@ -45003,6 +45278,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsCreateSkuResponseSkusItemFieldDataEcSkuSubscriptionPlanInterval: @@ -45012,6 +45288,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsCreateSkuResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -45020,6 +45297,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsCreateSkuResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItem: @@ -45124,6 +45402,7 @@ Required scope | `ecommerce:write` - live docs: Indicate whether your Product should be set as "staging" or "live" default: staging + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuRequestSkuFieldDataPrice: @@ -45155,6 +45434,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuRequestSkuFieldDataEcSkuSubscriptionPlanInterval: @@ -45164,6 +45444,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuRequestSkuFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -45172,6 +45453,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuRequestSkuFieldDataEcSkuSubscriptionPlanPlansItem: @@ -45293,6 +45575,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuResponseFieldDataEcSkuSubscriptionPlanInterval: @@ -45302,6 +45585,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuResponseFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -45310,6 +45594,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuResponseFieldDataEcSkuSubscriptionPlanPlansItem: @@ -48347,6 +48632,7 @@ webhooks: "UNPUBLISHED", "DELETED", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -48393,6 +48679,7 @@ webhooks: - PUBLISHED - UNPUBLISHED - DELETED + inline: true source: openapi: ../openapi.yml ActivityLogsListResponseItemsItemUser: @@ -48859,6 +49146,7 @@ service: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -48943,6 +49231,7 @@ service: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -48953,6 +49242,7 @@ service: "page", "site", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -49011,6 +49301,7 @@ service: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -49069,6 +49360,7 @@ service: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -49084,6 +49376,7 @@ service: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsGetCustomCodeResponseScriptsItem: @@ -49129,6 +49422,7 @@ service: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsUpsertCustomCodeRequestScriptsItem: @@ -49161,6 +49455,7 @@ service: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsUpsertCustomCodeResponseScriptsItem: @@ -49203,6 +49498,7 @@ service: - page - site docs: Whether the Custom Code script is applied at the Site-level or Page-level + inline: true source: openapi: ../openapi.yml ScriptsListCustomCodeBlocksResponseBlocksItemScriptsItemLocation: @@ -49213,6 +49509,7 @@ service: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsListCustomCodeBlocksResponseBlocksItemScriptsItem: @@ -50395,6 +50692,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50449,6 +50747,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50460,6 +50759,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "user_account_updated", "user_account_deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50557,6 +50857,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50611,6 +50912,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50622,6 +50924,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "user_account_updated", "user_account_deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50719,6 +51022,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50773,6 +51077,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50784,6 +51089,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "user_account_updated", "user_account_deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50863,6 +51169,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50917,6 +51224,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -50996,6 +51304,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -51050,6 +51359,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -51107,6 +51417,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "value": "-UpdatedOn", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -51217,6 +51528,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -51271,6 +51583,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -51374,6 +51687,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -51428,6 +51742,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -51564,6 +51879,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UsersListResponseUsersItemAccessGroupsItemType: @@ -51574,6 +51890,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UsersListResponseUsersItemAccessGroupsItem: @@ -51687,6 +52004,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UsersGetResponseAccessGroupsItemType: @@ -51697,6 +52015,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UsersGetResponseAccessGroupsItem: @@ -51804,6 +52123,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UsersUpdateResponseAccessGroupsItemType: @@ -51814,6 +52134,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UsersUpdateResponseAccessGroupsItem: @@ -51904,6 +52225,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UsersInviteResponseAccessGroupsItemType: @@ -51914,6 +52236,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UsersInviteResponseAccessGroupsItem: @@ -52004,6 +52327,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - user_account_updated - user_account_deleted docs: The type of event that triggered the request + inline: true source: openapi: ../openapi.yml UserAccountAddedPayloadPayloadStatus: @@ -52012,6 +52336,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UserAccountAddedPayloadPayloadAccessGroupsItemType: @@ -52022,6 +52347,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UserAccountAddedPayloadPayloadAccessGroupsItem: @@ -52127,6 +52453,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - user_account_updated - user_account_deleted docs: The type of event that triggered the request + inline: true source: openapi: ../openapi.yml UserAccountUpdatedPayloadPayloadStatus: @@ -52135,6 +52462,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UserAccountUpdatedPayloadPayloadAccessGroupsItemType: @@ -52145,6 +52473,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UserAccountUpdatedPayloadPayloadAccessGroupsItem: @@ -52250,6 +52579,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - user_account_updated - user_account_deleted docs: The type of event that triggered the request + inline: true source: openapi: ../openapi.yml UserAccountDeletedPayloadPayloadStatus: @@ -52258,6 +52588,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UserAccountDeletedPayloadPayloadAccessGroupsItemType: @@ -52268,6 +52599,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UserAccountDeletedPayloadPayloadAccessGroupsItem: @@ -53061,6 +53393,7 @@ webhooks: "collection_item_deleted", "collection_item_unpublished", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -53168,6 +53501,7 @@ webhooks: "collection_item_deleted", "collection_item_unpublished", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -53275,6 +53609,7 @@ webhooks: "collection_item_deleted", "collection_item_unpublished", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -53417,6 +53752,7 @@ webhooks: "collection_item_deleted", "collection_item_unpublished", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -53497,6 +53833,7 @@ webhooks: * `collection_item_unpublished` - Sends the [collection_item_unpublished](#collection_item_unpublished) event + inline: true source: openapi: ../openapi.yml WebhooksListResponseWebhooksItemFilter: @@ -53648,6 +53985,7 @@ webhooks: * `collection_item_unpublished` - Sends the [collection_item_unpublished](#collection_item_unpublished) event + inline: true source: openapi: ../openapi.yml WebhooksCreateRequestFilter: @@ -53719,6 +54057,7 @@ webhooks: * `collection_item_unpublished` - Sends the [collection_item_unpublished](#collection_item_unpublished) event + inline: true source: openapi: ../openapi.yml WebhooksCreateResponseFilter: @@ -53861,6 +54200,7 @@ webhooks: * `collection_item_unpublished` - Sends the [collection_item_unpublished](#collection_item_unpublished) event + inline: true source: openapi: ../openapi.yml WebhooksGetResponseFilter: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/x-fern-enum.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/x-fern-enum.json index b6cb815d795..dcd5420c5fe 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/x-fern-enum.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-docs/x-fern-enum.json @@ -21,6 +21,7 @@ "value": "nano", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/aries.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/aries.json index 5ee55eba7f8..63573024fb3 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/aries.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/aries.json @@ -35699,6 +35699,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "AttributeMimeTypesResultResults", @@ -35958,6 +35959,7 @@ }, "generatedName": "ClearPendingRevocationsRequestPurgeValue", "groupName": [], + "inline": true, "type": "array" }, "generatedName": "ClearPendingRevocationsRequestPurge", @@ -45478,6 +45480,7 @@ }, "type": "reference" }, + "inline": true, "type": "nullable" }, "generatedName": "IndyProofRequestedProofRevealedAttrGroups", @@ -45526,6 +45529,7 @@ }, "type": "reference" }, + "inline": true, "type": "nullable" }, "generatedName": "IndyProofRequestedProofRevealedAttrs", @@ -51490,6 +51494,7 @@ }, "generatedName": "PublishRevocationsRrid2CridValue", "groupName": [], + "inline": true, "type": "array" }, "generatedName": "PublishRevocationsRrid2Crid", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/hookdeck.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/hookdeck.json index 21b37f8e33c..fd3a67d6a9a 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/hookdeck.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/hookdeck.json @@ -46649,6 +46649,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -47005,6 +47006,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -47595,6 +47597,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -58278,6 +58281,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "ShortEventDataHeadersOne", @@ -58975,6 +58979,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "EventDataHeadersOne", @@ -63839,6 +63844,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "RequestDataHeadersOne", @@ -64953,6 +64959,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "TransformFullTransformationEnv", @@ -65935,6 +65942,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "TransformationEnv", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/humanloop.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/humanloop.json index 2ab84606370..ea010171e65 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/humanloop.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/humanloop.json @@ -22747,6 +22747,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -23250,6 +23251,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/intercom.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/intercom.json index 4c43c812008..b3060c64067 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/intercom.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/intercom.json @@ -112612,6 +112612,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -121748,6 +121749,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -122781,6 +122783,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/only-include-referenced-schemas.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/only-include-referenced-schemas.json index 4c43c812008..b3060c64067 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/only-include-referenced-schemas.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/only-include-referenced-schemas.json @@ -112612,6 +112612,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -121748,6 +121749,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -122781,6 +122783,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/openapi-filter.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/openapi-filter.json index 88993758965..220a30a0b66 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/openapi-filter.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/openapi-filter.json @@ -15737,6 +15737,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -24903,6 +24904,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -25936,6 +25938,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/permit.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/permit.json index 0f11f45968c..9262d97444e 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/permit.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/permit.json @@ -40004,6 +40004,7 @@ }, "generatedName": "ResourceReadActionGroupsValue", "groupName": [], + "inline": true, "type": "array" }, "generatedName": "ResourceReadActionGroups", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/rightbrain.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/rightbrain.json index 26612f200cc..6e3aafa9769 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/rightbrain.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/rightbrain.json @@ -63871,6 +63871,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "enum" }, "generatedName": "TaskCreateOutputFormat", @@ -65058,6 +65059,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "enum" }, "generatedName": "TaskRevisionOutputFormat", @@ -65581,9 +65583,11 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "enum" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "TaskUpdateOutputFormat", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/seam.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/seam.json index 34a3f589b69..7a1800dd90a 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/seam.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/seam.json @@ -6766,11 +6766,13 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "ConnectWebviewsCreateRequestCustomMetadata", @@ -7692,6 +7694,7 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -8634,6 +8637,7 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -9000,11 +9004,13 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "ConnectedAccountsUpdateRequestCustomMetadata", @@ -11724,6 +11730,7 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -12672,11 +12679,13 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "DevicesUpdateRequestCustomMetadata", @@ -17795,6 +17804,7 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -23131,6 +23141,7 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -43301,6 +43312,7 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -55706,6 +55718,7 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -56057,6 +56070,7 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -60427,6 +60441,7 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" @@ -65391,6 +65406,7 @@ "file": "../openapi.json", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/squidex.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/squidex.json index c05c1557606..95adb961406 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/squidex.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/squidex.json @@ -71861,6 +71861,7 @@ }, "generatedName": "LocalizedValueOfReadonlyListOfStringValue", "groupName": [], + "inline": true, "type": "array" }, "generatedName": "LocalizedValueOfReadonlyListOfString", @@ -72013,6 +72014,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "LocalizedValueOfNullableBoolean", @@ -72413,6 +72415,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "LocalizedValueOfNullableInstant", @@ -72756,6 +72759,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "LocalizedValueOfNullableDouble", @@ -76468,6 +76472,7 @@ }, "generatedName": "CallsUsageDtoDtoDetailsValue", "groupName": [], + "inline": true, "type": "array" }, "generatedName": "CallsUsageDtoDtoDetails", @@ -78139,6 +78144,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "UpsertSchemaDtoPreviewUrls", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/valtown.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/valtown.json index 1e4f165c4ee..9a5ac1c0a99 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/valtown.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/valtown.json @@ -3821,11 +3821,13 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "SqliteExecuteRequestStatementArgsArgsOne", @@ -4311,11 +4313,13 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "undisciminated" }, "type": "oneOf" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "SqliteBatchRequestStatementsItemArgsArgsOne", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/vellum.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/vellum.json index 20685688475..1a6d2e09c3c 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/vellum.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/vellum.json @@ -6993,6 +6993,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "ModelVersionExecConfigParametersLogitBias", @@ -7471,6 +7472,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "NormalizedTokenLogProbsTopLogprobs", @@ -8707,6 +8709,7 @@ "type": "primitive" }, "groupName": [], + "inline": true, "type": "nullable" }, "generatedName": "RegisterPromptModelParametersRequestLogitBias", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/webflow.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/webflow.json index 9099d13f527..772b95cafa5 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/webflow.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi-ir/webflow.json @@ -37937,6 +37937,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "object" }, "generatedName": "FormsListResponseFormsItemFields", @@ -39159,6 +39160,7 @@ "file": "../openapi.yml", "type": "openapi" }, + "inline": true, "type": "object" }, "generatedName": "FormsGetResponseFields", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/apiture.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/apiture.json index a8837830bb1..f190a039609 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/apiture.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/apiture.json @@ -557,6 +557,7 @@ This error response may have one of the following `type` values: "viewCards", "manageCards", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -730,6 +731,7 @@ Account transfers are only allowed between `internal` and `external` accounts. A "external", "outside", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -890,6 +892,7 @@ Account transfers are only allowed between `internal` and `external` accounts. A "float", "sameDay", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -950,6 +953,7 @@ Account transfers are only allowed between `internal` and `external` accounts. A "tel", "web", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1172,6 +1176,7 @@ Account transfers are only allowed between `internal` and `external` accounts. A "securityQuestions", "authenticatorToken", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1314,6 +1319,7 @@ Account transfers are only allowed between `internal` and `external` accounts. A "externalTransfer", "billPay", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1440,6 +1446,7 @@ The client can use this value to localize the `items[].time` values to the local "microDeposits", "manual", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1569,6 +1576,7 @@ The client can use this value to localize the `items[].time` values to the local "swiftBicCode", "ibanAccountNumber", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1875,6 +1883,7 @@ The client can use this value to localize the `items[].time` values to the local "loan", "creditCard", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2069,6 +2078,7 @@ The client can use this value to localize the `items[].time` values to the local "credit", "debit", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2291,6 +2301,7 @@ The client can use this value to localize the `items[].time` values to the local "check", "other", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2326,6 +2337,7 @@ The client can use this value to localize the `items[].time` values to the local "debit", "credit", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2489,6 +2501,7 @@ The client can use this value to localize the `items[].time` values to the local "closure", "other", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2632,6 +2645,7 @@ The response may include dates prior to requested the start date, as that is use "semiyearly", "yearly", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2733,6 +2747,7 @@ The response may include dates prior to requested the start date, as that is use "fixed", "variable", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2821,6 +2836,7 @@ For recurring transfer schedules, `endsOn`, `count`, and `amountLimit` are mutua "credit", "both", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2921,6 +2937,7 @@ For recurring transfer schedules, `endsOn`, `count`, and `amountLimit` are mutua "failed", "other", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2970,6 +2987,7 @@ For recurring transfer schedules, `endsOn`, `count`, and `amountLimit` are mutua "domesticWireTransfer", "internationalWireTransfer", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6254,6 +6272,7 @@ Optionally, an agent can access a business customer's ACH accounts when acting o "internal", "external", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/aries.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/aries.json index 7c52fb1a7d7..ad8c91902c0 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/aries.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/aries.json @@ -427,6 +427,7 @@ "value": "present-proof", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -628,6 +629,7 @@ "manual", "auto", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -644,6 +646,7 @@ "value": "didexchange/1.0", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -655,6 +658,7 @@ "multi", "static", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -667,6 +671,7 @@ "active", "error", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -679,6 +684,7 @@ "inviter", "responder", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -865,6 +871,7 @@ "allowed", "disallowed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -875,6 +882,7 @@ "allowed", "disallowed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -885,6 +893,7 @@ "allowed", "disallowed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -895,6 +904,7 @@ "required", "preferred", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -954,6 +964,7 @@ "managed", "unmanaged", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1700,6 +1711,7 @@ "ed25519", "bls12381g2", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1710,6 +1722,7 @@ "ed25519", "bls12381g2", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1721,6 +1734,7 @@ "posted", "wallet_only", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2012,6 +2026,7 @@ "USER", "ROLE_REMOVE", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2428,6 +2443,7 @@ "GE", "GT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2596,6 +2612,7 @@ "value": ">", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2919,6 +2936,7 @@ "value": ">", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3765,6 +3783,7 @@ "add", "remove", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4259,6 +4278,7 @@ "sender", "receiver", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4286,6 +4306,7 @@ "done", "deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4481,6 +4502,7 @@ "value": "goal-code", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5051,6 +5073,7 @@ "TRANSACTION_ENDORSER", "reset", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5062,6 +5085,7 @@ "TRANSACTION_ENDORSER", "reset", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5463,6 +5487,7 @@ "self", "external", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5490,6 +5515,7 @@ "holder", "issuer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5668,6 +5694,7 @@ "self", "external", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5707,6 +5734,7 @@ "prover", "verifier", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5717,6 +5745,7 @@ "true", "false", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6062,6 +6091,7 @@ "self", "external", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6130,6 +6160,7 @@ "issuer", "holder", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6177,6 +6208,7 @@ "abandoned", "deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6680,6 +6712,7 @@ "self", "external", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6715,6 +6748,7 @@ "prover", "verifier", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6750,6 +6784,7 @@ "abandoned", "deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6760,6 +6795,7 @@ "true", "false", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7042,6 +7078,7 @@ "managed", "unmanaged", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7072,6 +7109,7 @@ "required", "preferred", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7082,6 +7120,7 @@ "ISSUANCE_ON_DEMAND", "ISSUANCE_BY_DEFAULT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7116,6 +7155,7 @@ "required", "preferred", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7134,6 +7174,7 @@ "all", "pick", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -7394,6 +7435,7 @@ types: - value: present-proof name: PresentProof docs: Attachment type + inline: true source: openapi: ../openapi.yml AttachmentDef: @@ -7464,6 +7506,7 @@ types: - manual - auto docs: 'Connection acceptance: manual or auto' + inline: true source: openapi: ../openapi.yml ConnRecordConnectionProtocol: @@ -7473,6 +7516,7 @@ types: - value: didexchange/1.0 name: Didexchange10 docs: Connection protocol used + inline: true source: openapi: ../openapi.yml ConnRecordInvitationMode: @@ -7481,6 +7525,7 @@ types: - multi - static docs: Invitation mode + inline: true source: openapi: ../openapi.yml ConnRecordRoutingState: @@ -7490,6 +7535,7 @@ types: - active - error docs: Routing state of connection + inline: true source: openapi: ../openapi.yml ConnRecordTheirRole: @@ -7499,6 +7545,7 @@ types: - inviter - responder docs: Their role in the connection protocol + inline: true source: openapi: ../openapi.yml ConnRecord: @@ -7675,6 +7722,7 @@ types: - required - allowed - disallowed + inline: true source: openapi: ../openapi.yml ConstraintsStatusRevoked: @@ -7682,6 +7730,7 @@ types: - required - allowed - disallowed + inline: true source: openapi: ../openapi.yml ConstraintsStatusSuspended: @@ -7689,6 +7738,7 @@ types: - required - allowed - disallowed + inline: true source: openapi: ../openapi.yml ConstraintsSubjectIsIssuer: @@ -7696,6 +7746,7 @@ types: - required - preferred docs: SubjectIsIssuer + inline: true source: openapi: ../openapi.yml Constraints: @@ -7723,6 +7774,7 @@ types: - managed - unmanaged docs: Mode regarding management of wallet key + inline: true source: openapi: ../openapi.yml CreateWalletResponseSettings: @@ -8044,6 +8096,7 @@ types: - ed25519 - bls12381g2 docs: Key type associated with the DID + inline: true source: openapi: ../openapi.yml DidPosture: @@ -8054,6 +8107,7 @@ types: docs: >- Whether DID is current public DID, posted to ledger but not current public DID, or local to the wallet + inline: true source: openapi: ../openapi.yml DID: @@ -8090,6 +8144,7 @@ types: docs: >- Key type to use for the DID keypair. Validated with the chosen DID method's supported key types. + inline: true source: openapi: ../openapi.yml DIDCreateOptions: @@ -8143,6 +8198,7 @@ types: - required - preferred docs: Preference + inline: true source: openapi: ../openapi.yml DIFField: @@ -8167,6 +8223,7 @@ types: - required - preferred docs: Preference + inline: true source: openapi: ../openapi.yml DIFHolder: @@ -8392,6 +8449,7 @@ types: - USER - ROLE_REMOVE docs: Ledger role + inline: true source: openapi: ../openapi.yml GetNymRoleResponse: @@ -8630,6 +8688,7 @@ types: - GE - GT docs: Predicate type + inline: true source: openapi: ../openapi.yml IndyGEProofPred: @@ -8716,6 +8775,7 @@ types: - value: '>' name: GreaterThan docs: Predicate type ('<', '<=', '>=', or '>') + inline: true source: openapi: ../openapi.yml IndyPresPredSpec: @@ -8884,6 +8944,7 @@ types: - value: '>' name: GreaterThan docs: Predicate type ('<', '<=', '>=', or '>') + inline: true source: openapi: ../openapi.yml IndyProofReqPredSpec: @@ -9082,6 +9143,7 @@ types: - ISSUANCE_ON_DEMAND - ISSUANCE_BY_DEFAULT docs: Issuance type + inline: true source: openapi: ../openapi.yml IndyRevRegDefValue: @@ -9428,6 +9490,7 @@ types: - add - remove docs: Action for specific key + inline: true source: openapi: ../openapi.yml KeylistUpdateRule: @@ -9721,6 +9784,7 @@ types: - sender - receiver docs: OOB Role + inline: true source: openapi: ../openapi.yml OobRecordState: @@ -9737,6 +9801,7 @@ types: - done - deleted docs: Out of band message exchange state + inline: true source: openapi: ../openapi.yml OobRecord: @@ -9893,6 +9958,7 @@ types: - value: goal-code name: GoalCode docs: feature type + inline: true source: openapi: ../openapi.yml QueryItem: @@ -10147,6 +10213,7 @@ types: - all - pick docs: Selection + inline: true source: openapi: ../openapi.yml SubmissionRequirements: @@ -10226,6 +10293,7 @@ types: - TRANSACTION_ENDORSER - reset docs: My transaction related job + inline: true source: openapi: ../openapi.yml TransactionJobsTransactionTheirJob: @@ -10234,6 +10302,7 @@ types: - TRANSACTION_ENDORSER - reset docs: Their transaction related job + inline: true source: openapi: ../openapi.yml TransactionJobs: @@ -10381,6 +10450,7 @@ types: - self - external docs: 'Issue-credential exchange initiator: self or external' + inline: true source: openapi: ../openapi.yml V10CredentialExchangeRole: @@ -10388,6 +10458,7 @@ types: - holder - issuer docs: 'Issue-credential exchange role: holder or issuer' + inline: true source: openapi: ../openapi.yml V10CredentialExchange: @@ -10536,6 +10607,7 @@ types: - self - external docs: 'Present-proof exchange initiator: self or external' + inline: true source: openapi: ../openapi.yml V10PresentationExchangeRole: @@ -10543,6 +10615,7 @@ types: - prover - verifier docs: 'Present-proof exchange role: prover or verifier' + inline: true source: openapi: ../openapi.yml V10PresentationExchangeVerified: @@ -10550,6 +10623,7 @@ types: - 'true' - 'false' docs: 'Whether presentation is verified: true or false' + inline: true source: openapi: ../openapi.yml V10PresentationExchange: @@ -10664,6 +10738,7 @@ types: - self - external docs: 'Issue-credential exchange initiator: self or external' + inline: true source: openapi: ../openapi.yml V20CredExRecordRole: @@ -10671,6 +10746,7 @@ types: - issuer - holder docs: 'Issue-credential exchange role: holder or issuer' + inline: true source: openapi: ../openapi.yml V20CredExRecordState: @@ -10697,6 +10773,7 @@ types: - abandoned - deleted docs: Issue-credential exchange state + inline: true source: openapi: ../openapi.yml V20CredExRecord: @@ -11118,6 +11195,7 @@ types: - self - external docs: 'Present-proof exchange initiator: self or external' + inline: true source: openapi: ../openapi.yml V20PresExRecordRole: @@ -11125,6 +11203,7 @@ types: - prover - verifier docs: 'Present-proof exchange role: prover or verifier' + inline: true source: openapi: ../openapi.yml V20PresExRecordState: @@ -11145,6 +11224,7 @@ types: - abandoned - deleted docs: Present-proof exchange state + inline: true source: openapi: ../openapi.yml V20PresExRecordVerified: @@ -11152,6 +11232,7 @@ types: - 'true' - 'false' docs: 'Whether presentation is verified: ''true'' or ''false''' + inline: true source: openapi: ../openapi.yml V20PresExRecord: @@ -11374,6 +11455,7 @@ types: - managed - unmanaged docs: Mode regarding management of wallet key + inline: true source: openapi: ../openapi.yml WalletRecordSettings: @@ -13036,6 +13118,7 @@ docs: Simple messaging "value": "didexchange/1.0", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13052,6 +13135,7 @@ docs: Simple messaging "active", "completed", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13063,6 +13147,7 @@ docs: Simple messaging "inviter", "responder", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16700,6 +16785,7 @@ docs: Feature discovery v2 "TRANSACTION_ENDORSER", "reset", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -18414,6 +18500,7 @@ docs: Introduction of known parties "issuer", "holder", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -18432,6 +18519,7 @@ docs: Introduction of known parties "credential_revoked", "abandoned", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20316,6 +20404,7 @@ types: "issuer", "holder", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20361,6 +20450,7 @@ types: }, "abandoned", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -21702,6 +21792,7 @@ docs: Sign and verify json-ld data "Profile", "LinkedDomains", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -21714,6 +21805,7 @@ docs: Sign and verify json-ld data "NETWORK_MONITOR", "reset", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -22787,6 +22879,7 @@ docs: Interaction with ledger "client", "server", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -22797,6 +22890,7 @@ docs: Interaction with ledger "granted", "denied", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -23724,6 +23818,7 @@ types: "both", "base", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23735,6 +23830,7 @@ types: "ARGON2I_INT", "RAW", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23746,6 +23842,7 @@ types: "in_memory", "indy", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23757,6 +23854,7 @@ types: "both", "base", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -23774,6 +23872,7 @@ types: Dispatch only to webhooks associated with this wallet. base - Dispatch only to webhooks associated with the base wallet. both - Dispatch to both webhook targets. + inline: true source: openapi: ../openapi.yml CreateWalletRequestWalletKeyDerivation: @@ -23782,6 +23881,7 @@ types: - ARGON2I_INT - RAW docs: Key derivation + inline: true source: openapi: ../openapi.yml CreateWalletRequestWalletType: @@ -23790,6 +23890,7 @@ types: - in_memory - indy docs: Type of the wallet to create + inline: true source: openapi: ../openapi.yml UpdateWalletRequestWalletDispatchType: @@ -23802,6 +23903,7 @@ types: Dispatch only to webhooks associated with this wallet. base - Dispatch only to webhooks associated with the base wallet. both - Dispatch to both webhook targets. + inline: true source: openapi: ../openapi.yml imports: @@ -25546,6 +25648,7 @@ docs: Out-of-band connections "prover", "verifier", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -25562,6 +25665,7 @@ docs: Out-of-band connections "presentation_acked", "abandoned", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -26906,6 +27010,7 @@ types: "prover", "verifier", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -26939,6 +27044,7 @@ types: "done", "abandoned", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -28633,6 +28739,7 @@ docs: did resolver interface. "active", "full", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -28643,6 +28750,7 @@ docs: did resolver interface. "v1_0", "v2_0", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -28655,6 +28763,7 @@ docs: did resolver interface. "active", "full", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -29406,6 +29515,7 @@ types: - v1_0 - v2_0 docs: Specify which version of the revocation notification should be sent + inline: true source: openapi: ../openapi.yml ", @@ -30609,6 +30719,7 @@ docs: Trust-ping over connection "Profile", "LinkedDomains", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30618,6 +30729,7 @@ docs: Trust-ping over connection "ed25519", "bls12381g2", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -30627,6 +30739,7 @@ docs: Trust-ping over connection "key", "sov", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -30637,6 +30750,7 @@ docs: Trust-ping over connection "posted", "wallet_only", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -30671,6 +30785,7 @@ docs: Trust-ping over connection docs: >- Endpoint type to set (default 'Endpoint'); affects only public or posted DIDs + inline: true source: openapi: ../openapi.yml imports: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/assembly.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/assembly.json index 08c5dad13a5..de5fe617b31 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/assembly.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/assembly.json @@ -94,6 +94,7 @@ "success", "unavailable", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -537,6 +538,7 @@ Valid values are in the range [0, 1] inclusive. "value": "us_social_security_number", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -634,6 +636,7 @@ Can be any value between 0.0 and 1.0 inclusive. "default", "basic", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -809,6 +812,7 @@ Can be any value between 0.0 and 1.0 inclusive. "drivers_license", "banking_information", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -896,6 +900,7 @@ Can be any value between 0.0 and 1.0 inclusive. "NEUTRAL", "NEGATIVE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -985,6 +990,7 @@ Can be any value between 0.0 and 1.0 inclusive. "entity_type", "hash", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -995,6 +1001,7 @@ Can be any value between 0.0 and 1.0 inclusive. "srt", "vtt", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1007,6 +1014,7 @@ Can be any value between 0.0 and 1.0 inclusive. "conversational", "catchy", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1021,6 +1029,7 @@ Can be any value between 0.0 and 1.0 inclusive. "headline", "paragraph", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1354,6 +1363,7 @@ See [Speech recognition](https://www.assemblyai.com/docs/Models/speech_recogniti "default", "high", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1441,6 +1451,7 @@ The default value is 'en_us'. "uk", "vi", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1577,6 +1588,7 @@ The default value is 'en_us'. "value": "error", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4805,6 +4817,7 @@ docs: Real-time transcription "value": "error", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/axle.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/axle.json index c894a317c7d..a70148cc961 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/axle.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/axle.json @@ -87,6 +87,7 @@ "COLL", "COMP", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -184,6 +185,7 @@ "lessor", "interest", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -275,6 +277,7 @@ - UIMPD - COLL - COMP + inline: true source: openapi: ../openapi.yml Coverage: @@ -335,6 +338,7 @@ - lessor - interest default: interest + inline: true source: openapi: ../openapi.yml ThirdParty: @@ -536,6 +540,7 @@ "auto", "motorcycle", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -575,6 +580,7 @@ types: enum: - auto - motorcycle + inline: true source: openapi: ../openapi.yml Policy: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/belvo.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/belvo.json index 39e9371429b..95073e80807 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/belvo.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/belvo.json @@ -1668,6 +1668,7 @@ In our documentation example, we use `{endpoint}` as a placeholder value. In pro "SUCCEEDED", "FAILED", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2762,6 +2763,7 @@ We return one of the following enum values: "INDIVIDUAL", "BUSINESS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2781,6 +2783,7 @@ We return one of the following enum values: "SAVINGS", "SALARY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2798,6 +2801,7 @@ Can be either: "LOAN_ACCOUNT", "SAVINGS_ACCOUNT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2812,6 +2816,7 @@ Can be either: "INDIVIDUAL", "BUSINESS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2936,6 +2941,7 @@ Can be either: "INFLOW", "OUTFLOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2949,6 +2955,7 @@ Can be either: "CPF", "CNPJ", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2965,6 +2972,7 @@ Can be either: "TI", "NIT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2982,6 +2990,7 @@ Can be either: "INDIVIDUAL", "BUSINESS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2996,6 +3005,7 @@ Can be either: "NSS", "CURP", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3007,6 +3017,7 @@ Can be either: "EMPLOYED", "UNEMPLOYED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3029,6 +3040,7 @@ Can be either: "ABSENCE", "SICK_LEAVE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3047,6 +3059,7 @@ You can send through one of the following values: "MEDIUM", "LOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3073,6 +3086,7 @@ We return one of the following enum values: "MEDIUM", "LOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3095,6 +3109,7 @@ We return one of the following enum values: "IRREGULAR", "SINGLE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3127,6 +3142,7 @@ We return one of the following enum values: "DEPOSIT", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3140,6 +3156,7 @@ Can be either: "CHECKING_ACCOUNT", "SAVINGS_ACCOUNT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3167,6 +3184,7 @@ Can be either: "credentials", "openbanking", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3178,6 +3196,7 @@ Can be either: "healthy", "down", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3194,6 +3213,7 @@ Can be either: "fiscal", "employment", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3220,6 +3240,7 @@ We return one of the following values: "PENSION", "STOCK", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3240,6 +3261,7 @@ We return one of the following values: "PENSION", "VARIABLE_INCOME", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3269,6 +3291,7 @@ You can send through one or more of the following values: "DEPOSIT", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3314,6 +3337,7 @@ For Mexico's SAT, we return one of the following values: "Pago", "Traslado", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3344,6 +3368,7 @@ For more information, see our [Links](https://developers.belvo.com/docs/links-an "single", "recurrent", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3385,6 +3410,7 @@ We return one of the following values: "unconfirmed", "token_required", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3401,6 +3427,7 @@ We return one of the following values: "INSURANCE_FEE", "OTHERS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3415,6 +3442,7 @@ We return one of the following values: "MONTHLY", "YEARLY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3425,6 +3453,7 @@ We return one of the following values: "INDIVIDUAL", "BUSINESS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3439,6 +3468,7 @@ We return one of the following values: "PROCESSING", "FAILED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3452,6 +3482,7 @@ We return one of the following values: "open_finance", "pse", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3467,6 +3498,7 @@ We return one of the following values: "belvo", "payments_way", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3482,6 +3514,7 @@ We return one of the following values: "ACTIVE", "INACTIVE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3495,6 +3528,7 @@ We return one of the following values: "INFLOW", "OUTFLOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3510,6 +3544,7 @@ We return one of the following values: "BRA", "COL", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3524,6 +3559,7 @@ We return one of the following values: "BRL", "COP", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3547,6 +3583,7 @@ We return one of the following values: "REVERTED", "UNCATEGORIZED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3596,6 +3633,7 @@ We return one of the following values: }, "Taxes", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3618,6 +3656,7 @@ We return one of the following values: "SUBSCRIPTION", "REGULAR", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3629,6 +3668,7 @@ We return one of the following values: "NEGATIVE", "NO_OBLIGATIONS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3642,6 +3682,7 @@ We return one of the following values: "PAID", "PROVISIONED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3655,6 +3696,7 @@ We return one of the following values: "NATIONAL", "FOREIGN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3669,6 +3711,7 @@ We return one of the following values: "OUTFLOW", "INFLOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20424,6 +20467,7 @@ types: - FAILED docs: | The current status of the charge. + inline: true source: openapi: ../openapi.yml ChargePaymentMethodDetails: @@ -50837,6 +50881,7 @@ types: "value": "-created_at", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -50846,6 +50891,7 @@ types: "ACTIVE", "INACTIVE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/deel.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/deel.json index 13cfb2c3ff7..b647ec7ea96 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/deel.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/deel.json @@ -976,6 +976,7 @@ "client", "contractor", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1194,6 +1195,7 @@ "rejected", "waiting_for_client_payment", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1622,6 +1624,7 @@ "shield_msa", "hris_direct_employee", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1637,6 +1640,7 @@ "payg_tasks", "payg_milestones", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1648,6 +1652,7 @@ "client", "contractor", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1673,6 +1678,7 @@ "total", "status", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1800,6 +1806,7 @@ "SICK_LEAVE", "OTHER", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2510,6 +2517,7 @@ "STANDARD", "SPECIFIC", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2526,6 +2534,7 @@ "value": "Part-time", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2557,6 +2566,7 @@ "Skilled", "Unskilled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2660,6 +2670,7 @@ "ALLOWED_WITH_MAXIMUM_LIMITATION", "NOT_ALLOWED", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2708,6 +2719,7 @@ "STANDARD", "SPECIFIC", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2910,6 +2922,7 @@ "LIMITED_ROLLOVER", "UNSET", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3145,6 +3158,7 @@ "CALENDAR_DAYS", "FULL_AMOUNT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3220,6 +3234,7 @@ "value": "image/png", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3271,6 +3286,7 @@ "CALENDAR_DAYS", "FULL_AMOUNT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3489,6 +3505,7 @@ "ENABLED", "DISABLED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3977,6 +3994,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3998,6 +4016,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4203,6 +4222,7 @@ "withholding_tax", "work", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4220,6 +4240,7 @@ "time_off", "vat", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4256,6 +4277,7 @@ "failed", "refunded", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4324,6 +4346,7 @@ "failed", "refunded", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4348,6 +4371,7 @@ "SHIELD_DEPOSIT", "EOR_MANAGEMENT_FEE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4412,6 +4436,7 @@ "individual", "company", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4547,6 +4572,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4585,6 +4611,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4704,6 +4731,7 @@ "value": "tasks:write", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5054,6 +5082,7 @@ "mercury_wire", "bt_pay_pal", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5090,6 +5119,7 @@ "paid", "processing", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5423,6 +5453,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5451,6 +5482,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5664,6 +5696,7 @@ "CALENDAR_DAYS", "FULL_AMOUNT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5677,6 +5710,7 @@ "hris_direct_employee", "service_account", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5811,6 +5845,7 @@ "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5993,6 +6028,7 @@ "APPROVED", "REJECTED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6003,6 +6039,7 @@ "SICK_LEAVE", "OTHER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6117,6 +6154,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6138,6 +6176,7 @@ "approved", "declined", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6394,6 +6433,7 @@ "enabled", "disabled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6419,6 +6459,7 @@ "Friday", "Saturday", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6430,6 +6471,7 @@ "DAY_OF_LAST_WEEK", "DAY_OF_MONTH", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6446,6 +6488,7 @@ "value": "calendar-month", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6457,6 +6500,7 @@ "REGULAR", "WITHIN_MONTH", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6472,6 +6516,7 @@ "semimonthly", "custom", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6487,6 +6532,7 @@ "semimonthly", "custom", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -7699,6 +7745,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml TimesheetReviewsToCreate: @@ -7726,6 +7773,7 @@ - approved - declined docs: Review status. + inline: true source: openapi: ../openapi.yml PgoTaskReviewsByIdToCreate: @@ -7743,6 +7791,7 @@ - approved - declined docs: Review status. + inline: true source: openapi: ../openapi.yml PgoTaskReviewsToCreate: @@ -7760,6 +7809,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml TimesheetReviewToCreate: @@ -8067,6 +8117,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml InvoiceAdjustmentReviewsToCreate: @@ -8089,6 +8140,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml InvoiceAdjustmentReviewToCreate: @@ -8670,6 +8722,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml MilestoneReviewsToCreate: @@ -8683,6 +8736,7 @@ enum: - approved - declined + inline: true source: openapi: ../openapi.yml MilestoneReviewToCreate: @@ -8717,6 +8771,7 @@ - CALENDAR_DAYS - FULL_AMOUNT docs: Either works days or calendar days + inline: true source: openapi: ../openapi.yml EstimateFirstPaymentCompensationDetails: @@ -8765,6 +8820,7 @@ - CALENDAR_DAYS - FULL_AMOUNT docs: Either works days or calendar days + inline: true source: openapi: ../openapi.yml ProRata: @@ -9100,6 +9156,7 @@ - CALENDAR_DAYS - FULL_AMOUNT docs: Either works days or calendar days + inline: true source: openapi: ../openapi.yml FinalPaymentCalculated: @@ -9355,6 +9412,7 @@ - value: Part-time name: PartTime docs: Is it a full-time contract or a part-time contract? + inline: true source: openapi: ../openapi.yml EorContractToCreateEmploymentTimeOffType: @@ -9365,6 +9423,7 @@ If you want to use standard number of holidays for this employee, choose "STANDARD". If you want to enter a specific number of holidays, choose "SPECIFIC" and enter the number of days in the holidays field. + inline: true source: openapi: ../openapi.yml EorContractToCreateEmployment: @@ -9468,6 +9527,7 @@ - Skilled - Unskilled docs: Type of worker. + inline: true source: openapi: ../openapi.yml EorContractToCreateQuoteAdditionalFields: @@ -9634,6 +9694,7 @@ - PRORATED - STANDARD - SPECIFIC + inline: true source: openapi: ../openapi.yml EorCountryValidationsPartTimeHoliday: @@ -9718,6 +9779,7 @@ - ALLOWED_WITHOUT_LIMITATION - ALLOWED_WITH_MAXIMUM_LIMITATION - NOT_ALLOWED + inline: true source: openapi: ../openapi.yml EorCountryValidationsDefiniteContract: @@ -10077,6 +10139,7 @@ - SICK_LEAVE - OTHER docs: Time off type. + inline: true source: openapi: ../openapi.yml CreateTimeoff: @@ -10168,6 +10231,7 @@ - enabled - disabled docs: Status of webhook. + inline: true source: openapi: ../openapi.yml WebhookItem: @@ -14887,6 +14951,7 @@ docs: The Contracts resource lets you create, amend and, retrieve Deel contracts "CALENDAR_DAYS", "FULL_AMOUNT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -22258,6 +22323,7 @@ docs: >- "enabled", "disabled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22268,6 +22334,7 @@ docs: >- "enabled", "disabled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -22527,6 +22594,7 @@ types: - enabled - disabled docs: Status of webhook. + inline: true source: openapi: ../openapi.yml PatchWebhookRequestStatus: @@ -22534,6 +22602,7 @@ types: - enabled - disabled docs: Status of webhook. + inline: true source: openapi: ../openapi.yml ", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/devrev.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/devrev.json index 5d4a3ddaf8a..05ceeda8758 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/devrev.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/devrev.json @@ -346,6 +346,7 @@ authentication connection. "disable", "enable", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -361,6 +362,7 @@ for each authentication connection will depend on the type value. "social", "waad", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -417,6 +419,7 @@ token. Only applicable for application access tokens. "value": "urn:ietf:params:oauth:grant-type:token-exchange", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -461,6 +464,7 @@ token. Only applicable for application access tokens. "value": "urn:ietf:params:oauth:token-type:jwt", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -472,6 +476,7 @@ token. Only applicable for application access tokens. "expired", "revoked", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -508,6 +513,7 @@ token. Only applicable for application access tokens. "value": "urn:ietf:params:oauth:token-type:jwt", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -712,6 +718,7 @@ authentication connections have different configuration parameters. "samlp", "waad", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -816,6 +823,7 @@ that can be updated. "samlp", "waad", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -953,6 +961,7 @@ sort order. If not set, then no prior elements exist. "parse_error", "value_not_permitted", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1320,6 +1329,7 @@ sort order. If not set, then no prior elements exist. "p2", "p3", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1335,6 +1345,7 @@ always be returned in the specified sort-by order. "after", "before", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1379,6 +1390,7 @@ always be returned in the specified sort-by order. "staging", "test", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1468,6 +1480,7 @@ always be returned in the specified sort-by order. "feature", "product", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1995,6 +2008,7 @@ sort order. If not set, then no prior elements exist. "low", "medium", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2032,6 +2046,7 @@ will appear in the response. "snap_kit", "text", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2306,6 +2321,7 @@ default visibility. "shadow", "unassigned", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2333,6 +2349,7 @@ default visibility. "rev_user", "sys_user", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2466,6 +2483,7 @@ be set for other request types. "work_deleted", "work_updated", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2496,6 +2514,7 @@ be set for other request types. "inactive", "unverified", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2547,6 +2566,7 @@ be set for other request types. "activate", "deactivate", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2640,6 +2660,7 @@ event types. Note this is mutually exclusive with 'add' and "issue", "ticket", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/enum-casing.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/enum-casing.json index f672a171260..5cbdda8189b 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/enum-casing.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/enum-casing.json @@ -60,6 +60,7 @@ "success", "failure", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -75,6 +76,7 @@ "value": "urn:ietf:params:oauth:grant-type:token-exchange", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -109,6 +111,7 @@ types: enum: - success - failure + inline: true source: openapi: ../openapi.yml ExampleResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/flagright.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/flagright.json index c0257a814df..42785e8dcc3 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/flagright.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/flagright.json @@ -2052,6 +2052,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "GATHERING", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2436,6 +2437,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "RUPAY", "JCB", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2447,6 +2449,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "DEBIT", "PREPAID", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2456,6 +2459,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "VIRTUAL", "PHYSICAL", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2602,6 +2606,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "CLOSED", "HIT", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2614,6 +2619,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "DOCUMENTS_COLLECTED", "OTHER", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2661,6 +2667,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "REFUND", "DECLINED", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2736,6 +2743,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "LARGE", "UNKNOWN", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3126,6 +3134,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "value": "N/A", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3406,6 +3415,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "ZMW", "ZWL", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3805,6 +3815,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "IN_PROGRESS", "MANUAL_REVIEW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4000,6 +4011,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "IP_ADDRESS", "STRING", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4010,6 +4022,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "BLACKLIST", "FLAGRIGHT_LIBRARY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4067,6 +4080,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "BusinessPayment", "PromotionPayment", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4106,6 +4120,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "WALLET", "CHECK", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4203,6 +4218,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "LOW", "VERY_LOW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4236,6 +4252,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "BLOCK", "SUSPEND", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4274,6 +4291,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "ORIGIN", "DESTINATION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4305,6 +4323,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "SANCTIONS_PEP", "SANCTIONS_PEP_ADVERSE_MEDIA", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4316,6 +4335,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "CTF", "SCREENING", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4420,6 +4440,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "PAYMENT_BENEFICIARY_NAME", "BANK_NAME", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4685,6 +4706,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "REFUNDED", "SUCCESSFUL", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4698,6 +4720,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "REFUND", "OTHER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4980,6 +5003,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "F", "NB", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5049,6 +5073,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "RETAIL", "PROFESSIONAL", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5058,6 +5083,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "REGISTERED", "UNREGISTERED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5075,6 +5101,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "SUSPENDED", "BLOCKED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5185,6 +5212,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu "USER_STATE_UPDATED", "ALERT_CLOSED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5276,6 +5304,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu enum: - RETAIL - PROFESSIONAL + inline: true source: openapi: ../openapi.yml UserOptional: @@ -5832,6 +5861,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - F - NB docs: Gender of the individual - Male, Female or Non-Binary + inline: true source: openapi: ../openapi.yml UserDetails: @@ -5868,6 +5898,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - LARGE - UNKNOWN docs: Segmentation of the business user + inline: true source: openapi: ../openapi.yml CompanyGeneralDetails: @@ -6034,6 +6065,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - RUPAY - JCB docs: Brand of Card + inline: true source: openapi: ../openapi.yml CardDetailsCardFunding: @@ -6042,12 +6074,14 @@ In order to make individual events retrievable, you also need to pass in a uniqu - DEBIT - PREPAID docs: Funding of Card + inline: true source: openapi: ../openapi.yml CardDetailsCardType: enum: - VIRTUAL - PHYSICAL + inline: true source: openapi: ../openapi.yml CardDetails: @@ -6229,6 +6263,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - BusinessPayment - PromotionPayment docs: Type of transaction + inline: true source: openapi: ../openapi.yml MpesaDetails: @@ -6391,6 +6426,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - CLOSED - HIT docs: Status of a case. E.g. Open, Closed etc. + inline: true source: openapi: ../openapi.yml CaseManagementEventCaseStatusReason: @@ -6402,6 +6438,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu docs: >- Case status reason. E.g. Closed & False Positive, Closed & Investigation Completed etc. + inline: true source: openapi: ../openapi.yml CaseManagementEvent: @@ -6767,6 +6804,7 @@ In order to make individual events retrievable, you also need to pass in a uniqu - CANCELED - REFUND - DECLINED + inline: true source: openapi: ../openapi.yml CheckDetails: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/flexport.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/flexport.json index 55d47ede3f2..590decba284 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/flexport.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/flexport.json @@ -509,6 +509,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -826,6 +827,7 @@ "requoted_quote", "archived_quote", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -851,6 +853,7 @@ "booked", "shipment", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -920,6 +923,7 @@ "contained_in_equipment", "contained_in_battery_powered_vehicles", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -993,6 +997,7 @@ "reviewed", "complete", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1309,6 +1314,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1406,6 +1412,7 @@ "contained_in_equipment", "contained_in_battery_powered_vehicles", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1655,6 +1662,7 @@ "DAP", "DDP", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1667,6 +1675,7 @@ "sub_line", "component_line", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1704,6 +1713,7 @@ "gross_volume", "volume_weight", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1716,6 +1726,7 @@ "truck", "rail", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1859,6 +1870,7 @@ "YD", "Z3", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1922,6 +1934,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2039,6 +2052,7 @@ "freight_collect", "freight_prepaid", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2058,6 +2072,7 @@ "DAP", "DDP", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2072,6 +2087,7 @@ "delivery_order", "work_order", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2083,6 +2099,7 @@ "high", "standard", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2095,6 +2112,7 @@ "cancelled", "closed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2107,6 +2125,7 @@ "truck", "rail", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2166,6 +2185,7 @@ "buyers_agent", "sellers_agent", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2212,6 +2232,7 @@ "icao", "us_cbp", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2301,6 +2322,7 @@ "prs", "dpr", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2332,6 +2354,7 @@ "collect", "prepaid", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2419,6 +2442,7 @@ "customs_hold", "pending", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2469,6 +2493,7 @@ "km", "mi", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2593,6 +2618,7 @@ "terminal", "unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2625,6 +2651,7 @@ "door_to_door", "door_to_port", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2805,6 +2832,7 @@ "additional", "capital", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2860,6 +2888,7 @@ "paid", "payment_pending", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2870,6 +2899,7 @@ "Shipment", "Client", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2952,6 +2982,7 @@ "cm", "in", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2962,6 +2993,7 @@ "cm", "in", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2999,6 +3031,7 @@ "gross_volume", "volume_weight", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3144,6 +3177,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3253,6 +3287,7 @@ "buyers_agent", "sellers_agent", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3320,6 +3355,7 @@ "value": "/ocean/port", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3520,6 +3556,7 @@ "freight_collect", "freight_prepaid", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3539,6 +3576,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3657,6 +3695,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3668,6 +3707,7 @@ "sub_line", "component_line", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3733,6 +3773,7 @@ "W", "X", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3746,6 +3787,7 @@ "delivery_order", "work_order", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3755,6 +3797,7 @@ "standard", "high", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3837,6 +3880,7 @@ "closed", "cancelled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4093,6 +4137,7 @@ "fifty_three_ft", "fifty_three_ft_hc", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4110,6 +4155,7 @@ "bulk", "special", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4141,6 +4187,7 @@ "not_applicable", "misflagged", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4198,6 +4245,7 @@ "DDP", "DPU", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4285,6 +4333,7 @@ "standard", "high", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4330,6 +4379,7 @@ "gated_out", "final_destination", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4431,6 +4481,7 @@ "truck_intl", "warehouse_storage", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4456,6 +4507,7 @@ "collect", "prepaid", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4482,6 +4534,7 @@ "drayage", "cartage", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4543,6 +4596,7 @@ "cbm", "cbft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4605,6 +4659,7 @@ "kg", "lbs", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4731,6 +4786,7 @@ - cbm - cbft docs: unit of measurement. "cbm" for cubic meters. "cbft" for cubic feet. + inline: true source: openapi: ../openapi.yml VolumeCreate: @@ -4748,6 +4804,7 @@ - kg - lbs docs: Required. Unit of measurement. "kg" for kilograms, "lbs" for pounds + inline: true source: openapi: ../openapi.yml WeightCreate: @@ -4765,6 +4822,7 @@ - cm - in docs: Required. Unit of measurement. "cm" for centimeters. "in" for inches. + inline: true source: openapi: ../openapi.yml LengthCreate: @@ -4812,6 +4870,7 @@ - packed_with_equipment - contained_in_equipment - contained_in_battery_powered_vehicles + inline: true source: openapi: ../openapi.yml CreateCargo: @@ -4982,6 +5041,7 @@ - cm - in docs: Required. Unit of measurement. "cm" for centimeters. "in" for inches. + inline: true source: openapi: ../openapi.yml Length: @@ -5039,6 +5099,7 @@ - packed_with_equipment - contained_in_equipment - contained_in_battery_powered_vehicles + inline: true source: openapi: ../openapi.yml Cargo: @@ -5282,6 +5343,7 @@ - value: /ocean/port name: OceanPort docs: Type of the object + inline: true source: openapi: ../openapi.yml Placeport: @@ -5359,6 +5421,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml OceanBookingDetail: @@ -5390,6 +5453,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml AirBookingDetail: @@ -5409,6 +5473,7 @@ enum: - collect - prepaid + inline: true source: openapi: ../openapi.yml TruckingBookingDetail: @@ -5442,6 +5507,7 @@ - submitted - booked - shipment + inline: true source: openapi: ../openapi.yml BookingQuoteStatus: @@ -5456,6 +5522,7 @@ - rejected_quote - requoted_quote - archived_quote + inline: true source: openapi: ../openapi.yml Booking: @@ -5544,6 +5611,7 @@ - DDP - DPU docs: Always required. The Incoterm of your shipment + inline: true source: openapi: ../openapi.yml CreateOceanBooking: @@ -5608,6 +5676,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml CreateAirBooking: @@ -5691,6 +5760,7 @@ docs: >- Whether the shipper or consignee is responsible for payment of trucking freight. This can be `collect` (consignee) or `prepaid` (shipper). + inline: true source: openapi: ../openapi.yml CreateTruckingBooking: @@ -5716,6 +5786,7 @@ - km - mi docs: Required. Unit of measurement. "km" for kilometers. "mi" for miles. + inline: true source: openapi: ../openapi.yml DistanceCreate: @@ -5852,6 +5923,7 @@ Status about if the digitization process for this commercial invoice is complete. If it is not complete, then the commercial invoice should be considered a draft that can change. + inline: true source: openapi: ../openapi.yml CommercialInvoice: @@ -5916,6 +5988,7 @@ - prs - dpr docs: Required. Unit of measurement. + inline: true source: openapi: ../openapi.yml CreateQuantity: @@ -5969,6 +6042,7 @@ - customs_hold - pending docs: The release status for this entry. + inline: true source: openapi: ../openapi.yml CustomsEntry: @@ -6154,6 +6228,7 @@ - denied - not_applicable - misflagged + inline: true source: openapi: ../openapi.yml ShipmentDangerousGoods: @@ -6306,6 +6381,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml ShipmentPriority: @@ -6313,6 +6389,7 @@ - standard - high docs: The level of attention Flexport should give to this shipment + inline: true source: openapi: ../openapi.yml Shipment: @@ -6581,6 +6658,7 @@ - ftl - drayage - cartage + inline: true source: openapi: ../openapi.yml TruckingShipmentLeg: @@ -6669,6 +6747,7 @@ - ventilated - bulk - special + inline: true source: openapi: ../openapi.yml ShipmentContainerContainerSize: @@ -6679,6 +6758,7 @@ - fourty_five_ft_hc - fifty_three_ft - fifty_three_ft_hc + inline: true source: openapi: ../openapi.yml ShipmentContainer: @@ -6736,6 +6816,7 @@ - terminal - unknown docs: The main reason for the exception as an identifier. + inline: true source: openapi: ../openapi.yml Exception: @@ -6829,6 +6910,7 @@ - additional - capital docs: Category of the charge. + inline: true source: openapi: ../openapi.yml InvoiceItem: @@ -6882,6 +6964,7 @@ - paid - payment_pending docs: Status of the invoice + inline: true source: openapi: ../openapi.yml InvoiceType: @@ -6891,6 +6974,7 @@ docs: >- What the invoice is being issued for. Shipment related charges are type `Shipment` and non-shipment related charges are type `Client` + inline: true source: openapi: ../openapi.yml Invoice: @@ -7136,6 +7220,7 @@ - gross_volume - volume_weight docs: The type of measure + inline: true source: openapi: ../openapi.yml LineItemMeasurement: @@ -7157,6 +7242,7 @@ - sub_line - component_line default: main_line + inline: true source: openapi: ../openapi.yml PurchaseOrderLineItemIncoterm: @@ -7173,6 +7259,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml PurchaseOrderLineItemUnitOfMeasure: @@ -7222,6 +7309,7 @@ - TDWB - W - X + inline: true source: openapi: ../openapi.yml PurchaseOrderLineItem: @@ -7286,6 +7374,7 @@ - buyers_agent - sellers_agent docs: The role that the party has + inline: true source: openapi: ../openapi.yml PartiesContactsItem: @@ -7347,6 +7436,7 @@ because they've finished shipping), while Cancelled POs denote POs that were mistakenly uploaded or that should not be used. default: open + inline: true source: openapi: ../openapi.yml PurchaseOrderIncoterm: @@ -7363,6 +7453,7 @@ - DAP - DDP - DPU + inline: true source: openapi: ../openapi.yml PurchaseOrderOrderClass: @@ -7373,18 +7464,21 @@ - delivery_order - work_order docs: Class of the purchase order. + inline: true source: openapi: ../openapi.yml PurchaseOrderFreightPaymnetTerms: enum: - freight_collect - freight_prepaid + inline: true source: openapi: ../openapi.yml PurchaseOrderPriority: enum: - standard - high + inline: true source: openapi: ../openapi.yml PurchaseOrder: @@ -7463,6 +7557,7 @@ - buyers_agent - sellers_agent docs: The role that the party has + inline: true source: openapi: ../openapi.yml CreatePartyContactsItem: @@ -7510,6 +7605,7 @@ - icao - us_cbp docs: The code type of the port + inline: true source: openapi: ../openapi.yml CreatePurchaseOrderPort: @@ -7595,6 +7691,7 @@ - gross_volume - volume_weight docs: The type of measure + inline: true source: openapi: ../openapi.yml CreateLineItemMeasurement: @@ -7620,6 +7717,7 @@ - truck - rail docs: Required if there is no transportation_mode in purchase order + inline: true source: openapi: ../openapi.yml CreateLineItemIncoterm: @@ -7638,6 +7736,7 @@ docs: >- Required if there is no incoterm in the line item's purchase order. The Incoterm of your line item. + inline: true source: openapi: ../openapi.yml CreateLineItemLineType: @@ -7647,6 +7746,7 @@ - component_line docs: type of the line item default: main_line + inline: true source: openapi: ../openapi.yml CreateLineItemUnitOfMeasure: @@ -7779,6 +7879,7 @@ - Z3 docs: The measurement per unit for this line item. default: EA + inline: true source: openapi: ../openapi.yml CreateLineItem: @@ -7877,6 +7978,7 @@ because they've finished shipping), while Cancelled POs denote POs that were mistakenly uploaded or that should not be used default: open + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrderFreightPaymentTerms: @@ -7884,6 +7986,7 @@ - freight_collect - freight_prepaid docs: The freight payment term for the purchase order + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrderTransportationMode: @@ -7893,6 +7996,7 @@ - truck - rail docs: Required if there is no transportation_mode in purchase order + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrderIncoterm: @@ -7911,6 +8015,7 @@ docs: >- Required if there is no incoterm in each line item. The incoterm of your purchase order. + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrderPriority: @@ -7919,6 +8024,7 @@ - standard docs: priority of the purchase order. default: standard + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrderOrderClass: @@ -7930,6 +8036,7 @@ - work_order docs: Class of the purchase order. default: purchase_order + inline: true source: openapi: ../openapi.yml CreateOrUpdatePurchaseOrder: @@ -9315,6 +9422,7 @@ errors: "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -9324,6 +9432,7 @@ errors: "booked", "submitted", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -9333,6 +9442,7 @@ errors: "cargo_ready_date", "created_at", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -9370,6 +9480,7 @@ errors: "no", "notsure", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9423,6 +9534,7 @@ errors: contain goods subject to export control regulations? Export Control Regulations include dual use item control, Hong Kong strategic commodity control, US and EU export control, etc. + inline: true source: openapi: ../openapi.yml BookingCreateResponse: @@ -11163,6 +11275,7 @@ docs: >- "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11596,6 +11709,7 @@ docs: >- "belly_freighter", "unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11608,6 +11722,7 @@ docs: >- "truck", "rail", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11623,6 +11738,7 @@ docs: >- "airport_transfer", "air_cartage", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11641,6 +11757,7 @@ docs: >- `truck`, or `rail`. If `transportation_mode` is `truck`, `ocean`, or `rail`, `country_code` in both `origin_address` and `destination_address` is required. + inline: true source: openapi: ../openapi.yml CreateCarbonCalculationFlightType: @@ -11652,6 +11769,7 @@ docs: >- For `transportation_mode: air`, the type of plane used. One of `freighter`, `belly_freighter`, or `unknown`. Defaults to `unknown`. default: unknown + inline: true source: openapi: ../openapi.yml CreateCarbonCalculationTruckingServiceType: @@ -11667,6 +11785,7 @@ docs: >- For `transportation_mode: truck`, the type of service used. One of `ftl`, `ltl`, `drayage`, `cartage`, `last_mile`, `airport_transfer`, or `air_cartage`. + inline: true source: openapi: ../openapi.yml CarbonCalculationCreateResponse: @@ -17683,6 +17802,7 @@ docs: Endpoints relating to Document objects "value": "/shipment_leg", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -18578,6 +18698,7 @@ Other details about this invoice", "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -18589,6 +18710,7 @@ Other details about this invoice", "void", "paid", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20182,6 +20304,7 @@ docs: Endpoints relating to Location objects "roadport", "seaport", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -22195,6 +22318,7 @@ docs: Endpoints relating to Product objects "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -22214,6 +22338,7 @@ docs: Endpoints relating to Product objects "buyers_agent", "sellers_agent", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -22224,6 +22349,7 @@ docs: Endpoints relating to Product objects "closed", "cancelled", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -23446,6 +23572,7 @@ docs: >- "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -24973,6 +25100,7 @@ docs: >- "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -24986,6 +25114,7 @@ docs: >- "updated_at", "archived_at", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hathora.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hathora.json index 183a789bdf1..29948defae3 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hathora.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hathora.json @@ -226,6 +226,7 @@ "succeeded", "failed", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -360,6 +361,7 @@ "public", "local", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -371,6 +373,7 @@ "rate_egress", "total_egress", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -412,6 +415,7 @@ "medium", "large", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -490,6 +494,7 @@ "Sydney", "Sao_Paulo", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -530,6 +535,7 @@ "suspended", "destroyed", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -561,6 +567,7 @@ "udp", "tls", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -759,6 +766,7 @@ types: - running - succeeded - failed + inline: true source: openapi: ../openapi.json Build: @@ -789,6 +797,7 @@ types: - private - public - local + inline: true source: openapi: ../openapi.json Lobby: @@ -3132,6 +3141,7 @@ service: "private", "local", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3468,6 +3478,7 @@ types: - public - private - local + inline: true source: openapi: ../openapi.json ", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hookdeck.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hookdeck.json index 4fbbe7da936..f0273d5c611 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hookdeck.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hookdeck.json @@ -72,6 +72,7 @@ "each_attempt", "last_attempt", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -150,6 +151,7 @@ "SOCKET_CLOSED", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -162,6 +164,7 @@ "COMPLETED", "HOLD", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -174,6 +177,7 @@ "SUCCESSFUL", "HOLD", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -187,6 +191,7 @@ "UNPAUSE", "AUTOMATIC", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -474,6 +479,7 @@ "info", "debug", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -726,6 +732,7 @@ "minute", "hour", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1001,6 +1008,7 @@ "SUCCESSFUL", "FAILED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1025,6 +1033,7 @@ "path", "query", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1046,6 +1055,7 @@ "sha256", "sha512", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1068,6 +1078,7 @@ "base64", "hex", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1096,6 +1107,7 @@ "TRANSFORMATION_FAILED", "CLI_DISCONNECTED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1189,6 +1201,7 @@ "HANDSHAKE", "POLLING", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1235,6 +1248,7 @@ "pipedrive", "sendgrid", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1274,6 +1288,7 @@ "ACKNOWLEDGED", "RESOLVED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1456,6 +1471,7 @@ "first_attempt", "final_attempt", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1494,6 +1510,7 @@ "transformation", "backpressure", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1529,6 +1546,7 @@ "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1685,6 +1703,7 @@ "NORMAL", "LOW", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1713,6 +1732,7 @@ "INGESTION_FATAL", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1763,6 +1783,7 @@ "linear", "exponential", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1897,6 +1918,7 @@ "minute", "second", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2083,6 +2105,7 @@ "value": "event.successful", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2229,6 +2252,7 @@ "error", "fatal", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3285,6 +3309,7 @@ types: enum: - base64 - hex + inline: true source: openapi: ../openapi.yml HmacIntegrationConfigs: @@ -3316,6 +3341,7 @@ types: enum: - minute - second + inline: true source: openapi: ../openapi.yml ShopifyIntegrationConfigs: @@ -3488,6 +3514,7 @@ types: - warn - info - debug + inline: true source: openapi: ../openapi.yml ConsoleLine: @@ -3681,6 +3708,7 @@ types: - NORMAL - LOW docs: The priority attributed to the request when received + inline: true source: openapi: ../openapi.yml RequestDataParsedQueryOne: @@ -5017,6 +5045,7 @@ docs: An attempt is any request that Hookdeck makes on behalf of an event. "http", "cli", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5036,6 +5065,7 @@ docs: An attempt is any request that Hookdeck makes on behalf of an event. - http - cli docs: Bookmark target + inline: true source: openapi: ../openapi.yml imports: @@ -8182,6 +8212,7 @@ docs: '' "accepted", "rejected", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8223,6 +8254,7 @@ docs: '' enum: - accepted - rejected + inline: true source: openapi: ../openapi.yml CreateRequestBulkRetryRequestQueryRejectionCauseAny: @@ -9810,6 +9842,7 @@ docs: '' "minute", "hour", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9935,6 +9968,7 @@ docs: '' "minute", "hour", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9998,6 +10032,7 @@ docs: '' - minute - hour docs: Period to rate limit attempts + inline: true source: openapi: ../openapi.yml CreateConnectionRequestDestination: @@ -10059,6 +10094,7 @@ docs: '' - minute - hour docs: Period to rate limit attempts + inline: true source: openapi: ../openapi.yml UpsertConnectionRequestDestination: @@ -11386,6 +11422,7 @@ docs: >- "minute", "hour", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11408,6 +11445,7 @@ docs: >- "minute", "hour", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11419,6 +11457,7 @@ docs: >- "minute", "hour", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11439,6 +11478,7 @@ docs: >- - minute - hour docs: Period to rate limit attempts + inline: true source: openapi: ../openapi.yml UpsertDestinationRequestRateLimitPeriod: @@ -11447,6 +11487,7 @@ docs: >- - minute - hour docs: Period to rate limit attempts + inline: true source: openapi: ../openapi.yml UpdateDestinationRequestRateLimitPeriod: @@ -11455,6 +11496,7 @@ docs: >- - minute - hour docs: Period to rate limit attempts + inline: true source: openapi: ../openapi.yml imports: @@ -14695,6 +14737,7 @@ docs: >- "ACKNOWLEDGED", "RESOLVED", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14753,6 +14796,7 @@ docs: >- - ACKNOWLEDGED - RESOLVED docs: New status + inline: true source: openapi: ../openapi.yml imports: @@ -15802,6 +15846,7 @@ docs: Notifications let your team receive alerts anytime an issue changes. "accepted", "rejected", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/humanloop.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/humanloop.json index 0b640f69072..368be829217 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/humanloop.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/humanloop.json @@ -228,6 +228,7 @@ in the Evaluation Report.", "system", "tool", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -570,6 +571,7 @@ in the inheriting classes with documentation and appropriate Field definitions." "default", "other", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -786,6 +788,7 @@ function.", "cancelled", "failed", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -847,6 +850,7 @@ function.", "target_free", "target_required", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -993,6 +997,7 @@ function.", "boolean", "number", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1005,6 +1010,7 @@ function.", "text", "number", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1016,6 +1022,7 @@ function.", "active", "inactive", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1092,6 +1099,7 @@ function.", "correction", "comment", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1277,6 +1285,7 @@ function.", "low", "auto", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1338,6 +1347,7 @@ Used by a File's PAPV (Positive Action Per View) metric.", "neutral", "unset", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1923,6 +1933,7 @@ Does not have things like the signature or setup schema.", "chat", "edit", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1941,6 +1952,7 @@ Does not have things like the signature or setup schema.", "google", "groq", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1995,6 +2007,7 @@ Does not have things like the signature or setup schema.", "active", "inactive", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2061,6 +2074,7 @@ Observability is implemented by running monitoring Evaluators on Logs.", "completed", "failed", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2168,6 +2182,7 @@ Observability is implemented by running monitoring Evaluators on Logs.", "supportadmin", "user", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2179,6 +2194,7 @@ Observability is implemented by running monitoring Evaluators on Logs.", "updated_at", "name", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2845,6 +2861,7 @@ Observability is implemented by running monitoring Evaluators on Logs.", "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2903,6 +2920,7 @@ Observability is implemented by running monitoring Evaluators on Logs.", "week", "month", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3187,6 +3205,7 @@ V4 uses organization and inline. Those are deprecated and will be removed in fav "organization", "inline", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3230,6 +3249,7 @@ V4 uses organization and inline. Those are deprecated and will be removed in fav "json_schema", "get_api_call", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3241,6 +3261,7 @@ V4 uses organization and inline. Those are deprecated and will be removed in fav "add", "remove", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3424,6 +3445,7 @@ V4 uses organization and inline. Those are deprecated and will be removed in fav "committed", "deleted", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4313,6 +4335,7 @@ types: Specify the detail level of the image provided to the model. For more details see: https://platform.openai.com/docs/guides/vision/low-or-high-fidelity-image-understanding + inline: true source: openapi: ../openapi.yml ImageUrl: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hume.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hume.json index 85e3504dc4d..525c50ba481 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hume.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/hume.json @@ -255,6 +255,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "tr", "uk", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, @@ -353,6 +354,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, @@ -555,6 +557,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "utterance", "conversational_turn", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, @@ -1068,6 +1071,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "started", "ended", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, @@ -1190,6 +1194,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "COMPLETED", "FAILED", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, @@ -1270,6 +1275,7 @@ If you wish to supply more than 100 URLs, consider providing them as an archive "created_before", "created_after", ], + "inline": undefined, "source": { "openapi": "../openapi.yaml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/inline-path-parameters.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/inline-path-parameters.json index 8a25286f6d0..80bde1edcc0 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/inline-path-parameters.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/inline-path-parameters.json @@ -213,6 +213,7 @@ types: "private", "public", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -235,6 +236,7 @@ types: - private - public docs: Access level + inline: true source: openapi: ../openapi.yml SearchResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/intercom.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/intercom.json index 344d1c9115e..d8df318af39 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/intercom.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/intercom.json @@ -2845,6 +2845,7 @@ "upfront_email_collection_change", "welcome_message_change", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3082,6 +3083,7 @@ "comment", "note", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3123,6 +3125,7 @@ "note", "quick_reply", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3280,6 +3283,7 @@ "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3533,6 +3537,7 @@ "admin", "team", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4538,6 +4543,7 @@ "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4683,6 +4689,7 @@ }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4725,7 +4732,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5439,6 +5446,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul }, "Unstable", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5495,6 +5503,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "ticket", "conversation", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5521,6 +5530,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "AND", "OR", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5591,6 +5601,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "draft", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5717,6 +5728,7 @@ Their responses are likely to contain a pages object that hosts pagination links "value": "conversation.list", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5978,6 +5990,7 @@ Their responses are likely to contain a pages object that hosts pagination links "value": "~", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6019,6 +6032,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "cancelled", "active", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6221,7 +6235,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6298,6 +6312,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "team", "user", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6374,6 +6389,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "comment", "quick_reply", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6386,7 +6402,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6617,6 +6633,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6668,6 +6685,7 @@ You can copy the `icon` property for your ticket type from [Twemoji Cheatsheet]( }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8445,6 +8463,7 @@ types: - temporary_expectation_change - upfront_email_collection_change - welcome_message_change + inline: true source: openapi: ../openapi.yml ActivityLog: @@ -8565,6 +8584,7 @@ types: enum: - comment - note + inline: true source: openapi: ../openapi.yml AdminReplyConversationRequest: @@ -8602,6 +8622,7 @@ types: - comment - note - quick_reply + inline: true source: openapi: ../openapi.yml AdminReplyTicketRequestReplyOptionsItem: @@ -8744,6 +8765,7 @@ types: - published - draft docs: Whether the article is `published` or is a `draft` . + inline: true source: openapi: ../openapi.yml ArticleContent: @@ -8951,6 +8973,7 @@ types: enum: - admin - team + inline: true source: openapi: ../openapi.yml AssignConversationRequest: @@ -9732,6 +9755,7 @@ types: Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + inline: true source: openapi: ../openapi.yml CreateArticleRequest: @@ -9859,6 +9883,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml CreateTicketTypeRequest: @@ -9920,6 +9945,7 @@ types: - type: optional source: openapi: ../openapi.yml + inline: true CustomAttributes: type: map docs: >- @@ -10440,6 +10466,7 @@ types: - ticket - conversation docs: ticket or conversation + inline: true source: openapi: ../openapi.yml LinkedObject: @@ -10480,6 +10507,7 @@ types: - AND - OR docs: An operator to allow boolean inspection between multiple fields. + inline: true source: openapi: ../openapi.yml MultipleFilterSearchRequestValue: @@ -10509,6 +10537,7 @@ types: docs: >- News items will not be visible to your users in the assigned newsfeeds until they are set live. + inline: true source: openapi: ../openapi.yml NewsItemRequest: @@ -10608,6 +10637,7 @@ types: - value: conversation.list name: ConversationList docs: The type of object + inline: true source: openapi: ../openapi.yml PaginatedResponseDataItem: @@ -10780,6 +10810,7 @@ types: docs: >- The accepted operators you can use to define how you want to search for the value. + inline: true source: openapi: ../openapi.yml SingleFilterSearchRequest: @@ -10809,6 +10840,7 @@ types: - `hit`: If there’s at least one hit event in the underlying sla_events table, and no “missed” or “canceled” events for the conversation. - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. + inline: true source: openapi: ../openapi.yml SlaApplied: @@ -10967,6 +10999,7 @@ types: - type: File source: openapi: ../openapi.yml + inline: true TicketCustomAttributes: type: map docs: >- @@ -10996,6 +11029,7 @@ types: - team - user docs: The type of the author + inline: true source: openapi: ../openapi.yml TicketPartAuthor: @@ -11043,6 +11077,7 @@ types: - comment - quick_reply docs: Type of the part + inline: true source: openapi: ../openapi.yml TicketReply: @@ -11085,6 +11120,7 @@ types: - list source: openapi: ../openapi.yml + inline: true TicketRequestCustomAttributes: type: map docs: >- @@ -11240,6 +11276,7 @@ types: Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + inline: true source: openapi: ../openapi.yml UpdateArticleRequest: @@ -11291,6 +11328,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml UpdateTicketTypeRequest: @@ -12415,6 +12453,7 @@ types: "workflow_preview", "fin_preview", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12432,6 +12471,7 @@ types: docs: >- The type of the source that triggered AI Agent involvement in the conversation. + inline: true source: openapi: ../openapi.yml AiAgent: @@ -12510,6 +12550,7 @@ imports: "content_snippet", "workflow_connector_action", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12525,6 +12566,7 @@ imports: - content_snippet - workflow_connector_action docs: The type of the content source. + inline: true source: openapi: ../openapi.yml ContentSource: @@ -15131,6 +15173,7 @@ imports: "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15179,6 +15222,7 @@ imports: "highlight", "plain", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15206,6 +15250,7 @@ imports: "highlight", "plain", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17617,6 +17662,7 @@ types: Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. default: draft + inline: true source: openapi: ../openapi.yml Articles: @@ -17702,6 +17748,7 @@ types: - highlight - plain docs: The type of text - `highlight` or `plain`. + inline: true source: openapi: ../openapi.yml ArticleSearchHighlightsHighlightedTitleItem: @@ -17721,6 +17768,7 @@ types: - highlight - plain docs: The type of text - `highlight` or `plain`. + inline: true source: openapi: ../openapi.yml ArticleSearchHighlightsHighlightedSummaryItemItem: @@ -26556,6 +26604,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "priority", "not_priority", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26567,6 +26616,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "closed", "snoozed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26601,6 +26651,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "user", "contact", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -29840,6 +29891,7 @@ types: - user - contact docs: The role associated to the contact - user or lead. + inline: true source: openapi: ../openapi.yml CreateConversationRequestFrom: @@ -29920,6 +29972,7 @@ types: - closed - snoozed docs: Can be set to "open", "closed" or "snoozed". + inline: true source: openapi: ../openapi.yml ConversationPriority: @@ -29927,6 +29980,7 @@ types: - priority - not_priority docs: If marked as priority, it will return priority or else not_priority. + inline: true source: openapi: ../openapi.yml Conversation: @@ -30980,6 +31034,7 @@ You can update a data attribute. "datetime", "date", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30990,6 +31045,7 @@ You can update a data attribute. "contact", "company", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31080,6 +31136,7 @@ You can update a data attribute. "boolean", "date", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31090,6 +31147,7 @@ You can update a data attribute. "contact", "company", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31100,6 +31158,7 @@ You can update a data attribute. "company", "conversation", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -31119,6 +31178,7 @@ You can update a data attribute. - contact - company docs: The model that the data attribute belongs to. + inline: true source: openapi: ../openapi.yml CreateDataAttributeRequestDataType: @@ -31130,6 +31190,7 @@ You can update a data attribute. - datetime - date docs: The type of data stored for this attribute. + inline: true source: openapi: ../openapi.yml DataAttributeModel: @@ -31139,6 +31200,7 @@ You can update a data attribute. docs: >- Value is `contact` for user/lead attributes and `company` for company attributes. + inline: true source: openapi: ../openapi.yml DataAttributeDataType: @@ -31149,6 +31211,7 @@ You can update a data attribute. - boolean - date docs: The data type of the attribute. + inline: true source: openapi: ../openapi.yml DataAttribute: @@ -32804,6 +32867,7 @@ Your exported message data will be streamed continuously back down to you in a g "no_data", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32995,6 +33059,7 @@ types: - no_data - canceled docs: The current state of your job. + inline: true source: openapi: ../openapi.yml DataExport: @@ -35981,6 +36046,7 @@ This will return the Message model that has been created. "facebook", "twitter", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -36158,6 +36224,7 @@ types: docs: >- The type of message that was sent. Can be email, inapp, facebook or twitter. + inline: true source: openapi: ../openapi.yml Message: @@ -36785,6 +36852,7 @@ types: "draft", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -37206,6 +37274,7 @@ types: docs: >- News items will not be visible to your users in the assigned newsfeeds until they are set live. + inline: true source: openapi: ../openapi.yml NewsItem: @@ -38210,6 +38279,7 @@ types: "contact", "user", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38304,6 +38374,7 @@ types: - contact - user docs: 'Type of the contact: contact (lead) or user.' + inline: true source: openapi: ../openapi.yml Segment: @@ -38660,6 +38731,7 @@ This will return a subscription type model for the subscription type that was ad "opt_out", "opt_in", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38669,6 +38741,7 @@ This will return a subscription type model for the subscription type that was ad "email", "sms_message", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38680,6 +38753,7 @@ This will return a subscription type model for the subscription type that was ad "draft", "archived", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38893,6 +38967,7 @@ types: - draft - archived docs: The state of the subscription type. + inline: true source: openapi: ../openapi.yml SubscriptionTypeConsentType: @@ -38900,12 +38975,14 @@ types: - opt_out - opt_in docs: Describes the type of consent. + inline: true source: openapi: ../openapi.yml SubscriptionTypeContentTypesItem: enum: - email - sms_message + inline: true source: openapi: ../openapi.yml SubscriptionType: @@ -41090,6 +41167,7 @@ types: "datetime", "files", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -41107,6 +41185,7 @@ types: - datetime - files docs: The data type of the attribute + inline: true source: openapi: ../openapi.yml imports: @@ -43552,6 +43631,7 @@ The table below shows the operators you can use to define how you want to search }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43624,6 +43704,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43636,6 +43717,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43648,6 +43730,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43714,6 +43797,7 @@ The table below shows the operators you can use to define how you want to search }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43742,6 +43826,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43802,6 +43887,7 @@ types: - waiting_on_customer - resolved docs: The state of the ticket. + inline: true source: openapi: ../openapi.yml UpdateTicketRequestAssignment: @@ -43824,6 +43910,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket. + inline: true source: openapi: ../openapi.yml TicketTicketState: @@ -43833,6 +43920,7 @@ types: - waiting_on_customer - resolved docs: The state the ticket is currently in + inline: true source: openapi: ../openapi.yml Ticket: @@ -43918,6 +44006,7 @@ types: - waiting_on_customer - resolved docs: The previous state of the ticket. + inline: true source: openapi: ../openapi.yml TicketPartTicketState: @@ -43927,6 +44016,7 @@ types: - waiting_on_customer - resolved docs: The state of the ticket. + inline: true source: openapi: ../openapi.yml TicketPart: @@ -43981,6 +44071,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml TicketType: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/merge.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/merge.json index 5419f90792a..5fb5fc872e9 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/merge.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/merge.json @@ -105,6 +105,7 @@ View a list of your organization's `LinkedAccount` objects.", "INCOMPLETE", "RELINK_NEEDED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -183,6 +184,7 @@ View a list of your organization's `LinkedAccount` objects.", "SAVINGS", "CHECKING", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -368,6 +370,7 @@ Fetch from the `LIST Benefits` endpoint and filter by `ID` to show all benefits. "mktg", "filestorage", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -389,6 +392,7 @@ Fetch from the `LIST Benefits` endpoint and filter by `ID` to show all benefits. "mktg", "filestorage", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -530,6 +534,7 @@ Fetch from the `LIST Companies` endpoint and filter by `ID` to show all companie "STRING", "LIST_OF_STRINGS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1035,6 +1040,7 @@ Fetch from the `LIST Companies` endpoint and filter by `ID` to show all companie "ZM", "ZW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1246,6 +1252,7 @@ Fetch from the `LIST Earnings` endpoint and filter by `ID` to show all earnings. "OVERTIME", "BONUS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2223,6 +2230,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "PENDING", "INACTIVE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2240,6 +2248,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "CONTRACTOR", "FREELANCE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2251,6 +2260,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "READ", "WRITE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2264,6 +2274,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "BASE64", "GZIP_BASE64", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2374,6 +2385,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "WHITE", "PREFER_NOT_TO_DISCLOSE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2389,6 +2401,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "NONEXEMPT", "OWNER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2409,6 +2422,7 @@ Fetch from the `LIST Employments` endpoint and filter by `ID` to show all employ "OTHER", "PREFER_NOT_TO_DISCLOSE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2510,6 +2524,7 @@ Fetch from the `LIST Employee` endpoint and expand groups to view an employee's "BUSINESS_UNIT", "GROUP", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2571,6 +2586,7 @@ Fetch from the `LIST Employee` endpoint and expand groups to view an employee's "ONGOING", "RESOLVED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3023,6 +3039,7 @@ Fetch from the `LIST Locations` endpoint and filter by `ID` to show all office l "HOME", "WORK", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3040,6 +3057,7 @@ Fetch from the `LIST Locations` endpoint and filter by `ID` to show all office l "HEAD_OF_HOUSEHOLD", "QUALIFYING_WIDOW_OR_WIDOWER_WITH_DEPENDENT_CHILD", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3075,6 +3093,7 @@ Fetch from the `LIST Locations` endpoint and filter by `ID` to show all office l "PATCH", "DELETE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3995,6 +4014,7 @@ Create a `MultipartFormField` to define a multipart form entry.", "ZWR", "ZWL", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4023,6 +4043,7 @@ Create a `MultipartFormField` to define a multipart form entry.", "PRO_RATA", "SEMIMONTHLY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4089,6 +4110,7 @@ Fetch from the `LIST PayGroup` endpoint and filter by `ID` to show all pay group "EVERY_SIX_MONTHS", "YEAR", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4177,6 +4199,7 @@ Fetch from the `LIST PayrollRuns` endpoint and filter by `ID` to show all payrol "VOLUNTEER", "BEREAVEMENT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4190,6 +4213,7 @@ Fetch from the `LIST PayrollRuns` endpoint and filter by `ID` to show all payrol "GDPR", "OTHER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4274,6 +4298,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "XML", "MULTIPART", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4293,6 +4318,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "VOLUNTEER", "BEREAVEMENT", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4304,6 +4330,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "JSON", "BASE64_GZIP", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4321,6 +4348,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "FAILED", "CLOSED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4338,6 +4366,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "TERMINATION", "SIGN_ON_BONUS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4349,6 +4378,7 @@ View the `RemoteResponse` returned from your `DataPassthrough`.", "IN_NEXT_SYNC", "IN_LAST_SYNC", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4389,6 +4419,7 @@ View the `SyncStatus` for an account to see how recently its models were synced. "PAUSED", "PARTIALLY_SYNCED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4782,6 +4813,7 @@ Fetch from the `LIST TimeOffs` endpoint and filter by `ID` to show all time off "CANCELLED", "DELETED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4793,6 +4825,7 @@ Fetch from the `LIST TimeOffs` endpoint and filter by `ID` to show all time off "HOURS", "DAYS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10270,6 +10303,7 @@ service: "CHECKING", "SAVINGS", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -10285,6 +10319,7 @@ service: "value": "remote_created_at", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11524,6 +11559,7 @@ service: }, "payroll_run", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -11537,6 +11573,7 @@ service: }, "payroll_run", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -12362,6 +12399,7 @@ service: "INACTIVE", "PENDING", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13365,6 +13403,7 @@ service: "value": "work_location,team,pay_group", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13420,6 +13459,7 @@ service: }, "marital_status", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13475,6 +13515,7 @@ service: }, "marital_status", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -14478,6 +14519,7 @@ service: "value": "work_location,team,pay_group", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -14533,6 +14575,7 @@ service: }, "marital_status", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -14588,6 +14631,7 @@ service: }, "marital_status", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16386,6 +16430,7 @@ service: }, "pay_group", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16401,6 +16446,7 @@ service: "value": "effective_date", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16456,6 +16502,7 @@ service: }, "pay_period", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16511,6 +16558,7 @@ service: }, "pay_period", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16524,6 +16572,7 @@ service: }, "pay_group", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16579,6 +16628,7 @@ service: }, "pay_period", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16634,6 +16684,7 @@ service: }, "pay_period", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -17599,6 +17650,7 @@ service: "ONGOING", "RESOLVED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -17969,6 +18021,7 @@ service: "mktg", "ticketing", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -19079,6 +19132,7 @@ service: }, "run_type", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -19091,6 +19145,7 @@ service: "SIGN_ON_BONUS", "TERMINATION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -19104,6 +19159,7 @@ service: }, "run_type", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -19117,6 +19173,7 @@ service: }, "run_type", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -19130,6 +19187,7 @@ service: }, "run_type", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20515,6 +20573,7 @@ service: "value": "employee,approver", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20541,6 +20600,7 @@ service: }, "units", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20554,6 +20614,7 @@ service: "VACATION", "VOLUNTEER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20580,6 +20641,7 @@ service: }, "units", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20592,6 +20654,7 @@ service: "DELETED", "REQUESTED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20605,6 +20668,7 @@ service: "value": "employee,approver", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20631,6 +20695,7 @@ service: }, "units", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20657,6 +20722,7 @@ service: }, "units", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -21274,6 +21340,7 @@ service: "VACATION", "VOLUNTEER", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/non-alphanumeric-characters.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/non-alphanumeric-characters.json index 0e93f21bc04..205a502067b 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/non-alphanumeric-characters.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/non-alphanumeric-characters.json @@ -66,6 +66,7 @@ "value": "", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/ntropy.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/ntropy.json index 1234b194890..eca84e8fbf6 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/ntropy.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/ntropy.json @@ -119,6 +119,7 @@ "consumer", "business", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -129,6 +130,7 @@ "consumer", "business", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -148,6 +150,7 @@ "financing", "taxes", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -287,6 +290,7 @@ "invalid_bank_statement", "internal_error", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -328,6 +332,7 @@ "completed", "error", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -459,6 +464,7 @@ enriched transactions.", "completed", "error", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -488,6 +494,7 @@ enriched transactions.", "low", "unknown", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -545,6 +552,7 @@ enriched transactions.", "person", "organization", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -797,6 +805,7 @@ enriched transactions.", "ZM", "ZW", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -955,6 +964,7 @@ enriched transactions.", "ZWL", "HRK", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -982,6 +992,7 @@ enriched transactions.", "processed", "failed", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -996,6 +1007,7 @@ enriched transactions.", "person", "transaction_type", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1098,6 +1110,7 @@ enriched transactions.", "incoming", "outgoing", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1454,6 +1467,7 @@ enriched transactions.", "delivery_service", "payment_processor", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1811,6 +1825,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "yearly", "other", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1825,6 +1840,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "value": "one off", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1885,6 +1901,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "resolved", "rejected", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2044,6 +2061,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "account_holder_not_found", "internal_error", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2216,6 +2234,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "value": "batches.error", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2289,6 +2308,7 @@ whether a transaction is a one-time event or a part of a recurring series.", "account_holder_id", "account_holder_name", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3606,6 +3626,7 @@ types: name: BatchesCompleted - value: batches.error name: BatchesError + inline: true source: openapi: ../openapi.yml Webhook: @@ -9684,6 +9705,7 @@ sdk.webhooks.create( "value": "batches.error", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9719,6 +9741,7 @@ sdk.webhooks.create( "value": "batches.error", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -10052,6 +10075,7 @@ types: name: BatchesCompleted - value: batches.error name: BatchesError + inline: true source: openapi: ../openapi.yml WebhookPatchEventsItem: @@ -10070,6 +10094,7 @@ types: name: BatchesCompleted - value: batches.error name: BatchesError + inline: true source: openapi: ../openapi.yml ", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/oauth.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/oauth.json index 4fa557b7ba4..319dfb66338 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/oauth.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/oauth.json @@ -123,6 +123,7 @@ "refresh_token", "client_credentials", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -152,6 +153,7 @@ - refresh_token - client_credentials docs: The type of grant to request + inline: true source: openapi: ../openapi.yml AuthGetTokenResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/only-include-referenced-schemas.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/only-include-referenced-schemas.json index a5fd6fe7cb1..2b7438636ca 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/only-include-referenced-schemas.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/only-include-referenced-schemas.json @@ -2844,6 +2844,7 @@ "upfront_email_collection_change", "welcome_message_change", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3081,6 +3082,7 @@ "comment", "note", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3122,6 +3124,7 @@ "note", "quick_reply", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3279,6 +3282,7 @@ "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3532,6 +3536,7 @@ "admin", "team", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4506,6 +4511,7 @@ "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4634,6 +4640,7 @@ }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4676,7 +4683,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5223,6 +5230,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "ticket", "conversation", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5249,6 +5257,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "AND", "OR", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5319,6 +5328,7 @@ A "cursor" or pointer is used to keep track of the current position in the resul "draft", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5445,6 +5455,7 @@ Their responses are likely to contain a pages object that hosts pagination links "value": "conversation.list", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5706,6 +5717,7 @@ Their responses are likely to contain a pages object that hosts pagination links "value": "~", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5747,6 +5759,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "cancelled", "active", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5949,7 +5962,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6026,6 +6039,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "team", "user", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6102,6 +6116,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "comment", "quick_reply", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6114,7 +6129,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "discriminated": false, "docs": undefined, "encoding": undefined, - "inline": undefined, + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6345,6 +6360,7 @@ Important: if there are any canceled sla_events for the conversation - meaning a "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6396,6 +6412,7 @@ You can copy the `icon` property for your ticket type from [Twemoji Cheatsheet]( }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8152,6 +8169,7 @@ types: - temporary_expectation_change - upfront_email_collection_change - welcome_message_change + inline: true source: openapi: ../openapi.yml ActivityLog: @@ -8272,6 +8290,7 @@ types: enum: - comment - note + inline: true source: openapi: ../openapi.yml AdminReplyConversationRequest: @@ -8309,6 +8328,7 @@ types: - comment - note - quick_reply + inline: true source: openapi: ../openapi.yml AdminReplyTicketRequestReplyOptionsItem: @@ -8451,6 +8471,7 @@ types: - published - draft docs: Whether the article is `published` or is a `draft` . + inline: true source: openapi: ../openapi.yml ArticleContent: @@ -8658,6 +8679,7 @@ types: enum: - admin - team + inline: true source: openapi: ../openapi.yml AssignConversationRequest: @@ -9414,6 +9436,7 @@ types: Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + inline: true source: openapi: ../openapi.yml CreateArticleRequest: @@ -9534,6 +9557,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml CreateTicketTypeRequest: @@ -9595,6 +9619,7 @@ types: - type: optional source: openapi: ../openapi.yml + inline: true CustomAttributes: type: map docs: >- @@ -9941,6 +9966,7 @@ types: - ticket - conversation docs: ticket or conversation + inline: true source: openapi: ../openapi.yml LinkedObject: @@ -9981,6 +10007,7 @@ types: - AND - OR docs: An operator to allow boolean inspection between multiple fields. + inline: true source: openapi: ../openapi.yml MultipleFilterSearchRequestValue: @@ -10010,6 +10037,7 @@ types: docs: >- News items will not be visible to your users in the assigned newsfeeds until they are set live. + inline: true source: openapi: ../openapi.yml NewsItemRequest: @@ -10109,6 +10137,7 @@ types: - value: conversation.list name: ConversationList docs: The type of object + inline: true source: openapi: ../openapi.yml PaginatedResponseDataItem: @@ -10281,6 +10310,7 @@ types: docs: >- The accepted operators you can use to define how you want to search for the value. + inline: true source: openapi: ../openapi.yml SingleFilterSearchRequest: @@ -10310,6 +10340,7 @@ types: - `hit`: If there’s at least one hit event in the underlying sla_events table, and no “missed” or “canceled” events for the conversation. - `missed`: If there are any missed sla_events for the conversation and no canceled events. If there’s even a single missed sla event, the status will always be missed. A missed status is not applied when the SLA expires, only the next time a teammate replies. - `active`: An SLA has been applied to a conversation, but has not yet been fulfilled. SLA status is active only if there are no “hit, “missed”, or “canceled” events. + inline: true source: openapi: ../openapi.yml SlaApplied: @@ -10468,6 +10499,7 @@ types: - type: File source: openapi: ../openapi.yml + inline: true TicketCustomAttributes: type: map docs: >- @@ -10497,6 +10529,7 @@ types: - team - user docs: The type of the author + inline: true source: openapi: ../openapi.yml TicketPartAuthor: @@ -10544,6 +10577,7 @@ types: - comment - quick_reply docs: Type of the part + inline: true source: openapi: ../openapi.yml TicketReply: @@ -10586,6 +10620,7 @@ types: - list source: openapi: ../openapi.yml + inline: true TicketRequestCustomAttributes: type: map docs: >- @@ -10741,6 +10776,7 @@ types: Whether the article will be `published` or will be a `draft`. Defaults to draft. For multilingual articles, this will be the state of the default language's content. + inline: true source: openapi: ../openapi.yml UpdateArticleRequest: @@ -10792,6 +10828,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml UpdateTicketTypeRequest: @@ -11901,6 +11938,7 @@ types: "workflow_preview", "fin_preview", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -11918,6 +11956,7 @@ types: docs: >- The type of the source that triggered AI Agent involvement in the conversation. + inline: true source: openapi: ../openapi.yml AiAgent: @@ -11996,6 +12035,7 @@ imports: "content_snippet", "workflow_connector_action", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12011,6 +12051,7 @@ imports: - content_snippet - workflow_connector_action docs: The type of the content source. + inline: true source: openapi: ../openapi.yml ContentSource: @@ -14617,6 +14658,7 @@ imports: "published", "draft", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14665,6 +14707,7 @@ imports: "highlight", "plain", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14692,6 +14735,7 @@ imports: "highlight", "plain", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17103,6 +17147,7 @@ types: Whether the article is `published` or is a `draft`. For multilingual articles, this will be the state of the default language's content. default: draft + inline: true source: openapi: ../openapi.yml Articles: @@ -17188,6 +17233,7 @@ types: - highlight - plain docs: The type of text - `highlight` or `plain`. + inline: true source: openapi: ../openapi.yml ArticleSearchHighlightsHighlightedTitleItem: @@ -17207,6 +17253,7 @@ types: - highlight - plain docs: The type of text - `highlight` or `plain`. + inline: true source: openapi: ../openapi.yml ArticleSearchHighlightsHighlightedSummaryItemItem: @@ -26042,6 +26089,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "priority", "not_priority", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26053,6 +26101,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "closed", "snoozed", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -26087,6 +26136,7 @@ If you want to reply to a coveration or take an action such as assign, unassign, "user", "contact", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -29326,6 +29376,7 @@ types: - user - contact docs: The role associated to the contact - user or lead. + inline: true source: openapi: ../openapi.yml CreateConversationRequestFrom: @@ -29406,6 +29457,7 @@ types: - closed - snoozed docs: Can be set to "open", "closed" or "snoozed". + inline: true source: openapi: ../openapi.yml ConversationPriority: @@ -29413,6 +29465,7 @@ types: - priority - not_priority docs: If marked as priority, it will return priority or else not_priority. + inline: true source: openapi: ../openapi.yml Conversation: @@ -30466,6 +30519,7 @@ You can update a data attribute. "datetime", "date", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30476,6 +30530,7 @@ You can update a data attribute. "contact", "company", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30566,6 +30621,7 @@ You can update a data attribute. "boolean", "date", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30576,6 +30632,7 @@ You can update a data attribute. "contact", "company", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30586,6 +30643,7 @@ You can update a data attribute. "company", "conversation", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -30605,6 +30663,7 @@ You can update a data attribute. - contact - company docs: The model that the data attribute belongs to. + inline: true source: openapi: ../openapi.yml CreateDataAttributeRequestDataType: @@ -30616,6 +30675,7 @@ You can update a data attribute. - datetime - date docs: The type of data stored for this attribute. + inline: true source: openapi: ../openapi.yml DataAttributeModel: @@ -30625,6 +30685,7 @@ You can update a data attribute. docs: >- Value is `contact` for user/lead attributes and `company` for company attributes. + inline: true source: openapi: ../openapi.yml DataAttributeDataType: @@ -30635,6 +30696,7 @@ You can update a data attribute. - boolean - date docs: The data type of the attribute. + inline: true source: openapi: ../openapi.yml DataAttribute: @@ -32214,6 +32276,7 @@ Your exported message data will be streamed continuously back down to you in a g "no_data", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32405,6 +32468,7 @@ types: - no_data - canceled docs: The current state of your job. + inline: true source: openapi: ../openapi.yml DataExport: @@ -35391,6 +35455,7 @@ This will return the Message model that has been created. "facebook", "twitter", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -35568,6 +35633,7 @@ types: docs: >- The type of message that was sent. Can be email, inapp, facebook or twitter. + inline: true source: openapi: ../openapi.yml Message: @@ -36195,6 +36261,7 @@ types: "draft", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -36616,6 +36683,7 @@ types: docs: >- News items will not be visible to your users in the assigned newsfeeds until they are set live. + inline: true source: openapi: ../openapi.yml NewsItem: @@ -37620,6 +37688,7 @@ types: "contact", "user", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -37714,6 +37783,7 @@ types: - contact - user docs: 'Type of the contact: contact (lead) or user.' + inline: true source: openapi: ../openapi.yml Segment: @@ -38070,6 +38140,7 @@ This will return a subscription type model for the subscription type that was ad "opt_out", "opt_in", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38079,6 +38150,7 @@ This will return a subscription type model for the subscription type that was ad "email", "sms_message", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38090,6 +38162,7 @@ This will return a subscription type model for the subscription type that was ad "draft", "archived", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -38303,6 +38376,7 @@ types: - draft - archived docs: The state of the subscription type. + inline: true source: openapi: ../openapi.yml SubscriptionTypeConsentType: @@ -38310,12 +38384,14 @@ types: - opt_out - opt_in docs: Describes the type of consent. + inline: true source: openapi: ../openapi.yml SubscriptionTypeContentTypesItem: enum: - email - sms_message + inline: true source: openapi: ../openapi.yml SubscriptionType: @@ -40500,6 +40576,7 @@ types: "datetime", "files", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40517,6 +40594,7 @@ types: - datetime - files docs: The data type of the attribute + inline: true source: openapi: ../openapi.yml imports: @@ -42962,6 +43040,7 @@ The table below shows the operators you can use to define how you want to search }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43034,6 +43113,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43046,6 +43126,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43058,6 +43139,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43124,6 +43206,7 @@ The table below shows the operators you can use to define how you want to search }, "Tracker", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43152,6 +43235,7 @@ The table below shows the operators you can use to define how you want to search "waiting_on_customer", "resolved", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43212,6 +43296,7 @@ types: - waiting_on_customer - resolved docs: The state of the ticket. + inline: true source: openapi: ../openapi.yml UpdateTicketRequestAssignment: @@ -43234,6 +43319,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket. + inline: true source: openapi: ../openapi.yml TicketTicketState: @@ -43243,6 +43329,7 @@ types: - waiting_on_customer - resolved docs: The state the ticket is currently in + inline: true source: openapi: ../openapi.yml Ticket: @@ -43328,6 +43415,7 @@ types: - waiting_on_customer - resolved docs: The previous state of the ticket. + inline: true source: openapi: ../openapi.yml TicketPartTicketState: @@ -43337,6 +43425,7 @@ types: - waiting_on_customer - resolved docs: The state of the ticket. + inline: true source: openapi: ../openapi.yml TicketPart: @@ -43391,6 +43480,7 @@ types: name: BackOffice - Tracker docs: Category of the Ticket Type. + inline: true source: openapi: ../openapi.yml TicketType: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/openapi-filter.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/openapi-filter.json index dc1231b4ea9..0cde222d73d 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/openapi-filter.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/openapi-filter.json @@ -725,6 +725,7 @@ types: "contact", "user", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -737,6 +738,7 @@ types: - contact - user docs: 'Type of the contact: contact (lead) or user.' + inline: true source: openapi: ../openapi.yml Segment: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/permit.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/permit.json index 61a8144055b..51cebc15e77 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/permit.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/permit.json @@ -145,6 +145,7 @@ "array", "json", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -357,6 +358,7 @@ "userset", "resourceset", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -741,6 +743,7 @@ "failed", "canceled", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -766,6 +769,7 @@ "read", "no_access", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -777,6 +781,7 @@ "project", "env", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -793,6 +798,7 @@ "connect_sdk", "done", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2633,6 +2639,7 @@ The actions represents the ways you can interact with a protected resource.", "active", "pending", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -7874,6 +7881,7 @@ allowed.", "fail", "overwrite", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -8340,6 +8348,7 @@ types: Action to take when detecting a conflict when copying. Only applies to copying into an existing environment default: fail + inline: true source: openapi: ../openapi.json ", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/query-params.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/query-params.json index 7805574f7b8..5d5571cd224 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/query-params.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/query-params.json @@ -92,6 +92,7 @@ "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/readonly.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/readonly.json index 82e436f7c5a..67eee6c06eb 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/readonly.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/readonly.json @@ -143,6 +143,7 @@ "suspended", "deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -253,6 +254,7 @@ types: - active - suspended - deleted + inline: true source: openapi: ../openapi.yml UserStatsRead: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/rightbrain.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/rightbrain.json index 3b35a54d507..2c2554129aa 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/rightbrain.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/rightbrain.json @@ -477,6 +477,7 @@ "dropbox", "sharepoint", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -573,6 +574,7 @@ "all", "viewable", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1053,6 +1055,7 @@ Some entities, such as Organizations, may contain members that exist without any "prompt_policy", "pii_policy", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1363,6 +1366,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "italian", "german", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1419,6 +1423,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1506,6 +1511,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "prompt_policy", "pii_policy", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1544,6 +1550,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "user_defined", "zendesk", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1587,6 +1594,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "no_size", "site", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1596,6 +1604,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "file", "dir", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1637,6 +1646,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "pending", "accepted", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1648,6 +1658,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "joinable_by_domain", "joinable_by_invite", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2164,6 +2175,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "dropbox", "sharepoint", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2190,6 +2202,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "RETRY", "PROGRESS", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2199,6 +2212,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "unverified", "verified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2496,6 +2510,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2510,6 +2525,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "integer", "list", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2562,6 +2578,7 @@ https://github.com/ory/kratos/blob/master/selfservice/hook/web_hook.go", "success", "validation", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2830,6 +2847,7 @@ types: - value: gemini-pro name: GeminiPro default: gpt-3.5-turbo + inline: true source: openapi: ../openapi.yml ChatConfig: @@ -2872,6 +2890,7 @@ types: - box - dropbox - sharepoint + inline: true source: openapi: ../openapi.yml ChatDocument: @@ -2940,6 +2959,7 @@ types: - source_validation - prompt_policy - pii_policy + inline: true source: openapi: ../openapi.yml Type: @@ -2948,6 +2968,7 @@ types: - error - success - validation + inline: true source: openapi: ../openapi.yml ChatGuardrail: @@ -2964,6 +2985,7 @@ types: enum: - prompt_policy - pii_policy + inline: true source: openapi: ../openapi.yml ChatModel: @@ -3048,6 +3070,7 @@ types: - italian - german default: english_british + inline: true source: openapi: ../openapi.yml ComposeInit: @@ -3182,6 +3205,7 @@ types: enum: - unverified - verified + inline: true source: openapi: ../openapi.yml DatasourceSyncRun: @@ -3213,6 +3237,7 @@ types: - FAILURE - RETRY - PROGRESS + inline: true source: openapi: ../openapi.yml DocumentCreateTask: @@ -3889,6 +3914,7 @@ types: - box - dropbox - sharepoint + inline: true source: openapi: ../openapi.yml SourceRow: @@ -4040,6 +4066,7 @@ types: - value: gemini-pro name: GeminiPro docs: The LLM model to use for the Task. + inline: true source: openapi: ../openapi.yml TaskRevisionOutputFormatValue: @@ -4051,6 +4078,7 @@ types: - int - integer - list + inline: true source: openapi: ../openapi.yml TaskRevision: @@ -4837,6 +4865,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -4847,6 +4876,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4857,6 +4887,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4874,6 +4905,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4930,6 +4962,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -5405,6 +5438,7 @@ types: - value: gemini-pro name: GeminiPro default: gpt-3.5-turbo + inline: true source: openapi: ../openapi.yml ChatIamListMembersRequestType: @@ -5419,6 +5453,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml ChatIamMemberRoleUpdateRemoveItem: @@ -5426,6 +5461,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml ChatIamPermissionTestPermissionsItem: @@ -5440,6 +5476,7 @@ types: - remove_owner - view - view_members + inline: true source: openapi: ../openapi.yml ", @@ -6309,6 +6346,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -6319,6 +6357,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6329,6 +6368,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6350,6 +6390,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -6965,6 +7006,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml CollectionIamMemberRoleUpdateRemoveItem: @@ -6972,6 +7014,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml CollectionIamPermissionTestPermissionsItem: @@ -6990,6 +7033,7 @@ types: - remove_owner - view - view_members + inline: true source: openapi: ../openapi.yml ", @@ -13924,6 +13968,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -13934,6 +13979,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13944,6 +13990,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13961,6 +14008,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13977,6 +14025,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "dropbox", "sharepoint", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -14009,6 +14058,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - editor - owner - viewer + inline: true source: openapi: ../openapi.yml DocumentIamMemberRoleUpdateRemoveItem: @@ -14016,6 +14066,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - editor - owner - viewer + inline: true source: openapi: ../openapi.yml DocumentIamPermissionTestPermissionsItem: @@ -14030,6 +14081,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - remove_owner - view - view_members + inline: true source: openapi: ../openapi.yml imports: @@ -16149,6 +16201,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -16159,6 +16212,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16169,6 +16223,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16186,6 +16241,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16205,6 +16261,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - editor - owner - viewer + inline: true source: openapi: ../openapi.yml OrganizationIamMemberRoleUpdateRemoveItem: @@ -16212,6 +16269,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - editor - owner - viewer + inline: true source: openapi: ../openapi.yml OrganizationIamPermissionTestPermissionsItem: @@ -16226,6 +16284,7 @@ This may be combined with `remove_all` to replace the member's entire role list. - remove_owner - view - view_members + inline: true source: openapi: ../openapi.yml imports: @@ -17496,6 +17555,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17506,6 +17566,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -17521,6 +17582,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "task_runner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17536,6 +17598,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "task_runner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17569,6 +17632,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view_data", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18064,6 +18128,7 @@ types: - value: gemini-pro name: GeminiPro default: gpt-3.5-turbo + inline: true source: openapi: ../openapi.yml ProjectIamListMembersRequestType: @@ -18083,6 +18148,7 @@ types: - task_creator - task_runner - viewer + inline: true source: openapi: ../openapi.yml ProjectIamMemberRoleUpdateRemoveItem: @@ -18095,6 +18161,7 @@ types: - task_creator - task_runner - viewer + inline: true source: openapi: ../openapi.yml ProjectIamPermissionTestPermissionsItem: @@ -18125,6 +18192,7 @@ types: - view - view_data - view_members + inline: true source: openapi: ../openapi.yml ", @@ -20265,6 +20333,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20279,6 +20348,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "integer", "list", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20289,6 +20359,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "organization", "project", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -20299,6 +20370,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20309,6 +20381,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "owner", "viewer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20326,6 +20399,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "view", "view_members", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20381,6 +20455,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "value": "gemini-pro", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20395,6 +20470,7 @@ This may be combined with `remove_all` to replace the member's entire role list. "integer", "list", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -21302,6 +21378,7 @@ types: - value: gemini-pro name: GeminiPro docs: The LLM model to use for the Task. + inline: true source: openapi: ../openapi.yml TaskCreateOutputFormatValue: @@ -21313,6 +21390,7 @@ types: - int - integer - list + inline: true source: openapi: ../openapi.yml TaskUpdateLlmModel: @@ -21341,6 +21419,7 @@ types: name: Gemini15ProLatest - value: gemini-pro name: GeminiPro + inline: true source: openapi: ../openapi.yml TaskUpdateOutputFormatValue: @@ -21352,6 +21431,7 @@ types: - int - integer - list + inline: true source: openapi: ../openapi.yml TaskIamListMembersRequestType: @@ -21366,6 +21446,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml TaskIamMemberRoleUpdateRemoveItem: @@ -21373,6 +21454,7 @@ types: - editor - owner - viewer + inline: true source: openapi: ../openapi.yml TaskIamPermissionTestPermissionsItem: @@ -21387,6 +21469,7 @@ types: - run_task - view - view_members + inline: true source: openapi: ../openapi.yml ", diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/seam.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/seam.json index ab1cf1a0152..83e53b61395 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/seam.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/seam.json @@ -136,6 +136,7 @@ "removing", "unknown", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -146,6 +147,7 @@ "time_bound", "ongoing", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -219,6 +221,7 @@ "salto_access_group", "brivo_group", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -230,6 +233,7 @@ "salto_access_group", "brivo_group", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -325,6 +329,7 @@ "card", "mobile_key", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -347,6 +352,7 @@ "hid_credential", "visionline_card", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -463,6 +469,7 @@ "guest", "staff", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -560,6 +567,7 @@ "value": "common (PMS)", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -581,6 +589,7 @@ "commonDoor", "touch", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -688,6 +697,7 @@ "assa_abloy_credential_service", "latch_building", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -708,6 +718,7 @@ "assa_abloy_credential_service", "latch_building", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -819,6 +830,7 @@ "salto_site_user", "latch_user", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -2522,6 +2534,7 @@ "cool", "heat_cool", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -2635,6 +2648,7 @@ "single", "multiple", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -2645,6 +2659,7 @@ "failed", "authorized", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -2798,6 +2813,7 @@ "battery", "phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -2852,6 +2868,7 @@ "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3151,6 +3168,7 @@ "good", "full", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3195,6 +3213,7 @@ "name_length", "name_must_be_unique", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3221,6 +3240,7 @@ "at_least_three_unique_digits", "cannot_contain_089", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3551,6 +3571,7 @@ "indoor", "outdoor", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3614,6 +3635,7 @@ "bridge", "doorking", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3740,6 +3762,7 @@ "honeywell_resideo", "latch", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -3752,6 +3775,7 @@ "noise_sensors", "access_control_systems", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4047,6 +4071,7 @@ "battery", "phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4069,6 +4094,7 @@ "android_phone", "ios_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4162,6 +4188,7 @@ "degraded", "down", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4229,6 +4256,7 @@ "time_bound", "ongoing", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4310,6 +4338,7 @@ "battery", "phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4351,6 +4380,7 @@ "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4497,6 +4527,7 @@ "good", "full", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4680,6 +4711,7 @@ types: Nature of the access code. Values are "ongoing" for access codes that are active continuously until deactivated manually or "time_bound" for access codes that have a specific duration. + inline: true source: openapi: ../openapi.json AccessCodeStatus: @@ -4693,6 +4725,7 @@ types: Current status of the access code within the operational lifecycle. Values are "setting," a transitional phase that indicates that the code is being configured or activated; "set", which indicates that the code is active and operational; "unset," which indicates a deactivated or unused state, either before activation or after deliberate deactivation; "removing," which indicates a transitional period in which the code is being deleted or made inactive; and "unknown," which indicates an indeterminate state, due to reasons such as system errors or incomplete data, that highlights a potential need for system review or troubleshooting. + inline: true source: openapi: ../openapi.json AccessCode: @@ -4796,6 +4829,7 @@ types: Nature of the access code. Values are "ongoing" for access codes that are active continuously until deactivated manually or "time_bound" for access codes that have a specific duration. + inline: true source: openapi: ../openapi.json UnmanagedAccessCode: @@ -6008,6 +6042,7 @@ types: - heat - cool - heat_cool + inline: true source: openapi: ../openapi.json ClimateSettingSchedule: @@ -6041,6 +6076,7 @@ types: - none - single - multiple + inline: true source: openapi: ../openapi.json ConnectWebviewStatus: @@ -6048,6 +6084,7 @@ types: - pending - failed - authorized + inline: true source: openapi: ../openapi.json ConnectWebviewCustomMetadataValue: @@ -6183,6 +6220,7 @@ types: - ios_phone - android_phone docs: Type of the device. + inline: true source: openapi: ../openapi.json DeviceCapabilitiesSupportedItem: @@ -6193,6 +6231,7 @@ types: - thermostat - battery - phone + inline: true source: openapi: ../openapi.json DevicePropertiesAccessoryKeypadBattery: @@ -6267,6 +6306,7 @@ types: - low - good - full + inline: true source: openapi: ../openapi.json DevicePropertiesBattery: @@ -6406,6 +6446,7 @@ types: enum: - indoor - outdoor + inline: true source: openapi: ../openapi.json DevicePropertiesNoiseawareMetadata: @@ -6506,6 +6547,7 @@ types: enum: - bridge - doorking + inline: true source: openapi: ../openapi.json DevicePropertiesSeamBridgeMetadata: @@ -6624,6 +6666,7 @@ types: - no_ascending_or_descending_sequence - at_least_three_unique_digits - cannot_contain_089 + inline: true source: openapi: ../openapi.json DevicePropertiesCodeConstraintsItemZero: @@ -6636,6 +6679,7 @@ types: enum: - name_length - name_must_be_unique + inline: true source: openapi: ../openapi.json DevicePropertiesCodeConstraintsItemMaxLength: @@ -6942,6 +6986,7 @@ types: - ios_phone - android_phone docs: Type of the device. + inline: true source: openapi: ../openapi.json UnmanagedDeviceCapabilitiesSupportedItem: @@ -6952,6 +6997,7 @@ types: - thermostat - battery - phone + inline: true source: openapi: ../openapi.json UnmanagedDeviceErrorsItem: @@ -6997,6 +7043,7 @@ types: - low - good - full + inline: true source: openapi: ../openapi.json UnmanagedDevicePropertiesBattery: @@ -7216,6 +7263,7 @@ types: - tedee - honeywell_resideo - latch + inline: true source: openapi: ../openapi.json DeviceProviderProviderCategoriesItem: @@ -7225,6 +7273,7 @@ types: - thermostats - noise_sensors - access_control_systems + inline: true source: openapi: ../openapi.json DeviceProvider: @@ -7300,6 +7349,7 @@ types: - healthy - degraded - down + inline: true source: openapi: ../openapi.json ServiceHealth: @@ -7346,6 +7396,7 @@ types: - visionline_system - assa_abloy_credential_service - latch_building + inline: true source: openapi: ../openapi.json AcsSystemSystemType: @@ -7364,6 +7415,7 @@ types: deprecated: use external_type --- + inline: true source: openapi: ../openapi.json AcsSystemErrorsItemSeamBridgeDisconnected: @@ -7446,6 +7498,7 @@ types: deprecated: use external_type --- + inline: true source: openapi: ../openapi.json AcsAccessGroupExternalType: @@ -7454,6 +7507,7 @@ types: - pti_access_level - salto_access_group - brivo_group + inline: true source: openapi: ../openapi.json AcsAccessGroup: @@ -7500,6 +7554,7 @@ types: - hid_credential_manager_user - salto_site_user - latch_user + inline: true source: openapi: ../openapi.json AcsUserAccessSchedule: @@ -7580,6 +7635,7 @@ types: - common - value: common (PMS) name: CommonPms + inline: true source: openapi: ../openapi.json AcsEntranceVisionlineMetadataProfilesItemVisionlineDoorProfileType: @@ -7587,6 +7643,7 @@ types: - BLE - commonDoor - touch + inline: true source: openapi: ../openapi.json AcsEntranceVisionlineMetadataProfilesItem: @@ -7670,6 +7727,7 @@ types: - code - card - mobile_key + inline: true source: openapi: ../openapi.json AcsCredentialExternalType: @@ -7678,6 +7736,7 @@ types: - brivo_credential - hid_credential - visionline_card + inline: true source: openapi: ../openapi.json AcsCredentialErrorsItem: @@ -7698,6 +7757,7 @@ types: enum: - guest - staff + inline: true source: openapi: ../openapi.json AcsCredentialVisionlineMetadata: @@ -7779,6 +7839,7 @@ types: enum: - android_phone - ios_phone + inline: true source: openapi: ../openapi.json PhoneCapabilitiesSupportedItem: @@ -7789,6 +7850,7 @@ types: - thermostat - battery - phone + inline: true source: openapi: ../openapi.json PhonePropertiesAssaAbloyCredentialServiceMetadataEndpointsItem: @@ -8709,6 +8771,7 @@ types: "throw", "create_random_code", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -8733,6 +8796,7 @@ types: "value": "1d", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -8768,6 +8832,7 @@ types: "value": "1d", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -8859,6 +8924,7 @@ types: "value": "1d", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -8868,6 +8934,7 @@ types: "ongoing", "time_bound", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -8897,6 +8964,7 @@ types: - value: 1d name: OneD default: 1hour + inline: true source: openapi: ../openapi.json AccessCodesCreateResponse: @@ -8911,6 +8979,7 @@ types: - throw - create_random_code default: throw + inline: true source: openapi: ../openapi.json AccessCodesCreateMultipleRequestMaxTimeRounding: @@ -8924,6 +8993,7 @@ types: - value: 1d name: OneD default: 1hour + inline: true source: openapi: ../openapi.json AccessCodesCreateMultipleResponse: @@ -8973,12 +9043,14 @@ types: - value: 1d name: OneD default: 1hour + inline: true source: openapi: ../openapi.json AccessCodesUpdateRequestType: enum: - ongoing - time_bound + inline: true source: openapi: ../openapi.json AccessCodesUpdateResponse: @@ -12032,6 +12104,7 @@ service: "card", "mobile_key", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -12074,6 +12147,7 @@ service: "TLCode", "rfid48", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -12084,6 +12158,7 @@ service: "guest", "staff", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -12180,12 +12255,14 @@ types: - code - card - mobile_key + inline: true source: openapi: ../openapi.json CredentialsCreateRequestVisionlineMetadataCardFormat: enum: - TLCode - rfid48 + inline: true source: openapi: ../openapi.json CredentialsCreateRequestVisionlineMetadataCardFunctionType: @@ -12193,6 +12270,7 @@ types: - guest - staff default: guest + inline: true source: openapi: ../openapi.json CredentialsCreateRequestVisionlineMetadata: @@ -16680,6 +16758,7 @@ service: "hid_cm", "google_nest", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -16712,6 +16791,7 @@ service: "single", "multiple", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -16725,6 +16805,7 @@ service: "access_control_systems", "internal_beta", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -16793,6 +16874,7 @@ service: - none - single - multiple + inline: true source: openapi: ../openapi.json ConnectWebviewsCreateRequestAcceptedProvidersItem: @@ -16837,6 +16919,7 @@ service: - yale_access - hid_cm - google_nest + inline: true source: openapi: ../openapi.json ConnectWebviewsCreateRequestProviderCategory: @@ -16847,6 +16930,7 @@ service: - noise_sensors - access_control_systems - internal_beta + inline: true source: openapi: ../openapi.json ConnectWebviewsCreateRequestCustomMetadataValue: @@ -18375,6 +18459,7 @@ service: "noise_sensors", "access_control_systems", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -18439,6 +18524,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -18479,6 +18565,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -18493,6 +18580,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -18507,6 +18595,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -18548,6 +18637,7 @@ service: "tedee", "honeywell_resideo", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -18654,6 +18744,7 @@ service: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json DevicesListRequestDeviceTypesItem: @@ -18691,6 +18782,7 @@ service: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json DevicesListRequestManufacturer: @@ -18729,6 +18821,7 @@ service: - dormakaba_oracode - tedee - honeywell_resideo + inline: true source: openapi: ../openapi.json DevicesListRequestCustomMetadataHasValue: @@ -18748,6 +18841,7 @@ service: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json DevicesListRequestExcludeIfItem: @@ -18759,6 +18853,7 @@ service: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json DevicesListResponse: @@ -18774,6 +18869,7 @@ service: - thermostats - noise_sensors - access_control_systems + inline: true source: openapi: ../openapi.json DevicesListDeviceProvidersResponse: @@ -19869,6 +19965,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -19909,6 +20006,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -19923,6 +20021,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -19937,6 +20036,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -19978,6 +20078,7 @@ service: "tedee", "honeywell_resideo", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -20049,6 +20150,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json UnmanagedListRequestDeviceTypesItem: @@ -20086,6 +20188,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json UnmanagedListRequestManufacturer: @@ -20124,6 +20227,7 @@ types: - dormakaba_oracode - tedee - honeywell_resideo + inline: true source: openapi: ../openapi.json UnmanagedListRequestCustomMetadataHasValue: @@ -20143,6 +20247,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json UnmanagedListRequestExcludeIfItem: @@ -20154,6 +20259,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json UnmanagedListResponse: @@ -20792,6 +20898,7 @@ service: "value": "action_attempt.unlock_door.failed", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -21031,6 +21138,7 @@ service: "value": "action_attempt.unlock_door.failed", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -21184,6 +21292,7 @@ types: name: ActionAttemptUnlockDoorSucceeded - value: action_attempt.unlock_door.failed name: ActionAttemptUnlockDoorFailed + inline: true source: openapi: ../openapi.json EventsListRequestEventTypesItem: @@ -21304,6 +21413,7 @@ types: name: ActionAttemptUnlockDoorSucceeded - value: action_attempt.unlock_door.failed name: ActionAttemptUnlockDoorFailed + inline: true source: openapi: ../openapi.json EventsListResponse: @@ -22355,6 +22465,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -22395,6 +22506,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -22409,6 +22521,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -22423,6 +22536,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -22464,6 +22578,7 @@ service: "tedee", "honeywell_resideo", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -22549,6 +22664,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json LocksListRequestDeviceTypesItem: @@ -22586,6 +22702,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json LocksListRequestManufacturer: @@ -22624,6 +22741,7 @@ types: - dormakaba_oracode - tedee - honeywell_resideo + inline: true source: openapi: ../openapi.json LocksListRequestCustomMetadataHasValue: @@ -22643,6 +22761,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json LocksListRequestExcludeIfItem: @@ -22654,6 +22773,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json LocksListResponse: @@ -24787,6 +24907,7 @@ service: "android", "ios", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -24810,6 +24931,7 @@ service: - android - ios default: android + inline: true source: openapi: ../openapi.json SimulateCreateSandboxPhoneRequestPhoneMetadata: @@ -25848,6 +25970,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -25888,6 +26011,7 @@ service: "ios_phone", "android_phone", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -25902,6 +26026,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -25916,6 +26041,7 @@ service: "can_simulate_connection", "can_simulate_disconnection", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -25957,6 +26083,7 @@ service: "tedee", "honeywell_resideo", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -25988,6 +26115,7 @@ service: "auto", "on", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -25997,6 +26125,7 @@ service: "auto", "on", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -26036,6 +26165,7 @@ service: "cool", "heat_cool", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -26114,6 +26244,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json ThermostatsListRequestDeviceTypesItem: @@ -26151,6 +26282,7 @@ types: - honeywell_resideo_thermostat - ios_phone - android_phone + inline: true source: openapi: ../openapi.json ThermostatsListRequestManufacturer: @@ -26189,6 +26321,7 @@ types: - dormakaba_oracode - tedee - honeywell_resideo + inline: true source: openapi: ../openapi.json ThermostatsListRequestCustomMetadataHasValue: @@ -26208,6 +26341,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json ThermostatsListRequestExcludeIfItem: @@ -26219,6 +26353,7 @@ types: - can_simulate_removal - can_simulate_connection - can_simulate_disconnection + inline: true source: openapi: ../openapi.json ThermostatsListResponse: @@ -26237,12 +26372,14 @@ types: enum: - auto - 'on' + inline: true source: openapi: ../openapi.json ThermostatsSetFanModeRequestFanModeSetting: enum: - auto - 'on' + inline: true source: openapi: ../openapi.json ThermostatsSetFanModeResponse: @@ -26257,6 +26394,7 @@ types: - heat - cool - heat_cool + inline: true source: openapi: ../openapi.json ThermostatsUpdateRequestDefaultClimateSetting: @@ -27210,6 +27348,7 @@ service: "cool", "heat_cool", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -27264,6 +27403,7 @@ service: "cool", "heat_cool", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -27288,6 +27428,7 @@ service: - heat - cool - heat_cool + inline: true source: openapi: ../openapi.json ClimateSettingSchedulesCreateResponse: @@ -27319,6 +27460,7 @@ service: - heat - cool - heat_cool + inline: true source: openapi: ../openapi.json ClimateSettingSchedulesUpdateResponse: @@ -30541,6 +30683,7 @@ service: "circle", "square", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -30596,6 +30739,7 @@ service: enum: - circle - square + inline: true source: openapi: ../openapi.json WorkspacesCreateResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/squidex.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/squidex.json index f7f8a90af90..6336c86a9ef 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/squidex.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/squidex.json @@ -110,6 +110,7 @@ "User", "Group", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -553,6 +554,7 @@ "Path", "Items", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -601,6 +603,7 @@ "Image", "FileName", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -657,6 +660,7 @@ "Audio", "Video", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -894,6 +898,7 @@ "Checkbox", "Toggle", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -956,6 +961,7 @@ "Move", "Delete", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1020,6 +1026,7 @@ "Update", "Validate", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1637,6 +1644,7 @@ "Now", "Today", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1647,6 +1655,7 @@ "Date", "DateTime", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2194,6 +2203,7 @@ "Hide", "Require", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2287,6 +2297,7 @@ "TIFF", "WEBP", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2299,6 +2310,7 @@ "Completed", "Failed", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2505,6 +2517,7 @@ "Dropdown", "Stars", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2729,6 +2742,7 @@ "NoPermission", "ManagedByTeam", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2810,6 +2824,7 @@ "Checkboxes", "Input", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -2895,6 +2910,7 @@ "Min", "Stretch", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -3293,6 +3309,7 @@ "TextArea", "Url", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -3306,6 +3323,7 @@ "Failed", "Cancelled", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -3318,6 +3336,7 @@ "Failed", "Timeout", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -3605,6 +3624,7 @@ "Singleton", "Component", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -3678,6 +3698,7 @@ "Rule", "Schema", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -3821,6 +3842,7 @@ "WrongEvent", "WrongEventForTrigger", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -3871,6 +3893,7 @@ "Ascending", "Descending", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -3926,6 +3949,7 @@ "Html", "Markdown", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -3944,6 +3968,7 @@ "StockPhoto", "TextArea", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -4040,6 +4065,7 @@ "Checkboxes", "Dropdown", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -4204,6 +4230,7 @@ "Unauthorized", "Failed", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -4615,6 +4642,7 @@ "DELETE", "PATCH", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/suger.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/suger.json index fa49fbb7b64..eb600804380 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/suger.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/suger.json @@ -96,6 +96,7 @@ "Monthly", "Annual", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -120,6 +121,7 @@ "Engineering", "ChannelManager", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -194,6 +196,7 @@ "StopSelling", "Terminated", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -316,6 +319,7 @@ "cspCustomer", "billingGroup", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -362,6 +366,7 @@ "percentage", "absolute", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -372,6 +377,7 @@ "FLAT_RATE", "PER_USER", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -381,6 +387,7 @@ "customerPromotion", "cspPromotion", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -403,6 +410,7 @@ "withdrawn", "deleted", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -412,6 +420,7 @@ "pendingAcceptance", "accepted", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -437,6 +446,7 @@ "month", "year", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -471,6 +481,7 @@ "resourceNotFound", "schemaValidationError", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -480,6 +491,7 @@ "informational", "warning", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -530,6 +542,7 @@ "perMarket", "usd", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -594,6 +607,7 @@ "perMarket", "usd", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -614,6 +628,7 @@ "Month", "Year", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -637,6 +652,7 @@ "Recurring", "Usage", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -660,6 +676,7 @@ "sharedcore", "transactions", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -749,6 +766,7 @@ "Public", "Private", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -806,6 +824,7 @@ "ListingImage", "ListingVideo", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -818,6 +837,7 @@ "Processed", "ProcessFailed", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -892,6 +912,7 @@ "value": "contact-me", }, ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -901,6 +922,7 @@ "ListingOnly", "ListAndSell", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -931,6 +953,7 @@ "Inprogress", "Published", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -946,6 +969,7 @@ "Published", "InStore", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1015,6 +1039,7 @@ "AzureSkuVariant", "AzureTestDriveVariant", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1024,6 +1049,7 @@ "InActive", "Active", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1047,6 +1073,7 @@ "Days", "Months", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1058,6 +1085,7 @@ "TimedUsage", "Unlimited", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1254,6 +1282,7 @@ This member is required.", "InvalidQuantity", "BadArgument", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -1755,6 +1784,7 @@ in the google.rpc.Status.details field, or localized by the client.", "CONFIRMED", "PENDING_CONFIRMATION", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -1870,6 +1900,7 @@ in the google.rpc.Status.details field, or localized by the client.", "Update", "Delete", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1879,6 +1910,7 @@ in the google.rpc.Status.details field, or localized by the client.", "None", "Csp", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1888,6 +1920,7 @@ in the google.rpc.Status.details field, or localized by the client.", "None", "DryRun", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -1900,6 +1933,7 @@ in the google.rpc.Status.details field, or localized by the client.", "Suspended", "Unsubscribed", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2021,6 +2055,7 @@ in the google.rpc.Status.details field, or localized by the client.", "MONTH", "YEAR", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2030,6 +2065,7 @@ in the google.rpc.Status.details field, or localized by the client.", "FLAT_RATE", "PER_USER", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2154,6 +2190,7 @@ in the google.rpc.Status.details field, or localized by the client.", "QuantityChange", "Signup", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2180,6 +2217,7 @@ in the google.rpc.Status.details field, or localized by the client.", "ENTITLEMENT_TERM", "INTEGRATION", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2196,6 +2234,7 @@ in the google.rpc.Status.details field, or localized by the client.", "ISV", "CURRENT", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2301,6 +2340,7 @@ in the google.rpc.Status.details field, or localized by the client.", "USAGE", "SUBSCRIPTION_PLUS_USAGE", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2656,6 +2696,7 @@ This field is present only if the product has usage-based billing configured.", "value": "ENTITLEMENT_SUSPENDED", }, ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2725,6 +2766,7 @@ This field is present only if the product has usage-based billing configured.", "APPROVED", "REJECTED", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2740,6 +2782,7 @@ This field is present only if the product has usage-based billing configured.", "value": "ACCOUNT_ACTIVE", }, ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -2860,6 +2903,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -2888,6 +2932,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -2898,6 +2943,7 @@ This field is present only if the product has usage-based billing configured.", "VERIFIED", "NOT_VERIFIED", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3176,6 +3222,7 @@ This field is present only if the product has usage-based billing configured.", "NOTIFY_CONTACTS", "TEST", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3191,6 +3238,7 @@ This field is present only if the product has usage-based billing configured.", "DONE", "FAILED", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3258,6 +3306,7 @@ This field is present only if the product has usage-based billing configured.", "PRIVATE", "PUBLIC", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3450,6 +3499,7 @@ This field is present only if the product has usage-based billing configured.", "CollectableAmount", "DisbursedAmount", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3571,6 +3621,7 @@ This field is present only if the product has usage-based billing configured.", "DISTRIBUTION", "MONEY", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -3612,6 +3663,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3624,6 +3676,7 @@ This field is present only if the product has usage-based billing configured.", "PENDING_START", "UNKNOWN", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3663,6 +3716,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3710,6 +3764,7 @@ This field is present only if the product has usage-based billing configured.", "PRIVATE", "UNKNOWN", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3720,6 +3775,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3737,6 +3793,7 @@ This field is present only if the product has usage-based billing configured.", "CANCEL_FAILED", "CANCEL_SUCCESS", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3770,6 +3827,7 @@ This field is present only if the product has usage-based billing configured.", "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3783,6 +3841,7 @@ This field is present only if the product has usage-based billing configured.", "PER_USER", "USAGE_BASED", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -3996,6 +4055,7 @@ the same customer, dimension, and time, but a different quantity.", "CustomerNotSubscribed", "DuplicateRecord", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -4045,6 +4105,7 @@ types: enum: - Monthly - Annual + inline: true source: openapi: ../swagger.json AzureIncludedBaseQuantity: @@ -4059,6 +4120,7 @@ types: - CustomerSupport - Engineering - ChannelManager + inline: true source: openapi: ../swagger.json AzureListingContact: @@ -4104,6 +4166,7 @@ types: - Enabled - StopSelling - Terminated + inline: true source: openapi: ../swagger.json AzureMarketState: @@ -4130,6 +4193,7 @@ types: enum: - customerPromotion - cspPromotion + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOfferState: @@ -4138,12 +4202,14 @@ types: - live - withdrawn - deleted + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOfferSubState: enum: - pendingAcceptance - accepted + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOffer: @@ -4212,6 +4278,7 @@ types: enum: - cspCustomer - billingGroup + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOfferBeneficiaryRecipient: @@ -4224,6 +4291,7 @@ types: enum: - percentage - absolute + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOfferPricingPlanType: @@ -4231,6 +4299,7 @@ types: - FLAT_RATE - PER_USER docs: The type of the plan, FLAT_RATE or PER_USER. + inline: true source: openapi: ../swagger.json AzureMarketplacePrivateOfferPricing: @@ -4271,6 +4340,7 @@ types: - week - month - year + inline: true source: openapi: ../swagger.json AzureMarketplaceTerm: @@ -4296,12 +4366,14 @@ types: - productLocked - resourceNotFound - schemaValidationError + inline: true source: openapi: ../swagger.json AzureMarketplaceValidationLevel: enum: - informational - warning + inline: true source: openapi: ../swagger.json AzureMarketplaceValidation: @@ -4333,6 +4405,7 @@ types: - perMarket - usd docs: default "usd" + inline: true source: openapi: ../swagger.json AzurePriceAndAvailabilityPrivateOfferCustomMeters: @@ -4366,6 +4439,7 @@ types: - perMarket - usd docs: default "usd" + inline: true source: openapi: ../swagger.json AzurePriceAndAvailabilityRecurrentPrice: @@ -4388,6 +4462,7 @@ types: enum: - Month - Year + inline: true source: openapi: ../swagger.json AzurePriceCadence: @@ -4401,6 +4476,7 @@ types: - Flat - Recurring - Usage + inline: true source: openapi: ../swagger.json AzurePriceSchedule: @@ -4415,6 +4491,7 @@ types: enum: - sharedcore - transactions + inline: true source: openapi: ../swagger.json AzurePricingUnit: @@ -4470,6 +4547,7 @@ types: enum: - Public - Private + inline: true source: openapi: ../swagger.json AzureProductFeatureAvailability: @@ -4517,6 +4595,7 @@ types: - ListingAsset - ListingImage - ListingVideo + inline: true source: openapi: ../swagger.json AzureProductListingAssetState: @@ -4526,6 +4605,7 @@ types: - InProcessing - Processed - ProcessFailed + inline: true source: openapi: ../swagger.json AzureProductListingAsset: @@ -4581,12 +4661,14 @@ types: name: FreeTrial - value: contact-me name: ContactMe + inline: true source: openapi: ../swagger.json AzureProductSetupSellingOption: enum: - ListingOnly - ListAndSell + inline: true source: openapi: ../swagger.json AzureProductSetup: @@ -4604,6 +4686,7 @@ types: enum: - Inprogress - Published + inline: true source: openapi: ../swagger.json AzureProductSubmissionSubState: @@ -4616,6 +4699,7 @@ types: - Publishing - Published - InStore + inline: true source: openapi: ../swagger.json AzureProductSubmission: @@ -4638,12 +4722,14 @@ types: enum: - AzureSkuVariant - AzureTestDriveVariant + inline: true source: openapi: ../swagger.json AzureProductVariantState: enum: - InActive - Active + inline: true source: openapi: ../swagger.json AzureProductVariant: @@ -4693,6 +4779,7 @@ types: - Minute - Days - Months + inline: true source: openapi: ../swagger.json AzureProductVariantTrialType: @@ -4701,6 +4788,7 @@ types: - TimedAccess - TimedUsage - Unlimited + inline: true source: openapi: ../swagger.json AzureProductVariantTrial: @@ -5299,18 +5387,21 @@ types: - Read - Update - Delete + inline: true source: openapi: ../swagger.json SharedAzureMarketplaceSubscriptionSandboxType: enum: - None - Csp + inline: true source: openapi: ../swagger.json SharedAzureMarketplaceSubscriptionSessionMode: enum: - None - DryRun + inline: true source: openapi: ../swagger.json SharedAzureMarketplaceSubscription: @@ -6094,6 +6185,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedIdentityBuyer: @@ -6114,6 +6206,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedIdentityIntegrationStatus: @@ -6121,6 +6214,7 @@ types: - CREATED - VERIFIED - NOT_VERIFIED + inline: true source: openapi: ../swagger.json SharedIdentityIntegration: @@ -6357,6 +6451,7 @@ types: - PRIVATE - PUBLIC docs: The default visibility of offer is PRIVATE. + inline: true source: openapi: ../swagger.json SharedOfferInfo: @@ -6647,6 +6742,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedWorkloadEntitlementStatus: @@ -6656,6 +6752,7 @@ types: - SUSPENDED - PENDING_START - UNKNOWN + inline: true source: openapi: ../swagger.json SharedWorkloadEntitlement: @@ -6688,6 +6785,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedWorkloadEntitlementTerm: @@ -6723,6 +6821,7 @@ types: - PER_USER - PRIVATE - UNKNOWN + inline: true source: openapi: ../swagger.json SharedWorkloadOfferPartner: @@ -6730,6 +6829,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedWorkloadOfferStatus: @@ -6744,6 +6844,7 @@ types: - PENDING_CANCEL - CANCEL_FAILED - CANCEL_SUCCESS + inline: true source: openapi: ../swagger.json SharedWorkloadOffer: @@ -6776,6 +6877,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json SharedWorkloadProductProductType: @@ -6786,6 +6888,7 @@ types: - FLAT_RATE - PER_USER - USAGE_BASED + inline: true source: openapi: ../swagger.json SharedWorkloadProduct: @@ -8303,6 +8406,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -9787,6 +9891,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -9796,6 +9901,7 @@ service: "MARKETPLACE", "CRM", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -9806,6 +9912,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -9815,6 +9922,7 @@ service: "MARKETPLACE", "CRM", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -9825,6 +9933,7 @@ service: "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -9835,6 +9944,7 @@ service: "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -9845,6 +9955,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -9854,6 +9965,7 @@ service: "MARKETPLACE", "CRM", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -9864,6 +9976,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -9873,6 +9986,7 @@ service: "MARKETPLACE", "CRM", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -10292,6 +10406,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json GetIntegrationRequestPartner: @@ -10338,6 +10453,7 @@ types: - AWS - AZURE - GCP + inline: true source: openapi: ../swagger.json VerifyIntegrationRequestPartner: @@ -12453,6 +12569,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -13772,6 +13889,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -14517,6 +14635,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -14527,6 +14646,7 @@ service: "AZURE", "GCP", ], + "inline": undefined, "source": { "openapi": "../swagger.json", }, @@ -14538,6 +14658,7 @@ service: "AZURE", "GCP", ], + "inline": true, "source": { "openapi": "../swagger.json", }, @@ -14565,6 +14686,7 @@ service: - AZURE - GCP docs: Required. + inline: true source: openapi: ../swagger.json imports: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/switchboard.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/switchboard.json index 8a2e8f12e83..6eb7e548a62 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/switchboard.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/switchboard.json @@ -143,6 +143,7 @@ "partial_success", "failure", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -588,6 +589,7 @@ "running", "ended", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -707,6 +709,7 @@ types: - success - partial_success - failure + inline: true source: openapi: ../openapi.yml ExternalSessionAiResponseMetadata: @@ -990,6 +993,7 @@ types: - running - ended docs: Status of the session + inline: true source: openapi: ../openapi.yml StatusMessage: @@ -2376,6 +2380,7 @@ service: "running", "ended", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/uploadcare.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/uploadcare.json index 0227feb3f08..d0c1bfd6e63 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/uploadcare.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/uploadcare.json @@ -829,6 +829,7 @@ that are tool old (or that have not been created at all). "HSV", "LAB", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1074,6 +1075,7 @@ See [docs](https://uploadcare.com/docs/file-metadata/) and [REST API v0.7](/api- "HSV", "LAB", ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -1152,6 +1154,7 @@ change the value to `auto`. }, "auto", ], + "inline": undefined, "source": { "openapi": "../openapi.json", }, @@ -1689,6 +1692,7 @@ change the value to `auto`. - HSV - LAB docs: Image color mode. + inline: true source: openapi: ../openapi.json ImageInfoGeoLocation: @@ -1813,6 +1817,7 @@ change the value to `auto`. - HSV - LAB docs: Image color mode. + inline: true source: openapi: ../openapi.json SchemasImageInfoGeoLocation: @@ -4976,6 +4981,7 @@ this request will return information about the already uploaded file. "value": "1", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -4995,6 +5001,7 @@ to the value of the `check_URL_duplicates` parameter. "value": "1", }, ], + "inline": true, "source": { "openapi": "../openapi.json", }, @@ -5088,6 +5095,7 @@ types: this request will return information about the already uploaded file. default: '0' + inline: true source: openapi: ../openapi.json FromUrlUploadRequestSaveUrlDuplicates: @@ -5100,6 +5108,7 @@ types: Determines if the requested `source_url` should be kept in the history of fetched/uploaded URLs. If the value is not defined explicitly, it is set to the value of the `check_URL_duplicates` parameter. + inline: true source: openapi: ../openapi.json FromUrlUploadResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/valtown.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/valtown.json index 2f216262394..7ba3f68a848 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/valtown.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/valtown.json @@ -201,6 +201,7 @@ "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -216,6 +217,7 @@ "rpc", "httpnext", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -376,6 +378,7 @@ "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -391,6 +394,7 @@ "rpc", "httpnext", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -686,6 +690,7 @@ This value is not specified if the SQL statement was not an INSERT or if the tab docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml ExtendedValType: @@ -701,6 +706,7 @@ This value is not specified if the SQL statement was not an INSERT or if the tab The type of a val. HTTP can receive web requests, Email can receive emails, Cron runs periodically, and Script can be used for libraries or one-off calculations + inline: true source: openapi: ../openapi.yml ExtendedValLinks: @@ -799,6 +805,7 @@ This value is not specified if the SQL statement was not an INSERT or if the tab docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml BasicValType: @@ -814,6 +821,7 @@ This value is not specified if the SQL statement was not an INSERT or if the tab The type of a val. HTTP can receive web requests, Email can receive emails, Cron runs periodically, and Script can be used for libraries or one-off calculations + inline: true source: openapi: ../openapi.yml BasicValLinks: @@ -1219,6 +1227,7 @@ API endpoints", "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1234,6 +1243,7 @@ API endpoints", "rpc", "httpnext", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -1332,6 +1342,7 @@ types: docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml AliasValResponseType: @@ -1347,6 +1358,7 @@ types: The type of a val. HTTP can receive web requests, Email can receive emails, Cron runs periodically, and Script can be used for libraries or one-off calculations + inline: true source: openapi: ../openapi.yml AliasValResponseLinks: @@ -2300,6 +2312,7 @@ give access to details and data from the requesting user.", "received", "given", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2426,6 +2439,7 @@ give access to details and data from the requesting user.", "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2511,6 +2525,7 @@ give access to details and data from the requesting user.", "free", "pro", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -2647,6 +2662,7 @@ give access to details and data from the requesting user.", - free - pro docs: Your account tier + inline: true source: openapi: ../openapi.yml MeGetResponse: @@ -2717,6 +2733,7 @@ give access to details and data from the requesting user.", docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml MeCommentsResponseDataItemValAuthor: @@ -3413,6 +3430,7 @@ docs: Search "read", "deferred", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3550,6 +3568,7 @@ docs: Search - write - read - deferred + inline: true source: openapi: ../openapi.yml imports: @@ -4797,6 +4816,7 @@ let you get, create, and run vals.", "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4809,6 +4829,7 @@ let you get, create, and run vals.", "script", "email", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4820,6 +4841,7 @@ let you get, create, and run vals.", "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4832,6 +4854,7 @@ let you get, create, and run vals.", "script", "email", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4885,6 +4908,7 @@ let you get, create, and run vals.", "unlisted", "private", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4896,6 +4920,7 @@ let you get, create, and run vals.", "script", "email", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4931,6 +4956,7 @@ let you get, create, and run vals.", docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml ValsCreateRequestType: @@ -4942,6 +4968,7 @@ let you get, create, and run vals.", The type of the val you want to create. Note that this does not include interval vals, because they cannot be created through the API yet. default: script + inline: true source: openapi: ../openapi.yml ValsUpdateRequestPrivacy: @@ -4952,6 +4979,7 @@ let you get, create, and run vals.", docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml ValsUpdateRequestType: @@ -4962,6 +4990,7 @@ let you get, create, and run vals.", docs: >- The type of the val you want to update. Note that this does not include interval vals, because they cannot be created through the API yet. + inline: true source: openapi: ../openapi.yml ValsListResponseDataItem: @@ -4995,6 +5024,7 @@ let you get, create, and run vals.", docs: >- This val’s privacy setting. Unlisted vals do not appear on profile pages or elsewhere, but you can link to them. + inline: true source: openapi: ../openapi.yml ValsCreateVersionRequestType: @@ -5006,6 +5036,7 @@ let you get, create, and run vals.", The type of the val you want to create. Note that this does not include interval vals, because they cannot be created through the API yet. default: script + inline: true source: openapi: ../openapi.yml ValsCancelResponse: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/vellum.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/vellum.json index cd87a10eac3..2f7fb492392 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/vellum.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/vellum.json @@ -573,6 +573,7 @@ Used to submit feedback regarding the quality of previously generated completion "JINJA", "FUNCTION_DEFINITION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -610,6 +611,7 @@ Used to submit feedback regarding the quality of previously generated completion "USER", "FUNCTION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -641,6 +643,7 @@ Used to submit feedback regarding the quality of previously generated completion "STRING", "JSON", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -740,6 +743,7 @@ Used to submit feedback regarding the quality of previously generated completion "INACTIVE", "ARCHIVED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -887,6 +891,7 @@ Used to submit feedback regarding the quality of previously generated completion "ACTIVE", "ARCHIVED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -944,6 +949,7 @@ Used to submit feedback regarding the quality of previously generated completion "STAGING", "PRODUCTION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -983,6 +989,7 @@ Used to submit feedback regarding the quality of previously generated completion "STOP", "UNKNOWN", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1139,6 +1146,7 @@ Used to submit feedback regarding the quality of previously generated completion "INDEXED", "FAILED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1150,6 +1158,7 @@ Used to submit feedback regarding the quality of previously generated completion "ALL", "NONE", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1161,6 +1170,7 @@ Used to submit feedback regarding the quality of previously generated completion "GENERATE", "CLASSIFY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1342,6 +1352,7 @@ Used to submit feedback regarding the quality of previously generated completion "CREATION_FAILED", "DISABLED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1443,6 +1454,7 @@ Used to submit feedback regarding the quality of previously generated completion "PROCESSED", "FAILED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1630,6 +1642,7 @@ Used to submit feedback regarding the quality of previously generated completion "OPENAI", "PYQ", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -1901,6 +1914,7 @@ Used to submit feedback regarding the quality of previously generated completion "TEXT", "CHAT_HISTORY", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2324,6 +2338,7 @@ Used to submit feedback regarding the quality of previously generated completion "WORKFLOW_INITIALIZATION", "NODE_EXECUTION", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -2397,6 +2412,7 @@ Used to submit feedback regarding the quality of previously generated completion "FULFILLED", "REJECTED", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/webflow.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/webflow.json index 5fd90a8fa32..a94d307cdd9 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/webflow.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/webflow.json @@ -409,6 +409,7 @@ "value": "site_config:write", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -802,6 +803,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "value": "-CreatedOn", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -3196,6 +3198,7 @@ service: "Color", "ExtFileRef", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3291,6 +3294,7 @@ service: "Color", "ExtFileRef", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3393,6 +3397,7 @@ service: - Color - ExtFileRef docs: Choose these appropriate field type for your collection data + inline: true source: openapi: ../openapi.yml CollectionsCreateResponseFieldsItem: @@ -3468,6 +3473,7 @@ service: - Color - ExtFileRef docs: Choose these appropriate field type for your collection data + inline: true source: openapi: ../openapi.yml CollectionsGetResponseFieldsItem: @@ -3925,6 +3931,7 @@ service: "Color", "File", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -3983,6 +3990,7 @@ service: "Color", "ExtFileRef", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4041,6 +4049,7 @@ service: "Color", "ExtFileRef", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -4064,6 +4073,7 @@ service: - Color - File docs: Choose these appropriate field type for your collection data + inline: true source: openapi: ../openapi.yml FieldsCreateResponseType: @@ -4082,6 +4092,7 @@ service: - Color - ExtFileRef docs: Choose these appropriate field type for your collection data + inline: true source: openapi: ../openapi.yml FieldsCreateResponse: @@ -4128,6 +4139,7 @@ service: - Color - ExtFileRef docs: Choose these appropriate field type for your collection data + inline: true source: openapi: ../openapi.yml FieldsUpdateResponse: @@ -5620,6 +5632,7 @@ service: "name", "slug", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5629,6 +5642,7 @@ service: "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5735,6 +5749,7 @@ service: "name", "slug", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -5744,6 +5759,7 @@ service: "asc", "desc", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -8030,6 +8046,7 @@ service: "Phone", "Number", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8197,6 +8214,7 @@ service: "Phone", "Number", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -8416,6 +8434,7 @@ service: - Phone - Number docs: The field type + inline: true source: openapi: ../openapi.yml FormsListResponseFormsItemFieldsValue: @@ -8528,6 +8547,7 @@ service: - Phone - Number docs: The field type + inline: true source: openapi: ../openapi.yml FormsGetResponseFieldsValue: @@ -9246,6 +9266,7 @@ Required scope | `ecommerce:write` "infinite", "finite", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9277,6 +9298,7 @@ Required scope | `ecommerce:write` "infinite", "finite", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9287,6 +9309,7 @@ Required scope | `ecommerce:write` "infinite", "finite", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9318,6 +9341,7 @@ Required scope | `ecommerce:write` "infinite", "finite", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -9351,6 +9375,7 @@ Required scope | `ecommerce:write` - infinite - finite docs: infinite or finite + inline: true source: openapi: ../openapi.yml InventoryListResponse: @@ -9374,6 +9399,7 @@ Required scope | `ecommerce:write` - infinite - finite docs: infinite or finite + inline: true source: openapi: ../openapi.yml InventoryUpdateResponseInventoryType: @@ -9381,6 +9407,7 @@ Required scope | `ecommerce:write` - infinite - finite docs: infinite or finite + inline: true source: openapi: ../openapi.yml InventoryUpdateResponse: @@ -9404,6 +9431,7 @@ Required scope | `ecommerce:write` - infinite - finite docs: infinite or finite + inline: true source: openapi: ../openapi.yml EcommInventoryChangedPayload: @@ -12136,6 +12164,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12146,6 +12175,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12222,6 +12252,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12232,6 +12263,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12293,6 +12325,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12636,6 +12669,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12646,6 +12680,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12664,6 +12699,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12711,6 +12747,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -12851,6 +12888,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13102,6 +13140,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13112,6 +13151,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13188,6 +13228,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13198,6 +13239,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13259,6 +13301,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13602,6 +13645,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13612,6 +13656,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13630,6 +13675,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13677,6 +13723,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -13817,6 +13864,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14068,6 +14116,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14078,6 +14127,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14154,6 +14204,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14164,6 +14215,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14225,6 +14277,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14568,6 +14621,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14578,6 +14632,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14596,6 +14651,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14643,6 +14699,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14783,6 +14840,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -14841,6 +14899,7 @@ Required scope | `ecommerce:write` "disputed", "unfulfilled", ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -15067,6 +15126,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15077,6 +15137,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15153,6 +15214,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15163,6 +15225,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15224,6 +15287,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15567,6 +15631,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15577,6 +15642,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15595,6 +15661,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15642,6 +15709,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15782,6 +15850,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -15856,6 +15925,7 @@ Required scope | `ecommerce:write` "fraudulent", "requested", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16065,6 +16135,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16075,6 +16146,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16151,6 +16223,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16161,6 +16234,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16222,6 +16296,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16565,6 +16640,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16575,6 +16651,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16593,6 +16670,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16640,6 +16718,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -16780,6 +16859,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17031,6 +17111,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17041,6 +17122,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17117,6 +17199,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17127,6 +17210,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17188,6 +17272,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17531,6 +17616,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17541,6 +17627,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17559,6 +17646,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17606,6 +17694,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17746,6 +17835,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -17997,6 +18087,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18007,6 +18098,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18083,6 +18175,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18093,6 +18186,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18154,6 +18248,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18497,6 +18592,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18507,6 +18603,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18525,6 +18622,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18572,6 +18670,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18712,6 +18811,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18963,6 +19063,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -18973,6 +19074,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19049,6 +19151,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19059,6 +19162,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19120,6 +19224,7 @@ Required scope | `ecommerce:write` "won", "lost", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19463,6 +19568,7 @@ Required scope | `ecommerce:write` "kana", "kanji", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19473,6 +19579,7 @@ Required scope | `ecommerce:write` "shipping", "billing", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19491,6 +19598,7 @@ Required scope | `ecommerce:write` }, "refunded", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19538,6 +19646,7 @@ Required scope | `ecommerce:write` }, "Unknown", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -19678,6 +19787,7 @@ Required scope | `ecommerce:write` "shipping", "tax", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -20203,6 +20313,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemDisputeLastStatus: @@ -20218,6 +20329,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemCustomerPaid: @@ -20270,6 +20382,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemAllAddressesItemJapanType: @@ -20279,6 +20392,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemAllAddressesItem: @@ -20321,6 +20435,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemShippingAddressJapanType: @@ -20330,6 +20445,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemShippingAddress: @@ -20372,6 +20488,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemBillingAddressJapanType: @@ -20381,6 +20498,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemBillingAddress: @@ -20613,6 +20731,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemStripeCardExpires: @@ -20699,6 +20818,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersListResponseOrdersItemTotalsExtrasItemPrice: @@ -20954,6 +21074,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersGetResponseDisputeLastStatus: @@ -20969,6 +21090,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersGetResponseCustomerPaid: @@ -21021,6 +21143,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersGetResponseAllAddressesItemJapanType: @@ -21030,6 +21153,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersGetResponseAllAddressesItem: @@ -21072,6 +21196,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersGetResponseShippingAddressJapanType: @@ -21081,6 +21206,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersGetResponseShippingAddress: @@ -21123,6 +21249,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersGetResponseBillingAddressJapanType: @@ -21132,6 +21259,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersGetResponseBillingAddress: @@ -21364,6 +21492,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersGetResponseStripeCardExpires: @@ -21450,6 +21579,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersGetResponseTotalsExtrasItemPrice: @@ -21678,6 +21808,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseDisputeLastStatus: @@ -21693,6 +21824,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseCustomerPaid: @@ -21745,6 +21877,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseAllAddressesItemJapanType: @@ -21754,6 +21887,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseAllAddressesItem: @@ -21796,6 +21930,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseShippingAddressJapanType: @@ -21805,6 +21940,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseShippingAddress: @@ -21847,6 +21983,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseBillingAddressJapanType: @@ -21856,6 +21993,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseBillingAddress: @@ -22088,6 +22226,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseStripeCardExpires: @@ -22174,6 +22313,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersUpdateResponseTotalsExtrasItemPrice: @@ -22402,6 +22542,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseDisputeLastStatus: @@ -22417,6 +22558,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseCustomerPaid: @@ -22469,6 +22611,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseAllAddressesItemJapanType: @@ -22478,6 +22621,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseAllAddressesItem: @@ -22520,6 +22664,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseShippingAddressJapanType: @@ -22529,6 +22674,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseShippingAddress: @@ -22571,6 +22717,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseBillingAddressJapanType: @@ -22580,6 +22727,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseBillingAddress: @@ -22812,6 +22960,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseStripeCardExpires: @@ -22898,6 +23047,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersUpdateFulfillResponseTotalsExtrasItemPrice: @@ -23126,6 +23276,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseDisputeLastStatus: @@ -23141,6 +23292,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseCustomerPaid: @@ -23193,6 +23345,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseAllAddressesItemJapanType: @@ -23202,6 +23355,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseAllAddressesItem: @@ -23244,6 +23398,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseShippingAddressJapanType: @@ -23253,6 +23408,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseShippingAddress: @@ -23295,6 +23451,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseBillingAddressJapanType: @@ -23304,6 +23461,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseBillingAddress: @@ -23537,6 +23695,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseStripeCardExpires: @@ -23623,6 +23782,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersUpdateUnfulfillResponseTotalsExtrasItemPrice: @@ -23846,6 +24006,7 @@ Required scope | `ecommerce:write` - fraudulent - requested docs: The reason for the refund + inline: true source: openapi: ../openapi.yml OrdersRefundResponseStatus: @@ -23859,6 +24020,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml OrdersRefundResponseDisputeLastStatus: @@ -23874,6 +24036,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml OrdersRefundResponseCustomerPaid: @@ -23926,6 +24089,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersRefundResponseAllAddressesItemJapanType: @@ -23935,6 +24099,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersRefundResponseAllAddressesItem: @@ -23977,6 +24142,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersRefundResponseShippingAddressJapanType: @@ -23986,6 +24152,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersRefundResponseShippingAddress: @@ -24028,6 +24195,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml OrdersRefundResponseBillingAddressJapanType: @@ -24037,6 +24205,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml OrdersRefundResponseBillingAddress: @@ -24269,6 +24438,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml OrdersRefundResponseStripeCardExpires: @@ -24355,6 +24525,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml OrdersRefundResponseTotalsExtrasItemPrice: @@ -24583,6 +24754,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadDisputeLastStatus: @@ -24598,6 +24770,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadCustomerPaid: @@ -24650,6 +24823,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadAllAddressesItemJapanType: @@ -24659,6 +24833,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadAllAddressesItem: @@ -24701,6 +24876,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadShippingAddressJapanType: @@ -24710,6 +24886,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadShippingAddress: @@ -24752,6 +24929,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadBillingAddressJapanType: @@ -24761,6 +24939,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadBillingAddress: @@ -24993,6 +25172,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadStripeCardExpires: @@ -25079,6 +25259,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml EcommNewOrderPayloadTotalsExtrasItemPrice: @@ -25307,6 +25488,7 @@ Required scope | `ecommerce:write` - refunded docs: | The status of the Order + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadDisputeLastStatus: @@ -25322,6 +25504,7 @@ Required scope | `ecommerce:write` docs: > If an order was disputed by the customer, then this key will be set with the [dispute's status](https://stripe.com/docs/api#dispute_object-status). + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadCustomerPaid: @@ -25374,6 +25557,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadAllAddressesItemJapanType: @@ -25383,6 +25567,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadAllAddressesItem: @@ -25425,6 +25610,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadShippingAddressJapanType: @@ -25434,6 +25620,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadShippingAddress: @@ -25476,6 +25663,7 @@ Required scope | `ecommerce:write` - shipping - billing docs: The type of the order address (billing or shipping) + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadBillingAddressJapanType: @@ -25485,6 +25673,7 @@ Required scope | `ecommerce:write` docs: >- Represents a Japan-only address format. This field will only appear on orders placed from Japan. + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadBillingAddress: @@ -25717,6 +25906,7 @@ Required scope | `ecommerce:write` name: DinersClub - Unknown docs: The card's brand (ie. credit card network) + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadStripeCardExpires: @@ -25803,6 +25993,7 @@ Required scope | `ecommerce:write` - shipping - tax docs: The type of extra item this is. + inline: true source: openapi: ../openapi.yml EcommOrderChangedPayloadTotalsExtrasItemPrice: @@ -28533,6 +28724,7 @@ Required scope | `pages:write` "text", "image", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -29461,6 +29653,7 @@ Required scope | `pages:write` enum: - text - image + inline: true source: openapi: ../openapi.yml PagesGetContentResponseNodesItemText: @@ -30328,6 +30521,7 @@ webhooks: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30365,6 +30559,7 @@ webhooks: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30423,6 +30618,7 @@ webhooks: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -30438,6 +30634,7 @@ webhooks: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsGetCustomCodeResponseScriptsItem: @@ -30483,6 +30680,7 @@ webhooks: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsUpsertCustomCodeRequestScriptsItem: @@ -30515,6 +30713,7 @@ webhooks: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsUpsertCustomCodeResponseScriptsItem: @@ -31568,6 +31767,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31731,6 +31931,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31742,6 +31943,7 @@ Required scope | `ecommerce:write` "staging", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31845,6 +32047,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31879,6 +32082,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -31911,6 +32115,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32045,6 +32250,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32208,6 +32414,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32311,6 +32518,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32345,6 +32553,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32377,6 +32586,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32405,6 +32615,7 @@ Required scope | `ecommerce:write` "staging", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32508,6 +32719,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32542,6 +32754,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32574,6 +32787,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32704,6 +32918,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32738,6 +32953,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32770,6 +32986,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -32904,6 +33121,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33067,6 +33285,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33170,6 +33389,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33204,6 +33424,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33236,6 +33457,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33387,6 +33609,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33550,6 +33773,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33653,6 +33877,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33687,6 +33912,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33719,6 +33945,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -33857,6 +34084,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34020,6 +34248,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34031,6 +34260,7 @@ Required scope | `ecommerce:write` "staging", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34134,6 +34364,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34168,6 +34399,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34200,6 +34432,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34317,6 +34550,7 @@ Required scope | `ecommerce:write` "c599e43b1a1c34d5a323aedf75d3adf6", "b6ccc1830db4b1babeb06a9ac5f6dd76", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34480,6 +34714,7 @@ Required scope | `ecommerce:write` "value": "service-training", }, ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34491,6 +34726,7 @@ Required scope | `ecommerce:write` "staging", "live", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34594,6 +34830,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34628,6 +34865,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34660,6 +34898,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34780,6 +35019,7 @@ Required scope | `ecommerce:write` }, "subscription", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34814,6 +35054,7 @@ Required scope | `ecommerce:write` "month", "year", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34846,6 +35087,7 @@ Required scope | `ecommerce:write` "inactive", "canceled", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -34963,6 +35205,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsListResponseItemsItemProductFieldDataEcProductType: @@ -34976,6 +35219,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsListResponseItemsItemProductFieldData: @@ -35083,6 +35327,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsListResponseItemsItemSkusItemFieldDataEcSkuSubscriptionPlanInterval: @@ -35092,6 +35337,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsListResponseItemsItemSkusItemFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -35100,6 +35346,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsListResponseItemsItemSkusItemFieldDataEcSkuSubscriptionPlanPlansItem: @@ -35240,6 +35487,7 @@ Required scope | `ecommerce:write` - live docs: Indicate whether your Product should be set as "staging" or "live" default: staging + inline: true source: openapi: ../openapi.yml ProductsCreateRequestProductFieldDataSkuPropertiesItemEnumItem: @@ -35334,6 +35582,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsCreateRequestProductFieldDataEcProductType: @@ -35347,6 +35596,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsCreateRequestProductFieldData: @@ -35430,6 +35680,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsCreateRequestSkuFieldDataEcSkuSubscriptionPlanInterval: @@ -35439,6 +35690,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsCreateRequestSkuFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -35447,6 +35699,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsCreateRequestSkuFieldDataEcSkuSubscriptionPlanPlansItem: @@ -35631,6 +35884,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsCreateResponseProductFieldDataEcProductType: @@ -35644,6 +35898,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsCreateResponseProductFieldData: @@ -35751,6 +36006,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsCreateResponseSkusItemFieldDataEcSkuSubscriptionPlanInterval: @@ -35760,6 +36016,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsCreateResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -35768,6 +36025,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsCreateResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItem: @@ -35963,6 +36221,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsGetResponseProductFieldDataEcProductType: @@ -35976,6 +36235,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsGetResponseProductFieldData: @@ -36082,6 +36342,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsGetResponseSkusItemFieldDataEcSkuSubscriptionPlanInterval: @@ -36091,6 +36352,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsGetResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -36099,6 +36361,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsGetResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItem: @@ -36208,6 +36471,7 @@ Required scope | `ecommerce:write` - live docs: Indicate whether your Product should be set as "staging" or "live" default: staging + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestProductFieldDataSkuPropertiesItemEnumItem: @@ -36302,6 +36566,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestProductFieldDataEcProductType: @@ -36315,6 +36580,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestProductFieldData: @@ -36421,6 +36687,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestSkuFieldDataEcSkuSubscriptionPlanInterval: @@ -36430,6 +36697,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestSkuFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -36438,6 +36706,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsUpdateRequestSkuFieldDataEcSkuSubscriptionPlanPlansItem: @@ -36622,6 +36891,7 @@ Required scope | `ecommerce:write` - value: service-training name: ServiceTraining docs: Product tax class + inline: true source: openapi: ../openapi.yml ProductsUpdateResponseFieldDataEcProductType: @@ -36635,6 +36905,7 @@ Required scope | `ecommerce:write` href="https://university.webflow.com/lesson/add-and-manage-products-and-categories?topics=ecommerce#how-to-understand-product-types">Product types. Enums reflect the following values in order: Physical, Digital, Service, Advanced" + inline: true source: openapi: ../openapi.yml ProductsUpdateResponseFieldData: @@ -36717,6 +36988,7 @@ Required scope | `ecommerce:write` - live docs: Indicate whether your Product should be set as "staging" or "live" default: staging + inline: true source: openapi: ../openapi.yml ProductsCreateSkuRequestSkusItemFieldDataPrice: @@ -36748,6 +37020,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsCreateSkuRequestSkusItemFieldDataEcSkuSubscriptionPlanInterval: @@ -36757,6 +37030,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsCreateSkuRequestSkusItemFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -36765,6 +37039,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsCreateSkuRequestSkusItemFieldDataEcSkuSubscriptionPlanPlansItem: @@ -36886,6 +37161,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsCreateSkuResponseSkusItemFieldDataEcSkuSubscriptionPlanInterval: @@ -36895,6 +37171,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsCreateSkuResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -36903,6 +37180,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsCreateSkuResponseSkusItemFieldDataEcSkuSubscriptionPlanPlansItem: @@ -37007,6 +37285,7 @@ Required scope | `ecommerce:write` - live docs: Indicate whether your Product should be set as "staging" or "live" default: staging + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuRequestSkuFieldDataPrice: @@ -37038,6 +37317,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuRequestSkuFieldDataEcSkuSubscriptionPlanInterval: @@ -37047,6 +37327,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuRequestSkuFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -37055,6 +37336,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuRequestSkuFieldDataEcSkuSubscriptionPlanPlansItem: @@ -37176,6 +37458,7 @@ Required scope | `ecommerce:write` - value: one-time name: OneTime - subscription + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuResponseFieldDataEcSkuSubscriptionPlanInterval: @@ -37185,6 +37468,7 @@ Required scope | `ecommerce:write` - month - year docs: Interval of subscription renewal + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuResponseFieldDataEcSkuSubscriptionPlanPlansItemStatus: @@ -37193,6 +37477,7 @@ Required scope | `ecommerce:write` - inactive - canceled docs: The status of the plan + inline: true source: openapi: ../openapi.yml ProductsUpdateSkuResponseFieldDataEcSkuSubscriptionPlanPlansItem: @@ -40230,6 +40515,7 @@ webhooks: "UNPUBLISHED", "DELETED", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40276,6 +40562,7 @@ webhooks: - PUBLISHED - UNPUBLISHED - DELETED + inline: true source: openapi: ../openapi.yml ActivityLogsListResponseItemsItemUser: @@ -40742,6 +41029,7 @@ service: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40826,6 +41114,7 @@ service: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40836,6 +41125,7 @@ service: "page", "site", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40894,6 +41184,7 @@ service: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40952,6 +41243,7 @@ service: "header", "footer", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -40967,6 +41259,7 @@ service: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsGetCustomCodeResponseScriptsItem: @@ -41012,6 +41305,7 @@ service: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsUpsertCustomCodeRequestScriptsItem: @@ -41044,6 +41338,7 @@ service: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsUpsertCustomCodeResponseScriptsItem: @@ -41086,6 +41381,7 @@ service: - page - site docs: Whether the Custom Code script is applied at the Site-level or Page-level + inline: true source: openapi: ../openapi.yml ScriptsListCustomCodeBlocksResponseBlocksItemScriptsItemLocation: @@ -41096,6 +41392,7 @@ service: Location of the script, either in the header or footer of the published site default: header + inline: true source: openapi: ../openapi.yml ScriptsListCustomCodeBlocksResponseBlocksItemScriptsItem: @@ -42278,6 +42575,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42332,6 +42630,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42343,6 +42642,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "user_account_updated", "user_account_deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42440,6 +42740,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42494,6 +42795,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42505,6 +42807,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "user_account_updated", "user_account_deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42602,6 +42905,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42656,6 +42960,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42667,6 +42972,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "user_account_updated", "user_account_deleted", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42746,6 +43052,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42800,6 +43107,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42879,6 +43187,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42933,6 +43242,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -42990,6 +43300,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "value": "-UpdatedOn", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, @@ -43100,6 +43411,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43154,6 +43466,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43257,6 +43570,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "admin", "ecommerce", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43311,6 +43625,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) "verified", "unverified", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -43447,6 +43762,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UsersListResponseUsersItemAccessGroupsItemType: @@ -43457,6 +43773,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UsersListResponseUsersItemAccessGroupsItem: @@ -43570,6 +43887,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UsersGetResponseAccessGroupsItemType: @@ -43580,6 +43898,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UsersGetResponseAccessGroupsItem: @@ -43687,6 +44006,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UsersUpdateResponseAccessGroupsItemType: @@ -43697,6 +44017,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UsersUpdateResponseAccessGroupsItem: @@ -43787,6 +44108,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UsersInviteResponseAccessGroupsItemType: @@ -43797,6 +44119,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UsersInviteResponseAccessGroupsItem: @@ -43887,6 +44210,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - user_account_updated - user_account_deleted docs: The type of event that triggered the request + inline: true source: openapi: ../openapi.yml UserAccountAddedPayloadPayloadStatus: @@ -43895,6 +44219,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UserAccountAddedPayloadPayloadAccessGroupsItemType: @@ -43905,6 +44230,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UserAccountAddedPayloadPayloadAccessGroupsItem: @@ -44010,6 +44336,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - user_account_updated - user_account_deleted docs: The type of event that triggered the request + inline: true source: openapi: ../openapi.yml UserAccountUpdatedPayloadPayloadStatus: @@ -44018,6 +44345,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UserAccountUpdatedPayloadPayloadAccessGroupsItemType: @@ -44028,6 +44356,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UserAccountUpdatedPayloadPayloadAccessGroupsItem: @@ -44133,6 +44462,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - user_account_updated - user_account_deleted docs: The type of event that triggered the request + inline: true source: openapi: ../openapi.yml UserAccountDeletedPayloadPayloadStatus: @@ -44141,6 +44471,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) - verified - unverified docs: The status of the user + inline: true source: openapi: ../openapi.yml UserAccountDeletedPayloadPayloadAccessGroupsItemType: @@ -44151,6 +44482,7 @@ Can be prefixed with a `-` to reverse the sort (ex. `-CreatedOn`) The type of access group based on how it was assigned to the user. * `admin` - Assigned to the user via API or in the designer * `ecommerce` - Assigned to the user via an ecommerce purchase + inline: true source: openapi: ../openapi.yml UserAccountDeletedPayloadPayloadAccessGroupsItem: @@ -44944,6 +45276,7 @@ webhooks: "collection_item_deleted", "collection_item_unpublished", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45051,6 +45384,7 @@ webhooks: "collection_item_deleted", "collection_item_unpublished", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45158,6 +45492,7 @@ webhooks: "collection_item_deleted", "collection_item_unpublished", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45300,6 +45635,7 @@ webhooks: "collection_item_deleted", "collection_item_unpublished", ], + "inline": true, "source": { "openapi": "../openapi.yml", }, @@ -45380,6 +45716,7 @@ webhooks: * `collection_item_unpublished` - Sends the [collection_item_unpublished](#collection_item_unpublished) event + inline: true source: openapi: ../openapi.yml WebhooksListResponseWebhooksItemFilter: @@ -45531,6 +45868,7 @@ webhooks: * `collection_item_unpublished` - Sends the [collection_item_unpublished](#collection_item_unpublished) event + inline: true source: openapi: ../openapi.yml WebhooksCreateRequestFilter: @@ -45602,6 +45940,7 @@ webhooks: * `collection_item_unpublished` - Sends the [collection_item_unpublished](#collection_item_unpublished) event + inline: true source: openapi: ../openapi.yml WebhooksCreateResponseFilter: @@ -45744,6 +46083,7 @@ webhooks: * `collection_item_unpublished` - Sends the [collection_item_unpublished](#collection_item_unpublished) event + inline: true source: openapi: ../openapi.yml WebhooksGetResponseFilter: diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/x-fern-enum.json b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/x-fern-enum.json index b6cb815d795..dcd5420c5fe 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/x-fern-enum.json +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern-tests/src/__test__/__snapshots__/openapi/x-fern-enum.json @@ -21,6 +21,7 @@ "value": "nano", }, ], + "inline": undefined, "source": { "openapi": "../openapi.yml", }, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern/src/buildQueryParameter.ts b/packages/cli/api-importers/openapi/openapi-ir-to-fern/src/buildQueryParameter.ts index d0042f2966e..26eaf22881f 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern/src/buildQueryParameter.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern/src/buildQueryParameter.ts @@ -108,7 +108,8 @@ function getQueryParameterTypeReference({ value: resolvedSchema.value, description: schema.description ?? resolvedSchema.description, availability: schema.availability, - groupName: undefined + groupName: undefined, + inline: undefined }), context, declarationFile: RelativeFilePath.of(FERN_PACKAGE_MARKER_FILENAME), @@ -161,7 +162,8 @@ function getQueryParameterTypeReference({ value: secondSchema, description: schema.description, availability: schema.availability, - groupName: undefined + groupName: undefined, + inline: undefined }), context, fileContainingReference, @@ -185,7 +187,8 @@ function getQueryParameterTypeReference({ value: firstSchema, description: schema.description, availability: schema.availability, - groupName: undefined + groupName: undefined, + inline: undefined }), context, fileContainingReference, @@ -236,7 +239,8 @@ function getQueryParameterTypeReference({ value: resolvedSchema.value, description: schema.description ?? resolvedSchema.description, availability: schema.availability, - groupName: undefined + groupName: undefined, + inline: schema.inline }), context, fileContainingReference, @@ -270,7 +274,8 @@ function getQueryParameterTypeReference({ value: schema.value.value, description: schema.description, availability: schema.availability, - groupName: undefined + groupName: undefined, + inline: schema.inline }), context, fileContainingReference, @@ -322,7 +327,8 @@ function getQueryParameterTypeReference({ value: secondSchema, description: schema.description, availability: schema.availability, - groupName: undefined + groupName: undefined, + inline: schema.inline }), context, fileContainingReference, @@ -346,7 +352,8 @@ function getQueryParameterTypeReference({ value: firstSchema, description: schema.description, availability: schema.availability, - groupName: undefined + groupName: undefined, + inline: schema.inline }), context, fileContainingReference, @@ -368,7 +375,8 @@ function getQueryParameterTypeReference({ value: oneOfSchema, description: undefined, availability: schema.availability, - groupName: undefined + groupName: undefined, + inline: schema.inline }), context, fileContainingReference, @@ -413,7 +421,8 @@ function getQueryParameterTypeReference({ value: schema.value, description: schema.description, availability: schema.availability, - groupName: undefined + groupName: undefined, + inline: schema.inline }), context, fileContainingReference, diff --git a/packages/cli/api-importers/openapi/openapi-ir-to-fern/src/buildTypeDeclaration.ts b/packages/cli/api-importers/openapi/openapi-ir-to-fern/src/buildTypeDeclaration.ts index 9403bf2d56b..7643c919b10 100644 --- a/packages/cli/api-importers/openapi/openapi-ir-to-fern/src/buildTypeDeclaration.ts +++ b/packages/cli/api-importers/openapi/openapi-ir-to-fern/src/buildTypeDeclaration.ts @@ -13,7 +13,8 @@ import { PrimitiveSchema, ReferencedSchema, Schema, - SchemaId + SchemaId, + WithInline } from "@fern-api/openapi-ir"; import { RawSchemas } from "@fern-api/fern-definition-schema"; import { @@ -52,37 +53,73 @@ export function buildTypeDeclaration({ namespace: string | undefined; declarationDepth: number; }): ConvertedTypeDeclaration { + let typeDeclaration: ConvertedTypeDeclaration; switch (schema.type) { case "primitive": - return buildPrimitiveTypeDeclaration(schema); + typeDeclaration = buildPrimitiveTypeDeclaration(schema); + break; case "array": - return buildArrayTypeDeclaration({ schema, context, declarationFile, namespace, declarationDepth }); + typeDeclaration = buildArrayTypeDeclaration({ + schema, + context, + declarationFile, + namespace, + declarationDepth + }); + break; case "map": - return buildMapTypeDeclaration({ schema, context, declarationFile, namespace, declarationDepth }); + typeDeclaration = buildMapTypeDeclaration({ + schema, + context, + declarationFile, + namespace, + declarationDepth + }); + break; case "reference": - return buildReferenceTypeDeclaration({ schema, context, declarationFile, namespace }); + typeDeclaration = buildReferenceTypeDeclaration({ schema, context, declarationFile, namespace }); + break; case "unknown": - return buildUnknownTypeDeclaration(schema.nameOverride, schema.generatedName); + typeDeclaration = buildUnknownTypeDeclaration(schema.nameOverride, schema.generatedName); + break; case "optional": case "nullable": - return buildOptionalTypeDeclaration({ schema, context, declarationFile, namespace, declarationDepth }); + typeDeclaration = buildOptionalTypeDeclaration({ + schema, + context, + declarationFile, + namespace, + declarationDepth + }); + break; case "enum": - return buildEnumTypeDeclaration(schema, declarationDepth); + typeDeclaration = buildEnumTypeDeclaration(schema, declarationDepth); + break; case "literal": - return buildLiteralTypeDeclaration(schema, schema.nameOverride, schema.generatedName); + typeDeclaration = buildLiteralTypeDeclaration(schema, schema.nameOverride, schema.generatedName); + break; case "object": - return buildObjectTypeDeclaration({ schema, context, declarationFile, namespace, declarationDepth }); + typeDeclaration = buildObjectTypeDeclaration({ + schema, + context, + declarationFile, + namespace, + declarationDepth + }); + break; case "oneOf": - return buildOneOfTypeDeclaration({ + typeDeclaration = buildOneOfTypeDeclaration({ schema: schema.value, context, declarationFile, namespace, declarationDepth }); + break; default: assertNever(schema); } + return typeDeclaration; } export function buildObjectTypeDeclaration({ @@ -249,7 +286,7 @@ export function buildObjectTypeDeclaration({ objectTypeDeclaration.source = convertToSourceSchema(schema.source); } - objectTypeDeclaration.inline = getInline(declarationDepth); + objectTypeDeclaration.inline = getInline(schema, declarationDepth); const name = schema.nameOverride ?? schema.generatedName; return { @@ -442,6 +479,7 @@ export function buildEnumTypeDeclaration(schema: EnumSchema, declarationDepth: n if (schema.default != null) { enumSchema.default = schema.default.value; } + enumSchema.inline = getInline(schema, declarationDepth); const uniqueEnumName = new Set(); const uniqueEnumSchema: RawSchemas.EnumSchema = { ...enumSchema, @@ -455,7 +493,6 @@ export function buildEnumTypeDeclaration(schema: EnumSchema, declarationDepth: n uniqueEnumName.add(name.toLowerCase()); } // TODO: log a warning if the name is not unique } - enumSchema.inline = getInline(declarationDepth); return { name: schema.nameOverride ?? schema.generatedName, @@ -601,7 +638,7 @@ export function buildOneOfTypeDeclaration({ union, encoding, source: schema.source != null ? convertToSourceSchema(schema.source) : undefined, - inline: getInline(declarationDepth) + inline: getInline(schema, declarationDepth) } }; } @@ -659,6 +696,9 @@ function convertPropertyTypeReferenceToTypeDefinition({ * @param declarationDepth Keeps track of how nested the declaration is. * @returns `true` if the declaration should be inlined, `undefined` otherwise. */ -function getInline(declarationDepth: number): boolean | undefined { +function getInline(schema: WithInline, declarationDepth: number): boolean | undefined { + if (schema.inline === true) { + return true; + } return declarationDepth > 0 ? true : undefined; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/fern/definition/commons.yml b/packages/cli/api-importers/openapi/openapi-ir/fern/definition/commons.yml index a15a3064fdc..63fb2aea670 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/fern/definition/commons.yml +++ b/packages/cli/api-importers/openapi/openapi-ir/fern/definition/commons.yml @@ -35,6 +35,14 @@ types: [MyType -> propA -> propB] will turn into MyTypePropAPropB [MyType] will turn into MyType + WithInline: + properties: + inline: + docs: | + Whether a type should be inlined. If true, it should be inlined. + If false, it may still become inlined in a later stage. + type: optional + Source: union: openapi: OpenAPISource @@ -43,7 +51,7 @@ types: OpenAPISource: properties: file: string - + ProtobufSource: properties: file: string diff --git a/packages/cli/api-importers/openapi/openapi-ir/fern/definition/finalIr.yml b/packages/cli/api-importers/openapi/openapi-ir/fern/definition/finalIr.yml index ee66d73bdaf..2aed07940f3 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/fern/definition/finalIr.yml +++ b/packages/cli/api-importers/openapi/openapi-ir/fern/definition/finalIr.yml @@ -572,6 +572,7 @@ types: - commons.WithAvailability - commons.WithSource - commons.WithTitle + - commons.WithInline properties: allOf: list properties: list @@ -622,6 +623,7 @@ types: - commons.WithSdkGroupName - commons.WithAvailability - commons.WithTitle + - commons.WithInline properties: value: Schema @@ -633,6 +635,7 @@ types: - commons.WithAvailability - commons.WithEncoding - commons.WithTitle + - commons.WithInline properties: key: PrimitiveSchema value: Schema @@ -644,6 +647,7 @@ types: - commons.WithSdkGroupName - commons.WithAvailability - commons.WithTitle + - commons.WithInline properties: value: Schema @@ -654,6 +658,7 @@ types: - commons.WithSdkGroupName - commons.WithAvailability - commons.WithTitle + - commons.WithInline properties: value: Schema @@ -665,6 +670,7 @@ types: - commons.WithAvailability - commons.WithSource - commons.WithTitle + - commons.WithInline properties: default: optional values: list @@ -717,6 +723,7 @@ types: - commons.WithEncoding - commons.WithSource - commons.WithTitle + - commons.WithInline properties: discriminantProperty: string commonProperties: list @@ -736,5 +743,6 @@ types: - commons.WithEncoding - commons.WithSource - commons.WithTitle + - commons.WithInline properties: schemas: list diff --git a/packages/cli/api-importers/openapi/openapi-ir/fern/definition/parseIr.yml b/packages/cli/api-importers/openapi/openapi-ir/fern/definition/parseIr.yml index f5d974fc73a..09ec060d9c8 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/fern/definition/parseIr.yml +++ b/packages/cli/api-importers/openapi/openapi-ir/fern/definition/parseIr.yml @@ -189,6 +189,7 @@ types: - commons.WithDescription - commons.WithAvailability - commons.WithTitle + - commons.WithInline properties: value: SchemaWithExample example: optional> @@ -201,6 +202,7 @@ types: - commons.WithAvailability - commons.WithEncoding - commons.WithTitle + - commons.WithInline properties: key: PrimitiveSchemaWithExample value: SchemaWithExample @@ -213,6 +215,7 @@ types: - commons.WithDescription - commons.WithAvailability - commons.WithTitle + - commons.WithInline properties: value: SchemaWithExample @@ -223,6 +226,7 @@ types: - commons.WithDescription - commons.WithAvailability - commons.WithTitle + - commons.WithInline properties: value: SchemaWithExample @@ -234,6 +238,7 @@ types: - commons.WithAvailability - commons.WithSource - commons.WithTitle + - commons.WithInline properties: default: optional values: list @@ -257,6 +262,7 @@ types: - commons.WithAvailability - commons.WithSource - commons.WithTitle + - commons.WithInline properties: allOf: list properties: list @@ -298,6 +304,7 @@ types: - commons.WithEncoding - commons.WithSource - commons.WithTitle + - commons.WithInline properties: discriminantProperty: string commonProperties: list @@ -317,6 +324,7 @@ types: - commons.WithEncoding - commons.WithSource - commons.WithTitle + - commons.WithInline properties: schemas: list diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/commons/types/WithInline.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/commons/types/WithInline.ts new file mode 100644 index 00000000000..a8471d506a6 --- /dev/null +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/commons/types/WithInline.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface WithInline { + /** + * Whether a type should be inlined. If true, it should be inlined. + * If false, it may still become inlined in a later stage. + */ + inline: boolean | undefined; +} diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/commons/types/index.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/commons/types/index.ts index 82808c1b649..1eb29983878 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/commons/types/index.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/commons/types/index.ts @@ -4,6 +4,7 @@ export * from "./WithEncoding"; export * from "./WithDescription"; export * from "./WithAvailability"; export * from "./WithName"; +export * from "./WithInline"; export * from "./Source"; export * from "./OpenApiSource"; export * from "./ProtobufSource"; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/ArraySchema.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/ArraySchema.ts index 133d405d0d1..222d26ea51c 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/ArraySchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/ArraySchema.ts @@ -9,6 +9,7 @@ export interface ArraySchema FernOpenapiIr.WithName, FernOpenapiIr.WithSdkGroupName, FernOpenapiIr.WithAvailability, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { value: FernOpenapiIr.Schema; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/DiscriminatedOneOfSchema.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/DiscriminatedOneOfSchema.ts index b6a2e54b6ae..dc3db92e9a5 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/DiscriminatedOneOfSchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/DiscriminatedOneOfSchema.ts @@ -11,7 +11,8 @@ export interface DiscriminatedOneOfSchema FernOpenapiIr.WithAvailability, FernOpenapiIr.WithEncoding, FernOpenapiIr.WithSource, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { discriminantProperty: string; commonProperties: FernOpenapiIr.CommonProperty[]; schemas: Record; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/EnumSchema.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/EnumSchema.ts index a57870fca1c..b84d06717c6 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/EnumSchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/EnumSchema.ts @@ -10,7 +10,8 @@ export interface EnumSchema FernOpenapiIr.WithSdkGroupName, FernOpenapiIr.WithAvailability, FernOpenapiIr.WithSource, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { default: FernOpenapiIr.EnumValue | undefined; values: FernOpenapiIr.EnumValue[]; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/MapSchema.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/MapSchema.ts index 595e204e94a..a6ec11473d2 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/MapSchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/MapSchema.ts @@ -10,7 +10,8 @@ export interface MapSchema FernOpenapiIr.WithSdkGroupName, FernOpenapiIr.WithAvailability, FernOpenapiIr.WithEncoding, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { key: FernOpenapiIr.PrimitiveSchema; value: FernOpenapiIr.Schema; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/NullableSchema.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/NullableSchema.ts index 00464dce653..3c0ad122ca5 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/NullableSchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/NullableSchema.ts @@ -9,6 +9,7 @@ export interface NullableSchema FernOpenapiIr.WithName, FernOpenapiIr.WithSdkGroupName, FernOpenapiIr.WithAvailability, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { value: FernOpenapiIr.Schema; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/ObjectSchema.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/ObjectSchema.ts index aa29bffc44b..39090356ba3 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/ObjectSchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/ObjectSchema.ts @@ -10,7 +10,8 @@ export interface ObjectSchema FernOpenapiIr.WithSdkGroupName, FernOpenapiIr.WithAvailability, FernOpenapiIr.WithSource, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { allOf: FernOpenapiIr.ReferencedSchema[]; properties: FernOpenapiIr.ObjectProperty[]; allOfPropertyConflicts: FernOpenapiIr.AllOfPropertyConflict[]; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/OptionalSchema.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/OptionalSchema.ts index eac5cf61807..7f13af6a5cf 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/OptionalSchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/OptionalSchema.ts @@ -9,6 +9,7 @@ export interface OptionalSchema FernOpenapiIr.WithName, FernOpenapiIr.WithSdkGroupName, FernOpenapiIr.WithAvailability, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { value: FernOpenapiIr.Schema; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/UnDiscriminatedOneOfSchema.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/UnDiscriminatedOneOfSchema.ts index 43a77daba6c..dd277986008 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/UnDiscriminatedOneOfSchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/finalIr/types/UnDiscriminatedOneOfSchema.ts @@ -11,6 +11,7 @@ export interface UnDiscriminatedOneOfSchema FernOpenapiIr.WithAvailability, FernOpenapiIr.WithEncoding, FernOpenapiIr.WithSource, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { schemas: FernOpenapiIr.Schema[]; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/ArraySchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/ArraySchemaWithExample.ts index 78eadb1038d..9d13ce0ffba 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/ArraySchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/ArraySchemaWithExample.ts @@ -9,7 +9,8 @@ export interface ArraySchemaWithExample FernOpenapiIr.WithName, FernOpenapiIr.WithDescription, FernOpenapiIr.WithAvailability, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { value: FernOpenapiIr.SchemaWithExample; example: unknown[] | undefined; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/DiscriminatedOneOfSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/DiscriminatedOneOfSchemaWithExample.ts index cf18f13a54e..ebc2ed604e4 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/DiscriminatedOneOfSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/DiscriminatedOneOfSchemaWithExample.ts @@ -11,7 +11,8 @@ export interface DiscriminatedOneOfSchemaWithExample FernOpenapiIr.WithAvailability, FernOpenapiIr.WithEncoding, FernOpenapiIr.WithSource, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { discriminantProperty: string; commonProperties: FernOpenapiIr.CommonPropertyWithExample[]; schemas: Record; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/EnumSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/EnumSchemaWithExample.ts index 70621d0a72f..0a0fbcb8c5c 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/EnumSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/EnumSchemaWithExample.ts @@ -10,7 +10,8 @@ export interface EnumSchemaWithExample FernOpenapiIr.WithSdkGroupName, FernOpenapiIr.WithAvailability, FernOpenapiIr.WithSource, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { default: FernOpenapiIr.EnumValue | undefined; values: FernOpenapiIr.EnumValue[]; example: string | undefined; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/MapSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/MapSchemaWithExample.ts index f749e41e975..43146dc3ed9 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/MapSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/MapSchemaWithExample.ts @@ -10,7 +10,8 @@ export interface MapSchemaWithExample FernOpenapiIr.WithDescription, FernOpenapiIr.WithAvailability, FernOpenapiIr.WithEncoding, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { key: FernOpenapiIr.PrimitiveSchemaWithExample; value: FernOpenapiIr.SchemaWithExample; example: unknown | undefined; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/NullableSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/NullableSchemaWithExample.ts index 689eae93af8..0f34bdda5fd 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/NullableSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/NullableSchemaWithExample.ts @@ -9,6 +9,7 @@ export interface NullableSchemaWithExample FernOpenapiIr.WithName, FernOpenapiIr.WithDescription, FernOpenapiIr.WithAvailability, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { value: FernOpenapiIr.SchemaWithExample; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/ObjectSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/ObjectSchemaWithExample.ts index 465c42ee616..2f2e3c0a5af 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/ObjectSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/ObjectSchemaWithExample.ts @@ -10,7 +10,8 @@ export interface ObjectSchemaWithExample FernOpenapiIr.WithSdkGroupName, FernOpenapiIr.WithAvailability, FernOpenapiIr.WithSource, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { allOf: FernOpenapiIr.ReferencedSchema[]; properties: FernOpenapiIr.ObjectPropertyWithExample[]; allOfPropertyConflicts: FernOpenapiIr.AllOfPropertyConflict[]; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/OptionalSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/OptionalSchemaWithExample.ts index 5e41d462529..e8574df954f 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/OptionalSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/OptionalSchemaWithExample.ts @@ -9,6 +9,7 @@ export interface OptionalSchemaWithExample FernOpenapiIr.WithName, FernOpenapiIr.WithDescription, FernOpenapiIr.WithAvailability, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { value: FernOpenapiIr.SchemaWithExample; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/UnDiscriminatedOneOfSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/UnDiscriminatedOneOfSchemaWithExample.ts index 734e15a24f6..f206bea92b7 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/UnDiscriminatedOneOfSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/api/resources/parseIr/types/UnDiscriminatedOneOfSchemaWithExample.ts @@ -11,6 +11,7 @@ export interface UnDiscriminatedOneOfSchemaWithExample FernOpenapiIr.WithAvailability, FernOpenapiIr.WithEncoding, FernOpenapiIr.WithSource, - FernOpenapiIr.WithTitle { + FernOpenapiIr.WithTitle, + FernOpenapiIr.WithInline { schemas: FernOpenapiIr.SchemaWithExample[]; } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/commons/types/WithInline.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/commons/types/WithInline.ts new file mode 100644 index 00000000000..c435488139d --- /dev/null +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/commons/types/WithInline.ts @@ -0,0 +1,18 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../../index"; +import * as FernOpenapiIr from "../../../../api/index"; +import * as core from "../../../../core"; + +export const WithInline: core.serialization.ObjectSchema = + core.serialization.objectWithoutOptionalProperties({ + inline: core.serialization.boolean().optional(), + }); + +export declare namespace WithInline { + interface Raw { + inline?: boolean | null; + } +} diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/commons/types/index.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/commons/types/index.ts index 82808c1b649..1eb29983878 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/commons/types/index.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/commons/types/index.ts @@ -4,6 +4,7 @@ export * from "./WithEncoding"; export * from "./WithDescription"; export * from "./WithAvailability"; export * from "./WithName"; +export * from "./WithInline"; export * from "./Source"; export * from "./OpenApiSource"; export * from "./ProtobufSource"; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/finalIr/types/ArraySchema.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/finalIr/types/ArraySchema.ts index 0d53d50d031..b06d2c178ed 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/finalIr/types/ArraySchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/finalIr/types/ArraySchema.ts @@ -10,6 +10,7 @@ import { WithName } from "../../commons/types/WithName"; import { WithSdkGroupName } from "../../commons/types/WithSdkGroupName"; import { WithAvailability } from "../../commons/types/WithAvailability"; import { WithTitle } from "../../commons/types/WithTitle"; +import { WithInline } from "../../commons/types/WithInline"; export const ArraySchema: core.serialization.ObjectSchema = core.serialization @@ -20,10 +21,17 @@ export const ArraySchema: core.serialization.ObjectSchema; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/finalIr/types/EnumSchema.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/finalIr/types/EnumSchema.ts index efdf0107738..7a44bfc0eb4 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/finalIr/types/EnumSchema.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/finalIr/types/EnumSchema.ts @@ -12,6 +12,7 @@ import { WithSdkGroupName } from "../../commons/types/WithSdkGroupName"; import { WithAvailability } from "../../commons/types/WithAvailability"; import { WithSource } from "../../commons/types/WithSource"; import { WithTitle } from "../../commons/types/WithTitle"; +import { WithInline } from "../../commons/types/WithInline"; export const EnumSchema: core.serialization.ObjectSchema = core.serialization @@ -24,7 +25,8 @@ export const EnumSchema: core.serialization.ObjectSchema = core.serialization @@ -24,7 +25,8 @@ export const MapSchema: core.serialization.ObjectSchema = core.serialization @@ -27,7 +28,8 @@ export const ObjectSchema: core.serialization.ObjectSchema; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/EnumSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/EnumSchemaWithExample.ts index d76495b66da..112253b0f31 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/EnumSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/EnumSchemaWithExample.ts @@ -12,6 +12,7 @@ import { WithSdkGroupName } from "../../commons/types/WithSdkGroupName"; import { WithAvailability } from "../../commons/types/WithAvailability"; import { WithSource } from "../../commons/types/WithSource"; import { WithTitle } from "../../commons/types/WithTitle"; +import { WithInline } from "../../commons/types/WithInline"; export const EnumSchemaWithExample: core.serialization.ObjectSchema< serializers.EnumSchemaWithExample.Raw, @@ -27,7 +28,8 @@ export const EnumSchemaWithExample: core.serialization.ObjectSchema< .extend(WithSdkGroupName) .extend(WithAvailability) .extend(WithSource) - .extend(WithTitle); + .extend(WithTitle) + .extend(WithInline); export declare namespace EnumSchemaWithExample { interface Raw @@ -36,7 +38,8 @@ export declare namespace EnumSchemaWithExample { WithSdkGroupName.Raw, WithAvailability.Raw, WithSource.Raw, - WithTitle.Raw { + WithTitle.Raw, + WithInline.Raw { default?: EnumValue.Raw | null; values: EnumValue.Raw[]; example?: string | null; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/MapSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/MapSchemaWithExample.ts index 88cdb3bc712..a0850a26ca7 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/MapSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/MapSchemaWithExample.ts @@ -12,6 +12,7 @@ import { WithDescription } from "../../commons/types/WithDescription"; import { WithAvailability } from "../../commons/types/WithAvailability"; import { WithEncoding } from "../../commons/types/WithEncoding"; import { WithTitle } from "../../commons/types/WithTitle"; +import { WithInline } from "../../commons/types/WithInline"; export const MapSchemaWithExample: core.serialization.ObjectSchema< serializers.MapSchemaWithExample.Raw, @@ -27,7 +28,8 @@ export const MapSchemaWithExample: core.serialization.ObjectSchema< .extend(WithDescription) .extend(WithAvailability) .extend(WithEncoding) - .extend(WithTitle); + .extend(WithTitle) + .extend(WithInline); export declare namespace MapSchemaWithExample { interface Raw @@ -36,7 +38,8 @@ export declare namespace MapSchemaWithExample { WithDescription.Raw, WithAvailability.Raw, WithEncoding.Raw, - WithTitle.Raw { + WithTitle.Raw, + WithInline.Raw { key: PrimitiveSchemaWithExample.Raw; value: serializers.SchemaWithExample.Raw; example?: unknown | null; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/NullableSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/NullableSchemaWithExample.ts index 9e1a5565687..203e26a8fc3 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/NullableSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/NullableSchemaWithExample.ts @@ -10,6 +10,7 @@ import { WithName } from "../../commons/types/WithName"; import { WithDescription } from "../../commons/types/WithDescription"; import { WithAvailability } from "../../commons/types/WithAvailability"; import { WithTitle } from "../../commons/types/WithTitle"; +import { WithInline } from "../../commons/types/WithInline"; export const NullableSchemaWithExample: core.serialization.ObjectSchema< serializers.NullableSchemaWithExample.Raw, @@ -22,10 +23,17 @@ export const NullableSchemaWithExample: core.serialization.ObjectSchema< .extend(WithName) .extend(WithDescription) .extend(WithAvailability) - .extend(WithTitle); + .extend(WithTitle) + .extend(WithInline); export declare namespace NullableSchemaWithExample { - interface Raw extends WithSdkGroupName.Raw, WithName.Raw, WithDescription.Raw, WithAvailability.Raw, WithTitle.Raw { + interface Raw + extends WithSdkGroupName.Raw, + WithName.Raw, + WithDescription.Raw, + WithAvailability.Raw, + WithTitle.Raw, + WithInline.Raw { value: serializers.SchemaWithExample.Raw; } } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/ObjectSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/ObjectSchemaWithExample.ts index cd9bcf4af59..47e441c623a 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/ObjectSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/ObjectSchemaWithExample.ts @@ -14,6 +14,7 @@ import { WithSdkGroupName } from "../../commons/types/WithSdkGroupName"; import { WithAvailability } from "../../commons/types/WithAvailability"; import { WithSource } from "../../commons/types/WithSource"; import { WithTitle } from "../../commons/types/WithTitle"; +import { WithInline } from "../../commons/types/WithInline"; export const ObjectSchemaWithExample: core.serialization.ObjectSchema< serializers.ObjectSchemaWithExample.Raw, @@ -31,7 +32,8 @@ export const ObjectSchemaWithExample: core.serialization.ObjectSchema< .extend(WithSdkGroupName) .extend(WithAvailability) .extend(WithSource) - .extend(WithTitle); + .extend(WithTitle) + .extend(WithInline); export declare namespace ObjectSchemaWithExample { interface Raw @@ -40,7 +42,8 @@ export declare namespace ObjectSchemaWithExample { WithSdkGroupName.Raw, WithAvailability.Raw, WithSource.Raw, - WithTitle.Raw { + WithTitle.Raw, + WithInline.Raw { allOf: ReferencedSchema.Raw[]; properties: serializers.ObjectPropertyWithExample.Raw[]; allOfPropertyConflicts: AllOfPropertyConflict.Raw[]; diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/OptionalSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/OptionalSchemaWithExample.ts index cc6395fff41..b97404c2db8 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/OptionalSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/OptionalSchemaWithExample.ts @@ -10,6 +10,7 @@ import { WithName } from "../../commons/types/WithName"; import { WithDescription } from "../../commons/types/WithDescription"; import { WithAvailability } from "../../commons/types/WithAvailability"; import { WithTitle } from "../../commons/types/WithTitle"; +import { WithInline } from "../../commons/types/WithInline"; export const OptionalSchemaWithExample: core.serialization.ObjectSchema< serializers.OptionalSchemaWithExample.Raw, @@ -22,10 +23,17 @@ export const OptionalSchemaWithExample: core.serialization.ObjectSchema< .extend(WithName) .extend(WithDescription) .extend(WithAvailability) - .extend(WithTitle); + .extend(WithTitle) + .extend(WithInline); export declare namespace OptionalSchemaWithExample { - interface Raw extends WithSdkGroupName.Raw, WithName.Raw, WithDescription.Raw, WithAvailability.Raw, WithTitle.Raw { + interface Raw + extends WithSdkGroupName.Raw, + WithName.Raw, + WithDescription.Raw, + WithAvailability.Raw, + WithTitle.Raw, + WithInline.Raw { value: serializers.SchemaWithExample.Raw; } } diff --git a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/UnDiscriminatedOneOfSchemaWithExample.ts b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/UnDiscriminatedOneOfSchemaWithExample.ts index d1869b759c2..65cf5bd1f9a 100644 --- a/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/UnDiscriminatedOneOfSchemaWithExample.ts +++ b/packages/cli/api-importers/openapi/openapi-ir/src/sdk/serialization/resources/parseIr/types/UnDiscriminatedOneOfSchemaWithExample.ts @@ -12,6 +12,7 @@ import { WithAvailability } from "../../commons/types/WithAvailability"; import { WithEncoding } from "../../commons/types/WithEncoding"; import { WithSource } from "../../commons/types/WithSource"; import { WithTitle } from "../../commons/types/WithTitle"; +import { WithInline } from "../../commons/types/WithInline"; export const UnDiscriminatedOneOfSchemaWithExample: core.serialization.ObjectSchema< serializers.UnDiscriminatedOneOfSchemaWithExample.Raw, @@ -26,7 +27,8 @@ export const UnDiscriminatedOneOfSchemaWithExample: core.serialization.ObjectSch .extend(WithAvailability) .extend(WithEncoding) .extend(WithSource) - .extend(WithTitle); + .extend(WithTitle) + .extend(WithInline); export declare namespace UnDiscriminatedOneOfSchemaWithExample { interface Raw @@ -36,7 +38,8 @@ export declare namespace UnDiscriminatedOneOfSchemaWithExample { WithAvailability.Raw, WithEncoding.Raw, WithSource.Raw, - WithTitle.Raw { + WithTitle.Raw, + WithInline.Raw { schemas: serializers.SchemaWithExample.Raw[]; } } diff --git a/packages/cli/cli/versions.yml b/packages/cli/cli/versions.yml index c364ba3aa86..d8193bd1d94 100644 --- a/packages/cli/cli/versions.yml +++ b/packages/cli/cli/versions.yml @@ -1,3 +1,11 @@ +- changelogEntry: + - summary: | + * Set `inline: true` for inline enums imported from OpenAPI. + * Set `inline: true` for maps generated from OpenAPI additionalProperties. + type: fix + irVersion: 53 + version: 0.46.0-rc1 + - changelogEntry: - summary: | The Fern Definition now supports `bytes` as a response type. @@ -17,10 +25,10 @@ type: fix irVersion: 53 version: 0.45.4 - + - changelogEntry: - summary: | - Bumped Java IR to latest (v53) + Unknown schemas are no longer incorrectly marked as `additionalProperties: true`. type: chore irVersion: 53 version: 0.45.4-rc1 @@ -34,7 +42,7 @@ - changelogEntry: - summary: | - Unknown schemas are no longer incorrectly marked as `additionalProperties: true`. + Unknown schemas are no longer incorrectly marked as `additionalProperties: true`. type: fix irVersion: 53 version: 0.45.3 @@ -68,7 +76,6 @@ irVersion: 53 version: 0.45.0 - - changelogEntry: - summary: | Docs generation now preserves original model schema names. diff --git a/packages/cli/ete-tests/src/tests/write-definition/__snapshots__/writeDefinition.test.ts.snap b/packages/cli/ete-tests/src/tests/write-definition/__snapshots__/writeDefinition.test.ts.snap index ed3178559c8..de34cee5810 100644 --- a/packages/cli/ete-tests/src/tests/write-definition/__snapshots__/writeDefinition.test.ts.snap +++ b/packages/cli/ete-tests/src/tests/write-definition/__snapshots__/writeDefinition.test.ts.snap @@ -415,12 +415,14 @@ service: - trade - cancel - initial + inline: true source: openapi: asyncapi/sample.yml EventsItemSide: enum: - bid - side + inline: true source: openapi: asyncapi/sample.yml EventsItemType: @@ -429,6 +431,7 @@ service: - change - name: AuctionBlockTrade value: auction, block_trade + inline: true source: openapi: asyncapi/sample.yml Heartbeat: @@ -583,6 +586,7 @@ channel: - nok - sek - try + inline: true source: openapi: openapi/trains/openapi.yml BookingPaymentSource: @@ -640,6 +644,7 @@ channel: enum: - individual - company + inline: true source: openapi: openapi/trains/openapi.yml BookingPaymentStatus: @@ -648,6 +653,7 @@ channel: - pending - succeeded - failed + inline: true source: openapi: openapi/trains/openapi.yml Card: @@ -1572,6 +1578,7 @@ name: api - 'OFF' - AUTO - AUTO_PRESERVE_ORDER + inline: true source: openapi: openapi/cohere.yaml ChatRequestSafetyMode: @@ -1597,6 +1604,7 @@ name: api - CONTEXTUAL - STRICT - NONE + inline: true source: openapi: openapi/cohere.yaml ClientClosedRequestErrorBody: @@ -2190,6 +2198,7 @@ types: - CONTEXTUAL - STRICT - NONE + inline: true source: openapi: openapi/cohere-v2.yaml service: diff --git a/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced-fleshedout/fern/.definition/v1/__package__.yml b/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced-fleshedout/fern/.definition/v1/__package__.yml index 84b8e967746..f0d3192247d 100644 --- a/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced-fleshedout/fern/.definition/v1/__package__.yml +++ b/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced-fleshedout/fern/.definition/v1/__package__.yml @@ -39,6 +39,7 @@ types: - 'OFF' - AUTO - AUTO_PRESERVE_ORDER + inline: true source: openapi: openapi/cohere.yaml ChatRequestSafetyMode: @@ -64,6 +65,7 @@ types: - CONTEXTUAL - STRICT - NONE + inline: true source: openapi: openapi/cohere.yaml ClientClosedRequestErrorBody: diff --git a/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced-fleshedout/fern/.definition/v2/v2.yml b/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced-fleshedout/fern/.definition/v2/v2.yml index 069a05c81b8..2c4889d1c0d 100644 --- a/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced-fleshedout/fern/.definition/v2/v2.yml +++ b/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced-fleshedout/fern/.definition/v2/v2.yml @@ -24,6 +24,7 @@ types: - CONTEXTUAL - STRICT - NONE + inline: true source: openapi: openapi/cohere-v2.yaml service: diff --git a/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced/fern/.definition/stream/__package__.yml b/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced/fern/.definition/stream/__package__.yml index 561105e7a85..b088d509de7 100644 --- a/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced/fern/.definition/stream/__package__.yml +++ b/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced/fern/.definition/stream/__package__.yml @@ -57,12 +57,14 @@ types: - trade - cancel - initial + inline: true source: openapi: asyncapi/sample.yml EventsItemSide: enum: - bid - side + inline: true source: openapi: asyncapi/sample.yml EventsItemType: @@ -71,6 +73,7 @@ types: - change - name: AuctionBlockTrade value: auction, block_trade + inline: true source: openapi: asyncapi/sample.yml Heartbeat: diff --git a/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced/fern/.definition/trains/__package__.yml b/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced/fern/.definition/trains/__package__.yml index 12ae3bf8277..3d0a768745d 100644 --- a/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced/fern/.definition/trains/__package__.yml +++ b/packages/cli/ete-tests/src/tests/write-definition/fixtures/namespaced/fern/.definition/trains/__package__.yml @@ -66,6 +66,7 @@ types: - nok - sek - try + inline: true source: openapi: openapi/trains/openapi.yml BookingPaymentSource: @@ -123,6 +124,7 @@ types: enum: - individual - company + inline: true source: openapi: openapi/trains/openapi.yml BookingPaymentStatus: @@ -131,6 +133,7 @@ types: - pending - succeeded - failed + inline: true source: openapi: openapi/trains/openapi.yml Card: diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasInlineValue.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasInlineValue.json new file mode 100644 index 00000000000..a86a97251cf --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasInlineValue.json @@ -0,0 +1,17 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "type": "string" + } + }, + "required": [ + "foo", + "bar" + ], + "additionalProperties": false, + "definitions": {} +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasListInline.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasListInline.json new file mode 100644 index 00000000000..e31e4a64b87 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasListInline.json @@ -0,0 +1,24 @@ +{ + "type": "array", + "items": { + "$ref": "#/definitions/AliasInlineValue" + }, + "definitions": { + "AliasInlineValue": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "type": "string" + } + }, + "required": [ + "foo", + "bar" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasMapInline.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasMapInline.json new file mode 100644 index 00000000000..488b51ce648 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasMapInline.json @@ -0,0 +1,24 @@ +{ + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/AliasInlineValue" + }, + "definitions": { + "AliasInlineValue": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "type": "string" + } + }, + "required": [ + "foo", + "bar" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasOptionalInline.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasOptionalInline.json new file mode 100644 index 00000000000..2be7e4cf223 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasOptionalInline.json @@ -0,0 +1,28 @@ +{ + "oneOf": [ + { + "$ref": "#/definitions/AliasInlineValue" + }, + { + "type": "null" + } + ], + "definitions": { + "AliasInlineValue": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "type": "string" + } + }, + "required": [ + "foo", + "bar" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasSetInline.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasSetInline.json new file mode 100644 index 00000000000..727f11a0ec3 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__AliasSetInline.json @@ -0,0 +1,25 @@ +{ + "type": "array", + "items": { + "$ref": "#/definitions/AliasInlineValue" + }, + "uniqueItems": true, + "definitions": { + "AliasInlineValue": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "type": "string" + } + }, + "required": [ + "foo", + "bar" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1.json index 56723478151..94f4a226346 100644 --- a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1.json +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1.json @@ -5,7 +5,8 @@ "type": "string", "enum": [ "type1", - "type2" + "type2", + "ref" ] } }, @@ -22,13 +23,17 @@ "type": "string" }, "bar": { - "$ref": "#/definitions/NestedInlineType1" + "$ref": "#/definitions/DiscriminatedUnion1InlineType1InlineType1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" } }, "required": [ "type", "foo", - "bar" + "bar", + "ref" ] }, { @@ -36,34 +41,60 @@ "type": { "const": "type2" }, - "foo": { + "baz": { "type": "string" }, - "bar": { + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "type", + "baz", + "ref" + ] + }, + { + "properties": { + "type": { + "const": "ref" + }, + "foo": { "type": "string" } }, "required": [ "type", - "foo", - "bar" + "foo" ] } ], "definitions": { - "NestedInlineType1": { + "ReferenceType": { "type": "object", "properties": { "foo": { "type": "string" - }, - "bar": { + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + }, + "DiscriminatedUnion1InlineType1InlineType1": { + "type": "object", + "properties": { + "foo": { "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" } }, "required": [ "foo", - "bar" + "ref" ], "additionalProperties": false } diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1InlineType1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1InlineType1.json new file mode 100644 index 00000000000..da941d968ac --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1InlineType1.json @@ -0,0 +1,50 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "$ref": "#/definitions/DiscriminatedUnion1InlineType1InlineType1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "bar", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + }, + "DiscriminatedUnion1InlineType1InlineType1": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1InlineType1InlineType1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1InlineType1InlineType1.json new file mode 100644 index 00000000000..d43b6cb8bc4 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1InlineType1InlineType1.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1InlineType2.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1InlineType2.json new file mode 100644 index 00000000000..86f3f399eb1 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__DiscriminatedUnion1InlineType2.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "baz": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "baz", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__InlineEnum1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__InlineEnum1.json new file mode 100644 index 00000000000..247b41d0eb2 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__InlineEnum1.json @@ -0,0 +1,10 @@ +{ + "type": "string", + "enum": [ + "SUNNY", + "CLOUDY", + "RAINING", + "SNOWING" + ], + "definitions": {} +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__ReferenceType.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__ReferenceType.json new file mode 100644 index 00000000000..080dd1a61ae --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__ReferenceType.json @@ -0,0 +1,13 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false, + "definitions": {} +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RequestTypeInlineType1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RequestTypeInlineType1.json new file mode 100644 index 00000000000..080dd1a61ae --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RequestTypeInlineType1.json @@ -0,0 +1,13 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false, + "definitions": {} +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1.json index 2e21be35674..eb0a382274c 100644 --- a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1.json +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1.json @@ -5,16 +5,42 @@ "type": "string" }, "bar": { - "$ref": "#/definitions/InlineType1" + "$ref": "#/definitions/RootType1InlineType1" + }, + "fooMap": { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/RootType1FooMapValue" + } + }, + "fooList": { + "type": "array", + "items": { + "$ref": "#/definitions/RootType1FooListItem" + } + }, + "fooSet": { + "type": "array", + "items": { + "$ref": "#/definitions/RootType1FooSetItem" + }, + "uniqueItems": true + }, + "ref": { + "$ref": "#/definitions/ReferenceType" } }, "required": [ "foo", - "bar" + "bar", + "fooMap", + "fooList", + "fooSet", + "ref" ], "additionalProperties": false, "definitions": { - "InlineEnum": { + "InlineEnum1": { "type": "string", "enum": [ "SUNNY", @@ -23,7 +49,19 @@ "SNOWING" ] }, - "NestedInlineType1": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + }, + "RootType1InlineType1NestedInlineType1": { "type": "object", "properties": { "foo": { @@ -33,29 +71,85 @@ "type": "string" }, "myEnum": { - "$ref": "#/definitions/InlineEnum" + "$ref": "#/definitions/InlineEnum1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" } }, "required": [ "foo", "bar", - "myEnum" + "myEnum", + "ref" ], "additionalProperties": false }, - "InlineType1": { + "RootType1InlineType1": { "type": "object", "properties": { "foo": { "type": "string" }, "bar": { - "$ref": "#/definitions/NestedInlineType1" + "$ref": "#/definitions/RootType1InlineType1NestedInlineType1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "bar", + "ref" + ], + "additionalProperties": false + }, + "RootType1FooMapValue": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false + }, + "RootType1FooListItem": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false + }, + "RootType1FooSetItem": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" } }, "required": [ "foo", - "bar" + "ref" ], "additionalProperties": false } diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1FooListItem.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1FooListItem.json new file mode 100644 index 00000000000..d43b6cb8bc4 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1FooListItem.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1FooMapValue.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1FooMapValue.json new file mode 100644 index 00000000000..d43b6cb8bc4 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1FooMapValue.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1FooSetItem.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1FooSetItem.json new file mode 100644 index 00000000000..d43b6cb8bc4 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1FooSetItem.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1InlineType1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1InlineType1.json new file mode 100644 index 00000000000..d39cce62366 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1InlineType1.json @@ -0,0 +1,67 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "$ref": "#/definitions/RootType1InlineType1NestedInlineType1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "bar", + "ref" + ], + "additionalProperties": false, + "definitions": { + "InlineEnum1": { + "type": "string", + "enum": [ + "SUNNY", + "CLOUDY", + "RAINING", + "SNOWING" + ] + }, + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + }, + "RootType1InlineType1NestedInlineType1": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "type": "string" + }, + "myEnum": { + "$ref": "#/definitions/InlineEnum1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "bar", + "myEnum", + "ref" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1InlineType1NestedInlineType1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1InlineType1NestedInlineType1.json new file mode 100644 index 00000000000..4c714bfff7f --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__RootType1InlineType1NestedInlineType1.json @@ -0,0 +1,47 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "type": "string" + }, + "myEnum": { + "$ref": "#/definitions/InlineEnum1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "bar", + "myEnum", + "ref" + ], + "additionalProperties": false, + "definitions": { + "InlineEnum1": { + "type": "string", + "enum": [ + "SUNNY", + "CLOUDY", + "RAINING", + "SNOWING" + ] + }, + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1.json index eb5b53eba17..07479c3ec42 100644 --- a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1.json +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1.json @@ -1,58 +1,266 @@ { "anyOf": [ { - "$ref": "#/definitions/InlineType1" + "$ref": "#/definitions/UndiscriminatedUnion1InlineType1", + "description": "lorem ipsum" }, { - "$ref": "#/definitions/MixedInlineType1" + "$ref": "#/definitions/UndiscriminatedUnion1InlineType2", + "description": "lorem ipsum" + }, + { + "$ref": "#/definitions/UndiscriminatedUnion1DiscriminatedUnion1", + "description": "lorem ipsum" + }, + { + "$ref": "#/definitions/UndiscriminatedUnion1DiscriminatedUnion1", + "description": "lorem ipsum" + }, + { + "$ref": "#/definitions/UndiscriminatedUnion1InlineEnum1", + "description": "lorem ipsum" + }, + { + "$ref": "#/definitions/UserId", + "description": "lorem ipsum" + }, + { + "type": "array", + "items": { + "$ref": "#/definitions/UndiscriminatedUnion1InlineListItem1" + }, + "description": "lorem ipsum" + }, + { + "type": "array", + "items": { + "$ref": "#/definitions/UndiscriminatedUnion1InlineSetItem1" + }, + "uniqueItems": true, + "description": "lorem ipsum" + }, + { + "type": "object", + "additionalProperties": { + "$ref": "#/definitions/UndiscriminatedUnion1InlineMapItem1" + }, + "description": "lorem ipsum" + }, + { + "$ref": "#/definitions/ReferenceType", + "description": "lorem ipsum" } ], "definitions": { - "NestedInlineType1": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + }, + "UndiscriminatedUnion1InlineType1InlineType1": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false + }, + "UndiscriminatedUnion1InlineType1": { "type": "object", "properties": { "foo": { "type": "string" }, "bar": { + "$ref": "#/definitions/UndiscriminatedUnion1InlineType1InlineType1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "bar", + "ref" + ], + "additionalProperties": false + }, + "UndiscriminatedUnion1InlineType2": { + "type": "object", + "properties": { + "baz": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "baz", + "ref" + ], + "additionalProperties": false + }, + "UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1": { + "type": "object", + "properties": { + "foo": { "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" } }, "required": [ "foo", - "bar" + "ref" ], "additionalProperties": false }, - "InlineType1": { + "UndiscriminatedUnion1DiscriminatedUnion1": { + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "type1", + "type2", + "ref" + ] + } + }, + "required": [ + "type" + ], + "oneOf": [ + { + "properties": { + "type": { + "const": "type1" + }, + "foo": { + "type": "string" + }, + "bar": { + "$ref": "#/definitions/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "type", + "foo", + "bar", + "ref" + ] + }, + { + "properties": { + "type": { + "const": "type2" + }, + "baz": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "type", + "baz", + "ref" + ] + }, + { + "properties": { + "type": { + "const": "ref" + }, + "foo": { + "type": "string" + } + }, + "required": [ + "type", + "foo" + ] + } + ] + }, + "UndiscriminatedUnion1InlineEnum1": { + "type": "string", + "enum": [ + "SUNNY", + "CLOUDY", + "RAINING", + "SNOWING" + ] + }, + "UserId": { + "type": "string" + }, + "UndiscriminatedUnion1InlineListItem1": { "type": "object", "properties": { "foo": { "type": "string" }, - "bar": { - "$ref": "#/definitions/NestedInlineType1" + "ref": { + "$ref": "#/definitions/ReferenceType" } }, "required": [ "foo", - "bar" + "ref" ], "additionalProperties": false }, - "MixedInlineType1": { + "UndiscriminatedUnion1InlineSetItem1": { "type": "object", "properties": { "foo": { "type": "string" }, - "bar": { + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false + }, + "UndiscriminatedUnion1InlineMapItem1": { + "type": "object", + "properties": { + "foo": { "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" } }, "required": [ "foo", - "bar" + "ref" ], "additionalProperties": false } diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1.json new file mode 100644 index 00000000000..7c541eba134 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1.json @@ -0,0 +1,102 @@ +{ + "type": "object", + "properties": { + "type": { + "type": "string", + "enum": [ + "type1", + "type2", + "ref" + ] + } + }, + "required": [ + "type" + ], + "oneOf": [ + { + "properties": { + "type": { + "const": "type1" + }, + "foo": { + "type": "string" + }, + "bar": { + "$ref": "#/definitions/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "type", + "foo", + "bar", + "ref" + ] + }, + { + "properties": { + "type": { + "const": "type2" + }, + "baz": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "type", + "baz", + "ref" + ] + }, + { + "properties": { + "type": { + "const": "ref" + }, + "foo": { + "type": "string" + } + }, + "required": [ + "type", + "foo" + ] + } + ], + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + }, + "UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1InlineType1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1InlineType1.json new file mode 100644 index 00000000000..c55d0195ec7 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1InlineType1.json @@ -0,0 +1,50 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "$ref": "#/definitions/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "bar", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + }, + "UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.json new file mode 100644 index 00000000000..d43b6cb8bc4 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1InlineType2.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1InlineType2.json new file mode 100644 index 00000000000..86f3f399eb1 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1DiscriminatedUnion1InlineType2.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "baz": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "baz", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineEnum1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineEnum1.json new file mode 100644 index 00000000000..247b41d0eb2 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineEnum1.json @@ -0,0 +1,10 @@ +{ + "type": "string", + "enum": [ + "SUNNY", + "CLOUDY", + "RAINING", + "SNOWING" + ], + "definitions": {} +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineListItem1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineListItem1.json new file mode 100644 index 00000000000..d43b6cb8bc4 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineListItem1.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineMapItem1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineMapItem1.json new file mode 100644 index 00000000000..d43b6cb8bc4 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineMapItem1.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineSetItem1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineSetItem1.json new file mode 100644 index 00000000000..d43b6cb8bc4 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineSetItem1.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineType1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineType1.json new file mode 100644 index 00000000000..7669e968d6a --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineType1.json @@ -0,0 +1,50 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "bar": { + "$ref": "#/definitions/UndiscriminatedUnion1InlineType1InlineType1" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "bar", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + }, + "UndiscriminatedUnion1InlineType1InlineType1": { + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineType1InlineType1.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineType1InlineType1.json new file mode 100644 index 00000000000..d43b6cb8bc4 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineType1InlineType1.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "foo": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "foo", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineType2.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineType2.json new file mode 100644 index 00000000000..86f3f399eb1 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UndiscriminatedUnion1InlineType2.json @@ -0,0 +1,30 @@ +{ + "type": "object", + "properties": { + "baz": { + "type": "string" + }, + "ref": { + "$ref": "#/definitions/ReferenceType" + } + }, + "required": [ + "baz", + "ref" + ], + "additionalProperties": false, + "definitions": { + "ReferenceType": { + "type": "object", + "properties": { + "foo": { + "type": "string" + } + }, + "required": [ + "foo" + ], + "additionalProperties": false + } + } +} \ No newline at end of file diff --git a/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UserId.json b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UserId.json new file mode 100644 index 00000000000..cdb8c887b62 --- /dev/null +++ b/packages/cli/fern-definition/ir-to-jsonschema/src/__test__/__snapshots__/inline-types/type__UserId.json @@ -0,0 +1,4 @@ +{ + "type": "string", + "definitions": {} +} \ No newline at end of file diff --git a/packages/cli/generation/ir-generator-tests/src/dynamic-snippets/__test__/test-definitions/inline-types.json b/packages/cli/generation/ir-generator-tests/src/dynamic-snippets/__test__/test-definitions/inline-types.json index 20109cd87d1..7d7882e4ae6 100644 --- a/packages/cli/generation/ir-generator-tests/src/dynamic-snippets/__test__/test-definitions/inline-types.json +++ b/packages/cli/generation/ir-generator-tests/src/dynamic-snippets/__test__/test-definitions/inline-types.json @@ -1,26 +1,26 @@ { "version": "1.0.0", "types": { - "type_:RootType1": { - "type": "object", + "type_:AliasMapInline": { + "type": "alias", "declaration": { "name": { - "originalName": "RootType1", + "originalName": "AliasMapInline", "camelCase": { - "unsafeName": "rootType1", - "safeName": "rootType1" + "unsafeName": "aliasMapInline", + "safeName": "aliasMapInline" }, "snakeCase": { - "unsafeName": "root_type1", - "safeName": "root_type1" + "unsafeName": "alias_map_inline", + "safeName": "alias_map_inline" }, "screamingSnakeCase": { - "unsafeName": "ROOT_TYPE1", - "safeName": "ROOT_TYPE1" + "unsafeName": "ALIAS_MAP_INLINE", + "safeName": "ALIAS_MAP_INLINE" }, "pascalCase": { - "unsafeName": "RootType1", - "safeName": "RootType1" + "unsafeName": "AliasMapInline", + "safeName": "AliasMapInline" } }, "fernFilepath": { @@ -29,85 +29,110 @@ "file": null } }, - "properties": [ - { - "name": { - "name": { - "originalName": "foo", - "camelCase": { - "unsafeName": "foo", - "safeName": "foo" - }, - "snakeCase": { - "unsafeName": "foo", - "safeName": "foo" - }, - "screamingSnakeCase": { - "unsafeName": "FOO", - "safeName": "FOO" - }, - "pascalCase": { - "unsafeName": "Foo", - "safeName": "Foo" - } - }, - "wireValue": "foo" + "typeReference": { + "type": "map", + "key": { + "type": "primitive", + "value": "STRING" + }, + "value": { + "type": "named", + "value": "type_:AliasInlineValue" + } + } + }, + "type_:AliasSetInline": { + "type": "alias", + "declaration": { + "name": { + "originalName": "AliasSetInline", + "camelCase": { + "unsafeName": "aliasSetInline", + "safeName": "aliasSetInline" }, - "typeReference": { - "type": "primitive", - "value": "STRING" + "snakeCase": { + "unsafeName": "alias_set_inline", + "safeName": "alias_set_inline" + }, + "screamingSnakeCase": { + "unsafeName": "ALIAS_SET_INLINE", + "safeName": "ALIAS_SET_INLINE" + }, + "pascalCase": { + "unsafeName": "AliasSetInline", + "safeName": "AliasSetInline" } }, - { - "name": { - "name": { - "originalName": "bar", - "camelCase": { - "unsafeName": "bar", - "safeName": "bar" - }, - "snakeCase": { - "unsafeName": "bar", - "safeName": "bar" - }, - "screamingSnakeCase": { - "unsafeName": "BAR", - "safeName": "BAR" - }, - "pascalCase": { - "unsafeName": "Bar", - "safeName": "Bar" - } - }, - "wireValue": "bar" + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "typeReference": { + "type": "set", + "value": { + "type": "named", + "value": "type_:AliasInlineValue" + } + } + }, + "type_:AliasListInline": { + "type": "alias", + "declaration": { + "name": { + "originalName": "AliasListInline", + "camelCase": { + "unsafeName": "aliasListInline", + "safeName": "aliasListInline" }, - "typeReference": { - "type": "named", - "value": "type_:InlineType1" + "snakeCase": { + "unsafeName": "alias_list_inline", + "safeName": "alias_list_inline" + }, + "screamingSnakeCase": { + "unsafeName": "ALIAS_LIST_INLINE", + "safeName": "ALIAS_LIST_INLINE" + }, + "pascalCase": { + "unsafeName": "AliasListInline", + "safeName": "AliasListInline" } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null } - ] + }, + "typeReference": { + "type": "list", + "value": { + "type": "named", + "value": "type_:AliasInlineValue" + } + } }, - "type_:InlineType1": { + "type_:AliasInlineValue": { "type": "object", "declaration": { "name": { - "originalName": "InlineType1", + "originalName": "AliasInlineValue", "camelCase": { - "unsafeName": "inlineType1", - "safeName": "inlineType1" + "unsafeName": "aliasInlineValue", + "safeName": "aliasInlineValue" }, "snakeCase": { - "unsafeName": "inline_type1", - "safeName": "inline_type1" + "unsafeName": "alias_inline_value", + "safeName": "alias_inline_value" }, "screamingSnakeCase": { - "unsafeName": "INLINE_TYPE1", - "safeName": "INLINE_TYPE1" + "unsafeName": "ALIAS_INLINE_VALUE", + "safeName": "ALIAS_INLINE_VALUE" }, "pascalCase": { - "unsafeName": "InlineType1", - "safeName": "InlineType1" + "unsafeName": "AliasInlineValue", + "safeName": "AliasInlineValue" } }, "fernFilepath": { @@ -169,32 +194,32 @@ "wireValue": "bar" }, "typeReference": { - "type": "named", - "value": "type_:NestedInlineType1" + "type": "primitive", + "value": "STRING" } } ] }, - "type_:InlineType2": { + "type_:RequestTypeInlineType1": { "type": "object", "declaration": { "name": { - "originalName": "InlineType2", + "originalName": "RequestTypeInlineType1", "camelCase": { - "unsafeName": "inlineType2", - "safeName": "inlineType2" + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" }, "snakeCase": { - "unsafeName": "inline_type2", - "safeName": "inline_type2" + "unsafeName": "request_type_inline_type1", + "safeName": "request_type_inline_type1" }, "screamingSnakeCase": { - "unsafeName": "INLINE_TYPE2", - "safeName": "INLINE_TYPE2" + "unsafeName": "REQUEST_TYPE_INLINE_TYPE1", + "safeName": "REQUEST_TYPE_INLINE_TYPE1" }, "pascalCase": { - "unsafeName": "InlineType2", - "safeName": "InlineType2" + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" } }, "fernFilepath": { @@ -207,25 +232,25 @@ { "name": { "name": { - "originalName": "baz", + "originalName": "foo", "camelCase": { - "unsafeName": "baz", - "safeName": "baz" + "unsafeName": "foo", + "safeName": "foo" }, "snakeCase": { - "unsafeName": "baz", - "safeName": "baz" + "unsafeName": "foo", + "safeName": "foo" }, "screamingSnakeCase": { - "unsafeName": "BAZ", - "safeName": "BAZ" + "unsafeName": "FOO", + "safeName": "FOO" }, "pascalCase": { - "unsafeName": "Baz", - "safeName": "Baz" + "unsafeName": "Foo", + "safeName": "Foo" } }, - "wireValue": "baz" + "wireValue": "foo" }, "typeReference": { "type": "primitive", @@ -234,26 +259,26 @@ } ] }, - "type_:NestedInlineType1": { + "type_:RootType1": { "type": "object", "declaration": { "name": { - "originalName": "NestedInlineType1", + "originalName": "RootType1", "camelCase": { - "unsafeName": "nestedInlineType1", - "safeName": "nestedInlineType1" + "unsafeName": "rootType1", + "safeName": "rootType1" }, "snakeCase": { - "unsafeName": "nested_inline_type1", - "safeName": "nested_inline_type1" + "unsafeName": "root_type1", + "safeName": "root_type1" }, "screamingSnakeCase": { - "unsafeName": "NESTED_INLINE_TYPE1", - "safeName": "NESTED_INLINE_TYPE1" + "unsafeName": "ROOT_TYPE1", + "safeName": "ROOT_TYPE1" }, "pascalCase": { - "unsafeName": "NestedInlineType1", - "safeName": "NestedInlineType1" + "unsafeName": "RootType1", + "safeName": "RootType1" } }, "fernFilepath": { @@ -315,167 +340,157 @@ "wireValue": "bar" }, "typeReference": { - "type": "primitive", - "value": "STRING" + "type": "named", + "value": "type_:RootType1InlineType1" } }, { "name": { "name": { - "originalName": "myEnum", + "originalName": "fooMap", "camelCase": { - "unsafeName": "myEnum", - "safeName": "myEnum" + "unsafeName": "fooMap", + "safeName": "fooMap" }, "snakeCase": { - "unsafeName": "my_enum", - "safeName": "my_enum" + "unsafeName": "foo_map", + "safeName": "foo_map" }, "screamingSnakeCase": { - "unsafeName": "MY_ENUM", - "safeName": "MY_ENUM" + "unsafeName": "FOO_MAP", + "safeName": "FOO_MAP" }, "pascalCase": { - "unsafeName": "MyEnum", - "safeName": "MyEnum" + "unsafeName": "FooMap", + "safeName": "FooMap" } }, - "wireValue": "myEnum" + "wireValue": "fooMap" }, "typeReference": { - "type": "named", - "value": "type_:InlineEnum" - } - } - ] - }, - "type_:InlinedDiscriminatedUnion1": { - "type": "discriminatedUnion", - "declaration": { - "name": { - "originalName": "InlinedDiscriminatedUnion1", - "camelCase": { - "unsafeName": "inlinedDiscriminatedUnion1", - "safeName": "inlinedDiscriminatedUnion1" - }, - "snakeCase": { - "unsafeName": "inlined_discriminated_union1", - "safeName": "inlined_discriminated_union1" - }, - "screamingSnakeCase": { - "unsafeName": "INLINED_DISCRIMINATED_UNION1", - "safeName": "INLINED_DISCRIMINATED_UNION1" - }, - "pascalCase": { - "unsafeName": "InlinedDiscriminatedUnion1", - "safeName": "InlinedDiscriminatedUnion1" + "type": "map", + "key": { + "type": "primitive", + "value": "STRING" + }, + "value": { + "type": "named", + "value": "type_:RootType1FooMapValue" + } } }, - "fernFilepath": { - "allParts": [], - "packagePath": [], - "file": null - } - }, - "discriminant": { - "name": { - "originalName": "type", - "camelCase": { - "unsafeName": "type", - "safeName": "type" - }, - "snakeCase": { - "unsafeName": "type", - "safeName": "type" - }, - "screamingSnakeCase": { - "unsafeName": "TYPE", - "safeName": "TYPE" + { + "name": { + "name": { + "originalName": "fooList", + "camelCase": { + "unsafeName": "fooList", + "safeName": "fooList" + }, + "snakeCase": { + "unsafeName": "foo_list", + "safeName": "foo_list" + }, + "screamingSnakeCase": { + "unsafeName": "FOO_LIST", + "safeName": "FOO_LIST" + }, + "pascalCase": { + "unsafeName": "FooList", + "safeName": "FooList" + } + }, + "wireValue": "fooList" }, - "pascalCase": { - "unsafeName": "Type", - "safeName": "Type" + "typeReference": { + "type": "list", + "value": { + "type": "named", + "value": "type_:RootType1FooListItem" + } } }, - "wireValue": "type" - }, - "types": { - "type1": { - "type": "samePropertiesAsObject", - "typeId": "type_:InlineType1", - "discriminantValue": { + { + "name": { "name": { - "originalName": "type1", + "originalName": "fooSet", "camelCase": { - "unsafeName": "type1", - "safeName": "type1" + "unsafeName": "fooSet", + "safeName": "fooSet" }, "snakeCase": { - "unsafeName": "type1", - "safeName": "type1" + "unsafeName": "foo_set", + "safeName": "foo_set" }, "screamingSnakeCase": { - "unsafeName": "TYPE1", - "safeName": "TYPE1" + "unsafeName": "FOO_SET", + "safeName": "FOO_SET" }, "pascalCase": { - "unsafeName": "Type1", - "safeName": "Type1" + "unsafeName": "FooSet", + "safeName": "FooSet" } }, - "wireValue": "type1" + "wireValue": "fooSet" }, - "properties": [] + "typeReference": { + "type": "set", + "value": { + "type": "named", + "value": "type_:RootType1FooSetItem" + } + } }, - "type2": { - "type": "samePropertiesAsObject", - "typeId": "type_:InlineType2", - "discriminantValue": { + { + "name": { "name": { - "originalName": "type2", + "originalName": "ref", "camelCase": { - "unsafeName": "type2", - "safeName": "type2" + "unsafeName": "ref", + "safeName": "ref" }, "snakeCase": { - "unsafeName": "type2", - "safeName": "type2" + "unsafeName": "ref", + "safeName": "ref" }, "screamingSnakeCase": { - "unsafeName": "TYPE2", - "safeName": "TYPE2" + "unsafeName": "REF", + "safeName": "REF" }, "pascalCase": { - "unsafeName": "Type2", - "safeName": "Type2" + "unsafeName": "Ref", + "safeName": "Ref" } }, - "wireValue": "type2" + "wireValue": "ref" }, - "properties": [] + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } } - } + ] }, - "type_:InlinedUndiscriminatedUnion1": { - "type": "undiscriminatedUnion", + "type_:RootType1FooMapValue": { + "type": "object", "declaration": { "name": { - "originalName": "InlinedUndiscriminatedUnion1", + "originalName": "RootType1FooMapValue", "camelCase": { - "unsafeName": "inlinedUndiscriminatedUnion1", - "safeName": "inlinedUndiscriminatedUnion1" + "unsafeName": "rootType1FooMapValue", + "safeName": "rootType1FooMapValue" }, "snakeCase": { - "unsafeName": "inlined_undiscriminated_union1", - "safeName": "inlined_undiscriminated_union1" + "unsafeName": "root_type1foo_map_value", + "safeName": "root_type1foo_map_value" }, "screamingSnakeCase": { - "unsafeName": "INLINED_UNDISCRIMINATED_UNION1", - "safeName": "INLINED_UNDISCRIMINATED_UNION1" + "unsafeName": "ROOT_TYPE1FOO_MAP_VALUE", + "safeName": "ROOT_TYPE1FOO_MAP_VALUE" }, "pascalCase": { - "unsafeName": "InlinedUndiscriminatedUnion1", - "safeName": "InlinedUndiscriminatedUnion1" + "unsafeName": "RootType1FooMapValue", + "safeName": "RootType1FooMapValue" } }, "fernFilepath": { @@ -484,37 +499,2463 @@ "file": null } }, - "types": [ - { - "type": "named", - "value": "type_:InlineType1" - }, + "properties": [ { - "type": "named", - "value": "type_:InlineType2" - } - ] - }, - "type_:InlineEnum": { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:RootType1FooListItem": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1FooListItem", + "camelCase": { + "unsafeName": "rootType1FooListItem", + "safeName": "rootType1FooListItem" + }, + "snakeCase": { + "unsafeName": "root_type1foo_list_item", + "safeName": "root_type1foo_list_item" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE1FOO_LIST_ITEM", + "safeName": "ROOT_TYPE1FOO_LIST_ITEM" + }, + "pascalCase": { + "unsafeName": "RootType1FooListItem", + "safeName": "RootType1FooListItem" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:RootType1FooSetItem": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1FooSetItem", + "camelCase": { + "unsafeName": "rootType1FooSetItem", + "safeName": "rootType1FooSetItem" + }, + "snakeCase": { + "unsafeName": "root_type1foo_set_item", + "safeName": "root_type1foo_set_item" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE1FOO_SET_ITEM", + "safeName": "ROOT_TYPE1FOO_SET_ITEM" + }, + "pascalCase": { + "unsafeName": "RootType1FooSetItem", + "safeName": "RootType1FooSetItem" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:RootType1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type1inline_type1", + "safeName": "root_type1inline_type1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE1INLINE_TYPE1", + "safeName": "ROOT_TYPE1INLINE_TYPE1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "type": "named", + "value": "type_:RootType1InlineType1NestedInlineType1" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:RootType1InlineType1NestedInlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type1inline_type1nested_inline_type1", + "safeName": "root_type1inline_type1nested_inline_type1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE1INLINE_TYPE1NESTED_INLINE_TYPE1", + "safeName": "ROOT_TYPE1INLINE_TYPE1NESTED_INLINE_TYPE1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "myEnum", + "camelCase": { + "unsafeName": "myEnum", + "safeName": "myEnum" + }, + "snakeCase": { + "unsafeName": "my_enum", + "safeName": "my_enum" + }, + "screamingSnakeCase": { + "unsafeName": "MY_ENUM", + "safeName": "MY_ENUM" + }, + "pascalCase": { + "unsafeName": "MyEnum", + "safeName": "MyEnum" + } + }, + "wireValue": "myEnum" + }, + "typeReference": { + "type": "named", + "value": "type_:InlineEnum1" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:DiscriminatedUnion1": { + "type": "discriminatedUnion", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union1", + "safeName": "discriminated_union1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION1", + "safeName": "DISCRIMINATED_UNION1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "types": { + "type1": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType1", + "discriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE1", + "safeName": "TYPE1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "properties": [] + }, + "type2": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType2", + "discriminantValue": { + "name": { + "originalName": "type2", + "camelCase": { + "unsafeName": "type2", + "safeName": "type2" + }, + "snakeCase": { + "unsafeName": "type2", + "safeName": "type2" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE2", + "safeName": "TYPE2" + }, + "pascalCase": { + "unsafeName": "Type2", + "safeName": "Type2" + } + }, + "wireValue": "type2" + }, + "properties": [] + }, + "ref": { + "type": "samePropertiesAsObject", + "typeId": "type_:ReferenceType", + "discriminantValue": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "properties": [] + } + } + }, + "type_:DiscriminatedUnion1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union1inline_type1", + "safeName": "discriminated_union1inline_type1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION1INLINE_TYPE1", + "safeName": "DISCRIMINATED_UNION1INLINE_TYPE1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "type": "named", + "value": "type_:DiscriminatedUnion1InlineType1InlineType1" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:DiscriminatedUnion1InlineType1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1InlineType1", + "safeName": "discriminatedUnion1InlineType1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union1inline_type1inline_type1", + "safeName": "discriminated_union1inline_type1inline_type1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION1INLINE_TYPE1INLINE_TYPE1", + "safeName": "DISCRIMINATED_UNION1INLINE_TYPE1INLINE_TYPE1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:DiscriminatedUnion1InlineType2": { + "type": "object", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType2", + "safeName": "discriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "discriminated_union1inline_type2", + "safeName": "discriminated_union1inline_type2" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION1INLINE_TYPE2", + "safeName": "DISCRIMINATED_UNION1INLINE_TYPE2" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType2", + "safeName": "DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:UndiscriminatedUnion1": { + "type": "undiscriminatedUnion", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1", + "safeName": "undiscriminated_union1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1", + "safeName": "UNDISCRIMINATED_UNION1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "types": [ + { + "type": "named", + "value": "type_:UndiscriminatedUnion1InlineType1" + }, + { + "type": "named", + "value": "type_:UndiscriminatedUnion1InlineType2" + }, + { + "type": "named", + "value": "type_:UndiscriminatedUnion1DiscriminatedUnion1" + }, + { + "type": "named", + "value": "type_:UndiscriminatedUnion1DiscriminatedUnion1" + }, + { + "type": "named", + "value": "type_:UndiscriminatedUnion1InlineEnum1" + }, + { + "type": "named", + "value": "type_:UserId" + }, + { + "type": "list", + "value": { + "type": "named", + "value": "type_:UndiscriminatedUnion1InlineListItem1" + } + }, + { + "type": "set", + "value": { + "type": "named", + "value": "type_:UndiscriminatedUnion1InlineSetItem1" + } + }, + { + "type": "map", + "key": { + "type": "primitive", + "value": "STRING" + }, + "value": { + "type": "named", + "value": "type_:UndiscriminatedUnion1InlineMapItem1" + } + }, + { + "type": "named", + "value": "type_:ReferenceType" + } + ] + }, + "type_:UndiscriminatedUnion1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1inline_type1", + "safeName": "undiscriminated_union1inline_type1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1INLINE_TYPE1", + "safeName": "UNDISCRIMINATED_UNION1INLINE_TYPE1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "type": "named", + "value": "type_:UndiscriminatedUnion1InlineType1InlineType1" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:UndiscriminatedUnion1InlineType1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1inline_type1inline_type1", + "safeName": "undiscriminated_union1inline_type1inline_type1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1INLINE_TYPE1INLINE_TYPE1", + "safeName": "UNDISCRIMINATED_UNION1INLINE_TYPE1INLINE_TYPE1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:UndiscriminatedUnion1InlineType2": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1inline_type2", + "safeName": "undiscriminated_union1inline_type2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1INLINE_TYPE2", + "safeName": "UNDISCRIMINATED_UNION1INLINE_TYPE2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:InlineEnum1": { + "type": "enum", + "declaration": { + "name": { + "originalName": "InlineEnum1", + "camelCase": { + "unsafeName": "inlineEnum1", + "safeName": "inlineEnum1" + }, + "snakeCase": { + "unsafeName": "inline_enum1", + "safeName": "inline_enum1" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM1", + "safeName": "INLINE_ENUM1" + }, + "pascalCase": { + "unsafeName": "InlineEnum1", + "safeName": "InlineEnum1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "values": [ + { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + }, + { + "name": { + "originalName": "CLOUDY", + "camelCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "snakeCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "screamingSnakeCase": { + "unsafeName": "CLOUDY", + "safeName": "CLOUDY" + }, + "pascalCase": { + "unsafeName": "Cloudy", + "safeName": "Cloudy" + } + }, + "wireValue": "CLOUDY" + }, + { + "name": { + "originalName": "RAINING", + "camelCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "snakeCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "screamingSnakeCase": { + "unsafeName": "RAINING", + "safeName": "RAINING" + }, + "pascalCase": { + "unsafeName": "Raining", + "safeName": "Raining" + } + }, + "wireValue": "RAINING" + }, + { + "name": { + "originalName": "SNOWING", + "camelCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "snakeCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "screamingSnakeCase": { + "unsafeName": "SNOWING", + "safeName": "SNOWING" + }, + "pascalCase": { + "unsafeName": "Snowing", + "safeName": "Snowing" + } + }, + "wireValue": "SNOWING" + } + ] + }, + "type_:UndiscriminatedUnion1DiscriminatedUnion1": { + "type": "discriminatedUnion", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1DiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1DiscriminatedUnion1", + "safeName": "undiscriminatedUnion1DiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1discriminated_union1", + "safeName": "undiscriminated_union1discriminated_union1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1DISCRIMINATED_UNION1", + "safeName": "UNDISCRIMINATED_UNION1DISCRIMINATED_UNION1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1DiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "types": { + "type1": { + "type": "samePropertiesAsObject", + "typeId": "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType1", + "discriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE1", + "safeName": "TYPE1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "properties": [] + }, + "type2": { + "type": "samePropertiesAsObject", + "typeId": "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType2", + "discriminantValue": { + "name": { + "originalName": "type2", + "camelCase": { + "unsafeName": "type2", + "safeName": "type2" + }, + "snakeCase": { + "unsafeName": "type2", + "safeName": "type2" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE2", + "safeName": "TYPE2" + }, + "pascalCase": { + "unsafeName": "Type2", + "safeName": "Type2" + } + }, + "wireValue": "type2" + }, + "properties": [] + }, + "ref": { + "type": "samePropertiesAsObject", + "typeId": "type_:ReferenceType", + "discriminantValue": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "properties": [] + } + } + }, + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1DiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1DiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1discriminated_union1inline_type1", + "safeName": "undiscriminated_union1discriminated_union1inline_type1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1DISCRIMINATED_UNION1INLINE_TYPE1", + "safeName": "UNDISCRIMINATED_UNION1DISCRIMINATED_UNION1INLINE_TYPE1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1DiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "type": "named", + "value": "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1", + "safeName": "undiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1discriminated_union1inline_type1inline_type1", + "safeName": "undiscriminated_union1discriminated_union1inline_type1inline_type1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1DISCRIMINATED_UNION1INLINE_TYPE1INLINE_TYPE1", + "safeName": "UNDISCRIMINATED_UNION1DISCRIMINATED_UNION1INLINE_TYPE1INLINE_TYPE1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1", + "safeName": "UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType2": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1DiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1DiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1discriminated_union1inline_type2", + "safeName": "undiscriminated_union1discriminated_union1inline_type2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1DISCRIMINATED_UNION1INLINE_TYPE2", + "safeName": "UNDISCRIMINATED_UNION1DISCRIMINATED_UNION1INLINE_TYPE2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1DiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:UndiscriminatedUnion1InlineEnum1": { "type": "enum", "declaration": { "name": { - "originalName": "InlineEnum", + "originalName": "UndiscriminatedUnion1InlineEnum1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineEnum1", + "safeName": "undiscriminatedUnion1InlineEnum1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1inline_enum1", + "safeName": "undiscriminated_union1inline_enum1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1INLINE_ENUM1", + "safeName": "UNDISCRIMINATED_UNION1INLINE_ENUM1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineEnum1", + "safeName": "UndiscriminatedUnion1InlineEnum1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "values": [ + { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + }, + { + "name": { + "originalName": "CLOUDY", + "camelCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "snakeCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "screamingSnakeCase": { + "unsafeName": "CLOUDY", + "safeName": "CLOUDY" + }, + "pascalCase": { + "unsafeName": "Cloudy", + "safeName": "Cloudy" + } + }, + "wireValue": "CLOUDY" + }, + { + "name": { + "originalName": "RAINING", + "camelCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "snakeCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "screamingSnakeCase": { + "unsafeName": "RAINING", + "safeName": "RAINING" + }, + "pascalCase": { + "unsafeName": "Raining", + "safeName": "Raining" + } + }, + "wireValue": "RAINING" + }, + { + "name": { + "originalName": "SNOWING", + "camelCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "snakeCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "screamingSnakeCase": { + "unsafeName": "SNOWING", + "safeName": "SNOWING" + }, + "pascalCase": { + "unsafeName": "Snowing", + "safeName": "Snowing" + } + }, + "wireValue": "SNOWING" + } + ] + }, + "type_:UserId": { + "type": "alias", + "declaration": { + "name": { + "originalName": "UserId", + "camelCase": { + "unsafeName": "userID", + "safeName": "userID" + }, + "snakeCase": { + "unsafeName": "user_id", + "safeName": "user_id" + }, + "screamingSnakeCase": { + "unsafeName": "USER_ID", + "safeName": "USER_ID" + }, + "pascalCase": { + "unsafeName": "UserID", + "safeName": "UserID" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + "type_:UndiscriminatedUnion1InlineListItem1": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineListItem1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineListItem1", + "safeName": "undiscriminatedUnion1InlineListItem1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1inline_list_item1", + "safeName": "undiscriminated_union1inline_list_item1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1INLINE_LIST_ITEM1", + "safeName": "UNDISCRIMINATED_UNION1INLINE_LIST_ITEM1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineListItem1", + "safeName": "UndiscriminatedUnion1InlineListItem1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:UndiscriminatedUnion1InlineSetItem1": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineSetItem1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineSetItem1", + "safeName": "undiscriminatedUnion1InlineSetItem1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1inline_set_item1", + "safeName": "undiscriminated_union1inline_set_item1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1INLINE_SET_ITEM1", + "safeName": "UNDISCRIMINATED_UNION1INLINE_SET_ITEM1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineSetItem1", + "safeName": "UndiscriminatedUnion1InlineSetItem1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:UndiscriminatedUnion1InlineMapItem1": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineMapItem1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineMapItem1", + "safeName": "undiscriminatedUnion1InlineMapItem1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union1inline_map_item1", + "safeName": "undiscriminated_union1inline_map_item1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION1INLINE_MAP_ITEM1", + "safeName": "UNDISCRIMINATED_UNION1INLINE_MAP_ITEM1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineMapItem1", + "safeName": "UndiscriminatedUnion1InlineMapItem1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "ref", + "camelCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "snakeCase": { + "unsafeName": "ref", + "safeName": "ref" + }, + "screamingSnakeCase": { + "unsafeName": "REF", + "safeName": "REF" + }, + "pascalCase": { + "unsafeName": "Ref", + "safeName": "Ref" + } + }, + "wireValue": "ref" + }, + "typeReference": { + "type": "named", + "value": "type_:ReferenceType" + } + } + ] + }, + "type_:ReferenceType": { + "type": "object", + "declaration": { + "name": { + "originalName": "ReferenceType", + "camelCase": { + "unsafeName": "referenceType", + "safeName": "referenceType" + }, + "snakeCase": { + "unsafeName": "reference_type", + "safeName": "reference_type" + }, + "screamingSnakeCase": { + "unsafeName": "REFERENCE_TYPE", + "safeName": "REFERENCE_TYPE" + }, + "pascalCase": { + "unsafeName": "ReferenceType", + "safeName": "ReferenceType" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + } + ] + } + }, + "headers": [], + "endpoints": { + "endpoint_.getRoot": { + "auth": null, + "declaration": { + "name": { + "originalName": "getRoot", + "camelCase": { + "unsafeName": "getRoot", + "safeName": "getRoot" + }, + "snakeCase": { + "unsafeName": "get_root", + "safeName": "get_root" + }, + "screamingSnakeCase": { + "unsafeName": "GET_ROOT", + "safeName": "GET_ROOT" + }, + "pascalCase": { + "unsafeName": "GetRoot", + "safeName": "GetRoot" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "location": { + "method": "POST", + "path": "/root/root" + }, + "request": { + "type": "inlined", + "declaration": { + "name": { + "originalName": "PostRootRequest", + "camelCase": { + "unsafeName": "postRootRequest", + "safeName": "postRootRequest" + }, + "snakeCase": { + "unsafeName": "post_root_request", + "safeName": "post_root_request" + }, + "screamingSnakeCase": { + "unsafeName": "POST_ROOT_REQUEST", + "safeName": "POST_ROOT_REQUEST" + }, + "pascalCase": { + "unsafeName": "PostRootRequest", + "safeName": "PostRootRequest" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "pathParameters": [], + "queryParameters": [], + "headers": [], + "body": { + "type": "properties", + "value": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "type": "named", + "value": "type_:RequestTypeInlineType1" + } + }, + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } + } + ] + }, + "metadata": { + "includePathParameters": false, + "onlyPathParameters": false + } + }, + "response": { + "type": "json" + } + }, + "endpoint_.getDiscriminatedUnion": { + "auth": null, + "declaration": { + "name": { + "originalName": "getDiscriminatedUnion", "camelCase": { - "unsafeName": "inlineEnum", - "safeName": "inlineEnum" + "unsafeName": "getDiscriminatedUnion", + "safeName": "getDiscriminatedUnion" }, "snakeCase": { - "unsafeName": "inline_enum", - "safeName": "inline_enum" + "unsafeName": "get_discriminated_union", + "safeName": "get_discriminated_union" }, "screamingSnakeCase": { - "unsafeName": "INLINE_ENUM", - "safeName": "INLINE_ENUM" + "unsafeName": "GET_DISCRIMINATED_UNION", + "safeName": "GET_DISCRIMINATED_UNION" }, "pascalCase": { - "unsafeName": "InlineEnum", - "safeName": "InlineEnum" + "unsafeName": "GetDiscriminatedUnion", + "safeName": "GetDiscriminatedUnion" } }, "fernFilepath": { @@ -523,120 +2964,131 @@ "file": null } }, - "values": [ - { - "name": { - "originalName": "SUNNY", - "camelCase": { - "unsafeName": "sunny", - "safeName": "sunny" - }, - "snakeCase": { - "unsafeName": "sunny", - "safeName": "sunny" - }, - "screamingSnakeCase": { - "unsafeName": "SUNNY", - "safeName": "SUNNY" - }, - "pascalCase": { - "unsafeName": "Sunny", - "safeName": "Sunny" - } - }, - "wireValue": "SUNNY" - }, - { + "location": { + "method": "POST", + "path": "/root/discriminated-union" + }, + "request": { + "type": "inlined", + "declaration": { "name": { - "originalName": "CLOUDY", + "originalName": "GetDiscriminatedUnionRequest", "camelCase": { - "unsafeName": "cloudy", - "safeName": "cloudy" + "unsafeName": "getDiscriminatedUnionRequest", + "safeName": "getDiscriminatedUnionRequest" }, "snakeCase": { - "unsafeName": "cloudy", - "safeName": "cloudy" + "unsafeName": "get_discriminated_union_request", + "safeName": "get_discriminated_union_request" }, "screamingSnakeCase": { - "unsafeName": "CLOUDY", - "safeName": "CLOUDY" + "unsafeName": "GET_DISCRIMINATED_UNION_REQUEST", + "safeName": "GET_DISCRIMINATED_UNION_REQUEST" }, "pascalCase": { - "unsafeName": "Cloudy", - "safeName": "Cloudy" + "unsafeName": "GetDiscriminatedUnionRequest", + "safeName": "GetDiscriminatedUnionRequest" } }, - "wireValue": "CLOUDY" + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } }, - { - "name": { - "originalName": "RAINING", - "camelCase": { - "unsafeName": "raining", - "safeName": "raining" - }, - "snakeCase": { - "unsafeName": "raining", - "safeName": "raining" - }, - "screamingSnakeCase": { - "unsafeName": "RAINING", - "safeName": "RAINING" + "pathParameters": [], + "queryParameters": [], + "headers": [], + "body": { + "type": "properties", + "value": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "type": "named", + "value": "type_:DiscriminatedUnion1" + } }, - "pascalCase": { - "unsafeName": "Raining", - "safeName": "Raining" + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "type": "primitive", + "value": "STRING" + } } - }, - "wireValue": "RAINING" + ] }, - { - "name": { - "originalName": "SNOWING", - "camelCase": { - "unsafeName": "snowing", - "safeName": "snowing" - }, - "snakeCase": { - "unsafeName": "snowing", - "safeName": "snowing" - }, - "screamingSnakeCase": { - "unsafeName": "SNOWING", - "safeName": "SNOWING" - }, - "pascalCase": { - "unsafeName": "Snowing", - "safeName": "Snowing" - } - }, - "wireValue": "SNOWING" + "metadata": { + "includePathParameters": false, + "onlyPathParameters": false } - ] - } - }, - "headers": [], - "endpoints": { - "endpoint_.getRoot": { + }, + "response": { + "type": "json" + } + }, + "endpoint_.getUndiscriminatedUnion": { "auth": null, "declaration": { "name": { - "originalName": "getRoot", + "originalName": "getUndiscriminatedUnion", "camelCase": { - "unsafeName": "getRoot", - "safeName": "getRoot" + "unsafeName": "getUndiscriminatedUnion", + "safeName": "getUndiscriminatedUnion" }, "snakeCase": { - "unsafeName": "get_root", - "safeName": "get_root" + "unsafeName": "get_undiscriminated_union", + "safeName": "get_undiscriminated_union" }, "screamingSnakeCase": { - "unsafeName": "GET_ROOT", - "safeName": "GET_ROOT" + "unsafeName": "GET_UNDISCRIMINATED_UNION", + "safeName": "GET_UNDISCRIMINATED_UNION" }, "pascalCase": { - "unsafeName": "GetRoot", - "safeName": "GetRoot" + "unsafeName": "GetUndiscriminatedUnion", + "safeName": "GetUndiscriminatedUnion" } }, "fernFilepath": { @@ -647,28 +3099,28 @@ }, "location": { "method": "POST", - "path": "/root/root" + "path": "/root/undiscriminated-union" }, "request": { "type": "inlined", "declaration": { "name": { - "originalName": "PostRootRequest", + "originalName": "GetUndiscriminatedUnionRequest", "camelCase": { - "unsafeName": "postRootRequest", - "safeName": "postRootRequest" + "unsafeName": "getUndiscriminatedUnionRequest", + "safeName": "getUndiscriminatedUnionRequest" }, "snakeCase": { - "unsafeName": "post_root_request", - "safeName": "post_root_request" + "unsafeName": "get_undiscriminated_union_request", + "safeName": "get_undiscriminated_union_request" }, "screamingSnakeCase": { - "unsafeName": "POST_ROOT_REQUEST", - "safeName": "POST_ROOT_REQUEST" + "unsafeName": "GET_UNDISCRIMINATED_UNION_REQUEST", + "safeName": "GET_UNDISCRIMINATED_UNION_REQUEST" }, "pascalCase": { - "unsafeName": "PostRootRequest", - "safeName": "PostRootRequest" + "unsafeName": "GetUndiscriminatedUnionRequest", + "safeName": "GetUndiscriminatedUnionRequest" } }, "fernFilepath": { @@ -708,7 +3160,7 @@ }, "typeReference": { "type": "named", - "value": "type_:InlineType1" + "value": "type_:UndiscriminatedUnion1" } }, { diff --git a/packages/cli/register/src/ir-to-fdr-converter/__test__/__snapshots__/inline-types.json b/packages/cli/register/src/ir-to-fdr-converter/__test__/__snapshots__/inline-types.json index bcdd5f5231b..be312f99f23 100644 --- a/packages/cli/register/src/ir-to-fdr-converter/__test__/__snapshots__/inline-types.json +++ b/packages/cli/register/src/ir-to-fdr-converter/__test__/__snapshots__/inline-types.json @@ -1,12 +1,112 @@ { "types": { + "type_:AliasMapInline": { + "name": "AliasMapInline", + "shape": { + "type": "alias", + "value": { + "type": "map", + "keyType": { + "type": "primitive", + "value": { + "type": "string" + } + }, + "valueType": { + "type": "id", + "value": "type_:AliasInlineValue" + } + } + } + }, + "type_:AliasSetInline": { + "name": "AliasSetInline", + "shape": { + "type": "alias", + "value": { + "type": "set", + "itemType": { + "type": "id", + "value": "type_:AliasInlineValue" + } + } + } + }, + "type_:AliasListInline": { + "name": "AliasListInline", + "shape": { + "type": "alias", + "value": { + "type": "list", + "itemType": { + "type": "id", + "value": "type_:AliasInlineValue" + } + } + } + }, + "type_:AliasInlineValue": { + "name": "AliasInlineValue", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "key": "bar", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:RequestTypeInlineType1": { + "description": "lorem ipsum", + "name": "RequestTypeInlineType1", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, "type_:RootType1": { + "description": "lorem ipsum", "name": "RootType1", "shape": { "type": "object", "extends": [], "properties": [ { + "description": "lorem ipsum", "key": "foo", "valueType": { "type": "primitive", @@ -16,10 +116,58 @@ } }, { + "description": "lorem ipsum", "key": "bar", "valueType": { "type": "id", - "value": "type_:InlineType1" + "value": "type_:RootType1InlineType1" + } + }, + { + "description": "lorem ipsum", + "key": "fooMap", + "valueType": { + "type": "map", + "keyType": { + "type": "primitive", + "value": { + "type": "string" + } + }, + "valueType": { + "type": "id", + "value": "type_:RootType1FooMapValue" + } + } + }, + { + "description": "lorem ipsum", + "key": "fooList", + "valueType": { + "type": "list", + "itemType": { + "type": "id", + "value": "type_:RootType1FooListItem" + } + } + }, + { + "description": "lorem ipsum", + "key": "fooSet", + "valueType": { + "type": "set", + "itemType": { + "type": "id", + "value": "type_:RootType1FooSetItem" + } + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" } } ], @@ -28,13 +176,15 @@ } } }, - "type_:InlineType1": { - "name": "InlineType1", + "type_:RootType1FooMapValue": { + "description": "lorem ipsum", + "name": "RootType1FooMapValue", "shape": { "type": "object", "extends": [], "properties": [ { + "description": "lorem ipsum", "key": "foo", "valueType": { "type": "primitive", @@ -44,10 +194,11 @@ } }, { - "key": "bar", + "description": "lorem ipsum", + "key": "ref", "valueType": { "type": "id", - "value": "type_:NestedInlineType1" + "value": "type_:ReferenceType" } } ], @@ -56,20 +207,100 @@ } } }, - "type_:InlineType2": { - "name": "InlineType2", + "type_:RootType1FooListItem": { + "description": "lorem ipsum", + "name": "RootType1FooListItem", "shape": { "type": "object", "extends": [], "properties": [ { - "key": "baz", + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:RootType1FooSetItem": { + "description": "lorem ipsum", + "name": "RootType1FooSetItem", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:RootType1InlineType1": { + "description": "lorem ipsum", + "name": "RootType1InlineType1", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", "valueType": { "type": "primitive", "value": { "type": "string" } } + }, + { + "description": "lorem ipsum", + "key": "bar", + "valueType": { + "type": "id", + "value": "type_:RootType1InlineType1NestedInlineType1" + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } } ], "extraProperties": { @@ -77,13 +308,15 @@ } } }, - "type_:NestedInlineType1": { - "name": "NestedInlineType1", + "type_:RootType1InlineType1NestedInlineType1": { + "description": "lorem ipsum", + "name": "RootType1InlineType1NestedInlineType1", "shape": { "type": "object", "extends": [], "properties": [ { + "description": "lorem ipsum", "key": "foo", "valueType": { "type": "primitive", @@ -93,6 +326,7 @@ } }, { + "description": "lorem ipsum", "key": "bar", "valueType": { "type": "primitive", @@ -102,10 +336,19 @@ } }, { + "description": "lorem ipsum", "key": "myEnum", "valueType": { "type": "id", - "value": "type_:InlineEnum" + "value": "type_:InlineEnum1" + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" } } ], @@ -114,26 +357,39 @@ } } }, - "type_:InlinedDiscriminatedUnion1": { - "name": "InlinedDiscriminatedUnion1", + "type_:DiscriminatedUnion1": { + "description": "lorem ipsum", + "name": "DiscriminatedUnion1", "shape": { "type": "discriminatedUnion", "discriminant": "type", "variants": [ { + "description": "lorem ipsum", "discriminantValue": "type1", "additionalProperties": { "extends": [ - "type_:InlineType1" + "type_:DiscriminatedUnion1InlineType1" ], "properties": [] } }, { + "description": "lorem ipsum", "discriminantValue": "type2", "additionalProperties": { "extends": [ - "type_:InlineType2" + "type_:DiscriminatedUnion1InlineType2" + ], + "properties": [] + } + }, + { + "description": "lorem ipsum", + "discriminantValue": "ref", + "additionalProperties": { + "extends": [ + "type_:ReferenceType" ], "properties": [] } @@ -141,72 +397,645 @@ ] } }, - "type_:InlinedUndiscriminatedUnion1": { - "name": "InlinedUndiscriminatedUnion1", + "type_:DiscriminatedUnion1InlineType1": { + "description": "lorem ipsum", + "name": "DiscriminatedUnion1InlineType1", "shape": { - "type": "undiscriminatedUnion", - "variants": [ + "type": "object", + "extends": [], + "properties": [ { - "typeName": "InlineType1", - "type": { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "bar", + "valueType": { "type": "id", - "value": "type_:InlineType1" + "value": "type_:DiscriminatedUnion1InlineType1InlineType1" } }, { - "typeName": "InlineType2", - "type": { + "description": "lorem ipsum", + "key": "ref", + "valueType": { "type": "id", - "value": "type_:InlineType2" + "value": "type_:ReferenceType" } } - ] + ], + "extraProperties": { + "type": "unknown" + } } }, - "type_:InlineEnum": { - "name": "InlineEnum", + "type_:DiscriminatedUnion1InlineType1InlineType1": { + "description": "lorem ipsum", + "name": "DiscriminatedUnion1InlineType1InlineType1", "shape": { - "type": "enum", - "values": [ + "type": "object", + "extends": [], + "properties": [ { - "value": "SUNNY" + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } }, { - "value": "CLOUDY" - }, + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:DiscriminatedUnion1InlineType2": { + "description": "lorem ipsum", + "name": "DiscriminatedUnion1InlineType2", + "shape": { + "type": "object", + "extends": [], + "properties": [ { - "value": "RAINING" + "description": "lorem ipsum", + "key": "baz", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } }, { - "value": "SNOWING" + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } } - ] + ], + "extraProperties": { + "type": "unknown" + } } - } - }, - "subpackages": {}, - "rootPackage": { - "endpoints": [ - { - "auth": false, - "method": "POST", - "id": "getRoot", - "originalEndpointId": "endpoint_.getRoot", - "name": "Get Root", - "path": { - "pathParameters": [], - "parts": [ - { - "type": "literal", - "value": "/root" - }, - { - "type": "literal", - "value": "/root" - } - ] - }, - "queryParameters": [], + }, + "type_:UndiscriminatedUnion1": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1", + "shape": { + "type": "undiscriminatedUnion", + "variants": [ + { + "typeName": "UndiscriminatedUnion1InlineType1", + "description": "lorem ipsum", + "type": { + "type": "id", + "value": "type_:UndiscriminatedUnion1InlineType1" + } + }, + { + "typeName": "UndiscriminatedUnion1InlineType2", + "description": "lorem ipsum", + "type": { + "type": "id", + "value": "type_:UndiscriminatedUnion1InlineType2" + } + }, + { + "typeName": "UndiscriminatedUnion1DiscriminatedUnion1", + "description": "lorem ipsum", + "type": { + "type": "id", + "value": "type_:UndiscriminatedUnion1DiscriminatedUnion1" + } + }, + { + "typeName": "UndiscriminatedUnion1DiscriminatedUnion1", + "description": "lorem ipsum", + "type": { + "type": "id", + "value": "type_:UndiscriminatedUnion1DiscriminatedUnion1" + } + }, + { + "typeName": "UndiscriminatedUnion1InlineEnum1", + "description": "lorem ipsum", + "type": { + "type": "id", + "value": "type_:UndiscriminatedUnion1InlineEnum1" + } + }, + { + "typeName": "UserId", + "description": "lorem ipsum", + "type": { + "type": "id", + "value": "type_:UserId" + } + }, + { + "description": "lorem ipsum", + "type": { + "type": "list", + "itemType": { + "type": "id", + "value": "type_:UndiscriminatedUnion1InlineListItem1" + } + } + }, + { + "description": "lorem ipsum", + "type": { + "type": "set", + "itemType": { + "type": "id", + "value": "type_:UndiscriminatedUnion1InlineSetItem1" + } + } + }, + { + "description": "lorem ipsum", + "type": { + "type": "map", + "keyType": { + "type": "primitive", + "value": { + "type": "string" + } + }, + "valueType": { + "type": "id", + "value": "type_:UndiscriminatedUnion1InlineMapItem1" + } + } + }, + { + "typeName": "ReferenceType", + "description": "lorem ipsum", + "type": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ] + } + }, + "type_:UndiscriminatedUnion1InlineType1": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1InlineType1", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "bar", + "valueType": { + "type": "id", + "value": "type_:UndiscriminatedUnion1InlineType1InlineType1" + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:UndiscriminatedUnion1InlineType1InlineType1": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1InlineType1InlineType1", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:UndiscriminatedUnion1InlineType2": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1InlineType2", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "baz", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:InlineEnum1": { + "description": "lorem ipsum", + "name": "InlineEnum1", + "shape": { + "type": "enum", + "values": [ + { + "value": "SUNNY" + }, + { + "value": "CLOUDY" + }, + { + "value": "RAINING" + }, + { + "value": "SNOWING" + } + ] + } + }, + "type_:UndiscriminatedUnion1DiscriminatedUnion1": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1DiscriminatedUnion1", + "shape": { + "type": "discriminatedUnion", + "discriminant": "type", + "variants": [ + { + "description": "lorem ipsum", + "discriminantValue": "type1", + "additionalProperties": { + "extends": [ + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType1" + ], + "properties": [] + } + }, + { + "description": "lorem ipsum", + "discriminantValue": "type2", + "additionalProperties": { + "extends": [ + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType2" + ], + "properties": [] + } + }, + { + "description": "lorem ipsum", + "discriminantValue": "ref", + "additionalProperties": { + "extends": [ + "type_:ReferenceType" + ], + "properties": [] + } + } + ] + } + }, + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType1": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1DiscriminatedUnion1InlineType1", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "bar", + "valueType": { + "type": "id", + "value": "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1" + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType2": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1DiscriminatedUnion1InlineType2", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "baz", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:UndiscriminatedUnion1InlineEnum1": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1InlineEnum1", + "shape": { + "type": "enum", + "values": [ + { + "value": "SUNNY" + }, + { + "value": "CLOUDY" + }, + { + "value": "RAINING" + }, + { + "value": "SNOWING" + } + ] + } + }, + "type_:UserId": { + "description": "lorem ipsum", + "name": "UserId", + "shape": { + "type": "alias", + "value": { + "type": "primitive", + "value": { + "type": "string" + } + } + } + }, + "type_:UndiscriminatedUnion1InlineListItem1": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1InlineListItem1", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:UndiscriminatedUnion1InlineSetItem1": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1InlineSetItem1", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:UndiscriminatedUnion1InlineMapItem1": { + "description": "lorem ipsum", + "name": "UndiscriminatedUnion1InlineMapItem1", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + }, + { + "description": "lorem ipsum", + "key": "ref", + "valueType": { + "type": "id", + "value": "type_:ReferenceType" + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + }, + "type_:ReferenceType": { + "description": "lorem ipsum", + "name": "ReferenceType", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "description": "lorem ipsum", + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + } + ], + "extraProperties": { + "type": "unknown" + } + } + } + }, + "subpackages": {}, + "rootPackage": { + "endpoints": [ + { + "auth": false, + "method": "POST", + "id": "getRoot", + "originalEndpointId": "endpoint_.getRoot", + "name": "Get Root", + "path": { + "pathParameters": [], + "parts": [ + { + "type": "literal", + "value": "/root" + }, + { + "type": "literal", + "value": "/root" + } + ] + }, + "queryParameters": [], "headers": [], "request": { "type": { @@ -220,7 +1049,7 @@ "key": "bar", "valueType": { "type": "id", - "value": "type_:InlineType1" + "value": "type_:RequestTypeInlineType1" } }, { @@ -254,12 +1083,7 @@ "headers": {}, "requestBody": { "bar": { - "foo": "foo", - "bar": { - "foo": "foo", - "bar": "bar", - "myEnum": "SUNNY" - } + "foo": "foo" }, "foo": "foo" }, @@ -267,12 +1091,7 @@ "type": "json", "value": { "bar": { - "foo": "foo", - "bar": { - "foo": "foo", - "bar": "bar", - "myEnum": "SUNNY" - } + "foo": "foo" }, "foo": "foo" } @@ -285,8 +1104,47 @@ "bar": { "foo": "foo", "bar": "bar", - "myEnum": "SUNNY" + "myEnum": "SUNNY", + "ref": { + "foo": "foo" + } + }, + "ref": { + "foo": "foo" + } + }, + "fooMap": { + "fooMap": { + "foo": "foo", + "ref": { + "foo": "foo" + } + } + }, + "fooList": [ + { + "foo": "foo", + "ref": { + "foo": "foo" + } + }, + { + "foo": "foo", + "ref": { + "foo": "foo" + } + } + ], + "fooSet": [ + { + "foo": "foo", + "ref": { + "foo": "foo" + } } + ], + "ref": { + "foo": "foo" } }, "responseBodyV3": { @@ -298,11 +1156,240 @@ "bar": { "foo": "foo", "bar": "bar", - "myEnum": "SUNNY" + "myEnum": "SUNNY", + "ref": { + "foo": "foo" + } + }, + "ref": { + "foo": "foo" + } + }, + "fooMap": { + "fooMap": { + "foo": "foo", + "ref": { + "foo": "foo" + } + } + }, + "fooList": [ + { + "foo": "foo", + "ref": { + "foo": "foo" + } + }, + { + "foo": "foo", + "ref": { + "foo": "foo" + } + } + ], + "fooSet": [ + { + "foo": "foo", + "ref": { + "foo": "foo" + } + } + ], + "ref": { + "foo": "foo" + } + } + }, + "codeSamples": [] + } + ] + }, + { + "auth": false, + "method": "POST", + "id": "getDiscriminatedUnion", + "originalEndpointId": "endpoint_.getDiscriminatedUnion", + "name": "Get Discriminated Union", + "path": { + "pathParameters": [], + "parts": [ + { + "type": "literal", + "value": "/root" + }, + { + "type": "literal", + "value": "/discriminated-union" + } + ] + }, + "queryParameters": [], + "headers": [], + "request": { + "type": { + "type": "json", + "contentType": "application/json", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "key": "bar", + "valueType": { + "type": "id", + "value": "type_:DiscriminatedUnion1" + } + }, + { + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } + } + } + ] + } + } + }, + "errorsV2": [], + "examples": [ + { + "path": "/root/discriminated-union", + "pathParameters": {}, + "queryParameters": {}, + "headers": {}, + "requestBody": { + "bar": { + "type": "type1", + "foo": "foo", + "bar": { + "foo": "foo", + "ref": { + "foo": "foo" + } + }, + "ref": { + "foo": "foo" + } + }, + "foo": "foo" + }, + "requestBodyV3": { + "type": "json", + "value": { + "bar": { + "type": "type1", + "foo": "foo", + "bar": { + "foo": "foo", + "ref": { + "foo": "foo" + } + }, + "ref": { + "foo": "foo" + } + }, + "foo": "foo" + } + }, + "responseStatusCode": 204, + "codeSamples": [] + } + ] + }, + { + "auth": false, + "method": "POST", + "id": "getUndiscriminatedUnion", + "originalEndpointId": "endpoint_.getUndiscriminatedUnion", + "name": "Get Undiscriminated Union", + "path": { + "pathParameters": [], + "parts": [ + { + "type": "literal", + "value": "/root" + }, + { + "type": "literal", + "value": "/undiscriminated-union" + } + ] + }, + "queryParameters": [], + "headers": [], + "request": { + "type": { + "type": "json", + "contentType": "application/json", + "shape": { + "type": "object", + "extends": [], + "properties": [ + { + "key": "bar", + "valueType": { + "type": "id", + "value": "type_:UndiscriminatedUnion1" + } + }, + { + "key": "foo", + "valueType": { + "type": "primitive", + "value": { + "type": "string" + } } } + ] + } + } + }, + "errorsV2": [], + "examples": [ + { + "path": "/root/undiscriminated-union", + "pathParameters": {}, + "queryParameters": {}, + "headers": {}, + "requestBody": { + "bar": { + "foo": "foo", + "bar": { + "foo": "foo", + "ref": { + "foo": "foo" + } + }, + "ref": { + "foo": "foo" + } + }, + "foo": "foo" + }, + "requestBodyV3": { + "type": "json", + "value": { + "bar": { + "foo": "foo", + "bar": { + "foo": "foo", + "ref": { + "foo": "foo" + } + }, + "ref": { + "foo": "foo" + } + }, + "foo": "foo" } }, + "responseStatusCode": 204, "codeSamples": [] } ] @@ -311,13 +1398,36 @@ "webhooks": [], "websockets": [], "types": [ + "type_:AliasMapInline", + "type_:AliasSetInline", + "type_:AliasListInline", + "type_:AliasInlineValue", + "type_:RequestTypeInlineType1", "type_:RootType1", - "type_:InlineType1", - "type_:InlineType2", - "type_:NestedInlineType1", - "type_:InlinedDiscriminatedUnion1", - "type_:InlinedUndiscriminatedUnion1", - "type_:InlineEnum" + "type_:RootType1FooMapValue", + "type_:RootType1FooListItem", + "type_:RootType1FooSetItem", + "type_:RootType1InlineType1", + "type_:RootType1InlineType1NestedInlineType1", + "type_:DiscriminatedUnion1", + "type_:DiscriminatedUnion1InlineType1", + "type_:DiscriminatedUnion1InlineType1InlineType1", + "type_:DiscriminatedUnion1InlineType2", + "type_:UndiscriminatedUnion1", + "type_:UndiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1InlineType1InlineType1", + "type_:UndiscriminatedUnion1InlineType2", + "type_:InlineEnum1", + "type_:UndiscriminatedUnion1DiscriminatedUnion1", + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1", + "type_:UndiscriminatedUnion1DiscriminatedUnion1InlineType2", + "type_:UndiscriminatedUnion1InlineEnum1", + "type_:UserId", + "type_:UndiscriminatedUnion1InlineListItem1", + "type_:UndiscriminatedUnion1InlineSetItem1", + "type_:UndiscriminatedUnion1InlineMapItem1", + "type_:ReferenceType" ], "subpackages": [] }, diff --git a/packages/commons/core-utils/src/index.ts b/packages/commons/core-utils/src/index.ts index f130697333c..7035a1d36e5 100644 --- a/packages/commons/core-utils/src/index.ts +++ b/packages/commons/core-utils/src/index.ts @@ -27,3 +27,4 @@ export { stripLeadingSlash } from "./stripLeadingSlash"; export { parseEndpointLocator } from "./parseEndpointLocator"; export { removeSuffix } from "./removeSuffix"; export { validateAgainstJsonSchema } from "./validateAgainstJsonSchema"; +export { type SetRequired } from "./setRequired"; diff --git a/packages/commons/core-utils/src/setRequired.ts b/packages/commons/core-utils/src/setRequired.ts new file mode 100644 index 00000000000..308165d6797 --- /dev/null +++ b/packages/commons/core-utils/src/setRequired.ts @@ -0,0 +1,3 @@ +type Required = T & { [P in K]-?: T[P] }; + +export type SetRequired = Pick> & Required; diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index d5c3f260a3b..25745557ccc 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1393,8 +1393,8 @@ importers: specifier: workspace:* version: link:../../../packages/commons/core-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@types/jest': specifier: ^29.5.12 version: 29.5.12 @@ -1426,8 +1426,8 @@ importers: specifier: ^0.0.898 version: 0.0.898 '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-generator-cli': specifier: workspace:* version: link:../../utils/abstract-generator-cli @@ -1492,8 +1492,8 @@ importers: specifier: workspace:* version: link:../../../../packages/commons/core-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-schema-generator': specifier: workspace:* version: link:../../utils/abstract-schema-generator @@ -1535,8 +1535,8 @@ importers: generators/typescript/express/express-error-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-error-class-generator': specifier: workspace:* version: link:../../utils/abstract-error-class-generator @@ -1581,8 +1581,8 @@ importers: specifier: workspace:* version: link:../../../../packages/commons/core-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-schema-generator': specifier: workspace:* version: link:../../utils/abstract-schema-generator @@ -1624,8 +1624,8 @@ importers: generators/typescript/express/express-inlined-request-body-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -1661,8 +1661,8 @@ importers: generators/typescript/express/express-inlined-request-body-schema-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-schema-generator': specifier: workspace:* version: link:../../utils/abstract-schema-generator @@ -1704,8 +1704,8 @@ importers: generators/typescript/express/express-register-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -1753,8 +1753,8 @@ importers: generators/typescript/express/express-service-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -1801,9 +1801,12 @@ importers: '@fern-api/fs-utils': specifier: workspace:* version: link:../../../../packages/commons/fs-utils + '@fern-api/logger': + specifier: workspace:* + version: link:../../../../packages/cli/logger '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -1921,8 +1924,8 @@ importers: generators/typescript/model/type-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -1963,9 +1966,12 @@ importers: generators/typescript/model/type-reference-converters: dependencies: + '@fern-api/core-utils': + specifier: workspace:* + version: link:../../../../packages/commons/core-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -2007,8 +2013,8 @@ importers: specifier: workspace:* version: link:../../../../packages/commons/core-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -2047,8 +2053,8 @@ importers: generators/typescript/model/type-schema-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-schema-generator': specifier: workspace:* version: link:../../utils/abstract-schema-generator @@ -2096,8 +2102,8 @@ importers: specifier: workspace:* version: link:../../../../packages/commons/core-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -2136,8 +2142,8 @@ importers: generators/typescript/model/union-schema-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-schema-generator': specifier: workspace:* version: link:../../utils/abstract-schema-generator @@ -2261,8 +2267,8 @@ importers: specifier: workspace:* version: link:../../../../packages/commons/fs-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-generator-cli': specifier: workspace:* version: link:../../utils/abstract-generator-cli @@ -2327,8 +2333,8 @@ importers: specifier: workspace:* version: link:../../../../packages/commons/core-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -2373,8 +2379,8 @@ importers: generators/typescript/sdk/endpoint-error-union-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -2419,8 +2425,8 @@ importers: generators/typescript/sdk/environments-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -2480,8 +2486,8 @@ importers: specifier: ^0.0.898 version: 0.0.898 '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-fern/snippet-sdk': specifier: ^0.0.5526 version: 0.0.5526 @@ -2629,8 +2635,8 @@ importers: specifier: workspace:* version: link:../../../../packages/commons/core-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../../utils/commons @@ -2672,8 +2678,8 @@ importers: specifier: workspace:* version: link:../../../../packages/commons/core-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-schema-generator': specifier: workspace:* version: link:../../utils/abstract-schema-generator @@ -2721,8 +2727,8 @@ importers: generators/typescript/sdk/sdk-error-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-error-class-generator': specifier: workspace:* version: link:../../utils/abstract-error-class-generator @@ -2767,8 +2773,8 @@ importers: specifier: workspace:* version: link:../../../../packages/commons/core-utils '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-schema-generator': specifier: workspace:* version: link:../../utils/abstract-schema-generator @@ -2810,8 +2816,8 @@ importers: generators/typescript/sdk/sdk-inlined-request-body-schema-generator: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/abstract-schema-generator': specifier: workspace:* version: link:../../utils/abstract-schema-generator @@ -2902,8 +2908,8 @@ importers: specifier: ^0.0.898 version: 0.0.898 '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../commons @@ -2988,8 +2994,8 @@ importers: specifier: workspace:* version: link:../../../../packages/commons/logging-execa '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/fetcher': specifier: workspace:* version: link:../core-utilities/fetcher @@ -3082,8 +3088,8 @@ importers: specifier: ^0.0.898 version: 0.0.898 '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../commons @@ -3358,8 +3364,8 @@ importers: generators/typescript/utils/resolvers: dependencies: '@fern-fern/ir-sdk': - specifier: 53.8.0 - version: 53.8.0 + specifier: 53.23.0 + version: 53.23.0 '@fern-typescript/commons': specifier: workspace:* version: link:../commons @@ -4162,6 +4168,8 @@ importers: specifier: ^2.1.4 version: 2.1.4(@types/node@18.7.18)(jsdom@20.0.3)(sass@1.72.0)(terser@5.31.5) + packages/cli/cli/dist/local: {} + packages/cli/configuration: dependencies: '@fern-api/core-utils': @@ -8052,9 +8060,6 @@ packages: '@fern-fern/ir-sdk@53.7.0': resolution: {integrity: sha512-PoCj8yOep3kFeDZYORAzqPwVtCSNmbT2SfR/AoxKCcikeZ5i+4Um4ZXx1e6UaAy7dIYF5kWeRc6lptFBRoj7Gw==} - '@fern-fern/ir-sdk@53.8.0': - resolution: {integrity: sha512-h5q0DuXyeCs61Nl0ueBYMtNhG5uiSKJqdqtgTON5RWjGH0aJAhGMfoRXoq5Sar4HLWHhbK/t/290O/iCJLE0hQ==} - '@fern-fern/ir-sdk@53.9.0': resolution: {integrity: sha512-WAXXL+XVnDO4a3nfZRbRTr0+xz88jIYEZYTbJ7sYWLS7DLjmU780EFMMwO8ySmCdI0R2yRfeSY0qaGvuomXg6g==} @@ -15256,8 +15261,6 @@ snapshots: '@fern-fern/ir-sdk@53.7.0': {} - '@fern-fern/ir-sdk@53.8.0': {} - '@fern-fern/ir-sdk@53.9.0': {} '@fern-fern/ir-v1-model@0.0.2': {} diff --git a/seed/ts-express/circular-references-advanced/api/resources/ast/types/ContainerValue.ts b/seed/ts-express/circular-references-advanced/api/resources/ast/types/ContainerValue.ts index 04cfa4e089e..0377dd788a2 100644 --- a/seed/ts-express/circular-references-advanced/api/resources/ast/types/ContainerValue.ts +++ b/seed/ts-express/circular-references-advanced/api/resources/ast/types/ContainerValue.ts @@ -6,13 +6,13 @@ import * as SeedApi from "../../../index"; export type ContainerValue = SeedApi.ContainerValue.List | SeedApi.ContainerValue.Optional; -export declare namespace ContainerValue { - interface List { +export namespace ContainerValue { + export interface List { type: "list"; value: SeedApi.FieldValue[]; } - interface Optional { + export interface Optional { type: "optional"; value?: SeedApi.FieldValue; } diff --git a/seed/ts-express/circular-references-advanced/api/resources/ast/types/FieldValue.ts b/seed/ts-express/circular-references-advanced/api/resources/ast/types/FieldValue.ts index 30d0c699a91..0b114997310 100644 --- a/seed/ts-express/circular-references-advanced/api/resources/ast/types/FieldValue.ts +++ b/seed/ts-express/circular-references-advanced/api/resources/ast/types/FieldValue.ts @@ -9,17 +9,17 @@ export type FieldValue = | SeedApi.FieldValue.ObjectValue | SeedApi.FieldValue.ContainerValue; -export declare namespace FieldValue { - interface PrimitiveValue { +export namespace FieldValue { + export interface PrimitiveValue { type: "primitive_value"; value: SeedApi.PrimitiveValue; } - interface ObjectValue extends SeedApi.ObjectValue { + export interface ObjectValue extends SeedApi.ObjectValue { type: "object_value"; } - interface ContainerValue { + export interface ContainerValue { type: "container_value"; value: SeedApi.ContainerValue; } diff --git a/seed/ts-express/circular-references-advanced/api/resources/ast/types/PrimitiveValue.ts b/seed/ts-express/circular-references-advanced/api/resources/ast/types/PrimitiveValue.ts index 58baf11d749..1b01851df2f 100644 --- a/seed/ts-express/circular-references-advanced/api/resources/ast/types/PrimitiveValue.ts +++ b/seed/ts-express/circular-references-advanced/api/resources/ast/types/PrimitiveValue.ts @@ -3,7 +3,6 @@ */ export type PrimitiveValue = "STRING" | "NUMBER"; - export const PrimitiveValue = { String: "STRING", Number: "NUMBER", diff --git a/seed/ts-express/circular-references/api/resources/ast/types/ContainerValue.ts b/seed/ts-express/circular-references/api/resources/ast/types/ContainerValue.ts index 04cfa4e089e..0377dd788a2 100644 --- a/seed/ts-express/circular-references/api/resources/ast/types/ContainerValue.ts +++ b/seed/ts-express/circular-references/api/resources/ast/types/ContainerValue.ts @@ -6,13 +6,13 @@ import * as SeedApi from "../../../index"; export type ContainerValue = SeedApi.ContainerValue.List | SeedApi.ContainerValue.Optional; -export declare namespace ContainerValue { - interface List { +export namespace ContainerValue { + export interface List { type: "list"; value: SeedApi.FieldValue[]; } - interface Optional { + export interface Optional { type: "optional"; value?: SeedApi.FieldValue; } diff --git a/seed/ts-express/circular-references/api/resources/ast/types/FieldValue.ts b/seed/ts-express/circular-references/api/resources/ast/types/FieldValue.ts index 30d0c699a91..0b114997310 100644 --- a/seed/ts-express/circular-references/api/resources/ast/types/FieldValue.ts +++ b/seed/ts-express/circular-references/api/resources/ast/types/FieldValue.ts @@ -9,17 +9,17 @@ export type FieldValue = | SeedApi.FieldValue.ObjectValue | SeedApi.FieldValue.ContainerValue; -export declare namespace FieldValue { - interface PrimitiveValue { +export namespace FieldValue { + export interface PrimitiveValue { type: "primitive_value"; value: SeedApi.PrimitiveValue; } - interface ObjectValue extends SeedApi.ObjectValue { + export interface ObjectValue extends SeedApi.ObjectValue { type: "object_value"; } - interface ContainerValue { + export interface ContainerValue { type: "container_value"; value: SeedApi.ContainerValue; } diff --git a/seed/ts-express/circular-references/api/resources/ast/types/PrimitiveValue.ts b/seed/ts-express/circular-references/api/resources/ast/types/PrimitiveValue.ts index 58baf11d749..1b01851df2f 100644 --- a/seed/ts-express/circular-references/api/resources/ast/types/PrimitiveValue.ts +++ b/seed/ts-express/circular-references/api/resources/ast/types/PrimitiveValue.ts @@ -3,7 +3,6 @@ */ export type PrimitiveValue = "STRING" | "NUMBER"; - export const PrimitiveValue = { String: "STRING", Number: "NUMBER", diff --git a/seed/ts-express/enum/api/types/Color.ts b/seed/ts-express/enum/api/types/Color.ts index 2fa67f67f83..fab9171627b 100644 --- a/seed/ts-express/enum/api/types/Color.ts +++ b/seed/ts-express/enum/api/types/Color.ts @@ -7,7 +7,6 @@ * SeedEnum.Color.Red */ export type Color = "red" | "blue"; - export const Color = { Red: "red", Blue: "blue", diff --git a/seed/ts-express/enum/api/types/Operand.ts b/seed/ts-express/enum/api/types/Operand.ts index b527c10e61b..b023f9444b9 100644 --- a/seed/ts-express/enum/api/types/Operand.ts +++ b/seed/ts-express/enum/api/types/Operand.ts @@ -19,7 +19,6 @@ export type Operand = * The name and value should be similar * are similar for less than. */ | "less_than"; - export const Operand = { GreaterThan: ">", EqualTo: "=", diff --git a/seed/ts-express/examples/api/resources/commons/resources/types/types/Data.ts b/seed/ts-express/examples/api/resources/commons/resources/types/types/Data.ts index ca73fda6852..ff6636b20e7 100644 --- a/seed/ts-express/examples/api/resources/commons/resources/types/types/Data.ts +++ b/seed/ts-express/examples/api/resources/commons/resources/types/types/Data.ts @@ -13,13 +13,13 @@ import * as SeedExamples from "../../../../../index"; */ export type Data = SeedExamples.commons.Data.String | SeedExamples.commons.Data.Base64; -export declare namespace Data { - interface String { +export namespace Data { + export interface String { type: "string"; value: string; } - interface Base64 { + export interface Base64 { type: "base64"; value: string; } diff --git a/seed/ts-express/examples/api/resources/commons/resources/types/types/EventInfo.ts b/seed/ts-express/examples/api/resources/commons/resources/types/types/EventInfo.ts index 559f7726408..619f49001c6 100644 --- a/seed/ts-express/examples/api/resources/commons/resources/types/types/EventInfo.ts +++ b/seed/ts-express/examples/api/resources/commons/resources/types/types/EventInfo.ts @@ -17,12 +17,12 @@ import * as SeedExamples from "../../../../../index"; */ export type EventInfo = SeedExamples.commons.EventInfo.Metadata | SeedExamples.commons.EventInfo.Tag; -export declare namespace EventInfo { - interface Metadata extends SeedExamples.commons.Metadata { +export namespace EventInfo { + export interface Metadata extends SeedExamples.commons.Metadata { type: "metadata"; } - interface Tag { + export interface Tag { type: "tag"; value: SeedExamples.commons.Tag; } diff --git a/seed/ts-express/examples/api/resources/types/types/Exception.ts b/seed/ts-express/examples/api/resources/types/types/Exception.ts index e83b4952829..11ef21c1f01 100644 --- a/seed/ts-express/examples/api/resources/types/types/Exception.ts +++ b/seed/ts-express/examples/api/resources/types/types/Exception.ts @@ -15,12 +15,12 @@ import * as SeedExamples from "../../../index"; */ export type Exception = SeedExamples.Exception.Generic | SeedExamples.Exception.Timeout; -export declare namespace Exception { - interface Generic extends SeedExamples.ExceptionInfo { +export namespace Exception { + export interface Generic extends SeedExamples.ExceptionInfo { type: "generic"; } - interface Timeout { + export interface Timeout { type: "timeout"; } } diff --git a/seed/ts-express/examples/api/resources/types/types/Metadata.ts b/seed/ts-express/examples/api/resources/types/types/Metadata.ts index d35087a1c66..b99d4869a53 100644 --- a/seed/ts-express/examples/api/resources/types/types/Metadata.ts +++ b/seed/ts-express/examples/api/resources/types/types/Metadata.ts @@ -13,13 +13,13 @@ import * as SeedExamples from "../../../index"; */ export type Metadata = SeedExamples.Metadata.Html | SeedExamples.Metadata.Markdown; -export declare namespace Metadata { - interface Html extends _Base { +export namespace Metadata { + export interface Html extends _Base { type: "html"; value: string; } - interface Markdown extends _Base { + export interface Markdown extends _Base { type: "markdown"; value: string; } diff --git a/seed/ts-express/examples/api/resources/types/types/MigrationStatus.ts b/seed/ts-express/examples/api/resources/types/types/MigrationStatus.ts index c45e7382155..11502aa2e9d 100644 --- a/seed/ts-express/examples/api/resources/types/types/MigrationStatus.ts +++ b/seed/ts-express/examples/api/resources/types/types/MigrationStatus.ts @@ -17,7 +17,6 @@ export type MigrationStatus = * The migration failed. */ | "FAILED" | "FINISHED"; - export const MigrationStatus = { Running: "RUNNING", Failed: "FAILED", diff --git a/seed/ts-express/examples/api/resources/types/types/Test.ts b/seed/ts-express/examples/api/resources/types/types/Test.ts index c1d733da0eb..7fcc346381e 100644 --- a/seed/ts-express/examples/api/resources/types/types/Test.ts +++ b/seed/ts-express/examples/api/resources/types/types/Test.ts @@ -19,13 +19,13 @@ import * as SeedExamples from "../../../index"; */ export type Test = SeedExamples.Test.And | SeedExamples.Test.Or; -export declare namespace Test { - interface And { +export namespace Test { + export interface And { type: "and"; value: boolean; } - interface Or { + export interface Or { type: "or"; value: boolean; } diff --git a/seed/ts-express/examples/api/types/BasicType.ts b/seed/ts-express/examples/api/types/BasicType.ts index 32e12a88016..d20f2862feb 100644 --- a/seed/ts-express/examples/api/types/BasicType.ts +++ b/seed/ts-express/examples/api/types/BasicType.ts @@ -3,7 +3,6 @@ */ export type BasicType = "primitive" | "literal"; - export const BasicType = { Primitive: "primitive", Literal: "literal", diff --git a/seed/ts-express/examples/api/types/ComplexType.ts b/seed/ts-express/examples/api/types/ComplexType.ts index f61ca784ac5..4ef541c74d4 100644 --- a/seed/ts-express/examples/api/types/ComplexType.ts +++ b/seed/ts-express/examples/api/types/ComplexType.ts @@ -3,7 +3,6 @@ */ export type ComplexType = "object" | "union" | "unknown"; - export const ComplexType = { Object: "object", Union: "union", diff --git a/seed/ts-express/exhaustive/allow-extra-fields/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-express/exhaustive/allow-extra-fields/api/resources/types/resources/enum/types/WeatherReport.ts index df4b29b1c64..6a0091bb8c0 100644 --- a/seed/ts-express/exhaustive/allow-extra-fields/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-express/exhaustive/allow-extra-fields/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", diff --git a/seed/ts-express/exhaustive/allow-extra-fields/api/resources/types/resources/union/types/Animal.ts b/seed/ts-express/exhaustive/allow-extra-fields/api/resources/types/resources/union/types/Animal.ts index b03ca8d422a..c05e5891781 100644 --- a/seed/ts-express/exhaustive/allow-extra-fields/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-express/exhaustive/allow-extra-fields/api/resources/types/resources/union/types/Animal.ts @@ -6,12 +6,12 @@ import * as SeedExhaustive from "../../../../../index"; export type Animal = SeedExhaustive.types.Animal.Dog | SeedExhaustive.types.Animal.Cat; -export declare namespace Animal { - interface Dog extends SeedExhaustive.types.Dog { +export namespace Animal { + export interface Dog extends SeedExhaustive.types.Dog { animal: "dog"; } - interface Cat extends SeedExhaustive.types.Cat { + export interface Cat extends SeedExhaustive.types.Cat { animal: "cat"; } } diff --git a/seed/ts-express/exhaustive/no-custom-config/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-express/exhaustive/no-custom-config/api/resources/types/resources/enum/types/WeatherReport.ts index df4b29b1c64..6a0091bb8c0 100644 --- a/seed/ts-express/exhaustive/no-custom-config/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-express/exhaustive/no-custom-config/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", diff --git a/seed/ts-express/exhaustive/no-custom-config/api/resources/types/resources/union/types/Animal.ts b/seed/ts-express/exhaustive/no-custom-config/api/resources/types/resources/union/types/Animal.ts index b03ca8d422a..c05e5891781 100644 --- a/seed/ts-express/exhaustive/no-custom-config/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-express/exhaustive/no-custom-config/api/resources/types/resources/union/types/Animal.ts @@ -6,12 +6,12 @@ import * as SeedExhaustive from "../../../../../index"; export type Animal = SeedExhaustive.types.Animal.Dog | SeedExhaustive.types.Animal.Cat; -export declare namespace Animal { - interface Dog extends SeedExhaustive.types.Dog { +export namespace Animal { + export interface Dog extends SeedExhaustive.types.Dog { animal: "dog"; } - interface Cat extends SeedExhaustive.types.Cat { + export interface Cat extends SeedExhaustive.types.Cat { animal: "cat"; } } diff --git a/seed/ts-express/exhaustive/no-optional-properties/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-express/exhaustive/no-optional-properties/api/resources/types/resources/enum/types/WeatherReport.ts index df4b29b1c64..6a0091bb8c0 100644 --- a/seed/ts-express/exhaustive/no-optional-properties/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-express/exhaustive/no-optional-properties/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", diff --git a/seed/ts-express/exhaustive/no-optional-properties/api/resources/types/resources/union/types/Animal.ts b/seed/ts-express/exhaustive/no-optional-properties/api/resources/types/resources/union/types/Animal.ts index b03ca8d422a..c05e5891781 100644 --- a/seed/ts-express/exhaustive/no-optional-properties/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-express/exhaustive/no-optional-properties/api/resources/types/resources/union/types/Animal.ts @@ -6,12 +6,12 @@ import * as SeedExhaustive from "../../../../../index"; export type Animal = SeedExhaustive.types.Animal.Dog | SeedExhaustive.types.Animal.Cat; -export declare namespace Animal { - interface Dog extends SeedExhaustive.types.Dog { +export namespace Animal { + export interface Dog extends SeedExhaustive.types.Dog { animal: "dog"; } - interface Cat extends SeedExhaustive.types.Cat { + export interface Cat extends SeedExhaustive.types.Cat { animal: "cat"; } } diff --git a/seed/ts-express/exhaustive/retain-original-casing/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-express/exhaustive/retain-original-casing/api/resources/types/resources/enum/types/WeatherReport.ts index df4b29b1c64..6a0091bb8c0 100644 --- a/seed/ts-express/exhaustive/retain-original-casing/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-express/exhaustive/retain-original-casing/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", diff --git a/seed/ts-express/exhaustive/retain-original-casing/api/resources/types/resources/union/types/Animal.ts b/seed/ts-express/exhaustive/retain-original-casing/api/resources/types/resources/union/types/Animal.ts index b03ca8d422a..c05e5891781 100644 --- a/seed/ts-express/exhaustive/retain-original-casing/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-express/exhaustive/retain-original-casing/api/resources/types/resources/union/types/Animal.ts @@ -6,12 +6,12 @@ import * as SeedExhaustive from "../../../../../index"; export type Animal = SeedExhaustive.types.Animal.Dog | SeedExhaustive.types.Animal.Cat; -export declare namespace Animal { - interface Dog extends SeedExhaustive.types.Dog { +export namespace Animal { + export interface Dog extends SeedExhaustive.types.Dog { animal: "dog"; } - interface Cat extends SeedExhaustive.types.Cat { + export interface Cat extends SeedExhaustive.types.Cat { animal: "cat"; } } diff --git a/seed/ts-express/exhaustive/union-utils/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-express/exhaustive/union-utils/api/resources/types/resources/enum/types/WeatherReport.ts index 4cd2ac175cf..babba9a7b3c 100644 --- a/seed/ts-express/exhaustive/union-utils/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-express/exhaustive/union-utils/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", @@ -25,7 +24,7 @@ export const WeatherReport = { }, } as const; -export declare namespace WeatherReport { +export namespace WeatherReport { interface Visitor { sunny: () => R; cloudy: () => R; diff --git a/seed/ts-express/exhaustive/union-utils/api/resources/types/resources/union/types/Animal.ts b/seed/ts-express/exhaustive/union-utils/api/resources/types/resources/union/types/Animal.ts index 08bf92a3afc..0c2188d3201 100644 --- a/seed/ts-express/exhaustive/union-utils/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-express/exhaustive/union-utils/api/resources/types/resources/union/types/Animal.ts @@ -9,16 +9,16 @@ export type Animal = | SeedExhaustive.types.Animal.Cat | SeedExhaustive.types.Animal._Unknown; -export declare namespace Animal { - interface Dog extends SeedExhaustive.types.Dog, _Utils { +export namespace Animal { + export interface Dog extends SeedExhaustive.types.Dog, _Utils { animal: "dog"; } - interface Cat extends SeedExhaustive.types.Cat, _Utils { + export interface Cat extends SeedExhaustive.types.Cat, _Utils { animal: "cat"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { animal: void; } diff --git a/seed/ts-express/idempotency-headers/api/resources/payment/types/Currency.ts b/seed/ts-express/idempotency-headers/api/resources/payment/types/Currency.ts index 16022be914e..17ebd363838 100644 --- a/seed/ts-express/idempotency-headers/api/resources/payment/types/Currency.ts +++ b/seed/ts-express/idempotency-headers/api/resources/payment/types/Currency.ts @@ -3,7 +3,6 @@ */ export type Currency = "USD" | "YEN"; - export const Currency = { Usd: "USD", Yen: "YEN", diff --git a/seed/ts-express/inline-types/.mock/definition/__package__.yml b/seed/ts-express/inline-types/.mock/definition/__package__.yml index a2a0cbfac7c..af14bf356cd 100644 --- a/seed/ts-express/inline-types/.mock/definition/__package__.yml +++ b/seed/ts-express/inline-types/.mock/definition/__package__.yml @@ -8,54 +8,358 @@ service: request: body: properties: - bar: InlineType1 + bar: RequestTypeInlineType1 foo: string content-type: application/json name: PostRootRequest response: RootType1 + getDiscriminatedUnion: + path: /discriminated-union + method: POST + request: + body: + properties: + bar: DiscriminatedUnion1 + foo: string + content-type: application/json + name: GetDiscriminatedUnionRequest + getUndiscriminatedUnion: + path: /undiscriminated-union + method: POST + request: + body: + properties: + bar: UndiscriminatedUnion1 + foo: string + content-type: application/json + name: GetUndiscriminatedUnionRequest types: - RootType1: + # this is also the type that would be produced by + AliasMapInline: map + AliasSetInline: set + AliasListInline: list + + AliasInlineValue: + inline: true properties: foo: string - bar: InlineType1 + bar: string - InlineType1: + RequestTypeInlineType1: inline: true + docs: lorem ipsum properties: - foo: string + foo: + type: string + docs: lorem ipsum + + RootType1: + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum bar: - type: NestedInlineType1 + type: RootType1InlineType1 + docs: lorem ipsum + fooMap: + type: map + docs: lorem ipsum + fooList: + type: list + docs: lorem ipsum + fooSet: + type: set + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum - InlineType2: + RootType1FooMapValue: inline: true + docs: lorem ipsum properties: - baz: string + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum - NestedInlineType1: + RootType1FooListItem: inline: true + docs: lorem ipsum properties: - foo: string - bar: string - myEnum: InlineEnum + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum - InlinedDiscriminatedUnion1: + RootType1FooSetItem: inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: RootType1InlineType1NestedInlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1InlineType1NestedInlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: string + docs: lorem ipsum + myEnum: + type: InlineEnum1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1: + inline: true + docs: lorem ipsum union: - type1: InlineType1 - type2: InlineType2 + type1: + type: DiscriminatedUnion1InlineType1 + docs: lorem ipsum + type2: + type: DiscriminatedUnion1InlineType2 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: DiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum - InlinedUndiscriminatedUnion1: + UndiscriminatedUnion1: inline: true + docs: lorem ipsum discriminated: false union: - - type: InlineType1 - - type: InlineType2 + - type: UndiscriminatedUnion1InlineType1 + docs: lorem ipsum + - type: UndiscriminatedUnion1InlineType2 + docs: lorem ipsum + - type: UndiscriminatedUnion1DiscriminatedUnion1 + docs: lorem ipsum + - type: UndiscriminatedUnion1DiscriminatedUnion1 + docs: lorem ipsum + - type: UndiscriminatedUnion1InlineEnum1 + docs: lorem ipsum + - type: UserId + docs: lorem ipsum + - type: list + docs: lorem ipsum + - type: set + docs: lorem ipsum + - type: map + docs: lorem ipsum + - type: ReferenceType + docs: lorem ipsum - InlineEnum: + UndiscriminatedUnion1InlineType1: inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: UndiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + InlineEnum1: + inline: true + docs: lorem ipsum + enum: + - SUNNY + - CLOUDY + - RAINING + - SNOWING + + UndiscriminatedUnion1DiscriminatedUnion1: + inline: true + docs: lorem ipsum + union: + type1: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType1 + docs: lorem ipsum + type2: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType2 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineEnum1: + inline: true + docs: lorem ipsum enum: - SUNNY - CLOUDY - RAINING - SNOWING + + UserId: + type: string + docs: lorem ipsum + + UndiscriminatedUnion1InlineListItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineSetItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineMapItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + ReferenceType: + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum diff --git a/seed/ts-express/inline-types/.mock/ir.json b/seed/ts-express/inline-types/.mock/ir.json new file mode 100644 index 00000000000..00d22b232be --- /dev/null +++ b/seed/ts-express/inline-types/.mock/ir.json @@ -0,0 +1,4159 @@ +{ + "fdrApiDefinitionId": null, + "apiVersion": null, + "apiName": { + "originalName": "object", + "camelCase": { + "unsafeName": "object", + "safeName": "object" + }, + "snakeCase": { + "unsafeName": "object", + "safeName": "object" + }, + "screamingSnakeCase": { + "unsafeName": "OBJECT", + "safeName": "OBJECT" + }, + "pascalCase": { + "unsafeName": "Object", + "safeName": "Object" + } + }, + "apiDisplayName": null, + "apiDocs": null, + "auth": { + "requirement": "ALL", + "schemes": [], + "docs": null + }, + "headers": [], + "idempotencyHeaders": [], + "types": { + "type_:RequestTypeInlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:RootType1": { + "inline": null, + "name": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [ + "type_:RootType1InlineType1", + "type_:RootType1InlineType1NestedInlineType1", + "type_:InlineEnum" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:RootType1InlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [ + "type_:RootType1InlineType1NestedInlineType1", + "type_:InlineEnum" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:RootType1InlineType1NestedInlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "myEnum", + "camelCase": { + "unsafeName": "myEnum", + "safeName": "myEnum" + }, + "snakeCase": { + "unsafeName": "my_enum", + "safeName": "my_enum" + }, + "screamingSnakeCase": { + "unsafeName": "MY_ENUM", + "safeName": "MY_ENUM" + }, + "pascalCase": { + "unsafeName": "MyEnum", + "safeName": "MyEnum" + } + }, + "wireValue": "myEnum" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:InlineEnum", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [ + "type_:InlineEnum" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:DiscriminatedUnion1": { + "inline": true, + "name": { + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1" + }, + "shape": { + "_type": "union", + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "extends": [], + "baseProperties": [], + "types": [ + { + "discriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type_1", + "safeName": "type_1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_1", + "safeName": "TYPE_1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "shape": { + "_type": "samePropertiesAsObject", + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType1" + }, + "displayName": null, + "availability": null, + "docs": null + }, + { + "discriminantValue": { + "name": { + "originalName": "type2", + "camelCase": { + "unsafeName": "type2", + "safeName": "type2" + }, + "snakeCase": { + "unsafeName": "type_2", + "safeName": "type_2" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_2", + "safeName": "TYPE_2" + }, + "pascalCase": { + "unsafeName": "Type2", + "safeName": "Type2" + } + }, + "wireValue": "type2" + }, + "shape": { + "_type": "samePropertiesAsObject", + "name": { + "originalName": "DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType2", + "safeName": "discriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_2", + "safeName": "discriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType2", + "safeName": "DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType2" + }, + "displayName": null, + "availability": null, + "docs": null + } + ] + }, + "referencedTypes": [ + "type_:DiscriminatedUnion1InlineType1", + "type_:DiscriminatedUnion1InlineType2" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:DiscriminatedUnion1InlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:DiscriminatedUnion1InlineType2": { + "inline": true, + "name": { + "name": { + "originalName": "DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType2", + "safeName": "discriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_2", + "safeName": "discriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType2", + "safeName": "DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType2" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:UndiscriminatedUnion1": { + "inline": true, + "name": { + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1" + }, + "shape": { + "_type": "undiscriminatedUnion", + "members": [ + { + "type": { + "_type": "named", + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1", + "default": null, + "inline": null + }, + "docs": null + }, + { + "type": { + "_type": "named", + "name": { + "originalName": "UndiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_2", + "safeName": "undiscriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType2", + "default": null, + "inline": null + }, + "docs": null + } + ] + }, + "referencedTypes": [ + "type_:UndiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1InlineType2" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:UndiscriminatedUnion1InlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:UndiscriminatedUnion1InlineType2": { + "inline": true, + "name": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_2", + "safeName": "undiscriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType2" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:InlineEnum": { + "inline": true, + "name": { + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:InlineEnum" + }, + "shape": { + "_type": "enum", + "default": null, + "values": [ + { + "name": { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "CLOUDY", + "camelCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "snakeCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "screamingSnakeCase": { + "unsafeName": "CLOUDY", + "safeName": "CLOUDY" + }, + "pascalCase": { + "unsafeName": "Cloudy", + "safeName": "Cloudy" + } + }, + "wireValue": "CLOUDY" + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "RAINING", + "camelCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "snakeCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "screamingSnakeCase": { + "unsafeName": "RAINING", + "safeName": "RAINING" + }, + "pascalCase": { + "unsafeName": "Raining", + "safeName": "Raining" + } + }, + "wireValue": "RAINING" + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "SNOWING", + "camelCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "snakeCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "screamingSnakeCase": { + "unsafeName": "SNOWING", + "safeName": "SNOWING" + }, + "pascalCase": { + "unsafeName": "Snowing", + "safeName": "Snowing" + } + }, + "wireValue": "SNOWING" + }, + "availability": null, + "docs": null + } + ] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + } + }, + "errors": {}, + "services": { + "service_": { + "availability": null, + "name": { + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "displayName": null, + "basePath": { + "head": "/root", + "parts": [] + }, + "headers": [], + "pathParameters": [], + "encoding": { + "json": {}, + "proto": null + }, + "transport": { + "type": "http" + }, + "endpoints": [ + { + "id": "endpoint_.getRoot", + "name": { + "originalName": "getRoot", + "camelCase": { + "unsafeName": "getRoot", + "safeName": "getRoot" + }, + "snakeCase": { + "unsafeName": "get_root", + "safeName": "get_root" + }, + "screamingSnakeCase": { + "unsafeName": "GET_ROOT", + "safeName": "GET_ROOT" + }, + "pascalCase": { + "unsafeName": "GetRoot", + "safeName": "GetRoot" + } + }, + "displayName": null, + "auth": false, + "idempotent": false, + "baseUrl": null, + "method": "POST", + "basePath": null, + "path": { + "head": "/root", + "parts": [] + }, + "fullPath": { + "head": "/root/root", + "parts": [] + }, + "pathParameters": [], + "allPathParameters": [], + "queryParameters": [], + "headers": [], + "requestBody": { + "type": "inlinedRequestBody", + "name": { + "originalName": "PostRootRequest", + "camelCase": { + "unsafeName": "postRootRequest", + "safeName": "postRootRequest" + }, + "snakeCase": { + "unsafeName": "post_root_request", + "safeName": "post_root_request" + }, + "screamingSnakeCase": { + "unsafeName": "POST_ROOT_REQUEST", + "safeName": "POST_ROOT_REQUEST" + }, + "pascalCase": { + "unsafeName": "PostRootRequest", + "safeName": "PostRootRequest" + } + }, + "extends": [], + "contentType": "application/json", + "properties": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [], + "docs": null + }, + "sdkRequest": { + "shape": { + "type": "wrapper", + "wrapperName": { + "originalName": "PostRootRequest", + "camelCase": { + "unsafeName": "postRootRequest", + "safeName": "postRootRequest" + }, + "snakeCase": { + "unsafeName": "post_root_request", + "safeName": "post_root_request" + }, + "screamingSnakeCase": { + "unsafeName": "POST_ROOT_REQUEST", + "safeName": "POST_ROOT_REQUEST" + }, + "pascalCase": { + "unsafeName": "PostRootRequest", + "safeName": "PostRootRequest" + } + }, + "bodyKey": { + "originalName": "body", + "camelCase": { + "unsafeName": "body", + "safeName": "body" + }, + "snakeCase": { + "unsafeName": "body", + "safeName": "body" + }, + "screamingSnakeCase": { + "unsafeName": "BODY", + "safeName": "BODY" + }, + "pascalCase": { + "unsafeName": "Body", + "safeName": "Body" + } + }, + "includePathParameters": false, + "onlyPathParameters": false + }, + "requestParameterName": { + "originalName": "request", + "camelCase": { + "unsafeName": "request", + "safeName": "request" + }, + "snakeCase": { + "unsafeName": "request", + "safeName": "request" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST", + "safeName": "REQUEST" + }, + "pascalCase": { + "unsafeName": "Request", + "safeName": "Request" + } + }, + "streamParameter": null + }, + "response": { + "body": { + "type": "json", + "value": { + "type": "response", + "responseBodyType": { + "_type": "named", + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1", + "default": null, + "inline": null + }, + "docs": null + } + }, + "status-code": null + }, + "errors": [], + "userSpecifiedExamples": [], + "autogeneratedExamples": [ + { + "example": { + "id": "cc979ed415b4638d8e170df64556fbd1154268c5", + "url": "/root/root", + "name": null, + "endpointHeaders": [], + "endpointPathParameters": [], + "queryParameters": [], + "servicePathParameters": [], + "serviceHeaders": [], + "rootPathParameters": [], + "request": { + "type": "inlinedRequestBody", + "properties": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": null, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1" + } + }, + "jsonExample": { + "foo": "foo" + } + } + }, + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": null, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ], + "jsonExample": { + "bar": { + "foo": "foo" + }, + "foo": "foo" + } + }, + "response": { + "type": "ok", + "value": { + "type": "body", + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + }, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + }, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "bar" + } + } + }, + "jsonExample": "bar" + } + }, + { + "name": { + "name": { + "originalName": "myEnum", + "camelCase": { + "unsafeName": "myEnum", + "safeName": "myEnum" + }, + "snakeCase": { + "unsafeName": "my_enum", + "safeName": "my_enum" + }, + "screamingSnakeCase": { + "unsafeName": "MY_ENUM", + "safeName": "MY_ENUM" + }, + "pascalCase": { + "unsafeName": "MyEnum", + "safeName": "MyEnum" + } + }, + "wireValue": "myEnum" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "enum", + "value": { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + } + }, + "typeName": { + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:InlineEnum" + } + }, + "jsonExample": "SUNNY" + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + } + }, + "jsonExample": { + "foo": "foo", + "bar": "bar", + "myEnum": "SUNNY" + } + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + } + }, + "jsonExample": { + "foo": "foo", + "bar": { + "foo": "foo", + "bar": "bar", + "myEnum": "SUNNY" + } + } + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + } + }, + "jsonExample": { + "foo": "foo", + "bar": { + "foo": "foo", + "bar": { + "foo": "foo", + "bar": "bar", + "myEnum": "SUNNY" + } + } + } + } + } + }, + "docs": null + } + } + ], + "pagination": null, + "transport": null, + "availability": null, + "docs": null + }, + { + "id": "endpoint_.getDiscriminatedUnion", + "name": { + "originalName": "getDiscriminatedUnion", + "camelCase": { + "unsafeName": "getDiscriminatedUnion", + "safeName": "getDiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_discriminated_union", + "safeName": "get_discriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_DISCRIMINATED_UNION", + "safeName": "GET_DISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetDiscriminatedUnion", + "safeName": "GetDiscriminatedUnion" + } + }, + "displayName": null, + "auth": false, + "idempotent": false, + "baseUrl": null, + "method": "GET", + "basePath": null, + "path": { + "head": "/discriminated-union", + "parts": [] + }, + "fullPath": { + "head": "/root/discriminated-union", + "parts": [] + }, + "pathParameters": [], + "allPathParameters": [], + "queryParameters": [], + "headers": [], + "requestBody": null, + "sdkRequest": null, + "response": { + "body": { + "type": "json", + "value": { + "type": "response", + "responseBodyType": { + "_type": "named", + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1", + "default": null, + "inline": null + }, + "docs": null + } + }, + "status-code": null + }, + "errors": [], + "userSpecifiedExamples": [], + "autogeneratedExamples": [ + { + "example": { + "id": "66b0f09d479437029bc19bcd824ec0242f8f71e8", + "url": "/root/discriminated-union", + "name": null, + "endpointHeaders": [], + "endpointPathParameters": [], + "queryParameters": [], + "servicePathParameters": [], + "serviceHeaders": [], + "rootPathParameters": [], + "request": null, + "response": { + "type": "ok", + "value": { + "type": "body", + "value": { + "shape": { + "type": "named", + "shape": { + "type": "union", + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "singleUnionType": { + "wireDiscriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type_1", + "safeName": "type_1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_1", + "safeName": "TYPE_1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "shape": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType1", + "object": { + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ] + } + } + } + }, + "typeName": { + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1" + } + }, + "jsonExample": { + "type": "type1", + "foo": "foo" + } + } + } + }, + "docs": null + } + } + ], + "pagination": null, + "transport": null, + "availability": null, + "docs": null + }, + { + "id": "endpoint_.getUndiscriminatedUnion", + "name": { + "originalName": "getUndiscriminatedUnion", + "camelCase": { + "unsafeName": "getUndiscriminatedUnion", + "safeName": "getUndiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_undiscriminated_union", + "safeName": "get_undiscriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_UNDISCRIMINATED_UNION", + "safeName": "GET_UNDISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetUndiscriminatedUnion", + "safeName": "GetUndiscriminatedUnion" + } + }, + "displayName": null, + "auth": false, + "idempotent": false, + "baseUrl": null, + "method": "GET", + "basePath": null, + "path": { + "head": "/undiscriminated-union", + "parts": [] + }, + "fullPath": { + "head": "/root/undiscriminated-union", + "parts": [] + }, + "pathParameters": [], + "allPathParameters": [], + "queryParameters": [], + "headers": [], + "requestBody": null, + "sdkRequest": null, + "response": { + "body": { + "type": "json", + "value": { + "type": "response", + "responseBodyType": { + "_type": "named", + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1", + "default": null, + "inline": null + }, + "docs": null + } + }, + "status-code": null + }, + "errors": [], + "userSpecifiedExamples": [], + "autogeneratedExamples": [ + { + "example": { + "id": "4e32aff3299d7769cc9e184747382c076b82c724", + "url": "/root/undiscriminated-union", + "name": null, + "endpointHeaders": [], + "endpointPathParameters": [], + "queryParameters": [], + "servicePathParameters": [], + "serviceHeaders": [], + "rootPathParameters": [], + "request": null, + "response": { + "type": "ok", + "value": { + "type": "body", + "value": { + "shape": { + "type": "named", + "shape": { + "type": "undiscriminatedUnion", + "index": 0, + "singleUnionType": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ] + }, + "typeName": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1" + } + }, + "jsonExample": { + "foo": "foo" + } + } + }, + "typeName": { + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1" + } + }, + "jsonExample": { + "foo": "foo" + } + } + } + }, + "docs": null + } + } + ], + "pagination": null, + "transport": null, + "availability": null, + "docs": null + } + ] + } + }, + "constants": { + "errorInstanceIdKey": { + "name": { + "originalName": "errorInstanceId", + "camelCase": { + "unsafeName": "errorInstanceId", + "safeName": "errorInstanceId" + }, + "snakeCase": { + "unsafeName": "error_instance_id", + "safeName": "error_instance_id" + }, + "screamingSnakeCase": { + "unsafeName": "ERROR_INSTANCE_ID", + "safeName": "ERROR_INSTANCE_ID" + }, + "pascalCase": { + "unsafeName": "ErrorInstanceId", + "safeName": "ErrorInstanceId" + } + }, + "wireValue": "errorInstanceId" + } + }, + "environments": null, + "errorDiscriminationStrategy": { + "type": "statusCode" + }, + "basePath": null, + "pathParameters": [], + "variables": [], + "serviceTypeReferenceInfo": { + "typesReferencedOnlyByService": { + "service_": [ + "type_:RequestTypeInlineType1", + "type_:RootType1", + "type_:RootType1InlineType1", + "type_:RootType1InlineType1NestedInlineType1", + "type_:DiscriminatedUnion1", + "type_:DiscriminatedUnion1InlineType1", + "type_:DiscriminatedUnion1InlineType2", + "type_:UndiscriminatedUnion1", + "type_:UndiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1InlineType2", + "type_:InlineEnum" + ] + }, + "sharedTypes": [] + }, + "webhookGroups": {}, + "websocketChannels": {}, + "readmeConfig": null, + "sourceConfig": null, + "publishConfig": null, + "dynamic": { + "version": "1.0.0", + "types": { + "type_:RequestTypeInlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:RootType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "named", + "value": "type_:RootType1InlineType1" + } + } + ] + }, + "type_:RootType1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "named", + "value": "type_:RootType1InlineType1NestedInlineType1" + } + } + ] + }, + "type_:RootType1InlineType1NestedInlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "myEnum", + "camelCase": { + "unsafeName": "myEnum", + "safeName": "myEnum" + }, + "snakeCase": { + "unsafeName": "my_enum", + "safeName": "my_enum" + }, + "screamingSnakeCase": { + "unsafeName": "MY_ENUM", + "safeName": "MY_ENUM" + }, + "pascalCase": { + "unsafeName": "MyEnum", + "safeName": "MyEnum" + } + }, + "wireValue": "myEnum" + }, + "typeReference": { + "_type": "named", + "value": "type_:InlineEnum" + } + } + ] + }, + "type_:DiscriminatedUnion1": { + "type": "discriminatedUnion", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "types": { + "type1": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType1", + "discriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type_1", + "safeName": "type_1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_1", + "safeName": "TYPE_1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "properties": [] + }, + "type2": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType2", + "discriminantValue": { + "name": { + "originalName": "type2", + "camelCase": { + "unsafeName": "type2", + "safeName": "type2" + }, + "snakeCase": { + "unsafeName": "type_2", + "safeName": "type_2" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_2", + "safeName": "TYPE_2" + }, + "pascalCase": { + "unsafeName": "Type2", + "safeName": "Type2" + } + }, + "wireValue": "type2" + }, + "properties": [] + } + } + }, + "type_:DiscriminatedUnion1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:DiscriminatedUnion1InlineType2": { + "type": "object", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType2", + "safeName": "discriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_2", + "safeName": "discriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType2", + "safeName": "DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:UndiscriminatedUnion1": { + "type": "undiscriminatedUnion", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "types": [ + { + "_type": "named", + "value": "type_:UndiscriminatedUnion1InlineType1" + }, + { + "_type": "named", + "value": "type_:UndiscriminatedUnion1InlineType2" + } + ] + }, + "type_:UndiscriminatedUnion1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:UndiscriminatedUnion1InlineType2": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_2", + "safeName": "undiscriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:InlineEnum": { + "type": "enum", + "declaration": { + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "values": [ + { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + }, + { + "name": { + "originalName": "CLOUDY", + "camelCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "snakeCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "screamingSnakeCase": { + "unsafeName": "CLOUDY", + "safeName": "CLOUDY" + }, + "pascalCase": { + "unsafeName": "Cloudy", + "safeName": "Cloudy" + } + }, + "wireValue": "CLOUDY" + }, + { + "name": { + "originalName": "RAINING", + "camelCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "snakeCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "screamingSnakeCase": { + "unsafeName": "RAINING", + "safeName": "RAINING" + }, + "pascalCase": { + "unsafeName": "Raining", + "safeName": "Raining" + } + }, + "wireValue": "RAINING" + }, + { + "name": { + "originalName": "SNOWING", + "camelCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "snakeCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "screamingSnakeCase": { + "unsafeName": "SNOWING", + "safeName": "SNOWING" + }, + "pascalCase": { + "unsafeName": "Snowing", + "safeName": "Snowing" + } + }, + "wireValue": "SNOWING" + } + ] + } + }, + "headers": [], + "endpoints": { + "endpoint_.getRoot": { + "auth": null, + "declaration": { + "name": { + "originalName": "getRoot", + "camelCase": { + "unsafeName": "getRoot", + "safeName": "getRoot" + }, + "snakeCase": { + "unsafeName": "get_root", + "safeName": "get_root" + }, + "screamingSnakeCase": { + "unsafeName": "GET_ROOT", + "safeName": "GET_ROOT" + }, + "pascalCase": { + "unsafeName": "GetRoot", + "safeName": "GetRoot" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "location": { + "method": "POST", + "path": "/root/root" + }, + "request": { + "type": "inlined", + "declaration": { + "name": { + "originalName": "PostRootRequest", + "camelCase": { + "unsafeName": "postRootRequest", + "safeName": "postRootRequest" + }, + "snakeCase": { + "unsafeName": "post_root_request", + "safeName": "post_root_request" + }, + "screamingSnakeCase": { + "unsafeName": "POST_ROOT_REQUEST", + "safeName": "POST_ROOT_REQUEST" + }, + "pascalCase": { + "unsafeName": "PostRootRequest", + "safeName": "PostRootRequest" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "pathParameters": [], + "queryParameters": [], + "headers": [], + "body": { + "type": "properties", + "value": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "named", + "value": "type_:RequestTypeInlineType1" + } + }, + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "metadata": { + "includePathParameters": false, + "onlyPathParameters": false + } + }, + "response": { + "type": "json" + } + }, + "endpoint_.getDiscriminatedUnion": { + "auth": null, + "declaration": { + "name": { + "originalName": "getDiscriminatedUnion", + "camelCase": { + "unsafeName": "getDiscriminatedUnion", + "safeName": "getDiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_discriminated_union", + "safeName": "get_discriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_DISCRIMINATED_UNION", + "safeName": "GET_DISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetDiscriminatedUnion", + "safeName": "GetDiscriminatedUnion" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "location": { + "method": "GET", + "path": "/root/discriminated-union" + }, + "request": { + "type": "body", + "pathParameters": [], + "body": null + }, + "response": { + "type": "json" + } + }, + "endpoint_.getUndiscriminatedUnion": { + "auth": null, + "declaration": { + "name": { + "originalName": "getUndiscriminatedUnion", + "camelCase": { + "unsafeName": "getUndiscriminatedUnion", + "safeName": "getUndiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_undiscriminated_union", + "safeName": "get_undiscriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_UNDISCRIMINATED_UNION", + "safeName": "GET_UNDISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetUndiscriminatedUnion", + "safeName": "GetUndiscriminatedUnion" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "location": { + "method": "GET", + "path": "/root/undiscriminated-union" + }, + "request": { + "type": "body", + "pathParameters": [], + "body": null + }, + "response": { + "type": "json" + } + } + } + }, + "subpackages": {}, + "rootPackage": { + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "websocket": null, + "service": "service_", + "types": [ + "type_:RequestTypeInlineType1", + "type_:RootType1", + "type_:RootType1InlineType1", + "type_:RootType1InlineType1NestedInlineType1", + "type_:DiscriminatedUnion1", + "type_:DiscriminatedUnion1InlineType1", + "type_:DiscriminatedUnion1InlineType2", + "type_:UndiscriminatedUnion1", + "type_:UndiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1InlineType2", + "type_:InlineEnum" + ], + "errors": [], + "subpackages": [], + "webhooks": null, + "navigationConfig": null, + "hasEndpointsInTree": true, + "docs": null + }, + "sdkConfig": { + "isAuthMandatory": false, + "hasStreamingEndpoints": false, + "hasPaginatedEndpoints": false, + "hasFileDownloadEndpoints": false, + "platformHeaders": { + "language": "X-Fern-Language", + "sdkName": "X-Fern-SDK-Name", + "sdkVersion": "X-Fern-SDK-Version", + "userAgent": null + } + } +} \ No newline at end of file diff --git a/seed/ts-express/inline-types/api/service/RootService.ts b/seed/ts-express/inline-types/api/service/RootService.ts index 8b818d49332..978c55feb0d 100644 --- a/seed/ts-express/inline-types/api/service/RootService.ts +++ b/seed/ts-express/inline-types/api/service/RootService.ts @@ -17,6 +17,24 @@ export interface RootServiceMethods { }, next: express.NextFunction ): void | Promise; + getDiscriminatedUnion( + req: express.Request, + res: { + send: () => Promise; + cookie: (cookie: string, value: string, options?: express.CookieOptions) => void; + locals: any; + }, + next: express.NextFunction + ): void | Promise; + getUndiscriminatedUnion( + req: express.Request, + res: { + send: () => Promise; + cookie: (cookie: string, value: string, options?: express.CookieOptions) => void; + locals: any; + }, + next: express.NextFunction + ): void | Promise; } export class RootService { @@ -78,6 +96,84 @@ export class RootService { next(request.errors); } }); + this.router.post("/discriminated-union", async (req, res, next) => { + const request = serializers.GetDiscriminatedUnionRequest.parse(req.body); + if (request.ok) { + req.body = request.value; + try { + await this.methods.getDiscriminatedUnion( + req as any, + { + send: async () => { + res.sendStatus(204); + }, + cookie: res.cookie.bind(res), + locals: res.locals, + }, + next + ); + next(); + } catch (error) { + if (error instanceof errors.SeedObjectError) { + console.warn( + `Endpoint 'getDiscriminatedUnion' unexpectedly threw ${error.constructor.name}.` + + ` If this was intentional, please add ${error.constructor.name} to` + + " the endpoint's errors list in your Fern Definition." + ); + await error.send(res); + } else { + res.status(500).json("Internal Server Error"); + } + next(error); + } + } else { + res.status(422).json({ + errors: request.errors.map( + (error) => ["request", ...error.path].join(" -> ") + ": " + error.message + ), + }); + next(request.errors); + } + }); + this.router.post("/undiscriminated-union", async (req, res, next) => { + const request = serializers.GetUndiscriminatedUnionRequest.parse(req.body); + if (request.ok) { + req.body = request.value; + try { + await this.methods.getUndiscriminatedUnion( + req as any, + { + send: async () => { + res.sendStatus(204); + }, + cookie: res.cookie.bind(res), + locals: res.locals, + }, + next + ); + next(); + } catch (error) { + if (error instanceof errors.SeedObjectError) { + console.warn( + `Endpoint 'getUndiscriminatedUnion' unexpectedly threw ${error.constructor.name}.` + + ` If this was intentional, please add ${error.constructor.name} to` + + " the endpoint's errors list in your Fern Definition." + ); + await error.send(res); + } else { + res.status(500).json("Internal Server Error"); + } + next(error); + } + } else { + res.status(422).json({ + errors: request.errors.map( + (error) => ["request", ...error.path].join(" -> ") + ": " + error.message + ), + }); + next(request.errors); + } + }); return this.router; } } diff --git a/seed/ts-express/inline-types/api/service/requests/GetDiscriminatedUnionRequest.ts b/seed/ts-express/inline-types/api/service/requests/GetDiscriminatedUnionRequest.ts new file mode 100644 index 00000000000..4fa358e7598 --- /dev/null +++ b/seed/ts-express/inline-types/api/service/requests/GetDiscriminatedUnionRequest.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../../index"; + +export interface GetDiscriminatedUnionRequest { + bar: SeedObject.DiscriminatedUnion1; + foo: string; +} diff --git a/seed/ts-express/inline-types/api/service/requests/GetUndiscriminatedUnionRequest.ts b/seed/ts-express/inline-types/api/service/requests/GetUndiscriminatedUnionRequest.ts new file mode 100644 index 00000000000..c260e9a3f11 --- /dev/null +++ b/seed/ts-express/inline-types/api/service/requests/GetUndiscriminatedUnionRequest.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../../index"; + +export interface GetUndiscriminatedUnionRequest { + bar: SeedObject.UndiscriminatedUnion1; + foo: string; +} diff --git a/seed/ts-express/inline-types/api/service/requests/PostRootRequest.ts b/seed/ts-express/inline-types/api/service/requests/PostRootRequest.ts index ec6749bed53..ef25c95411c 100644 --- a/seed/ts-express/inline-types/api/service/requests/PostRootRequest.ts +++ b/seed/ts-express/inline-types/api/service/requests/PostRootRequest.ts @@ -5,6 +5,6 @@ import * as SeedObject from "../../index"; export interface PostRootRequest { - bar: SeedObject.InlineType1; + bar: SeedObject.RequestTypeInlineType1; foo: string; } diff --git a/seed/ts-express/inline-types/api/service/requests/index.ts b/seed/ts-express/inline-types/api/service/requests/index.ts index 497781074f3..1e2ed00361c 100644 --- a/seed/ts-express/inline-types/api/service/requests/index.ts +++ b/seed/ts-express/inline-types/api/service/requests/index.ts @@ -1 +1,3 @@ export { PostRootRequest } from "./PostRootRequest"; +export { GetDiscriminatedUnionRequest } from "./GetDiscriminatedUnionRequest"; +export { GetUndiscriminatedUnionRequest } from "./GetUndiscriminatedUnionRequest"; diff --git a/seed/ts-express/inline-types/api/types/AliasInlineValue.ts b/seed/ts-express/inline-types/api/types/AliasInlineValue.ts new file mode 100644 index 00000000000..0beb9652513 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/AliasInlineValue.ts @@ -0,0 +1,8 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface AliasInlineValue { + foo: string; + bar: string; +} diff --git a/seed/ts-express/inline-types/api/types/InlineType1.ts b/seed/ts-express/inline-types/api/types/AliasListInline.ts similarity index 56% rename from seed/ts-express/inline-types/api/types/InlineType1.ts rename to seed/ts-express/inline-types/api/types/AliasListInline.ts index 46eb751da7c..a684ff0eef7 100644 --- a/seed/ts-express/inline-types/api/types/InlineType1.ts +++ b/seed/ts-express/inline-types/api/types/AliasListInline.ts @@ -4,7 +4,4 @@ import * as SeedObject from "../index"; -export interface InlineType1 { - foo: string; - bar: SeedObject.NestedInlineType1; -} +export type AliasListInline = SeedObject.AliasInlineValue[]; diff --git a/seed/ts-express/inline-types/api/types/InlinedUndiscriminatedUnion1.ts b/seed/ts-express/inline-types/api/types/AliasMapInline.ts similarity index 55% rename from seed/ts-express/inline-types/api/types/InlinedUndiscriminatedUnion1.ts rename to seed/ts-express/inline-types/api/types/AliasMapInline.ts index aa17b80bb9a..f0d6f380859 100644 --- a/seed/ts-express/inline-types/api/types/InlinedUndiscriminatedUnion1.ts +++ b/seed/ts-express/inline-types/api/types/AliasMapInline.ts @@ -4,4 +4,4 @@ import * as SeedObject from "../index"; -export type InlinedUndiscriminatedUnion1 = SeedObject.InlineType1 | SeedObject.InlineType2; +export type AliasMapInline = Record; diff --git a/seed/ts-express/inline-types/api/types/NestedInlineType1.ts b/seed/ts-express/inline-types/api/types/AliasSetInline.ts similarity index 51% rename from seed/ts-express/inline-types/api/types/NestedInlineType1.ts rename to seed/ts-express/inline-types/api/types/AliasSetInline.ts index 149f04ffa10..32d6e6ebd97 100644 --- a/seed/ts-express/inline-types/api/types/NestedInlineType1.ts +++ b/seed/ts-express/inline-types/api/types/AliasSetInline.ts @@ -4,8 +4,4 @@ import * as SeedObject from "../index"; -export interface NestedInlineType1 { - foo: string; - bar: string; - myEnum: SeedObject.InlineEnum; -} +export type AliasSetInline = SeedObject.AliasInlineValue[]; diff --git a/seed/ts-express/inline-types/api/types/DiscriminatedUnion1.ts b/seed/ts-express/inline-types/api/types/DiscriminatedUnion1.ts new file mode 100644 index 00000000000..1ecb788196f --- /dev/null +++ b/seed/ts-express/inline-types/api/types/DiscriminatedUnion1.ts @@ -0,0 +1,33 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export type DiscriminatedUnion1 = + /** + * lorem ipsum */ + | SeedObject.DiscriminatedUnion1.Type1 + /** + * lorem ipsum */ + | SeedObject.DiscriminatedUnion1.Type2 + /** + * lorem ipsum */ + | SeedObject.DiscriminatedUnion1.Ref; + +export namespace DiscriminatedUnion1 { + export interface Type1 extends SeedObject.DiscriminatedUnion1InlineType1 { + type: "type1"; + } + + export interface Type2 extends SeedObject.DiscriminatedUnion1InlineType2 { + type: "type2"; + } + + export interface Ref extends SeedObject.ReferenceType { + type: "ref"; + } +} diff --git a/seed/ts-express/inline-types/api/types/DiscriminatedUnion1InlineType1.ts b/seed/ts-express/inline-types/api/types/DiscriminatedUnion1InlineType1.ts new file mode 100644 index 00000000000..aee4789e932 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/DiscriminatedUnion1InlineType1.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface DiscriminatedUnion1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: SeedObject.DiscriminatedUnion1InlineType1InlineType1; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/DiscriminatedUnion1InlineType1InlineType1.ts b/seed/ts-express/inline-types/api/types/DiscriminatedUnion1InlineType1InlineType1.ts new file mode 100644 index 00000000000..259925b7704 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/DiscriminatedUnion1InlineType1InlineType1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface DiscriminatedUnion1InlineType1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/DiscriminatedUnion1InlineType2.ts b/seed/ts-express/inline-types/api/types/DiscriminatedUnion1InlineType2.ts new file mode 100644 index 00000000000..b90bfb679a2 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/DiscriminatedUnion1InlineType2.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface DiscriminatedUnion1InlineType2 { + /** lorem ipsum */ + baz: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/InlineEnum.ts b/seed/ts-express/inline-types/api/types/InlineEnum1.ts similarity index 59% rename from seed/ts-express/inline-types/api/types/InlineEnum.ts rename to seed/ts-express/inline-types/api/types/InlineEnum1.ts index efc9b2dc13b..c678052d190 100644 --- a/seed/ts-express/inline-types/api/types/InlineEnum.ts +++ b/seed/ts-express/inline-types/api/types/InlineEnum1.ts @@ -2,9 +2,11 @@ * This file was auto-generated by Fern from our API Definition. */ -export type InlineEnum = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - -export const InlineEnum = { +/** + * lorem ipsum + */ +export type InlineEnum1 = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; +export const InlineEnum1 = { Sunny: "SUNNY", Cloudy: "CLOUDY", Raining: "RAINING", diff --git a/seed/ts-express/inline-types/api/types/InlinedDiscriminatedUnion1.ts b/seed/ts-express/inline-types/api/types/InlinedDiscriminatedUnion1.ts deleted file mode 100644 index 6fd939b1ecd..00000000000 --- a/seed/ts-express/inline-types/api/types/InlinedDiscriminatedUnion1.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as SeedObject from "../index"; - -export type InlinedDiscriminatedUnion1 = - | SeedObject.InlinedDiscriminatedUnion1.Type1 - | SeedObject.InlinedDiscriminatedUnion1.Type2; - -export declare namespace InlinedDiscriminatedUnion1 { - interface Type1 extends SeedObject.InlineType1 { - type: "type1"; - } - - interface Type2 extends SeedObject.InlineType2 { - type: "type2"; - } -} diff --git a/seed/ts-express/inline-types/api/types/ReferenceType.ts b/seed/ts-express/inline-types/api/types/ReferenceType.ts new file mode 100644 index 00000000000..3754bc9c7e2 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/ReferenceType.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * lorem ipsum + */ +export interface ReferenceType { + /** lorem ipsum */ + foo: string; +} diff --git a/seed/ts-express/inline-types/api/types/RequestTypeInlineType1.ts b/seed/ts-express/inline-types/api/types/RequestTypeInlineType1.ts new file mode 100644 index 00000000000..1e390edb73c --- /dev/null +++ b/seed/ts-express/inline-types/api/types/RequestTypeInlineType1.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * lorem ipsum + */ +export interface RequestTypeInlineType1 { + /** lorem ipsum */ + foo: string; +} diff --git a/seed/ts-express/inline-types/api/types/RootType1.ts b/seed/ts-express/inline-types/api/types/RootType1.ts index 5fd2ba90356..d0d33243bcc 100644 --- a/seed/ts-express/inline-types/api/types/RootType1.ts +++ b/seed/ts-express/inline-types/api/types/RootType1.ts @@ -4,7 +4,20 @@ import * as SeedObject from "../index"; +/** + * lorem ipsum + */ export interface RootType1 { + /** lorem ipsum */ foo: string; - bar: SeedObject.InlineType1; + /** lorem ipsum */ + bar: SeedObject.RootType1InlineType1; + /** lorem ipsum */ + fooMap: Record; + /** lorem ipsum */ + fooList: SeedObject.RootType1FooListItem[]; + /** lorem ipsum */ + fooSet: SeedObject.RootType1FooSetItem[]; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; } diff --git a/seed/ts-express/inline-types/api/types/RootType1FooListItem.ts b/seed/ts-express/inline-types/api/types/RootType1FooListItem.ts new file mode 100644 index 00000000000..0ffcae98837 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/RootType1FooListItem.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1FooListItem { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/RootType1FooMapValue.ts b/seed/ts-express/inline-types/api/types/RootType1FooMapValue.ts new file mode 100644 index 00000000000..431bc3c905f --- /dev/null +++ b/seed/ts-express/inline-types/api/types/RootType1FooMapValue.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1FooMapValue { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/RootType1FooSetItem.ts b/seed/ts-express/inline-types/api/types/RootType1FooSetItem.ts new file mode 100644 index 00000000000..b4c3b6b5788 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/RootType1FooSetItem.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1FooSetItem { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/RootType1InlineType1.ts b/seed/ts-express/inline-types/api/types/RootType1InlineType1.ts new file mode 100644 index 00000000000..786b87523f5 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/RootType1InlineType1.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: SeedObject.RootType1InlineType1NestedInlineType1; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/RootType1InlineType1NestedInlineType1.ts b/seed/ts-express/inline-types/api/types/RootType1InlineType1NestedInlineType1.ts new file mode 100644 index 00000000000..7f2cca73ba7 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/RootType1InlineType1NestedInlineType1.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1InlineType1NestedInlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: string; + /** lorem ipsum */ + myEnum: SeedObject.InlineEnum1; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1.ts new file mode 100644 index 00000000000..e27127ef2eb --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export type UndiscriminatedUnion1 = + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1InlineType1 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1InlineType2 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1DiscriminatedUnion1 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1DiscriminatedUnion1 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1InlineEnum1 + /** + * lorem ipsum */ + | SeedObject.UserId + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1InlineListItem1[] + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1InlineSetItem1[] + /** + * lorem ipsum */ + | Record + /** + * lorem ipsum */ + | SeedObject.ReferenceType; diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1.ts new file mode 100644 index 00000000000..79d5ac09d41 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1.ts @@ -0,0 +1,33 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export type UndiscriminatedUnion1DiscriminatedUnion1 = + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1DiscriminatedUnion1.Type1 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1DiscriminatedUnion1.Type2 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1DiscriminatedUnion1.Ref; + +export namespace UndiscriminatedUnion1DiscriminatedUnion1 { + export interface Type1 extends SeedObject.UndiscriminatedUnion1DiscriminatedUnion1InlineType1 { + type: "type1"; + } + + export interface Type2 extends SeedObject.UndiscriminatedUnion1DiscriminatedUnion1InlineType2 { + type: "type2"; + } + + export interface Ref extends SeedObject.ReferenceType { + type: "ref"; + } +} diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1.ts new file mode 100644 index 00000000000..ed023f35ece --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1DiscriminatedUnion1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: SeedObject.UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.ts new file mode 100644 index 00000000000..06dc9f4879f --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType2.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType2.ts new file mode 100644 index 00000000000..a691050422a --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType2.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1DiscriminatedUnion1InlineType2 { + /** lorem ipsum */ + baz: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineEnum1.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineEnum1.ts new file mode 100644 index 00000000000..b0184d4a8fe --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineEnum1.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * lorem ipsum + */ +export type UndiscriminatedUnion1InlineEnum1 = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; +export const UndiscriminatedUnion1InlineEnum1 = { + Sunny: "SUNNY", + Cloudy: "CLOUDY", + Raining: "RAINING", + Snowing: "SNOWING", +} as const; diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineListItem1.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineListItem1.ts new file mode 100644 index 00000000000..a4e8738f30e --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineListItem1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineListItem1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineMapItem1.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineMapItem1.ts new file mode 100644 index 00000000000..2c343a1648d --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineMapItem1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineMapItem1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineSetItem1.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineSetItem1.ts new file mode 100644 index 00000000000..bfb627dff7a --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineSetItem1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineSetItem1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineType1.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineType1.ts new file mode 100644 index 00000000000..cd15e0f5170 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineType1.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: SeedObject.UndiscriminatedUnion1InlineType1InlineType1; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineType1InlineType1.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineType1InlineType1.ts new file mode 100644 index 00000000000..104de7c900d --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineType1InlineType1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineType1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineType2.ts b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineType2.ts new file mode 100644 index 00000000000..ceaf78891a0 --- /dev/null +++ b/seed/ts-express/inline-types/api/types/UndiscriminatedUnion1InlineType2.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineType2 { + /** lorem ipsum */ + baz: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-express/inline-types/api/types/InlineType2.ts b/seed/ts-express/inline-types/api/types/UserId.ts similarity index 58% rename from seed/ts-express/inline-types/api/types/InlineType2.ts rename to seed/ts-express/inline-types/api/types/UserId.ts index 6fd9bee2f7c..5a6e3e5152f 100644 --- a/seed/ts-express/inline-types/api/types/InlineType2.ts +++ b/seed/ts-express/inline-types/api/types/UserId.ts @@ -2,6 +2,7 @@ * This file was auto-generated by Fern from our API Definition. */ -export interface InlineType2 { - baz: string; -} +/** + * lorem ipsum + */ +export type UserId = string; diff --git a/seed/ts-express/inline-types/api/types/index.ts b/seed/ts-express/inline-types/api/types/index.ts index bb183ec944a..57d21ed5261 100644 --- a/seed/ts-express/inline-types/api/types/index.ts +++ b/seed/ts-express/inline-types/api/types/index.ts @@ -1,7 +1,30 @@ +export * from "./AliasMapInline"; +export * from "./AliasSetInline"; +export * from "./AliasListInline"; +export * from "./AliasInlineValue"; +export * from "./RequestTypeInlineType1"; export * from "./RootType1"; -export * from "./InlineType1"; -export * from "./InlineType2"; -export * from "./NestedInlineType1"; -export * from "./InlinedDiscriminatedUnion1"; -export * from "./InlinedUndiscriminatedUnion1"; -export * from "./InlineEnum"; +export * from "./RootType1FooMapValue"; +export * from "./RootType1FooListItem"; +export * from "./RootType1FooSetItem"; +export * from "./RootType1InlineType1"; +export * from "./RootType1InlineType1NestedInlineType1"; +export * from "./DiscriminatedUnion1"; +export * from "./DiscriminatedUnion1InlineType1"; +export * from "./DiscriminatedUnion1InlineType1InlineType1"; +export * from "./DiscriminatedUnion1InlineType2"; +export * from "./UndiscriminatedUnion1"; +export * from "./UndiscriminatedUnion1InlineType1"; +export * from "./UndiscriminatedUnion1InlineType1InlineType1"; +export * from "./UndiscriminatedUnion1InlineType2"; +export * from "./InlineEnum1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1InlineType1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1InlineType2"; +export * from "./UndiscriminatedUnion1InlineEnum1"; +export * from "./UserId"; +export * from "./UndiscriminatedUnion1InlineListItem1"; +export * from "./UndiscriminatedUnion1InlineSetItem1"; +export * from "./UndiscriminatedUnion1InlineMapItem1"; +export * from "./ReferenceType"; diff --git a/seed/ts-express/inline-types/serialization/service/requests/GetDiscriminatedUnionRequest.ts b/seed/ts-express/inline-types/serialization/service/requests/GetDiscriminatedUnionRequest.ts new file mode 100644 index 00000000000..f31cff3b9ae --- /dev/null +++ b/seed/ts-express/inline-types/serialization/service/requests/GetDiscriminatedUnionRequest.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../index"; +import * as SeedObject from "../../../api/index"; +import * as core from "../../../core"; + +export const GetDiscriminatedUnionRequest: core.serialization.Schema< + serializers.GetDiscriminatedUnionRequest.Raw, + SeedObject.GetDiscriminatedUnionRequest +> = core.serialization.object({ + bar: core.serialization.lazy(() => serializers.DiscriminatedUnion1), + foo: core.serialization.string(), +}); + +export declare namespace GetDiscriminatedUnionRequest { + interface Raw { + bar: serializers.DiscriminatedUnion1.Raw; + foo: string; + } +} diff --git a/seed/ts-express/inline-types/serialization/service/requests/GetUndiscriminatedUnionRequest.ts b/seed/ts-express/inline-types/serialization/service/requests/GetUndiscriminatedUnionRequest.ts new file mode 100644 index 00000000000..6718a23bff6 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/service/requests/GetUndiscriminatedUnionRequest.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../../index"; +import * as SeedObject from "../../../api/index"; +import * as core from "../../../core"; + +export const GetUndiscriminatedUnionRequest: core.serialization.Schema< + serializers.GetUndiscriminatedUnionRequest.Raw, + SeedObject.GetUndiscriminatedUnionRequest +> = core.serialization.object({ + bar: core.serialization.lazy(() => serializers.UndiscriminatedUnion1), + foo: core.serialization.string(), +}); + +export declare namespace GetUndiscriminatedUnionRequest { + interface Raw { + bar: serializers.UndiscriminatedUnion1.Raw; + foo: string; + } +} diff --git a/seed/ts-express/inline-types/serialization/service/requests/PostRootRequest.ts b/seed/ts-express/inline-types/serialization/service/requests/PostRootRequest.ts index eb7ecde3fb8..cee54c2feea 100644 --- a/seed/ts-express/inline-types/serialization/service/requests/PostRootRequest.ts +++ b/seed/ts-express/inline-types/serialization/service/requests/PostRootRequest.ts @@ -8,13 +8,13 @@ import * as core from "../../../core"; export const PostRootRequest: core.serialization.Schema = core.serialization.object({ - bar: core.serialization.lazyObject(() => serializers.InlineType1), + bar: core.serialization.lazyObject(() => serializers.RequestTypeInlineType1), foo: core.serialization.string(), }); export declare namespace PostRootRequest { interface Raw { - bar: serializers.InlineType1.Raw; + bar: serializers.RequestTypeInlineType1.Raw; foo: string; } } diff --git a/seed/ts-express/inline-types/serialization/service/requests/index.ts b/seed/ts-express/inline-types/serialization/service/requests/index.ts index 497781074f3..1e2ed00361c 100644 --- a/seed/ts-express/inline-types/serialization/service/requests/index.ts +++ b/seed/ts-express/inline-types/serialization/service/requests/index.ts @@ -1 +1,3 @@ export { PostRootRequest } from "./PostRootRequest"; +export { GetDiscriminatedUnionRequest } from "./GetDiscriminatedUnionRequest"; +export { GetUndiscriminatedUnionRequest } from "./GetUndiscriminatedUnionRequest"; diff --git a/seed/ts-express/inline-types/serialization/types/NestedInlineType1.ts b/seed/ts-express/inline-types/serialization/types/AliasInlineValue.ts similarity index 56% rename from seed/ts-express/inline-types/serialization/types/NestedInlineType1.ts rename to seed/ts-express/inline-types/serialization/types/AliasInlineValue.ts index 91c30faa4fc..ad5f6437099 100644 --- a/seed/ts-express/inline-types/serialization/types/NestedInlineType1.ts +++ b/seed/ts-express/inline-types/serialization/types/AliasInlineValue.ts @@ -6,19 +6,17 @@ import * as serializers from "../index"; import * as SeedObject from "../../api/index"; import * as core from "../../core"; -export const NestedInlineType1: core.serialization.ObjectSchema< - serializers.NestedInlineType1.Raw, - SeedObject.NestedInlineType1 +export const AliasInlineValue: core.serialization.ObjectSchema< + serializers.AliasInlineValue.Raw, + SeedObject.AliasInlineValue > = core.serialization.object({ foo: core.serialization.string(), bar: core.serialization.string(), - myEnum: core.serialization.lazy(() => serializers.InlineEnum), }); -export declare namespace NestedInlineType1 { +export declare namespace AliasInlineValue { interface Raw { foo: string; bar: string; - myEnum: serializers.InlineEnum.Raw; } } diff --git a/seed/ts-express/inline-types/serialization/types/AliasListInline.ts b/seed/ts-express/inline-types/serialization/types/AliasListInline.ts new file mode 100644 index 00000000000..0e9608b201e --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/AliasListInline.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const AliasListInline: core.serialization.Schema = + core.serialization.list(core.serialization.lazyObject(() => serializers.AliasInlineValue)); + +export declare namespace AliasListInline { + type Raw = serializers.AliasInlineValue.Raw[]; +} diff --git a/seed/ts-express/inline-types/serialization/types/AliasMapInline.ts b/seed/ts-express/inline-types/serialization/types/AliasMapInline.ts new file mode 100644 index 00000000000..e37388761e9 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/AliasMapInline.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const AliasMapInline: core.serialization.Schema = + core.serialization.record( + core.serialization.string(), + core.serialization.lazyObject(() => serializers.AliasInlineValue) + ); + +export declare namespace AliasMapInline { + type Raw = Record; +} diff --git a/seed/ts-express/inline-types/serialization/types/AliasSetInline.ts b/seed/ts-express/inline-types/serialization/types/AliasSetInline.ts new file mode 100644 index 00000000000..0d931080074 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/AliasSetInline.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const AliasSetInline: core.serialization.Schema = + core.serialization.list(core.serialization.lazyObject(() => serializers.AliasInlineValue)); + +export declare namespace AliasSetInline { + type Raw = serializers.AliasInlineValue.Raw[]; +} diff --git a/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1.ts b/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1.ts new file mode 100644 index 00000000000..38151ead239 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1.ts @@ -0,0 +1,37 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const DiscriminatedUnion1: core.serialization.Schema< + serializers.DiscriminatedUnion1.Raw, + SeedObject.DiscriminatedUnion1 +> = core.serialization + .union("type", { + type1: core.serialization.lazyObject(() => serializers.DiscriminatedUnion1InlineType1), + type2: core.serialization.lazyObject(() => serializers.DiscriminatedUnion1InlineType2), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), + }) + .transform({ + transform: (value) => value, + untransform: (value) => value, + }); + +export declare namespace DiscriminatedUnion1 { + type Raw = DiscriminatedUnion1.Type1 | DiscriminatedUnion1.Type2 | DiscriminatedUnion1.Ref; + + interface Type1 extends serializers.DiscriminatedUnion1InlineType1.Raw { + type: "type1"; + } + + interface Type2 extends serializers.DiscriminatedUnion1InlineType2.Raw { + type: "type2"; + } + + interface Ref extends serializers.ReferenceType.Raw { + type: "ref"; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1InlineType1.ts b/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1InlineType1.ts new file mode 100644 index 00000000000..92cd978767e --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1InlineType1.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const DiscriminatedUnion1InlineType1: core.serialization.ObjectSchema< + serializers.DiscriminatedUnion1InlineType1.Raw, + SeedObject.DiscriminatedUnion1InlineType1 +> = core.serialization.object({ + foo: core.serialization.string(), + bar: core.serialization.lazyObject(() => serializers.DiscriminatedUnion1InlineType1InlineType1), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace DiscriminatedUnion1InlineType1 { + interface Raw { + foo: string; + bar: serializers.DiscriminatedUnion1InlineType1InlineType1.Raw; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1InlineType1InlineType1.ts b/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1InlineType1InlineType1.ts new file mode 100644 index 00000000000..5eb65cea843 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1InlineType1InlineType1.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const DiscriminatedUnion1InlineType1InlineType1: core.serialization.ObjectSchema< + serializers.DiscriminatedUnion1InlineType1InlineType1.Raw, + SeedObject.DiscriminatedUnion1InlineType1InlineType1 +> = core.serialization.object({ + foo: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace DiscriminatedUnion1InlineType1InlineType1 { + interface Raw { + foo: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1InlineType2.ts b/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1InlineType2.ts new file mode 100644 index 00000000000..9acf0a5c56e --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/DiscriminatedUnion1InlineType2.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const DiscriminatedUnion1InlineType2: core.serialization.ObjectSchema< + serializers.DiscriminatedUnion1InlineType2.Raw, + SeedObject.DiscriminatedUnion1InlineType2 +> = core.serialization.object({ + baz: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace DiscriminatedUnion1InlineType2 { + interface Raw { + baz: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/InlineEnum.ts b/seed/ts-express/inline-types/serialization/types/InlineEnum1.ts similarity index 69% rename from seed/ts-express/inline-types/serialization/types/InlineEnum.ts rename to seed/ts-express/inline-types/serialization/types/InlineEnum1.ts index ee1e24ef1f6..ee1f6ab474a 100644 --- a/seed/ts-express/inline-types/serialization/types/InlineEnum.ts +++ b/seed/ts-express/inline-types/serialization/types/InlineEnum1.ts @@ -6,9 +6,9 @@ import * as serializers from "../index"; import * as SeedObject from "../../api/index"; import * as core from "../../core"; -export const InlineEnum: core.serialization.Schema = +export const InlineEnum1: core.serialization.Schema = core.serialization.enum_(["SUNNY", "CLOUDY", "RAINING", "SNOWING"]); -export declare namespace InlineEnum { +export declare namespace InlineEnum1 { type Raw = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; } diff --git a/seed/ts-express/inline-types/serialization/types/InlineType1.ts b/seed/ts-express/inline-types/serialization/types/InlineType1.ts deleted file mode 100644 index 8ea05d90b78..00000000000 --- a/seed/ts-express/inline-types/serialization/types/InlineType1.ts +++ /dev/null @@ -1,20 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../index"; -import * as SeedObject from "../../api/index"; -import * as core from "../../core"; - -export const InlineType1: core.serialization.ObjectSchema = - core.serialization.object({ - foo: core.serialization.string(), - bar: core.serialization.lazyObject(() => serializers.NestedInlineType1), - }); - -export declare namespace InlineType1 { - interface Raw { - foo: string; - bar: serializers.NestedInlineType1.Raw; - } -} diff --git a/seed/ts-express/inline-types/serialization/types/InlinedDiscriminatedUnion1.ts b/seed/ts-express/inline-types/serialization/types/InlinedDiscriminatedUnion1.ts deleted file mode 100644 index 79a2c023337..00000000000 --- a/seed/ts-express/inline-types/serialization/types/InlinedDiscriminatedUnion1.ts +++ /dev/null @@ -1,32 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../index"; -import * as SeedObject from "../../api/index"; -import * as core from "../../core"; - -export const InlinedDiscriminatedUnion1: core.serialization.Schema< - serializers.InlinedDiscriminatedUnion1.Raw, - SeedObject.InlinedDiscriminatedUnion1 -> = core.serialization - .union("type", { - type1: core.serialization.lazyObject(() => serializers.InlineType1), - type2: core.serialization.lazyObject(() => serializers.InlineType2), - }) - .transform({ - transform: (value) => value, - untransform: (value) => value, - }); - -export declare namespace InlinedDiscriminatedUnion1 { - type Raw = InlinedDiscriminatedUnion1.Type1 | InlinedDiscriminatedUnion1.Type2; - - interface Type1 extends serializers.InlineType1.Raw { - type: "type1"; - } - - interface Type2 extends serializers.InlineType2.Raw { - type: "type2"; - } -} diff --git a/seed/ts-express/inline-types/serialization/types/InlinedUndiscriminatedUnion1.ts b/seed/ts-express/inline-types/serialization/types/InlinedUndiscriminatedUnion1.ts deleted file mode 100644 index 64402d9358b..00000000000 --- a/seed/ts-express/inline-types/serialization/types/InlinedUndiscriminatedUnion1.ts +++ /dev/null @@ -1,19 +0,0 @@ -/** - * This file was auto-generated by Fern from our API Definition. - */ - -import * as serializers from "../index"; -import * as SeedObject from "../../api/index"; -import * as core from "../../core"; - -export const InlinedUndiscriminatedUnion1: core.serialization.Schema< - serializers.InlinedUndiscriminatedUnion1.Raw, - SeedObject.InlinedUndiscriminatedUnion1 -> = core.serialization.undiscriminatedUnion([ - core.serialization.lazyObject(() => serializers.InlineType1), - core.serialization.lazyObject(() => serializers.InlineType2), -]); - -export declare namespace InlinedUndiscriminatedUnion1 { - type Raw = serializers.InlineType1.Raw | serializers.InlineType2.Raw; -} diff --git a/seed/ts-express/inline-types/serialization/types/InlineType2.ts b/seed/ts-express/inline-types/serialization/types/ReferenceType.ts similarity index 54% rename from seed/ts-express/inline-types/serialization/types/InlineType2.ts rename to seed/ts-express/inline-types/serialization/types/ReferenceType.ts index a2590844567..c90ea4b4a16 100644 --- a/seed/ts-express/inline-types/serialization/types/InlineType2.ts +++ b/seed/ts-express/inline-types/serialization/types/ReferenceType.ts @@ -6,13 +6,13 @@ import * as serializers from "../index"; import * as SeedObject from "../../api/index"; import * as core from "../../core"; -export const InlineType2: core.serialization.ObjectSchema = +export const ReferenceType: core.serialization.ObjectSchema = core.serialization.object({ - baz: core.serialization.string(), + foo: core.serialization.string(), }); -export declare namespace InlineType2 { +export declare namespace ReferenceType { interface Raw { - baz: string; + foo: string; } } diff --git a/seed/ts-express/inline-types/serialization/types/RequestTypeInlineType1.ts b/seed/ts-express/inline-types/serialization/types/RequestTypeInlineType1.ts new file mode 100644 index 00000000000..cc38d772dc8 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/RequestTypeInlineType1.ts @@ -0,0 +1,20 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const RequestTypeInlineType1: core.serialization.ObjectSchema< + serializers.RequestTypeInlineType1.Raw, + SeedObject.RequestTypeInlineType1 +> = core.serialization.object({ + foo: core.serialization.string(), +}); + +export declare namespace RequestTypeInlineType1 { + interface Raw { + foo: string; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/RootType1.ts b/seed/ts-express/inline-types/serialization/types/RootType1.ts index 6a546d9df61..397c1eefa92 100644 --- a/seed/ts-express/inline-types/serialization/types/RootType1.ts +++ b/seed/ts-express/inline-types/serialization/types/RootType1.ts @@ -9,12 +9,23 @@ import * as core from "../../core"; export const RootType1: core.serialization.ObjectSchema = core.serialization.object({ foo: core.serialization.string(), - bar: core.serialization.lazyObject(() => serializers.InlineType1), + bar: core.serialization.lazyObject(() => serializers.RootType1InlineType1), + fooMap: core.serialization.record( + core.serialization.string(), + core.serialization.lazyObject(() => serializers.RootType1FooMapValue) + ), + fooList: core.serialization.list(core.serialization.lazyObject(() => serializers.RootType1FooListItem)), + fooSet: core.serialization.list(core.serialization.lazyObject(() => serializers.RootType1FooSetItem)), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), }); export declare namespace RootType1 { interface Raw { foo: string; - bar: serializers.InlineType1.Raw; + bar: serializers.RootType1InlineType1.Raw; + fooMap: Record; + fooList: serializers.RootType1FooListItem.Raw[]; + fooSet: serializers.RootType1FooSetItem.Raw[]; + ref: serializers.ReferenceType.Raw; } } diff --git a/seed/ts-express/inline-types/serialization/types/RootType1FooListItem.ts b/seed/ts-express/inline-types/serialization/types/RootType1FooListItem.ts new file mode 100644 index 00000000000..2b2652b46fb --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/RootType1FooListItem.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const RootType1FooListItem: core.serialization.ObjectSchema< + serializers.RootType1FooListItem.Raw, + SeedObject.RootType1FooListItem +> = core.serialization.object({ + foo: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace RootType1FooListItem { + interface Raw { + foo: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/RootType1FooMapValue.ts b/seed/ts-express/inline-types/serialization/types/RootType1FooMapValue.ts new file mode 100644 index 00000000000..7fc1a66c2dc --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/RootType1FooMapValue.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const RootType1FooMapValue: core.serialization.ObjectSchema< + serializers.RootType1FooMapValue.Raw, + SeedObject.RootType1FooMapValue +> = core.serialization.object({ + foo: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace RootType1FooMapValue { + interface Raw { + foo: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/RootType1FooSetItem.ts b/seed/ts-express/inline-types/serialization/types/RootType1FooSetItem.ts new file mode 100644 index 00000000000..d7662b9aaac --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/RootType1FooSetItem.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const RootType1FooSetItem: core.serialization.ObjectSchema< + serializers.RootType1FooSetItem.Raw, + SeedObject.RootType1FooSetItem +> = core.serialization.object({ + foo: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace RootType1FooSetItem { + interface Raw { + foo: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/RootType1InlineType1.ts b/seed/ts-express/inline-types/serialization/types/RootType1InlineType1.ts new file mode 100644 index 00000000000..e1c3dd7808e --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/RootType1InlineType1.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const RootType1InlineType1: core.serialization.ObjectSchema< + serializers.RootType1InlineType1.Raw, + SeedObject.RootType1InlineType1 +> = core.serialization.object({ + foo: core.serialization.string(), + bar: core.serialization.lazyObject(() => serializers.RootType1InlineType1NestedInlineType1), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace RootType1InlineType1 { + interface Raw { + foo: string; + bar: serializers.RootType1InlineType1NestedInlineType1.Raw; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/RootType1InlineType1NestedInlineType1.ts b/seed/ts-express/inline-types/serialization/types/RootType1InlineType1NestedInlineType1.ts new file mode 100644 index 00000000000..03d5a36a505 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/RootType1InlineType1NestedInlineType1.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const RootType1InlineType1NestedInlineType1: core.serialization.ObjectSchema< + serializers.RootType1InlineType1NestedInlineType1.Raw, + SeedObject.RootType1InlineType1NestedInlineType1 +> = core.serialization.object({ + foo: core.serialization.string(), + bar: core.serialization.string(), + myEnum: core.serialization.lazy(() => serializers.InlineEnum1), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace RootType1InlineType1NestedInlineType1 { + interface Raw { + foo: string; + bar: string; + myEnum: serializers.InlineEnum1.Raw; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1.ts new file mode 100644 index 00000000000..44df84c435b --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1: core.serialization.Schema< + serializers.UndiscriminatedUnion1.Raw, + SeedObject.UndiscriminatedUnion1 +> = core.serialization.undiscriminatedUnion([ + core.serialization.lazyObject(() => serializers.UndiscriminatedUnion1InlineType1), + core.serialization.lazyObject(() => serializers.UndiscriminatedUnion1InlineType2), + core.serialization.lazy(() => serializers.UndiscriminatedUnion1DiscriminatedUnion1), + core.serialization.lazy(() => serializers.UndiscriminatedUnion1DiscriminatedUnion1), + core.serialization.lazy(() => serializers.UndiscriminatedUnion1InlineEnum1), + core.serialization.lazy(() => serializers.UserId), + core.serialization.list(core.serialization.lazyObject(() => serializers.UndiscriminatedUnion1InlineListItem1)), + core.serialization.list(core.serialization.lazyObject(() => serializers.UndiscriminatedUnion1InlineSetItem1)), + core.serialization.record( + core.serialization.string(), + core.serialization.lazyObject(() => serializers.UndiscriminatedUnion1InlineMapItem1) + ), + core.serialization.lazyObject(() => serializers.ReferenceType), +]); + +export declare namespace UndiscriminatedUnion1 { + type Raw = + | serializers.UndiscriminatedUnion1InlineType1.Raw + | serializers.UndiscriminatedUnion1InlineType2.Raw + | serializers.UndiscriminatedUnion1DiscriminatedUnion1.Raw + | serializers.UndiscriminatedUnion1DiscriminatedUnion1.Raw + | serializers.UndiscriminatedUnion1InlineEnum1.Raw + | serializers.UserId.Raw + | serializers.UndiscriminatedUnion1InlineListItem1.Raw[] + | serializers.UndiscriminatedUnion1InlineSetItem1.Raw[] + | Record + | serializers.ReferenceType.Raw; +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1.ts new file mode 100644 index 00000000000..d1ed9a31bf9 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1DiscriminatedUnion1: core.serialization.Schema< + serializers.UndiscriminatedUnion1DiscriminatedUnion1.Raw, + SeedObject.UndiscriminatedUnion1DiscriminatedUnion1 +> = core.serialization + .union("type", { + type1: core.serialization.lazyObject(() => serializers.UndiscriminatedUnion1DiscriminatedUnion1InlineType1), + type2: core.serialization.lazyObject(() => serializers.UndiscriminatedUnion1DiscriminatedUnion1InlineType2), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), + }) + .transform({ + transform: (value) => value, + untransform: (value) => value, + }); + +export declare namespace UndiscriminatedUnion1DiscriminatedUnion1 { + type Raw = + | UndiscriminatedUnion1DiscriminatedUnion1.Type1 + | UndiscriminatedUnion1DiscriminatedUnion1.Type2 + | UndiscriminatedUnion1DiscriminatedUnion1.Ref; + + interface Type1 extends serializers.UndiscriminatedUnion1DiscriminatedUnion1InlineType1.Raw { + type: "type1"; + } + + interface Type2 extends serializers.UndiscriminatedUnion1DiscriminatedUnion1InlineType2.Raw { + type: "type2"; + } + + interface Ref extends serializers.ReferenceType.Raw { + type: "ref"; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1.ts new file mode 100644 index 00000000000..e424b6dc2ca --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1.ts @@ -0,0 +1,26 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1DiscriminatedUnion1InlineType1: core.serialization.ObjectSchema< + serializers.UndiscriminatedUnion1DiscriminatedUnion1InlineType1.Raw, + SeedObject.UndiscriminatedUnion1DiscriminatedUnion1InlineType1 +> = core.serialization.object({ + foo: core.serialization.string(), + bar: core.serialization.lazyObject( + () => serializers.UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1 + ), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace UndiscriminatedUnion1DiscriminatedUnion1InlineType1 { + interface Raw { + foo: string; + bar: serializers.UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.Raw; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.ts new file mode 100644 index 00000000000..6f54c38f225 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1: core.serialization.ObjectSchema< + serializers.UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.Raw, + SeedObject.UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1 +> = core.serialization.object({ + foo: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1 { + interface Raw { + foo: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType2.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType2.ts new file mode 100644 index 00000000000..676d1857453 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType2.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1DiscriminatedUnion1InlineType2: core.serialization.ObjectSchema< + serializers.UndiscriminatedUnion1DiscriminatedUnion1InlineType2.Raw, + SeedObject.UndiscriminatedUnion1DiscriminatedUnion1InlineType2 +> = core.serialization.object({ + baz: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace UndiscriminatedUnion1DiscriminatedUnion1InlineType2 { + interface Raw { + baz: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineEnum1.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineEnum1.ts new file mode 100644 index 00000000000..b6d7aa2e67e --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineEnum1.ts @@ -0,0 +1,16 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1InlineEnum1: core.serialization.Schema< + serializers.UndiscriminatedUnion1InlineEnum1.Raw, + SeedObject.UndiscriminatedUnion1InlineEnum1 +> = core.serialization.enum_(["SUNNY", "CLOUDY", "RAINING", "SNOWING"]); + +export declare namespace UndiscriminatedUnion1InlineEnum1 { + type Raw = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineListItem1.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineListItem1.ts new file mode 100644 index 00000000000..dbef4677983 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineListItem1.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1InlineListItem1: core.serialization.ObjectSchema< + serializers.UndiscriminatedUnion1InlineListItem1.Raw, + SeedObject.UndiscriminatedUnion1InlineListItem1 +> = core.serialization.object({ + foo: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace UndiscriminatedUnion1InlineListItem1 { + interface Raw { + foo: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineMapItem1.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineMapItem1.ts new file mode 100644 index 00000000000..10d8a7a151f --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineMapItem1.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1InlineMapItem1: core.serialization.ObjectSchema< + serializers.UndiscriminatedUnion1InlineMapItem1.Raw, + SeedObject.UndiscriminatedUnion1InlineMapItem1 +> = core.serialization.object({ + foo: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace UndiscriminatedUnion1InlineMapItem1 { + interface Raw { + foo: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineSetItem1.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineSetItem1.ts new file mode 100644 index 00000000000..b96ca054986 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineSetItem1.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1InlineSetItem1: core.serialization.ObjectSchema< + serializers.UndiscriminatedUnion1InlineSetItem1.Raw, + SeedObject.UndiscriminatedUnion1InlineSetItem1 +> = core.serialization.object({ + foo: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace UndiscriminatedUnion1InlineSetItem1 { + interface Raw { + foo: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineType1.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineType1.ts new file mode 100644 index 00000000000..a43be21e8b6 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineType1.ts @@ -0,0 +1,24 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1InlineType1: core.serialization.ObjectSchema< + serializers.UndiscriminatedUnion1InlineType1.Raw, + SeedObject.UndiscriminatedUnion1InlineType1 +> = core.serialization.object({ + foo: core.serialization.string(), + bar: core.serialization.lazyObject(() => serializers.UndiscriminatedUnion1InlineType1InlineType1), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace UndiscriminatedUnion1InlineType1 { + interface Raw { + foo: string; + bar: serializers.UndiscriminatedUnion1InlineType1InlineType1.Raw; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineType1InlineType1.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineType1InlineType1.ts new file mode 100644 index 00000000000..4fcddd84d91 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineType1InlineType1.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1InlineType1InlineType1: core.serialization.ObjectSchema< + serializers.UndiscriminatedUnion1InlineType1InlineType1.Raw, + SeedObject.UndiscriminatedUnion1InlineType1InlineType1 +> = core.serialization.object({ + foo: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace UndiscriminatedUnion1InlineType1InlineType1 { + interface Raw { + foo: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineType2.ts b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineType2.ts new file mode 100644 index 00000000000..7ea5bec5896 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UndiscriminatedUnion1InlineType2.ts @@ -0,0 +1,22 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UndiscriminatedUnion1InlineType2: core.serialization.ObjectSchema< + serializers.UndiscriminatedUnion1InlineType2.Raw, + SeedObject.UndiscriminatedUnion1InlineType2 +> = core.serialization.object({ + baz: core.serialization.string(), + ref: core.serialization.lazyObject(() => serializers.ReferenceType), +}); + +export declare namespace UndiscriminatedUnion1InlineType2 { + interface Raw { + baz: string; + ref: serializers.ReferenceType.Raw; + } +} diff --git a/seed/ts-express/inline-types/serialization/types/UserId.ts b/seed/ts-express/inline-types/serialization/types/UserId.ts new file mode 100644 index 00000000000..1ad9c4920f0 --- /dev/null +++ b/seed/ts-express/inline-types/serialization/types/UserId.ts @@ -0,0 +1,13 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as serializers from "../index"; +import * as SeedObject from "../../api/index"; +import * as core from "../../core"; + +export const UserId: core.serialization.Schema = core.serialization.string(); + +export declare namespace UserId { + type Raw = string; +} diff --git a/seed/ts-express/inline-types/serialization/types/index.ts b/seed/ts-express/inline-types/serialization/types/index.ts index bb183ec944a..57d21ed5261 100644 --- a/seed/ts-express/inline-types/serialization/types/index.ts +++ b/seed/ts-express/inline-types/serialization/types/index.ts @@ -1,7 +1,30 @@ +export * from "./AliasMapInline"; +export * from "./AliasSetInline"; +export * from "./AliasListInline"; +export * from "./AliasInlineValue"; +export * from "./RequestTypeInlineType1"; export * from "./RootType1"; -export * from "./InlineType1"; -export * from "./InlineType2"; -export * from "./NestedInlineType1"; -export * from "./InlinedDiscriminatedUnion1"; -export * from "./InlinedUndiscriminatedUnion1"; -export * from "./InlineEnum"; +export * from "./RootType1FooMapValue"; +export * from "./RootType1FooListItem"; +export * from "./RootType1FooSetItem"; +export * from "./RootType1InlineType1"; +export * from "./RootType1InlineType1NestedInlineType1"; +export * from "./DiscriminatedUnion1"; +export * from "./DiscriminatedUnion1InlineType1"; +export * from "./DiscriminatedUnion1InlineType1InlineType1"; +export * from "./DiscriminatedUnion1InlineType2"; +export * from "./UndiscriminatedUnion1"; +export * from "./UndiscriminatedUnion1InlineType1"; +export * from "./UndiscriminatedUnion1InlineType1InlineType1"; +export * from "./UndiscriminatedUnion1InlineType2"; +export * from "./InlineEnum1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1InlineType1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1InlineType2"; +export * from "./UndiscriminatedUnion1InlineEnum1"; +export * from "./UserId"; +export * from "./UndiscriminatedUnion1InlineListItem1"; +export * from "./UndiscriminatedUnion1InlineSetItem1"; +export * from "./UndiscriminatedUnion1InlineMapItem1"; +export * from "./ReferenceType"; diff --git a/seed/ts-express/mixed-case/no-custom-config/api/resources/service/types/Resource.ts b/seed/ts-express/mixed-case/no-custom-config/api/resources/service/types/Resource.ts index a57573e4223..07cc54e8be3 100644 --- a/seed/ts-express/mixed-case/no-custom-config/api/resources/service/types/Resource.ts +++ b/seed/ts-express/mixed-case/no-custom-config/api/resources/service/types/Resource.ts @@ -18,12 +18,12 @@ import * as SeedMixedCase from "../../../index"; */ export type Resource = SeedMixedCase.Resource.User | SeedMixedCase.Resource.Organization; -export declare namespace Resource { - interface User extends SeedMixedCase.User, _Base { +export namespace Resource { + export interface User extends SeedMixedCase.User, _Base { resourceType: "user"; } - interface Organization extends SeedMixedCase.Organization, _Base { + export interface Organization extends SeedMixedCase.Organization, _Base { resourceType: "Organization"; } diff --git a/seed/ts-express/mixed-case/no-custom-config/api/resources/service/types/ResourceStatus.ts b/seed/ts-express/mixed-case/no-custom-config/api/resources/service/types/ResourceStatus.ts index 62f07d2f99a..7205d324fcc 100644 --- a/seed/ts-express/mixed-case/no-custom-config/api/resources/service/types/ResourceStatus.ts +++ b/seed/ts-express/mixed-case/no-custom-config/api/resources/service/types/ResourceStatus.ts @@ -3,7 +3,6 @@ */ export type ResourceStatus = "ACTIVE" | "INACTIVE"; - export const ResourceStatus = { Active: "ACTIVE", Inactive: "INACTIVE", diff --git a/seed/ts-express/mixed-case/retain-original-casing/api/resources/service/types/Resource.ts b/seed/ts-express/mixed-case/retain-original-casing/api/resources/service/types/Resource.ts index b8366ea37d7..ef2a74911b0 100644 --- a/seed/ts-express/mixed-case/retain-original-casing/api/resources/service/types/Resource.ts +++ b/seed/ts-express/mixed-case/retain-original-casing/api/resources/service/types/Resource.ts @@ -18,12 +18,12 @@ import * as SeedMixedCase from "../../../index"; */ export type Resource = SeedMixedCase.Resource.User | SeedMixedCase.Resource.Organization; -export declare namespace Resource { - interface User extends SeedMixedCase.User, _Base { +export namespace Resource { + export interface User extends SeedMixedCase.User, _Base { resourceType: "user"; } - interface Organization extends SeedMixedCase.Organization, _Base { + export interface Organization extends SeedMixedCase.Organization, _Base { resourceType: "Organization"; } diff --git a/seed/ts-express/mixed-case/retain-original-casing/api/resources/service/types/ResourceStatus.ts b/seed/ts-express/mixed-case/retain-original-casing/api/resources/service/types/ResourceStatus.ts index 62f07d2f99a..7205d324fcc 100644 --- a/seed/ts-express/mixed-case/retain-original-casing/api/resources/service/types/ResourceStatus.ts +++ b/seed/ts-express/mixed-case/retain-original-casing/api/resources/service/types/ResourceStatus.ts @@ -3,7 +3,6 @@ */ export type ResourceStatus = "ACTIVE" | "INACTIVE"; - export const ResourceStatus = { Active: "ACTIVE", Inactive: "INACTIVE", diff --git a/seed/ts-express/multi-line-docs/api/types/Operand.ts b/seed/ts-express/multi-line-docs/api/types/Operand.ts index c7565c6f971..aaf4cd3090c 100644 --- a/seed/ts-express/multi-line-docs/api/types/Operand.ts +++ b/seed/ts-express/multi-line-docs/api/types/Operand.ts @@ -19,7 +19,6 @@ export type Operand = * The name and value should be similar * are similar for less than. */ | "less_than"; - export const Operand = { GreaterThan: ">", EqualTo: "=", diff --git a/seed/ts-express/objects-with-imports/api/resources/file/types/FileInfo.ts b/seed/ts-express/objects-with-imports/api/resources/file/types/FileInfo.ts index 26407d4b8aa..f2bc29c15db 100644 --- a/seed/ts-express/objects-with-imports/api/resources/file/types/FileInfo.ts +++ b/seed/ts-express/objects-with-imports/api/resources/file/types/FileInfo.ts @@ -16,7 +16,6 @@ export type FileInfo = /** * A directory (e.g. foo/). */ | "DIRECTORY"; - export const FileInfo = { Regular: "REGULAR", Directory: "DIRECTORY", diff --git a/seed/ts-express/pagination/api/resources/users/types/Order.ts b/seed/ts-express/pagination/api/resources/users/types/Order.ts index e5763cabff4..a6405828876 100644 --- a/seed/ts-express/pagination/api/resources/users/types/Order.ts +++ b/seed/ts-express/pagination/api/resources/users/types/Order.ts @@ -3,7 +3,6 @@ */ export type Order = "asc" | "desc"; - export const Order = { Asc: "asc", Desc: "desc", diff --git a/seed/ts-express/trace/no-custom-config/api/resources/admin/types/Test.ts b/seed/ts-express/trace/no-custom-config/api/resources/admin/types/Test.ts index 70dd2b7fc56..ae63f5ef12d 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/admin/types/Test.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/admin/types/Test.ts @@ -6,13 +6,13 @@ import * as SeedTrace from "../../../index"; export type Test = SeedTrace.Test.And | SeedTrace.Test.Or; -export declare namespace Test { - interface And { +export namespace Test { + export interface And { type: "and"; value: boolean; } - interface Or { + export interface Or { type: "or"; value: boolean; } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/commons/types/DebugVariableValue.ts b/seed/ts-express/trace/no-custom-config/api/resources/commons/types/DebugVariableValue.ts index 7c3eaed6311..ac7f88480fc 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/commons/types/DebugVariableValue.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/commons/types/DebugVariableValue.ts @@ -19,62 +19,62 @@ export type DebugVariableValue = | SeedTrace.DebugVariableValue.NullValue | SeedTrace.DebugVariableValue.GenericValue; -export declare namespace DebugVariableValue { - interface IntegerValue { +export namespace DebugVariableValue { + export interface IntegerValue { type: "integerValue"; value: number; } - interface BooleanValue { + export interface BooleanValue { type: "booleanValue"; value: boolean; } - interface DoubleValue { + export interface DoubleValue { type: "doubleValue"; value: number; } - interface StringValue { + export interface StringValue { type: "stringValue"; value: string; } - interface CharValue { + export interface CharValue { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.DebugMapValue { + export interface MapValue extends SeedTrace.DebugMapValue { type: "mapValue"; } - interface ListValue { + export interface ListValue { type: "listValue"; value: SeedTrace.DebugVariableValue[]; } - interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue { + export interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue { type: "binaryTreeNodeValue"; } - interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue { + export interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue { type: "singlyLinkedListNodeValue"; } - interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue { + export interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue { type: "doublyLinkedListNodeValue"; } - interface UndefinedValue { + export interface UndefinedValue { type: "undefinedValue"; } - interface NullValue { + export interface NullValue { type: "nullValue"; } - interface GenericValue extends SeedTrace.GenericValue { + export interface GenericValue extends SeedTrace.GenericValue { type: "genericValue"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/commons/types/Language.ts b/seed/ts-express/trace/no-custom-config/api/resources/commons/types/Language.ts index 0cc47c2d31f..7f1719a43ea 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/commons/types/Language.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/commons/types/Language.ts @@ -3,7 +3,6 @@ */ export type Language = "JAVA" | "JAVASCRIPT" | "PYTHON"; - export const Language = { Java: "JAVA", Javascript: "JAVASCRIPT", diff --git a/seed/ts-express/trace/no-custom-config/api/resources/commons/types/VariableType.ts b/seed/ts-express/trace/no-custom-config/api/resources/commons/types/VariableType.ts index 3725c71223d..d38a364dfe5 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/commons/types/VariableType.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/commons/types/VariableType.ts @@ -16,44 +16,44 @@ export type VariableType = | SeedTrace.VariableType.SinglyLinkedListType | SeedTrace.VariableType.DoublyLinkedListType; -export declare namespace VariableType { - interface IntegerType { +export namespace VariableType { + export interface IntegerType { type: "integerType"; } - interface DoubleType { + export interface DoubleType { type: "doubleType"; } - interface BooleanType { + export interface BooleanType { type: "booleanType"; } - interface StringType { + export interface StringType { type: "stringType"; } - interface CharType { + export interface CharType { type: "charType"; } - interface ListType extends SeedTrace.ListType { + export interface ListType extends SeedTrace.ListType { type: "listType"; } - interface MapType extends SeedTrace.MapType { + export interface MapType extends SeedTrace.MapType { type: "mapType"; } - interface BinaryTreeType { + export interface BinaryTreeType { type: "binaryTreeType"; } - interface SinglyLinkedListType { + export interface SinglyLinkedListType { type: "singlyLinkedListType"; } - interface DoublyLinkedListType { + export interface DoublyLinkedListType { type: "doublyLinkedListType"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/commons/types/VariableValue.ts b/seed/ts-express/trace/no-custom-config/api/resources/commons/types/VariableValue.ts index d73c90ca9d7..94240a2c2b4 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/commons/types/VariableValue.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/commons/types/VariableValue.ts @@ -17,54 +17,54 @@ export type VariableValue = | SeedTrace.VariableValue.DoublyLinkedListValue | SeedTrace.VariableValue.NullValue; -export declare namespace VariableValue { - interface IntegerValue { +export namespace VariableValue { + export interface IntegerValue { type: "integerValue"; value: number; } - interface BooleanValue { + export interface BooleanValue { type: "booleanValue"; value: boolean; } - interface DoubleValue { + export interface DoubleValue { type: "doubleValue"; value: number; } - interface StringValue { + export interface StringValue { type: "stringValue"; value: string; } - interface CharValue { + export interface CharValue { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.MapValue { + export interface MapValue extends SeedTrace.MapValue { type: "mapValue"; } - interface ListValue { + export interface ListValue { type: "listValue"; value: SeedTrace.VariableValue[]; } - interface BinaryTreeValue extends SeedTrace.BinaryTreeValue { + export interface BinaryTreeValue extends SeedTrace.BinaryTreeValue { type: "binaryTreeValue"; } - interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue { + export interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue { type: "singlyLinkedListValue"; } - interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue { + export interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue { type: "doublyLinkedListValue"; } - interface NullValue { + export interface NullValue { type: "nullValue"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/migration/types/MigrationStatus.ts b/seed/ts-express/trace/no-custom-config/api/resources/migration/types/MigrationStatus.ts index 0a6bc6f9b03..a38078ae2c0 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/migration/types/MigrationStatus.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/migration/types/MigrationStatus.ts @@ -10,7 +10,6 @@ export type MigrationStatus = * The migration is failed */ | "FAILED" | "FINISHED"; - export const MigrationStatus = { Running: "RUNNING", Failed: "FAILED", diff --git a/seed/ts-express/trace/no-custom-config/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts b/seed/ts-express/trace/no-custom-config/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts index 577034ea128..83901a81226 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts @@ -6,8 +6,8 @@ import * as SeedTrace from "../../../index"; export type PlaylistIdNotFoundErrorBody = SeedTrace.PlaylistIdNotFoundErrorBody.PlaylistId; -export declare namespace PlaylistIdNotFoundErrorBody { - interface PlaylistId { +export namespace PlaylistIdNotFoundErrorBody { + export interface PlaylistId { type: "playlistId"; value: SeedTrace.PlaylistId; } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/playlist/types/ReservedKeywordEnum.ts b/seed/ts-express/trace/no-custom-config/api/resources/playlist/types/ReservedKeywordEnum.ts index 8ccd3d4c13e..a77a48fd64a 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/playlist/types/ReservedKeywordEnum.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/playlist/types/ReservedKeywordEnum.ts @@ -3,7 +3,6 @@ */ export type ReservedKeywordEnum = "is" | "as"; - export const ReservedKeywordEnum = { Is: "is", As: "as", diff --git a/seed/ts-express/trace/no-custom-config/api/resources/problem/types/CreateProblemError.ts b/seed/ts-express/trace/no-custom-config/api/resources/problem/types/CreateProblemError.ts index 3543a716884..b49568ddd08 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/problem/types/CreateProblemError.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/problem/types/CreateProblemError.ts @@ -6,8 +6,8 @@ import * as SeedTrace from "../../../index"; export type CreateProblemError = SeedTrace.CreateProblemError.Generic; -export declare namespace CreateProblemError { - interface Generic extends SeedTrace.GenericCreateProblemError { +export namespace CreateProblemError { + export interface Generic extends SeedTrace.GenericCreateProblemError { errorType: "generic"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/problem/types/CreateProblemResponse.ts b/seed/ts-express/trace/no-custom-config/api/resources/problem/types/CreateProblemResponse.ts index 80f89cfcb84..0e4095cac69 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/problem/types/CreateProblemResponse.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/problem/types/CreateProblemResponse.ts @@ -6,13 +6,13 @@ import * as SeedTrace from "../../../index"; export type CreateProblemResponse = SeedTrace.CreateProblemResponse.Success | SeedTrace.CreateProblemResponse.Error_; -export declare namespace CreateProblemResponse { - interface Success { +export namespace CreateProblemResponse { + export interface Success { type: "success"; value: SeedTrace.ProblemId; } - interface Error_ { + export interface Error_ { type: "error"; value: SeedTrace.CreateProblemError; } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/problem/types/ProblemDescriptionBoard.ts b/seed/ts-express/trace/no-custom-config/api/resources/problem/types/ProblemDescriptionBoard.ts index ae5a369c3e7..efcc213fcbb 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/problem/types/ProblemDescriptionBoard.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/problem/types/ProblemDescriptionBoard.ts @@ -9,18 +9,18 @@ export type ProblemDescriptionBoard = | SeedTrace.ProblemDescriptionBoard.Variable | SeedTrace.ProblemDescriptionBoard.TestCaseId; -export declare namespace ProblemDescriptionBoard { - interface Html { +export namespace ProblemDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface Variable { + export interface Variable { type: "variable"; value: SeedTrace.VariableValue; } - interface TestCaseId { + export interface TestCaseId { type: "testCaseId"; value: string; } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ActualResult.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ActualResult.ts index 6986afad702..b78eb0c13b9 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ActualResult.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ActualResult.ts @@ -9,17 +9,17 @@ export type ActualResult = | SeedTrace.ActualResult.Exception | SeedTrace.ActualResult.ExceptionV2; -export declare namespace ActualResult { - interface Value { +export namespace ActualResult { + export interface Value { type: "value"; value: SeedTrace.VariableValue; } - interface Exception extends SeedTrace.ExceptionInfo { + export interface Exception extends SeedTrace.ExceptionInfo { type: "exception"; } - interface ExceptionV2 { + export interface ExceptionV2 { type: "exceptionV2"; value: SeedTrace.ExceptionV2; } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/CodeExecutionUpdate.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/CodeExecutionUpdate.ts index 7e17d4aa354..9e41b5a9000 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/CodeExecutionUpdate.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/CodeExecutionUpdate.ts @@ -39,48 +39,48 @@ export type CodeExecutionUpdate = * Sent once a submission is graded and fully recorded. */ | SeedTrace.CodeExecutionUpdate.Finished; -export declare namespace CodeExecutionUpdate { - interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse { +export namespace CodeExecutionUpdate { + export interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse { type: "buildingExecutor"; } - interface Running extends SeedTrace.RunningResponse { + export interface Running extends SeedTrace.RunningResponse { type: "running"; } - interface Errored extends SeedTrace.ErroredResponse { + export interface Errored extends SeedTrace.ErroredResponse { type: "errored"; } - interface Stopped extends SeedTrace.StoppedResponse { + export interface Stopped extends SeedTrace.StoppedResponse { type: "stopped"; } - interface Graded extends SeedTrace.GradedResponse { + export interface Graded extends SeedTrace.GradedResponse { type: "graded"; } - interface GradedV2 extends SeedTrace.GradedResponseV2 { + export interface GradedV2 extends SeedTrace.GradedResponseV2 { type: "gradedV2"; } - interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse { + export interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse { type: "workspaceRan"; } - interface Recording extends SeedTrace.RecordingResponseNotification { + export interface Recording extends SeedTrace.RecordingResponseNotification { type: "recording"; } - interface Recorded extends SeedTrace.RecordedResponseNotification { + export interface Recorded extends SeedTrace.RecordedResponseNotification { type: "recorded"; } - interface InvalidRequest extends SeedTrace.InvalidRequestResponse { + export interface InvalidRequest extends SeedTrace.InvalidRequestResponse { type: "invalidRequest"; } - interface Finished extends SeedTrace.FinishedResponse { + export interface Finished extends SeedTrace.FinishedResponse { type: "finished"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ErrorInfo.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ErrorInfo.ts index ef3283fe81e..ddb886b4c9a 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ErrorInfo.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ErrorInfo.ts @@ -15,16 +15,16 @@ export type ErrorInfo = * */ | SeedTrace.ErrorInfo.InternalError; -export declare namespace ErrorInfo { - interface CompileError extends SeedTrace.CompileError { +export namespace ErrorInfo { + export interface CompileError extends SeedTrace.CompileError { type: "compileError"; } - interface RuntimeError extends SeedTrace.RuntimeError { + export interface RuntimeError extends SeedTrace.RuntimeError { type: "runtimeError"; } - interface InternalError extends SeedTrace.InternalError { + export interface InternalError extends SeedTrace.InternalError { type: "internalError"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ExceptionV2.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ExceptionV2.ts index 880817d708d..f43362137ad 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ExceptionV2.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ExceptionV2.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type ExceptionV2 = SeedTrace.ExceptionV2.Generic | SeedTrace.ExceptionV2.Timeout; -export declare namespace ExceptionV2 { - interface Generic extends SeedTrace.ExceptionInfo { +export namespace ExceptionV2 { + export interface Generic extends SeedTrace.ExceptionInfo { type: "generic"; } - interface Timeout { + export interface Timeout { type: "timeout"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ExecutionSessionStatus.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ExecutionSessionStatus.ts index a14d2035332..3709aaa7a69 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ExecutionSessionStatus.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/ExecutionSessionStatus.ts @@ -9,7 +9,6 @@ export type ExecutionSessionStatus = | "RUNNING_CONTAINER" | "LIVE_CONTAINER" | "FAILED_TO_LAUNCH"; - export const ExecutionSessionStatus = { CreatingContainer: "CREATING_CONTAINER", ProvisioningContainer: "PROVISIONING_CONTAINER", diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/InvalidRequestCause.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/InvalidRequestCause.ts index 3bb60f89b0f..3504cf7eaa3 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/InvalidRequestCause.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/InvalidRequestCause.ts @@ -13,16 +13,16 @@ export type InvalidRequestCause = * The submission request was routed to an incorrect language executor. */ | SeedTrace.InvalidRequestCause.UnexpectedLanguage; -export declare namespace InvalidRequestCause { - interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound { +export namespace InvalidRequestCause { + export interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound { type: "submissionIdNotFound"; } - interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported { + export interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported { type: "customTestCasesUnsupported"; } - interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError { + export interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError { type: "unexpectedLanguage"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/RunningSubmissionState.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/RunningSubmissionState.ts index 5d15c5180a9..38031ccd887 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/RunningSubmissionState.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/RunningSubmissionState.ts @@ -8,7 +8,6 @@ export type RunningSubmissionState = | "WRITING_SUBMISSION_TO_FILE" | "COMPILING_SUBMISSION" | "RUNNING_SUBMISSION"; - export const RunningSubmissionState = { QueueingSubmission: "QUEUEING_SUBMISSION", KillingHistoricalSubmissions: "KILLING_HISTORICAL_SUBMISSIONS", diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionRequest.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionRequest.ts index e63f940c5b8..e4907b98e7c 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionRequest.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionRequest.ts @@ -11,24 +11,24 @@ export type SubmissionRequest = | SeedTrace.SubmissionRequest.WorkspaceSubmit | SeedTrace.SubmissionRequest.Stop; -export declare namespace SubmissionRequest { - interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest { +export namespace SubmissionRequest { + export interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest { type: "initializeProblemRequest"; } - interface InitializeWorkspaceRequest { + export interface InitializeWorkspaceRequest { type: "initializeWorkspaceRequest"; } - interface SubmitV2 extends SeedTrace.SubmitRequestV2 { + export interface SubmitV2 extends SeedTrace.SubmitRequestV2 { type: "submitV2"; } - interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest { + export interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest { type: "workspaceSubmit"; } - interface Stop extends SeedTrace.StopRequest { + export interface Stop extends SeedTrace.StopRequest { type: "stop"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionResponse.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionResponse.ts index d2fb3f8172f..ca463a332a6 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionResponse.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionResponse.ts @@ -12,30 +12,30 @@ export type SubmissionResponse = | SeedTrace.SubmissionResponse.CodeExecutionUpdate | SeedTrace.SubmissionResponse.Terminated; -export declare namespace SubmissionResponse { - interface ServerInitialized { +export namespace SubmissionResponse { + export interface ServerInitialized { type: "serverInitialized"; } - interface ProblemInitialized { + export interface ProblemInitialized { type: "problemInitialized"; value: SeedTrace.ProblemId; } - interface WorkspaceInitialized { + export interface WorkspaceInitialized { type: "workspaceInitialized"; } - interface ServerErrored extends SeedTrace.ExceptionInfo { + export interface ServerErrored extends SeedTrace.ExceptionInfo { type: "serverErrored"; } - interface CodeExecutionUpdate { + export interface CodeExecutionUpdate { type: "codeExecutionUpdate"; value: SeedTrace.CodeExecutionUpdate; } - interface Terminated extends SeedTrace.TerminatedResponse { + export interface Terminated extends SeedTrace.TerminatedResponse { type: "terminated"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionStatusForTestCase.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionStatusForTestCase.ts index 8698643d86b..dd0d6039fee 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionStatusForTestCase.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionStatusForTestCase.ts @@ -9,17 +9,17 @@ export type SubmissionStatusForTestCase = | SeedTrace.SubmissionStatusForTestCase.GradedV2 | SeedTrace.SubmissionStatusForTestCase.Traced; -export declare namespace SubmissionStatusForTestCase { - interface Graded extends SeedTrace.TestCaseResultWithStdout { +export namespace SubmissionStatusForTestCase { + export interface Graded extends SeedTrace.TestCaseResultWithStdout { type: "graded"; } - interface GradedV2 { + export interface GradedV2 { type: "gradedV2"; value: SeedTrace.TestCaseGrade; } - interface Traced extends SeedTrace.TracedTestCase { + export interface Traced extends SeedTrace.TracedTestCase { type: "traced"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionStatusV2.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionStatusV2.ts index 652c732c408..95710f67978 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionStatusV2.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionStatusV2.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type SubmissionStatusV2 = SeedTrace.SubmissionStatusV2.Test | SeedTrace.SubmissionStatusV2.Workspace; -export declare namespace SubmissionStatusV2 { - interface Test extends SeedTrace.TestSubmissionStatusV2 { +export namespace SubmissionStatusV2 { + export interface Test extends SeedTrace.TestSubmissionStatusV2 { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2 { + export interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2 { type: "workspace"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionTypeEnum.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionTypeEnum.ts index bff5583dad7..8414392abfc 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionTypeEnum.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionTypeEnum.ts @@ -6,7 +6,6 @@ * Keep in sync with SubmissionType. */ export type SubmissionTypeEnum = "TEST"; - export const SubmissionTypeEnum = { Test: "TEST", } as const; diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionTypeState.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionTypeState.ts index fa4855ce698..c811ee050db 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionTypeState.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/SubmissionTypeState.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type SubmissionTypeState = SeedTrace.SubmissionTypeState.Test | SeedTrace.SubmissionTypeState.Workspace; -export declare namespace SubmissionTypeState { - interface Test extends SeedTrace.TestSubmissionState { +export namespace SubmissionTypeState { + export interface Test extends SeedTrace.TestSubmissionState { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionState { + export interface Workspace extends SeedTrace.WorkspaceSubmissionState { type: "workspace"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestCaseGrade.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestCaseGrade.ts index 2f02296e05a..901cf5fc6ec 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestCaseGrade.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestCaseGrade.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type TestCaseGrade = SeedTrace.TestCaseGrade.Hidden | SeedTrace.TestCaseGrade.NonHidden; -export declare namespace TestCaseGrade { - interface Hidden extends SeedTrace.TestCaseHiddenGrade { +export namespace TestCaseGrade { + export interface Hidden extends SeedTrace.TestCaseHiddenGrade { type: "hidden"; } - interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade { + export interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade { type: "nonHidden"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestSubmissionStatus.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestSubmissionStatus.ts index da3e7c63984..04dc0c011e9 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestSubmissionStatus.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestSubmissionStatus.ts @@ -10,22 +10,22 @@ export type TestSubmissionStatus = | SeedTrace.TestSubmissionStatus.Running | SeedTrace.TestSubmissionStatus.TestCaseIdToState; -export declare namespace TestSubmissionStatus { - interface Stopped { +export namespace TestSubmissionStatus { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface TestCaseIdToState { + export interface TestCaseIdToState { type: "testCaseIdToState"; value: Record; } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestSubmissionUpdateInfo.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestSubmissionUpdateInfo.ts index 69a146a5067..f04f0e0479c 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestSubmissionUpdateInfo.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/TestSubmissionUpdateInfo.ts @@ -12,30 +12,30 @@ export type TestSubmissionUpdateInfo = | SeedTrace.TestSubmissionUpdateInfo.RecordedTestCase | SeedTrace.TestSubmissionUpdateInfo.Finished; -export declare namespace TestSubmissionUpdateInfo { - interface Running { +export namespace TestSubmissionUpdateInfo { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Stopped { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate { + export interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate { type: "gradedTestCase"; } - interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate { + export interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate { type: "recordedTestCase"; } - interface Finished { + export interface Finished { type: "finished"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/WorkspaceSubmissionStatus.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/WorkspaceSubmissionStatus.ts index 5151126e193..cad2d60cdae 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/WorkspaceSubmissionStatus.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/WorkspaceSubmissionStatus.ts @@ -11,26 +11,26 @@ export type WorkspaceSubmissionStatus = | SeedTrace.WorkspaceSubmissionStatus.Ran | SeedTrace.WorkspaceSubmissionStatus.Traced; -export declare namespace WorkspaceSubmissionStatus { - interface Stopped { +export namespace WorkspaceSubmissionStatus { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails { + export interface Ran extends SeedTrace.WorkspaceRunDetails { type: "ran"; } - interface Traced extends SeedTrace.WorkspaceRunDetails { + export interface Traced extends SeedTrace.WorkspaceRunDetails { type: "traced"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts index 78c1249225c..a8b008b38fb 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts @@ -13,34 +13,34 @@ export type WorkspaceSubmissionUpdateInfo = | SeedTrace.WorkspaceSubmissionUpdateInfo.Errored | SeedTrace.WorkspaceSubmissionUpdateInfo.Finished; -export declare namespace WorkspaceSubmissionUpdateInfo { - interface Running { +export namespace WorkspaceSubmissionUpdateInfo { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails { + export interface Ran extends SeedTrace.WorkspaceRunDetails { type: "ran"; } - interface Stopped { + export interface Stopped { type: "stopped"; } - interface Traced { + export interface Traced { type: "traced"; } - interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate { + export interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate { type: "tracedV2"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Finished { + export interface Finished { type: "finished"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts index 85c6b996461..d2be6b87b97 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts @@ -8,12 +8,12 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.AssertCorrectnessCheck.DeepEquality | SeedTrace.v2.AssertCorrectnessCheck.Custom; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult { type: "custom"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/CustomFiles.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/CustomFiles.ts index b430b089eaf..06ccba9d49d 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/CustomFiles.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/CustomFiles.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../index"; export type CustomFiles = SeedTrace.v2.CustomFiles.Basic | SeedTrace.v2.CustomFiles.Custom; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.BasicCustomFiles { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.BasicCustomFiles { type: "basic"; } - interface Custom { + export interface Custom { type: "custom"; value: Record; } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/FunctionSignature.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/FunctionSignature.ts index 251760cd97e..f4adeea0b90 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/FunctionSignature.ts @@ -11,16 +11,16 @@ export type FunctionSignature = * Useful when specifying custom grading for a testcase where actualResult is defined. */ | SeedTrace.v2.FunctionSignature.VoidThatTakesActualResult; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.VoidFunctionSignature { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.VoidFunctionSignature { type: "void"; } - interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature { + export interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult { + export interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult { type: "voidThatTakesActualResult"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseFunction.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseFunction.ts index c70bdafe6bb..cc8ea6e85c2 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseFunction.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../index"; export type TestCaseFunction = SeedTrace.v2.TestCaseFunction.WithActualResult | SeedTrace.v2.TestCaseFunction.Custom; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinition { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinition { type: "custom"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index af60df46b61..3a83452376c 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.TestCaseImplementationDescriptionBoard.Html | SeedTrace.v2.TestCaseImplementationDescriptionBoard.ParamId; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface ParamId { + export interface ParamId { type: "paramId"; value: SeedTrace.v2.ParameterId; } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts index 045115835ab..66182e14e9f 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationReference = | SeedTrace.v2.TestCaseImplementationReference.TemplateId | SeedTrace.v2.TestCaseImplementationReference.Implementation; -export declare namespace TestCaseImplementationReference { - interface TemplateId { +export namespace TestCaseImplementationReference { + export interface TemplateId { type: "templateId"; value: SeedTrace.v2.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.TestCaseImplementation { + export interface Implementation extends SeedTrace.v2.TestCaseImplementation { type: "implementation"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts index 79d32643560..2c0e9b49c7c 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts @@ -8,12 +8,12 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.v3.AssertCorrectnessCheck.DeepEquality | SeedTrace.v2.v3.AssertCorrectnessCheck.Custom; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult { type: "custom"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts index 4ac8078742b..c287f6286f3 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../../../index"; export type CustomFiles = SeedTrace.v2.v3.CustomFiles.Basic | SeedTrace.v2.v3.CustomFiles.Custom; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.v3.BasicCustomFiles { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.v3.BasicCustomFiles { type: "basic"; } - interface Custom { + export interface Custom { type: "custom"; value: Record; } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts index 548b1d9092b..82243201aba 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts @@ -11,16 +11,16 @@ export type FunctionSignature = * Useful when specifying custom grading for a testcase where actualResult is defined. */ | SeedTrace.v2.v3.FunctionSignature.VoidThatTakesActualResult; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.v3.VoidFunctionSignature { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.v3.VoidFunctionSignature { type: "void"; } - interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature { + export interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult { + export interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult { type: "voidThatTakesActualResult"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts index 2381196a692..031ff15274d 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts @@ -8,12 +8,12 @@ export type TestCaseFunction = | SeedTrace.v2.v3.TestCaseFunction.WithActualResult | SeedTrace.v2.v3.TestCaseFunction.Custom; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition { type: "custom"; } } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index 8d670c214fc..157e99b52ac 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.Html | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.ParamId; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface ParamId { + export interface ParamId { type: "paramId"; value: SeedTrace.v2.v3.ParameterId; } diff --git a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts index 0fad5ef9988..67af0e57047 100644 --- a/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-express/trace/no-custom-config/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationReference = | SeedTrace.v2.v3.TestCaseImplementationReference.TemplateId | SeedTrace.v2.v3.TestCaseImplementationReference.Implementation; -export declare namespace TestCaseImplementationReference { - interface TemplateId { +export namespace TestCaseImplementationReference { + export interface TemplateId { type: "templateId"; value: SeedTrace.v2.v3.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation { + export interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation { type: "implementation"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/admin/types/Test.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/admin/types/Test.ts index 70dd2b7fc56..ae63f5ef12d 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/admin/types/Test.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/admin/types/Test.ts @@ -6,13 +6,13 @@ import * as SeedTrace from "../../../index"; export type Test = SeedTrace.Test.And | SeedTrace.Test.Or; -export declare namespace Test { - interface And { +export namespace Test { + export interface And { type: "and"; value: boolean; } - interface Or { + export interface Or { type: "or"; value: boolean; } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/DebugVariableValue.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/DebugVariableValue.ts index 7c3eaed6311..ac7f88480fc 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/DebugVariableValue.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/DebugVariableValue.ts @@ -19,62 +19,62 @@ export type DebugVariableValue = | SeedTrace.DebugVariableValue.NullValue | SeedTrace.DebugVariableValue.GenericValue; -export declare namespace DebugVariableValue { - interface IntegerValue { +export namespace DebugVariableValue { + export interface IntegerValue { type: "integerValue"; value: number; } - interface BooleanValue { + export interface BooleanValue { type: "booleanValue"; value: boolean; } - interface DoubleValue { + export interface DoubleValue { type: "doubleValue"; value: number; } - interface StringValue { + export interface StringValue { type: "stringValue"; value: string; } - interface CharValue { + export interface CharValue { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.DebugMapValue { + export interface MapValue extends SeedTrace.DebugMapValue { type: "mapValue"; } - interface ListValue { + export interface ListValue { type: "listValue"; value: SeedTrace.DebugVariableValue[]; } - interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue { + export interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue { type: "binaryTreeNodeValue"; } - interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue { + export interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue { type: "singlyLinkedListNodeValue"; } - interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue { + export interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue { type: "doublyLinkedListNodeValue"; } - interface UndefinedValue { + export interface UndefinedValue { type: "undefinedValue"; } - interface NullValue { + export interface NullValue { type: "nullValue"; } - interface GenericValue extends SeedTrace.GenericValue { + export interface GenericValue extends SeedTrace.GenericValue { type: "genericValue"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/Language.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/Language.ts index 0cc47c2d31f..7f1719a43ea 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/Language.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/Language.ts @@ -3,7 +3,6 @@ */ export type Language = "JAVA" | "JAVASCRIPT" | "PYTHON"; - export const Language = { Java: "JAVA", Javascript: "JAVASCRIPT", diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/VariableType.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/VariableType.ts index 3725c71223d..d38a364dfe5 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/VariableType.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/VariableType.ts @@ -16,44 +16,44 @@ export type VariableType = | SeedTrace.VariableType.SinglyLinkedListType | SeedTrace.VariableType.DoublyLinkedListType; -export declare namespace VariableType { - interface IntegerType { +export namespace VariableType { + export interface IntegerType { type: "integerType"; } - interface DoubleType { + export interface DoubleType { type: "doubleType"; } - interface BooleanType { + export interface BooleanType { type: "booleanType"; } - interface StringType { + export interface StringType { type: "stringType"; } - interface CharType { + export interface CharType { type: "charType"; } - interface ListType extends SeedTrace.ListType { + export interface ListType extends SeedTrace.ListType { type: "listType"; } - interface MapType extends SeedTrace.MapType { + export interface MapType extends SeedTrace.MapType { type: "mapType"; } - interface BinaryTreeType { + export interface BinaryTreeType { type: "binaryTreeType"; } - interface SinglyLinkedListType { + export interface SinglyLinkedListType { type: "singlyLinkedListType"; } - interface DoublyLinkedListType { + export interface DoublyLinkedListType { type: "doublyLinkedListType"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/VariableValue.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/VariableValue.ts index d73c90ca9d7..94240a2c2b4 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/VariableValue.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/commons/types/VariableValue.ts @@ -17,54 +17,54 @@ export type VariableValue = | SeedTrace.VariableValue.DoublyLinkedListValue | SeedTrace.VariableValue.NullValue; -export declare namespace VariableValue { - interface IntegerValue { +export namespace VariableValue { + export interface IntegerValue { type: "integerValue"; value: number; } - interface BooleanValue { + export interface BooleanValue { type: "booleanValue"; value: boolean; } - interface DoubleValue { + export interface DoubleValue { type: "doubleValue"; value: number; } - interface StringValue { + export interface StringValue { type: "stringValue"; value: string; } - interface CharValue { + export interface CharValue { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.MapValue { + export interface MapValue extends SeedTrace.MapValue { type: "mapValue"; } - interface ListValue { + export interface ListValue { type: "listValue"; value: SeedTrace.VariableValue[]; } - interface BinaryTreeValue extends SeedTrace.BinaryTreeValue { + export interface BinaryTreeValue extends SeedTrace.BinaryTreeValue { type: "binaryTreeValue"; } - interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue { + export interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue { type: "singlyLinkedListValue"; } - interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue { + export interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue { type: "doublyLinkedListValue"; } - interface NullValue { + export interface NullValue { type: "nullValue"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/migration/types/MigrationStatus.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/migration/types/MigrationStatus.ts index 0a6bc6f9b03..a38078ae2c0 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/migration/types/MigrationStatus.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/migration/types/MigrationStatus.ts @@ -10,7 +10,6 @@ export type MigrationStatus = * The migration is failed */ | "FAILED" | "FINISHED"; - export const MigrationStatus = { Running: "RUNNING", Failed: "FAILED", diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts index 577034ea128..83901a81226 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts @@ -6,8 +6,8 @@ import * as SeedTrace from "../../../index"; export type PlaylistIdNotFoundErrorBody = SeedTrace.PlaylistIdNotFoundErrorBody.PlaylistId; -export declare namespace PlaylistIdNotFoundErrorBody { - interface PlaylistId { +export namespace PlaylistIdNotFoundErrorBody { + export interface PlaylistId { type: "playlistId"; value: SeedTrace.PlaylistId; } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/playlist/types/ReservedKeywordEnum.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/playlist/types/ReservedKeywordEnum.ts index 8ccd3d4c13e..a77a48fd64a 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/playlist/types/ReservedKeywordEnum.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/playlist/types/ReservedKeywordEnum.ts @@ -3,7 +3,6 @@ */ export type ReservedKeywordEnum = "is" | "as"; - export const ReservedKeywordEnum = { Is: "is", As: "as", diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/CreateProblemError.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/CreateProblemError.ts index e764e29d34c..c43c26296dc 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/CreateProblemError.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/CreateProblemError.ts @@ -6,8 +6,8 @@ import * as SeedTrace from "../../../index"; export type CreateProblemError = SeedTrace.CreateProblemError.Generic; -export declare namespace CreateProblemError { - interface Generic extends SeedTrace.GenericCreateProblemError { +export namespace CreateProblemError { + export interface Generic extends SeedTrace.GenericCreateProblemError { _type: "generic"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/CreateProblemResponse.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/CreateProblemResponse.ts index 80f89cfcb84..0e4095cac69 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/CreateProblemResponse.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/CreateProblemResponse.ts @@ -6,13 +6,13 @@ import * as SeedTrace from "../../../index"; export type CreateProblemResponse = SeedTrace.CreateProblemResponse.Success | SeedTrace.CreateProblemResponse.Error_; -export declare namespace CreateProblemResponse { - interface Success { +export namespace CreateProblemResponse { + export interface Success { type: "success"; value: SeedTrace.ProblemId; } - interface Error_ { + export interface Error_ { type: "error"; value: SeedTrace.CreateProblemError; } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/ProblemDescriptionBoard.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/ProblemDescriptionBoard.ts index ae5a369c3e7..efcc213fcbb 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/ProblemDescriptionBoard.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/problem/types/ProblemDescriptionBoard.ts @@ -9,18 +9,18 @@ export type ProblemDescriptionBoard = | SeedTrace.ProblemDescriptionBoard.Variable | SeedTrace.ProblemDescriptionBoard.TestCaseId; -export declare namespace ProblemDescriptionBoard { - interface Html { +export namespace ProblemDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface Variable { + export interface Variable { type: "variable"; value: SeedTrace.VariableValue; } - interface TestCaseId { + export interface TestCaseId { type: "testCaseId"; value: string; } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ActualResult.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ActualResult.ts index 6986afad702..b78eb0c13b9 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ActualResult.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ActualResult.ts @@ -9,17 +9,17 @@ export type ActualResult = | SeedTrace.ActualResult.Exception | SeedTrace.ActualResult.ExceptionV2; -export declare namespace ActualResult { - interface Value { +export namespace ActualResult { + export interface Value { type: "value"; value: SeedTrace.VariableValue; } - interface Exception extends SeedTrace.ExceptionInfo { + export interface Exception extends SeedTrace.ExceptionInfo { type: "exception"; } - interface ExceptionV2 { + export interface ExceptionV2 { type: "exceptionV2"; value: SeedTrace.ExceptionV2; } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/CodeExecutionUpdate.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/CodeExecutionUpdate.ts index 7e17d4aa354..9e41b5a9000 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/CodeExecutionUpdate.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/CodeExecutionUpdate.ts @@ -39,48 +39,48 @@ export type CodeExecutionUpdate = * Sent once a submission is graded and fully recorded. */ | SeedTrace.CodeExecutionUpdate.Finished; -export declare namespace CodeExecutionUpdate { - interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse { +export namespace CodeExecutionUpdate { + export interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse { type: "buildingExecutor"; } - interface Running extends SeedTrace.RunningResponse { + export interface Running extends SeedTrace.RunningResponse { type: "running"; } - interface Errored extends SeedTrace.ErroredResponse { + export interface Errored extends SeedTrace.ErroredResponse { type: "errored"; } - interface Stopped extends SeedTrace.StoppedResponse { + export interface Stopped extends SeedTrace.StoppedResponse { type: "stopped"; } - interface Graded extends SeedTrace.GradedResponse { + export interface Graded extends SeedTrace.GradedResponse { type: "graded"; } - interface GradedV2 extends SeedTrace.GradedResponseV2 { + export interface GradedV2 extends SeedTrace.GradedResponseV2 { type: "gradedV2"; } - interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse { + export interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse { type: "workspaceRan"; } - interface Recording extends SeedTrace.RecordingResponseNotification { + export interface Recording extends SeedTrace.RecordingResponseNotification { type: "recording"; } - interface Recorded extends SeedTrace.RecordedResponseNotification { + export interface Recorded extends SeedTrace.RecordedResponseNotification { type: "recorded"; } - interface InvalidRequest extends SeedTrace.InvalidRequestResponse { + export interface InvalidRequest extends SeedTrace.InvalidRequestResponse { type: "invalidRequest"; } - interface Finished extends SeedTrace.FinishedResponse { + export interface Finished extends SeedTrace.FinishedResponse { type: "finished"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ErrorInfo.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ErrorInfo.ts index ef3283fe81e..ddb886b4c9a 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ErrorInfo.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ErrorInfo.ts @@ -15,16 +15,16 @@ export type ErrorInfo = * */ | SeedTrace.ErrorInfo.InternalError; -export declare namespace ErrorInfo { - interface CompileError extends SeedTrace.CompileError { +export namespace ErrorInfo { + export interface CompileError extends SeedTrace.CompileError { type: "compileError"; } - interface RuntimeError extends SeedTrace.RuntimeError { + export interface RuntimeError extends SeedTrace.RuntimeError { type: "runtimeError"; } - interface InternalError extends SeedTrace.InternalError { + export interface InternalError extends SeedTrace.InternalError { type: "internalError"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ExceptionV2.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ExceptionV2.ts index 880817d708d..f43362137ad 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ExceptionV2.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ExceptionV2.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type ExceptionV2 = SeedTrace.ExceptionV2.Generic | SeedTrace.ExceptionV2.Timeout; -export declare namespace ExceptionV2 { - interface Generic extends SeedTrace.ExceptionInfo { +export namespace ExceptionV2 { + export interface Generic extends SeedTrace.ExceptionInfo { type: "generic"; } - interface Timeout { + export interface Timeout { type: "timeout"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ExecutionSessionStatus.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ExecutionSessionStatus.ts index a14d2035332..3709aaa7a69 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ExecutionSessionStatus.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/ExecutionSessionStatus.ts @@ -9,7 +9,6 @@ export type ExecutionSessionStatus = | "RUNNING_CONTAINER" | "LIVE_CONTAINER" | "FAILED_TO_LAUNCH"; - export const ExecutionSessionStatus = { CreatingContainer: "CREATING_CONTAINER", ProvisioningContainer: "PROVISIONING_CONTAINER", diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/InvalidRequestCause.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/InvalidRequestCause.ts index 3bb60f89b0f..3504cf7eaa3 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/InvalidRequestCause.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/InvalidRequestCause.ts @@ -13,16 +13,16 @@ export type InvalidRequestCause = * The submission request was routed to an incorrect language executor. */ | SeedTrace.InvalidRequestCause.UnexpectedLanguage; -export declare namespace InvalidRequestCause { - interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound { +export namespace InvalidRequestCause { + export interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound { type: "submissionIdNotFound"; } - interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported { + export interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported { type: "customTestCasesUnsupported"; } - interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError { + export interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError { type: "unexpectedLanguage"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/RunningSubmissionState.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/RunningSubmissionState.ts index 5d15c5180a9..38031ccd887 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/RunningSubmissionState.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/RunningSubmissionState.ts @@ -8,7 +8,6 @@ export type RunningSubmissionState = | "WRITING_SUBMISSION_TO_FILE" | "COMPILING_SUBMISSION" | "RUNNING_SUBMISSION"; - export const RunningSubmissionState = { QueueingSubmission: "QUEUEING_SUBMISSION", KillingHistoricalSubmissions: "KILLING_HISTORICAL_SUBMISSIONS", diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionRequest.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionRequest.ts index e63f940c5b8..e4907b98e7c 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionRequest.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionRequest.ts @@ -11,24 +11,24 @@ export type SubmissionRequest = | SeedTrace.SubmissionRequest.WorkspaceSubmit | SeedTrace.SubmissionRequest.Stop; -export declare namespace SubmissionRequest { - interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest { +export namespace SubmissionRequest { + export interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest { type: "initializeProblemRequest"; } - interface InitializeWorkspaceRequest { + export interface InitializeWorkspaceRequest { type: "initializeWorkspaceRequest"; } - interface SubmitV2 extends SeedTrace.SubmitRequestV2 { + export interface SubmitV2 extends SeedTrace.SubmitRequestV2 { type: "submitV2"; } - interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest { + export interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest { type: "workspaceSubmit"; } - interface Stop extends SeedTrace.StopRequest { + export interface Stop extends SeedTrace.StopRequest { type: "stop"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionResponse.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionResponse.ts index d2fb3f8172f..ca463a332a6 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionResponse.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionResponse.ts @@ -12,30 +12,30 @@ export type SubmissionResponse = | SeedTrace.SubmissionResponse.CodeExecutionUpdate | SeedTrace.SubmissionResponse.Terminated; -export declare namespace SubmissionResponse { - interface ServerInitialized { +export namespace SubmissionResponse { + export interface ServerInitialized { type: "serverInitialized"; } - interface ProblemInitialized { + export interface ProblemInitialized { type: "problemInitialized"; value: SeedTrace.ProblemId; } - interface WorkspaceInitialized { + export interface WorkspaceInitialized { type: "workspaceInitialized"; } - interface ServerErrored extends SeedTrace.ExceptionInfo { + export interface ServerErrored extends SeedTrace.ExceptionInfo { type: "serverErrored"; } - interface CodeExecutionUpdate { + export interface CodeExecutionUpdate { type: "codeExecutionUpdate"; value: SeedTrace.CodeExecutionUpdate; } - interface Terminated extends SeedTrace.TerminatedResponse { + export interface Terminated extends SeedTrace.TerminatedResponse { type: "terminated"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionStatusForTestCase.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionStatusForTestCase.ts index 8698643d86b..dd0d6039fee 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionStatusForTestCase.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionStatusForTestCase.ts @@ -9,17 +9,17 @@ export type SubmissionStatusForTestCase = | SeedTrace.SubmissionStatusForTestCase.GradedV2 | SeedTrace.SubmissionStatusForTestCase.Traced; -export declare namespace SubmissionStatusForTestCase { - interface Graded extends SeedTrace.TestCaseResultWithStdout { +export namespace SubmissionStatusForTestCase { + export interface Graded extends SeedTrace.TestCaseResultWithStdout { type: "graded"; } - interface GradedV2 { + export interface GradedV2 { type: "gradedV2"; value: SeedTrace.TestCaseGrade; } - interface Traced extends SeedTrace.TracedTestCase { + export interface Traced extends SeedTrace.TracedTestCase { type: "traced"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionStatusV2.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionStatusV2.ts index 652c732c408..95710f67978 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionStatusV2.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionStatusV2.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type SubmissionStatusV2 = SeedTrace.SubmissionStatusV2.Test | SeedTrace.SubmissionStatusV2.Workspace; -export declare namespace SubmissionStatusV2 { - interface Test extends SeedTrace.TestSubmissionStatusV2 { +export namespace SubmissionStatusV2 { + export interface Test extends SeedTrace.TestSubmissionStatusV2 { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2 { + export interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2 { type: "workspace"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionTypeEnum.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionTypeEnum.ts index bff5583dad7..8414392abfc 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionTypeEnum.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionTypeEnum.ts @@ -6,7 +6,6 @@ * Keep in sync with SubmissionType. */ export type SubmissionTypeEnum = "TEST"; - export const SubmissionTypeEnum = { Test: "TEST", } as const; diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionTypeState.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionTypeState.ts index fa4855ce698..c811ee050db 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionTypeState.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/SubmissionTypeState.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type SubmissionTypeState = SeedTrace.SubmissionTypeState.Test | SeedTrace.SubmissionTypeState.Workspace; -export declare namespace SubmissionTypeState { - interface Test extends SeedTrace.TestSubmissionState { +export namespace SubmissionTypeState { + export interface Test extends SeedTrace.TestSubmissionState { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionState { + export interface Workspace extends SeedTrace.WorkspaceSubmissionState { type: "workspace"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestCaseGrade.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestCaseGrade.ts index 2f02296e05a..901cf5fc6ec 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestCaseGrade.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestCaseGrade.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type TestCaseGrade = SeedTrace.TestCaseGrade.Hidden | SeedTrace.TestCaseGrade.NonHidden; -export declare namespace TestCaseGrade { - interface Hidden extends SeedTrace.TestCaseHiddenGrade { +export namespace TestCaseGrade { + export interface Hidden extends SeedTrace.TestCaseHiddenGrade { type: "hidden"; } - interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade { + export interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade { type: "nonHidden"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestSubmissionStatus.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestSubmissionStatus.ts index da3e7c63984..04dc0c011e9 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestSubmissionStatus.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestSubmissionStatus.ts @@ -10,22 +10,22 @@ export type TestSubmissionStatus = | SeedTrace.TestSubmissionStatus.Running | SeedTrace.TestSubmissionStatus.TestCaseIdToState; -export declare namespace TestSubmissionStatus { - interface Stopped { +export namespace TestSubmissionStatus { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface TestCaseIdToState { + export interface TestCaseIdToState { type: "testCaseIdToState"; value: Record; } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestSubmissionUpdateInfo.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestSubmissionUpdateInfo.ts index 69a146a5067..f04f0e0479c 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestSubmissionUpdateInfo.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/TestSubmissionUpdateInfo.ts @@ -12,30 +12,30 @@ export type TestSubmissionUpdateInfo = | SeedTrace.TestSubmissionUpdateInfo.RecordedTestCase | SeedTrace.TestSubmissionUpdateInfo.Finished; -export declare namespace TestSubmissionUpdateInfo { - interface Running { +export namespace TestSubmissionUpdateInfo { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Stopped { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate { + export interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate { type: "gradedTestCase"; } - interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate { + export interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate { type: "recordedTestCase"; } - interface Finished { + export interface Finished { type: "finished"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/WorkspaceSubmissionStatus.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/WorkspaceSubmissionStatus.ts index 5151126e193..cad2d60cdae 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/WorkspaceSubmissionStatus.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/WorkspaceSubmissionStatus.ts @@ -11,26 +11,26 @@ export type WorkspaceSubmissionStatus = | SeedTrace.WorkspaceSubmissionStatus.Ran | SeedTrace.WorkspaceSubmissionStatus.Traced; -export declare namespace WorkspaceSubmissionStatus { - interface Stopped { +export namespace WorkspaceSubmissionStatus { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails { + export interface Ran extends SeedTrace.WorkspaceRunDetails { type: "ran"; } - interface Traced extends SeedTrace.WorkspaceRunDetails { + export interface Traced extends SeedTrace.WorkspaceRunDetails { type: "traced"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts index 78c1249225c..a8b008b38fb 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts @@ -13,34 +13,34 @@ export type WorkspaceSubmissionUpdateInfo = | SeedTrace.WorkspaceSubmissionUpdateInfo.Errored | SeedTrace.WorkspaceSubmissionUpdateInfo.Finished; -export declare namespace WorkspaceSubmissionUpdateInfo { - interface Running { +export namespace WorkspaceSubmissionUpdateInfo { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails { + export interface Ran extends SeedTrace.WorkspaceRunDetails { type: "ran"; } - interface Stopped { + export interface Stopped { type: "stopped"; } - interface Traced { + export interface Traced { type: "traced"; } - interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate { + export interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate { type: "tracedV2"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Finished { + export interface Finished { type: "finished"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts index 85c6b996461..d2be6b87b97 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts @@ -8,12 +8,12 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.AssertCorrectnessCheck.DeepEquality | SeedTrace.v2.AssertCorrectnessCheck.Custom; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult { type: "custom"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/CustomFiles.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/CustomFiles.ts index b430b089eaf..06ccba9d49d 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/CustomFiles.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/CustomFiles.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../index"; export type CustomFiles = SeedTrace.v2.CustomFiles.Basic | SeedTrace.v2.CustomFiles.Custom; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.BasicCustomFiles { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.BasicCustomFiles { type: "basic"; } - interface Custom { + export interface Custom { type: "custom"; value: Record; } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/FunctionSignature.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/FunctionSignature.ts index 251760cd97e..f4adeea0b90 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/FunctionSignature.ts @@ -11,16 +11,16 @@ export type FunctionSignature = * Useful when specifying custom grading for a testcase where actualResult is defined. */ | SeedTrace.v2.FunctionSignature.VoidThatTakesActualResult; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.VoidFunctionSignature { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.VoidFunctionSignature { type: "void"; } - interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature { + export interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult { + export interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult { type: "voidThatTakesActualResult"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseFunction.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseFunction.ts index c70bdafe6bb..cc8ea6e85c2 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseFunction.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../index"; export type TestCaseFunction = SeedTrace.v2.TestCaseFunction.WithActualResult | SeedTrace.v2.TestCaseFunction.Custom; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinition { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinition { type: "custom"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index af60df46b61..3a83452376c 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.TestCaseImplementationDescriptionBoard.Html | SeedTrace.v2.TestCaseImplementationDescriptionBoard.ParamId; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface ParamId { + export interface ParamId { type: "paramId"; value: SeedTrace.v2.ParameterId; } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts index 045115835ab..66182e14e9f 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationReference = | SeedTrace.v2.TestCaseImplementationReference.TemplateId | SeedTrace.v2.TestCaseImplementationReference.Implementation; -export declare namespace TestCaseImplementationReference { - interface TemplateId { +export namespace TestCaseImplementationReference { + export interface TemplateId { type: "templateId"; value: SeedTrace.v2.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.TestCaseImplementation { + export interface Implementation extends SeedTrace.v2.TestCaseImplementation { type: "implementation"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts index 79d32643560..2c0e9b49c7c 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts @@ -8,12 +8,12 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.v3.AssertCorrectnessCheck.DeepEquality | SeedTrace.v2.v3.AssertCorrectnessCheck.Custom; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult { type: "custom"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts index 4ac8078742b..c287f6286f3 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../../../index"; export type CustomFiles = SeedTrace.v2.v3.CustomFiles.Basic | SeedTrace.v2.v3.CustomFiles.Custom; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.v3.BasicCustomFiles { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.v3.BasicCustomFiles { type: "basic"; } - interface Custom { + export interface Custom { type: "custom"; value: Record; } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts index 548b1d9092b..82243201aba 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts @@ -11,16 +11,16 @@ export type FunctionSignature = * Useful when specifying custom grading for a testcase where actualResult is defined. */ | SeedTrace.v2.v3.FunctionSignature.VoidThatTakesActualResult; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.v3.VoidFunctionSignature { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.v3.VoidFunctionSignature { type: "void"; } - interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature { + export interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult { + export interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult { type: "voidThatTakesActualResult"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts index 2381196a692..031ff15274d 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts @@ -8,12 +8,12 @@ export type TestCaseFunction = | SeedTrace.v2.v3.TestCaseFunction.WithActualResult | SeedTrace.v2.v3.TestCaseFunction.Custom; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition { type: "custom"; } } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index 8d670c214fc..157e99b52ac 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.Html | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.ParamId; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface ParamId { + export interface ParamId { type: "paramId"; value: SeedTrace.v2.v3.ParameterId; } diff --git a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts index 0fad5ef9988..67af0e57047 100644 --- a/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-express/trace/no-zurg-trace/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationReference = | SeedTrace.v2.v3.TestCaseImplementationReference.TemplateId | SeedTrace.v2.v3.TestCaseImplementationReference.Implementation; -export declare namespace TestCaseImplementationReference { - interface TemplateId { +export namespace TestCaseImplementationReference { + export interface TemplateId { type: "templateId"; value: SeedTrace.v2.v3.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation { + export interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation { type: "implementation"; } } diff --git a/seed/ts-express/undiscriminated-unions/api/resources/union/types/KeyType.ts b/seed/ts-express/undiscriminated-unions/api/resources/union/types/KeyType.ts index 90f84c1ff15..e40980b26f7 100644 --- a/seed/ts-express/undiscriminated-unions/api/resources/union/types/KeyType.ts +++ b/seed/ts-express/undiscriminated-unions/api/resources/union/types/KeyType.ts @@ -3,7 +3,6 @@ */ export type KeyType = "name" | "value"; - export const KeyType = { Name: "name", Value: "value", diff --git a/seed/ts-express/unions/api/resources/types/types/Union.ts b/seed/ts-express/unions/api/resources/types/types/Union.ts index 1215df193a6..fec56bcc719 100644 --- a/seed/ts-express/unions/api/resources/types/types/Union.ts +++ b/seed/ts-express/unions/api/resources/types/types/Union.ts @@ -9,13 +9,13 @@ import * as SeedUnions from "../../../index"; */ export type Union = SeedUnions.Union.Foo | SeedUnions.Union.Bar; -export declare namespace Union { - interface Foo { +export namespace Union { + export interface Foo { type: "foo"; foo: SeedUnions.Foo; } - interface Bar { + export interface Bar { type: "bar"; bar: SeedUnions.Bar; } diff --git a/seed/ts-express/unions/api/resources/types/types/UnionWithBaseProperties.ts b/seed/ts-express/unions/api/resources/types/types/UnionWithBaseProperties.ts index c70f3054c60..3933d4aa9af 100644 --- a/seed/ts-express/unions/api/resources/types/types/UnionWithBaseProperties.ts +++ b/seed/ts-express/unions/api/resources/types/types/UnionWithBaseProperties.ts @@ -9,18 +9,18 @@ export type UnionWithBaseProperties = | SeedUnions.UnionWithBaseProperties.String | SeedUnions.UnionWithBaseProperties.Foo; -export declare namespace UnionWithBaseProperties { - interface Integer extends _Base { +export namespace UnionWithBaseProperties { + export interface Integer extends _Base { type: "integer"; value: number; } - interface String extends _Base { + export interface String extends _Base { type: "string"; value: string; } - interface Foo extends SeedUnions.Foo, _Base { + export interface Foo extends SeedUnions.Foo, _Base { type: "foo"; } diff --git a/seed/ts-express/unions/api/resources/types/types/UnionWithDiscriminant.ts b/seed/ts-express/unions/api/resources/types/types/UnionWithDiscriminant.ts index a5f1174798a..0d5b2c23e7c 100644 --- a/seed/ts-express/unions/api/resources/types/types/UnionWithDiscriminant.ts +++ b/seed/ts-express/unions/api/resources/types/types/UnionWithDiscriminant.ts @@ -9,13 +9,13 @@ export type UnionWithDiscriminant = * This is a Foo field. */ SeedUnions.UnionWithDiscriminant.Foo | SeedUnions.UnionWithDiscriminant.Bar; -export declare namespace UnionWithDiscriminant { - interface Foo { +export namespace UnionWithDiscriminant { + export interface Foo { type: "foo"; foo: SeedUnions.Foo; } - interface Bar { + export interface Bar { type: "bar"; bar: SeedUnions.Bar; } diff --git a/seed/ts-express/unions/api/resources/types/types/UnionWithLiteral.ts b/seed/ts-express/unions/api/resources/types/types/UnionWithLiteral.ts index 673303d649d..525d54b9031 100644 --- a/seed/ts-express/unions/api/resources/types/types/UnionWithLiteral.ts +++ b/seed/ts-express/unions/api/resources/types/types/UnionWithLiteral.ts @@ -6,8 +6,8 @@ import * as SeedUnions from "../../../index"; export type UnionWithLiteral = SeedUnions.UnionWithLiteral.Fern; -export declare namespace UnionWithLiteral { - interface Fern extends _Base { +export namespace UnionWithLiteral { + export interface Fern extends _Base { type: "fern"; value: "fern"; } diff --git a/seed/ts-express/unions/api/resources/types/types/UnionWithOptionalTime.ts b/seed/ts-express/unions/api/resources/types/types/UnionWithOptionalTime.ts index d5e2ea06176..2bfb3525ca8 100644 --- a/seed/ts-express/unions/api/resources/types/types/UnionWithOptionalTime.ts +++ b/seed/ts-express/unions/api/resources/types/types/UnionWithOptionalTime.ts @@ -6,13 +6,13 @@ import * as SeedUnions from "../../../index"; export type UnionWithOptionalTime = SeedUnions.UnionWithOptionalTime.Date_ | SeedUnions.UnionWithOptionalTime.Dateimte; -export declare namespace UnionWithOptionalTime { - interface Date_ { +export namespace UnionWithOptionalTime { + export interface Date_ { type: "date"; value?: string; } - interface Dateimte { + export interface Dateimte { type: "dateimte"; value?: Date; } diff --git a/seed/ts-express/unions/api/resources/types/types/UnionWithPrimitive.ts b/seed/ts-express/unions/api/resources/types/types/UnionWithPrimitive.ts index a5d0519e952..014c915649f 100644 --- a/seed/ts-express/unions/api/resources/types/types/UnionWithPrimitive.ts +++ b/seed/ts-express/unions/api/resources/types/types/UnionWithPrimitive.ts @@ -6,13 +6,13 @@ import * as SeedUnions from "../../../index"; export type UnionWithPrimitive = SeedUnions.UnionWithPrimitive.Integer | SeedUnions.UnionWithPrimitive.String; -export declare namespace UnionWithPrimitive { - interface Integer { +export namespace UnionWithPrimitive { + export interface Integer { type: "integer"; value: number; } - interface String { + export interface String { type: "string"; value: string; } diff --git a/seed/ts-express/unions/api/resources/types/types/UnionWithSingleElement.ts b/seed/ts-express/unions/api/resources/types/types/UnionWithSingleElement.ts index d5e0f9631ac..4be05880cb1 100644 --- a/seed/ts-express/unions/api/resources/types/types/UnionWithSingleElement.ts +++ b/seed/ts-express/unions/api/resources/types/types/UnionWithSingleElement.ts @@ -6,8 +6,8 @@ import * as SeedUnions from "../../../index"; export type UnionWithSingleElement = SeedUnions.UnionWithSingleElement.Foo; -export declare namespace UnionWithSingleElement { - interface Foo extends SeedUnions.Foo { +export namespace UnionWithSingleElement { + export interface Foo extends SeedUnions.Foo { type: "foo"; } } diff --git a/seed/ts-express/unions/api/resources/types/types/UnionWithTime.ts b/seed/ts-express/unions/api/resources/types/types/UnionWithTime.ts index 210ef6fef03..dd937debe01 100644 --- a/seed/ts-express/unions/api/resources/types/types/UnionWithTime.ts +++ b/seed/ts-express/unions/api/resources/types/types/UnionWithTime.ts @@ -9,18 +9,18 @@ export type UnionWithTime = | SeedUnions.UnionWithTime.Date_ | SeedUnions.UnionWithTime.Datetime; -export declare namespace UnionWithTime { - interface Value { +export namespace UnionWithTime { + export interface Value { type: "value"; value: number; } - interface Date_ { + export interface Date_ { type: "date"; value: string; } - interface Datetime { + export interface Datetime { type: "datetime"; value: Date; } diff --git a/seed/ts-express/unions/api/resources/types/types/UnionWithUnknown.ts b/seed/ts-express/unions/api/resources/types/types/UnionWithUnknown.ts index e05d672181a..59972746956 100644 --- a/seed/ts-express/unions/api/resources/types/types/UnionWithUnknown.ts +++ b/seed/ts-express/unions/api/resources/types/types/UnionWithUnknown.ts @@ -6,12 +6,12 @@ import * as SeedUnions from "../../../index"; export type UnionWithUnknown = SeedUnions.UnionWithUnknown.Foo | SeedUnions.UnionWithUnknown.Unknown; -export declare namespace UnionWithUnknown { - interface Foo extends SeedUnions.Foo { +export namespace UnionWithUnknown { + export interface Foo extends SeedUnions.Foo { type: "foo"; } - interface Unknown { + export interface Unknown { type: "unknown"; } } diff --git a/seed/ts-express/unions/api/resources/types/types/UnionWithoutKey.ts b/seed/ts-express/unions/api/resources/types/types/UnionWithoutKey.ts index 037fb65ab12..b4918e2526f 100644 --- a/seed/ts-express/unions/api/resources/types/types/UnionWithoutKey.ts +++ b/seed/ts-express/unions/api/resources/types/types/UnionWithoutKey.ts @@ -10,12 +10,12 @@ export type UnionWithoutKey = * This is a bar field. */ | SeedUnions.UnionWithoutKey.Bar; -export declare namespace UnionWithoutKey { - interface Foo extends SeedUnions.Foo { +export namespace UnionWithoutKey { + export interface Foo extends SeedUnions.Foo { type: "foo"; } - interface Bar extends SeedUnions.Bar { + export interface Bar extends SeedUnions.Bar { type: "bar"; } } diff --git a/seed/ts-express/unions/api/resources/union/types/Shape.ts b/seed/ts-express/unions/api/resources/union/types/Shape.ts index 95d573a7a36..d46544c5c5d 100644 --- a/seed/ts-express/unions/api/resources/union/types/Shape.ts +++ b/seed/ts-express/unions/api/resources/union/types/Shape.ts @@ -6,12 +6,12 @@ import * as SeedUnions from "../../../index"; export type Shape = SeedUnions.Shape.Circle | SeedUnions.Shape.Square; -export declare namespace Shape { - interface Circle extends SeedUnions.Circle, _Base { +export namespace Shape { + export interface Circle extends SeedUnions.Circle, _Base { type: "circle"; } - interface Square extends SeedUnions.Square, _Base { + export interface Square extends SeedUnions.Square, _Base { type: "square"; } diff --git a/seed/ts-express/validation/api/types/Shape.ts b/seed/ts-express/validation/api/types/Shape.ts index 0d256b8b1c4..d80208737b9 100644 --- a/seed/ts-express/validation/api/types/Shape.ts +++ b/seed/ts-express/validation/api/types/Shape.ts @@ -3,7 +3,6 @@ */ export type Shape = "SQUARE" | "CIRCLE" | "TRIANGLE"; - export const Shape = { Square: "SQUARE", Circle: "CIRCLE", diff --git a/seed/ts-sdk/any-auth/src/Client.ts b/seed/ts-sdk/any-auth/src/Client.ts index 45f77a755b0..b25af8ab9b6 100644 --- a/seed/ts-sdk/any-auth/src/Client.ts +++ b/seed/ts-sdk/any-auth/src/Client.ts @@ -29,6 +29,8 @@ export declare namespace SeedAnyAuthClient { export class SeedAnyAuthClient { private readonly _oauthTokenProvider: core.OAuthTokenProvider; + protected _auth: Auth | undefined; + protected _user: User | undefined; constructor(protected readonly _options: SeedAnyAuthClient.Options) { const clientId = this._options.clientId ?? process.env["MY_CLIENT_ID"]; @@ -54,8 +56,6 @@ export class SeedAnyAuthClient { }); } - protected _auth: Auth | undefined; - public get auth(): Auth { return (this._auth ??= new Auth({ ...this._options, @@ -63,8 +63,6 @@ export class SeedAnyAuthClient { })); } - protected _user: User | undefined; - public get user(): User { return (this._user ??= new User({ ...this._options, diff --git a/seed/ts-sdk/api-wide-base-path/src/Client.ts b/seed/ts-sdk/api-wide-base-path/src/Client.ts index 740060cfeb5..0f7902ce3b9 100644 --- a/seed/ts-sdk/api-wide-base-path/src/Client.ts +++ b/seed/ts-sdk/api-wide-base-path/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedApiWideBasePathClient { } export class SeedApiWideBasePathClient { - constructor(protected readonly _options: SeedApiWideBasePathClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedApiWideBasePathClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/audiences/no-custom-config/src/Client.ts b/seed/ts-sdk/audiences/no-custom-config/src/Client.ts index d22419839b1..c6205ef10e9 100644 --- a/seed/ts-sdk/audiences/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/audiences/no-custom-config/src/Client.ts @@ -26,22 +26,20 @@ export declare namespace SeedAudiencesClient { } export class SeedAudiencesClient { - constructor(protected readonly _options: SeedAudiencesClient.Options) {} - protected _folderA: FolderA | undefined; + protected _folderD: FolderD | undefined; + protected _foo: Foo | undefined; + + constructor(protected readonly _options: SeedAudiencesClient.Options) {} public get folderA(): FolderA { return (this._folderA ??= new FolderA(this._options)); } - protected _folderD: FolderD | undefined; - public get folderD(): FolderD { return (this._folderD ??= new FolderD(this._options)); } - protected _foo: Foo | undefined; - public get foo(): Foo { return (this._foo ??= new Foo(this._options)); } diff --git a/seed/ts-sdk/audiences/no-custom-config/src/api/resources/folderA/client/Client.ts b/seed/ts-sdk/audiences/no-custom-config/src/api/resources/folderA/client/Client.ts index eb30358e2c9..56f024fc889 100644 --- a/seed/ts-sdk/audiences/no-custom-config/src/api/resources/folderA/client/Client.ts +++ b/seed/ts-sdk/audiences/no-custom-config/src/api/resources/folderA/client/Client.ts @@ -24,10 +24,10 @@ export declare namespace FolderA { } export class FolderA { - constructor(protected readonly _options: FolderA.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: FolderA.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/audiences/no-custom-config/src/api/resources/folderD/client/Client.ts b/seed/ts-sdk/audiences/no-custom-config/src/api/resources/folderD/client/Client.ts index bc2daead282..895b670d53b 100644 --- a/seed/ts-sdk/audiences/no-custom-config/src/api/resources/folderD/client/Client.ts +++ b/seed/ts-sdk/audiences/no-custom-config/src/api/resources/folderD/client/Client.ts @@ -24,10 +24,10 @@ export declare namespace FolderD { } export class FolderD { - constructor(protected readonly _options: FolderD.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: FolderD.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/audiences/with-partner-audience/src/Client.ts b/seed/ts-sdk/audiences/with-partner-audience/src/Client.ts index 9cb5420954a..425b13be819 100644 --- a/seed/ts-sdk/audiences/with-partner-audience/src/Client.ts +++ b/seed/ts-sdk/audiences/with-partner-audience/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedAudiencesClient { } export class SeedAudiencesClient { - constructor(protected readonly _options: SeedAudiencesClient.Options) {} - protected _folderD: FolderD | undefined; + constructor(protected readonly _options: SeedAudiencesClient.Options) {} + public get folderD(): FolderD { return (this._folderD ??= new FolderD(this._options)); } diff --git a/seed/ts-sdk/audiences/with-partner-audience/src/api/resources/folderD/client/Client.ts b/seed/ts-sdk/audiences/with-partner-audience/src/api/resources/folderD/client/Client.ts index 3a085b790da..c5ea0e6e17c 100644 --- a/seed/ts-sdk/audiences/with-partner-audience/src/api/resources/folderD/client/Client.ts +++ b/seed/ts-sdk/audiences/with-partner-audience/src/api/resources/folderD/client/Client.ts @@ -23,10 +23,10 @@ export declare namespace FolderD { } export class FolderD { - constructor(protected readonly _options: FolderD.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: FolderD.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/auth-environment-variables/src/Client.ts b/seed/ts-sdk/auth-environment-variables/src/Client.ts index db99f8b24f4..df39c03d0a7 100644 --- a/seed/ts-sdk/auth-environment-variables/src/Client.ts +++ b/seed/ts-sdk/auth-environment-variables/src/Client.ts @@ -32,10 +32,10 @@ export declare namespace SeedAuthEnvironmentVariablesClient { } export class SeedAuthEnvironmentVariablesClient { - constructor(protected readonly _options: SeedAuthEnvironmentVariablesClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedAuthEnvironmentVariablesClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/basic-auth-environment-variables/src/Client.ts b/seed/ts-sdk/basic-auth-environment-variables/src/Client.ts index 035aac8211a..ed8da1e63e8 100644 --- a/seed/ts-sdk/basic-auth-environment-variables/src/Client.ts +++ b/seed/ts-sdk/basic-auth-environment-variables/src/Client.ts @@ -25,10 +25,10 @@ export declare namespace SeedBasicAuthEnvironmentVariablesClient { } export class SeedBasicAuthEnvironmentVariablesClient { - constructor(protected readonly _options: SeedBasicAuthEnvironmentVariablesClient.Options) {} - protected _basicAuth: BasicAuth | undefined; + constructor(protected readonly _options: SeedBasicAuthEnvironmentVariablesClient.Options) {} + public get basicAuth(): BasicAuth { return (this._basicAuth ??= new BasicAuth(this._options)); } diff --git a/seed/ts-sdk/basic-auth/src/Client.ts b/seed/ts-sdk/basic-auth/src/Client.ts index e178bc364bc..5f757f98ceb 100644 --- a/seed/ts-sdk/basic-auth/src/Client.ts +++ b/seed/ts-sdk/basic-auth/src/Client.ts @@ -25,10 +25,10 @@ export declare namespace SeedBasicAuthClient { } export class SeedBasicAuthClient { - constructor(protected readonly _options: SeedBasicAuthClient.Options) {} - protected _basicAuth: BasicAuth | undefined; + constructor(protected readonly _options: SeedBasicAuthClient.Options) {} + public get basicAuth(): BasicAuth { return (this._basicAuth ??= new BasicAuth(this._options)); } diff --git a/seed/ts-sdk/bearer-token-environment-variable/src/Client.ts b/seed/ts-sdk/bearer-token-environment-variable/src/Client.ts index 12dd0ac531b..536e2a04e2d 100644 --- a/seed/ts-sdk/bearer-token-environment-variable/src/Client.ts +++ b/seed/ts-sdk/bearer-token-environment-variable/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedBearerTokenEnvironmentVariableClient { } export class SeedBearerTokenEnvironmentVariableClient { - constructor(protected readonly _options: SeedBearerTokenEnvironmentVariableClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedBearerTokenEnvironmentVariableClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/bytes/src/Client.ts b/seed/ts-sdk/bytes/src/Client.ts index 5b809080e1e..19f3ec412ba 100644 --- a/seed/ts-sdk/bytes/src/Client.ts +++ b/seed/ts-sdk/bytes/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedBytesClient { } export class SeedBytesClient { - constructor(protected readonly _options: SeedBytesClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedBytesClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/ContainerValue.ts b/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/ContainerValue.ts index 04cfa4e089e..0377dd788a2 100644 --- a/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/ContainerValue.ts +++ b/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/ContainerValue.ts @@ -6,13 +6,13 @@ import * as SeedApi from "../../../index"; export type ContainerValue = SeedApi.ContainerValue.List | SeedApi.ContainerValue.Optional; -export declare namespace ContainerValue { - interface List { +export namespace ContainerValue { + export interface List { type: "list"; value: SeedApi.FieldValue[]; } - interface Optional { + export interface Optional { type: "optional"; value?: SeedApi.FieldValue; } diff --git a/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/FieldValue.ts b/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/FieldValue.ts index 30d0c699a91..0b114997310 100644 --- a/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/FieldValue.ts +++ b/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/FieldValue.ts @@ -9,17 +9,17 @@ export type FieldValue = | SeedApi.FieldValue.ObjectValue | SeedApi.FieldValue.ContainerValue; -export declare namespace FieldValue { - interface PrimitiveValue { +export namespace FieldValue { + export interface PrimitiveValue { type: "primitive_value"; value: SeedApi.PrimitiveValue; } - interface ObjectValue extends SeedApi.ObjectValue { + export interface ObjectValue extends SeedApi.ObjectValue { type: "object_value"; } - interface ContainerValue { + export interface ContainerValue { type: "container_value"; value: SeedApi.ContainerValue; } diff --git a/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/PrimitiveValue.ts b/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/PrimitiveValue.ts index 58baf11d749..1b01851df2f 100644 --- a/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/PrimitiveValue.ts +++ b/seed/ts-sdk/circular-references-advanced/src/api/resources/ast/types/PrimitiveValue.ts @@ -3,7 +3,6 @@ */ export type PrimitiveValue = "STRING" | "NUMBER"; - export const PrimitiveValue = { String: "STRING", Number: "NUMBER", diff --git a/seed/ts-sdk/circular-references/src/api/resources/ast/types/ContainerValue.ts b/seed/ts-sdk/circular-references/src/api/resources/ast/types/ContainerValue.ts index 04cfa4e089e..0377dd788a2 100644 --- a/seed/ts-sdk/circular-references/src/api/resources/ast/types/ContainerValue.ts +++ b/seed/ts-sdk/circular-references/src/api/resources/ast/types/ContainerValue.ts @@ -6,13 +6,13 @@ import * as SeedApi from "../../../index"; export type ContainerValue = SeedApi.ContainerValue.List | SeedApi.ContainerValue.Optional; -export declare namespace ContainerValue { - interface List { +export namespace ContainerValue { + export interface List { type: "list"; value: SeedApi.FieldValue[]; } - interface Optional { + export interface Optional { type: "optional"; value?: SeedApi.FieldValue; } diff --git a/seed/ts-sdk/circular-references/src/api/resources/ast/types/FieldValue.ts b/seed/ts-sdk/circular-references/src/api/resources/ast/types/FieldValue.ts index 30d0c699a91..0b114997310 100644 --- a/seed/ts-sdk/circular-references/src/api/resources/ast/types/FieldValue.ts +++ b/seed/ts-sdk/circular-references/src/api/resources/ast/types/FieldValue.ts @@ -9,17 +9,17 @@ export type FieldValue = | SeedApi.FieldValue.ObjectValue | SeedApi.FieldValue.ContainerValue; -export declare namespace FieldValue { - interface PrimitiveValue { +export namespace FieldValue { + export interface PrimitiveValue { type: "primitive_value"; value: SeedApi.PrimitiveValue; } - interface ObjectValue extends SeedApi.ObjectValue { + export interface ObjectValue extends SeedApi.ObjectValue { type: "object_value"; } - interface ContainerValue { + export interface ContainerValue { type: "container_value"; value: SeedApi.ContainerValue; } diff --git a/seed/ts-sdk/circular-references/src/api/resources/ast/types/PrimitiveValue.ts b/seed/ts-sdk/circular-references/src/api/resources/ast/types/PrimitiveValue.ts index 58baf11d749..1b01851df2f 100644 --- a/seed/ts-sdk/circular-references/src/api/resources/ast/types/PrimitiveValue.ts +++ b/seed/ts-sdk/circular-references/src/api/resources/ast/types/PrimitiveValue.ts @@ -3,7 +3,6 @@ */ export type PrimitiveValue = "STRING" | "NUMBER"; - export const PrimitiveValue = { String: "STRING", Number: "NUMBER", diff --git a/seed/ts-sdk/cross-package-type-names/src/Client.ts b/seed/ts-sdk/cross-package-type-names/src/Client.ts index 156252ec396..a6270ec4b53 100644 --- a/seed/ts-sdk/cross-package-type-names/src/Client.ts +++ b/seed/ts-sdk/cross-package-type-names/src/Client.ts @@ -25,22 +25,20 @@ export declare namespace SeedCrossPackageTypeNamesClient { } export class SeedCrossPackageTypeNamesClient { - constructor(protected readonly _options: SeedCrossPackageTypeNamesClient.Options) {} - protected _folderA: FolderA | undefined; + protected _folderD: FolderD | undefined; + protected _foo: Foo | undefined; + + constructor(protected readonly _options: SeedCrossPackageTypeNamesClient.Options) {} public get folderA(): FolderA { return (this._folderA ??= new FolderA(this._options)); } - protected _folderD: FolderD | undefined; - public get folderD(): FolderD { return (this._folderD ??= new FolderD(this._options)); } - protected _foo: Foo | undefined; - public get foo(): Foo { return (this._foo ??= new Foo(this._options)); } diff --git a/seed/ts-sdk/cross-package-type-names/src/api/resources/folderA/client/Client.ts b/seed/ts-sdk/cross-package-type-names/src/api/resources/folderA/client/Client.ts index 5aa684888bd..524f39daaa0 100644 --- a/seed/ts-sdk/cross-package-type-names/src/api/resources/folderA/client/Client.ts +++ b/seed/ts-sdk/cross-package-type-names/src/api/resources/folderA/client/Client.ts @@ -23,10 +23,10 @@ export declare namespace FolderA { } export class FolderA { - constructor(protected readonly _options: FolderA.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: FolderA.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/cross-package-type-names/src/api/resources/folderD/client/Client.ts b/seed/ts-sdk/cross-package-type-names/src/api/resources/folderD/client/Client.ts index 3a085b790da..c5ea0e6e17c 100644 --- a/seed/ts-sdk/cross-package-type-names/src/api/resources/folderD/client/Client.ts +++ b/seed/ts-sdk/cross-package-type-names/src/api/resources/folderD/client/Client.ts @@ -23,10 +23,10 @@ export declare namespace FolderD { } export class FolderD { - constructor(protected readonly _options: FolderD.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: FolderD.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/custom-auth/src/Client.ts b/seed/ts-sdk/custom-auth/src/Client.ts index 74409ceb17a..d4855a6f33a 100644 --- a/seed/ts-sdk/custom-auth/src/Client.ts +++ b/seed/ts-sdk/custom-auth/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedCustomAuthClient { } export class SeedCustomAuthClient { - constructor(protected readonly _options: SeedCustomAuthClient.Options) {} - protected _customAuth: CustomAuth | undefined; + constructor(protected readonly _options: SeedCustomAuthClient.Options) {} + public get customAuth(): CustomAuth { return (this._customAuth ??= new CustomAuth(this._options)); } diff --git a/seed/ts-sdk/enum/src/Client.ts b/seed/ts-sdk/enum/src/Client.ts index 317d1772fc1..0a8562b1384 100644 --- a/seed/ts-sdk/enum/src/Client.ts +++ b/seed/ts-sdk/enum/src/Client.ts @@ -25,22 +25,20 @@ export declare namespace SeedEnumClient { } export class SeedEnumClient { - constructor(protected readonly _options: SeedEnumClient.Options) {} - protected _inlinedRequest: InlinedRequest | undefined; + protected _pathParam: PathParam | undefined; + protected _queryParam: QueryParam | undefined; + + constructor(protected readonly _options: SeedEnumClient.Options) {} public get inlinedRequest(): InlinedRequest { return (this._inlinedRequest ??= new InlinedRequest(this._options)); } - protected _pathParam: PathParam | undefined; - public get pathParam(): PathParam { return (this._pathParam ??= new PathParam(this._options)); } - protected _queryParam: QueryParam | undefined; - public get queryParam(): QueryParam { return (this._queryParam ??= new QueryParam(this._options)); } diff --git a/seed/ts-sdk/enum/src/api/types/Color.ts b/seed/ts-sdk/enum/src/api/types/Color.ts index 2fa67f67f83..fab9171627b 100644 --- a/seed/ts-sdk/enum/src/api/types/Color.ts +++ b/seed/ts-sdk/enum/src/api/types/Color.ts @@ -7,7 +7,6 @@ * SeedEnum.Color.Red */ export type Color = "red" | "blue"; - export const Color = { Red: "red", Blue: "blue", diff --git a/seed/ts-sdk/enum/src/api/types/Operand.ts b/seed/ts-sdk/enum/src/api/types/Operand.ts index b527c10e61b..b023f9444b9 100644 --- a/seed/ts-sdk/enum/src/api/types/Operand.ts +++ b/seed/ts-sdk/enum/src/api/types/Operand.ts @@ -19,7 +19,6 @@ export type Operand = * The name and value should be similar * are similar for less than. */ | "less_than"; - export const Operand = { GreaterThan: ">", EqualTo: "=", diff --git a/seed/ts-sdk/error-property/union-utils/src/Client.ts b/seed/ts-sdk/error-property/union-utils/src/Client.ts index bc1b9597428..ec8a1eb055e 100644 --- a/seed/ts-sdk/error-property/union-utils/src/Client.ts +++ b/seed/ts-sdk/error-property/union-utils/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedErrorPropertyClient { } export class SeedErrorPropertyClient { - constructor(protected readonly _options: SeedErrorPropertyClient.Options) {} - protected _propertyBasedError: PropertyBasedError | undefined; + constructor(protected readonly _options: SeedErrorPropertyClient.Options) {} + public get propertyBasedError(): PropertyBasedError { return (this._propertyBasedError ??= new PropertyBasedError(this._options)); } diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/Client.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/Client.ts index 98ed475d957..86550294c18 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/Client.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/Client.ts @@ -30,8 +30,24 @@ export declare namespace SeedExamplesClient { } export class SeedExamplesClient { + protected _file: File_ | undefined; + protected _health: Health | undefined; + protected _service: Service | undefined; + constructor(protected readonly _options: SeedExamplesClient.Options) {} + public get file(): File_ { + return (this._file ??= new File_(this._options)); + } + + public get health(): Health { + return (this._health ??= new Health(this._options)); + } + + public get service(): Service { + return (this._service ??= new Service(this._options)); + } + /** * @param {string} request * @param {SeedExamplesClient.RequestOptions} requestOptions - Request-specific configuration. @@ -153,24 +169,6 @@ export class SeedExamplesClient { } } - protected _file: File_ | undefined; - - public get file(): File_ { - return (this._file ??= new File_(this._options)); - } - - protected _health: Health | undefined; - - public get health(): Health { - return (this._health ??= new Health(this._options)); - } - - protected _service: Service | undefined; - - public get service(): Service { - return (this._service ??= new Service(this._options)); - } - protected async _getAuthorizationHeader(): Promise { const bearer = await core.Supplier.get(this._options.token); if (bearer != null) { diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/commons/resources/types/types/Data.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/commons/resources/types/types/Data.ts index ca73fda6852..ff6636b20e7 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/commons/resources/types/types/Data.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/commons/resources/types/types/Data.ts @@ -13,13 +13,13 @@ import * as SeedExamples from "../../../../../index"; */ export type Data = SeedExamples.commons.Data.String | SeedExamples.commons.Data.Base64; -export declare namespace Data { - interface String { +export namespace Data { + export interface String { type: "string"; value: string; } - interface Base64 { + export interface Base64 { type: "base64"; value: string; } diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/commons/resources/types/types/EventInfo.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/commons/resources/types/types/EventInfo.ts index 559f7726408..619f49001c6 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/commons/resources/types/types/EventInfo.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/commons/resources/types/types/EventInfo.ts @@ -17,12 +17,12 @@ import * as SeedExamples from "../../../../../index"; */ export type EventInfo = SeedExamples.commons.EventInfo.Metadata | SeedExamples.commons.EventInfo.Tag; -export declare namespace EventInfo { - interface Metadata extends SeedExamples.commons.Metadata { +export namespace EventInfo { + export interface Metadata extends SeedExamples.commons.Metadata { type: "metadata"; } - interface Tag { + export interface Tag { type: "tag"; value: SeedExamples.commons.Tag; } diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/file/client/Client.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/file/client/Client.ts index 215152278d5..9bb28c947a2 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/file/client/Client.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/file/client/Client.ts @@ -26,16 +26,15 @@ export declare namespace File_ { } export class File_ { - constructor(protected readonly _options: File_.Options) {} - protected _notification: Notification | undefined; + protected _service: Service | undefined; + + constructor(protected readonly _options: File_.Options) {} public get notification(): Notification { return (this._notification ??= new Notification(this._options)); } - protected _service: Service | undefined; - public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/file/resources/notification/client/Client.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/file/resources/notification/client/Client.ts index b60310ce619..b656ba4419e 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/file/resources/notification/client/Client.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/file/resources/notification/client/Client.ts @@ -25,10 +25,10 @@ export declare namespace Notification { } export class Notification { - constructor(protected readonly _options: Notification.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: Notification.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/health/client/Client.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/health/client/Client.ts index 08f634494cc..eeae565550f 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/health/client/Client.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/health/client/Client.ts @@ -25,10 +25,10 @@ export declare namespace Health { } export class Health { - constructor(protected readonly _options: Health.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: Health.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Exception.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Exception.ts index e83b4952829..11ef21c1f01 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Exception.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Exception.ts @@ -15,12 +15,12 @@ import * as SeedExamples from "../../../index"; */ export type Exception = SeedExamples.Exception.Generic | SeedExamples.Exception.Timeout; -export declare namespace Exception { - interface Generic extends SeedExamples.ExceptionInfo { +export namespace Exception { + export interface Generic extends SeedExamples.ExceptionInfo { type: "generic"; } - interface Timeout { + export interface Timeout { type: "timeout"; } } diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Metadata.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Metadata.ts index d35087a1c66..b99d4869a53 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Metadata.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Metadata.ts @@ -13,13 +13,13 @@ import * as SeedExamples from "../../../index"; */ export type Metadata = SeedExamples.Metadata.Html | SeedExamples.Metadata.Markdown; -export declare namespace Metadata { - interface Html extends _Base { +export namespace Metadata { + export interface Html extends _Base { type: "html"; value: string; } - interface Markdown extends _Base { + export interface Markdown extends _Base { type: "markdown"; value: string; } diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/MigrationStatus.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/MigrationStatus.ts index c45e7382155..11502aa2e9d 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/MigrationStatus.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/MigrationStatus.ts @@ -17,7 +17,6 @@ export type MigrationStatus = * The migration failed. */ | "FAILED" | "FINISHED"; - export const MigrationStatus = { Running: "RUNNING", Failed: "FAILED", diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Test.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Test.ts index c1d733da0eb..7fcc346381e 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Test.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/resources/types/types/Test.ts @@ -19,13 +19,13 @@ import * as SeedExamples from "../../../index"; */ export type Test = SeedExamples.Test.And | SeedExamples.Test.Or; -export declare namespace Test { - interface And { +export namespace Test { + export interface And { type: "and"; value: boolean; } - interface Or { + export interface Or { type: "or"; value: boolean; } diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/types/BasicType.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/types/BasicType.ts index 32e12a88016..d20f2862feb 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/types/BasicType.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/types/BasicType.ts @@ -3,7 +3,6 @@ */ export type BasicType = "primitive" | "literal"; - export const BasicType = { Primitive: "primitive", Literal: "literal", diff --git a/seed/ts-sdk/examples/examples-with-api-reference/src/api/types/ComplexType.ts b/seed/ts-sdk/examples/examples-with-api-reference/src/api/types/ComplexType.ts index f61ca784ac5..4ef541c74d4 100644 --- a/seed/ts-sdk/examples/examples-with-api-reference/src/api/types/ComplexType.ts +++ b/seed/ts-sdk/examples/examples-with-api-reference/src/api/types/ComplexType.ts @@ -3,7 +3,6 @@ */ export type ComplexType = "object" | "union" | "unknown"; - export const ComplexType = { Object: "object", Union: "union", diff --git a/seed/ts-sdk/examples/retain-original-casing/src/Client.ts b/seed/ts-sdk/examples/retain-original-casing/src/Client.ts index 98ed475d957..86550294c18 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/Client.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/Client.ts @@ -30,8 +30,24 @@ export declare namespace SeedExamplesClient { } export class SeedExamplesClient { + protected _file: File_ | undefined; + protected _health: Health | undefined; + protected _service: Service | undefined; + constructor(protected readonly _options: SeedExamplesClient.Options) {} + public get file(): File_ { + return (this._file ??= new File_(this._options)); + } + + public get health(): Health { + return (this._health ??= new Health(this._options)); + } + + public get service(): Service { + return (this._service ??= new Service(this._options)); + } + /** * @param {string} request * @param {SeedExamplesClient.RequestOptions} requestOptions - Request-specific configuration. @@ -153,24 +169,6 @@ export class SeedExamplesClient { } } - protected _file: File_ | undefined; - - public get file(): File_ { - return (this._file ??= new File_(this._options)); - } - - protected _health: Health | undefined; - - public get health(): Health { - return (this._health ??= new Health(this._options)); - } - - protected _service: Service | undefined; - - public get service(): Service { - return (this._service ??= new Service(this._options)); - } - protected async _getAuthorizationHeader(): Promise { const bearer = await core.Supplier.get(this._options.token); if (bearer != null) { diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/commons/resources/types/types/Data.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/commons/resources/types/types/Data.ts index ca73fda6852..ff6636b20e7 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/commons/resources/types/types/Data.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/commons/resources/types/types/Data.ts @@ -13,13 +13,13 @@ import * as SeedExamples from "../../../../../index"; */ export type Data = SeedExamples.commons.Data.String | SeedExamples.commons.Data.Base64; -export declare namespace Data { - interface String { +export namespace Data { + export interface String { type: "string"; value: string; } - interface Base64 { + export interface Base64 { type: "base64"; value: string; } diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/commons/resources/types/types/EventInfo.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/commons/resources/types/types/EventInfo.ts index 559f7726408..619f49001c6 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/commons/resources/types/types/EventInfo.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/commons/resources/types/types/EventInfo.ts @@ -17,12 +17,12 @@ import * as SeedExamples from "../../../../../index"; */ export type EventInfo = SeedExamples.commons.EventInfo.Metadata | SeedExamples.commons.EventInfo.Tag; -export declare namespace EventInfo { - interface Metadata extends SeedExamples.commons.Metadata { +export namespace EventInfo { + export interface Metadata extends SeedExamples.commons.Metadata { type: "metadata"; } - interface Tag { + export interface Tag { type: "tag"; value: SeedExamples.commons.Tag; } diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/file/client/Client.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/file/client/Client.ts index 215152278d5..9bb28c947a2 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/file/client/Client.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/file/client/Client.ts @@ -26,16 +26,15 @@ export declare namespace File_ { } export class File_ { - constructor(protected readonly _options: File_.Options) {} - protected _notification: Notification | undefined; + protected _service: Service | undefined; + + constructor(protected readonly _options: File_.Options) {} public get notification(): Notification { return (this._notification ??= new Notification(this._options)); } - protected _service: Service | undefined; - public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/file/resources/notification/client/Client.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/file/resources/notification/client/Client.ts index b60310ce619..b656ba4419e 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/file/resources/notification/client/Client.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/file/resources/notification/client/Client.ts @@ -25,10 +25,10 @@ export declare namespace Notification { } export class Notification { - constructor(protected readonly _options: Notification.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: Notification.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/health/client/Client.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/health/client/Client.ts index 08f634494cc..eeae565550f 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/health/client/Client.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/health/client/Client.ts @@ -25,10 +25,10 @@ export declare namespace Health { } export class Health { - constructor(protected readonly _options: Health.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: Health.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Exception.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Exception.ts index e83b4952829..11ef21c1f01 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Exception.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Exception.ts @@ -15,12 +15,12 @@ import * as SeedExamples from "../../../index"; */ export type Exception = SeedExamples.Exception.Generic | SeedExamples.Exception.Timeout; -export declare namespace Exception { - interface Generic extends SeedExamples.ExceptionInfo { +export namespace Exception { + export interface Generic extends SeedExamples.ExceptionInfo { type: "generic"; } - interface Timeout { + export interface Timeout { type: "timeout"; } } diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Metadata.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Metadata.ts index d35087a1c66..b99d4869a53 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Metadata.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Metadata.ts @@ -13,13 +13,13 @@ import * as SeedExamples from "../../../index"; */ export type Metadata = SeedExamples.Metadata.Html | SeedExamples.Metadata.Markdown; -export declare namespace Metadata { - interface Html extends _Base { +export namespace Metadata { + export interface Html extends _Base { type: "html"; value: string; } - interface Markdown extends _Base { + export interface Markdown extends _Base { type: "markdown"; value: string; } diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/MigrationStatus.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/MigrationStatus.ts index c45e7382155..11502aa2e9d 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/MigrationStatus.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/MigrationStatus.ts @@ -17,7 +17,6 @@ export type MigrationStatus = * The migration failed. */ | "FAILED" | "FINISHED"; - export const MigrationStatus = { Running: "RUNNING", Failed: "FAILED", diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Test.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Test.ts index c1d733da0eb..7fcc346381e 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Test.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/resources/types/types/Test.ts @@ -19,13 +19,13 @@ import * as SeedExamples from "../../../index"; */ export type Test = SeedExamples.Test.And | SeedExamples.Test.Or; -export declare namespace Test { - interface And { +export namespace Test { + export interface And { type: "and"; value: boolean; } - interface Or { + export interface Or { type: "or"; value: boolean; } diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/types/BasicType.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/types/BasicType.ts index 32e12a88016..d20f2862feb 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/types/BasicType.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/types/BasicType.ts @@ -3,7 +3,6 @@ */ export type BasicType = "primitive" | "literal"; - export const BasicType = { Primitive: "primitive", Literal: "literal", diff --git a/seed/ts-sdk/examples/retain-original-casing/src/api/types/ComplexType.ts b/seed/ts-sdk/examples/retain-original-casing/src/api/types/ComplexType.ts index f61ca784ac5..4ef541c74d4 100644 --- a/seed/ts-sdk/examples/retain-original-casing/src/api/types/ComplexType.ts +++ b/seed/ts-sdk/examples/retain-original-casing/src/api/types/ComplexType.ts @@ -3,7 +3,6 @@ */ export type ComplexType = "object" | "union" | "unknown"; - export const ComplexType = { Object: "object", Union: "union", diff --git a/seed/ts-sdk/exhaustive/allow-extra-fields/src/Client.ts b/seed/ts-sdk/exhaustive/allow-extra-fields/src/Client.ts index 9da7b36ff52..119821de7f2 100644 --- a/seed/ts-sdk/exhaustive/allow-extra-fields/src/Client.ts +++ b/seed/ts-sdk/exhaustive/allow-extra-fields/src/Client.ts @@ -28,34 +28,30 @@ export declare namespace SeedExhaustiveClient { } export class SeedExhaustiveClient { - constructor(protected readonly _options: SeedExhaustiveClient.Options) {} - protected _endpoints: Endpoints | undefined; + protected _inlinedRequests: InlinedRequests | undefined; + protected _noAuth: NoAuth | undefined; + protected _noReqBody: NoReqBody | undefined; + protected _reqWithHeaders: ReqWithHeaders | undefined; + + constructor(protected readonly _options: SeedExhaustiveClient.Options) {} public get endpoints(): Endpoints { return (this._endpoints ??= new Endpoints(this._options)); } - protected _inlinedRequests: InlinedRequests | undefined; - public get inlinedRequests(): InlinedRequests { return (this._inlinedRequests ??= new InlinedRequests(this._options)); } - protected _noAuth: NoAuth | undefined; - public get noAuth(): NoAuth { return (this._noAuth ??= new NoAuth(this._options)); } - protected _noReqBody: NoReqBody | undefined; - public get noReqBody(): NoReqBody { return (this._noReqBody ??= new NoReqBody(this._options)); } - protected _reqWithHeaders: ReqWithHeaders | undefined; - public get reqWithHeaders(): ReqWithHeaders { return (this._reqWithHeaders ??= new ReqWithHeaders(this._options)); } diff --git a/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/endpoints/client/Client.ts b/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/endpoints/client/Client.ts index e3e9747f1f7..280f29aa453 100644 --- a/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/endpoints/client/Client.ts +++ b/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/endpoints/client/Client.ts @@ -31,52 +31,45 @@ export declare namespace Endpoints { } export class Endpoints { - constructor(protected readonly _options: Endpoints.Options) {} - protected _container: Container | undefined; + protected _contentType: ContentType | undefined; + protected _enum: Enum | undefined; + protected _httpMethods: HttpMethods | undefined; + protected _object: Object_ | undefined; + protected _params: Params | undefined; + protected _primitive: Primitive | undefined; + protected _union: Union | undefined; + + constructor(protected readonly _options: Endpoints.Options) {} public get container(): Container { return (this._container ??= new Container(this._options)); } - protected _contentType: ContentType | undefined; - public get contentType(): ContentType { return (this._contentType ??= new ContentType(this._options)); } - protected _enum: Enum | undefined; - public get enum(): Enum { return (this._enum ??= new Enum(this._options)); } - protected _httpMethods: HttpMethods | undefined; - public get httpMethods(): HttpMethods { return (this._httpMethods ??= new HttpMethods(this._options)); } - protected _object: Object_ | undefined; - public get object(): Object_ { return (this._object ??= new Object_(this._options)); } - protected _params: Params | undefined; - public get params(): Params { return (this._params ??= new Params(this._options)); } - protected _primitive: Primitive | undefined; - public get primitive(): Primitive { return (this._primitive ??= new Primitive(this._options)); } - protected _union: Union | undefined; - public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/types/resources/enum/types/WeatherReport.ts index df4b29b1c64..6a0091bb8c0 100644 --- a/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", diff --git a/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/types/resources/union/types/Animal.ts b/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/types/resources/union/types/Animal.ts index b03ca8d422a..c05e5891781 100644 --- a/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-sdk/exhaustive/allow-extra-fields/src/api/resources/types/resources/union/types/Animal.ts @@ -6,12 +6,12 @@ import * as SeedExhaustive from "../../../../../index"; export type Animal = SeedExhaustive.types.Animal.Dog | SeedExhaustive.types.Animal.Cat; -export declare namespace Animal { - interface Dog extends SeedExhaustive.types.Dog { +export namespace Animal { + export interface Dog extends SeedExhaustive.types.Dog { animal: "dog"; } - interface Cat extends SeedExhaustive.types.Cat { + export interface Cat extends SeedExhaustive.types.Cat { animal: "cat"; } } diff --git a/seed/ts-sdk/exhaustive/bigint/src/Client.ts b/seed/ts-sdk/exhaustive/bigint/src/Client.ts index 9da7b36ff52..119821de7f2 100644 --- a/seed/ts-sdk/exhaustive/bigint/src/Client.ts +++ b/seed/ts-sdk/exhaustive/bigint/src/Client.ts @@ -28,34 +28,30 @@ export declare namespace SeedExhaustiveClient { } export class SeedExhaustiveClient { - constructor(protected readonly _options: SeedExhaustiveClient.Options) {} - protected _endpoints: Endpoints | undefined; + protected _inlinedRequests: InlinedRequests | undefined; + protected _noAuth: NoAuth | undefined; + protected _noReqBody: NoReqBody | undefined; + protected _reqWithHeaders: ReqWithHeaders | undefined; + + constructor(protected readonly _options: SeedExhaustiveClient.Options) {} public get endpoints(): Endpoints { return (this._endpoints ??= new Endpoints(this._options)); } - protected _inlinedRequests: InlinedRequests | undefined; - public get inlinedRequests(): InlinedRequests { return (this._inlinedRequests ??= new InlinedRequests(this._options)); } - protected _noAuth: NoAuth | undefined; - public get noAuth(): NoAuth { return (this._noAuth ??= new NoAuth(this._options)); } - protected _noReqBody: NoReqBody | undefined; - public get noReqBody(): NoReqBody { return (this._noReqBody ??= new NoReqBody(this._options)); } - protected _reqWithHeaders: ReqWithHeaders | undefined; - public get reqWithHeaders(): ReqWithHeaders { return (this._reqWithHeaders ??= new ReqWithHeaders(this._options)); } diff --git a/seed/ts-sdk/exhaustive/bigint/src/api/resources/endpoints/client/Client.ts b/seed/ts-sdk/exhaustive/bigint/src/api/resources/endpoints/client/Client.ts index e3e9747f1f7..280f29aa453 100644 --- a/seed/ts-sdk/exhaustive/bigint/src/api/resources/endpoints/client/Client.ts +++ b/seed/ts-sdk/exhaustive/bigint/src/api/resources/endpoints/client/Client.ts @@ -31,52 +31,45 @@ export declare namespace Endpoints { } export class Endpoints { - constructor(protected readonly _options: Endpoints.Options) {} - protected _container: Container | undefined; + protected _contentType: ContentType | undefined; + protected _enum: Enum | undefined; + protected _httpMethods: HttpMethods | undefined; + protected _object: Object_ | undefined; + protected _params: Params | undefined; + protected _primitive: Primitive | undefined; + protected _union: Union | undefined; + + constructor(protected readonly _options: Endpoints.Options) {} public get container(): Container { return (this._container ??= new Container(this._options)); } - protected _contentType: ContentType | undefined; - public get contentType(): ContentType { return (this._contentType ??= new ContentType(this._options)); } - protected _enum: Enum | undefined; - public get enum(): Enum { return (this._enum ??= new Enum(this._options)); } - protected _httpMethods: HttpMethods | undefined; - public get httpMethods(): HttpMethods { return (this._httpMethods ??= new HttpMethods(this._options)); } - protected _object: Object_ | undefined; - public get object(): Object_ { return (this._object ??= new Object_(this._options)); } - protected _params: Params | undefined; - public get params(): Params { return (this._params ??= new Params(this._options)); } - protected _primitive: Primitive | undefined; - public get primitive(): Primitive { return (this._primitive ??= new Primitive(this._options)); } - protected _union: Union | undefined; - public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/exhaustive/bigint/src/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-sdk/exhaustive/bigint/src/api/resources/types/resources/enum/types/WeatherReport.ts index df4b29b1c64..6a0091bb8c0 100644 --- a/seed/ts-sdk/exhaustive/bigint/src/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-sdk/exhaustive/bigint/src/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", diff --git a/seed/ts-sdk/exhaustive/bigint/src/api/resources/types/resources/union/types/Animal.ts b/seed/ts-sdk/exhaustive/bigint/src/api/resources/types/resources/union/types/Animal.ts index b03ca8d422a..c05e5891781 100644 --- a/seed/ts-sdk/exhaustive/bigint/src/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-sdk/exhaustive/bigint/src/api/resources/types/resources/union/types/Animal.ts @@ -6,12 +6,12 @@ import * as SeedExhaustive from "../../../../../index"; export type Animal = SeedExhaustive.types.Animal.Dog | SeedExhaustive.types.Animal.Cat; -export declare namespace Animal { - interface Dog extends SeedExhaustive.types.Dog { +export namespace Animal { + export interface Dog extends SeedExhaustive.types.Dog { animal: "dog"; } - interface Cat extends SeedExhaustive.types.Cat { + export interface Cat extends SeedExhaustive.types.Cat { animal: "cat"; } } diff --git a/seed/ts-sdk/exhaustive/bundle/src/Client.ts b/seed/ts-sdk/exhaustive/bundle/src/Client.ts index ac84bf99d12..ecf0e60dc0a 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/Client.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/Client.ts @@ -28,34 +28,30 @@ export declare namespace FiddleClient { } export class FiddleClient { - constructor(protected readonly _options: FiddleClient.Options) {} - protected _endpoints: Endpoints | undefined; + protected _inlinedRequests: InlinedRequests | undefined; + protected _noAuth: NoAuth | undefined; + protected _noReqBody: NoReqBody | undefined; + protected _reqWithHeaders: ReqWithHeaders | undefined; + + constructor(protected readonly _options: FiddleClient.Options) {} public get endpoints(): Endpoints { return (this._endpoints ??= new Endpoints(this._options)); } - protected _inlinedRequests: InlinedRequests | undefined; - public get inlinedRequests(): InlinedRequests { return (this._inlinedRequests ??= new InlinedRequests(this._options)); } - protected _noAuth: NoAuth | undefined; - public get noAuth(): NoAuth { return (this._noAuth ??= new NoAuth(this._options)); } - protected _noReqBody: NoReqBody | undefined; - public get noReqBody(): NoReqBody { return (this._noReqBody ??= new NoReqBody(this._options)); } - protected _reqWithHeaders: ReqWithHeaders | undefined; - public get reqWithHeaders(): ReqWithHeaders { return (this._reqWithHeaders ??= new ReqWithHeaders(this._options)); } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/client/Client.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/client/Client.ts index e3e9747f1f7..280f29aa453 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/client/Client.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/client/Client.ts @@ -31,52 +31,45 @@ export declare namespace Endpoints { } export class Endpoints { - constructor(protected readonly _options: Endpoints.Options) {} - protected _container: Container | undefined; + protected _contentType: ContentType | undefined; + protected _enum: Enum | undefined; + protected _httpMethods: HttpMethods | undefined; + protected _object: Object_ | undefined; + protected _params: Params | undefined; + protected _primitive: Primitive | undefined; + protected _union: Union | undefined; + + constructor(protected readonly _options: Endpoints.Options) {} public get container(): Container { return (this._container ??= new Container(this._options)); } - protected _contentType: ContentType | undefined; - public get contentType(): ContentType { return (this._contentType ??= new ContentType(this._options)); } - protected _enum: Enum | undefined; - public get enum(): Enum { return (this._enum ??= new Enum(this._options)); } - protected _httpMethods: HttpMethods | undefined; - public get httpMethods(): HttpMethods { return (this._httpMethods ??= new HttpMethods(this._options)); } - protected _object: Object_ | undefined; - public get object(): Object_ { return (this._object ??= new Object_(this._options)); } - protected _params: Params | undefined; - public get params(): Params { return (this._params ??= new Params(this._options)); } - protected _primitive: Primitive | undefined; - public get primitive(): Primitive { return (this._primitive ??= new Primitive(this._options)); } - protected _union: Union | undefined; - public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts index 28de602dc42..b6d96953f58 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnListOfObjects.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts index 6cc22075b93..b8e9e1bf2c6 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnListOfPrimitives.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts index c55ca2d5d9a..b27cf746001 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnMapOfPrimToObject.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts index dbba08edfaf..dcd313ba2f5 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnMapPrimToPrim.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts index 12930b17744..728c001b47e 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnOptional.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts index 5d74c307429..60af19d1d6c 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnSetOfObjects.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts index 6cbdc14fc71..2bfc53856c3 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnSetOfPrimitives.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts index c474809d2c2..5c737917554 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.contentType.postJsonPatchContentType.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts index 69cbf6e95a0..b279e096002 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.contentType.postJsonPatchContentWithCharsetType.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts index dc76cc3775f..df12d344497 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.enum_.getAndReturnEnum.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts index 29618127d0b..dbd1e9f452a 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testDelete.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts index c2e93d94b18..c5a890c5c13 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testGet.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts index 3a2041e7fe0..f2c17c5b99d 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testPatch.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts index d38d39be2f3..c800a582433 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testPost.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts index 88bd33283d8..b74a22b12fe 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testPut.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts index 68938a2d7db..a7f919567bb 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnNestedWithOptionalField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts index 83b008e3e06..029816008db 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnNestedWithRequiredField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts index 46c59aedba5..933abfd377c 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnNestedWithRequiredFieldAsList.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts index 668c772c3e2..eb81a1fdf19 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnWithMapOfMap.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts index 903077cf0a6..c640ab79e64 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnWithOptionalField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts index 5358a04e32b..c42dab795a2 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnWithRequiredField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts index a2f42c4ca29..977b09ec8e1 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithAllowMultipleQuery.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithPath.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithPath.ts index 04e60fe1143..3aa4dd631dc 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithPath.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithPath.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithPath.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts index 961d70b8ad1..e6c2e3aa6bb 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithPathAndQuery.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithQuery.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithQuery.ts index 20ab6597736..ef9bfe1188e 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithQuery.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/getWithQuery.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithQuery.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts index fabc6e8c92e..653916d7365 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.modifyWithPath.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts index 8301172f076..a7ef65c89cd 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnBase64.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts index 5d1712865d6..0fcd9f6e493 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnBool.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts index c3ad72823e9..ce295d2aed8 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnDate.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts index e9a5934522a..80d01fa15d1 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnDatetime.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts index c0b76f41fb5..2ca882c7f2f 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnDouble.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts index cbcbc7c9479..227f0ab9534 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnInt.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts index 37ecf2cfc09..f3c7de4acd5 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnLong.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts index 59bd4e284f9..f0f4b77395a 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnString.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts index 6fdd79c4c4d..918a3716279 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnUuid.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts index e7bf4986e24..d81cd0409c8 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.union.getAndReturnUnion.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts index a8985fd8968..8068724442e 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts @@ -9,13 +9,13 @@ export type Error = | Fiddle.inlinedRequests.postWithObjectBodyandResponse.Error.BadRequestBody | Fiddle.inlinedRequests.postWithObjectBodyandResponse.Error._Unknown; -export declare namespace Error { - interface BadRequestBody extends _Utils { +export namespace Error { + export interface BadRequestBody extends _Utils { statusCode: 400; content: Fiddle.BadObjectRequestInfo; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/noAuth/client/postWithNoAuth.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/noAuth/client/postWithNoAuth.ts index b6d422d7d4d..382c26891b5 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/noAuth/client/postWithNoAuth.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/noAuth/client/postWithNoAuth.ts @@ -7,13 +7,13 @@ import * as core from "../../../../core"; export type Error = Fiddle.noAuth.postWithNoAuth.Error.BadRequestBody | Fiddle.noAuth.postWithNoAuth.Error._Unknown; -export declare namespace Error { - interface BadRequestBody extends _Utils { +export namespace Error { + export interface BadRequestBody extends _Utils { statusCode: 400; content: Fiddle.BadObjectRequestInfo; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/noReqBody/client/getWithNoRequestBody.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/noReqBody/client/getWithNoRequestBody.ts index f2538ad3dc3..d27e21f52e5 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/noReqBody/client/getWithNoRequestBody.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/noReqBody/client/getWithNoRequestBody.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = Fiddle.noReqBody.getWithNoRequestBody.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/noReqBody/client/postWithNoRequestBody.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/noReqBody/client/postWithNoRequestBody.ts index 8e0bb96c8f8..ed5adb3cb5a 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/noReqBody/client/postWithNoRequestBody.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/noReqBody/client/postWithNoRequestBody.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = Fiddle.noReqBody.postWithNoRequestBody.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts index e3f9aa9b4a5..57504d03bfb 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = Fiddle.reqWithHeaders.getWithCustomHeader.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/types/resources/enum/types/WeatherReport.ts index 4cd2ac175cf..babba9a7b3c 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", @@ -25,7 +24,7 @@ export const WeatherReport = { }, } as const; -export declare namespace WeatherReport { +export namespace WeatherReport { interface Visitor { sunny: () => R; cloudy: () => R; diff --git a/seed/ts-sdk/exhaustive/bundle/src/api/resources/types/resources/union/types/Animal.ts b/seed/ts-sdk/exhaustive/bundle/src/api/resources/types/resources/union/types/Animal.ts index 159a83af453..4cddd06567e 100644 --- a/seed/ts-sdk/exhaustive/bundle/src/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-sdk/exhaustive/bundle/src/api/resources/types/resources/union/types/Animal.ts @@ -6,16 +6,16 @@ import * as Fiddle from "../../../../../index"; export type Animal = Fiddle.types.Animal.Dog | Fiddle.types.Animal.Cat | Fiddle.types.Animal._Unknown; -export declare namespace Animal { - interface Dog extends Fiddle.types.Dog, _Utils { +export namespace Animal { + export interface Dog extends Fiddle.types.Dog, _Utils { animal: "dog"; } - interface Cat extends Fiddle.types.Cat, _Utils { + export interface Cat extends Fiddle.types.Cat, _Utils { animal: "cat"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { animal: void; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/Client.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/Client.ts index ac84bf99d12..ecf0e60dc0a 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/Client.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/Client.ts @@ -28,34 +28,30 @@ export declare namespace FiddleClient { } export class FiddleClient { - constructor(protected readonly _options: FiddleClient.Options) {} - protected _endpoints: Endpoints | undefined; + protected _inlinedRequests: InlinedRequests | undefined; + protected _noAuth: NoAuth | undefined; + protected _noReqBody: NoReqBody | undefined; + protected _reqWithHeaders: ReqWithHeaders | undefined; + + constructor(protected readonly _options: FiddleClient.Options) {} public get endpoints(): Endpoints { return (this._endpoints ??= new Endpoints(this._options)); } - protected _inlinedRequests: InlinedRequests | undefined; - public get inlinedRequests(): InlinedRequests { return (this._inlinedRequests ??= new InlinedRequests(this._options)); } - protected _noAuth: NoAuth | undefined; - public get noAuth(): NoAuth { return (this._noAuth ??= new NoAuth(this._options)); } - protected _noReqBody: NoReqBody | undefined; - public get noReqBody(): NoReqBody { return (this._noReqBody ??= new NoReqBody(this._options)); } - protected _reqWithHeaders: ReqWithHeaders | undefined; - public get reqWithHeaders(): ReqWithHeaders { return (this._reqWithHeaders ??= new ReqWithHeaders(this._options)); } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/client/Client.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/client/Client.ts index e3e9747f1f7..280f29aa453 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/client/Client.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/client/Client.ts @@ -31,52 +31,45 @@ export declare namespace Endpoints { } export class Endpoints { - constructor(protected readonly _options: Endpoints.Options) {} - protected _container: Container | undefined; + protected _contentType: ContentType | undefined; + protected _enum: Enum | undefined; + protected _httpMethods: HttpMethods | undefined; + protected _object: Object_ | undefined; + protected _params: Params | undefined; + protected _primitive: Primitive | undefined; + protected _union: Union | undefined; + + constructor(protected readonly _options: Endpoints.Options) {} public get container(): Container { return (this._container ??= new Container(this._options)); } - protected _contentType: ContentType | undefined; - public get contentType(): ContentType { return (this._contentType ??= new ContentType(this._options)); } - protected _enum: Enum | undefined; - public get enum(): Enum { return (this._enum ??= new Enum(this._options)); } - protected _httpMethods: HttpMethods | undefined; - public get httpMethods(): HttpMethods { return (this._httpMethods ??= new HttpMethods(this._options)); } - protected _object: Object_ | undefined; - public get object(): Object_ { return (this._object ??= new Object_(this._options)); } - protected _params: Params | undefined; - public get params(): Params { return (this._params ??= new Params(this._options)); } - protected _primitive: Primitive | undefined; - public get primitive(): Primitive { return (this._primitive ??= new Primitive(this._options)); } - protected _union: Union | undefined; - public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts index 28de602dc42..b6d96953f58 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnListOfObjects.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts index 6cc22075b93..b8e9e1bf2c6 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnListOfPrimitives.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts index c55ca2d5d9a..b27cf746001 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnMapOfPrimToObject.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts index dbba08edfaf..dcd313ba2f5 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnMapPrimToPrim.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts index 12930b17744..728c001b47e 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnOptional.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts index 5d74c307429..60af19d1d6c 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnSetOfObjects.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts index 6cbdc14fc71..2bfc53856c3 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnSetOfPrimitives.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts index c474809d2c2..5c737917554 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.contentType.postJsonPatchContentType.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts index 69cbf6e95a0..b279e096002 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.contentType.postJsonPatchContentWithCharsetType.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts index dc76cc3775f..df12d344497 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.enum_.getAndReturnEnum.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts index 29618127d0b..dbd1e9f452a 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testDelete.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts index c2e93d94b18..c5a890c5c13 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testGet.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts index 3a2041e7fe0..f2c17c5b99d 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testPatch.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts index d38d39be2f3..c800a582433 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testPost.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts index 88bd33283d8..b74a22b12fe 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testPut.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts index 68938a2d7db..a7f919567bb 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnNestedWithOptionalField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts index 83b008e3e06..029816008db 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnNestedWithRequiredField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts index 46c59aedba5..933abfd377c 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnNestedWithRequiredFieldAsList.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts index 668c772c3e2..eb81a1fdf19 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnWithMapOfMap.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts index 903077cf0a6..c640ab79e64 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnWithOptionalField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts index 5358a04e32b..c42dab795a2 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnWithRequiredField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts index a2f42c4ca29..977b09ec8e1 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithAllowMultipleQuery.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithPath.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithPath.ts index 04e60fe1143..3aa4dd631dc 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithPath.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithPath.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithPath.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts index 961d70b8ad1..e6c2e3aa6bb 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithPathAndQuery.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithQuery.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithQuery.ts index 20ab6597736..ef9bfe1188e 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithQuery.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/getWithQuery.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithQuery.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts index fabc6e8c92e..653916d7365 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.modifyWithPath.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts index 8301172f076..a7ef65c89cd 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnBase64.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts index 5d1712865d6..0fcd9f6e493 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnBool.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts index c3ad72823e9..ce295d2aed8 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnDate.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts index e9a5934522a..80d01fa15d1 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnDatetime.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts index c0b76f41fb5..2ca882c7f2f 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnDouble.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts index cbcbc7c9479..227f0ab9534 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnInt.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts index 37ecf2cfc09..f3c7de4acd5 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnLong.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts index 59bd4e284f9..f0f4b77395a 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnString.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts index 6fdd79c4c4d..918a3716279 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnUuid.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts index e7bf4986e24..d81cd0409c8 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.union.getAndReturnUnion.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts index a8985fd8968..8068724442e 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts @@ -9,13 +9,13 @@ export type Error = | Fiddle.inlinedRequests.postWithObjectBodyandResponse.Error.BadRequestBody | Fiddle.inlinedRequests.postWithObjectBodyandResponse.Error._Unknown; -export declare namespace Error { - interface BadRequestBody extends _Utils { +export namespace Error { + export interface BadRequestBody extends _Utils { statusCode: 400; content: Fiddle.BadObjectRequestInfo; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noAuth/client/postWithNoAuth.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noAuth/client/postWithNoAuth.ts index b6d422d7d4d..382c26891b5 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noAuth/client/postWithNoAuth.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noAuth/client/postWithNoAuth.ts @@ -7,13 +7,13 @@ import * as core from "../../../../core"; export type Error = Fiddle.noAuth.postWithNoAuth.Error.BadRequestBody | Fiddle.noAuth.postWithNoAuth.Error._Unknown; -export declare namespace Error { - interface BadRequestBody extends _Utils { +export namespace Error { + export interface BadRequestBody extends _Utils { statusCode: 400; content: Fiddle.BadObjectRequestInfo; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noReqBody/client/getWithNoRequestBody.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noReqBody/client/getWithNoRequestBody.ts index f2538ad3dc3..d27e21f52e5 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noReqBody/client/getWithNoRequestBody.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noReqBody/client/getWithNoRequestBody.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = Fiddle.noReqBody.getWithNoRequestBody.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noReqBody/client/postWithNoRequestBody.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noReqBody/client/postWithNoRequestBody.ts index 8e0bb96c8f8..ed5adb3cb5a 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noReqBody/client/postWithNoRequestBody.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/noReqBody/client/postWithNoRequestBody.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = Fiddle.noReqBody.postWithNoRequestBody.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts index e3f9aa9b4a5..57504d03bfb 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = Fiddle.reqWithHeaders.getWithCustomHeader.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/types/resources/enum/types/WeatherReport.ts index 4cd2ac175cf..babba9a7b3c 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", @@ -25,7 +24,7 @@ export const WeatherReport = { }, } as const; -export declare namespace WeatherReport { +export namespace WeatherReport { interface Visitor { sunny: () => R; cloudy: () => R; diff --git a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/types/resources/union/types/Animal.ts b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/types/resources/union/types/Animal.ts index 159a83af453..4cddd06567e 100644 --- a/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-sdk/exhaustive/custom-package-json/src/api/resources/types/resources/union/types/Animal.ts @@ -6,16 +6,16 @@ import * as Fiddle from "../../../../../index"; export type Animal = Fiddle.types.Animal.Dog | Fiddle.types.Animal.Cat | Fiddle.types.Animal._Unknown; -export declare namespace Animal { - interface Dog extends Fiddle.types.Dog, _Utils { +export namespace Animal { + export interface Dog extends Fiddle.types.Dog, _Utils { animal: "dog"; } - interface Cat extends Fiddle.types.Cat, _Utils { + export interface Cat extends Fiddle.types.Cat, _Utils { animal: "cat"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { animal: void; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/Client.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/Client.ts index ac84bf99d12..ecf0e60dc0a 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/Client.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/Client.ts @@ -28,34 +28,30 @@ export declare namespace FiddleClient { } export class FiddleClient { - constructor(protected readonly _options: FiddleClient.Options) {} - protected _endpoints: Endpoints | undefined; + protected _inlinedRequests: InlinedRequests | undefined; + protected _noAuth: NoAuth | undefined; + protected _noReqBody: NoReqBody | undefined; + protected _reqWithHeaders: ReqWithHeaders | undefined; + + constructor(protected readonly _options: FiddleClient.Options) {} public get endpoints(): Endpoints { return (this._endpoints ??= new Endpoints(this._options)); } - protected _inlinedRequests: InlinedRequests | undefined; - public get inlinedRequests(): InlinedRequests { return (this._inlinedRequests ??= new InlinedRequests(this._options)); } - protected _noAuth: NoAuth | undefined; - public get noAuth(): NoAuth { return (this._noAuth ??= new NoAuth(this._options)); } - protected _noReqBody: NoReqBody | undefined; - public get noReqBody(): NoReqBody { return (this._noReqBody ??= new NoReqBody(this._options)); } - protected _reqWithHeaders: ReqWithHeaders | undefined; - public get reqWithHeaders(): ReqWithHeaders { return (this._reqWithHeaders ??= new ReqWithHeaders(this._options)); } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/client/Client.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/client/Client.ts index e3e9747f1f7..280f29aa453 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/client/Client.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/client/Client.ts @@ -31,52 +31,45 @@ export declare namespace Endpoints { } export class Endpoints { - constructor(protected readonly _options: Endpoints.Options) {} - protected _container: Container | undefined; + protected _contentType: ContentType | undefined; + protected _enum: Enum | undefined; + protected _httpMethods: HttpMethods | undefined; + protected _object: Object_ | undefined; + protected _params: Params | undefined; + protected _primitive: Primitive | undefined; + protected _union: Union | undefined; + + constructor(protected readonly _options: Endpoints.Options) {} public get container(): Container { return (this._container ??= new Container(this._options)); } - protected _contentType: ContentType | undefined; - public get contentType(): ContentType { return (this._contentType ??= new ContentType(this._options)); } - protected _enum: Enum | undefined; - public get enum(): Enum { return (this._enum ??= new Enum(this._options)); } - protected _httpMethods: HttpMethods | undefined; - public get httpMethods(): HttpMethods { return (this._httpMethods ??= new HttpMethods(this._options)); } - protected _object: Object_ | undefined; - public get object(): Object_ { return (this._object ??= new Object_(this._options)); } - protected _params: Params | undefined; - public get params(): Params { return (this._params ??= new Params(this._options)); } - protected _primitive: Primitive | undefined; - public get primitive(): Primitive { return (this._primitive ??= new Primitive(this._options)); } - protected _union: Union | undefined; - public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts index 28de602dc42..b6d96953f58 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnListOfObjects.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnListOfObjects.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts index 6cc22075b93..b8e9e1bf2c6 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnListOfPrimitives.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnListOfPrimitives.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts index c55ca2d5d9a..b27cf746001 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnMapOfPrimToObject.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnMapOfPrimToObject.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts index dbba08edfaf..dcd313ba2f5 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnMapPrimToPrim.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnMapPrimToPrim.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts index 12930b17744..728c001b47e 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnOptional.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnOptional.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts index 5d74c307429..60af19d1d6c 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfObjects.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnSetOfObjects.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts index 6cbdc14fc71..2bfc53856c3 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/container/client/getAndReturnSetOfPrimitives.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.container.getAndReturnSetOfPrimitives.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts index c474809d2c2..5c737917554 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentType.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.contentType.postJsonPatchContentType.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts index 69cbf6e95a0..b279e096002 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/contentType/client/postJsonPatchContentWithCharsetType.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.contentType.postJsonPatchContentWithCharsetType.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts index dc76cc3775f..df12d344497 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/enum/client/getAndReturnEnum.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.enum_.getAndReturnEnum.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts index 29618127d0b..dbd1e9f452a 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testDelete.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testDelete.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts index c2e93d94b18..c5a890c5c13 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testGet.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testGet.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts index 3a2041e7fe0..f2c17c5b99d 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPatch.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testPatch.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts index d38d39be2f3..c800a582433 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPost.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testPost.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts index 88bd33283d8..b74a22b12fe 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/httpMethods/client/testPut.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.httpMethods.testPut.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts index 68938a2d7db..a7f919567bb 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithOptionalField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnNestedWithOptionalField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts index 83b008e3e06..029816008db 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnNestedWithRequiredField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts index 46c59aedba5..933abfd377c 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnNestedWithRequiredFieldAsList.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnNestedWithRequiredFieldAsList.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts index 668c772c3e2..eb81a1fdf19 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithMapOfMap.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnWithMapOfMap.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts index 903077cf0a6..c640ab79e64 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithOptionalField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnWithOptionalField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts index 5358a04e32b..c42dab795a2 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/object/client/getAndReturnWithRequiredField.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.object.getAndReturnWithRequiredField.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts index a2f42c4ca29..977b09ec8e1 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithAllowMultipleQuery.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithAllowMultipleQuery.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithPath.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithPath.ts index 04e60fe1143..3aa4dd631dc 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithPath.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithPath.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithPath.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts index 961d70b8ad1..e6c2e3aa6bb 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithPathAndQuery.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithPathAndQuery.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithQuery.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithQuery.ts index 20ab6597736..ef9bfe1188e 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithQuery.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/getWithQuery.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.getWithQuery.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts index fabc6e8c92e..653916d7365 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/params/client/modifyWithPath.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.params.modifyWithPath.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts index 8301172f076..a7ef65c89cd 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnBase64.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnBase64.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts index 5d1712865d6..0fcd9f6e493 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnBool.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnBool.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts index c3ad72823e9..ce295d2aed8 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDate.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnDate.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts index e9a5934522a..80d01fa15d1 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDatetime.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnDatetime.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts index c0b76f41fb5..2ca882c7f2f 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnDouble.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnDouble.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts index cbcbc7c9479..227f0ab9534 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnInt.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnInt.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts index 37ecf2cfc09..f3c7de4acd5 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnLong.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnLong.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts index 59bd4e284f9..f0f4b77395a 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnString.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnString.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts index 6fdd79c4c4d..918a3716279 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/primitive/client/getAndReturnUuid.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.primitive.getAndReturnUuid.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts index e7bf4986e24..d81cd0409c8 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/endpoints/resources/union/client/getAndReturnUnion.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = Fiddle.endpoints.union.getAndReturnUnion.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts index a8985fd8968..8068724442e 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/inlinedRequests/client/postWithObjectBodyandResponse.ts @@ -9,13 +9,13 @@ export type Error = | Fiddle.inlinedRequests.postWithObjectBodyandResponse.Error.BadRequestBody | Fiddle.inlinedRequests.postWithObjectBodyandResponse.Error._Unknown; -export declare namespace Error { - interface BadRequestBody extends _Utils { +export namespace Error { + export interface BadRequestBody extends _Utils { statusCode: 400; content: Fiddle.BadObjectRequestInfo; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noAuth/client/postWithNoAuth.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noAuth/client/postWithNoAuth.ts index b6d422d7d4d..382c26891b5 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noAuth/client/postWithNoAuth.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noAuth/client/postWithNoAuth.ts @@ -7,13 +7,13 @@ import * as core from "../../../../core"; export type Error = Fiddle.noAuth.postWithNoAuth.Error.BadRequestBody | Fiddle.noAuth.postWithNoAuth.Error._Unknown; -export declare namespace Error { - interface BadRequestBody extends _Utils { +export namespace Error { + export interface BadRequestBody extends _Utils { statusCode: 400; content: Fiddle.BadObjectRequestInfo; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noReqBody/client/getWithNoRequestBody.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noReqBody/client/getWithNoRequestBody.ts index f2538ad3dc3..d27e21f52e5 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noReqBody/client/getWithNoRequestBody.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noReqBody/client/getWithNoRequestBody.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = Fiddle.noReqBody.getWithNoRequestBody.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noReqBody/client/postWithNoRequestBody.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noReqBody/client/postWithNoRequestBody.ts index 8e0bb96c8f8..ed5adb3cb5a 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noReqBody/client/postWithNoRequestBody.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/noReqBody/client/postWithNoRequestBody.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = Fiddle.noReqBody.postWithNoRequestBody.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts index e3f9aa9b4a5..57504d03bfb 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/reqWithHeaders/client/getWithCustomHeader.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = Fiddle.reqWithHeaders.getWithCustomHeader.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/types/resources/enum/types/WeatherReport.ts index 4cd2ac175cf..babba9a7b3c 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", @@ -25,7 +24,7 @@ export const WeatherReport = { }, } as const; -export declare namespace WeatherReport { +export namespace WeatherReport { interface Visitor { sunny: () => R; cloudy: () => R; diff --git a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/types/resources/union/types/Animal.ts b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/types/resources/union/types/Animal.ts index 159a83af453..4cddd06567e 100644 --- a/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-sdk/exhaustive/dev-dependencies/src/api/resources/types/resources/union/types/Animal.ts @@ -6,16 +6,16 @@ import * as Fiddle from "../../../../../index"; export type Animal = Fiddle.types.Animal.Dog | Fiddle.types.Animal.Cat | Fiddle.types.Animal._Unknown; -export declare namespace Animal { - interface Dog extends Fiddle.types.Dog, _Utils { +export namespace Animal { + export interface Dog extends Fiddle.types.Dog, _Utils { animal: "dog"; } - interface Cat extends Fiddle.types.Cat, _Utils { + export interface Cat extends Fiddle.types.Cat, _Utils { animal: "cat"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { animal: void; } diff --git a/seed/ts-sdk/exhaustive/jsr/src/Client.ts b/seed/ts-sdk/exhaustive/jsr/src/Client.ts index 9da7b36ff52..119821de7f2 100644 --- a/seed/ts-sdk/exhaustive/jsr/src/Client.ts +++ b/seed/ts-sdk/exhaustive/jsr/src/Client.ts @@ -28,34 +28,30 @@ export declare namespace SeedExhaustiveClient { } export class SeedExhaustiveClient { - constructor(protected readonly _options: SeedExhaustiveClient.Options) {} - protected _endpoints: Endpoints | undefined; + protected _inlinedRequests: InlinedRequests | undefined; + protected _noAuth: NoAuth | undefined; + protected _noReqBody: NoReqBody | undefined; + protected _reqWithHeaders: ReqWithHeaders | undefined; + + constructor(protected readonly _options: SeedExhaustiveClient.Options) {} public get endpoints(): Endpoints { return (this._endpoints ??= new Endpoints(this._options)); } - protected _inlinedRequests: InlinedRequests | undefined; - public get inlinedRequests(): InlinedRequests { return (this._inlinedRequests ??= new InlinedRequests(this._options)); } - protected _noAuth: NoAuth | undefined; - public get noAuth(): NoAuth { return (this._noAuth ??= new NoAuth(this._options)); } - protected _noReqBody: NoReqBody | undefined; - public get noReqBody(): NoReqBody { return (this._noReqBody ??= new NoReqBody(this._options)); } - protected _reqWithHeaders: ReqWithHeaders | undefined; - public get reqWithHeaders(): ReqWithHeaders { return (this._reqWithHeaders ??= new ReqWithHeaders(this._options)); } diff --git a/seed/ts-sdk/exhaustive/jsr/src/api/resources/endpoints/client/Client.ts b/seed/ts-sdk/exhaustive/jsr/src/api/resources/endpoints/client/Client.ts index e3e9747f1f7..280f29aa453 100644 --- a/seed/ts-sdk/exhaustive/jsr/src/api/resources/endpoints/client/Client.ts +++ b/seed/ts-sdk/exhaustive/jsr/src/api/resources/endpoints/client/Client.ts @@ -31,52 +31,45 @@ export declare namespace Endpoints { } export class Endpoints { - constructor(protected readonly _options: Endpoints.Options) {} - protected _container: Container | undefined; + protected _contentType: ContentType | undefined; + protected _enum: Enum | undefined; + protected _httpMethods: HttpMethods | undefined; + protected _object: Object_ | undefined; + protected _params: Params | undefined; + protected _primitive: Primitive | undefined; + protected _union: Union | undefined; + + constructor(protected readonly _options: Endpoints.Options) {} public get container(): Container { return (this._container ??= new Container(this._options)); } - protected _contentType: ContentType | undefined; - public get contentType(): ContentType { return (this._contentType ??= new ContentType(this._options)); } - protected _enum: Enum | undefined; - public get enum(): Enum { return (this._enum ??= new Enum(this._options)); } - protected _httpMethods: HttpMethods | undefined; - public get httpMethods(): HttpMethods { return (this._httpMethods ??= new HttpMethods(this._options)); } - protected _object: Object_ | undefined; - public get object(): Object_ { return (this._object ??= new Object_(this._options)); } - protected _params: Params | undefined; - public get params(): Params { return (this._params ??= new Params(this._options)); } - protected _primitive: Primitive | undefined; - public get primitive(): Primitive { return (this._primitive ??= new Primitive(this._options)); } - protected _union: Union | undefined; - public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/exhaustive/jsr/src/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-sdk/exhaustive/jsr/src/api/resources/types/resources/enum/types/WeatherReport.ts index df4b29b1c64..6a0091bb8c0 100644 --- a/seed/ts-sdk/exhaustive/jsr/src/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-sdk/exhaustive/jsr/src/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", diff --git a/seed/ts-sdk/exhaustive/jsr/src/api/resources/types/resources/union/types/Animal.ts b/seed/ts-sdk/exhaustive/jsr/src/api/resources/types/resources/union/types/Animal.ts index b03ca8d422a..c05e5891781 100644 --- a/seed/ts-sdk/exhaustive/jsr/src/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-sdk/exhaustive/jsr/src/api/resources/types/resources/union/types/Animal.ts @@ -6,12 +6,12 @@ import * as SeedExhaustive from "../../../../../index"; export type Animal = SeedExhaustive.types.Animal.Dog | SeedExhaustive.types.Animal.Cat; -export declare namespace Animal { - interface Dog extends SeedExhaustive.types.Dog { +export namespace Animal { + export interface Dog extends SeedExhaustive.types.Dog { animal: "dog"; } - interface Cat extends SeedExhaustive.types.Cat { + export interface Cat extends SeedExhaustive.types.Cat { animal: "cat"; } } diff --git a/seed/ts-sdk/exhaustive/no-custom-config/src/Client.ts b/seed/ts-sdk/exhaustive/no-custom-config/src/Client.ts index 9da7b36ff52..119821de7f2 100644 --- a/seed/ts-sdk/exhaustive/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/exhaustive/no-custom-config/src/Client.ts @@ -28,34 +28,30 @@ export declare namespace SeedExhaustiveClient { } export class SeedExhaustiveClient { - constructor(protected readonly _options: SeedExhaustiveClient.Options) {} - protected _endpoints: Endpoints | undefined; + protected _inlinedRequests: InlinedRequests | undefined; + protected _noAuth: NoAuth | undefined; + protected _noReqBody: NoReqBody | undefined; + protected _reqWithHeaders: ReqWithHeaders | undefined; + + constructor(protected readonly _options: SeedExhaustiveClient.Options) {} public get endpoints(): Endpoints { return (this._endpoints ??= new Endpoints(this._options)); } - protected _inlinedRequests: InlinedRequests | undefined; - public get inlinedRequests(): InlinedRequests { return (this._inlinedRequests ??= new InlinedRequests(this._options)); } - protected _noAuth: NoAuth | undefined; - public get noAuth(): NoAuth { return (this._noAuth ??= new NoAuth(this._options)); } - protected _noReqBody: NoReqBody | undefined; - public get noReqBody(): NoReqBody { return (this._noReqBody ??= new NoReqBody(this._options)); } - protected _reqWithHeaders: ReqWithHeaders | undefined; - public get reqWithHeaders(): ReqWithHeaders { return (this._reqWithHeaders ??= new ReqWithHeaders(this._options)); } diff --git a/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/endpoints/client/Client.ts b/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/endpoints/client/Client.ts index e3e9747f1f7..280f29aa453 100644 --- a/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/endpoints/client/Client.ts +++ b/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/endpoints/client/Client.ts @@ -31,52 +31,45 @@ export declare namespace Endpoints { } export class Endpoints { - constructor(protected readonly _options: Endpoints.Options) {} - protected _container: Container | undefined; + protected _contentType: ContentType | undefined; + protected _enum: Enum | undefined; + protected _httpMethods: HttpMethods | undefined; + protected _object: Object_ | undefined; + protected _params: Params | undefined; + protected _primitive: Primitive | undefined; + protected _union: Union | undefined; + + constructor(protected readonly _options: Endpoints.Options) {} public get container(): Container { return (this._container ??= new Container(this._options)); } - protected _contentType: ContentType | undefined; - public get contentType(): ContentType { return (this._contentType ??= new ContentType(this._options)); } - protected _enum: Enum | undefined; - public get enum(): Enum { return (this._enum ??= new Enum(this._options)); } - protected _httpMethods: HttpMethods | undefined; - public get httpMethods(): HttpMethods { return (this._httpMethods ??= new HttpMethods(this._options)); } - protected _object: Object_ | undefined; - public get object(): Object_ { return (this._object ??= new Object_(this._options)); } - protected _params: Params | undefined; - public get params(): Params { return (this._params ??= new Params(this._options)); } - protected _primitive: Primitive | undefined; - public get primitive(): Primitive { return (this._primitive ??= new Primitive(this._options)); } - protected _union: Union | undefined; - public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/types/resources/enum/types/WeatherReport.ts index df4b29b1c64..6a0091bb8c0 100644 --- a/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", diff --git a/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/types/resources/union/types/Animal.ts b/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/types/resources/union/types/Animal.ts index b03ca8d422a..c05e5891781 100644 --- a/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-sdk/exhaustive/no-custom-config/src/api/resources/types/resources/union/types/Animal.ts @@ -6,12 +6,12 @@ import * as SeedExhaustive from "../../../../../index"; export type Animal = SeedExhaustive.types.Animal.Dog | SeedExhaustive.types.Animal.Cat; -export declare namespace Animal { - interface Dog extends SeedExhaustive.types.Dog { +export namespace Animal { + export interface Dog extends SeedExhaustive.types.Dog { animal: "dog"; } - interface Cat extends SeedExhaustive.types.Cat { + export interface Cat extends SeedExhaustive.types.Cat { animal: "cat"; } } diff --git a/seed/ts-sdk/exhaustive/retain-original-casing/src/Client.ts b/seed/ts-sdk/exhaustive/retain-original-casing/src/Client.ts index 9da7b36ff52..119821de7f2 100644 --- a/seed/ts-sdk/exhaustive/retain-original-casing/src/Client.ts +++ b/seed/ts-sdk/exhaustive/retain-original-casing/src/Client.ts @@ -28,34 +28,30 @@ export declare namespace SeedExhaustiveClient { } export class SeedExhaustiveClient { - constructor(protected readonly _options: SeedExhaustiveClient.Options) {} - protected _endpoints: Endpoints | undefined; + protected _inlinedRequests: InlinedRequests | undefined; + protected _noAuth: NoAuth | undefined; + protected _noReqBody: NoReqBody | undefined; + protected _reqWithHeaders: ReqWithHeaders | undefined; + + constructor(protected readonly _options: SeedExhaustiveClient.Options) {} public get endpoints(): Endpoints { return (this._endpoints ??= new Endpoints(this._options)); } - protected _inlinedRequests: InlinedRequests | undefined; - public get inlinedRequests(): InlinedRequests { return (this._inlinedRequests ??= new InlinedRequests(this._options)); } - protected _noAuth: NoAuth | undefined; - public get noAuth(): NoAuth { return (this._noAuth ??= new NoAuth(this._options)); } - protected _noReqBody: NoReqBody | undefined; - public get noReqBody(): NoReqBody { return (this._noReqBody ??= new NoReqBody(this._options)); } - protected _reqWithHeaders: ReqWithHeaders | undefined; - public get reqWithHeaders(): ReqWithHeaders { return (this._reqWithHeaders ??= new ReqWithHeaders(this._options)); } diff --git a/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/endpoints/client/Client.ts b/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/endpoints/client/Client.ts index e3e9747f1f7..280f29aa453 100644 --- a/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/endpoints/client/Client.ts +++ b/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/endpoints/client/Client.ts @@ -31,52 +31,45 @@ export declare namespace Endpoints { } export class Endpoints { - constructor(protected readonly _options: Endpoints.Options) {} - protected _container: Container | undefined; + protected _contentType: ContentType | undefined; + protected _enum: Enum | undefined; + protected _httpMethods: HttpMethods | undefined; + protected _object: Object_ | undefined; + protected _params: Params | undefined; + protected _primitive: Primitive | undefined; + protected _union: Union | undefined; + + constructor(protected readonly _options: Endpoints.Options) {} public get container(): Container { return (this._container ??= new Container(this._options)); } - protected _contentType: ContentType | undefined; - public get contentType(): ContentType { return (this._contentType ??= new ContentType(this._options)); } - protected _enum: Enum | undefined; - public get enum(): Enum { return (this._enum ??= new Enum(this._options)); } - protected _httpMethods: HttpMethods | undefined; - public get httpMethods(): HttpMethods { return (this._httpMethods ??= new HttpMethods(this._options)); } - protected _object: Object_ | undefined; - public get object(): Object_ { return (this._object ??= new Object_(this._options)); } - protected _params: Params | undefined; - public get params(): Params { return (this._params ??= new Params(this._options)); } - protected _primitive: Primitive | undefined; - public get primitive(): Primitive { return (this._primitive ??= new Primitive(this._options)); } - protected _union: Union | undefined; - public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/types/resources/enum/types/WeatherReport.ts b/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/types/resources/enum/types/WeatherReport.ts index df4b29b1c64..6a0091bb8c0 100644 --- a/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/types/resources/enum/types/WeatherReport.ts +++ b/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/types/resources/enum/types/WeatherReport.ts @@ -3,7 +3,6 @@ */ export type WeatherReport = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; - export const WeatherReport = { Sunny: "SUNNY", Cloudy: "CLOUDY", diff --git a/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/types/resources/union/types/Animal.ts b/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/types/resources/union/types/Animal.ts index b03ca8d422a..c05e5891781 100644 --- a/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/types/resources/union/types/Animal.ts +++ b/seed/ts-sdk/exhaustive/retain-original-casing/src/api/resources/types/resources/union/types/Animal.ts @@ -6,12 +6,12 @@ import * as SeedExhaustive from "../../../../../index"; export type Animal = SeedExhaustive.types.Animal.Dog | SeedExhaustive.types.Animal.Cat; -export declare namespace Animal { - interface Dog extends SeedExhaustive.types.Dog { +export namespace Animal { + export interface Dog extends SeedExhaustive.types.Dog { animal: "dog"; } - interface Cat extends SeedExhaustive.types.Cat { + export interface Cat extends SeedExhaustive.types.Cat { animal: "cat"; } } diff --git a/seed/ts-sdk/extra-properties/src/Client.ts b/seed/ts-sdk/extra-properties/src/Client.ts index cac7af1b6d0..746bc930c51 100644 --- a/seed/ts-sdk/extra-properties/src/Client.ts +++ b/seed/ts-sdk/extra-properties/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedExtraPropertiesClient { } export class SeedExtraPropertiesClient { - constructor(protected readonly _options: SeedExtraPropertiesClient.Options) {} - protected _user: User | undefined; + constructor(protected readonly _options: SeedExtraPropertiesClient.Options) {} + public get user(): User { return (this._user ??= new User(this._options)); } diff --git a/seed/ts-sdk/file-download/file-download-reponse-headers/src/Client.ts b/seed/ts-sdk/file-download/file-download-reponse-headers/src/Client.ts index 9aca32bf5c1..b45035e0c17 100644 --- a/seed/ts-sdk/file-download/file-download-reponse-headers/src/Client.ts +++ b/seed/ts-sdk/file-download/file-download-reponse-headers/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedFileDownloadClient { } export class SeedFileDownloadClient { - constructor(protected readonly _options: SeedFileDownloadClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedFileDownloadClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/file-download/no-custom-config/src/Client.ts b/seed/ts-sdk/file-download/no-custom-config/src/Client.ts index 9aca32bf5c1..b45035e0c17 100644 --- a/seed/ts-sdk/file-download/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/file-download/no-custom-config/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedFileDownloadClient { } export class SeedFileDownloadClient { - constructor(protected readonly _options: SeedFileDownloadClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedFileDownloadClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/file-upload/no-custom-config/src/Client.ts b/seed/ts-sdk/file-upload/no-custom-config/src/Client.ts index d65bcc99609..1d225c25ff2 100644 --- a/seed/ts-sdk/file-upload/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/file-upload/no-custom-config/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedFileUploadClient { } export class SeedFileUploadClient { - constructor(protected readonly _options: SeedFileUploadClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedFileUploadClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/file-upload/no-custom-config/src/api/resources/service/types/ObjectType.ts b/seed/ts-sdk/file-upload/no-custom-config/src/api/resources/service/types/ObjectType.ts index b660d8ceb02..7bc09b0223f 100644 --- a/seed/ts-sdk/file-upload/no-custom-config/src/api/resources/service/types/ObjectType.ts +++ b/seed/ts-sdk/file-upload/no-custom-config/src/api/resources/service/types/ObjectType.ts @@ -3,7 +3,6 @@ */ export type ObjectType = "FOO" | "BAR"; - export const ObjectType = { Foo: "FOO", Bar: "BAR", diff --git a/seed/ts-sdk/file-upload/wrap-file-properties/src/Client.ts b/seed/ts-sdk/file-upload/wrap-file-properties/src/Client.ts index d65bcc99609..1d225c25ff2 100644 --- a/seed/ts-sdk/file-upload/wrap-file-properties/src/Client.ts +++ b/seed/ts-sdk/file-upload/wrap-file-properties/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedFileUploadClient { } export class SeedFileUploadClient { - constructor(protected readonly _options: SeedFileUploadClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedFileUploadClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/file-upload/wrap-file-properties/src/api/resources/service/types/ObjectType.ts b/seed/ts-sdk/file-upload/wrap-file-properties/src/api/resources/service/types/ObjectType.ts index b660d8ceb02..7bc09b0223f 100644 --- a/seed/ts-sdk/file-upload/wrap-file-properties/src/api/resources/service/types/ObjectType.ts +++ b/seed/ts-sdk/file-upload/wrap-file-properties/src/api/resources/service/types/ObjectType.ts @@ -3,7 +3,6 @@ */ export type ObjectType = "FOO" | "BAR"; - export const ObjectType = { Foo: "FOO", Bar: "BAR", diff --git a/seed/ts-sdk/folders/src/Client.ts b/seed/ts-sdk/folders/src/Client.ts index 1c0fb057786..616b0a0e74b 100644 --- a/seed/ts-sdk/folders/src/Client.ts +++ b/seed/ts-sdk/folders/src/Client.ts @@ -25,8 +25,19 @@ export declare namespace SeedApiClient { } export class SeedApiClient { + protected _a: A | undefined; + protected _folder: Folder | undefined; + constructor(protected readonly _options: SeedApiClient.Options) {} + public get a(): A { + return (this._a ??= new A(this._options)); + } + + public get folder(): Folder { + return (this._folder ??= new Folder(this._options)); + } + /** * @param {SeedApiClient.RequestOptions} requestOptions - Request-specific configuration. * @@ -77,16 +88,4 @@ export class SeedApiClient { }); } } - - protected _a: A | undefined; - - public get a(): A { - return (this._a ??= new A(this._options)); - } - - protected _folder: Folder | undefined; - - public get folder(): Folder { - return (this._folder ??= new Folder(this._options)); - } } diff --git a/seed/ts-sdk/folders/src/api/resources/a/client/Client.ts b/seed/ts-sdk/folders/src/api/resources/a/client/Client.ts index c325b854601..2374693fd3a 100644 --- a/seed/ts-sdk/folders/src/api/resources/a/client/Client.ts +++ b/seed/ts-sdk/folders/src/api/resources/a/client/Client.ts @@ -24,16 +24,15 @@ export declare namespace A { } export class A { - constructor(protected readonly _options: A.Options) {} - protected _b: B | undefined; + protected _c: C | undefined; + + constructor(protected readonly _options: A.Options) {} public get b(): B { return (this._b ??= new B(this._options)); } - protected _c: C | undefined; - public get c(): C { return (this._c ??= new C(this._options)); } diff --git a/seed/ts-sdk/folders/src/api/resources/folder/client/Client.ts b/seed/ts-sdk/folders/src/api/resources/folder/client/Client.ts index d0ad9155ff0..92c243cfbe4 100644 --- a/seed/ts-sdk/folders/src/api/resources/folder/client/Client.ts +++ b/seed/ts-sdk/folders/src/api/resources/folder/client/Client.ts @@ -24,8 +24,14 @@ export declare namespace Folder { } export class Folder { + protected _service: Service | undefined; + constructor(protected readonly _options: Folder.Options) {} + public get service(): Service { + return (this._service ??= new Service(this._options)); + } + /** * @param {Folder.RequestOptions} requestOptions - Request-specific configuration. * @@ -76,10 +82,4 @@ export class Folder { }); } } - - protected _service: Service | undefined; - - public get service(): Service { - return (this._service ??= new Service(this._options)); - } } diff --git a/seed/ts-sdk/idempotency-headers/src/Client.ts b/seed/ts-sdk/idempotency-headers/src/Client.ts index e1b06ab66c1..9ecaef8348a 100644 --- a/seed/ts-sdk/idempotency-headers/src/Client.ts +++ b/seed/ts-sdk/idempotency-headers/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedIdempotencyHeadersClient { } export class SeedIdempotencyHeadersClient { - constructor(protected readonly _options: SeedIdempotencyHeadersClient.Options) {} - protected _payment: Payment | undefined; + constructor(protected readonly _options: SeedIdempotencyHeadersClient.Options) {} + public get payment(): Payment { return (this._payment ??= new Payment(this._options)); } diff --git a/seed/ts-sdk/idempotency-headers/src/api/resources/payment/client/Client.ts b/seed/ts-sdk/idempotency-headers/src/api/resources/payment/client/Client.ts index da77f0c6073..ed2479483c2 100644 --- a/seed/ts-sdk/idempotency-headers/src/api/resources/payment/client/Client.ts +++ b/seed/ts-sdk/idempotency-headers/src/api/resources/payment/client/Client.ts @@ -24,11 +24,6 @@ export declare namespace Payment { /** Additional headers to include in the request. */ headers?: Record; } - - interface IdempotentRequestOptions extends RequestOptions { - idempotencyKey: string; - idempotencyExpiration: number; - } } export class Payment { diff --git a/seed/ts-sdk/idempotency-headers/src/api/resources/payment/types/Currency.ts b/seed/ts-sdk/idempotency-headers/src/api/resources/payment/types/Currency.ts index 16022be914e..17ebd363838 100644 --- a/seed/ts-sdk/idempotency-headers/src/api/resources/payment/types/Currency.ts +++ b/seed/ts-sdk/idempotency-headers/src/api/resources/payment/types/Currency.ts @@ -3,7 +3,6 @@ */ export type Currency = "USD" | "YEN"; - export const Currency = { Usd: "USD", Yen: "YEN", diff --git a/seed/ts-sdk/imdb/no-custom-config/src/Client.ts b/seed/ts-sdk/imdb/no-custom-config/src/Client.ts index 16058002bad..f31d80e954d 100644 --- a/seed/ts-sdk/imdb/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/imdb/no-custom-config/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedApiClient { } export class SeedApiClient { - constructor(protected readonly _options: SeedApiClient.Options) {} - protected _imdb: Imdb | undefined; + constructor(protected readonly _options: SeedApiClient.Options) {} + public get imdb(): Imdb { return (this._imdb ??= new Imdb(this._options)); } diff --git a/seed/ts-sdk/imdb/noScripts/src/Client.ts b/seed/ts-sdk/imdb/noScripts/src/Client.ts index ba235fe39a6..93246172fb2 100644 --- a/seed/ts-sdk/imdb/noScripts/src/Client.ts +++ b/seed/ts-sdk/imdb/noScripts/src/Client.ts @@ -24,11 +24,11 @@ export declare namespace SeedApiClient { } export class SeedApiClient { + protected _imdb: Imdb | undefined; + constructor(protected readonly _options: SeedApiClient.Options) { } - protected _imdb: Imdb | undefined; - public get imdb(): Imdb { return (this._imdb ??= new Imdb(this._options)); } diff --git a/seed/ts-sdk/imdb/omit-undefined/src/Client.ts b/seed/ts-sdk/imdb/omit-undefined/src/Client.ts index 16058002bad..f31d80e954d 100644 --- a/seed/ts-sdk/imdb/omit-undefined/src/Client.ts +++ b/seed/ts-sdk/imdb/omit-undefined/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedApiClient { } export class SeedApiClient { - constructor(protected readonly _options: SeedApiClient.Options) {} - protected _imdb: Imdb | undefined; + constructor(protected readonly _options: SeedApiClient.Options) {} + public get imdb(): Imdb { return (this._imdb ??= new Imdb(this._options)); } diff --git a/seed/ts-sdk/inline-types/inline/.github/workflows/ci.yml b/seed/ts-sdk/inline-types/inline/.github/workflows/ci.yml new file mode 100644 index 00000000000..b64a6cbbb4a --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/.github/workflows/ci.yml @@ -0,0 +1,57 @@ +name: ci + +on: [push] + +jobs: + compile: + runs-on: ubuntu-latest + + steps: + - name: Checkout repo + uses: actions/checkout@v3 + + - name: Set up node + uses: actions/setup-node@v3 + + - name: Compile + run: yarn && yarn build + + test: + runs-on: ubuntu-latest + + steps: + - name: Checkout repo + uses: actions/checkout@v3 + + - name: Set up node + uses: actions/setup-node@v3 + + - name: Compile + run: yarn && yarn test + + publish: + needs: [ compile, test ] + if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v3 + - name: Set up node + uses: actions/setup-node@v3 + - name: Install dependencies + run: yarn install + - name: Build + run: yarn build + + - name: Publish to npm + run: | + npm config set //registry.npmjs.org/:_authToken ${NPM_TOKEN} + if [[ ${GITHUB_REF} == *alpha* ]]; then + npm publish --access public --tag alpha + elif [[ ${GITHUB_REF} == *beta* ]]; then + npm publish --access public --tag beta + else + npm publish --access public + fi + env: + NPM_TOKEN: ${{ secrets. }} \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/inline/.gitignore b/seed/ts-sdk/inline-types/inline/.gitignore new file mode 100644 index 00000000000..72271e049c0 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/.gitignore @@ -0,0 +1,3 @@ +node_modules +.DS_Store +/dist \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/inline/.mock/definition/__package__.yml b/seed/ts-sdk/inline-types/inline/.mock/definition/__package__.yml new file mode 100644 index 00000000000..af14bf356cd --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/.mock/definition/__package__.yml @@ -0,0 +1,365 @@ +service: + base-path: /root + auth: false + endpoints: + getRoot: + path: /root + method: POST + request: + body: + properties: + bar: RequestTypeInlineType1 + foo: string + content-type: application/json + name: PostRootRequest + response: RootType1 + getDiscriminatedUnion: + path: /discriminated-union + method: POST + request: + body: + properties: + bar: DiscriminatedUnion1 + foo: string + content-type: application/json + name: GetDiscriminatedUnionRequest + getUndiscriminatedUnion: + path: /undiscriminated-union + method: POST + request: + body: + properties: + bar: UndiscriminatedUnion1 + foo: string + content-type: application/json + name: GetUndiscriminatedUnionRequest + +types: + # this is also the type that would be produced by + AliasMapInline: map + AliasSetInline: set + AliasListInline: list + + AliasInlineValue: + inline: true + properties: + foo: string + bar: string + + RequestTypeInlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + + RootType1: + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: RootType1InlineType1 + docs: lorem ipsum + fooMap: + type: map + docs: lorem ipsum + fooList: + type: list + docs: lorem ipsum + fooSet: + type: set + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1FooMapValue: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1FooListItem: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1FooSetItem: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: RootType1InlineType1NestedInlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1InlineType1NestedInlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: string + docs: lorem ipsum + myEnum: + type: InlineEnum1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1: + inline: true + docs: lorem ipsum + union: + type1: + type: DiscriminatedUnion1InlineType1 + docs: lorem ipsum + type2: + type: DiscriminatedUnion1InlineType2 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: DiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1: + inline: true + docs: lorem ipsum + discriminated: false + union: + - type: UndiscriminatedUnion1InlineType1 + docs: lorem ipsum + - type: UndiscriminatedUnion1InlineType2 + docs: lorem ipsum + - type: UndiscriminatedUnion1DiscriminatedUnion1 + docs: lorem ipsum + - type: UndiscriminatedUnion1DiscriminatedUnion1 + docs: lorem ipsum + - type: UndiscriminatedUnion1InlineEnum1 + docs: lorem ipsum + - type: UserId + docs: lorem ipsum + - type: list + docs: lorem ipsum + - type: set + docs: lorem ipsum + - type: map + docs: lorem ipsum + - type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: UndiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + InlineEnum1: + inline: true + docs: lorem ipsum + enum: + - SUNNY + - CLOUDY + - RAINING + - SNOWING + + UndiscriminatedUnion1DiscriminatedUnion1: + inline: true + docs: lorem ipsum + union: + type1: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType1 + docs: lorem ipsum + type2: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType2 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineEnum1: + inline: true + docs: lorem ipsum + enum: + - SUNNY + - CLOUDY + - RAINING + - SNOWING + + UserId: + type: string + docs: lorem ipsum + + UndiscriminatedUnion1InlineListItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineSetItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineMapItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + ReferenceType: + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum diff --git a/seed/ts-sdk/inline-types/inline/.mock/definition/api.yml b/seed/ts-sdk/inline-types/inline/.mock/definition/api.yml new file mode 100644 index 00000000000..a82930c145b --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/.mock/definition/api.yml @@ -0,0 +1 @@ +name: object diff --git a/seed/ts-sdk/inline-types/inline/.mock/fern.config.json b/seed/ts-sdk/inline-types/inline/.mock/fern.config.json new file mode 100644 index 00000000000..4c8e54ac313 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/.mock/fern.config.json @@ -0,0 +1 @@ +{"organization": "fern-test", "version": "*"} \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/inline/.mock/generators.yml b/seed/ts-sdk/inline-types/inline/.mock/generators.yml new file mode 100644 index 00000000000..0967ef424bc --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/.mock/generators.yml @@ -0,0 +1 @@ +{} diff --git a/seed/ts-sdk/inline-types/inline/.mock/ir.json b/seed/ts-sdk/inline-types/inline/.mock/ir.json new file mode 100644 index 00000000000..00d22b232be --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/.mock/ir.json @@ -0,0 +1,4159 @@ +{ + "fdrApiDefinitionId": null, + "apiVersion": null, + "apiName": { + "originalName": "object", + "camelCase": { + "unsafeName": "object", + "safeName": "object" + }, + "snakeCase": { + "unsafeName": "object", + "safeName": "object" + }, + "screamingSnakeCase": { + "unsafeName": "OBJECT", + "safeName": "OBJECT" + }, + "pascalCase": { + "unsafeName": "Object", + "safeName": "Object" + } + }, + "apiDisplayName": null, + "apiDocs": null, + "auth": { + "requirement": "ALL", + "schemes": [], + "docs": null + }, + "headers": [], + "idempotencyHeaders": [], + "types": { + "type_:RequestTypeInlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:RootType1": { + "inline": null, + "name": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [ + "type_:RootType1InlineType1", + "type_:RootType1InlineType1NestedInlineType1", + "type_:InlineEnum" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:RootType1InlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [ + "type_:RootType1InlineType1NestedInlineType1", + "type_:InlineEnum" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:RootType1InlineType1NestedInlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "myEnum", + "camelCase": { + "unsafeName": "myEnum", + "safeName": "myEnum" + }, + "snakeCase": { + "unsafeName": "my_enum", + "safeName": "my_enum" + }, + "screamingSnakeCase": { + "unsafeName": "MY_ENUM", + "safeName": "MY_ENUM" + }, + "pascalCase": { + "unsafeName": "MyEnum", + "safeName": "MyEnum" + } + }, + "wireValue": "myEnum" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:InlineEnum", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [ + "type_:InlineEnum" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:DiscriminatedUnion1": { + "inline": true, + "name": { + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1" + }, + "shape": { + "_type": "union", + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "extends": [], + "baseProperties": [], + "types": [ + { + "discriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type_1", + "safeName": "type_1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_1", + "safeName": "TYPE_1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "shape": { + "_type": "samePropertiesAsObject", + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType1" + }, + "displayName": null, + "availability": null, + "docs": null + }, + { + "discriminantValue": { + "name": { + "originalName": "type2", + "camelCase": { + "unsafeName": "type2", + "safeName": "type2" + }, + "snakeCase": { + "unsafeName": "type_2", + "safeName": "type_2" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_2", + "safeName": "TYPE_2" + }, + "pascalCase": { + "unsafeName": "Type2", + "safeName": "Type2" + } + }, + "wireValue": "type2" + }, + "shape": { + "_type": "samePropertiesAsObject", + "name": { + "originalName": "DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType2", + "safeName": "discriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_2", + "safeName": "discriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType2", + "safeName": "DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType2" + }, + "displayName": null, + "availability": null, + "docs": null + } + ] + }, + "referencedTypes": [ + "type_:DiscriminatedUnion1InlineType1", + "type_:DiscriminatedUnion1InlineType2" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:DiscriminatedUnion1InlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:DiscriminatedUnion1InlineType2": { + "inline": true, + "name": { + "name": { + "originalName": "DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType2", + "safeName": "discriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_2", + "safeName": "discriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType2", + "safeName": "DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType2" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:UndiscriminatedUnion1": { + "inline": true, + "name": { + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1" + }, + "shape": { + "_type": "undiscriminatedUnion", + "members": [ + { + "type": { + "_type": "named", + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1", + "default": null, + "inline": null + }, + "docs": null + }, + { + "type": { + "_type": "named", + "name": { + "originalName": "UndiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_2", + "safeName": "undiscriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType2", + "default": null, + "inline": null + }, + "docs": null + } + ] + }, + "referencedTypes": [ + "type_:UndiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1InlineType2" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:UndiscriminatedUnion1InlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:UndiscriminatedUnion1InlineType2": { + "inline": true, + "name": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_2", + "safeName": "undiscriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType2" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:InlineEnum": { + "inline": true, + "name": { + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:InlineEnum" + }, + "shape": { + "_type": "enum", + "default": null, + "values": [ + { + "name": { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "CLOUDY", + "camelCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "snakeCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "screamingSnakeCase": { + "unsafeName": "CLOUDY", + "safeName": "CLOUDY" + }, + "pascalCase": { + "unsafeName": "Cloudy", + "safeName": "Cloudy" + } + }, + "wireValue": "CLOUDY" + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "RAINING", + "camelCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "snakeCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "screamingSnakeCase": { + "unsafeName": "RAINING", + "safeName": "RAINING" + }, + "pascalCase": { + "unsafeName": "Raining", + "safeName": "Raining" + } + }, + "wireValue": "RAINING" + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "SNOWING", + "camelCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "snakeCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "screamingSnakeCase": { + "unsafeName": "SNOWING", + "safeName": "SNOWING" + }, + "pascalCase": { + "unsafeName": "Snowing", + "safeName": "Snowing" + } + }, + "wireValue": "SNOWING" + }, + "availability": null, + "docs": null + } + ] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + } + }, + "errors": {}, + "services": { + "service_": { + "availability": null, + "name": { + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "displayName": null, + "basePath": { + "head": "/root", + "parts": [] + }, + "headers": [], + "pathParameters": [], + "encoding": { + "json": {}, + "proto": null + }, + "transport": { + "type": "http" + }, + "endpoints": [ + { + "id": "endpoint_.getRoot", + "name": { + "originalName": "getRoot", + "camelCase": { + "unsafeName": "getRoot", + "safeName": "getRoot" + }, + "snakeCase": { + "unsafeName": "get_root", + "safeName": "get_root" + }, + "screamingSnakeCase": { + "unsafeName": "GET_ROOT", + "safeName": "GET_ROOT" + }, + "pascalCase": { + "unsafeName": "GetRoot", + "safeName": "GetRoot" + } + }, + "displayName": null, + "auth": false, + "idempotent": false, + "baseUrl": null, + "method": "POST", + "basePath": null, + "path": { + "head": "/root", + "parts": [] + }, + "fullPath": { + "head": "/root/root", + "parts": [] + }, + "pathParameters": [], + "allPathParameters": [], + "queryParameters": [], + "headers": [], + "requestBody": { + "type": "inlinedRequestBody", + "name": { + "originalName": "PostRootRequest", + "camelCase": { + "unsafeName": "postRootRequest", + "safeName": "postRootRequest" + }, + "snakeCase": { + "unsafeName": "post_root_request", + "safeName": "post_root_request" + }, + "screamingSnakeCase": { + "unsafeName": "POST_ROOT_REQUEST", + "safeName": "POST_ROOT_REQUEST" + }, + "pascalCase": { + "unsafeName": "PostRootRequest", + "safeName": "PostRootRequest" + } + }, + "extends": [], + "contentType": "application/json", + "properties": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [], + "docs": null + }, + "sdkRequest": { + "shape": { + "type": "wrapper", + "wrapperName": { + "originalName": "PostRootRequest", + "camelCase": { + "unsafeName": "postRootRequest", + "safeName": "postRootRequest" + }, + "snakeCase": { + "unsafeName": "post_root_request", + "safeName": "post_root_request" + }, + "screamingSnakeCase": { + "unsafeName": "POST_ROOT_REQUEST", + "safeName": "POST_ROOT_REQUEST" + }, + "pascalCase": { + "unsafeName": "PostRootRequest", + "safeName": "PostRootRequest" + } + }, + "bodyKey": { + "originalName": "body", + "camelCase": { + "unsafeName": "body", + "safeName": "body" + }, + "snakeCase": { + "unsafeName": "body", + "safeName": "body" + }, + "screamingSnakeCase": { + "unsafeName": "BODY", + "safeName": "BODY" + }, + "pascalCase": { + "unsafeName": "Body", + "safeName": "Body" + } + }, + "includePathParameters": false, + "onlyPathParameters": false + }, + "requestParameterName": { + "originalName": "request", + "camelCase": { + "unsafeName": "request", + "safeName": "request" + }, + "snakeCase": { + "unsafeName": "request", + "safeName": "request" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST", + "safeName": "REQUEST" + }, + "pascalCase": { + "unsafeName": "Request", + "safeName": "Request" + } + }, + "streamParameter": null + }, + "response": { + "body": { + "type": "json", + "value": { + "type": "response", + "responseBodyType": { + "_type": "named", + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1", + "default": null, + "inline": null + }, + "docs": null + } + }, + "status-code": null + }, + "errors": [], + "userSpecifiedExamples": [], + "autogeneratedExamples": [ + { + "example": { + "id": "cc979ed415b4638d8e170df64556fbd1154268c5", + "url": "/root/root", + "name": null, + "endpointHeaders": [], + "endpointPathParameters": [], + "queryParameters": [], + "servicePathParameters": [], + "serviceHeaders": [], + "rootPathParameters": [], + "request": { + "type": "inlinedRequestBody", + "properties": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": null, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1" + } + }, + "jsonExample": { + "foo": "foo" + } + } + }, + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": null, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ], + "jsonExample": { + "bar": { + "foo": "foo" + }, + "foo": "foo" + } + }, + "response": { + "type": "ok", + "value": { + "type": "body", + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + }, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + }, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "bar" + } + } + }, + "jsonExample": "bar" + } + }, + { + "name": { + "name": { + "originalName": "myEnum", + "camelCase": { + "unsafeName": "myEnum", + "safeName": "myEnum" + }, + "snakeCase": { + "unsafeName": "my_enum", + "safeName": "my_enum" + }, + "screamingSnakeCase": { + "unsafeName": "MY_ENUM", + "safeName": "MY_ENUM" + }, + "pascalCase": { + "unsafeName": "MyEnum", + "safeName": "MyEnum" + } + }, + "wireValue": "myEnum" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "enum", + "value": { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + } + }, + "typeName": { + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:InlineEnum" + } + }, + "jsonExample": "SUNNY" + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + } + }, + "jsonExample": { + "foo": "foo", + "bar": "bar", + "myEnum": "SUNNY" + } + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + } + }, + "jsonExample": { + "foo": "foo", + "bar": { + "foo": "foo", + "bar": "bar", + "myEnum": "SUNNY" + } + } + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + } + }, + "jsonExample": { + "foo": "foo", + "bar": { + "foo": "foo", + "bar": { + "foo": "foo", + "bar": "bar", + "myEnum": "SUNNY" + } + } + } + } + } + }, + "docs": null + } + } + ], + "pagination": null, + "transport": null, + "availability": null, + "docs": null + }, + { + "id": "endpoint_.getDiscriminatedUnion", + "name": { + "originalName": "getDiscriminatedUnion", + "camelCase": { + "unsafeName": "getDiscriminatedUnion", + "safeName": "getDiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_discriminated_union", + "safeName": "get_discriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_DISCRIMINATED_UNION", + "safeName": "GET_DISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetDiscriminatedUnion", + "safeName": "GetDiscriminatedUnion" + } + }, + "displayName": null, + "auth": false, + "idempotent": false, + "baseUrl": null, + "method": "GET", + "basePath": null, + "path": { + "head": "/discriminated-union", + "parts": [] + }, + "fullPath": { + "head": "/root/discriminated-union", + "parts": [] + }, + "pathParameters": [], + "allPathParameters": [], + "queryParameters": [], + "headers": [], + "requestBody": null, + "sdkRequest": null, + "response": { + "body": { + "type": "json", + "value": { + "type": "response", + "responseBodyType": { + "_type": "named", + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1", + "default": null, + "inline": null + }, + "docs": null + } + }, + "status-code": null + }, + "errors": [], + "userSpecifiedExamples": [], + "autogeneratedExamples": [ + { + "example": { + "id": "66b0f09d479437029bc19bcd824ec0242f8f71e8", + "url": "/root/discriminated-union", + "name": null, + "endpointHeaders": [], + "endpointPathParameters": [], + "queryParameters": [], + "servicePathParameters": [], + "serviceHeaders": [], + "rootPathParameters": [], + "request": null, + "response": { + "type": "ok", + "value": { + "type": "body", + "value": { + "shape": { + "type": "named", + "shape": { + "type": "union", + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "singleUnionType": { + "wireDiscriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type_1", + "safeName": "type_1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_1", + "safeName": "TYPE_1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "shape": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType1", + "object": { + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ] + } + } + } + }, + "typeName": { + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1" + } + }, + "jsonExample": { + "type": "type1", + "foo": "foo" + } + } + } + }, + "docs": null + } + } + ], + "pagination": null, + "transport": null, + "availability": null, + "docs": null + }, + { + "id": "endpoint_.getUndiscriminatedUnion", + "name": { + "originalName": "getUndiscriminatedUnion", + "camelCase": { + "unsafeName": "getUndiscriminatedUnion", + "safeName": "getUndiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_undiscriminated_union", + "safeName": "get_undiscriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_UNDISCRIMINATED_UNION", + "safeName": "GET_UNDISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetUndiscriminatedUnion", + "safeName": "GetUndiscriminatedUnion" + } + }, + "displayName": null, + "auth": false, + "idempotent": false, + "baseUrl": null, + "method": "GET", + "basePath": null, + "path": { + "head": "/undiscriminated-union", + "parts": [] + }, + "fullPath": { + "head": "/root/undiscriminated-union", + "parts": [] + }, + "pathParameters": [], + "allPathParameters": [], + "queryParameters": [], + "headers": [], + "requestBody": null, + "sdkRequest": null, + "response": { + "body": { + "type": "json", + "value": { + "type": "response", + "responseBodyType": { + "_type": "named", + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1", + "default": null, + "inline": null + }, + "docs": null + } + }, + "status-code": null + }, + "errors": [], + "userSpecifiedExamples": [], + "autogeneratedExamples": [ + { + "example": { + "id": "4e32aff3299d7769cc9e184747382c076b82c724", + "url": "/root/undiscriminated-union", + "name": null, + "endpointHeaders": [], + "endpointPathParameters": [], + "queryParameters": [], + "servicePathParameters": [], + "serviceHeaders": [], + "rootPathParameters": [], + "request": null, + "response": { + "type": "ok", + "value": { + "type": "body", + "value": { + "shape": { + "type": "named", + "shape": { + "type": "undiscriminatedUnion", + "index": 0, + "singleUnionType": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ] + }, + "typeName": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1" + } + }, + "jsonExample": { + "foo": "foo" + } + } + }, + "typeName": { + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1" + } + }, + "jsonExample": { + "foo": "foo" + } + } + } + }, + "docs": null + } + } + ], + "pagination": null, + "transport": null, + "availability": null, + "docs": null + } + ] + } + }, + "constants": { + "errorInstanceIdKey": { + "name": { + "originalName": "errorInstanceId", + "camelCase": { + "unsafeName": "errorInstanceId", + "safeName": "errorInstanceId" + }, + "snakeCase": { + "unsafeName": "error_instance_id", + "safeName": "error_instance_id" + }, + "screamingSnakeCase": { + "unsafeName": "ERROR_INSTANCE_ID", + "safeName": "ERROR_INSTANCE_ID" + }, + "pascalCase": { + "unsafeName": "ErrorInstanceId", + "safeName": "ErrorInstanceId" + } + }, + "wireValue": "errorInstanceId" + } + }, + "environments": null, + "errorDiscriminationStrategy": { + "type": "statusCode" + }, + "basePath": null, + "pathParameters": [], + "variables": [], + "serviceTypeReferenceInfo": { + "typesReferencedOnlyByService": { + "service_": [ + "type_:RequestTypeInlineType1", + "type_:RootType1", + "type_:RootType1InlineType1", + "type_:RootType1InlineType1NestedInlineType1", + "type_:DiscriminatedUnion1", + "type_:DiscriminatedUnion1InlineType1", + "type_:DiscriminatedUnion1InlineType2", + "type_:UndiscriminatedUnion1", + "type_:UndiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1InlineType2", + "type_:InlineEnum" + ] + }, + "sharedTypes": [] + }, + "webhookGroups": {}, + "websocketChannels": {}, + "readmeConfig": null, + "sourceConfig": null, + "publishConfig": null, + "dynamic": { + "version": "1.0.0", + "types": { + "type_:RequestTypeInlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:RootType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "named", + "value": "type_:RootType1InlineType1" + } + } + ] + }, + "type_:RootType1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "named", + "value": "type_:RootType1InlineType1NestedInlineType1" + } + } + ] + }, + "type_:RootType1InlineType1NestedInlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "myEnum", + "camelCase": { + "unsafeName": "myEnum", + "safeName": "myEnum" + }, + "snakeCase": { + "unsafeName": "my_enum", + "safeName": "my_enum" + }, + "screamingSnakeCase": { + "unsafeName": "MY_ENUM", + "safeName": "MY_ENUM" + }, + "pascalCase": { + "unsafeName": "MyEnum", + "safeName": "MyEnum" + } + }, + "wireValue": "myEnum" + }, + "typeReference": { + "_type": "named", + "value": "type_:InlineEnum" + } + } + ] + }, + "type_:DiscriminatedUnion1": { + "type": "discriminatedUnion", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "types": { + "type1": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType1", + "discriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type_1", + "safeName": "type_1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_1", + "safeName": "TYPE_1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "properties": [] + }, + "type2": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType2", + "discriminantValue": { + "name": { + "originalName": "type2", + "camelCase": { + "unsafeName": "type2", + "safeName": "type2" + }, + "snakeCase": { + "unsafeName": "type_2", + "safeName": "type_2" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_2", + "safeName": "TYPE_2" + }, + "pascalCase": { + "unsafeName": "Type2", + "safeName": "Type2" + } + }, + "wireValue": "type2" + }, + "properties": [] + } + } + }, + "type_:DiscriminatedUnion1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:DiscriminatedUnion1InlineType2": { + "type": "object", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType2", + "safeName": "discriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_2", + "safeName": "discriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType2", + "safeName": "DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:UndiscriminatedUnion1": { + "type": "undiscriminatedUnion", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "types": [ + { + "_type": "named", + "value": "type_:UndiscriminatedUnion1InlineType1" + }, + { + "_type": "named", + "value": "type_:UndiscriminatedUnion1InlineType2" + } + ] + }, + "type_:UndiscriminatedUnion1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:UndiscriminatedUnion1InlineType2": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_2", + "safeName": "undiscriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:InlineEnum": { + "type": "enum", + "declaration": { + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "values": [ + { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + }, + { + "name": { + "originalName": "CLOUDY", + "camelCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "snakeCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "screamingSnakeCase": { + "unsafeName": "CLOUDY", + "safeName": "CLOUDY" + }, + "pascalCase": { + "unsafeName": "Cloudy", + "safeName": "Cloudy" + } + }, + "wireValue": "CLOUDY" + }, + { + "name": { + "originalName": "RAINING", + "camelCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "snakeCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "screamingSnakeCase": { + "unsafeName": "RAINING", + "safeName": "RAINING" + }, + "pascalCase": { + "unsafeName": "Raining", + "safeName": "Raining" + } + }, + "wireValue": "RAINING" + }, + { + "name": { + "originalName": "SNOWING", + "camelCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "snakeCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "screamingSnakeCase": { + "unsafeName": "SNOWING", + "safeName": "SNOWING" + }, + "pascalCase": { + "unsafeName": "Snowing", + "safeName": "Snowing" + } + }, + "wireValue": "SNOWING" + } + ] + } + }, + "headers": [], + "endpoints": { + "endpoint_.getRoot": { + "auth": null, + "declaration": { + "name": { + "originalName": "getRoot", + "camelCase": { + "unsafeName": "getRoot", + "safeName": "getRoot" + }, + "snakeCase": { + "unsafeName": "get_root", + "safeName": "get_root" + }, + "screamingSnakeCase": { + "unsafeName": "GET_ROOT", + "safeName": "GET_ROOT" + }, + "pascalCase": { + "unsafeName": "GetRoot", + "safeName": "GetRoot" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "location": { + "method": "POST", + "path": "/root/root" + }, + "request": { + "type": "inlined", + "declaration": { + "name": { + "originalName": "PostRootRequest", + "camelCase": { + "unsafeName": "postRootRequest", + "safeName": "postRootRequest" + }, + "snakeCase": { + "unsafeName": "post_root_request", + "safeName": "post_root_request" + }, + "screamingSnakeCase": { + "unsafeName": "POST_ROOT_REQUEST", + "safeName": "POST_ROOT_REQUEST" + }, + "pascalCase": { + "unsafeName": "PostRootRequest", + "safeName": "PostRootRequest" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "pathParameters": [], + "queryParameters": [], + "headers": [], + "body": { + "type": "properties", + "value": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "named", + "value": "type_:RequestTypeInlineType1" + } + }, + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "metadata": { + "includePathParameters": false, + "onlyPathParameters": false + } + }, + "response": { + "type": "json" + } + }, + "endpoint_.getDiscriminatedUnion": { + "auth": null, + "declaration": { + "name": { + "originalName": "getDiscriminatedUnion", + "camelCase": { + "unsafeName": "getDiscriminatedUnion", + "safeName": "getDiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_discriminated_union", + "safeName": "get_discriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_DISCRIMINATED_UNION", + "safeName": "GET_DISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetDiscriminatedUnion", + "safeName": "GetDiscriminatedUnion" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "location": { + "method": "GET", + "path": "/root/discriminated-union" + }, + "request": { + "type": "body", + "pathParameters": [], + "body": null + }, + "response": { + "type": "json" + } + }, + "endpoint_.getUndiscriminatedUnion": { + "auth": null, + "declaration": { + "name": { + "originalName": "getUndiscriminatedUnion", + "camelCase": { + "unsafeName": "getUndiscriminatedUnion", + "safeName": "getUndiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_undiscriminated_union", + "safeName": "get_undiscriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_UNDISCRIMINATED_UNION", + "safeName": "GET_UNDISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetUndiscriminatedUnion", + "safeName": "GetUndiscriminatedUnion" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "location": { + "method": "GET", + "path": "/root/undiscriminated-union" + }, + "request": { + "type": "body", + "pathParameters": [], + "body": null + }, + "response": { + "type": "json" + } + } + } + }, + "subpackages": {}, + "rootPackage": { + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "websocket": null, + "service": "service_", + "types": [ + "type_:RequestTypeInlineType1", + "type_:RootType1", + "type_:RootType1InlineType1", + "type_:RootType1InlineType1NestedInlineType1", + "type_:DiscriminatedUnion1", + "type_:DiscriminatedUnion1InlineType1", + "type_:DiscriminatedUnion1InlineType2", + "type_:UndiscriminatedUnion1", + "type_:UndiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1InlineType2", + "type_:InlineEnum" + ], + "errors": [], + "subpackages": [], + "webhooks": null, + "navigationConfig": null, + "hasEndpointsInTree": true, + "docs": null + }, + "sdkConfig": { + "isAuthMandatory": false, + "hasStreamingEndpoints": false, + "hasPaginatedEndpoints": false, + "hasFileDownloadEndpoints": false, + "platformHeaders": { + "language": "X-Fern-Language", + "sdkName": "X-Fern-SDK-Name", + "sdkVersion": "X-Fern-SDK-Version", + "userAgent": null + } + } +} \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/inline/.npmignore b/seed/ts-sdk/inline-types/inline/.npmignore new file mode 100644 index 00000000000..6db0876c41c --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/.npmignore @@ -0,0 +1,9 @@ +node_modules +src +tests +.gitignore +.github +.fernignore +.prettierrc.yml +tsconfig.json +yarn.lock \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/inline/.prettierrc.yml b/seed/ts-sdk/inline-types/inline/.prettierrc.yml new file mode 100644 index 00000000000..0c06786bf53 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/.prettierrc.yml @@ -0,0 +1,2 @@ +tabWidth: 4 +printWidth: 120 diff --git a/seed/ts-sdk/inline-types/inline/README.md b/seed/ts-sdk/inline-types/inline/README.md new file mode 100644 index 00000000000..3a27a521141 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/README.md @@ -0,0 +1,156 @@ +# Seed TypeScript Library + +[![fern shield](https://img.shields.io/badge/%F0%9F%8C%BF-Built%20with%20Fern-brightgreen)](https://buildwithfern.com?utm_source=github&utm_medium=github&utm_campaign=readme&utm_source=Seed%2FTypeScript) +[![npm shield](https://img.shields.io/npm/v/@fern/inline-types)](https://www.npmjs.com/package/@fern/inline-types) + +The Seed TypeScript library provides convenient access to the Seed API from TypeScript. + +## Installation + +```sh +npm i -s @fern/inline-types +``` + +## Reference + +A full reference for this library is available [here](./reference.md). + +## Usage + +Instantiate and use the client with the following: + +```typescript +import { SeedObjectClient } from "@fern/inline-types"; + +const client = new SeedObjectClient({ environment: "YOUR_BASE_URL" }); +await client.getRoot({ + bar: { + foo: "foo", + }, + foo: "foo", +}); +``` + +## Request And Response Types + +The SDK exports all request and response types as TypeScript interfaces. Simply import them with the +following namespace: + +```typescript +import { SeedObject } from "@fern/inline-types"; + +const request: SeedObject.PostRootRequest = { + ... +}; +``` + +## Exception Handling + +When the API returns a non-success status code (4xx or 5xx response), a subclass of the following error +will be thrown. + +```typescript +import { SeedObjectError } from "@fern/inline-types"; + +try { + await client.getRoot(...); +} catch (err) { + if (err instanceof SeedObjectError) { + console.log(err.statusCode); + console.log(err.message); + console.log(err.body); + } +} +``` + +## Advanced + +### Additional Headers + +If you would like to send additional headers as part of the request, use the `headers` request option. + +```typescript +const response = await client.getRoot(..., { + headers: { + 'X-Custom-Header': 'custom value' + } +}); +``` + +### Retries + +The SDK is instrumented with automatic retries with exponential backoff. A request will be retried as long +as the request is deemed retriable and the number of retry attempts has not grown larger than the configured +retry limit (default: 2). + +A request is deemed retriable when any of the following HTTP status codes is returned: + +- [408](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/408) (Timeout) +- [429](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/429) (Too Many Requests) +- [5XX](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/500) (Internal Server Errors) + +Use the `maxRetries` request option to configure this behavior. + +```typescript +const response = await client.getRoot(..., { + maxRetries: 0 // override maxRetries at the request level +}); +``` + +### Timeouts + +The SDK defaults to a 60 second timeout. Use the `timeoutInSeconds` option to configure this behavior. + +```typescript +const response = await client.getRoot(..., { + timeoutInSeconds: 30 // override timeout to 30s +}); +``` + +### Aborting Requests + +The SDK allows users to abort requests at any point by passing in an abort signal. + +```typescript +const controller = new AbortController(); +const response = await client.getRoot(..., { + abortSignal: controller.signal +}); +controller.abort(); // aborts the request +``` + +### Runtime Compatibility + +The SDK defaults to `node-fetch` but will use the global fetch client if present. The SDK works in the following +runtimes: + +- Node.js 18+ +- Vercel +- Cloudflare Workers +- Deno v1.25+ +- Bun 1.0+ +- React Native + +### Customizing Fetch Client + +The SDK provides a way for your to customize the underlying HTTP client / Fetch function. If you're running in an +unsupported environment, this provides a way for you to break glass and ensure the SDK works. + +```typescript +import { SeedObjectClient } from "@fern/inline-types"; + +const client = new SeedObjectClient({ + ... + fetcher: // provide your implementation here +}); +``` + +## Contributing + +While we value open-source contributions to this SDK, this library is generated programmatically. +Additions made directly to this library would have to be moved over to our generation code, +otherwise they would be overwritten upon the next generated release. Feel free to open a PR as +a proof of concept, but know that we will not be able to merge it as-is. We suggest opening +an issue first to discuss with us! + +On the other hand, contributions to the README are always very welcome! diff --git a/seed/ts-sdk/inline-types/inline/jest.config.js b/seed/ts-sdk/inline-types/inline/jest.config.js new file mode 100644 index 00000000000..35d6e65bf93 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/jest.config.js @@ -0,0 +1,5 @@ +/** @type {import('jest').Config} */ +module.exports = { + preset: "ts-jest", + testEnvironment: "node", +}; diff --git a/seed/ts-sdk/inline-types/inline/package.json b/seed/ts-sdk/inline-types/inline/package.json new file mode 100644 index 00000000000..c62c4aac8d7 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/package.json @@ -0,0 +1,42 @@ +{ + "name": "@fern/inline-types", + "version": "0.0.1", + "private": false, + "repository": "https://github.com/inline-types/fern", + "main": "./index.js", + "types": "./index.d.ts", + "scripts": { + "format": "prettier . --write --ignore-unknown", + "build": "tsc", + "prepack": "cp -rv dist/. .", + "test": "jest" + }, + "dependencies": { + "url-join": "4.0.1", + "form-data": "^4.0.0", + "formdata-node": "^6.0.3", + "node-fetch": "2.7.0", + "qs": "6.11.2", + "readable-stream": "^4.5.2" + }, + "devDependencies": { + "@types/url-join": "4.0.1", + "@types/qs": "6.9.8", + "@types/node-fetch": "2.6.9", + "@types/readable-stream": "^4.0.15", + "webpack": "^5.94.0", + "ts-loader": "^9.3.1", + "jest": "29.7.0", + "@types/jest": "29.5.5", + "ts-jest": "29.1.1", + "jest-environment-jsdom": "29.7.0", + "@types/node": "17.0.33", + "prettier": "2.7.1", + "typescript": "4.6.4" + }, + "browser": { + "fs": false, + "os": false, + "path": false + } +} diff --git a/seed/ts-sdk/inline-types/inline/reference.md b/seed/ts-sdk/inline-types/inline/reference.md new file mode 100644 index 00000000000..25a9fd05cf9 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/reference.md @@ -0,0 +1,65 @@ +# Reference + +
client.getUndiscriminatedUnion({ ...params }) -> void +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.getUndiscriminatedUnion({ + bar: { + foo: "foo", + bar: { + foo: "foo", + ref: { + foo: "foo", + }, + }, + ref: { + foo: "foo", + }, + }, + foo: "foo", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `SeedObject.GetUndiscriminatedUnionRequest` + +
+
+ +
+
+ +**requestOptions:** `SeedObjectClient.RequestOptions` + +
+
+
+
+ +
+
+
+ +## diff --git a/seed/ts-sdk/inline-types/inline/resolved-snippet-templates.md b/seed/ts-sdk/inline-types/inline/resolved-snippet-templates.md new file mode 100644 index 00000000000..816b2039fa1 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/resolved-snippet-templates.md @@ -0,0 +1,51 @@ +```typescript +import { SeedObjectClient } from "@fern/inline-types"; + +const client = new SeedObjectClient({ environment: "YOUR_BASE_URL" }); +await client.getRoot({ + bar: { + foo: "foo", + }, + foo: "foo", +}); + +``` + + +```typescript +import { SeedObjectClient } from "@fern/inline-types"; + +const client = new SeedObjectClient({ environment: "YOUR_BASE_URL" }); +await client.getDiscriminatedUnion( + { + bar: bar: { + type : "type1", + foo: "foo", + bar: { + foo: "foo", + ref: { + foo: "foo" + } + }, + ref: { + foo: "foo" + } + }, + foo: "foo" + } +) + +``` + + +```typescript +import { SeedObjectClient } from "@fern/inline-types"; + +const client = new SeedObjectClient({ environment: "YOUR_BASE_URL" }); +await client.getUndiscriminatedUnion({ + foo: "foo", +}); + +``` + + diff --git a/seed/ts-sdk/inline-types/inline/snippet-templates.json b/seed/ts-sdk/inline-types/inline/snippet-templates.json new file mode 100644 index 00000000000..30032968443 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/snippet-templates.json @@ -0,0 +1,1496 @@ +[ + { + "sdk": { + "package": "@fern/inline-types", + "version": "0.0.1", + "type": "typescript" + }, + "endpointId": { + "path": "/root/root", + "method": "POST", + "identifierOverride": "endpoint_.getRoot" + }, + "snippetTemplate": { + "clientInstantiation": { + "imports": [ + "import { SeedObjectClient } from \"@fern/inline-types\";" + ], + "templateString": "const client = new SeedObjectClient($FERN_INPUT);", + "isOptional": false, + "inputDelimiter": ",", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{ $FERN_INPUT }", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "environment: \"YOUR_BASE_URL\"", + "isOptional": false, + "templateInputs": [], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "functionInvocation": { + "imports": [], + "templateString": "await client.getRoot(\n\t$FERN_INPUT\n)", + "isOptional": false, + "inputDelimiter": ",\n\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{\n\t\t$FERN_INPUT\n\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "bar: {\n\t\t\t$FERN_INPUT\n\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "v1" + } + }, + { + "sdk": { + "package": "@fern/inline-types", + "version": "0.0.1", + "type": "typescript" + }, + "endpointId": { + "path": "/root/discriminated-union", + "method": "POST", + "identifierOverride": "endpoint_.getDiscriminatedUnion" + }, + "snippetTemplate": { + "clientInstantiation": { + "imports": [ + "import { SeedObjectClient } from \"@fern/inline-types\";" + ], + "templateString": "const client = new SeedObjectClient($FERN_INPUT);", + "isOptional": false, + "inputDelimiter": ",", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{ $FERN_INPUT }", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "environment: \"YOUR_BASE_URL\"", + "isOptional": false, + "templateInputs": [], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "functionInvocation": { + "imports": [], + "templateString": "await client.getDiscriminatedUnion(\n\t$FERN_INPUT\n)", + "isOptional": false, + "inputDelimiter": ",\n\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{\n\t\t$FERN_INPUT\n\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "isOptional": true, + "templateString": "bar: $FERN_INPUT", + "discriminantField": "type", + "members": { + "type1": { + "imports": [], + "templateString": "bar: { \n\t\t\ttype : \"type1\", \n\t\t\t$FERN_INPUT\n\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "bar: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type2": { + "imports": [], + "templateString": "bar: { \n\t\t\ttype : \"type2\", \n\t\t\t$FERN_INPUT\n\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "baz: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.baz", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "ref": { + "imports": [], + "templateString": "bar: { \n\t\t\ttype : \"ref\", \n\t\t\t$FERN_INPUT\n\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + } + }, + "templateInput": { + "location": "BODY", + "path": "bar", + "type": "payload" + }, + "type": "discriminatedUnion" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "v1" + } + }, + { + "sdk": { + "package": "@fern/inline-types", + "version": "0.0.1", + "type": "typescript" + }, + "endpointId": { + "path": "/root/undiscriminated-union", + "method": "POST", + "identifierOverride": "endpoint_.getUndiscriminatedUnion" + }, + "snippetTemplate": { + "clientInstantiation": { + "imports": [ + "import { SeedObjectClient } from \"@fern/inline-types\";" + ], + "templateString": "const client = new SeedObjectClient($FERN_INPUT);", + "isOptional": false, + "inputDelimiter": ",", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{ $FERN_INPUT }", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "environment: \"YOUR_BASE_URL\"", + "isOptional": false, + "templateInputs": [], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "functionInvocation": { + "imports": [], + "templateString": "await client.getUndiscriminatedUnion(\n\t$FERN_INPUT\n)", + "isOptional": false, + "inputDelimiter": ",\n\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{\n\t\t$FERN_INPUT\n\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "isOptional": true, + "templateString": "bar: $FERN_INPUT", + "members": [ + { + "template": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "bar: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": { + "value": "type_:UndiscriminatedUnion1InlineType1", + "type": "id" + } + }, + { + "template": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "baz: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "baz", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": { + "value": "type_:UndiscriminatedUnion1InlineType2", + "type": "id" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "templateString": "$FERN_INPUT", + "discriminantField": "type", + "members": { + "type1": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"type1\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "bar: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type2": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"type2\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "baz: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "baz", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "ref": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"ref\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + } + }, + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "discriminatedUnion" + }, + "type": { + "value": "type_:UndiscriminatedUnion1DiscriminatedUnion1", + "type": "id" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "templateString": "$FERN_INPUT", + "discriminantField": "type", + "members": { + "type1": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"type1\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "bar: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type2": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"type2\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "baz: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "baz", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "ref": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"ref\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + } + }, + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "discriminatedUnion" + }, + "type": { + "value": "type_:UndiscriminatedUnion1DiscriminatedUnion1", + "type": "id" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "values": { + "SUNNY": "\"SUNNY\"", + "CLOUDY": "\"CLOUDY\"", + "RAINING": "\"RAINING\"", + "SNOWING": "\"SNOWING\"" + }, + "templateString": "$FERN_INPUT", + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "enum" + }, + "type": { + "value": "type_:UndiscriminatedUnion1InlineEnum1", + "type": "id" + } + }, + { + "template": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "type": "payload" + } + ], + "type": "generic" + }, + "type": { + "value": "type_:UserId", + "type": "id" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "containerTemplateString": "[\n\t\t\t\t$FERN_INPUT\n\t\t\t]", + "delimiter": ",\n\t\t\t\t", + "innerTemplate": { + "imports": [], + "templateString": "{\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "iterable" + }, + "type": { + "itemType": { + "value": "type_:UndiscriminatedUnion1InlineListItem1", + "type": "id" + }, + "type": "list" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "containerTemplateString": "new Set([\n\t\t\t\t$FERN_INPUT\n\t\t\t])", + "delimiter": ",\n\t\t\t\t", + "innerTemplate": { + "imports": [], + "templateString": "{\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "iterable" + }, + "type": { + "itemType": { + "value": "type_:UndiscriminatedUnion1InlineSetItem1", + "type": "id" + }, + "type": "set" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "containerTemplateString": "{\n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "delimiter": ",\n\t\t\t\t", + "keyValueSeparator": ": ", + "keyTemplate": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "type": "payload" + } + ], + "type": "generic" + }, + "valueTemplate": { + "imports": [], + "templateString": "{\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "dict" + }, + "type": { + "keyType": { + "value": { + "type": "string" + }, + "type": "primitive" + }, + "valueType": { + "value": "type_:UndiscriminatedUnion1InlineMapItem1", + "type": "id" + }, + "type": "map" + } + }, + { + "template": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": { + "value": "type_:ReferenceType", + "type": "id" + } + } + ], + "templateInput": { + "location": "BODY", + "path": "bar", + "type": "payload" + }, + "type": "union_v2" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "v1" + } + } +] \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/inline/snippet.json b/seed/ts-sdk/inline-types/inline/snippet.json new file mode 100644 index 00000000000..6b5456d3c0d --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/snippet.json @@ -0,0 +1,38 @@ +{ + "endpoints": [ + { + "id": { + "path": "/root/root", + "method": "POST", + "identifier_override": "endpoint_.getRoot" + }, + "snippet": { + "type": "typescript", + "client": "import { SeedObjectClient } from \"@fern/inline-types\";\n\nconst client = new SeedObjectClient({ environment: \"YOUR_BASE_URL\" });\nawait client.getRoot({\n bar: {\n foo: \"foo\"\n },\n foo: \"foo\"\n});\n" + } + }, + { + "id": { + "path": "/root/discriminated-union", + "method": "POST", + "identifier_override": "endpoint_.getDiscriminatedUnion" + }, + "snippet": { + "type": "typescript", + "client": "import { SeedObjectClient } from \"@fern/inline-types\";\n\nconst client = new SeedObjectClient({ environment: \"YOUR_BASE_URL\" });\nawait client.getDiscriminatedUnion({\n bar: {\n type: \"type1\",\n foo: \"foo\",\n bar: {\n foo: \"foo\",\n ref: {\n foo: \"foo\"\n }\n },\n ref: {\n foo: \"foo\"\n }\n },\n foo: \"foo\"\n});\n" + } + }, + { + "id": { + "path": "/root/undiscriminated-union", + "method": "POST", + "identifier_override": "endpoint_.getUndiscriminatedUnion" + }, + "snippet": { + "type": "typescript", + "client": "import { SeedObjectClient } from \"@fern/inline-types\";\n\nconst client = new SeedObjectClient({ environment: \"YOUR_BASE_URL\" });\nawait client.getUndiscriminatedUnion({\n bar: {\n foo: \"foo\",\n bar: {\n foo: \"foo\",\n ref: {\n foo: \"foo\"\n }\n },\n ref: {\n foo: \"foo\"\n }\n },\n foo: \"foo\"\n});\n" + } + } + ], + "types": {} +} \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/inline/src/Client.ts b/seed/ts-sdk/inline-types/inline/src/Client.ts new file mode 100644 index 00000000000..888489f9147 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/Client.ts @@ -0,0 +1,235 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as core from "./core"; +import * as SeedObject from "./api/index"; +import urlJoin from "url-join"; +import * as errors from "./errors/index"; + +export declare namespace SeedObjectClient { + interface Options { + environment: core.Supplier; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + } +} + +export class SeedObjectClient { + constructor(protected readonly _options: SeedObjectClient.Options) {} + + /** + * @param {SeedObject.PostRootRequest} request + * @param {SeedObjectClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.getRoot({ + * bar: { + * foo: "foo" + * }, + * foo: "foo" + * }) + */ + public async getRoot( + request: SeedObject.PostRootRequest, + requestOptions?: SeedObjectClient.RequestOptions + ): Promise { + const _response = await core.fetcher({ + url: urlJoin(await core.Supplier.get(this._options.environment), "/root/root"), + method: "POST", + headers: { + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "@fern/inline-types", + "X-Fern-SDK-Version": "0.0.1", + "User-Agent": "@fern/inline-types/0.0.1", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as SeedObject.RootType1; + } + + if (_response.error.reason === "status-code") { + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.SeedObjectTimeoutError("Timeout exceeded when calling POST /root/root."); + case "unknown": + throw new errors.SeedObjectError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * @param {SeedObject.GetDiscriminatedUnionRequest} request + * @param {SeedObjectClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.getDiscriminatedUnion({ + * bar: { + * type: "type1", + * foo: "foo", + * bar: { + * foo: "foo", + * ref: { + * foo: "foo" + * } + * }, + * ref: { + * foo: "foo" + * } + * }, + * foo: "foo" + * }) + */ + public async getDiscriminatedUnion( + request: SeedObject.GetDiscriminatedUnionRequest, + requestOptions?: SeedObjectClient.RequestOptions + ): Promise { + const _response = await core.fetcher({ + url: urlJoin(await core.Supplier.get(this._options.environment), "/root/discriminated-union"), + method: "POST", + headers: { + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "@fern/inline-types", + "X-Fern-SDK-Version": "0.0.1", + "User-Agent": "@fern/inline-types/0.0.1", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.SeedObjectTimeoutError( + "Timeout exceeded when calling POST /root/discriminated-union." + ); + case "unknown": + throw new errors.SeedObjectError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * @param {SeedObject.GetUndiscriminatedUnionRequest} request + * @param {SeedObjectClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.getUndiscriminatedUnion({ + * bar: { + * foo: "foo", + * bar: { + * foo: "foo", + * ref: { + * foo: "foo" + * } + * }, + * ref: { + * foo: "foo" + * } + * }, + * foo: "foo" + * }) + */ + public async getUndiscriminatedUnion( + request: SeedObject.GetUndiscriminatedUnionRequest, + requestOptions?: SeedObjectClient.RequestOptions + ): Promise { + const _response = await core.fetcher({ + url: urlJoin(await core.Supplier.get(this._options.environment), "/root/undiscriminated-union"), + method: "POST", + headers: { + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "@fern/inline-types", + "X-Fern-SDK-Version": "0.0.1", + "User-Agent": "@fern/inline-types/0.0.1", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.SeedObjectTimeoutError( + "Timeout exceeded when calling POST /root/undiscriminated-union." + ); + case "unknown": + throw new errors.SeedObjectError({ + message: _response.error.errorMessage, + }); + } + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/api/client/index.ts b/seed/ts-sdk/inline-types/inline/src/api/client/index.ts new file mode 100644 index 00000000000..415726b7fea --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/seed/ts-sdk/inline-types/inline/src/api/client/requests/GetDiscriminatedUnionRequest.ts b/seed/ts-sdk/inline-types/inline/src/api/client/requests/GetDiscriminatedUnionRequest.ts new file mode 100644 index 00000000000..a5ec42dca0f --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/client/requests/GetDiscriminatedUnionRequest.ts @@ -0,0 +1,81 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../../index"; + +/** + * @example + * { + * bar: { + * type: "type1", + * foo: "foo", + * bar: { + * foo: "foo", + * ref: { + * foo: "foo" + * } + * }, + * ref: { + * foo: "foo" + * } + * }, + * foo: "foo" + * } + */ +export interface GetDiscriminatedUnionRequest { + bar: GetDiscriminatedUnionRequest.Bar; + foo: string; +} + +export namespace GetDiscriminatedUnionRequest { + /** + * lorem ipsum + */ + export type Bar = + /** + * lorem ipsum */ + | Bar.Type1 + /** + * lorem ipsum */ + | Bar.Type2 + /** + * lorem ipsum */ + | Bar.Ref; + + export namespace Bar { + export interface Type1 { + type: "type1"; + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: DiscriminatedUnion1InlineType1.Bar; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; + } + + export namespace DiscriminatedUnion1InlineType1 { + /** + * lorem ipsum + */ + export interface Bar { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; + } + } + + export interface Type2 { + type: "type2"; + /** lorem ipsum */ + baz: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; + } + + export interface Ref extends SeedObject.ReferenceType { + type: "ref"; + } + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/api/client/requests/GetUndiscriminatedUnionRequest.ts b/seed/ts-sdk/inline-types/inline/src/api/client/requests/GetUndiscriminatedUnionRequest.ts new file mode 100644 index 00000000000..dda9e5023fe --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/client/requests/GetUndiscriminatedUnionRequest.ts @@ -0,0 +1,115 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../../index"; + +/** + * @example + * { + * bar: { + * foo: "foo", + * bar: { + * foo: "foo", + * ref: { + * foo: "foo" + * } + * }, + * ref: { + * foo: "foo" + * } + * }, + * foo: "foo" + * } + */ +export interface GetUndiscriminatedUnionRequest { + bar: GetUndiscriminatedUnionRequest.Bar; + foo: string; +} + +export namespace GetUndiscriminatedUnionRequest { + /** + * lorem ipsum + */ + export type Bar = + /** + * lorem ipsum */ + | { + foo: string; + bar: { + foo: string; + ref: SeedObject.ReferenceType; + }; + ref: SeedObject.ReferenceType; + } + /** + * lorem ipsum */ + | { + baz: string; + ref: SeedObject.ReferenceType; + } + /** + * lorem ipsum */ + | ( + | { + foo: string; + bar: { + foo: string; + ref: SeedObject.ReferenceType; + }; + ref: SeedObject.ReferenceType; + } + | { + baz: string; + ref: SeedObject.ReferenceType; + } + | SeedObject.ReferenceType + ) + /** + * lorem ipsum */ + | ( + | { + foo: string; + bar: { + foo: string; + ref: SeedObject.ReferenceType; + }; + ref: SeedObject.ReferenceType; + } + | { + baz: string; + ref: SeedObject.ReferenceType; + } + | SeedObject.ReferenceType + ) + /** + * lorem ipsum */ + | ("SUNNY" | "CLOUDY" | "RAINING" | "SNOWING") + /** + * lorem ipsum */ + | SeedObject.UserId + /** + * lorem ipsum */ + | { + foo: string; + ref: SeedObject.ReferenceType; + }[] + /** + * lorem ipsum */ + | { + foo: string; + ref: SeedObject.ReferenceType; + }[] + /** + * lorem ipsum */ + | Record< + string, + { + foo: string; + ref: SeedObject.ReferenceType; + } + > + /** + * lorem ipsum */ + | SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/inline/src/api/client/requests/PostRootRequest.ts b/seed/ts-sdk/inline-types/inline/src/api/client/requests/PostRootRequest.ts new file mode 100644 index 00000000000..beab02b7863 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/client/requests/PostRootRequest.ts @@ -0,0 +1,27 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * @example + * { + * bar: { + * foo: "foo" + * }, + * foo: "foo" + * } + */ +export interface PostRootRequest { + bar: PostRootRequest.Bar; + foo: string; +} + +export namespace PostRootRequest { + /** + * lorem ipsum + */ + export interface Bar { + /** lorem ipsum */ + foo: string; + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/api/client/requests/index.ts b/seed/ts-sdk/inline-types/inline/src/api/client/requests/index.ts new file mode 100644 index 00000000000..20fc5cd64ec --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type PostRootRequest } from "./PostRootRequest"; +export { type GetDiscriminatedUnionRequest } from "./GetDiscriminatedUnionRequest"; +export { type GetUndiscriminatedUnionRequest } from "./GetUndiscriminatedUnionRequest"; diff --git a/seed/ts-sdk/inline-types/inline/src/api/index.ts b/seed/ts-sdk/inline-types/inline/src/api/index.ts new file mode 100644 index 00000000000..c9240f83b48 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/seed/ts-sdk/inline-types/inline/src/api/types/AliasListInline.ts b/seed/ts-sdk/inline-types/inline/src/api/types/AliasListInline.ts new file mode 100644 index 00000000000..a74cec8eb2f --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/types/AliasListInline.ts @@ -0,0 +1,12 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type AliasListInline = AliasListInline.Item[]; + +export namespace AliasListInline { + export interface Item { + foo: string; + bar: string; + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/api/types/AliasMapInline.ts b/seed/ts-sdk/inline-types/inline/src/api/types/AliasMapInline.ts new file mode 100644 index 00000000000..8bde68a6297 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/types/AliasMapInline.ts @@ -0,0 +1,12 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type AliasMapInline = Record; + +export namespace AliasMapInline { + export interface Value { + foo: string; + bar: string; + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/api/types/AliasSetInline.ts b/seed/ts-sdk/inline-types/inline/src/api/types/AliasSetInline.ts new file mode 100644 index 00000000000..5c07872142b --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/types/AliasSetInline.ts @@ -0,0 +1,12 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export type AliasSetInline = AliasSetInline.Item[]; + +export namespace AliasSetInline { + export interface Item { + foo: string; + bar: string; + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/api/types/ReferenceType.ts b/seed/ts-sdk/inline-types/inline/src/api/types/ReferenceType.ts new file mode 100644 index 00000000000..3754bc9c7e2 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/types/ReferenceType.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * lorem ipsum + */ +export interface ReferenceType { + /** lorem ipsum */ + foo: string; +} diff --git a/seed/ts-sdk/inline-types/inline/src/api/types/RootType1.ts b/seed/ts-sdk/inline-types/inline/src/api/types/RootType1.ts new file mode 100644 index 00000000000..139e5f42231 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/types/RootType1.ts @@ -0,0 +1,106 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: RootType1.Bar; + /** lorem ipsum */ + fooMap: Record; + /** lorem ipsum */ + fooList: RootType1.FooList.Item[]; + /** lorem ipsum */ + fooSet: RootType1.FooSet.Item[]; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} + +export namespace RootType1 { + /** + * lorem ipsum + */ + export interface Bar { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: Bar.Bar; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; + } + + export namespace Bar { + /** + * lorem ipsum + */ + export interface Bar { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: string; + /** lorem ipsum */ + myEnum: Bar.MyEnum; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; + } + + export namespace Bar { + /** + * lorem ipsum + */ + export type MyEnum = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; + export const MyEnum = { + Sunny: "SUNNY", + Cloudy: "CLOUDY", + Raining: "RAINING", + Snowing: "SNOWING", + } as const; + } + } + + export namespace FooMap { + /** + * lorem ipsum + */ + export interface Value { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; + } + } + + export type FooList = FooList.Item[]; + + export namespace FooList { + /** + * lorem ipsum + */ + export interface Item { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; + } + } + + export type FooSet = FooSet.Item[]; + + export namespace FooSet { + /** + * lorem ipsum + */ + export interface Item { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; + } + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/api/types/UserId.ts b/seed/ts-sdk/inline-types/inline/src/api/types/UserId.ts new file mode 100644 index 00000000000..5a6e3e5152f --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/types/UserId.ts @@ -0,0 +1,8 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * lorem ipsum + */ +export type UserId = string; diff --git a/seed/ts-sdk/inline-types/inline/src/api/types/index.ts b/seed/ts-sdk/inline-types/inline/src/api/types/index.ts new file mode 100644 index 00000000000..a96d5677b58 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/api/types/index.ts @@ -0,0 +1,6 @@ +export * from "./AliasMapInline"; +export * from "./AliasSetInline"; +export * from "./AliasListInline"; +export * from "./RootType1"; +export * from "./UserId"; +export * from "./ReferenceType"; diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/APIResponse.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/APIResponse.ts new file mode 100644 index 00000000000..3664d09e168 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/APIResponse.ts @@ -0,0 +1,12 @@ +export type APIResponse = SuccessfulResponse | FailedResponse; + +export interface SuccessfulResponse { + ok: true; + body: T; + headers?: Record; +} + +export interface FailedResponse { + ok: false; + error: T; +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/Fetcher.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/Fetcher.ts new file mode 100644 index 00000000000..b8f23717b69 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/Fetcher.ts @@ -0,0 +1,143 @@ +import { APIResponse } from "./APIResponse"; +import { createRequestUrl } from "./createRequestUrl"; +import { getFetchFn } from "./getFetchFn"; +import { getRequestBody } from "./getRequestBody"; +import { getResponseBody } from "./getResponseBody"; +import { makeRequest } from "./makeRequest"; +import { requestWithRetries } from "./requestWithRetries"; + +export type FetchFunction = (args: Fetcher.Args) => Promise>; + +export declare namespace Fetcher { + export interface Args { + url: string; + method: string; + contentType?: string; + headers?: Record; + queryParameters?: Record; + body?: unknown; + timeoutMs?: number; + maxRetries?: number; + withCredentials?: boolean; + abortSignal?: AbortSignal; + requestType?: "json" | "file" | "bytes"; + responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer"; + duplex?: "half"; + } + + export type Error = FailedStatusCodeError | NonJsonError | TimeoutError | UnknownError; + + export interface FailedStatusCodeError { + reason: "status-code"; + statusCode: number; + body: unknown; + } + + export interface NonJsonError { + reason: "non-json"; + statusCode: number; + rawBody: string; + } + + export interface TimeoutError { + reason: "timeout"; + } + + export interface UnknownError { + reason: "unknown"; + errorMessage: string; + } +} + +export async function fetcherImpl(args: Fetcher.Args): Promise> { + const headers: Record = {}; + if (args.body !== undefined && args.contentType != null) { + headers["Content-Type"] = args.contentType; + } + + if (args.headers != null) { + for (const [key, value] of Object.entries(args.headers)) { + if (value != null) { + headers[key] = value; + } + } + } + + const url = createRequestUrl(args.url, args.queryParameters); + let requestBody: BodyInit | undefined = await getRequestBody({ + body: args.body, + type: args.requestType === "json" ? "json" : "other", + }); + const fetchFn = await getFetchFn(); + + try { + const response = await requestWithRetries( + async () => + makeRequest( + fetchFn, + url, + args.method, + headers, + requestBody, + args.timeoutMs, + args.abortSignal, + args.withCredentials, + args.duplex + ), + args.maxRetries + ); + let responseBody = await getResponseBody(response, args.responseType); + + if (response.status >= 200 && response.status < 400) { + return { + ok: true, + body: responseBody as R, + headers: response.headers, + }; + } else { + return { + ok: false, + error: { + reason: "status-code", + statusCode: response.status, + body: responseBody, + }, + }; + } + } catch (error) { + if (args.abortSignal != null && args.abortSignal.aborted) { + return { + ok: false, + error: { + reason: "unknown", + errorMessage: "The user aborted a request", + }, + }; + } else if (error instanceof Error && error.name === "AbortError") { + return { + ok: false, + error: { + reason: "timeout", + }, + }; + } else if (error instanceof Error) { + return { + ok: false, + error: { + reason: "unknown", + errorMessage: error.message, + }, + }; + } + + return { + ok: false, + error: { + reason: "unknown", + errorMessage: JSON.stringify(error), + }, + }; + } +} + +export const fetcher: FetchFunction = fetcherImpl; diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/Supplier.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/Supplier.ts new file mode 100644 index 00000000000..867c931c02f --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/Supplier.ts @@ -0,0 +1,11 @@ +export type Supplier = T | Promise | (() => T | Promise); + +export const Supplier = { + get: async (supplier: Supplier): Promise => { + if (typeof supplier === "function") { + return (supplier as () => T)(); + } else { + return supplier; + } + }, +}; diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/createRequestUrl.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/createRequestUrl.ts new file mode 100644 index 00000000000..9288a99bb22 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/createRequestUrl.ts @@ -0,0 +1,10 @@ +import qs from "qs"; + +export function createRequestUrl( + baseUrl: string, + queryParameters?: Record +): string { + return Object.keys(queryParameters ?? {}).length > 0 + ? `${baseUrl}?${qs.stringify(queryParameters, { arrayFormat: "repeat" })}` + : baseUrl; +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/getFetchFn.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/getFetchFn.ts new file mode 100644 index 00000000000..9fd9bfc42bd --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/getFetchFn.ts @@ -0,0 +1,25 @@ +import { RUNTIME } from "../runtime"; + +/** + * Returns a fetch function based on the runtime + */ +export async function getFetchFn(): Promise { + // In Node.js 18+ environments, use native fetch + if (RUNTIME.type === "node" && RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { + return fetch; + } + + // In Node.js 18 or lower environments, the SDK always uses`node-fetch`. + if (RUNTIME.type === "node") { + return (await import("node-fetch")).default as any; + } + + // Otherwise the SDK uses global fetch if available, + // and falls back to node-fetch. + if (typeof fetch == "function") { + return fetch; + } + + // Defaults to node `node-fetch` if global fetch isn't available + return (await import("node-fetch")).default as any; +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/getHeader.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/getHeader.ts new file mode 100644 index 00000000000..50f922b0e87 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/getHeader.ts @@ -0,0 +1,8 @@ +export function getHeader(headers: Record, header: string): string | undefined { + for (const [headerKey, headerValue] of Object.entries(headers)) { + if (headerKey.toLowerCase() === header.toLowerCase()) { + return headerValue; + } + } + return undefined; +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/getRequestBody.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/getRequestBody.ts new file mode 100644 index 00000000000..1138414b1c2 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/getRequestBody.ts @@ -0,0 +1,14 @@ +export declare namespace GetRequestBody { + interface Args { + body: unknown; + type: "json" | "file" | "bytes" | "other"; + } +} + +export async function getRequestBody({ body, type }: GetRequestBody.Args): Promise { + if (type.includes("json")) { + return JSON.stringify(body); + } else { + return body as BodyInit; + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/getResponseBody.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/getResponseBody.ts new file mode 100644 index 00000000000..d046e6ea275 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/getResponseBody.ts @@ -0,0 +1,34 @@ +import { chooseStreamWrapper } from "./stream-wrappers/chooseStreamWrapper"; + +export async function getResponseBody(response: Response, responseType?: string): Promise { + if (response.body != null && responseType === "blob") { + return await response.blob(); + } else if (response.body != null && responseType === "arrayBuffer") { + return await response.arrayBuffer(); + } else if (response.body != null && responseType === "sse") { + return response.body; + } else if (response.body != null && responseType === "streaming") { + return chooseStreamWrapper(response.body); + } else if (response.body != null && responseType === "text") { + return await response.text(); + } else { + const text = await response.text(); + if (text.length > 0) { + try { + let responseBody = JSON.parse(text); + return responseBody; + } catch (err) { + return { + ok: false, + error: { + reason: "non-json", + statusCode: response.status, + rawBody: text, + }, + }; + } + } else { + return undefined; + } + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/index.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/index.ts new file mode 100644 index 00000000000..2d658ca48f9 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/index.ts @@ -0,0 +1,5 @@ +export type { APIResponse } from "./APIResponse"; +export { fetcher } from "./Fetcher"; +export type { Fetcher, FetchFunction } from "./Fetcher"; +export { getHeader } from "./getHeader"; +export { Supplier } from "./Supplier"; diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/makeRequest.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/makeRequest.ts new file mode 100644 index 00000000000..8fb4bace466 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/makeRequest.ts @@ -0,0 +1,44 @@ +import { anySignal, getTimeoutSignal } from "./signals"; + +export const makeRequest = async ( + fetchFn: (url: string, init: RequestInit) => Promise, + url: string, + method: string, + headers: Record, + requestBody: BodyInit | undefined, + timeoutMs?: number, + abortSignal?: AbortSignal, + withCredentials?: boolean, + duplex?: "half" +): Promise => { + const signals: AbortSignal[] = []; + + // Add timeout signal + let timeoutAbortId: NodeJS.Timeout | undefined = undefined; + if (timeoutMs != null) { + const { signal, abortId } = getTimeoutSignal(timeoutMs); + timeoutAbortId = abortId; + signals.push(signal); + } + + // Add arbitrary signal + if (abortSignal != null) { + signals.push(abortSignal); + } + let newSignals = anySignal(signals); + const response = await fetchFn(url, { + method: method, + headers, + body: requestBody, + signal: newSignals, + credentials: withCredentials ? "include" : undefined, + // @ts-ignore + duplex, + }); + + if (timeoutAbortId != null) { + clearTimeout(timeoutAbortId); + } + + return response; +}; diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/requestWithRetries.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/requestWithRetries.ts new file mode 100644 index 00000000000..8d5af9d5a82 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/requestWithRetries.ts @@ -0,0 +1,33 @@ +const INITIAL_RETRY_DELAY = 1000; // in milliseconds +const MAX_RETRY_DELAY = 60000; // in milliseconds +const DEFAULT_MAX_RETRIES = 2; +const JITTER_FACTOR = 0.2; // 20% random jitter + +function addJitter(delay: number): number { + // Generate a random value between -JITTER_FACTOR and +JITTER_FACTOR + const jitterMultiplier = 1 + (Math.random() * 2 - 1) * JITTER_FACTOR; + return delay * jitterMultiplier; +} + +export async function requestWithRetries( + requestFn: () => Promise, + maxRetries: number = DEFAULT_MAX_RETRIES +): Promise { + let response: Response = await requestFn(); + + for (let i = 0; i < maxRetries; ++i) { + if ([408, 409, 429].includes(response.status) || response.status >= 500) { + // Calculate base delay using exponential backoff (in milliseconds) + const baseDelay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY); + + // Add jitter to the delay + const delayWithJitter = addJitter(baseDelay); + + await new Promise((resolve) => setTimeout(resolve, delayWithJitter)); + response = await requestFn(); + } else { + break; + } + } + return response!; +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/signals.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/signals.ts new file mode 100644 index 00000000000..6c124ff7985 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/signals.ts @@ -0,0 +1,38 @@ +const TIMEOUT = "timeout"; + +export function getTimeoutSignal(timeoutMs: number): { signal: AbortSignal; abortId: NodeJS.Timeout } { + const controller = new AbortController(); + const abortId = setTimeout(() => controller.abort(TIMEOUT), timeoutMs); + return { signal: controller.signal, abortId }; +} + +/** + * Returns an abort signal that is getting aborted when + * at least one of the specified abort signals is aborted. + * + * Requires at least node.js 18. + */ +export function anySignal(...args: AbortSignal[] | [AbortSignal[]]): AbortSignal { + // Allowing signals to be passed either as array + // of signals or as multiple arguments. + const signals = (args.length === 1 && Array.isArray(args[0]) ? args[0] : args); + + const controller = new AbortController(); + + for (const signal of signals) { + if (signal.aborted) { + // Exiting early if one of the signals + // is already aborted. + controller.abort((signal as any)?.reason); + break; + } + + // Listening for signals and removing the listeners + // when at least one symbol is aborted. + signal.addEventListener("abort", () => controller.abort((signal as any)?.reason), { + signal: controller.signal, + }); + } + + return controller.signal; +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts new file mode 100644 index 00000000000..4d7b7d52e8f --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts @@ -0,0 +1,256 @@ +import type { Writable } from "readable-stream"; +import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; + +export class Node18UniversalStreamWrapper + implements + StreamWrapper | Writable | WritableStream, ReadFormat> +{ + private readableStream: ReadableStream; + private reader: ReadableStreamDefaultReader; + private events: Record; + private paused: boolean; + private resumeCallback: ((value?: unknown) => void) | null; + private encoding: string | null; + + constructor(readableStream: ReadableStream) { + this.readableStream = readableStream; + this.reader = this.readableStream.getReader(); + this.events = { + data: [], + end: [], + error: [], + readable: [], + close: [], + pause: [], + resume: [], + }; + this.paused = false; + this.resumeCallback = null; + this.encoding = null; + } + + public on(event: string, callback: EventCallback): void { + this.events[event]?.push(callback); + } + + public off(event: string, callback: EventCallback): void { + this.events[event] = this.events[event]?.filter((cb) => cb !== callback); + } + + public pipe( + dest: Node18UniversalStreamWrapper | Writable | WritableStream + ): Node18UniversalStreamWrapper | Writable | WritableStream { + this.on("data", async (chunk) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._write(chunk); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } else { + dest.write(chunk); + } + }); + + this.on("end", async () => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._end(); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.close(); + } else { + dest.end(); + } + }); + + this.on("error", async (error) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._error(error); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.abort(error); + } else { + dest.destroy(error); + } + }); + + this._startReading(); + + return dest; + } + + public pipeTo( + dest: Node18UniversalStreamWrapper | Writable | WritableStream + ): Node18UniversalStreamWrapper | Writable | WritableStream { + return this.pipe(dest); + } + + public unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void { + this.off("data", async (chunk) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._write(chunk); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } else { + dest.write(chunk); + } + }); + + this.off("end", async () => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._end(); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.close(); + } else { + dest.end(); + } + }); + + this.off("error", async (error) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._error(error); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.abort(error); + } else { + dest.destroy(error); + } + }); + } + + public destroy(error?: Error): void { + this.reader + .cancel(error) + .then(() => { + this._emit("close"); + }) + .catch((err) => { + this._emit("error", err); + }); + } + + public pause(): void { + this.paused = true; + this._emit("pause"); + } + + public resume(): void { + if (this.paused) { + this.paused = false; + this._emit("resume"); + if (this.resumeCallback) { + this.resumeCallback(); + this.resumeCallback = null; + } + } + } + + public get isPaused(): boolean { + return this.paused; + } + + public async read(): Promise { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + + if (done) { + return undefined; + } + return value; + } + + public setEncoding(encoding: string): void { + this.encoding = encoding; + } + + public async text(): Promise { + const chunks: ReadFormat[] = []; + + while (true) { + const { done, value } = await this.reader.read(); + if (done) { + break; + } + if (value) { + chunks.push(value); + } + } + + const decoder = new TextDecoder(this.encoding || "utf-8"); + return decoder.decode(await new Blob(chunks).arrayBuffer()); + } + + public async json(): Promise { + const text = await this.text(); + return JSON.parse(text); + } + + private _write(chunk: ReadFormat): void { + this._emit("data", chunk); + } + + private _end(): void { + this._emit("end"); + } + + private _error(error: any): void { + this._emit("error", error); + } + + private _emit(event: string, data?: any): void { + if (this.events[event]) { + for (const callback of this.events[event] || []) { + callback(data); + } + } + } + + private async _startReading(): Promise { + try { + this._emit("readable"); + while (true) { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + this._emit("end"); + this._emit("close"); + break; + } + if (value) { + this._emit("data", value); + } + } + } catch (error) { + this._emit("error", error); + } + } + + [Symbol.asyncIterator](): AsyncIterableIterator { + return { + next: async () => { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return { done: true, value: undefined }; + } + return { done: false, value }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts new file mode 100644 index 00000000000..ba5f7276750 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts @@ -0,0 +1,106 @@ +import type { Readable, Writable } from "readable-stream"; +import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; + +export class NodePre18StreamWrapper implements StreamWrapper { + private readableStream: Readable; + private encoding: string | undefined; + + constructor(readableStream: Readable) { + this.readableStream = readableStream; + } + + public on(event: string, callback: EventCallback): void { + this.readableStream.on(event, callback); + } + + public off(event: string, callback: EventCallback): void { + this.readableStream.off(event, callback); + } + + public pipe(dest: Writable): Writable { + this.readableStream.pipe(dest); + return dest; + } + + public pipeTo(dest: Writable): Writable { + return this.pipe(dest); + } + + public unpipe(dest?: Writable): void { + if (dest) { + this.readableStream.unpipe(dest); + } else { + this.readableStream.unpipe(); + } + } + + public destroy(error?: Error): void { + this.readableStream.destroy(error); + } + + public pause(): void { + this.readableStream.pause(); + } + + public resume(): void { + this.readableStream.resume(); + } + + public get isPaused(): boolean { + return this.readableStream.isPaused(); + } + + public async read(): Promise { + return new Promise((resolve, reject) => { + const chunk = this.readableStream.read(); + if (chunk) { + resolve(chunk); + } else { + this.readableStream.once("readable", () => { + const chunk = this.readableStream.read(); + resolve(chunk); + }); + this.readableStream.once("error", reject); + } + }); + } + + public setEncoding(encoding?: string): void { + this.readableStream.setEncoding(encoding as BufferEncoding); + this.encoding = encoding; + } + + public async text(): Promise { + const chunks: Uint8Array[] = []; + const encoder = new TextEncoder(); + this.readableStream.setEncoding((this.encoding || "utf-8") as BufferEncoding); + + for await (const chunk of this.readableStream) { + chunks.push(encoder.encode(chunk)); + } + + const decoder = new TextDecoder(this.encoding || "utf-8"); + return decoder.decode(Buffer.concat(chunks)); + } + + public async json(): Promise { + const text = await this.text(); + return JSON.parse(text); + } + + public [Symbol.asyncIterator](): AsyncIterableIterator { + const readableStream = this.readableStream; + const iterator = readableStream[Symbol.asyncIterator](); + + // Create and return an async iterator that yields buffers + return { + async next(): Promise> { + const { value, done } = await iterator.next(); + return { value: value as Buffer, done }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts new file mode 100644 index 00000000000..263af00911f --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts @@ -0,0 +1,243 @@ +import { StreamWrapper } from "./chooseStreamWrapper"; + +type EventCallback = (data?: any) => void; + +export class UndiciStreamWrapper + implements StreamWrapper | WritableStream, ReadFormat> +{ + private readableStream: ReadableStream; + private reader: ReadableStreamDefaultReader; + private events: Record; + private paused: boolean; + private resumeCallback: ((value?: unknown) => void) | null; + private encoding: string | null; + + constructor(readableStream: ReadableStream) { + this.readableStream = readableStream; + this.reader = this.readableStream.getReader(); + this.events = { + data: [], + end: [], + error: [], + readable: [], + close: [], + pause: [], + resume: [], + }; + this.paused = false; + this.resumeCallback = null; + this.encoding = null; + } + + public on(event: string, callback: EventCallback): void { + this.events[event]?.push(callback); + } + + public off(event: string, callback: EventCallback): void { + this.events[event] = this.events[event]?.filter((cb) => cb !== callback); + } + + public pipe( + dest: UndiciStreamWrapper | WritableStream + ): UndiciStreamWrapper | WritableStream { + this.on("data", (chunk) => { + if (dest instanceof UndiciStreamWrapper) { + dest._write(chunk); + } else { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } + }); + + this.on("end", () => { + if (dest instanceof UndiciStreamWrapper) { + dest._end(); + } else { + const writer = dest.getWriter(); + writer.close(); + } + }); + + this.on("error", (error) => { + if (dest instanceof UndiciStreamWrapper) { + dest._error(error); + } else { + const writer = dest.getWriter(); + writer.abort(error); + } + }); + + this._startReading(); + + return dest; + } + + public pipeTo( + dest: UndiciStreamWrapper | WritableStream + ): UndiciStreamWrapper | WritableStream { + return this.pipe(dest); + } + + public unpipe(dest: UndiciStreamWrapper | WritableStream): void { + this.off("data", (chunk) => { + if (dest instanceof UndiciStreamWrapper) { + dest._write(chunk); + } else { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } + }); + + this.off("end", () => { + if (dest instanceof UndiciStreamWrapper) { + dest._end(); + } else { + const writer = dest.getWriter(); + writer.close(); + } + }); + + this.off("error", (error) => { + if (dest instanceof UndiciStreamWrapper) { + dest._error(error); + } else { + const writer = dest.getWriter(); + writer.abort(error); + } + }); + } + + public destroy(error?: Error): void { + this.reader + .cancel(error) + .then(() => { + this._emit("close"); + }) + .catch((err) => { + this._emit("error", err); + }); + } + + public pause(): void { + this.paused = true; + this._emit("pause"); + } + + public resume(): void { + if (this.paused) { + this.paused = false; + this._emit("resume"); + if (this.resumeCallback) { + this.resumeCallback(); + this.resumeCallback = null; + } + } + } + + public get isPaused(): boolean { + return this.paused; + } + + public async read(): Promise { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return undefined; + } + return value; + } + + public setEncoding(encoding: string): void { + this.encoding = encoding; + } + + public async text(): Promise { + const chunks: BlobPart[] = []; + + while (true) { + const { done, value } = await this.reader.read(); + if (done) { + break; + } + if (value) { + chunks.push(value); + } + } + + const decoder = new TextDecoder(this.encoding || "utf-8"); + return decoder.decode(await new Blob(chunks).arrayBuffer()); + } + + public async json(): Promise { + const text = await this.text(); + return JSON.parse(text); + } + + private _write(chunk: ReadFormat): void { + this._emit("data", chunk); + } + + private _end(): void { + this._emit("end"); + } + + private _error(error: any): void { + this._emit("error", error); + } + + private _emit(event: string, data?: any): void { + if (this.events[event]) { + for (const callback of this.events[event] || []) { + callback(data); + } + } + } + + private async _startReading(): Promise { + try { + this._emit("readable"); + while (true) { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + this._emit("end"); + this._emit("close"); + break; + } + if (value) { + this._emit("data", value); + } + } + } catch (error) { + this._emit("error", error); + } + } + + [Symbol.asyncIterator](): AsyncIterableIterator { + return { + next: async () => { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return { done: true, value: undefined }; + } + return { done: false, value }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts b/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts new file mode 100644 index 00000000000..2abd6b2ba1c --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts @@ -0,0 +1,33 @@ +import type { Readable } from "readable-stream"; +import { RUNTIME } from "../../runtime"; + +export type EventCallback = (data?: any) => void; + +export interface StreamWrapper { + setEncoding(encoding?: string): void; + on(event: string, callback: EventCallback): void; + off(event: string, callback: EventCallback): void; + pipe(dest: WritableStream): WritableStream; + pipeTo(dest: WritableStream): WritableStream; + unpipe(dest?: WritableStream): void; + destroy(error?: Error): void; + pause(): void; + resume(): void; + get isPaused(): boolean; + read(): Promise; + text(): Promise; + json(): Promise; + [Symbol.asyncIterator](): AsyncIterableIterator; +} + +export async function chooseStreamWrapper(responseBody: any): Promise>> { + if (RUNTIME.type === "node" && RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { + return new (await import("./Node18UniversalStreamWrapper")).Node18UniversalStreamWrapper( + responseBody as ReadableStream + ); + } else if (RUNTIME.type !== "node" && typeof fetch === "function") { + return new (await import("./UndiciStreamWrapper")).UndiciStreamWrapper(responseBody as ReadableStream); + } else { + return new (await import("./NodePre18StreamWrapper")).NodePre18StreamWrapper(responseBody as Readable); + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/core/index.ts b/seed/ts-sdk/inline-types/inline/src/core/index.ts new file mode 100644 index 00000000000..000107d9932 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/index.ts @@ -0,0 +1,2 @@ +export * from "./fetcher"; +export * from "./runtime"; diff --git a/seed/ts-sdk/inline-types/inline/src/core/runtime/index.ts b/seed/ts-sdk/inline-types/inline/src/core/runtime/index.ts new file mode 100644 index 00000000000..5c76dbb133f --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/runtime/index.ts @@ -0,0 +1 @@ +export { RUNTIME } from "./runtime"; diff --git a/seed/ts-sdk/inline-types/inline/src/core/runtime/runtime.ts b/seed/ts-sdk/inline-types/inline/src/core/runtime/runtime.ts new file mode 100644 index 00000000000..4d0687e8eb4 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/core/runtime/runtime.ts @@ -0,0 +1,126 @@ +interface DenoGlobal { + version: { + deno: string; + }; +} + +interface BunGlobal { + version: string; +} + +declare const Deno: DenoGlobal; +declare const Bun: BunGlobal; + +/** + * A constant that indicates whether the environment the code is running is a Web Browser. + */ +const isBrowser = typeof window !== "undefined" && typeof window.document !== "undefined"; + +/** + * A constant that indicates whether the environment the code is running is a Web Worker. + */ +const isWebWorker = + typeof self === "object" && + // @ts-ignore + typeof self?.importScripts === "function" && + (self.constructor?.name === "DedicatedWorkerGlobalScope" || + self.constructor?.name === "ServiceWorkerGlobalScope" || + self.constructor?.name === "SharedWorkerGlobalScope"); + +/** + * A constant that indicates whether the environment the code is running is Deno. + */ +const isDeno = + typeof Deno !== "undefined" && typeof Deno.version !== "undefined" && typeof Deno.version.deno !== "undefined"; + +/** + * A constant that indicates whether the environment the code is running is Bun.sh. + */ +const isBun = typeof Bun !== "undefined" && typeof Bun.version !== "undefined"; + +/** + * A constant that indicates whether the environment the code is running is Node.JS. + */ +const isNode = + typeof process !== "undefined" && + Boolean(process.version) && + Boolean(process.versions?.node) && + // Deno spoofs process.versions.node, see https://deno.land/std@0.177.0/node/process.ts?s=versions + !isDeno && + !isBun; + +/** + * A constant that indicates whether the environment the code is running is in React-Native. + * https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Core/setUpNavigator.js + */ +const isReactNative = typeof navigator !== "undefined" && navigator?.product === "ReactNative"; + +/** + * A constant that indicates whether the environment the code is running is Cloudflare. + * https://developers.cloudflare.com/workers/runtime-apis/web-standards/#navigatoruseragent + */ +const isCloudflare = typeof globalThis !== "undefined" && globalThis?.navigator?.userAgent === "Cloudflare-Workers"; + +/** + * A constant that indicates which environment and version the SDK is running in. + */ +export const RUNTIME: Runtime = evaluateRuntime(); + +export interface Runtime { + type: "browser" | "web-worker" | "deno" | "bun" | "node" | "react-native" | "unknown" | "workerd"; + version?: string; + parsedVersion?: number; +} + +function evaluateRuntime(): Runtime { + if (isBrowser) { + return { + type: "browser", + version: window.navigator.userAgent, + }; + } + + if (isCloudflare) { + return { + type: "workerd", + }; + } + + if (isWebWorker) { + return { + type: "web-worker", + }; + } + + if (isDeno) { + return { + type: "deno", + version: Deno.version.deno, + }; + } + + if (isBun) { + return { + type: "bun", + version: Bun.version, + }; + } + + if (isNode) { + return { + type: "node", + version: process.versions.node, + parsedVersion: Number(process.versions.node.split(".")[0]), + }; + } + + if (isReactNative) { + return { + type: "react-native", + }; + } + + return { + type: "unknown", + }; +} diff --git a/seed/ts-sdk/inline-types/inline/src/errors/SeedObjectError.ts b/seed/ts-sdk/inline-types/inline/src/errors/SeedObjectError.ts new file mode 100644 index 00000000000..489ad43d19e --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/errors/SeedObjectError.ts @@ -0,0 +1,45 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export class SeedObjectError extends Error { + readonly statusCode?: number; + readonly body?: unknown; + + constructor({ message, statusCode, body }: { message?: string; statusCode?: number; body?: unknown }) { + super(buildMessage({ message, statusCode, body })); + Object.setPrototypeOf(this, SeedObjectError.prototype); + if (statusCode != null) { + this.statusCode = statusCode; + } + + if (body !== undefined) { + this.body = body; + } + } +} + +function buildMessage({ + message, + statusCode, + body, +}: { + message: string | undefined; + statusCode: number | undefined; + body: unknown | undefined; +}): string { + let lines: string[] = []; + if (message != null) { + lines.push(message); + } + + if (statusCode != null) { + lines.push(`Status code: ${statusCode.toString()}`); + } + + if (body != null) { + lines.push(`Body: ${JSON.stringify(body, undefined, 2)}`); + } + + return lines.join("\n"); +} diff --git a/seed/ts-sdk/inline-types/inline/src/errors/SeedObjectTimeoutError.ts b/seed/ts-sdk/inline-types/inline/src/errors/SeedObjectTimeoutError.ts new file mode 100644 index 00000000000..27e69eb189f --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/errors/SeedObjectTimeoutError.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export class SeedObjectTimeoutError extends Error { + constructor(message: string) { + super(message); + Object.setPrototypeOf(this, SeedObjectTimeoutError.prototype); + } +} diff --git a/seed/ts-sdk/inline-types/inline/src/errors/index.ts b/seed/ts-sdk/inline-types/inline/src/errors/index.ts new file mode 100644 index 00000000000..c41ddbbfd72 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/errors/index.ts @@ -0,0 +1,2 @@ +export { SeedObjectError } from "./SeedObjectError"; +export { SeedObjectTimeoutError } from "./SeedObjectTimeoutError"; diff --git a/seed/ts-sdk/inline-types/inline/src/index.ts b/seed/ts-sdk/inline-types/inline/src/index.ts new file mode 100644 index 00000000000..bbb7c569b72 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/index.ts @@ -0,0 +1,3 @@ +export * as SeedObject from "./api"; +export { SeedObjectClient } from "./Client"; +export { SeedObjectError, SeedObjectTimeoutError } from "./errors"; diff --git a/seed/ts-sdk/inline-types/inline/src/version.ts b/seed/ts-sdk/inline-types/inline/src/version.ts new file mode 100644 index 00000000000..b643a3e3ea2 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/src/version.ts @@ -0,0 +1 @@ +export const SDK_VERSION = "0.0.1"; diff --git a/seed/ts-sdk/inline-types/inline/tests/custom.test.ts b/seed/ts-sdk/inline-types/inline/tests/custom.test.ts new file mode 100644 index 00000000000..7f5e031c839 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/custom.test.ts @@ -0,0 +1,13 @@ +/** + * This is a custom test file, if you wish to add more tests + * to your SDK. + * Be sure to mark this file in `.fernignore`. + * + * If you include example requests/responses in your fern definition, + * you will have tests automatically generated for you. + */ +describe("test", () => { + it("default", () => { + expect(true).toBe(true); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/Fetcher.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/Fetcher.test.ts new file mode 100644 index 00000000000..ff8042175ff --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/Fetcher.test.ts @@ -0,0 +1,73 @@ +import fs from "fs"; +import { Fetcher, fetcherImpl } from "../../../src/core/fetcher/Fetcher"; +import { join } from "path"; + +describe("Test fetcherImpl", () => { + it("should handle successful request", async () => { + const mockArgs: Fetcher.Args = { + url: "https://httpbin.org/post", + method: "POST", + headers: { "X-Test": "x-test-header" }, + body: { data: "test" }, + contentType: "application/json", + requestType: "json", + }; + + global.fetch = jest.fn().mockResolvedValue({ + ok: true, + status: 200, + text: () => Promise.resolve(JSON.stringify({ data: "test" })), + json: () => ({ data: "test" }), + }); + + const result = await fetcherImpl(mockArgs); + expect(result.ok).toBe(true); + if (result.ok) { + expect(result.body).toEqual({ data: "test" }); + } + + expect(global.fetch).toHaveBeenCalledWith( + "https://httpbin.org/post", + expect.objectContaining({ + method: "POST", + headers: expect.objectContaining({ "X-Test": "x-test-header" }), + body: JSON.stringify({ data: "test" }), + }) + ); + }); + + it("should send octet stream", async () => { + const url = "https://httpbin.org/post/file"; + const mockArgs: Fetcher.Args = { + url, + method: "POST", + headers: { "X-Test": "x-test-header" }, + contentType: "application/octet-stream", + requestType: "bytes", + duplex: "half", + body: fs.createReadStream(join(__dirname, "test-file.txt")), + }; + + global.fetch = jest.fn().mockResolvedValue({ + ok: true, + status: 200, + text: () => Promise.resolve(JSON.stringify({ data: "test" })), + json: () => Promise.resolve({ data: "test" }), + }); + + const result = await fetcherImpl(mockArgs); + + expect(global.fetch).toHaveBeenCalledWith( + url, + expect.objectContaining({ + method: "POST", + headers: expect.objectContaining({ "X-Test": "x-test-header" }), + body: expect.any(fs.ReadStream), + }) + ); + expect(result.ok).toBe(true); + if (result.ok) { + expect(result.body).toEqual({ data: "test" }); + } + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/createRequestUrl.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/createRequestUrl.test.ts new file mode 100644 index 00000000000..f2cd24b6721 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/createRequestUrl.test.ts @@ -0,0 +1,51 @@ +import { createRequestUrl } from "../../../src/core/fetcher/createRequestUrl"; + +describe("Test createRequestUrl", () => { + it("should return the base URL when no query parameters are provided", () => { + const baseUrl = "https://api.example.com"; + expect(createRequestUrl(baseUrl)).toBe(baseUrl); + }); + + it("should append simple query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { key: "value", another: "param" }; + expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?key=value&another=param"); + }); + + it("should handle array query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { items: ["a", "b", "c"] }; + expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?items=a&items=b&items=c"); + }); + + it("should handle object query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { filter: { name: "John", age: 30 } }; + expect(createRequestUrl(baseUrl, queryParams)).toBe( + "https://api.example.com?filter%5Bname%5D=John&filter%5Bage%5D=30" + ); + }); + + it("should handle mixed types of query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { + simple: "value", + array: ["x", "y"], + object: { key: "value" }, + }; + expect(createRequestUrl(baseUrl, queryParams)).toBe( + "https://api.example.com?simple=value&array=x&array=y&object%5Bkey%5D=value" + ); + }); + + it("should handle empty query parameters object", () => { + const baseUrl = "https://api.example.com"; + expect(createRequestUrl(baseUrl, {})).toBe(baseUrl); + }); + + it("should encode special characters in query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { special: "a&b=c d" }; + expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?special=a%26b%3Dc%20d"); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/getFetchFn.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/getFetchFn.test.ts new file mode 100644 index 00000000000..9b315ad095a --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/getFetchFn.test.ts @@ -0,0 +1,22 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { getFetchFn } from "../../../src/core/fetcher/getFetchFn"; + +describe("Test for getFetchFn", () => { + it("should get node-fetch function", async () => { + if (RUNTIME.type == "node") { + if (RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { + expect(await getFetchFn()).toBe(fetch); + } else { + expect(await getFetchFn()).toEqual((await import("node-fetch")).default as any); + } + } + }); + + it("should get fetch function", async () => { + if (RUNTIME.type == "browser") { + const fetchFn = await getFetchFn(); + expect(typeof fetchFn).toBe("function"); + expect(fetchFn.name).toBe("fetch"); + } + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/getRequestBody.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/getRequestBody.test.ts new file mode 100644 index 00000000000..919604c2e12 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/getRequestBody.test.ts @@ -0,0 +1,77 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { getRequestBody } from "../../../src/core/fetcher/getRequestBody"; + +describe("Test getRequestBody", () => { + it("should return FormData as is in Node environment", async () => { + if (RUNTIME.type === "node") { + const formData = new (await import("formdata-node")).FormData(); + formData.append("key", "value"); + const result = await getRequestBody({ + body: formData, + type: "file", + }); + expect(result).toBe(formData); + } + }); + + it("should stringify body if not FormData in Node environment", async () => { + if (RUNTIME.type === "node") { + const body = { key: "value" }; + const result = await getRequestBody({ + body, + type: "json", + }); + expect(result).toBe('{"key":"value"}'); + } + }); + + it("should return FormData in browser environment", async () => { + if (RUNTIME.type === "browser") { + const formData = new (await import("form-data")).default(); + formData.append("key", "value"); + const result = await getRequestBody({ + body: formData, + type: "file", + }); + expect(result).toBe(formData); + } + }); + + it("should stringify body if not FormData in browser environment", async () => { + if (RUNTIME.type === "browser") { + const body = { key: "value" }; + const result = await getRequestBody({ + body, + type: "json", + }); + expect(result).toBe('{"key":"value"}'); + } + }); + + it("should return the Uint8Array", async () => { + const input = new Uint8Array([1, 2, 3]); + const result = await getRequestBody({ + body: input, + type: "bytes", + }); + expect(result).toBe(input); + }); + + it("should return the input for content-type 'application/x-www-form-urlencoded'", async () => { + const input = "key=value&another=param"; + const result = await getRequestBody({ + body: input, + type: "other", + }); + expect(result).toBe(input); + }); + + it("should JSON stringify objects", async () => { + const input = { key: "value" }; + const result = await getRequestBody({ + body: input, + type: "json", + }); + expect(result).toBe('{"key":"value"}'); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/getResponseBody.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/getResponseBody.test.ts new file mode 100644 index 00000000000..1030c517ced --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/getResponseBody.test.ts @@ -0,0 +1,64 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { getResponseBody } from "../../../src/core/fetcher/getResponseBody"; +import { chooseStreamWrapper } from "../../../src/core/fetcher/stream-wrappers/chooseStreamWrapper"; + +describe("Test getResponseBody", () => { + it("should handle blob response type", async () => { + const mockBlob = new Blob(["test"], { type: "text/plain" }); + const mockResponse = new Response(mockBlob); + const result = await getResponseBody(mockResponse, "blob"); + // @ts-expect-error + expect(result.constructor.name).toBe("Blob"); + }); + + it("should handle sse response type", async () => { + if (RUNTIME.type === "node") { + const mockStream = new ReadableStream(); + const mockResponse = new Response(mockStream); + const result = await getResponseBody(mockResponse, "sse"); + expect(result).toBe(mockStream); + } + }); + + it("should handle streaming response type", async () => { + if (RUNTIME.type === "node") { + const mockStream = new ReadableStream(); + const mockResponse = new Response(mockStream); + const result = await getResponseBody(mockResponse, "streaming"); + // need to reinstantiate string as a result of locked state in Readable Stream after registration with Response + expect(JSON.stringify(result)).toBe(JSON.stringify(await chooseStreamWrapper(new ReadableStream()))); + } + }); + + it("should handle text response type", async () => { + const mockResponse = new Response("test text"); + const result = await getResponseBody(mockResponse, "text"); + expect(result).toBe("test text"); + }); + + it("should handle JSON response", async () => { + const mockJson = { key: "value" }; + const mockResponse = new Response(JSON.stringify(mockJson)); + const result = await getResponseBody(mockResponse); + expect(result).toEqual(mockJson); + }); + + it("should handle empty response", async () => { + const mockResponse = new Response(""); + const result = await getResponseBody(mockResponse); + expect(result).toBeUndefined(); + }); + + it("should handle non-JSON response", async () => { + const mockResponse = new Response("invalid json"); + const result = await getResponseBody(mockResponse); + expect(result).toEqual({ + ok: false, + error: { + reason: "non-json", + statusCode: 200, + rawBody: "invalid json", + }, + }); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/makeRequest.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/makeRequest.test.ts new file mode 100644 index 00000000000..be94ab45f10 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/makeRequest.test.ts @@ -0,0 +1,54 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { makeRequest } from "../../../src/core/fetcher/makeRequest"; + +describe("Test makeRequest", () => { + const mockPostUrl = "https://httpbin.org/post"; + const mockGetUrl = "https://httpbin.org/get"; + const mockHeaders = { "Content-Type": "application/json" }; + const mockBody = JSON.stringify({ key: "value" }); + + let mockFetch: jest.Mock; + + beforeEach(() => { + mockFetch = jest.fn(); + mockFetch.mockResolvedValue(new Response(JSON.stringify({ test: "successful" }), { status: 200 })); + }); + + it("should handle POST request correctly", async () => { + const response = await makeRequest(mockFetch, mockPostUrl, "POST", mockHeaders, mockBody); + const responseBody = await response.json(); + expect(responseBody).toEqual({ test: "successful" }); + expect(mockFetch).toHaveBeenCalledTimes(1); + const [calledUrl, calledOptions] = mockFetch.mock.calls[0]; + expect(calledUrl).toBe(mockPostUrl); + expect(calledOptions).toEqual( + expect.objectContaining({ + method: "POST", + headers: mockHeaders, + body: mockBody, + credentials: undefined, + }) + ); + expect(calledOptions.signal).toBeDefined(); + expect(calledOptions.signal).toBeInstanceOf(AbortSignal); + }); + + it("should handle GET request correctly", async () => { + const response = await makeRequest(mockFetch, mockGetUrl, "GET", mockHeaders, undefined); + const responseBody = await response.json(); + expect(responseBody).toEqual({ test: "successful" }); + expect(mockFetch).toHaveBeenCalledTimes(1); + const [calledUrl, calledOptions] = mockFetch.mock.calls[0]; + expect(calledUrl).toBe(mockGetUrl); + expect(calledOptions).toEqual( + expect.objectContaining({ + method: "GET", + headers: mockHeaders, + body: undefined, + credentials: undefined, + }) + ); + expect(calledOptions.signal).toBeDefined(); + expect(calledOptions.signal).toBeInstanceOf(AbortSignal); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/requestWithRetries.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/requestWithRetries.test.ts new file mode 100644 index 00000000000..6f77f093edf --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/requestWithRetries.test.ts @@ -0,0 +1,133 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { requestWithRetries } from "../../../src/core/fetcher/requestWithRetries"; + +describe("requestWithRetries", () => { + let mockFetch: jest.Mock; + let originalMathRandom: typeof Math.random; + let setTimeoutSpy: jest.SpyInstance; + + beforeEach(() => { + mockFetch = jest.fn(); + originalMathRandom = Math.random; + + // Mock Math.random for consistent jitter + Math.random = jest.fn(() => 0.5); + + jest.useFakeTimers({ doNotFake: ["nextTick"] }); + }); + + afterEach(() => { + Math.random = originalMathRandom; + jest.clearAllMocks(); + jest.clearAllTimers(); + }); + + it("should retry on retryable status codes", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + const retryableStatuses = [408, 409, 429, 500, 502]; + let callCount = 0; + + mockFetch.mockImplementation(async () => { + if (callCount < retryableStatuses.length) { + return new Response("", { status: retryableStatuses[callCount++] }); + } + return new Response("", { status: 200 }); + }); + + const responsePromise = requestWithRetries(() => mockFetch(), retryableStatuses.length); + await jest.runAllTimersAsync(); + const response = await responsePromise; + + expect(mockFetch).toHaveBeenCalledTimes(retryableStatuses.length + 1); + expect(response.status).toBe(200); + }); + + it("should respect maxRetries limit", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + const maxRetries = 2; + mockFetch.mockResolvedValue(new Response("", { status: 500 })); + + const responsePromise = requestWithRetries(() => mockFetch(), maxRetries); + await jest.runAllTimersAsync(); + const response = await responsePromise; + + expect(mockFetch).toHaveBeenCalledTimes(maxRetries + 1); + expect(response.status).toBe(500); + }); + + it("should not retry on success status codes", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + const successStatuses = [200, 201, 202]; + + for (const status of successStatuses) { + mockFetch.mockReset(); + setTimeoutSpy.mockClear(); + mockFetch.mockResolvedValueOnce(new Response("", { status })); + + const responsePromise = requestWithRetries(() => mockFetch(), 3); + await jest.runAllTimersAsync(); + await responsePromise; + + expect(mockFetch).toHaveBeenCalledTimes(1); + expect(setTimeoutSpy).not.toHaveBeenCalled(); + } + }); + + it("should apply correct exponential backoff with jitter", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + mockFetch.mockResolvedValue(new Response("", { status: 500 })); + const maxRetries = 3; + const expectedDelays = [1000, 2000, 4000]; + + const responsePromise = requestWithRetries(() => mockFetch(), maxRetries); + await jest.runAllTimersAsync(); + await responsePromise; + + // Verify setTimeout calls + expect(setTimeoutSpy).toHaveBeenCalledTimes(expectedDelays.length); + + expectedDelays.forEach((delay, index) => { + expect(setTimeoutSpy).toHaveBeenNthCalledWith(index + 1, expect.any(Function), delay); + }); + + expect(mockFetch).toHaveBeenCalledTimes(maxRetries + 1); + }); + + it("should handle concurrent retries independently", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + mockFetch + .mockResolvedValueOnce(new Response("", { status: 500 })) + .mockResolvedValueOnce(new Response("", { status: 500 })) + .mockResolvedValueOnce(new Response("", { status: 200 })) + .mockResolvedValueOnce(new Response("", { status: 200 })); + + const promise1 = requestWithRetries(() => mockFetch(), 1); + const promise2 = requestWithRetries(() => mockFetch(), 1); + + await jest.runAllTimersAsync(); + const [response1, response2] = await Promise.all([promise1, promise2]); + + expect(response1.status).toBe(200); + expect(response2.status).toBe(200); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/signals.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/signals.test.ts new file mode 100644 index 00000000000..9cabfa07447 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/signals.test.ts @@ -0,0 +1,69 @@ +import { anySignal, getTimeoutSignal } from "../../../src/core/fetcher/signals"; + +describe("Test getTimeoutSignal", () => { + beforeEach(() => { + jest.useFakeTimers(); + }); + + afterEach(() => { + jest.useRealTimers(); + }); + + it("should return an object with signal and abortId", () => { + const { signal, abortId } = getTimeoutSignal(1000); + + expect(signal).toBeDefined(); + expect(abortId).toBeDefined(); + expect(signal).toBeInstanceOf(AbortSignal); + expect(signal.aborted).toBe(false); + }); + + it("should create a signal that aborts after the specified timeout", () => { + const timeoutMs = 5000; + const { signal } = getTimeoutSignal(timeoutMs); + + expect(signal.aborted).toBe(false); + + jest.advanceTimersByTime(timeoutMs - 1); + expect(signal.aborted).toBe(false); + + jest.advanceTimersByTime(1); + expect(signal.aborted).toBe(true); + }); +}); + +describe("Test anySignal", () => { + it("should return an AbortSignal", () => { + const signal = anySignal(new AbortController().signal); + expect(signal).toBeInstanceOf(AbortSignal); + }); + + it("should abort when any of the input signals is aborted", () => { + const controller1 = new AbortController(); + const controller2 = new AbortController(); + const signal = anySignal(controller1.signal, controller2.signal); + + expect(signal.aborted).toBe(false); + controller1.abort(); + expect(signal.aborted).toBe(true); + }); + + it("should handle an array of signals", () => { + const controller1 = new AbortController(); + const controller2 = new AbortController(); + const signal = anySignal([controller1.signal, controller2.signal]); + + expect(signal.aborted).toBe(false); + controller2.abort(); + expect(signal.aborted).toBe(true); + }); + + it("should abort immediately if one of the input signals is already aborted", () => { + const controller1 = new AbortController(); + const controller2 = new AbortController(); + controller1.abort(); + + const signal = anySignal(controller1.signal, controller2.signal); + expect(signal.aborted).toBe(true); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts new file mode 100644 index 00000000000..1dc9be0cc0e --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts @@ -0,0 +1,178 @@ +import { Node18UniversalStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper"; + +describe("Node18UniversalStreamWrapper", () => { + it("should set encoding to utf-8", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const setEncodingSpy = jest.spyOn(stream, "setEncoding"); + + stream.setEncoding("utf-8"); + + expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); + }); + + it("should register an event listener for readable", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const onSpy = jest.spyOn(stream, "on"); + + stream.on("readable", () => {}); + + expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); + }); + + it("should remove an event listener for data", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const offSpy = jest.spyOn(stream, "off"); + + const fn = () => {}; + stream.on("data", fn); + stream.off("data", fn); + + expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); + }); + + it("should write to dest when calling pipe to writable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + const dest = new WritableStream({ + write(chunk) { + expect(chunk).toEqual(new TextEncoder().encode("test")); + }, + }); + + stream.pipe(dest); + }); + + it("should write to dest when calling pipe to node writable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + const dest = new (await import("readable-stream")).Writable({ + write(chunk, encoding, callback) { + expect(chunk.toString()).toEqual("test"); + callback(); + }, + }); + + stream.pipe(dest); + }); + + it("should write nothing when calling pipe and unpipe", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + const buffer: Uint8Array[] = []; + const dest = new WritableStream({ + write(chunk) { + buffer.push(chunk); + }, + }); + + stream.pipe(dest); + stream.unpipe(dest); + expect(buffer).toEqual([]); + }); + + it("should destroy the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const destroySpy = jest.spyOn(stream, "destroy"); + + stream.destroy(); + + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should pause and resume the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const pauseSpy = jest.spyOn(stream, "pause"); + const resumeSpy = jest.spyOn(stream, "resume"); + + expect(stream.isPaused).toBe(false); + stream.pause(); + expect(stream.isPaused).toBe(true); + stream.resume(); + + expect(pauseSpy).toHaveBeenCalled(); + expect(resumeSpy).toHaveBeenCalled(); + }); + + it("should read the stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + }); + + it("should read the stream as text", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + + const data = await stream.text(); + + expect(data).toEqual("testtest"); + }); + + it("should read the stream as json", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode(JSON.stringify({ test: "test" }))); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + + const data = await stream.json(); + + expect(data).toEqual({ test: "test" }); + }); + + it("should allow use with async iteratable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + let data = ""; + const stream = new Node18UniversalStreamWrapper(rawStream); + for await (const chunk of stream) { + data += new TextDecoder().decode(chunk); + } + + expect(data).toEqual("testtest"); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts new file mode 100644 index 00000000000..0c99d3b2655 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts @@ -0,0 +1,124 @@ +import { NodePre18StreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/NodePre18StreamWrapper"; + +describe("NodePre18StreamWrapper", () => { + it("should set encoding to utf-8", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const setEncodingSpy = jest.spyOn(stream, "setEncoding"); + + stream.setEncoding("utf-8"); + + expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); + }); + + it("should register an event listener for readable", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const onSpy = jest.spyOn(stream, "on"); + + stream.on("readable", () => {}); + + expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); + }); + + it("should remove an event listener for data", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const offSpy = jest.spyOn(stream, "off"); + + const fn = () => {}; + stream.on("data", fn); + stream.off("data", fn); + + expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); + }); + + it("should write to dest when calling pipe to node writable stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const dest = new (await import("readable-stream")).Writable({ + write(chunk, encoding, callback) { + expect(chunk.toString()).toEqual("test"); + callback(); + }, + }); + + stream.pipe(dest); + }); + + it("should write nothing when calling pipe and unpipe", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const buffer: Uint8Array[] = []; + const dest = new (await import("readable-stream")).Writable({ + write(chunk, encoding, callback) { + buffer.push(chunk); + callback(); + }, + }); + stream.pipe(dest); + stream.unpipe(); + + expect(buffer).toEqual([]); + }); + + it("should destroy the stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const destroySpy = jest.spyOn(stream, "destroy"); + + stream.destroy(); + + expect(destroySpy).toHaveBeenCalledWith(); + }); + + it("should pause the stream and resume", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const pauseSpy = jest.spyOn(stream, "pause"); + + stream.pause(); + expect(stream.isPaused).toBe(true); + stream.resume(); + expect(stream.isPaused).toBe(false); + + expect(pauseSpy).toHaveBeenCalledWith(); + }); + + it("should read the stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + + expect(await stream.read()).toEqual("test"); + expect(await stream.read()).toEqual("test"); + }); + + it("should read the stream as text", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + + const data = await stream.text(); + + expect(data).toEqual("testtest"); + }); + + it("should read the stream as json", async () => { + const rawStream = (await import("readable-stream")).Readable.from([JSON.stringify({ test: "test" })]); + const stream = new NodePre18StreamWrapper(rawStream); + + const data = await stream.json(); + + expect(data).toEqual({ test: "test" }); + }); + + it("should allow use with async iteratable stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + let data = ""; + const stream = new NodePre18StreamWrapper(rawStream); + for await (const chunk of stream) { + data += chunk; + } + + expect(data).toEqual("testtest"); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts new file mode 100644 index 00000000000..1d171ce6c67 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts @@ -0,0 +1,153 @@ +import { UndiciStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/UndiciStreamWrapper"; + +describe("UndiciStreamWrapper", () => { + it("should set encoding to utf-8", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const setEncodingSpy = jest.spyOn(stream, "setEncoding"); + + stream.setEncoding("utf-8"); + + expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); + }); + + it("should register an event listener for readable", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const onSpy = jest.spyOn(stream, "on"); + + stream.on("readable", () => {}); + + expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); + }); + + it("should remove an event listener for data", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const offSpy = jest.spyOn(stream, "off"); + + const fn = () => {}; + stream.on("data", fn); + stream.off("data", fn); + + expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); + }); + + it("should write to dest when calling pipe to writable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + const dest = new WritableStream({ + write(chunk) { + expect(chunk).toEqual(new TextEncoder().encode("test")); + }, + }); + + stream.pipe(dest); + }); + + it("should write nothing when calling pipe and unpipe", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const buffer: Uint8Array[] = []; + const dest = new WritableStream({ + write(chunk) { + buffer.push(chunk); + }, + }); + stream.pipe(dest); + stream.unpipe(dest); + + expect(buffer).toEqual([]); + }); + + it("should destroy the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const destroySpy = jest.spyOn(stream, "destroy"); + + stream.destroy(); + + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should pause and resume the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const pauseSpy = jest.spyOn(stream, "pause"); + const resumeSpy = jest.spyOn(stream, "resume"); + + expect(stream.isPaused).toBe(false); + stream.pause(); + expect(stream.isPaused).toBe(true); + stream.resume(); + + expect(pauseSpy).toHaveBeenCalled(); + expect(resumeSpy).toHaveBeenCalled(); + }); + + it("should read the stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + }); + + it("should read the stream as text", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + + const data = await stream.text(); + + expect(data).toEqual("testtest"); + }); + + it("should read the stream as json", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode(JSON.stringify({ test: "test" }))); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + + const data = await stream.json(); + + expect(data).toEqual({ test: "test" }); + }); + + it("should allow use with async iteratable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + let data = ""; + const stream = new UndiciStreamWrapper(rawStream); + for await (const chunk of stream) { + data += new TextDecoder().decode(chunk); + } + + expect(data).toEqual("testtest"); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts new file mode 100644 index 00000000000..17cf37a2f7f --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts @@ -0,0 +1,43 @@ +import { RUNTIME } from "../../../../src/core/runtime"; +import { chooseStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/chooseStreamWrapper"; +import { Node18UniversalStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper"; +import { NodePre18StreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/NodePre18StreamWrapper"; +import { UndiciStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/UndiciStreamWrapper"; + +describe("chooseStreamWrapper", () => { + beforeEach(() => { + RUNTIME.type = "unknown"; + RUNTIME.parsedVersion = 0; + }); + + it('should return a Node18UniversalStreamWrapper when RUNTIME.type is "node" and RUNTIME.parsedVersion is not null and RUNTIME.parsedVersion is greater than or equal to 18', async () => { + const expected = new Node18UniversalStreamWrapper(new ReadableStream()); + RUNTIME.type = "node"; + RUNTIME.parsedVersion = 18; + + const result = await chooseStreamWrapper(new ReadableStream()); + + expect(JSON.stringify(result)).toBe(JSON.stringify(expected)); + }); + + it('should return a NodePre18StreamWrapper when RUNTIME.type is "node" and RUNTIME.parsedVersion is not null and RUNTIME.parsedVersion is less than 18', async () => { + const stream = await import("readable-stream"); + const expected = new NodePre18StreamWrapper(new stream.Readable()); + + RUNTIME.type = "node"; + RUNTIME.parsedVersion = 16; + + const result = await chooseStreamWrapper(new stream.Readable()); + + expect(JSON.stringify(result)).toEqual(JSON.stringify(expected)); + }); + + it('should return a Undici when RUNTIME.type is not "node"', async () => { + const expected = new UndiciStreamWrapper(new ReadableStream()); + RUNTIME.type = "browser"; + + const result = await chooseStreamWrapper(new ReadableStream()); + + expect(JSON.stringify(result)).toEqual(JSON.stringify(expected)); + }); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/webpack.test.ts b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/webpack.test.ts new file mode 100644 index 00000000000..557db6dc4ef --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/stream-wrappers/webpack.test.ts @@ -0,0 +1,38 @@ +import webpack from "webpack"; + +describe("test env compatibility", () => { + test("webpack", () => { + return new Promise((resolve, reject) => { + webpack( + { + mode: "production", + entry: "./src/index.ts", + module: { + rules: [ + { + test: /\.tsx?$/, + use: "ts-loader", + exclude: /node_modules/, + }, + ], + }, + resolve: { + extensions: [".tsx", ".ts", ".js"], + }, + }, + (err, stats) => { + try { + expect(err).toBe(null); + if (stats?.hasErrors()) { + console.log(stats?.toString()); + } + expect(stats?.hasErrors()).toBe(false); + resolve(); + } catch (error) { + reject(error); + } + } + ); + }); + }, 60_000); +}); diff --git a/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/test-file.txt b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/test-file.txt new file mode 100644 index 00000000000..c66d471e359 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tests/unit/fetcher/test-file.txt @@ -0,0 +1 @@ +This is a test file! diff --git a/seed/ts-sdk/inline-types/inline/tsconfig.json b/seed/ts-sdk/inline-types/inline/tsconfig.json new file mode 100644 index 00000000000..538c94fe015 --- /dev/null +++ b/seed/ts-sdk/inline-types/inline/tsconfig.json @@ -0,0 +1,17 @@ +{ + "compilerOptions": { + "extendedDiagnostics": true, + "strict": true, + "target": "ES6", + "module": "CommonJS", + "moduleResolution": "node", + "esModuleInterop": true, + "skipLibCheck": true, + "declaration": true, + "outDir": "dist", + "rootDir": "src", + "baseUrl": "src" + }, + "include": ["src"], + "exclude": [] +} diff --git a/seed/ts-sdk/inline-types/no-inline/.github/workflows/ci.yml b/seed/ts-sdk/inline-types/no-inline/.github/workflows/ci.yml new file mode 100644 index 00000000000..b64a6cbbb4a --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/.github/workflows/ci.yml @@ -0,0 +1,57 @@ +name: ci + +on: [push] + +jobs: + compile: + runs-on: ubuntu-latest + + steps: + - name: Checkout repo + uses: actions/checkout@v3 + + - name: Set up node + uses: actions/setup-node@v3 + + - name: Compile + run: yarn && yarn build + + test: + runs-on: ubuntu-latest + + steps: + - name: Checkout repo + uses: actions/checkout@v3 + + - name: Set up node + uses: actions/setup-node@v3 + + - name: Compile + run: yarn && yarn test + + publish: + needs: [ compile, test ] + if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v3 + - name: Set up node + uses: actions/setup-node@v3 + - name: Install dependencies + run: yarn install + - name: Build + run: yarn build + + - name: Publish to npm + run: | + npm config set //registry.npmjs.org/:_authToken ${NPM_TOKEN} + if [[ ${GITHUB_REF} == *alpha* ]]; then + npm publish --access public --tag alpha + elif [[ ${GITHUB_REF} == *beta* ]]; then + npm publish --access public --tag beta + else + npm publish --access public + fi + env: + NPM_TOKEN: ${{ secrets. }} \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/no-inline/.gitignore b/seed/ts-sdk/inline-types/no-inline/.gitignore new file mode 100644 index 00000000000..72271e049c0 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/.gitignore @@ -0,0 +1,3 @@ +node_modules +.DS_Store +/dist \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/no-inline/.mock/definition/__package__.yml b/seed/ts-sdk/inline-types/no-inline/.mock/definition/__package__.yml new file mode 100644 index 00000000000..af14bf356cd --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/.mock/definition/__package__.yml @@ -0,0 +1,365 @@ +service: + base-path: /root + auth: false + endpoints: + getRoot: + path: /root + method: POST + request: + body: + properties: + bar: RequestTypeInlineType1 + foo: string + content-type: application/json + name: PostRootRequest + response: RootType1 + getDiscriminatedUnion: + path: /discriminated-union + method: POST + request: + body: + properties: + bar: DiscriminatedUnion1 + foo: string + content-type: application/json + name: GetDiscriminatedUnionRequest + getUndiscriminatedUnion: + path: /undiscriminated-union + method: POST + request: + body: + properties: + bar: UndiscriminatedUnion1 + foo: string + content-type: application/json + name: GetUndiscriminatedUnionRequest + +types: + # this is also the type that would be produced by + AliasMapInline: map + AliasSetInline: set + AliasListInline: list + + AliasInlineValue: + inline: true + properties: + foo: string + bar: string + + RequestTypeInlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + + RootType1: + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: RootType1InlineType1 + docs: lorem ipsum + fooMap: + type: map + docs: lorem ipsum + fooList: + type: list + docs: lorem ipsum + fooSet: + type: set + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1FooMapValue: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1FooListItem: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1FooSetItem: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: RootType1InlineType1NestedInlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1InlineType1NestedInlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: string + docs: lorem ipsum + myEnum: + type: InlineEnum1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1: + inline: true + docs: lorem ipsum + union: + type1: + type: DiscriminatedUnion1InlineType1 + docs: lorem ipsum + type2: + type: DiscriminatedUnion1InlineType2 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: DiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1: + inline: true + docs: lorem ipsum + discriminated: false + union: + - type: UndiscriminatedUnion1InlineType1 + docs: lorem ipsum + - type: UndiscriminatedUnion1InlineType2 + docs: lorem ipsum + - type: UndiscriminatedUnion1DiscriminatedUnion1 + docs: lorem ipsum + - type: UndiscriminatedUnion1DiscriminatedUnion1 + docs: lorem ipsum + - type: UndiscriminatedUnion1InlineEnum1 + docs: lorem ipsum + - type: UserId + docs: lorem ipsum + - type: list + docs: lorem ipsum + - type: set + docs: lorem ipsum + - type: map + docs: lorem ipsum + - type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: UndiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + InlineEnum1: + inline: true + docs: lorem ipsum + enum: + - SUNNY + - CLOUDY + - RAINING + - SNOWING + + UndiscriminatedUnion1DiscriminatedUnion1: + inline: true + docs: lorem ipsum + union: + type1: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType1 + docs: lorem ipsum + type2: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType2 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineEnum1: + inline: true + docs: lorem ipsum + enum: + - SUNNY + - CLOUDY + - RAINING + - SNOWING + + UserId: + type: string + docs: lorem ipsum + + UndiscriminatedUnion1InlineListItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineSetItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineMapItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + ReferenceType: + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum diff --git a/seed/ts-sdk/inline-types/no-inline/.mock/definition/api.yml b/seed/ts-sdk/inline-types/no-inline/.mock/definition/api.yml new file mode 100644 index 00000000000..a82930c145b --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/.mock/definition/api.yml @@ -0,0 +1 @@ +name: object diff --git a/seed/ts-sdk/inline-types/no-inline/.mock/fern.config.json b/seed/ts-sdk/inline-types/no-inline/.mock/fern.config.json new file mode 100644 index 00000000000..4c8e54ac313 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/.mock/fern.config.json @@ -0,0 +1 @@ +{"organization": "fern-test", "version": "*"} \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/no-inline/.mock/generators.yml b/seed/ts-sdk/inline-types/no-inline/.mock/generators.yml new file mode 100644 index 00000000000..0967ef424bc --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/.mock/generators.yml @@ -0,0 +1 @@ +{} diff --git a/seed/ts-sdk/inline-types/no-inline/.mock/ir.json b/seed/ts-sdk/inline-types/no-inline/.mock/ir.json new file mode 100644 index 00000000000..00d22b232be --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/.mock/ir.json @@ -0,0 +1,4159 @@ +{ + "fdrApiDefinitionId": null, + "apiVersion": null, + "apiName": { + "originalName": "object", + "camelCase": { + "unsafeName": "object", + "safeName": "object" + }, + "snakeCase": { + "unsafeName": "object", + "safeName": "object" + }, + "screamingSnakeCase": { + "unsafeName": "OBJECT", + "safeName": "OBJECT" + }, + "pascalCase": { + "unsafeName": "Object", + "safeName": "Object" + } + }, + "apiDisplayName": null, + "apiDocs": null, + "auth": { + "requirement": "ALL", + "schemes": [], + "docs": null + }, + "headers": [], + "idempotencyHeaders": [], + "types": { + "type_:RequestTypeInlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:RootType1": { + "inline": null, + "name": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [ + "type_:RootType1InlineType1", + "type_:RootType1InlineType1NestedInlineType1", + "type_:InlineEnum" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:RootType1InlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [ + "type_:RootType1InlineType1NestedInlineType1", + "type_:InlineEnum" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:RootType1InlineType1NestedInlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "myEnum", + "camelCase": { + "unsafeName": "myEnum", + "safeName": "myEnum" + }, + "snakeCase": { + "unsafeName": "my_enum", + "safeName": "my_enum" + }, + "screamingSnakeCase": { + "unsafeName": "MY_ENUM", + "safeName": "MY_ENUM" + }, + "pascalCase": { + "unsafeName": "MyEnum", + "safeName": "MyEnum" + } + }, + "wireValue": "myEnum" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:InlineEnum", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [ + "type_:InlineEnum" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:DiscriminatedUnion1": { + "inline": true, + "name": { + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1" + }, + "shape": { + "_type": "union", + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "extends": [], + "baseProperties": [], + "types": [ + { + "discriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type_1", + "safeName": "type_1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_1", + "safeName": "TYPE_1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "shape": { + "_type": "samePropertiesAsObject", + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType1" + }, + "displayName": null, + "availability": null, + "docs": null + }, + { + "discriminantValue": { + "name": { + "originalName": "type2", + "camelCase": { + "unsafeName": "type2", + "safeName": "type2" + }, + "snakeCase": { + "unsafeName": "type_2", + "safeName": "type_2" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_2", + "safeName": "TYPE_2" + }, + "pascalCase": { + "unsafeName": "Type2", + "safeName": "Type2" + } + }, + "wireValue": "type2" + }, + "shape": { + "_type": "samePropertiesAsObject", + "name": { + "originalName": "DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType2", + "safeName": "discriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_2", + "safeName": "discriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType2", + "safeName": "DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType2" + }, + "displayName": null, + "availability": null, + "docs": null + } + ] + }, + "referencedTypes": [ + "type_:DiscriminatedUnion1InlineType1", + "type_:DiscriminatedUnion1InlineType2" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:DiscriminatedUnion1InlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:DiscriminatedUnion1InlineType2": { + "inline": true, + "name": { + "name": { + "originalName": "DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType2", + "safeName": "discriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_2", + "safeName": "discriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType2", + "safeName": "DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType2" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:UndiscriminatedUnion1": { + "inline": true, + "name": { + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1" + }, + "shape": { + "_type": "undiscriminatedUnion", + "members": [ + { + "type": { + "_type": "named", + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1", + "default": null, + "inline": null + }, + "docs": null + }, + { + "type": { + "_type": "named", + "name": { + "originalName": "UndiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_2", + "safeName": "undiscriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType2", + "default": null, + "inline": null + }, + "docs": null + } + ] + }, + "referencedTypes": [ + "type_:UndiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1InlineType2" + ], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:UndiscriminatedUnion1InlineType1": { + "inline": true, + "name": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:UndiscriminatedUnion1InlineType2": { + "inline": true, + "name": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_2", + "safeName": "undiscriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType2" + }, + "shape": { + "_type": "object", + "extends": [], + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + }, + "type_:InlineEnum": { + "inline": true, + "name": { + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:InlineEnum" + }, + "shape": { + "_type": "enum", + "default": null, + "values": [ + { + "name": { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "CLOUDY", + "camelCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "snakeCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "screamingSnakeCase": { + "unsafeName": "CLOUDY", + "safeName": "CLOUDY" + }, + "pascalCase": { + "unsafeName": "Cloudy", + "safeName": "Cloudy" + } + }, + "wireValue": "CLOUDY" + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "RAINING", + "camelCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "snakeCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "screamingSnakeCase": { + "unsafeName": "RAINING", + "safeName": "RAINING" + }, + "pascalCase": { + "unsafeName": "Raining", + "safeName": "Raining" + } + }, + "wireValue": "RAINING" + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "SNOWING", + "camelCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "snakeCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "screamingSnakeCase": { + "unsafeName": "SNOWING", + "safeName": "SNOWING" + }, + "pascalCase": { + "unsafeName": "Snowing", + "safeName": "Snowing" + } + }, + "wireValue": "SNOWING" + }, + "availability": null, + "docs": null + } + ] + }, + "referencedTypes": [], + "encoding": { + "json": {}, + "proto": null + }, + "source": null, + "userProvidedExamples": [], + "autogeneratedExamples": [], + "availability": null, + "docs": null + } + }, + "errors": {}, + "services": { + "service_": { + "availability": null, + "name": { + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "displayName": null, + "basePath": { + "head": "/root", + "parts": [] + }, + "headers": [], + "pathParameters": [], + "encoding": { + "json": {}, + "proto": null + }, + "transport": { + "type": "http" + }, + "endpoints": [ + { + "id": "endpoint_.getRoot", + "name": { + "originalName": "getRoot", + "camelCase": { + "unsafeName": "getRoot", + "safeName": "getRoot" + }, + "snakeCase": { + "unsafeName": "get_root", + "safeName": "get_root" + }, + "screamingSnakeCase": { + "unsafeName": "GET_ROOT", + "safeName": "GET_ROOT" + }, + "pascalCase": { + "unsafeName": "GetRoot", + "safeName": "GetRoot" + } + }, + "displayName": null, + "auth": false, + "idempotent": false, + "baseUrl": null, + "method": "POST", + "basePath": null, + "path": { + "head": "/root", + "parts": [] + }, + "fullPath": { + "head": "/root/root", + "parts": [] + }, + "pathParameters": [], + "allPathParameters": [], + "queryParameters": [], + "headers": [], + "requestBody": { + "type": "inlinedRequestBody", + "name": { + "originalName": "PostRootRequest", + "camelCase": { + "unsafeName": "postRootRequest", + "safeName": "postRootRequest" + }, + "snakeCase": { + "unsafeName": "post_root_request", + "safeName": "post_root_request" + }, + "screamingSnakeCase": { + "unsafeName": "POST_ROOT_REQUEST", + "safeName": "POST_ROOT_REQUEST" + }, + "pascalCase": { + "unsafeName": "PostRootRequest", + "safeName": "PostRootRequest" + } + }, + "extends": [], + "contentType": "application/json", + "properties": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "valueType": { + "_type": "named", + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1", + "default": null, + "inline": null + }, + "availability": null, + "docs": null + }, + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "valueType": { + "_type": "primitive", + "primitive": { + "v1": "STRING", + "v2": { + "type": "string", + "default": null, + "validation": null + } + } + }, + "availability": null, + "docs": null + } + ], + "extra-properties": false, + "extendedProperties": [], + "docs": null + }, + "sdkRequest": { + "shape": { + "type": "wrapper", + "wrapperName": { + "originalName": "PostRootRequest", + "camelCase": { + "unsafeName": "postRootRequest", + "safeName": "postRootRequest" + }, + "snakeCase": { + "unsafeName": "post_root_request", + "safeName": "post_root_request" + }, + "screamingSnakeCase": { + "unsafeName": "POST_ROOT_REQUEST", + "safeName": "POST_ROOT_REQUEST" + }, + "pascalCase": { + "unsafeName": "PostRootRequest", + "safeName": "PostRootRequest" + } + }, + "bodyKey": { + "originalName": "body", + "camelCase": { + "unsafeName": "body", + "safeName": "body" + }, + "snakeCase": { + "unsafeName": "body", + "safeName": "body" + }, + "screamingSnakeCase": { + "unsafeName": "BODY", + "safeName": "BODY" + }, + "pascalCase": { + "unsafeName": "Body", + "safeName": "Body" + } + }, + "includePathParameters": false, + "onlyPathParameters": false + }, + "requestParameterName": { + "originalName": "request", + "camelCase": { + "unsafeName": "request", + "safeName": "request" + }, + "snakeCase": { + "unsafeName": "request", + "safeName": "request" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST", + "safeName": "REQUEST" + }, + "pascalCase": { + "unsafeName": "Request", + "safeName": "Request" + } + }, + "streamParameter": null + }, + "response": { + "body": { + "type": "json", + "value": { + "type": "response", + "responseBodyType": { + "_type": "named", + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1", + "default": null, + "inline": null + }, + "docs": null + } + }, + "status-code": null + }, + "errors": [], + "userSpecifiedExamples": [], + "autogeneratedExamples": [ + { + "example": { + "id": "cc979ed415b4638d8e170df64556fbd1154268c5", + "url": "/root/root", + "name": null, + "endpointHeaders": [], + "endpointPathParameters": [], + "queryParameters": [], + "servicePathParameters": [], + "serviceHeaders": [], + "rootPathParameters": [], + "request": { + "type": "inlinedRequestBody", + "properties": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": null, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RequestTypeInlineType1" + } + }, + "jsonExample": { + "foo": "foo" + } + } + }, + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": null, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ], + "jsonExample": { + "bar": { + "foo": "foo" + }, + "foo": "foo" + } + }, + "response": { + "type": "ok", + "value": { + "type": "body", + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + }, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + }, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "bar" + } + } + }, + "jsonExample": "bar" + } + }, + { + "name": { + "name": { + "originalName": "myEnum", + "camelCase": { + "unsafeName": "myEnum", + "safeName": "myEnum" + }, + "snakeCase": { + "unsafeName": "my_enum", + "safeName": "my_enum" + }, + "screamingSnakeCase": { + "unsafeName": "MY_ENUM", + "safeName": "MY_ENUM" + }, + "pascalCase": { + "unsafeName": "MyEnum", + "safeName": "MyEnum" + } + }, + "wireValue": "myEnum" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + }, + "value": { + "shape": { + "type": "named", + "shape": { + "type": "enum", + "value": { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + } + }, + "typeName": { + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:InlineEnum" + } + }, + "jsonExample": "SUNNY" + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1NestedInlineType1" + } + }, + "jsonExample": { + "foo": "foo", + "bar": "bar", + "myEnum": "SUNNY" + } + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1InlineType1" + } + }, + "jsonExample": { + "foo": "foo", + "bar": { + "foo": "foo", + "bar": "bar", + "myEnum": "SUNNY" + } + } + } + } + ] + }, + "typeName": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:RootType1" + } + }, + "jsonExample": { + "foo": "foo", + "bar": { + "foo": "foo", + "bar": { + "foo": "foo", + "bar": "bar", + "myEnum": "SUNNY" + } + } + } + } + } + }, + "docs": null + } + } + ], + "pagination": null, + "transport": null, + "availability": null, + "docs": null + }, + { + "id": "endpoint_.getDiscriminatedUnion", + "name": { + "originalName": "getDiscriminatedUnion", + "camelCase": { + "unsafeName": "getDiscriminatedUnion", + "safeName": "getDiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_discriminated_union", + "safeName": "get_discriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_DISCRIMINATED_UNION", + "safeName": "GET_DISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetDiscriminatedUnion", + "safeName": "GetDiscriminatedUnion" + } + }, + "displayName": null, + "auth": false, + "idempotent": false, + "baseUrl": null, + "method": "GET", + "basePath": null, + "path": { + "head": "/discriminated-union", + "parts": [] + }, + "fullPath": { + "head": "/root/discriminated-union", + "parts": [] + }, + "pathParameters": [], + "allPathParameters": [], + "queryParameters": [], + "headers": [], + "requestBody": null, + "sdkRequest": null, + "response": { + "body": { + "type": "json", + "value": { + "type": "response", + "responseBodyType": { + "_type": "named", + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1", + "default": null, + "inline": null + }, + "docs": null + } + }, + "status-code": null + }, + "errors": [], + "userSpecifiedExamples": [], + "autogeneratedExamples": [ + { + "example": { + "id": "66b0f09d479437029bc19bcd824ec0242f8f71e8", + "url": "/root/discriminated-union", + "name": null, + "endpointHeaders": [], + "endpointPathParameters": [], + "queryParameters": [], + "servicePathParameters": [], + "serviceHeaders": [], + "rootPathParameters": [], + "request": null, + "response": { + "type": "ok", + "value": { + "type": "body", + "value": { + "shape": { + "type": "named", + "shape": { + "type": "union", + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "singleUnionType": { + "wireDiscriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type_1", + "safeName": "type_1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_1", + "safeName": "TYPE_1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "shape": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType1", + "object": { + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1InlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ] + } + } + } + }, + "typeName": { + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:DiscriminatedUnion1" + } + }, + "jsonExample": { + "type": "type1", + "foo": "foo" + } + } + } + }, + "docs": null + } + } + ], + "pagination": null, + "transport": null, + "availability": null, + "docs": null + }, + { + "id": "endpoint_.getUndiscriminatedUnion", + "name": { + "originalName": "getUndiscriminatedUnion", + "camelCase": { + "unsafeName": "getUndiscriminatedUnion", + "safeName": "getUndiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_undiscriminated_union", + "safeName": "get_undiscriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_UNDISCRIMINATED_UNION", + "safeName": "GET_UNDISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetUndiscriminatedUnion", + "safeName": "GetUndiscriminatedUnion" + } + }, + "displayName": null, + "auth": false, + "idempotent": false, + "baseUrl": null, + "method": "GET", + "basePath": null, + "path": { + "head": "/undiscriminated-union", + "parts": [] + }, + "fullPath": { + "head": "/root/undiscriminated-union", + "parts": [] + }, + "pathParameters": [], + "allPathParameters": [], + "queryParameters": [], + "headers": [], + "requestBody": null, + "sdkRequest": null, + "response": { + "body": { + "type": "json", + "value": { + "type": "response", + "responseBodyType": { + "_type": "named", + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1", + "default": null, + "inline": null + }, + "docs": null + } + }, + "status-code": null + }, + "errors": [], + "userSpecifiedExamples": [], + "autogeneratedExamples": [ + { + "example": { + "id": "4e32aff3299d7769cc9e184747382c076b82c724", + "url": "/root/undiscriminated-union", + "name": null, + "endpointHeaders": [], + "endpointPathParameters": [], + "queryParameters": [], + "servicePathParameters": [], + "serviceHeaders": [], + "rootPathParameters": [], + "request": null, + "response": { + "type": "ok", + "value": { + "type": "body", + "value": { + "shape": { + "type": "named", + "shape": { + "type": "undiscriminatedUnion", + "index": 0, + "singleUnionType": { + "shape": { + "type": "named", + "shape": { + "type": "object", + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "originalTypeDeclaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1" + }, + "value": { + "shape": { + "type": "primitive", + "primitive": { + "type": "string", + "string": { + "original": "foo" + } + } + }, + "jsonExample": "foo" + } + } + ] + }, + "typeName": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1InlineType1" + } + }, + "jsonExample": { + "foo": "foo" + } + } + }, + "typeName": { + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "typeId": "type_:UndiscriminatedUnion1" + } + }, + "jsonExample": { + "foo": "foo" + } + } + } + }, + "docs": null + } + } + ], + "pagination": null, + "transport": null, + "availability": null, + "docs": null + } + ] + } + }, + "constants": { + "errorInstanceIdKey": { + "name": { + "originalName": "errorInstanceId", + "camelCase": { + "unsafeName": "errorInstanceId", + "safeName": "errorInstanceId" + }, + "snakeCase": { + "unsafeName": "error_instance_id", + "safeName": "error_instance_id" + }, + "screamingSnakeCase": { + "unsafeName": "ERROR_INSTANCE_ID", + "safeName": "ERROR_INSTANCE_ID" + }, + "pascalCase": { + "unsafeName": "ErrorInstanceId", + "safeName": "ErrorInstanceId" + } + }, + "wireValue": "errorInstanceId" + } + }, + "environments": null, + "errorDiscriminationStrategy": { + "type": "statusCode" + }, + "basePath": null, + "pathParameters": [], + "variables": [], + "serviceTypeReferenceInfo": { + "typesReferencedOnlyByService": { + "service_": [ + "type_:RequestTypeInlineType1", + "type_:RootType1", + "type_:RootType1InlineType1", + "type_:RootType1InlineType1NestedInlineType1", + "type_:DiscriminatedUnion1", + "type_:DiscriminatedUnion1InlineType1", + "type_:DiscriminatedUnion1InlineType2", + "type_:UndiscriminatedUnion1", + "type_:UndiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1InlineType2", + "type_:InlineEnum" + ] + }, + "sharedTypes": [] + }, + "webhookGroups": {}, + "websocketChannels": {}, + "readmeConfig": null, + "sourceConfig": null, + "publishConfig": null, + "dynamic": { + "version": "1.0.0", + "types": { + "type_:RequestTypeInlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RequestTypeInlineType1", + "camelCase": { + "unsafeName": "requestTypeInlineType1", + "safeName": "requestTypeInlineType1" + }, + "snakeCase": { + "unsafeName": "request_type_inline_type_1", + "safeName": "request_type_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "REQUEST_TYPE_INLINE_TYPE_1", + "safeName": "REQUEST_TYPE_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RequestTypeInlineType1", + "safeName": "RequestTypeInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:RootType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1", + "camelCase": { + "unsafeName": "rootType1", + "safeName": "rootType1" + }, + "snakeCase": { + "unsafeName": "root_type_1", + "safeName": "root_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1", + "safeName": "ROOT_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1", + "safeName": "RootType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "named", + "value": "type_:RootType1InlineType1" + } + } + ] + }, + "type_:RootType1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1InlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1", + "safeName": "rootType1InlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1", + "safeName": "root_type_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1", + "safeName": "RootType1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "named", + "value": "type_:RootType1InlineType1NestedInlineType1" + } + } + ] + }, + "type_:RootType1InlineType1NestedInlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "RootType1InlineType1NestedInlineType1", + "camelCase": { + "unsafeName": "rootType1InlineType1NestedInlineType1", + "safeName": "rootType1InlineType1NestedInlineType1" + }, + "snakeCase": { + "unsafeName": "root_type_1_inline_type_1_nested_inline_type_1", + "safeName": "root_type_1_inline_type_1_nested_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1", + "safeName": "ROOT_TYPE_1_INLINE_TYPE_1_NESTED_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "RootType1InlineType1NestedInlineType1", + "safeName": "RootType1InlineType1NestedInlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + }, + { + "name": { + "name": { + "originalName": "myEnum", + "camelCase": { + "unsafeName": "myEnum", + "safeName": "myEnum" + }, + "snakeCase": { + "unsafeName": "my_enum", + "safeName": "my_enum" + }, + "screamingSnakeCase": { + "unsafeName": "MY_ENUM", + "safeName": "MY_ENUM" + }, + "pascalCase": { + "unsafeName": "MyEnum", + "safeName": "MyEnum" + } + }, + "wireValue": "myEnum" + }, + "typeReference": { + "_type": "named", + "value": "type_:InlineEnum" + } + } + ] + }, + "type_:DiscriminatedUnion1": { + "type": "discriminatedUnion", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1", + "camelCase": { + "unsafeName": "discriminatedUnion1", + "safeName": "discriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1", + "safeName": "discriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1", + "safeName": "DISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1", + "safeName": "DiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "discriminant": { + "name": { + "originalName": "type", + "camelCase": { + "unsafeName": "type", + "safeName": "type" + }, + "snakeCase": { + "unsafeName": "type", + "safeName": "type" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE", + "safeName": "TYPE" + }, + "pascalCase": { + "unsafeName": "Type", + "safeName": "Type" + } + }, + "wireValue": "type" + }, + "types": { + "type1": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType1", + "discriminantValue": { + "name": { + "originalName": "type1", + "camelCase": { + "unsafeName": "type1", + "safeName": "type1" + }, + "snakeCase": { + "unsafeName": "type_1", + "safeName": "type_1" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_1", + "safeName": "TYPE_1" + }, + "pascalCase": { + "unsafeName": "Type1", + "safeName": "Type1" + } + }, + "wireValue": "type1" + }, + "properties": [] + }, + "type2": { + "type": "samePropertiesAsObject", + "typeId": "type_:DiscriminatedUnion1InlineType2", + "discriminantValue": { + "name": { + "originalName": "type2", + "camelCase": { + "unsafeName": "type2", + "safeName": "type2" + }, + "snakeCase": { + "unsafeName": "type_2", + "safeName": "type_2" + }, + "screamingSnakeCase": { + "unsafeName": "TYPE_2", + "safeName": "TYPE_2" + }, + "pascalCase": { + "unsafeName": "Type2", + "safeName": "Type2" + } + }, + "wireValue": "type2" + }, + "properties": [] + } + } + }, + "type_:DiscriminatedUnion1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType1", + "safeName": "discriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_1", + "safeName": "discriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType1", + "safeName": "DiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:DiscriminatedUnion1InlineType2": { + "type": "object", + "declaration": { + "name": { + "originalName": "DiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "discriminatedUnion1InlineType2", + "safeName": "discriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "discriminated_union_1_inline_type_2", + "safeName": "discriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "DISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "DiscriminatedUnion1InlineType2", + "safeName": "DiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:UndiscriminatedUnion1": { + "type": "undiscriminatedUnion", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1", + "safeName": "undiscriminatedUnion1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1", + "safeName": "undiscriminated_union_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1", + "safeName": "UNDISCRIMINATED_UNION_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1", + "safeName": "UndiscriminatedUnion1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "types": [ + { + "_type": "named", + "value": "type_:UndiscriminatedUnion1InlineType1" + }, + { + "_type": "named", + "value": "type_:UndiscriminatedUnion1InlineType2" + } + ] + }, + "type_:UndiscriminatedUnion1InlineType1": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType1", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType1", + "safeName": "undiscriminatedUnion1InlineType1" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_1", + "safeName": "undiscriminated_union_1_inline_type_1" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_1" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType1", + "safeName": "UndiscriminatedUnion1InlineType1" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:UndiscriminatedUnion1InlineType2": { + "type": "object", + "declaration": { + "name": { + "originalName": "UndiscriminatedUnion1InlineType2", + "camelCase": { + "unsafeName": "undiscriminatedUnion1InlineType2", + "safeName": "undiscriminatedUnion1InlineType2" + }, + "snakeCase": { + "unsafeName": "undiscriminated_union_1_inline_type_2", + "safeName": "undiscriminated_union_1_inline_type_2" + }, + "screamingSnakeCase": { + "unsafeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2", + "safeName": "UNDISCRIMINATED_UNION_1_INLINE_TYPE_2" + }, + "pascalCase": { + "unsafeName": "UndiscriminatedUnion1InlineType2", + "safeName": "UndiscriminatedUnion1InlineType2" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "properties": [ + { + "name": { + "name": { + "originalName": "baz", + "camelCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "snakeCase": { + "unsafeName": "baz", + "safeName": "baz" + }, + "screamingSnakeCase": { + "unsafeName": "BAZ", + "safeName": "BAZ" + }, + "pascalCase": { + "unsafeName": "Baz", + "safeName": "Baz" + } + }, + "wireValue": "baz" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "type_:InlineEnum": { + "type": "enum", + "declaration": { + "name": { + "originalName": "InlineEnum", + "camelCase": { + "unsafeName": "inlineEnum", + "safeName": "inlineEnum" + }, + "snakeCase": { + "unsafeName": "inline_enum", + "safeName": "inline_enum" + }, + "screamingSnakeCase": { + "unsafeName": "INLINE_ENUM", + "safeName": "INLINE_ENUM" + }, + "pascalCase": { + "unsafeName": "InlineEnum", + "safeName": "InlineEnum" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "values": [ + { + "name": { + "originalName": "SUNNY", + "camelCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "snakeCase": { + "unsafeName": "sunny", + "safeName": "sunny" + }, + "screamingSnakeCase": { + "unsafeName": "SUNNY", + "safeName": "SUNNY" + }, + "pascalCase": { + "unsafeName": "Sunny", + "safeName": "Sunny" + } + }, + "wireValue": "SUNNY" + }, + { + "name": { + "originalName": "CLOUDY", + "camelCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "snakeCase": { + "unsafeName": "cloudy", + "safeName": "cloudy" + }, + "screamingSnakeCase": { + "unsafeName": "CLOUDY", + "safeName": "CLOUDY" + }, + "pascalCase": { + "unsafeName": "Cloudy", + "safeName": "Cloudy" + } + }, + "wireValue": "CLOUDY" + }, + { + "name": { + "originalName": "RAINING", + "camelCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "snakeCase": { + "unsafeName": "raining", + "safeName": "raining" + }, + "screamingSnakeCase": { + "unsafeName": "RAINING", + "safeName": "RAINING" + }, + "pascalCase": { + "unsafeName": "Raining", + "safeName": "Raining" + } + }, + "wireValue": "RAINING" + }, + { + "name": { + "originalName": "SNOWING", + "camelCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "snakeCase": { + "unsafeName": "snowing", + "safeName": "snowing" + }, + "screamingSnakeCase": { + "unsafeName": "SNOWING", + "safeName": "SNOWING" + }, + "pascalCase": { + "unsafeName": "Snowing", + "safeName": "Snowing" + } + }, + "wireValue": "SNOWING" + } + ] + } + }, + "headers": [], + "endpoints": { + "endpoint_.getRoot": { + "auth": null, + "declaration": { + "name": { + "originalName": "getRoot", + "camelCase": { + "unsafeName": "getRoot", + "safeName": "getRoot" + }, + "snakeCase": { + "unsafeName": "get_root", + "safeName": "get_root" + }, + "screamingSnakeCase": { + "unsafeName": "GET_ROOT", + "safeName": "GET_ROOT" + }, + "pascalCase": { + "unsafeName": "GetRoot", + "safeName": "GetRoot" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "location": { + "method": "POST", + "path": "/root/root" + }, + "request": { + "type": "inlined", + "declaration": { + "name": { + "originalName": "PostRootRequest", + "camelCase": { + "unsafeName": "postRootRequest", + "safeName": "postRootRequest" + }, + "snakeCase": { + "unsafeName": "post_root_request", + "safeName": "post_root_request" + }, + "screamingSnakeCase": { + "unsafeName": "POST_ROOT_REQUEST", + "safeName": "POST_ROOT_REQUEST" + }, + "pascalCase": { + "unsafeName": "PostRootRequest", + "safeName": "PostRootRequest" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "pathParameters": [], + "queryParameters": [], + "headers": [], + "body": { + "type": "properties", + "value": [ + { + "name": { + "name": { + "originalName": "bar", + "camelCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "snakeCase": { + "unsafeName": "bar", + "safeName": "bar" + }, + "screamingSnakeCase": { + "unsafeName": "BAR", + "safeName": "BAR" + }, + "pascalCase": { + "unsafeName": "Bar", + "safeName": "Bar" + } + }, + "wireValue": "bar" + }, + "typeReference": { + "_type": "named", + "value": "type_:RequestTypeInlineType1" + } + }, + { + "name": { + "name": { + "originalName": "foo", + "camelCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "snakeCase": { + "unsafeName": "foo", + "safeName": "foo" + }, + "screamingSnakeCase": { + "unsafeName": "FOO", + "safeName": "FOO" + }, + "pascalCase": { + "unsafeName": "Foo", + "safeName": "Foo" + } + }, + "wireValue": "foo" + }, + "typeReference": { + "_type": "primitive", + "value": "STRING" + } + } + ] + }, + "metadata": { + "includePathParameters": false, + "onlyPathParameters": false + } + }, + "response": { + "type": "json" + } + }, + "endpoint_.getDiscriminatedUnion": { + "auth": null, + "declaration": { + "name": { + "originalName": "getDiscriminatedUnion", + "camelCase": { + "unsafeName": "getDiscriminatedUnion", + "safeName": "getDiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_discriminated_union", + "safeName": "get_discriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_DISCRIMINATED_UNION", + "safeName": "GET_DISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetDiscriminatedUnion", + "safeName": "GetDiscriminatedUnion" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "location": { + "method": "GET", + "path": "/root/discriminated-union" + }, + "request": { + "type": "body", + "pathParameters": [], + "body": null + }, + "response": { + "type": "json" + } + }, + "endpoint_.getUndiscriminatedUnion": { + "auth": null, + "declaration": { + "name": { + "originalName": "getUndiscriminatedUnion", + "camelCase": { + "unsafeName": "getUndiscriminatedUnion", + "safeName": "getUndiscriminatedUnion" + }, + "snakeCase": { + "unsafeName": "get_undiscriminated_union", + "safeName": "get_undiscriminated_union" + }, + "screamingSnakeCase": { + "unsafeName": "GET_UNDISCRIMINATED_UNION", + "safeName": "GET_UNDISCRIMINATED_UNION" + }, + "pascalCase": { + "unsafeName": "GetUndiscriminatedUnion", + "safeName": "GetUndiscriminatedUnion" + } + }, + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + } + }, + "location": { + "method": "GET", + "path": "/root/undiscriminated-union" + }, + "request": { + "type": "body", + "pathParameters": [], + "body": null + }, + "response": { + "type": "json" + } + } + } + }, + "subpackages": {}, + "rootPackage": { + "fernFilepath": { + "allParts": [], + "packagePath": [], + "file": null + }, + "websocket": null, + "service": "service_", + "types": [ + "type_:RequestTypeInlineType1", + "type_:RootType1", + "type_:RootType1InlineType1", + "type_:RootType1InlineType1NestedInlineType1", + "type_:DiscriminatedUnion1", + "type_:DiscriminatedUnion1InlineType1", + "type_:DiscriminatedUnion1InlineType2", + "type_:UndiscriminatedUnion1", + "type_:UndiscriminatedUnion1InlineType1", + "type_:UndiscriminatedUnion1InlineType2", + "type_:InlineEnum" + ], + "errors": [], + "subpackages": [], + "webhooks": null, + "navigationConfig": null, + "hasEndpointsInTree": true, + "docs": null + }, + "sdkConfig": { + "isAuthMandatory": false, + "hasStreamingEndpoints": false, + "hasPaginatedEndpoints": false, + "hasFileDownloadEndpoints": false, + "platformHeaders": { + "language": "X-Fern-Language", + "sdkName": "X-Fern-SDK-Name", + "sdkVersion": "X-Fern-SDK-Version", + "userAgent": null + } + } +} \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/no-inline/.npmignore b/seed/ts-sdk/inline-types/no-inline/.npmignore new file mode 100644 index 00000000000..6db0876c41c --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/.npmignore @@ -0,0 +1,9 @@ +node_modules +src +tests +.gitignore +.github +.fernignore +.prettierrc.yml +tsconfig.json +yarn.lock \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/no-inline/.prettierrc.yml b/seed/ts-sdk/inline-types/no-inline/.prettierrc.yml new file mode 100644 index 00000000000..0c06786bf53 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/.prettierrc.yml @@ -0,0 +1,2 @@ +tabWidth: 4 +printWidth: 120 diff --git a/seed/ts-sdk/inline-types/no-inline/README.md b/seed/ts-sdk/inline-types/no-inline/README.md new file mode 100644 index 00000000000..3a27a521141 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/README.md @@ -0,0 +1,156 @@ +# Seed TypeScript Library + +[![fern shield](https://img.shields.io/badge/%F0%9F%8C%BF-Built%20with%20Fern-brightgreen)](https://buildwithfern.com?utm_source=github&utm_medium=github&utm_campaign=readme&utm_source=Seed%2FTypeScript) +[![npm shield](https://img.shields.io/npm/v/@fern/inline-types)](https://www.npmjs.com/package/@fern/inline-types) + +The Seed TypeScript library provides convenient access to the Seed API from TypeScript. + +## Installation + +```sh +npm i -s @fern/inline-types +``` + +## Reference + +A full reference for this library is available [here](./reference.md). + +## Usage + +Instantiate and use the client with the following: + +```typescript +import { SeedObjectClient } from "@fern/inline-types"; + +const client = new SeedObjectClient({ environment: "YOUR_BASE_URL" }); +await client.getRoot({ + bar: { + foo: "foo", + }, + foo: "foo", +}); +``` + +## Request And Response Types + +The SDK exports all request and response types as TypeScript interfaces. Simply import them with the +following namespace: + +```typescript +import { SeedObject } from "@fern/inline-types"; + +const request: SeedObject.PostRootRequest = { + ... +}; +``` + +## Exception Handling + +When the API returns a non-success status code (4xx or 5xx response), a subclass of the following error +will be thrown. + +```typescript +import { SeedObjectError } from "@fern/inline-types"; + +try { + await client.getRoot(...); +} catch (err) { + if (err instanceof SeedObjectError) { + console.log(err.statusCode); + console.log(err.message); + console.log(err.body); + } +} +``` + +## Advanced + +### Additional Headers + +If you would like to send additional headers as part of the request, use the `headers` request option. + +```typescript +const response = await client.getRoot(..., { + headers: { + 'X-Custom-Header': 'custom value' + } +}); +``` + +### Retries + +The SDK is instrumented with automatic retries with exponential backoff. A request will be retried as long +as the request is deemed retriable and the number of retry attempts has not grown larger than the configured +retry limit (default: 2). + +A request is deemed retriable when any of the following HTTP status codes is returned: + +- [408](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/408) (Timeout) +- [429](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/429) (Too Many Requests) +- [5XX](https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/500) (Internal Server Errors) + +Use the `maxRetries` request option to configure this behavior. + +```typescript +const response = await client.getRoot(..., { + maxRetries: 0 // override maxRetries at the request level +}); +``` + +### Timeouts + +The SDK defaults to a 60 second timeout. Use the `timeoutInSeconds` option to configure this behavior. + +```typescript +const response = await client.getRoot(..., { + timeoutInSeconds: 30 // override timeout to 30s +}); +``` + +### Aborting Requests + +The SDK allows users to abort requests at any point by passing in an abort signal. + +```typescript +const controller = new AbortController(); +const response = await client.getRoot(..., { + abortSignal: controller.signal +}); +controller.abort(); // aborts the request +``` + +### Runtime Compatibility + +The SDK defaults to `node-fetch` but will use the global fetch client if present. The SDK works in the following +runtimes: + +- Node.js 18+ +- Vercel +- Cloudflare Workers +- Deno v1.25+ +- Bun 1.0+ +- React Native + +### Customizing Fetch Client + +The SDK provides a way for your to customize the underlying HTTP client / Fetch function. If you're running in an +unsupported environment, this provides a way for you to break glass and ensure the SDK works. + +```typescript +import { SeedObjectClient } from "@fern/inline-types"; + +const client = new SeedObjectClient({ + ... + fetcher: // provide your implementation here +}); +``` + +## Contributing + +While we value open-source contributions to this SDK, this library is generated programmatically. +Additions made directly to this library would have to be moved over to our generation code, +otherwise they would be overwritten upon the next generated release. Feel free to open a PR as +a proof of concept, but know that we will not be able to merge it as-is. We suggest opening +an issue first to discuss with us! + +On the other hand, contributions to the README are always very welcome! diff --git a/seed/ts-sdk/inline-types/no-inline/jest.config.js b/seed/ts-sdk/inline-types/no-inline/jest.config.js new file mode 100644 index 00000000000..35d6e65bf93 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/jest.config.js @@ -0,0 +1,5 @@ +/** @type {import('jest').Config} */ +module.exports = { + preset: "ts-jest", + testEnvironment: "node", +}; diff --git a/seed/ts-sdk/inline-types/no-inline/package.json b/seed/ts-sdk/inline-types/no-inline/package.json new file mode 100644 index 00000000000..c62c4aac8d7 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/package.json @@ -0,0 +1,42 @@ +{ + "name": "@fern/inline-types", + "version": "0.0.1", + "private": false, + "repository": "https://github.com/inline-types/fern", + "main": "./index.js", + "types": "./index.d.ts", + "scripts": { + "format": "prettier . --write --ignore-unknown", + "build": "tsc", + "prepack": "cp -rv dist/. .", + "test": "jest" + }, + "dependencies": { + "url-join": "4.0.1", + "form-data": "^4.0.0", + "formdata-node": "^6.0.3", + "node-fetch": "2.7.0", + "qs": "6.11.2", + "readable-stream": "^4.5.2" + }, + "devDependencies": { + "@types/url-join": "4.0.1", + "@types/qs": "6.9.8", + "@types/node-fetch": "2.6.9", + "@types/readable-stream": "^4.0.15", + "webpack": "^5.94.0", + "ts-loader": "^9.3.1", + "jest": "29.7.0", + "@types/jest": "29.5.5", + "ts-jest": "29.1.1", + "jest-environment-jsdom": "29.7.0", + "@types/node": "17.0.33", + "prettier": "2.7.1", + "typescript": "4.6.4" + }, + "browser": { + "fs": false, + "os": false, + "path": false + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/reference.md b/seed/ts-sdk/inline-types/no-inline/reference.md new file mode 100644 index 00000000000..25a9fd05cf9 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/reference.md @@ -0,0 +1,65 @@ +# Reference + +
client.getUndiscriminatedUnion({ ...params }) -> void +
+
+ +#### 🔌 Usage + +
+
+ +
+
+ +```typescript +await client.getUndiscriminatedUnion({ + bar: { + foo: "foo", + bar: { + foo: "foo", + ref: { + foo: "foo", + }, + }, + ref: { + foo: "foo", + }, + }, + foo: "foo", +}); +``` + +
+
+
+
+ +#### ⚙️ Parameters + +
+
+ +
+
+ +**request:** `SeedObject.GetUndiscriminatedUnionRequest` + +
+
+ +
+
+ +**requestOptions:** `SeedObjectClient.RequestOptions` + +
+
+
+
+ +
+
+
+ +## diff --git a/seed/ts-sdk/inline-types/no-inline/resolved-snippet-templates.md b/seed/ts-sdk/inline-types/no-inline/resolved-snippet-templates.md new file mode 100644 index 00000000000..816b2039fa1 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/resolved-snippet-templates.md @@ -0,0 +1,51 @@ +```typescript +import { SeedObjectClient } from "@fern/inline-types"; + +const client = new SeedObjectClient({ environment: "YOUR_BASE_URL" }); +await client.getRoot({ + bar: { + foo: "foo", + }, + foo: "foo", +}); + +``` + + +```typescript +import { SeedObjectClient } from "@fern/inline-types"; + +const client = new SeedObjectClient({ environment: "YOUR_BASE_URL" }); +await client.getDiscriminatedUnion( + { + bar: bar: { + type : "type1", + foo: "foo", + bar: { + foo: "foo", + ref: { + foo: "foo" + } + }, + ref: { + foo: "foo" + } + }, + foo: "foo" + } +) + +``` + + +```typescript +import { SeedObjectClient } from "@fern/inline-types"; + +const client = new SeedObjectClient({ environment: "YOUR_BASE_URL" }); +await client.getUndiscriminatedUnion({ + foo: "foo", +}); + +``` + + diff --git a/seed/ts-sdk/inline-types/no-inline/snippet-templates.json b/seed/ts-sdk/inline-types/no-inline/snippet-templates.json new file mode 100644 index 00000000000..30032968443 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/snippet-templates.json @@ -0,0 +1,1496 @@ +[ + { + "sdk": { + "package": "@fern/inline-types", + "version": "0.0.1", + "type": "typescript" + }, + "endpointId": { + "path": "/root/root", + "method": "POST", + "identifierOverride": "endpoint_.getRoot" + }, + "snippetTemplate": { + "clientInstantiation": { + "imports": [ + "import { SeedObjectClient } from \"@fern/inline-types\";" + ], + "templateString": "const client = new SeedObjectClient($FERN_INPUT);", + "isOptional": false, + "inputDelimiter": ",", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{ $FERN_INPUT }", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "environment: \"YOUR_BASE_URL\"", + "isOptional": false, + "templateInputs": [], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "functionInvocation": { + "imports": [], + "templateString": "await client.getRoot(\n\t$FERN_INPUT\n)", + "isOptional": false, + "inputDelimiter": ",\n\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{\n\t\t$FERN_INPUT\n\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "bar: {\n\t\t\t$FERN_INPUT\n\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "v1" + } + }, + { + "sdk": { + "package": "@fern/inline-types", + "version": "0.0.1", + "type": "typescript" + }, + "endpointId": { + "path": "/root/discriminated-union", + "method": "POST", + "identifierOverride": "endpoint_.getDiscriminatedUnion" + }, + "snippetTemplate": { + "clientInstantiation": { + "imports": [ + "import { SeedObjectClient } from \"@fern/inline-types\";" + ], + "templateString": "const client = new SeedObjectClient($FERN_INPUT);", + "isOptional": false, + "inputDelimiter": ",", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{ $FERN_INPUT }", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "environment: \"YOUR_BASE_URL\"", + "isOptional": false, + "templateInputs": [], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "functionInvocation": { + "imports": [], + "templateString": "await client.getDiscriminatedUnion(\n\t$FERN_INPUT\n)", + "isOptional": false, + "inputDelimiter": ",\n\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{\n\t\t$FERN_INPUT\n\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "isOptional": true, + "templateString": "bar: $FERN_INPUT", + "discriminantField": "type", + "members": { + "type1": { + "imports": [], + "templateString": "bar: { \n\t\t\ttype : \"type1\", \n\t\t\t$FERN_INPUT\n\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "bar: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type2": { + "imports": [], + "templateString": "bar: { \n\t\t\ttype : \"type2\", \n\t\t\t$FERN_INPUT\n\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "baz: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.baz", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "ref": { + "imports": [], + "templateString": "bar: { \n\t\t\ttype : \"ref\", \n\t\t\t$FERN_INPUT\n\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + } + }, + "templateInput": { + "location": "BODY", + "path": "bar", + "type": "payload" + }, + "type": "discriminatedUnion" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "v1" + } + }, + { + "sdk": { + "package": "@fern/inline-types", + "version": "0.0.1", + "type": "typescript" + }, + "endpointId": { + "path": "/root/undiscriminated-union", + "method": "POST", + "identifierOverride": "endpoint_.getUndiscriminatedUnion" + }, + "snippetTemplate": { + "clientInstantiation": { + "imports": [ + "import { SeedObjectClient } from \"@fern/inline-types\";" + ], + "templateString": "const client = new SeedObjectClient($FERN_INPUT);", + "isOptional": false, + "inputDelimiter": ",", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{ $FERN_INPUT }", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "environment: \"YOUR_BASE_URL\"", + "isOptional": false, + "templateInputs": [], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "functionInvocation": { + "imports": [], + "templateString": "await client.getUndiscriminatedUnion(\n\t$FERN_INPUT\n)", + "isOptional": false, + "inputDelimiter": ",\n\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "{\n\t\t$FERN_INPUT\n\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "isOptional": true, + "templateString": "bar: $FERN_INPUT", + "members": [ + { + "template": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "bar: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": { + "value": "type_:UndiscriminatedUnion1InlineType1", + "type": "id" + } + }, + { + "template": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "baz: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "baz", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": { + "value": "type_:UndiscriminatedUnion1InlineType2", + "type": "id" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "templateString": "$FERN_INPUT", + "discriminantField": "type", + "members": { + "type1": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"type1\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "bar: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type2": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"type2\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "baz: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "baz", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "ref": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"ref\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + } + }, + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "discriminatedUnion" + }, + "type": { + "value": "type_:UndiscriminatedUnion1DiscriminatedUnion1", + "type": "id" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "templateString": "$FERN_INPUT", + "discriminantField": "type", + "members": { + "type1": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"type1\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "bar: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "bar.ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type2": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"type2\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "baz: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "baz", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "ref": { + "imports": [], + "templateString": "{ \n\t\t\t\ttype : \"ref\", \n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "isOptional": true, + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + } + }, + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "discriminatedUnion" + }, + "type": { + "value": "type_:UndiscriminatedUnion1DiscriminatedUnion1", + "type": "id" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "values": { + "SUNNY": "\"SUNNY\"", + "CLOUDY": "\"CLOUDY\"", + "RAINING": "\"RAINING\"", + "SNOWING": "\"SNOWING\"" + }, + "templateString": "$FERN_INPUT", + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "enum" + }, + "type": { + "value": "type_:UndiscriminatedUnion1InlineEnum1", + "type": "id" + } + }, + { + "template": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "type": "payload" + } + ], + "type": "generic" + }, + "type": { + "value": "type_:UserId", + "type": "id" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "containerTemplateString": "[\n\t\t\t\t$FERN_INPUT\n\t\t\t]", + "delimiter": ",\n\t\t\t\t", + "innerTemplate": { + "imports": [], + "templateString": "{\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "iterable" + }, + "type": { + "itemType": { + "value": "type_:UndiscriminatedUnion1InlineListItem1", + "type": "id" + }, + "type": "list" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "containerTemplateString": "new Set([\n\t\t\t\t$FERN_INPUT\n\t\t\t])", + "delimiter": ",\n\t\t\t\t", + "innerTemplate": { + "imports": [], + "templateString": "{\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "iterable" + }, + "type": { + "itemType": { + "value": "type_:UndiscriminatedUnion1InlineSetItem1", + "type": "id" + }, + "type": "set" + } + }, + { + "template": { + "imports": [], + "isOptional": true, + "containerTemplateString": "{\n\t\t\t\t$FERN_INPUT\n\t\t\t}", + "delimiter": ",\n\t\t\t\t", + "keyValueSeparator": ": ", + "keyTemplate": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "type": "payload" + } + ], + "type": "generic" + }, + "valueTemplate": { + "imports": [], + "templateString": "{\n\t\t\t\t\t$FERN_INPUT\n\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "ref: {\n\t\t\t\t\t\t$FERN_INPUT\n\t\t\t\t\t}", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "ref.foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "templateInput": { + "location": "RELATIVE", + "type": "payload" + }, + "type": "dict" + }, + "type": { + "keyType": { + "value": { + "type": "string" + }, + "type": "primitive" + }, + "valueType": { + "value": "type_:UndiscriminatedUnion1InlineMapItem1", + "type": "id" + }, + "type": "map" + } + }, + { + "template": { + "imports": [], + "templateString": "$FERN_INPUT", + "isOptional": true, + "inputDelimiter": ",\n\t\t\t", + "templateInputs": [ + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "RELATIVE", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": { + "value": "type_:ReferenceType", + "type": "id" + } + } + ], + "templateInput": { + "location": "BODY", + "path": "bar", + "type": "payload" + }, + "type": "union_v2" + }, + "type": "template" + }, + { + "value": { + "imports": [], + "templateString": "foo: $FERN_INPUT", + "isOptional": true, + "templateInputs": [ + { + "location": "BODY", + "path": "foo", + "type": "payload" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "template" + } + ], + "type": "generic" + }, + "type": "v1" + } + } +] \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/no-inline/snippet.json b/seed/ts-sdk/inline-types/no-inline/snippet.json new file mode 100644 index 00000000000..6b5456d3c0d --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/snippet.json @@ -0,0 +1,38 @@ +{ + "endpoints": [ + { + "id": { + "path": "/root/root", + "method": "POST", + "identifier_override": "endpoint_.getRoot" + }, + "snippet": { + "type": "typescript", + "client": "import { SeedObjectClient } from \"@fern/inline-types\";\n\nconst client = new SeedObjectClient({ environment: \"YOUR_BASE_URL\" });\nawait client.getRoot({\n bar: {\n foo: \"foo\"\n },\n foo: \"foo\"\n});\n" + } + }, + { + "id": { + "path": "/root/discriminated-union", + "method": "POST", + "identifier_override": "endpoint_.getDiscriminatedUnion" + }, + "snippet": { + "type": "typescript", + "client": "import { SeedObjectClient } from \"@fern/inline-types\";\n\nconst client = new SeedObjectClient({ environment: \"YOUR_BASE_URL\" });\nawait client.getDiscriminatedUnion({\n bar: {\n type: \"type1\",\n foo: \"foo\",\n bar: {\n foo: \"foo\",\n ref: {\n foo: \"foo\"\n }\n },\n ref: {\n foo: \"foo\"\n }\n },\n foo: \"foo\"\n});\n" + } + }, + { + "id": { + "path": "/root/undiscriminated-union", + "method": "POST", + "identifier_override": "endpoint_.getUndiscriminatedUnion" + }, + "snippet": { + "type": "typescript", + "client": "import { SeedObjectClient } from \"@fern/inline-types\";\n\nconst client = new SeedObjectClient({ environment: \"YOUR_BASE_URL\" });\nawait client.getUndiscriminatedUnion({\n bar: {\n foo: \"foo\",\n bar: {\n foo: \"foo\",\n ref: {\n foo: \"foo\"\n }\n },\n ref: {\n foo: \"foo\"\n }\n },\n foo: \"foo\"\n});\n" + } + } + ], + "types": {} +} \ No newline at end of file diff --git a/seed/ts-sdk/inline-types/no-inline/src/Client.ts b/seed/ts-sdk/inline-types/no-inline/src/Client.ts new file mode 100644 index 00000000000..888489f9147 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/Client.ts @@ -0,0 +1,235 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as core from "./core"; +import * as SeedObject from "./api/index"; +import urlJoin from "url-join"; +import * as errors from "./errors/index"; + +export declare namespace SeedObjectClient { + interface Options { + environment: core.Supplier; + } + + interface RequestOptions { + /** The maximum time to wait for a response in seconds. */ + timeoutInSeconds?: number; + /** The number of times to retry the request. Defaults to 2. */ + maxRetries?: number; + /** A hook to abort the request. */ + abortSignal?: AbortSignal; + /** Additional headers to include in the request. */ + headers?: Record; + } +} + +export class SeedObjectClient { + constructor(protected readonly _options: SeedObjectClient.Options) {} + + /** + * @param {SeedObject.PostRootRequest} request + * @param {SeedObjectClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.getRoot({ + * bar: { + * foo: "foo" + * }, + * foo: "foo" + * }) + */ + public async getRoot( + request: SeedObject.PostRootRequest, + requestOptions?: SeedObjectClient.RequestOptions + ): Promise { + const _response = await core.fetcher({ + url: urlJoin(await core.Supplier.get(this._options.environment), "/root/root"), + method: "POST", + headers: { + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "@fern/inline-types", + "X-Fern-SDK-Version": "0.0.1", + "User-Agent": "@fern/inline-types/0.0.1", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return _response.body as SeedObject.RootType1; + } + + if (_response.error.reason === "status-code") { + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.SeedObjectTimeoutError("Timeout exceeded when calling POST /root/root."); + case "unknown": + throw new errors.SeedObjectError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * @param {SeedObject.GetDiscriminatedUnionRequest} request + * @param {SeedObjectClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.getDiscriminatedUnion({ + * bar: { + * type: "type1", + * foo: "foo", + * bar: { + * foo: "foo", + * ref: { + * foo: "foo" + * } + * }, + * ref: { + * foo: "foo" + * } + * }, + * foo: "foo" + * }) + */ + public async getDiscriminatedUnion( + request: SeedObject.GetDiscriminatedUnionRequest, + requestOptions?: SeedObjectClient.RequestOptions + ): Promise { + const _response = await core.fetcher({ + url: urlJoin(await core.Supplier.get(this._options.environment), "/root/discriminated-union"), + method: "POST", + headers: { + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "@fern/inline-types", + "X-Fern-SDK-Version": "0.0.1", + "User-Agent": "@fern/inline-types/0.0.1", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.SeedObjectTimeoutError( + "Timeout exceeded when calling POST /root/discriminated-union." + ); + case "unknown": + throw new errors.SeedObjectError({ + message: _response.error.errorMessage, + }); + } + } + + /** + * @param {SeedObject.GetUndiscriminatedUnionRequest} request + * @param {SeedObjectClient.RequestOptions} requestOptions - Request-specific configuration. + * + * @example + * await client.getUndiscriminatedUnion({ + * bar: { + * foo: "foo", + * bar: { + * foo: "foo", + * ref: { + * foo: "foo" + * } + * }, + * ref: { + * foo: "foo" + * } + * }, + * foo: "foo" + * }) + */ + public async getUndiscriminatedUnion( + request: SeedObject.GetUndiscriminatedUnionRequest, + requestOptions?: SeedObjectClient.RequestOptions + ): Promise { + const _response = await core.fetcher({ + url: urlJoin(await core.Supplier.get(this._options.environment), "/root/undiscriminated-union"), + method: "POST", + headers: { + "X-Fern-Language": "JavaScript", + "X-Fern-SDK-Name": "@fern/inline-types", + "X-Fern-SDK-Version": "0.0.1", + "User-Agent": "@fern/inline-types/0.0.1", + "X-Fern-Runtime": core.RUNTIME.type, + "X-Fern-Runtime-Version": core.RUNTIME.version, + ...requestOptions?.headers, + }, + contentType: "application/json", + requestType: "json", + body: request, + timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000, + maxRetries: requestOptions?.maxRetries, + abortSignal: requestOptions?.abortSignal, + }); + if (_response.ok) { + return; + } + + if (_response.error.reason === "status-code") { + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.body, + }); + } + + switch (_response.error.reason) { + case "non-json": + throw new errors.SeedObjectError({ + statusCode: _response.error.statusCode, + body: _response.error.rawBody, + }); + case "timeout": + throw new errors.SeedObjectTimeoutError( + "Timeout exceeded when calling POST /root/undiscriminated-union." + ); + case "unknown": + throw new errors.SeedObjectError({ + message: _response.error.errorMessage, + }); + } + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/client/index.ts b/seed/ts-sdk/inline-types/no-inline/src/api/client/index.ts new file mode 100644 index 00000000000..415726b7fea --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/client/index.ts @@ -0,0 +1 @@ +export * from "./requests"; diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/GetDiscriminatedUnionRequest.ts b/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/GetDiscriminatedUnionRequest.ts new file mode 100644 index 00000000000..a89b16d314e --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/GetDiscriminatedUnionRequest.ts @@ -0,0 +1,29 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../../index"; + +/** + * @example + * { + * bar: { + * type: "type1", + * foo: "foo", + * bar: { + * foo: "foo", + * ref: { + * foo: "foo" + * } + * }, + * ref: { + * foo: "foo" + * } + * }, + * foo: "foo" + * } + */ +export interface GetDiscriminatedUnionRequest { + bar: SeedObject.DiscriminatedUnion1; + foo: string; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/GetUndiscriminatedUnionRequest.ts b/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/GetUndiscriminatedUnionRequest.ts new file mode 100644 index 00000000000..e0e9f214ca5 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/GetUndiscriminatedUnionRequest.ts @@ -0,0 +1,28 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../../index"; + +/** + * @example + * { + * bar: { + * foo: "foo", + * bar: { + * foo: "foo", + * ref: { + * foo: "foo" + * } + * }, + * ref: { + * foo: "foo" + * } + * }, + * foo: "foo" + * } + */ +export interface GetUndiscriminatedUnionRequest { + bar: SeedObject.UndiscriminatedUnion1; + foo: string; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/PostRootRequest.ts b/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/PostRootRequest.ts new file mode 100644 index 00000000000..f509f577f12 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/PostRootRequest.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../../index"; + +/** + * @example + * { + * bar: { + * foo: "foo" + * }, + * foo: "foo" + * } + */ +export interface PostRootRequest { + bar: SeedObject.RequestTypeInlineType1; + foo: string; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/index.ts b/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/index.ts new file mode 100644 index 00000000000..20fc5cd64ec --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/client/requests/index.ts @@ -0,0 +1,3 @@ +export { type PostRootRequest } from "./PostRootRequest"; +export { type GetDiscriminatedUnionRequest } from "./GetDiscriminatedUnionRequest"; +export { type GetUndiscriminatedUnionRequest } from "./GetUndiscriminatedUnionRequest"; diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/index.ts b/seed/ts-sdk/inline-types/no-inline/src/api/index.ts new file mode 100644 index 00000000000..c9240f83b48 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/index.ts @@ -0,0 +1,2 @@ +export * from "./types"; +export * from "./client"; diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasInlineValue.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasInlineValue.ts new file mode 100644 index 00000000000..0beb9652513 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasInlineValue.ts @@ -0,0 +1,8 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export interface AliasInlineValue { + foo: string; + bar: string; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasListInline.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasListInline.ts new file mode 100644 index 00000000000..a684ff0eef7 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasListInline.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +export type AliasListInline = SeedObject.AliasInlineValue[]; diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasMapInline.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasMapInline.ts new file mode 100644 index 00000000000..f0d6f380859 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasMapInline.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +export type AliasMapInline = Record; diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasSetInline.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasSetInline.ts new file mode 100644 index 00000000000..32d6e6ebd97 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/AliasSetInline.ts @@ -0,0 +1,7 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +export type AliasSetInline = SeedObject.AliasInlineValue[]; diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1.ts new file mode 100644 index 00000000000..1ecb788196f --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1.ts @@ -0,0 +1,33 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export type DiscriminatedUnion1 = + /** + * lorem ipsum */ + | SeedObject.DiscriminatedUnion1.Type1 + /** + * lorem ipsum */ + | SeedObject.DiscriminatedUnion1.Type2 + /** + * lorem ipsum */ + | SeedObject.DiscriminatedUnion1.Ref; + +export namespace DiscriminatedUnion1 { + export interface Type1 extends SeedObject.DiscriminatedUnion1InlineType1 { + type: "type1"; + } + + export interface Type2 extends SeedObject.DiscriminatedUnion1InlineType2 { + type: "type2"; + } + + export interface Ref extends SeedObject.ReferenceType { + type: "ref"; + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1InlineType1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1InlineType1.ts new file mode 100644 index 00000000000..aee4789e932 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1InlineType1.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface DiscriminatedUnion1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: SeedObject.DiscriminatedUnion1InlineType1InlineType1; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1InlineType1InlineType1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1InlineType1InlineType1.ts new file mode 100644 index 00000000000..259925b7704 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1InlineType1InlineType1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface DiscriminatedUnion1InlineType1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1InlineType2.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1InlineType2.ts new file mode 100644 index 00000000000..b90bfb679a2 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/DiscriminatedUnion1InlineType2.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface DiscriminatedUnion1InlineType2 { + /** lorem ipsum */ + baz: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/InlineEnum1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/InlineEnum1.ts new file mode 100644 index 00000000000..c678052d190 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/InlineEnum1.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * lorem ipsum + */ +export type InlineEnum1 = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; +export const InlineEnum1 = { + Sunny: "SUNNY", + Cloudy: "CLOUDY", + Raining: "RAINING", + Snowing: "SNOWING", +} as const; diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/ReferenceType.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/ReferenceType.ts new file mode 100644 index 00000000000..3754bc9c7e2 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/ReferenceType.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * lorem ipsum + */ +export interface ReferenceType { + /** lorem ipsum */ + foo: string; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/RequestTypeInlineType1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/RequestTypeInlineType1.ts new file mode 100644 index 00000000000..1e390edb73c --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/RequestTypeInlineType1.ts @@ -0,0 +1,11 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * lorem ipsum + */ +export interface RequestTypeInlineType1 { + /** lorem ipsum */ + foo: string; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1.ts new file mode 100644 index 00000000000..d0d33243bcc --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1.ts @@ -0,0 +1,23 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: SeedObject.RootType1InlineType1; + /** lorem ipsum */ + fooMap: Record; + /** lorem ipsum */ + fooList: SeedObject.RootType1FooListItem[]; + /** lorem ipsum */ + fooSet: SeedObject.RootType1FooSetItem[]; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1FooListItem.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1FooListItem.ts new file mode 100644 index 00000000000..0ffcae98837 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1FooListItem.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1FooListItem { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1FooMapValue.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1FooMapValue.ts new file mode 100644 index 00000000000..431bc3c905f --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1FooMapValue.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1FooMapValue { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1FooSetItem.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1FooSetItem.ts new file mode 100644 index 00000000000..b4c3b6b5788 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1FooSetItem.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1FooSetItem { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1InlineType1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1InlineType1.ts new file mode 100644 index 00000000000..786b87523f5 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1InlineType1.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: SeedObject.RootType1InlineType1NestedInlineType1; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1InlineType1NestedInlineType1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1InlineType1NestedInlineType1.ts new file mode 100644 index 00000000000..7f2cca73ba7 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/RootType1InlineType1NestedInlineType1.ts @@ -0,0 +1,19 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface RootType1InlineType1NestedInlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: string; + /** lorem ipsum */ + myEnum: SeedObject.InlineEnum1; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1.ts new file mode 100644 index 00000000000..e27127ef2eb --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1.ts @@ -0,0 +1,40 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export type UndiscriminatedUnion1 = + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1InlineType1 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1InlineType2 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1DiscriminatedUnion1 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1DiscriminatedUnion1 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1InlineEnum1 + /** + * lorem ipsum */ + | SeedObject.UserId + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1InlineListItem1[] + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1InlineSetItem1[] + /** + * lorem ipsum */ + | Record + /** + * lorem ipsum */ + | SeedObject.ReferenceType; diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1.ts new file mode 100644 index 00000000000..79d5ac09d41 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1.ts @@ -0,0 +1,33 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export type UndiscriminatedUnion1DiscriminatedUnion1 = + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1DiscriminatedUnion1.Type1 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1DiscriminatedUnion1.Type2 + /** + * lorem ipsum */ + | SeedObject.UndiscriminatedUnion1DiscriminatedUnion1.Ref; + +export namespace UndiscriminatedUnion1DiscriminatedUnion1 { + export interface Type1 extends SeedObject.UndiscriminatedUnion1DiscriminatedUnion1InlineType1 { + type: "type1"; + } + + export interface Type2 extends SeedObject.UndiscriminatedUnion1DiscriminatedUnion1InlineType2 { + type: "type2"; + } + + export interface Ref extends SeedObject.ReferenceType { + type: "ref"; + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1.ts new file mode 100644 index 00000000000..ed023f35ece --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1DiscriminatedUnion1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: SeedObject.UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.ts new file mode 100644 index 00000000000..06dc9f4879f --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType2.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType2.ts new file mode 100644 index 00000000000..a691050422a --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1DiscriminatedUnion1InlineType2.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1DiscriminatedUnion1InlineType2 { + /** lorem ipsum */ + baz: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineEnum1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineEnum1.ts new file mode 100644 index 00000000000..b0184d4a8fe --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineEnum1.ts @@ -0,0 +1,14 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * lorem ipsum + */ +export type UndiscriminatedUnion1InlineEnum1 = "SUNNY" | "CLOUDY" | "RAINING" | "SNOWING"; +export const UndiscriminatedUnion1InlineEnum1 = { + Sunny: "SUNNY", + Cloudy: "CLOUDY", + Raining: "RAINING", + Snowing: "SNOWING", +} as const; diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineListItem1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineListItem1.ts new file mode 100644 index 00000000000..a4e8738f30e --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineListItem1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineListItem1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineMapItem1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineMapItem1.ts new file mode 100644 index 00000000000..2c343a1648d --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineMapItem1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineMapItem1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineSetItem1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineSetItem1.ts new file mode 100644 index 00000000000..bfb627dff7a --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineSetItem1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineSetItem1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineType1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineType1.ts new file mode 100644 index 00000000000..cd15e0f5170 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineType1.ts @@ -0,0 +1,17 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + bar: SeedObject.UndiscriminatedUnion1InlineType1InlineType1; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineType1InlineType1.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineType1InlineType1.ts new file mode 100644 index 00000000000..104de7c900d --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineType1InlineType1.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineType1InlineType1 { + /** lorem ipsum */ + foo: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineType2.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineType2.ts new file mode 100644 index 00000000000..ceaf78891a0 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UndiscriminatedUnion1InlineType2.ts @@ -0,0 +1,15 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +import * as SeedObject from "../index"; + +/** + * lorem ipsum + */ +export interface UndiscriminatedUnion1InlineType2 { + /** lorem ipsum */ + baz: string; + /** lorem ipsum */ + ref: SeedObject.ReferenceType; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/UserId.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/UserId.ts new file mode 100644 index 00000000000..5a6e3e5152f --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/UserId.ts @@ -0,0 +1,8 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +/** + * lorem ipsum + */ +export type UserId = string; diff --git a/seed/ts-sdk/inline-types/no-inline/src/api/types/index.ts b/seed/ts-sdk/inline-types/no-inline/src/api/types/index.ts new file mode 100644 index 00000000000..57d21ed5261 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/api/types/index.ts @@ -0,0 +1,30 @@ +export * from "./AliasMapInline"; +export * from "./AliasSetInline"; +export * from "./AliasListInline"; +export * from "./AliasInlineValue"; +export * from "./RequestTypeInlineType1"; +export * from "./RootType1"; +export * from "./RootType1FooMapValue"; +export * from "./RootType1FooListItem"; +export * from "./RootType1FooSetItem"; +export * from "./RootType1InlineType1"; +export * from "./RootType1InlineType1NestedInlineType1"; +export * from "./DiscriminatedUnion1"; +export * from "./DiscriminatedUnion1InlineType1"; +export * from "./DiscriminatedUnion1InlineType1InlineType1"; +export * from "./DiscriminatedUnion1InlineType2"; +export * from "./UndiscriminatedUnion1"; +export * from "./UndiscriminatedUnion1InlineType1"; +export * from "./UndiscriminatedUnion1InlineType1InlineType1"; +export * from "./UndiscriminatedUnion1InlineType2"; +export * from "./InlineEnum1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1InlineType1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1"; +export * from "./UndiscriminatedUnion1DiscriminatedUnion1InlineType2"; +export * from "./UndiscriminatedUnion1InlineEnum1"; +export * from "./UserId"; +export * from "./UndiscriminatedUnion1InlineListItem1"; +export * from "./UndiscriminatedUnion1InlineSetItem1"; +export * from "./UndiscriminatedUnion1InlineMapItem1"; +export * from "./ReferenceType"; diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/APIResponse.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/APIResponse.ts new file mode 100644 index 00000000000..3664d09e168 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/APIResponse.ts @@ -0,0 +1,12 @@ +export type APIResponse = SuccessfulResponse | FailedResponse; + +export interface SuccessfulResponse { + ok: true; + body: T; + headers?: Record; +} + +export interface FailedResponse { + ok: false; + error: T; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/Fetcher.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/Fetcher.ts new file mode 100644 index 00000000000..b8f23717b69 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/Fetcher.ts @@ -0,0 +1,143 @@ +import { APIResponse } from "./APIResponse"; +import { createRequestUrl } from "./createRequestUrl"; +import { getFetchFn } from "./getFetchFn"; +import { getRequestBody } from "./getRequestBody"; +import { getResponseBody } from "./getResponseBody"; +import { makeRequest } from "./makeRequest"; +import { requestWithRetries } from "./requestWithRetries"; + +export type FetchFunction = (args: Fetcher.Args) => Promise>; + +export declare namespace Fetcher { + export interface Args { + url: string; + method: string; + contentType?: string; + headers?: Record; + queryParameters?: Record; + body?: unknown; + timeoutMs?: number; + maxRetries?: number; + withCredentials?: boolean; + abortSignal?: AbortSignal; + requestType?: "json" | "file" | "bytes"; + responseType?: "json" | "blob" | "sse" | "streaming" | "text" | "arrayBuffer"; + duplex?: "half"; + } + + export type Error = FailedStatusCodeError | NonJsonError | TimeoutError | UnknownError; + + export interface FailedStatusCodeError { + reason: "status-code"; + statusCode: number; + body: unknown; + } + + export interface NonJsonError { + reason: "non-json"; + statusCode: number; + rawBody: string; + } + + export interface TimeoutError { + reason: "timeout"; + } + + export interface UnknownError { + reason: "unknown"; + errorMessage: string; + } +} + +export async function fetcherImpl(args: Fetcher.Args): Promise> { + const headers: Record = {}; + if (args.body !== undefined && args.contentType != null) { + headers["Content-Type"] = args.contentType; + } + + if (args.headers != null) { + for (const [key, value] of Object.entries(args.headers)) { + if (value != null) { + headers[key] = value; + } + } + } + + const url = createRequestUrl(args.url, args.queryParameters); + let requestBody: BodyInit | undefined = await getRequestBody({ + body: args.body, + type: args.requestType === "json" ? "json" : "other", + }); + const fetchFn = await getFetchFn(); + + try { + const response = await requestWithRetries( + async () => + makeRequest( + fetchFn, + url, + args.method, + headers, + requestBody, + args.timeoutMs, + args.abortSignal, + args.withCredentials, + args.duplex + ), + args.maxRetries + ); + let responseBody = await getResponseBody(response, args.responseType); + + if (response.status >= 200 && response.status < 400) { + return { + ok: true, + body: responseBody as R, + headers: response.headers, + }; + } else { + return { + ok: false, + error: { + reason: "status-code", + statusCode: response.status, + body: responseBody, + }, + }; + } + } catch (error) { + if (args.abortSignal != null && args.abortSignal.aborted) { + return { + ok: false, + error: { + reason: "unknown", + errorMessage: "The user aborted a request", + }, + }; + } else if (error instanceof Error && error.name === "AbortError") { + return { + ok: false, + error: { + reason: "timeout", + }, + }; + } else if (error instanceof Error) { + return { + ok: false, + error: { + reason: "unknown", + errorMessage: error.message, + }, + }; + } + + return { + ok: false, + error: { + reason: "unknown", + errorMessage: JSON.stringify(error), + }, + }; + } +} + +export const fetcher: FetchFunction = fetcherImpl; diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/Supplier.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/Supplier.ts new file mode 100644 index 00000000000..867c931c02f --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/Supplier.ts @@ -0,0 +1,11 @@ +export type Supplier = T | Promise | (() => T | Promise); + +export const Supplier = { + get: async (supplier: Supplier): Promise => { + if (typeof supplier === "function") { + return (supplier as () => T)(); + } else { + return supplier; + } + }, +}; diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/createRequestUrl.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/createRequestUrl.ts new file mode 100644 index 00000000000..9288a99bb22 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/createRequestUrl.ts @@ -0,0 +1,10 @@ +import qs from "qs"; + +export function createRequestUrl( + baseUrl: string, + queryParameters?: Record +): string { + return Object.keys(queryParameters ?? {}).length > 0 + ? `${baseUrl}?${qs.stringify(queryParameters, { arrayFormat: "repeat" })}` + : baseUrl; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getFetchFn.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getFetchFn.ts new file mode 100644 index 00000000000..9fd9bfc42bd --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getFetchFn.ts @@ -0,0 +1,25 @@ +import { RUNTIME } from "../runtime"; + +/** + * Returns a fetch function based on the runtime + */ +export async function getFetchFn(): Promise { + // In Node.js 18+ environments, use native fetch + if (RUNTIME.type === "node" && RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { + return fetch; + } + + // In Node.js 18 or lower environments, the SDK always uses`node-fetch`. + if (RUNTIME.type === "node") { + return (await import("node-fetch")).default as any; + } + + // Otherwise the SDK uses global fetch if available, + // and falls back to node-fetch. + if (typeof fetch == "function") { + return fetch; + } + + // Defaults to node `node-fetch` if global fetch isn't available + return (await import("node-fetch")).default as any; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getHeader.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getHeader.ts new file mode 100644 index 00000000000..50f922b0e87 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getHeader.ts @@ -0,0 +1,8 @@ +export function getHeader(headers: Record, header: string): string | undefined { + for (const [headerKey, headerValue] of Object.entries(headers)) { + if (headerKey.toLowerCase() === header.toLowerCase()) { + return headerValue; + } + } + return undefined; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getRequestBody.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getRequestBody.ts new file mode 100644 index 00000000000..1138414b1c2 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getRequestBody.ts @@ -0,0 +1,14 @@ +export declare namespace GetRequestBody { + interface Args { + body: unknown; + type: "json" | "file" | "bytes" | "other"; + } +} + +export async function getRequestBody({ body, type }: GetRequestBody.Args): Promise { + if (type.includes("json")) { + return JSON.stringify(body); + } else { + return body as BodyInit; + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getResponseBody.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getResponseBody.ts new file mode 100644 index 00000000000..d046e6ea275 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/getResponseBody.ts @@ -0,0 +1,34 @@ +import { chooseStreamWrapper } from "./stream-wrappers/chooseStreamWrapper"; + +export async function getResponseBody(response: Response, responseType?: string): Promise { + if (response.body != null && responseType === "blob") { + return await response.blob(); + } else if (response.body != null && responseType === "arrayBuffer") { + return await response.arrayBuffer(); + } else if (response.body != null && responseType === "sse") { + return response.body; + } else if (response.body != null && responseType === "streaming") { + return chooseStreamWrapper(response.body); + } else if (response.body != null && responseType === "text") { + return await response.text(); + } else { + const text = await response.text(); + if (text.length > 0) { + try { + let responseBody = JSON.parse(text); + return responseBody; + } catch (err) { + return { + ok: false, + error: { + reason: "non-json", + statusCode: response.status, + rawBody: text, + }, + }; + } + } else { + return undefined; + } + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/index.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/index.ts new file mode 100644 index 00000000000..2d658ca48f9 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/index.ts @@ -0,0 +1,5 @@ +export type { APIResponse } from "./APIResponse"; +export { fetcher } from "./Fetcher"; +export type { Fetcher, FetchFunction } from "./Fetcher"; +export { getHeader } from "./getHeader"; +export { Supplier } from "./Supplier"; diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/makeRequest.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/makeRequest.ts new file mode 100644 index 00000000000..8fb4bace466 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/makeRequest.ts @@ -0,0 +1,44 @@ +import { anySignal, getTimeoutSignal } from "./signals"; + +export const makeRequest = async ( + fetchFn: (url: string, init: RequestInit) => Promise, + url: string, + method: string, + headers: Record, + requestBody: BodyInit | undefined, + timeoutMs?: number, + abortSignal?: AbortSignal, + withCredentials?: boolean, + duplex?: "half" +): Promise => { + const signals: AbortSignal[] = []; + + // Add timeout signal + let timeoutAbortId: NodeJS.Timeout | undefined = undefined; + if (timeoutMs != null) { + const { signal, abortId } = getTimeoutSignal(timeoutMs); + timeoutAbortId = abortId; + signals.push(signal); + } + + // Add arbitrary signal + if (abortSignal != null) { + signals.push(abortSignal); + } + let newSignals = anySignal(signals); + const response = await fetchFn(url, { + method: method, + headers, + body: requestBody, + signal: newSignals, + credentials: withCredentials ? "include" : undefined, + // @ts-ignore + duplex, + }); + + if (timeoutAbortId != null) { + clearTimeout(timeoutAbortId); + } + + return response; +}; diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/requestWithRetries.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/requestWithRetries.ts new file mode 100644 index 00000000000..8d5af9d5a82 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/requestWithRetries.ts @@ -0,0 +1,33 @@ +const INITIAL_RETRY_DELAY = 1000; // in milliseconds +const MAX_RETRY_DELAY = 60000; // in milliseconds +const DEFAULT_MAX_RETRIES = 2; +const JITTER_FACTOR = 0.2; // 20% random jitter + +function addJitter(delay: number): number { + // Generate a random value between -JITTER_FACTOR and +JITTER_FACTOR + const jitterMultiplier = 1 + (Math.random() * 2 - 1) * JITTER_FACTOR; + return delay * jitterMultiplier; +} + +export async function requestWithRetries( + requestFn: () => Promise, + maxRetries: number = DEFAULT_MAX_RETRIES +): Promise { + let response: Response = await requestFn(); + + for (let i = 0; i < maxRetries; ++i) { + if ([408, 409, 429].includes(response.status) || response.status >= 500) { + // Calculate base delay using exponential backoff (in milliseconds) + const baseDelay = Math.min(INITIAL_RETRY_DELAY * Math.pow(2, i), MAX_RETRY_DELAY); + + // Add jitter to the delay + const delayWithJitter = addJitter(baseDelay); + + await new Promise((resolve) => setTimeout(resolve, delayWithJitter)); + response = await requestFn(); + } else { + break; + } + } + return response!; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/signals.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/signals.ts new file mode 100644 index 00000000000..6c124ff7985 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/signals.ts @@ -0,0 +1,38 @@ +const TIMEOUT = "timeout"; + +export function getTimeoutSignal(timeoutMs: number): { signal: AbortSignal; abortId: NodeJS.Timeout } { + const controller = new AbortController(); + const abortId = setTimeout(() => controller.abort(TIMEOUT), timeoutMs); + return { signal: controller.signal, abortId }; +} + +/** + * Returns an abort signal that is getting aborted when + * at least one of the specified abort signals is aborted. + * + * Requires at least node.js 18. + */ +export function anySignal(...args: AbortSignal[] | [AbortSignal[]]): AbortSignal { + // Allowing signals to be passed either as array + // of signals or as multiple arguments. + const signals = (args.length === 1 && Array.isArray(args[0]) ? args[0] : args); + + const controller = new AbortController(); + + for (const signal of signals) { + if (signal.aborted) { + // Exiting early if one of the signals + // is already aborted. + controller.abort((signal as any)?.reason); + break; + } + + // Listening for signals and removing the listeners + // when at least one symbol is aborted. + signal.addEventListener("abort", () => controller.abort((signal as any)?.reason), { + signal: controller.signal, + }); + } + + return controller.signal; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts new file mode 100644 index 00000000000..4d7b7d52e8f --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper.ts @@ -0,0 +1,256 @@ +import type { Writable } from "readable-stream"; +import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; + +export class Node18UniversalStreamWrapper + implements + StreamWrapper | Writable | WritableStream, ReadFormat> +{ + private readableStream: ReadableStream; + private reader: ReadableStreamDefaultReader; + private events: Record; + private paused: boolean; + private resumeCallback: ((value?: unknown) => void) | null; + private encoding: string | null; + + constructor(readableStream: ReadableStream) { + this.readableStream = readableStream; + this.reader = this.readableStream.getReader(); + this.events = { + data: [], + end: [], + error: [], + readable: [], + close: [], + pause: [], + resume: [], + }; + this.paused = false; + this.resumeCallback = null; + this.encoding = null; + } + + public on(event: string, callback: EventCallback): void { + this.events[event]?.push(callback); + } + + public off(event: string, callback: EventCallback): void { + this.events[event] = this.events[event]?.filter((cb) => cb !== callback); + } + + public pipe( + dest: Node18UniversalStreamWrapper | Writable | WritableStream + ): Node18UniversalStreamWrapper | Writable | WritableStream { + this.on("data", async (chunk) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._write(chunk); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } else { + dest.write(chunk); + } + }); + + this.on("end", async () => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._end(); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.close(); + } else { + dest.end(); + } + }); + + this.on("error", async (error) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._error(error); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.abort(error); + } else { + dest.destroy(error); + } + }); + + this._startReading(); + + return dest; + } + + public pipeTo( + dest: Node18UniversalStreamWrapper | Writable | WritableStream + ): Node18UniversalStreamWrapper | Writable | WritableStream { + return this.pipe(dest); + } + + public unpipe(dest: Node18UniversalStreamWrapper | Writable | WritableStream): void { + this.off("data", async (chunk) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._write(chunk); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } else { + dest.write(chunk); + } + }); + + this.off("end", async () => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._end(); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.close(); + } else { + dest.end(); + } + }); + + this.off("error", async (error) => { + if (dest instanceof Node18UniversalStreamWrapper) { + dest._error(error); + } else if (dest instanceof WritableStream) { + const writer = dest.getWriter(); + writer.abort(error); + } else { + dest.destroy(error); + } + }); + } + + public destroy(error?: Error): void { + this.reader + .cancel(error) + .then(() => { + this._emit("close"); + }) + .catch((err) => { + this._emit("error", err); + }); + } + + public pause(): void { + this.paused = true; + this._emit("pause"); + } + + public resume(): void { + if (this.paused) { + this.paused = false; + this._emit("resume"); + if (this.resumeCallback) { + this.resumeCallback(); + this.resumeCallback = null; + } + } + } + + public get isPaused(): boolean { + return this.paused; + } + + public async read(): Promise { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + + if (done) { + return undefined; + } + return value; + } + + public setEncoding(encoding: string): void { + this.encoding = encoding; + } + + public async text(): Promise { + const chunks: ReadFormat[] = []; + + while (true) { + const { done, value } = await this.reader.read(); + if (done) { + break; + } + if (value) { + chunks.push(value); + } + } + + const decoder = new TextDecoder(this.encoding || "utf-8"); + return decoder.decode(await new Blob(chunks).arrayBuffer()); + } + + public async json(): Promise { + const text = await this.text(); + return JSON.parse(text); + } + + private _write(chunk: ReadFormat): void { + this._emit("data", chunk); + } + + private _end(): void { + this._emit("end"); + } + + private _error(error: any): void { + this._emit("error", error); + } + + private _emit(event: string, data?: any): void { + if (this.events[event]) { + for (const callback of this.events[event] || []) { + callback(data); + } + } + } + + private async _startReading(): Promise { + try { + this._emit("readable"); + while (true) { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + this._emit("end"); + this._emit("close"); + break; + } + if (value) { + this._emit("data", value); + } + } + } catch (error) { + this._emit("error", error); + } + } + + [Symbol.asyncIterator](): AsyncIterableIterator { + return { + next: async () => { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return { done: true, value: undefined }; + } + return { done: false, value }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts new file mode 100644 index 00000000000..ba5f7276750 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/NodePre18StreamWrapper.ts @@ -0,0 +1,106 @@ +import type { Readable, Writable } from "readable-stream"; +import { EventCallback, StreamWrapper } from "./chooseStreamWrapper"; + +export class NodePre18StreamWrapper implements StreamWrapper { + private readableStream: Readable; + private encoding: string | undefined; + + constructor(readableStream: Readable) { + this.readableStream = readableStream; + } + + public on(event: string, callback: EventCallback): void { + this.readableStream.on(event, callback); + } + + public off(event: string, callback: EventCallback): void { + this.readableStream.off(event, callback); + } + + public pipe(dest: Writable): Writable { + this.readableStream.pipe(dest); + return dest; + } + + public pipeTo(dest: Writable): Writable { + return this.pipe(dest); + } + + public unpipe(dest?: Writable): void { + if (dest) { + this.readableStream.unpipe(dest); + } else { + this.readableStream.unpipe(); + } + } + + public destroy(error?: Error): void { + this.readableStream.destroy(error); + } + + public pause(): void { + this.readableStream.pause(); + } + + public resume(): void { + this.readableStream.resume(); + } + + public get isPaused(): boolean { + return this.readableStream.isPaused(); + } + + public async read(): Promise { + return new Promise((resolve, reject) => { + const chunk = this.readableStream.read(); + if (chunk) { + resolve(chunk); + } else { + this.readableStream.once("readable", () => { + const chunk = this.readableStream.read(); + resolve(chunk); + }); + this.readableStream.once("error", reject); + } + }); + } + + public setEncoding(encoding?: string): void { + this.readableStream.setEncoding(encoding as BufferEncoding); + this.encoding = encoding; + } + + public async text(): Promise { + const chunks: Uint8Array[] = []; + const encoder = new TextEncoder(); + this.readableStream.setEncoding((this.encoding || "utf-8") as BufferEncoding); + + for await (const chunk of this.readableStream) { + chunks.push(encoder.encode(chunk)); + } + + const decoder = new TextDecoder(this.encoding || "utf-8"); + return decoder.decode(Buffer.concat(chunks)); + } + + public async json(): Promise { + const text = await this.text(); + return JSON.parse(text); + } + + public [Symbol.asyncIterator](): AsyncIterableIterator { + const readableStream = this.readableStream; + const iterator = readableStream[Symbol.asyncIterator](); + + // Create and return an async iterator that yields buffers + return { + async next(): Promise> { + const { value, done } = await iterator.next(); + return { value: value as Buffer, done }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts new file mode 100644 index 00000000000..263af00911f --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/UndiciStreamWrapper.ts @@ -0,0 +1,243 @@ +import { StreamWrapper } from "./chooseStreamWrapper"; + +type EventCallback = (data?: any) => void; + +export class UndiciStreamWrapper + implements StreamWrapper | WritableStream, ReadFormat> +{ + private readableStream: ReadableStream; + private reader: ReadableStreamDefaultReader; + private events: Record; + private paused: boolean; + private resumeCallback: ((value?: unknown) => void) | null; + private encoding: string | null; + + constructor(readableStream: ReadableStream) { + this.readableStream = readableStream; + this.reader = this.readableStream.getReader(); + this.events = { + data: [], + end: [], + error: [], + readable: [], + close: [], + pause: [], + resume: [], + }; + this.paused = false; + this.resumeCallback = null; + this.encoding = null; + } + + public on(event: string, callback: EventCallback): void { + this.events[event]?.push(callback); + } + + public off(event: string, callback: EventCallback): void { + this.events[event] = this.events[event]?.filter((cb) => cb !== callback); + } + + public pipe( + dest: UndiciStreamWrapper | WritableStream + ): UndiciStreamWrapper | WritableStream { + this.on("data", (chunk) => { + if (dest instanceof UndiciStreamWrapper) { + dest._write(chunk); + } else { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } + }); + + this.on("end", () => { + if (dest instanceof UndiciStreamWrapper) { + dest._end(); + } else { + const writer = dest.getWriter(); + writer.close(); + } + }); + + this.on("error", (error) => { + if (dest instanceof UndiciStreamWrapper) { + dest._error(error); + } else { + const writer = dest.getWriter(); + writer.abort(error); + } + }); + + this._startReading(); + + return dest; + } + + public pipeTo( + dest: UndiciStreamWrapper | WritableStream + ): UndiciStreamWrapper | WritableStream { + return this.pipe(dest); + } + + public unpipe(dest: UndiciStreamWrapper | WritableStream): void { + this.off("data", (chunk) => { + if (dest instanceof UndiciStreamWrapper) { + dest._write(chunk); + } else { + const writer = dest.getWriter(); + writer.write(chunk).then(() => writer.releaseLock()); + } + }); + + this.off("end", () => { + if (dest instanceof UndiciStreamWrapper) { + dest._end(); + } else { + const writer = dest.getWriter(); + writer.close(); + } + }); + + this.off("error", (error) => { + if (dest instanceof UndiciStreamWrapper) { + dest._error(error); + } else { + const writer = dest.getWriter(); + writer.abort(error); + } + }); + } + + public destroy(error?: Error): void { + this.reader + .cancel(error) + .then(() => { + this._emit("close"); + }) + .catch((err) => { + this._emit("error", err); + }); + } + + public pause(): void { + this.paused = true; + this._emit("pause"); + } + + public resume(): void { + if (this.paused) { + this.paused = false; + this._emit("resume"); + if (this.resumeCallback) { + this.resumeCallback(); + this.resumeCallback = null; + } + } + } + + public get isPaused(): boolean { + return this.paused; + } + + public async read(): Promise { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return undefined; + } + return value; + } + + public setEncoding(encoding: string): void { + this.encoding = encoding; + } + + public async text(): Promise { + const chunks: BlobPart[] = []; + + while (true) { + const { done, value } = await this.reader.read(); + if (done) { + break; + } + if (value) { + chunks.push(value); + } + } + + const decoder = new TextDecoder(this.encoding || "utf-8"); + return decoder.decode(await new Blob(chunks).arrayBuffer()); + } + + public async json(): Promise { + const text = await this.text(); + return JSON.parse(text); + } + + private _write(chunk: ReadFormat): void { + this._emit("data", chunk); + } + + private _end(): void { + this._emit("end"); + } + + private _error(error: any): void { + this._emit("error", error); + } + + private _emit(event: string, data?: any): void { + if (this.events[event]) { + for (const callback of this.events[event] || []) { + callback(data); + } + } + } + + private async _startReading(): Promise { + try { + this._emit("readable"); + while (true) { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + this._emit("end"); + this._emit("close"); + break; + } + if (value) { + this._emit("data", value); + } + } + } catch (error) { + this._emit("error", error); + } + } + + [Symbol.asyncIterator](): AsyncIterableIterator { + return { + next: async () => { + if (this.paused) { + await new Promise((resolve) => { + this.resumeCallback = resolve; + }); + } + const { done, value } = await this.reader.read(); + if (done) { + return { done: true, value: undefined }; + } + return { done: false, value }; + }, + [Symbol.asyncIterator]() { + return this; + }, + }; + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts new file mode 100644 index 00000000000..2abd6b2ba1c --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/fetcher/stream-wrappers/chooseStreamWrapper.ts @@ -0,0 +1,33 @@ +import type { Readable } from "readable-stream"; +import { RUNTIME } from "../../runtime"; + +export type EventCallback = (data?: any) => void; + +export interface StreamWrapper { + setEncoding(encoding?: string): void; + on(event: string, callback: EventCallback): void; + off(event: string, callback: EventCallback): void; + pipe(dest: WritableStream): WritableStream; + pipeTo(dest: WritableStream): WritableStream; + unpipe(dest?: WritableStream): void; + destroy(error?: Error): void; + pause(): void; + resume(): void; + get isPaused(): boolean; + read(): Promise; + text(): Promise; + json(): Promise; + [Symbol.asyncIterator](): AsyncIterableIterator; +} + +export async function chooseStreamWrapper(responseBody: any): Promise>> { + if (RUNTIME.type === "node" && RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { + return new (await import("./Node18UniversalStreamWrapper")).Node18UniversalStreamWrapper( + responseBody as ReadableStream + ); + } else if (RUNTIME.type !== "node" && typeof fetch === "function") { + return new (await import("./UndiciStreamWrapper")).UndiciStreamWrapper(responseBody as ReadableStream); + } else { + return new (await import("./NodePre18StreamWrapper")).NodePre18StreamWrapper(responseBody as Readable); + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/index.ts b/seed/ts-sdk/inline-types/no-inline/src/core/index.ts new file mode 100644 index 00000000000..000107d9932 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/index.ts @@ -0,0 +1,2 @@ +export * from "./fetcher"; +export * from "./runtime"; diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/runtime/index.ts b/seed/ts-sdk/inline-types/no-inline/src/core/runtime/index.ts new file mode 100644 index 00000000000..5c76dbb133f --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/runtime/index.ts @@ -0,0 +1 @@ +export { RUNTIME } from "./runtime"; diff --git a/seed/ts-sdk/inline-types/no-inline/src/core/runtime/runtime.ts b/seed/ts-sdk/inline-types/no-inline/src/core/runtime/runtime.ts new file mode 100644 index 00000000000..4d0687e8eb4 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/core/runtime/runtime.ts @@ -0,0 +1,126 @@ +interface DenoGlobal { + version: { + deno: string; + }; +} + +interface BunGlobal { + version: string; +} + +declare const Deno: DenoGlobal; +declare const Bun: BunGlobal; + +/** + * A constant that indicates whether the environment the code is running is a Web Browser. + */ +const isBrowser = typeof window !== "undefined" && typeof window.document !== "undefined"; + +/** + * A constant that indicates whether the environment the code is running is a Web Worker. + */ +const isWebWorker = + typeof self === "object" && + // @ts-ignore + typeof self?.importScripts === "function" && + (self.constructor?.name === "DedicatedWorkerGlobalScope" || + self.constructor?.name === "ServiceWorkerGlobalScope" || + self.constructor?.name === "SharedWorkerGlobalScope"); + +/** + * A constant that indicates whether the environment the code is running is Deno. + */ +const isDeno = + typeof Deno !== "undefined" && typeof Deno.version !== "undefined" && typeof Deno.version.deno !== "undefined"; + +/** + * A constant that indicates whether the environment the code is running is Bun.sh. + */ +const isBun = typeof Bun !== "undefined" && typeof Bun.version !== "undefined"; + +/** + * A constant that indicates whether the environment the code is running is Node.JS. + */ +const isNode = + typeof process !== "undefined" && + Boolean(process.version) && + Boolean(process.versions?.node) && + // Deno spoofs process.versions.node, see https://deno.land/std@0.177.0/node/process.ts?s=versions + !isDeno && + !isBun; + +/** + * A constant that indicates whether the environment the code is running is in React-Native. + * https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Core/setUpNavigator.js + */ +const isReactNative = typeof navigator !== "undefined" && navigator?.product === "ReactNative"; + +/** + * A constant that indicates whether the environment the code is running is Cloudflare. + * https://developers.cloudflare.com/workers/runtime-apis/web-standards/#navigatoruseragent + */ +const isCloudflare = typeof globalThis !== "undefined" && globalThis?.navigator?.userAgent === "Cloudflare-Workers"; + +/** + * A constant that indicates which environment and version the SDK is running in. + */ +export const RUNTIME: Runtime = evaluateRuntime(); + +export interface Runtime { + type: "browser" | "web-worker" | "deno" | "bun" | "node" | "react-native" | "unknown" | "workerd"; + version?: string; + parsedVersion?: number; +} + +function evaluateRuntime(): Runtime { + if (isBrowser) { + return { + type: "browser", + version: window.navigator.userAgent, + }; + } + + if (isCloudflare) { + return { + type: "workerd", + }; + } + + if (isWebWorker) { + return { + type: "web-worker", + }; + } + + if (isDeno) { + return { + type: "deno", + version: Deno.version.deno, + }; + } + + if (isBun) { + return { + type: "bun", + version: Bun.version, + }; + } + + if (isNode) { + return { + type: "node", + version: process.versions.node, + parsedVersion: Number(process.versions.node.split(".")[0]), + }; + } + + if (isReactNative) { + return { + type: "react-native", + }; + } + + return { + type: "unknown", + }; +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/errors/SeedObjectError.ts b/seed/ts-sdk/inline-types/no-inline/src/errors/SeedObjectError.ts new file mode 100644 index 00000000000..489ad43d19e --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/errors/SeedObjectError.ts @@ -0,0 +1,45 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export class SeedObjectError extends Error { + readonly statusCode?: number; + readonly body?: unknown; + + constructor({ message, statusCode, body }: { message?: string; statusCode?: number; body?: unknown }) { + super(buildMessage({ message, statusCode, body })); + Object.setPrototypeOf(this, SeedObjectError.prototype); + if (statusCode != null) { + this.statusCode = statusCode; + } + + if (body !== undefined) { + this.body = body; + } + } +} + +function buildMessage({ + message, + statusCode, + body, +}: { + message: string | undefined; + statusCode: number | undefined; + body: unknown | undefined; +}): string { + let lines: string[] = []; + if (message != null) { + lines.push(message); + } + + if (statusCode != null) { + lines.push(`Status code: ${statusCode.toString()}`); + } + + if (body != null) { + lines.push(`Body: ${JSON.stringify(body, undefined, 2)}`); + } + + return lines.join("\n"); +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/errors/SeedObjectTimeoutError.ts b/seed/ts-sdk/inline-types/no-inline/src/errors/SeedObjectTimeoutError.ts new file mode 100644 index 00000000000..27e69eb189f --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/errors/SeedObjectTimeoutError.ts @@ -0,0 +1,10 @@ +/** + * This file was auto-generated by Fern from our API Definition. + */ + +export class SeedObjectTimeoutError extends Error { + constructor(message: string) { + super(message); + Object.setPrototypeOf(this, SeedObjectTimeoutError.prototype); + } +} diff --git a/seed/ts-sdk/inline-types/no-inline/src/errors/index.ts b/seed/ts-sdk/inline-types/no-inline/src/errors/index.ts new file mode 100644 index 00000000000..c41ddbbfd72 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/errors/index.ts @@ -0,0 +1,2 @@ +export { SeedObjectError } from "./SeedObjectError"; +export { SeedObjectTimeoutError } from "./SeedObjectTimeoutError"; diff --git a/seed/ts-sdk/inline-types/no-inline/src/index.ts b/seed/ts-sdk/inline-types/no-inline/src/index.ts new file mode 100644 index 00000000000..bbb7c569b72 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/index.ts @@ -0,0 +1,3 @@ +export * as SeedObject from "./api"; +export { SeedObjectClient } from "./Client"; +export { SeedObjectError, SeedObjectTimeoutError } from "./errors"; diff --git a/seed/ts-sdk/inline-types/no-inline/src/version.ts b/seed/ts-sdk/inline-types/no-inline/src/version.ts new file mode 100644 index 00000000000..b643a3e3ea2 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/src/version.ts @@ -0,0 +1 @@ +export const SDK_VERSION = "0.0.1"; diff --git a/seed/ts-sdk/inline-types/no-inline/tests/custom.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/custom.test.ts new file mode 100644 index 00000000000..7f5e031c839 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/custom.test.ts @@ -0,0 +1,13 @@ +/** + * This is a custom test file, if you wish to add more tests + * to your SDK. + * Be sure to mark this file in `.fernignore`. + * + * If you include example requests/responses in your fern definition, + * you will have tests automatically generated for you. + */ +describe("test", () => { + it("default", () => { + expect(true).toBe(true); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/Fetcher.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/Fetcher.test.ts new file mode 100644 index 00000000000..ff8042175ff --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/Fetcher.test.ts @@ -0,0 +1,73 @@ +import fs from "fs"; +import { Fetcher, fetcherImpl } from "../../../src/core/fetcher/Fetcher"; +import { join } from "path"; + +describe("Test fetcherImpl", () => { + it("should handle successful request", async () => { + const mockArgs: Fetcher.Args = { + url: "https://httpbin.org/post", + method: "POST", + headers: { "X-Test": "x-test-header" }, + body: { data: "test" }, + contentType: "application/json", + requestType: "json", + }; + + global.fetch = jest.fn().mockResolvedValue({ + ok: true, + status: 200, + text: () => Promise.resolve(JSON.stringify({ data: "test" })), + json: () => ({ data: "test" }), + }); + + const result = await fetcherImpl(mockArgs); + expect(result.ok).toBe(true); + if (result.ok) { + expect(result.body).toEqual({ data: "test" }); + } + + expect(global.fetch).toHaveBeenCalledWith( + "https://httpbin.org/post", + expect.objectContaining({ + method: "POST", + headers: expect.objectContaining({ "X-Test": "x-test-header" }), + body: JSON.stringify({ data: "test" }), + }) + ); + }); + + it("should send octet stream", async () => { + const url = "https://httpbin.org/post/file"; + const mockArgs: Fetcher.Args = { + url, + method: "POST", + headers: { "X-Test": "x-test-header" }, + contentType: "application/octet-stream", + requestType: "bytes", + duplex: "half", + body: fs.createReadStream(join(__dirname, "test-file.txt")), + }; + + global.fetch = jest.fn().mockResolvedValue({ + ok: true, + status: 200, + text: () => Promise.resolve(JSON.stringify({ data: "test" })), + json: () => Promise.resolve({ data: "test" }), + }); + + const result = await fetcherImpl(mockArgs); + + expect(global.fetch).toHaveBeenCalledWith( + url, + expect.objectContaining({ + method: "POST", + headers: expect.objectContaining({ "X-Test": "x-test-header" }), + body: expect.any(fs.ReadStream), + }) + ); + expect(result.ok).toBe(true); + if (result.ok) { + expect(result.body).toEqual({ data: "test" }); + } + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/createRequestUrl.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/createRequestUrl.test.ts new file mode 100644 index 00000000000..f2cd24b6721 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/createRequestUrl.test.ts @@ -0,0 +1,51 @@ +import { createRequestUrl } from "../../../src/core/fetcher/createRequestUrl"; + +describe("Test createRequestUrl", () => { + it("should return the base URL when no query parameters are provided", () => { + const baseUrl = "https://api.example.com"; + expect(createRequestUrl(baseUrl)).toBe(baseUrl); + }); + + it("should append simple query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { key: "value", another: "param" }; + expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?key=value&another=param"); + }); + + it("should handle array query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { items: ["a", "b", "c"] }; + expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?items=a&items=b&items=c"); + }); + + it("should handle object query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { filter: { name: "John", age: 30 } }; + expect(createRequestUrl(baseUrl, queryParams)).toBe( + "https://api.example.com?filter%5Bname%5D=John&filter%5Bage%5D=30" + ); + }); + + it("should handle mixed types of query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { + simple: "value", + array: ["x", "y"], + object: { key: "value" }, + }; + expect(createRequestUrl(baseUrl, queryParams)).toBe( + "https://api.example.com?simple=value&array=x&array=y&object%5Bkey%5D=value" + ); + }); + + it("should handle empty query parameters object", () => { + const baseUrl = "https://api.example.com"; + expect(createRequestUrl(baseUrl, {})).toBe(baseUrl); + }); + + it("should encode special characters in query parameters", () => { + const baseUrl = "https://api.example.com"; + const queryParams = { special: "a&b=c d" }; + expect(createRequestUrl(baseUrl, queryParams)).toBe("https://api.example.com?special=a%26b%3Dc%20d"); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/getFetchFn.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/getFetchFn.test.ts new file mode 100644 index 00000000000..9b315ad095a --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/getFetchFn.test.ts @@ -0,0 +1,22 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { getFetchFn } from "../../../src/core/fetcher/getFetchFn"; + +describe("Test for getFetchFn", () => { + it("should get node-fetch function", async () => { + if (RUNTIME.type == "node") { + if (RUNTIME.parsedVersion != null && RUNTIME.parsedVersion >= 18) { + expect(await getFetchFn()).toBe(fetch); + } else { + expect(await getFetchFn()).toEqual((await import("node-fetch")).default as any); + } + } + }); + + it("should get fetch function", async () => { + if (RUNTIME.type == "browser") { + const fetchFn = await getFetchFn(); + expect(typeof fetchFn).toBe("function"); + expect(fetchFn.name).toBe("fetch"); + } + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/getRequestBody.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/getRequestBody.test.ts new file mode 100644 index 00000000000..919604c2e12 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/getRequestBody.test.ts @@ -0,0 +1,77 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { getRequestBody } from "../../../src/core/fetcher/getRequestBody"; + +describe("Test getRequestBody", () => { + it("should return FormData as is in Node environment", async () => { + if (RUNTIME.type === "node") { + const formData = new (await import("formdata-node")).FormData(); + formData.append("key", "value"); + const result = await getRequestBody({ + body: formData, + type: "file", + }); + expect(result).toBe(formData); + } + }); + + it("should stringify body if not FormData in Node environment", async () => { + if (RUNTIME.type === "node") { + const body = { key: "value" }; + const result = await getRequestBody({ + body, + type: "json", + }); + expect(result).toBe('{"key":"value"}'); + } + }); + + it("should return FormData in browser environment", async () => { + if (RUNTIME.type === "browser") { + const formData = new (await import("form-data")).default(); + formData.append("key", "value"); + const result = await getRequestBody({ + body: formData, + type: "file", + }); + expect(result).toBe(formData); + } + }); + + it("should stringify body if not FormData in browser environment", async () => { + if (RUNTIME.type === "browser") { + const body = { key: "value" }; + const result = await getRequestBody({ + body, + type: "json", + }); + expect(result).toBe('{"key":"value"}'); + } + }); + + it("should return the Uint8Array", async () => { + const input = new Uint8Array([1, 2, 3]); + const result = await getRequestBody({ + body: input, + type: "bytes", + }); + expect(result).toBe(input); + }); + + it("should return the input for content-type 'application/x-www-form-urlencoded'", async () => { + const input = "key=value&another=param"; + const result = await getRequestBody({ + body: input, + type: "other", + }); + expect(result).toBe(input); + }); + + it("should JSON stringify objects", async () => { + const input = { key: "value" }; + const result = await getRequestBody({ + body: input, + type: "json", + }); + expect(result).toBe('{"key":"value"}'); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/getResponseBody.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/getResponseBody.test.ts new file mode 100644 index 00000000000..1030c517ced --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/getResponseBody.test.ts @@ -0,0 +1,64 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { getResponseBody } from "../../../src/core/fetcher/getResponseBody"; +import { chooseStreamWrapper } from "../../../src/core/fetcher/stream-wrappers/chooseStreamWrapper"; + +describe("Test getResponseBody", () => { + it("should handle blob response type", async () => { + const mockBlob = new Blob(["test"], { type: "text/plain" }); + const mockResponse = new Response(mockBlob); + const result = await getResponseBody(mockResponse, "blob"); + // @ts-expect-error + expect(result.constructor.name).toBe("Blob"); + }); + + it("should handle sse response type", async () => { + if (RUNTIME.type === "node") { + const mockStream = new ReadableStream(); + const mockResponse = new Response(mockStream); + const result = await getResponseBody(mockResponse, "sse"); + expect(result).toBe(mockStream); + } + }); + + it("should handle streaming response type", async () => { + if (RUNTIME.type === "node") { + const mockStream = new ReadableStream(); + const mockResponse = new Response(mockStream); + const result = await getResponseBody(mockResponse, "streaming"); + // need to reinstantiate string as a result of locked state in Readable Stream after registration with Response + expect(JSON.stringify(result)).toBe(JSON.stringify(await chooseStreamWrapper(new ReadableStream()))); + } + }); + + it("should handle text response type", async () => { + const mockResponse = new Response("test text"); + const result = await getResponseBody(mockResponse, "text"); + expect(result).toBe("test text"); + }); + + it("should handle JSON response", async () => { + const mockJson = { key: "value" }; + const mockResponse = new Response(JSON.stringify(mockJson)); + const result = await getResponseBody(mockResponse); + expect(result).toEqual(mockJson); + }); + + it("should handle empty response", async () => { + const mockResponse = new Response(""); + const result = await getResponseBody(mockResponse); + expect(result).toBeUndefined(); + }); + + it("should handle non-JSON response", async () => { + const mockResponse = new Response("invalid json"); + const result = await getResponseBody(mockResponse); + expect(result).toEqual({ + ok: false, + error: { + reason: "non-json", + statusCode: 200, + rawBody: "invalid json", + }, + }); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/makeRequest.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/makeRequest.test.ts new file mode 100644 index 00000000000..be94ab45f10 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/makeRequest.test.ts @@ -0,0 +1,54 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { makeRequest } from "../../../src/core/fetcher/makeRequest"; + +describe("Test makeRequest", () => { + const mockPostUrl = "https://httpbin.org/post"; + const mockGetUrl = "https://httpbin.org/get"; + const mockHeaders = { "Content-Type": "application/json" }; + const mockBody = JSON.stringify({ key: "value" }); + + let mockFetch: jest.Mock; + + beforeEach(() => { + mockFetch = jest.fn(); + mockFetch.mockResolvedValue(new Response(JSON.stringify({ test: "successful" }), { status: 200 })); + }); + + it("should handle POST request correctly", async () => { + const response = await makeRequest(mockFetch, mockPostUrl, "POST", mockHeaders, mockBody); + const responseBody = await response.json(); + expect(responseBody).toEqual({ test: "successful" }); + expect(mockFetch).toHaveBeenCalledTimes(1); + const [calledUrl, calledOptions] = mockFetch.mock.calls[0]; + expect(calledUrl).toBe(mockPostUrl); + expect(calledOptions).toEqual( + expect.objectContaining({ + method: "POST", + headers: mockHeaders, + body: mockBody, + credentials: undefined, + }) + ); + expect(calledOptions.signal).toBeDefined(); + expect(calledOptions.signal).toBeInstanceOf(AbortSignal); + }); + + it("should handle GET request correctly", async () => { + const response = await makeRequest(mockFetch, mockGetUrl, "GET", mockHeaders, undefined); + const responseBody = await response.json(); + expect(responseBody).toEqual({ test: "successful" }); + expect(mockFetch).toHaveBeenCalledTimes(1); + const [calledUrl, calledOptions] = mockFetch.mock.calls[0]; + expect(calledUrl).toBe(mockGetUrl); + expect(calledOptions).toEqual( + expect.objectContaining({ + method: "GET", + headers: mockHeaders, + body: undefined, + credentials: undefined, + }) + ); + expect(calledOptions.signal).toBeDefined(); + expect(calledOptions.signal).toBeInstanceOf(AbortSignal); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/requestWithRetries.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/requestWithRetries.test.ts new file mode 100644 index 00000000000..6f77f093edf --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/requestWithRetries.test.ts @@ -0,0 +1,133 @@ +import { RUNTIME } from "../../../src/core/runtime"; +import { requestWithRetries } from "../../../src/core/fetcher/requestWithRetries"; + +describe("requestWithRetries", () => { + let mockFetch: jest.Mock; + let originalMathRandom: typeof Math.random; + let setTimeoutSpy: jest.SpyInstance; + + beforeEach(() => { + mockFetch = jest.fn(); + originalMathRandom = Math.random; + + // Mock Math.random for consistent jitter + Math.random = jest.fn(() => 0.5); + + jest.useFakeTimers({ doNotFake: ["nextTick"] }); + }); + + afterEach(() => { + Math.random = originalMathRandom; + jest.clearAllMocks(); + jest.clearAllTimers(); + }); + + it("should retry on retryable status codes", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + const retryableStatuses = [408, 409, 429, 500, 502]; + let callCount = 0; + + mockFetch.mockImplementation(async () => { + if (callCount < retryableStatuses.length) { + return new Response("", { status: retryableStatuses[callCount++] }); + } + return new Response("", { status: 200 }); + }); + + const responsePromise = requestWithRetries(() => mockFetch(), retryableStatuses.length); + await jest.runAllTimersAsync(); + const response = await responsePromise; + + expect(mockFetch).toHaveBeenCalledTimes(retryableStatuses.length + 1); + expect(response.status).toBe(200); + }); + + it("should respect maxRetries limit", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + const maxRetries = 2; + mockFetch.mockResolvedValue(new Response("", { status: 500 })); + + const responsePromise = requestWithRetries(() => mockFetch(), maxRetries); + await jest.runAllTimersAsync(); + const response = await responsePromise; + + expect(mockFetch).toHaveBeenCalledTimes(maxRetries + 1); + expect(response.status).toBe(500); + }); + + it("should not retry on success status codes", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + const successStatuses = [200, 201, 202]; + + for (const status of successStatuses) { + mockFetch.mockReset(); + setTimeoutSpy.mockClear(); + mockFetch.mockResolvedValueOnce(new Response("", { status })); + + const responsePromise = requestWithRetries(() => mockFetch(), 3); + await jest.runAllTimersAsync(); + await responsePromise; + + expect(mockFetch).toHaveBeenCalledTimes(1); + expect(setTimeoutSpy).not.toHaveBeenCalled(); + } + }); + + it("should apply correct exponential backoff with jitter", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + mockFetch.mockResolvedValue(new Response("", { status: 500 })); + const maxRetries = 3; + const expectedDelays = [1000, 2000, 4000]; + + const responsePromise = requestWithRetries(() => mockFetch(), maxRetries); + await jest.runAllTimersAsync(); + await responsePromise; + + // Verify setTimeout calls + expect(setTimeoutSpy).toHaveBeenCalledTimes(expectedDelays.length); + + expectedDelays.forEach((delay, index) => { + expect(setTimeoutSpy).toHaveBeenNthCalledWith(index + 1, expect.any(Function), delay); + }); + + expect(mockFetch).toHaveBeenCalledTimes(maxRetries + 1); + }); + + it("should handle concurrent retries independently", async () => { + setTimeoutSpy = jest.spyOn(global, "setTimeout").mockImplementation((callback) => { + process.nextTick(callback); + return null as any; + }); + + mockFetch + .mockResolvedValueOnce(new Response("", { status: 500 })) + .mockResolvedValueOnce(new Response("", { status: 500 })) + .mockResolvedValueOnce(new Response("", { status: 200 })) + .mockResolvedValueOnce(new Response("", { status: 200 })); + + const promise1 = requestWithRetries(() => mockFetch(), 1); + const promise2 = requestWithRetries(() => mockFetch(), 1); + + await jest.runAllTimersAsync(); + const [response1, response2] = await Promise.all([promise1, promise2]); + + expect(response1.status).toBe(200); + expect(response2.status).toBe(200); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/signals.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/signals.test.ts new file mode 100644 index 00000000000..9cabfa07447 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/signals.test.ts @@ -0,0 +1,69 @@ +import { anySignal, getTimeoutSignal } from "../../../src/core/fetcher/signals"; + +describe("Test getTimeoutSignal", () => { + beforeEach(() => { + jest.useFakeTimers(); + }); + + afterEach(() => { + jest.useRealTimers(); + }); + + it("should return an object with signal and abortId", () => { + const { signal, abortId } = getTimeoutSignal(1000); + + expect(signal).toBeDefined(); + expect(abortId).toBeDefined(); + expect(signal).toBeInstanceOf(AbortSignal); + expect(signal.aborted).toBe(false); + }); + + it("should create a signal that aborts after the specified timeout", () => { + const timeoutMs = 5000; + const { signal } = getTimeoutSignal(timeoutMs); + + expect(signal.aborted).toBe(false); + + jest.advanceTimersByTime(timeoutMs - 1); + expect(signal.aborted).toBe(false); + + jest.advanceTimersByTime(1); + expect(signal.aborted).toBe(true); + }); +}); + +describe("Test anySignal", () => { + it("should return an AbortSignal", () => { + const signal = anySignal(new AbortController().signal); + expect(signal).toBeInstanceOf(AbortSignal); + }); + + it("should abort when any of the input signals is aborted", () => { + const controller1 = new AbortController(); + const controller2 = new AbortController(); + const signal = anySignal(controller1.signal, controller2.signal); + + expect(signal.aborted).toBe(false); + controller1.abort(); + expect(signal.aborted).toBe(true); + }); + + it("should handle an array of signals", () => { + const controller1 = new AbortController(); + const controller2 = new AbortController(); + const signal = anySignal([controller1.signal, controller2.signal]); + + expect(signal.aborted).toBe(false); + controller2.abort(); + expect(signal.aborted).toBe(true); + }); + + it("should abort immediately if one of the input signals is already aborted", () => { + const controller1 = new AbortController(); + const controller2 = new AbortController(); + controller1.abort(); + + const signal = anySignal(controller1.signal, controller2.signal); + expect(signal.aborted).toBe(true); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts new file mode 100644 index 00000000000..1dc9be0cc0e --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/Node18UniversalStreamWrapper.test.ts @@ -0,0 +1,178 @@ +import { Node18UniversalStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper"; + +describe("Node18UniversalStreamWrapper", () => { + it("should set encoding to utf-8", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const setEncodingSpy = jest.spyOn(stream, "setEncoding"); + + stream.setEncoding("utf-8"); + + expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); + }); + + it("should register an event listener for readable", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const onSpy = jest.spyOn(stream, "on"); + + stream.on("readable", () => {}); + + expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); + }); + + it("should remove an event listener for data", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const offSpy = jest.spyOn(stream, "off"); + + const fn = () => {}; + stream.on("data", fn); + stream.off("data", fn); + + expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); + }); + + it("should write to dest when calling pipe to writable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + const dest = new WritableStream({ + write(chunk) { + expect(chunk).toEqual(new TextEncoder().encode("test")); + }, + }); + + stream.pipe(dest); + }); + + it("should write to dest when calling pipe to node writable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + const dest = new (await import("readable-stream")).Writable({ + write(chunk, encoding, callback) { + expect(chunk.toString()).toEqual("test"); + callback(); + }, + }); + + stream.pipe(dest); + }); + + it("should write nothing when calling pipe and unpipe", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + const buffer: Uint8Array[] = []; + const dest = new WritableStream({ + write(chunk) { + buffer.push(chunk); + }, + }); + + stream.pipe(dest); + stream.unpipe(dest); + expect(buffer).toEqual([]); + }); + + it("should destroy the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const destroySpy = jest.spyOn(stream, "destroy"); + + stream.destroy(); + + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should pause and resume the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new Node18UniversalStreamWrapper(rawStream); + const pauseSpy = jest.spyOn(stream, "pause"); + const resumeSpy = jest.spyOn(stream, "resume"); + + expect(stream.isPaused).toBe(false); + stream.pause(); + expect(stream.isPaused).toBe(true); + stream.resume(); + + expect(pauseSpy).toHaveBeenCalled(); + expect(resumeSpy).toHaveBeenCalled(); + }); + + it("should read the stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + }); + + it("should read the stream as text", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + + const data = await stream.text(); + + expect(data).toEqual("testtest"); + }); + + it("should read the stream as json", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode(JSON.stringify({ test: "test" }))); + controller.close(); + }, + }); + const stream = new Node18UniversalStreamWrapper(rawStream); + + const data = await stream.json(); + + expect(data).toEqual({ test: "test" }); + }); + + it("should allow use with async iteratable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + let data = ""; + const stream = new Node18UniversalStreamWrapper(rawStream); + for await (const chunk of stream) { + data += new TextDecoder().decode(chunk); + } + + expect(data).toEqual("testtest"); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts new file mode 100644 index 00000000000..0c99d3b2655 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/NodePre18StreamWrapper.test.ts @@ -0,0 +1,124 @@ +import { NodePre18StreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/NodePre18StreamWrapper"; + +describe("NodePre18StreamWrapper", () => { + it("should set encoding to utf-8", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const setEncodingSpy = jest.spyOn(stream, "setEncoding"); + + stream.setEncoding("utf-8"); + + expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); + }); + + it("should register an event listener for readable", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const onSpy = jest.spyOn(stream, "on"); + + stream.on("readable", () => {}); + + expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); + }); + + it("should remove an event listener for data", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const offSpy = jest.spyOn(stream, "off"); + + const fn = () => {}; + stream.on("data", fn); + stream.off("data", fn); + + expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); + }); + + it("should write to dest when calling pipe to node writable stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const dest = new (await import("readable-stream")).Writable({ + write(chunk, encoding, callback) { + expect(chunk.toString()).toEqual("test"); + callback(); + }, + }); + + stream.pipe(dest); + }); + + it("should write nothing when calling pipe and unpipe", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const buffer: Uint8Array[] = []; + const dest = new (await import("readable-stream")).Writable({ + write(chunk, encoding, callback) { + buffer.push(chunk); + callback(); + }, + }); + stream.pipe(dest); + stream.unpipe(); + + expect(buffer).toEqual([]); + }); + + it("should destroy the stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const destroySpy = jest.spyOn(stream, "destroy"); + + stream.destroy(); + + expect(destroySpy).toHaveBeenCalledWith(); + }); + + it("should pause the stream and resume", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + const pauseSpy = jest.spyOn(stream, "pause"); + + stream.pause(); + expect(stream.isPaused).toBe(true); + stream.resume(); + expect(stream.isPaused).toBe(false); + + expect(pauseSpy).toHaveBeenCalledWith(); + }); + + it("should read the stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + + expect(await stream.read()).toEqual("test"); + expect(await stream.read()).toEqual("test"); + }); + + it("should read the stream as text", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + const stream = new NodePre18StreamWrapper(rawStream); + + const data = await stream.text(); + + expect(data).toEqual("testtest"); + }); + + it("should read the stream as json", async () => { + const rawStream = (await import("readable-stream")).Readable.from([JSON.stringify({ test: "test" })]); + const stream = new NodePre18StreamWrapper(rawStream); + + const data = await stream.json(); + + expect(data).toEqual({ test: "test" }); + }); + + it("should allow use with async iteratable stream", async () => { + const rawStream = (await import("readable-stream")).Readable.from(["test", "test"]); + let data = ""; + const stream = new NodePre18StreamWrapper(rawStream); + for await (const chunk of stream) { + data += chunk; + } + + expect(data).toEqual("testtest"); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts new file mode 100644 index 00000000000..1d171ce6c67 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/UndiciStreamWrapper.test.ts @@ -0,0 +1,153 @@ +import { UndiciStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/UndiciStreamWrapper"; + +describe("UndiciStreamWrapper", () => { + it("should set encoding to utf-8", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const setEncodingSpy = jest.spyOn(stream, "setEncoding"); + + stream.setEncoding("utf-8"); + + expect(setEncodingSpy).toHaveBeenCalledWith("utf-8"); + }); + + it("should register an event listener for readable", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const onSpy = jest.spyOn(stream, "on"); + + stream.on("readable", () => {}); + + expect(onSpy).toHaveBeenCalledWith("readable", expect.any(Function)); + }); + + it("should remove an event listener for data", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const offSpy = jest.spyOn(stream, "off"); + + const fn = () => {}; + stream.on("data", fn); + stream.off("data", fn); + + expect(offSpy).toHaveBeenCalledWith("data", expect.any(Function)); + }); + + it("should write to dest when calling pipe to writable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + const dest = new WritableStream({ + write(chunk) { + expect(chunk).toEqual(new TextEncoder().encode("test")); + }, + }); + + stream.pipe(dest); + }); + + it("should write nothing when calling pipe and unpipe", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const buffer: Uint8Array[] = []; + const dest = new WritableStream({ + write(chunk) { + buffer.push(chunk); + }, + }); + stream.pipe(dest); + stream.unpipe(dest); + + expect(buffer).toEqual([]); + }); + + it("should destroy the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const destroySpy = jest.spyOn(stream, "destroy"); + + stream.destroy(); + + expect(destroySpy).toHaveBeenCalled(); + }); + + it("should pause and resume the stream", async () => { + const rawStream = new ReadableStream(); + const stream = new UndiciStreamWrapper(rawStream); + const pauseSpy = jest.spyOn(stream, "pause"); + const resumeSpy = jest.spyOn(stream, "resume"); + + expect(stream.isPaused).toBe(false); + stream.pause(); + expect(stream.isPaused).toBe(true); + stream.resume(); + + expect(pauseSpy).toHaveBeenCalled(); + expect(resumeSpy).toHaveBeenCalled(); + }); + + it("should read the stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + expect(await stream.read()).toEqual(new TextEncoder().encode("test")); + }); + + it("should read the stream as text", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + + const data = await stream.text(); + + expect(data).toEqual("testtest"); + }); + + it("should read the stream as json", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode(JSON.stringify({ test: "test" }))); + controller.close(); + }, + }); + const stream = new UndiciStreamWrapper(rawStream); + + const data = await stream.json(); + + expect(data).toEqual({ test: "test" }); + }); + + it("should allow use with async iteratable stream", async () => { + const rawStream = new ReadableStream({ + start(controller) { + controller.enqueue(new TextEncoder().encode("test")); + controller.enqueue(new TextEncoder().encode("test")); + controller.close(); + }, + }); + let data = ""; + const stream = new UndiciStreamWrapper(rawStream); + for await (const chunk of stream) { + data += new TextDecoder().decode(chunk); + } + + expect(data).toEqual("testtest"); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts new file mode 100644 index 00000000000..17cf37a2f7f --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/chooseStreamWrapper.test.ts @@ -0,0 +1,43 @@ +import { RUNTIME } from "../../../../src/core/runtime"; +import { chooseStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/chooseStreamWrapper"; +import { Node18UniversalStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/Node18UniversalStreamWrapper"; +import { NodePre18StreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/NodePre18StreamWrapper"; +import { UndiciStreamWrapper } from "../../../../src/core/fetcher/stream-wrappers/UndiciStreamWrapper"; + +describe("chooseStreamWrapper", () => { + beforeEach(() => { + RUNTIME.type = "unknown"; + RUNTIME.parsedVersion = 0; + }); + + it('should return a Node18UniversalStreamWrapper when RUNTIME.type is "node" and RUNTIME.parsedVersion is not null and RUNTIME.parsedVersion is greater than or equal to 18', async () => { + const expected = new Node18UniversalStreamWrapper(new ReadableStream()); + RUNTIME.type = "node"; + RUNTIME.parsedVersion = 18; + + const result = await chooseStreamWrapper(new ReadableStream()); + + expect(JSON.stringify(result)).toBe(JSON.stringify(expected)); + }); + + it('should return a NodePre18StreamWrapper when RUNTIME.type is "node" and RUNTIME.parsedVersion is not null and RUNTIME.parsedVersion is less than 18', async () => { + const stream = await import("readable-stream"); + const expected = new NodePre18StreamWrapper(new stream.Readable()); + + RUNTIME.type = "node"; + RUNTIME.parsedVersion = 16; + + const result = await chooseStreamWrapper(new stream.Readable()); + + expect(JSON.stringify(result)).toEqual(JSON.stringify(expected)); + }); + + it('should return a Undici when RUNTIME.type is not "node"', async () => { + const expected = new UndiciStreamWrapper(new ReadableStream()); + RUNTIME.type = "browser"; + + const result = await chooseStreamWrapper(new ReadableStream()); + + expect(JSON.stringify(result)).toEqual(JSON.stringify(expected)); + }); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/webpack.test.ts b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/webpack.test.ts new file mode 100644 index 00000000000..557db6dc4ef --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/stream-wrappers/webpack.test.ts @@ -0,0 +1,38 @@ +import webpack from "webpack"; + +describe("test env compatibility", () => { + test("webpack", () => { + return new Promise((resolve, reject) => { + webpack( + { + mode: "production", + entry: "./src/index.ts", + module: { + rules: [ + { + test: /\.tsx?$/, + use: "ts-loader", + exclude: /node_modules/, + }, + ], + }, + resolve: { + extensions: [".tsx", ".ts", ".js"], + }, + }, + (err, stats) => { + try { + expect(err).toBe(null); + if (stats?.hasErrors()) { + console.log(stats?.toString()); + } + expect(stats?.hasErrors()).toBe(false); + resolve(); + } catch (error) { + reject(error); + } + } + ); + }); + }, 60_000); +}); diff --git a/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/test-file.txt b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/test-file.txt new file mode 100644 index 00000000000..c66d471e359 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tests/unit/fetcher/test-file.txt @@ -0,0 +1 @@ +This is a test file! diff --git a/seed/ts-sdk/inline-types/no-inline/tsconfig.json b/seed/ts-sdk/inline-types/no-inline/tsconfig.json new file mode 100644 index 00000000000..538c94fe015 --- /dev/null +++ b/seed/ts-sdk/inline-types/no-inline/tsconfig.json @@ -0,0 +1,17 @@ +{ + "compilerOptions": { + "extendedDiagnostics": true, + "strict": true, + "target": "ES6", + "module": "CommonJS", + "moduleResolution": "node", + "esModuleInterop": true, + "skipLibCheck": true, + "declaration": true, + "outDir": "dist", + "rootDir": "src", + "baseUrl": "src" + }, + "include": ["src"], + "exclude": [] +} diff --git a/seed/ts-sdk/literal/src/Client.ts b/seed/ts-sdk/literal/src/Client.ts index beae0adc7a1..fab963ef52a 100644 --- a/seed/ts-sdk/literal/src/Client.ts +++ b/seed/ts-sdk/literal/src/Client.ts @@ -35,34 +35,30 @@ export declare namespace SeedLiteralClient { } export class SeedLiteralClient { - constructor(protected readonly _options: SeedLiteralClient.Options) {} - protected _headers: Headers | undefined; + protected _inlined: Inlined | undefined; + protected _path: Path | undefined; + protected _query: Query | undefined; + protected _reference: Reference | undefined; + + constructor(protected readonly _options: SeedLiteralClient.Options) {} public get headers(): Headers { return (this._headers ??= new Headers(this._options)); } - protected _inlined: Inlined | undefined; - public get inlined(): Inlined { return (this._inlined ??= new Inlined(this._options)); } - protected _path: Path | undefined; - public get path(): Path { return (this._path ??= new Path(this._options)); } - protected _query: Query | undefined; - public get query(): Query { return (this._query ??= new Query(this._options)); } - protected _reference: Reference | undefined; - public get reference(): Reference { return (this._reference ??= new Reference(this._options)); } diff --git a/seed/ts-sdk/mixed-case/no-custom-config/src/Client.ts b/seed/ts-sdk/mixed-case/no-custom-config/src/Client.ts index 905b9f9a158..87bf9228957 100644 --- a/seed/ts-sdk/mixed-case/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/mixed-case/no-custom-config/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedMixedCaseClient { } export class SeedMixedCaseClient { - constructor(protected readonly _options: SeedMixedCaseClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedMixedCaseClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/mixed-case/no-custom-config/src/api/resources/service/types/Resource.ts b/seed/ts-sdk/mixed-case/no-custom-config/src/api/resources/service/types/Resource.ts index a57573e4223..07cc54e8be3 100644 --- a/seed/ts-sdk/mixed-case/no-custom-config/src/api/resources/service/types/Resource.ts +++ b/seed/ts-sdk/mixed-case/no-custom-config/src/api/resources/service/types/Resource.ts @@ -18,12 +18,12 @@ import * as SeedMixedCase from "../../../index"; */ export type Resource = SeedMixedCase.Resource.User | SeedMixedCase.Resource.Organization; -export declare namespace Resource { - interface User extends SeedMixedCase.User, _Base { +export namespace Resource { + export interface User extends SeedMixedCase.User, _Base { resourceType: "user"; } - interface Organization extends SeedMixedCase.Organization, _Base { + export interface Organization extends SeedMixedCase.Organization, _Base { resourceType: "Organization"; } diff --git a/seed/ts-sdk/mixed-case/no-custom-config/src/api/resources/service/types/ResourceStatus.ts b/seed/ts-sdk/mixed-case/no-custom-config/src/api/resources/service/types/ResourceStatus.ts index 62f07d2f99a..7205d324fcc 100644 --- a/seed/ts-sdk/mixed-case/no-custom-config/src/api/resources/service/types/ResourceStatus.ts +++ b/seed/ts-sdk/mixed-case/no-custom-config/src/api/resources/service/types/ResourceStatus.ts @@ -3,7 +3,6 @@ */ export type ResourceStatus = "ACTIVE" | "INACTIVE"; - export const ResourceStatus = { Active: "ACTIVE", Inactive: "INACTIVE", diff --git a/seed/ts-sdk/mixed-case/retain-original-casing/src/Client.ts b/seed/ts-sdk/mixed-case/retain-original-casing/src/Client.ts index 905b9f9a158..87bf9228957 100644 --- a/seed/ts-sdk/mixed-case/retain-original-casing/src/Client.ts +++ b/seed/ts-sdk/mixed-case/retain-original-casing/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedMixedCaseClient { } export class SeedMixedCaseClient { - constructor(protected readonly _options: SeedMixedCaseClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedMixedCaseClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/mixed-case/retain-original-casing/src/api/resources/service/types/Resource.ts b/seed/ts-sdk/mixed-case/retain-original-casing/src/api/resources/service/types/Resource.ts index b8366ea37d7..ef2a74911b0 100644 --- a/seed/ts-sdk/mixed-case/retain-original-casing/src/api/resources/service/types/Resource.ts +++ b/seed/ts-sdk/mixed-case/retain-original-casing/src/api/resources/service/types/Resource.ts @@ -18,12 +18,12 @@ import * as SeedMixedCase from "../../../index"; */ export type Resource = SeedMixedCase.Resource.User | SeedMixedCase.Resource.Organization; -export declare namespace Resource { - interface User extends SeedMixedCase.User, _Base { +export namespace Resource { + export interface User extends SeedMixedCase.User, _Base { resourceType: "user"; } - interface Organization extends SeedMixedCase.Organization, _Base { + export interface Organization extends SeedMixedCase.Organization, _Base { resourceType: "Organization"; } diff --git a/seed/ts-sdk/mixed-case/retain-original-casing/src/api/resources/service/types/ResourceStatus.ts b/seed/ts-sdk/mixed-case/retain-original-casing/src/api/resources/service/types/ResourceStatus.ts index 62f07d2f99a..7205d324fcc 100644 --- a/seed/ts-sdk/mixed-case/retain-original-casing/src/api/resources/service/types/ResourceStatus.ts +++ b/seed/ts-sdk/mixed-case/retain-original-casing/src/api/resources/service/types/ResourceStatus.ts @@ -3,7 +3,6 @@ */ export type ResourceStatus = "ACTIVE" | "INACTIVE"; - export const ResourceStatus = { Active: "ACTIVE", Inactive: "INACTIVE", diff --git a/seed/ts-sdk/mixed-file-directory/src/Client.ts b/seed/ts-sdk/mixed-file-directory/src/Client.ts index aae52f6ad82..61326d94564 100644 --- a/seed/ts-sdk/mixed-file-directory/src/Client.ts +++ b/seed/ts-sdk/mixed-file-directory/src/Client.ts @@ -24,16 +24,15 @@ export declare namespace SeedMixedFileDirectoryClient { } export class SeedMixedFileDirectoryClient { - constructor(protected readonly _options: SeedMixedFileDirectoryClient.Options) {} - protected _organization: Organization | undefined; + protected _user: User | undefined; + + constructor(protected readonly _options: SeedMixedFileDirectoryClient.Options) {} public get organization(): Organization { return (this._organization ??= new Organization(this._options)); } - protected _user: User | undefined; - public get user(): User { return (this._user ??= new User(this._options)); } diff --git a/seed/ts-sdk/mixed-file-directory/src/api/resources/user/client/Client.ts b/seed/ts-sdk/mixed-file-directory/src/api/resources/user/client/Client.ts index 6fb59a7705f..604de03ddde 100644 --- a/seed/ts-sdk/mixed-file-directory/src/api/resources/user/client/Client.ts +++ b/seed/ts-sdk/mixed-file-directory/src/api/resources/user/client/Client.ts @@ -27,8 +27,14 @@ export declare namespace User { } export class User { + protected _events: Events | undefined; + constructor(protected readonly _options: User.Options) {} + public get events(): Events { + return (this._events ??= new Events(this._options)); + } + /** * List all users. * @@ -99,10 +105,4 @@ export class User { }); } } - - protected _events: Events | undefined; - - public get events(): Events { - return (this._events ??= new Events(this._options)); - } } diff --git a/seed/ts-sdk/mixed-file-directory/src/api/resources/user/resources/events/client/Client.ts b/seed/ts-sdk/mixed-file-directory/src/api/resources/user/resources/events/client/Client.ts index 2db1db50034..5584e1af374 100644 --- a/seed/ts-sdk/mixed-file-directory/src/api/resources/user/resources/events/client/Client.ts +++ b/seed/ts-sdk/mixed-file-directory/src/api/resources/user/resources/events/client/Client.ts @@ -27,8 +27,14 @@ export declare namespace Events { } export class Events { + protected _metadata: Metadata | undefined; + constructor(protected readonly _options: Events.Options) {} + public get metadata(): Metadata { + return (this._metadata ??= new Metadata(this._options)); + } + /** * List all user events. * @@ -101,10 +107,4 @@ export class Events { }); } } - - protected _metadata: Metadata | undefined; - - public get metadata(): Metadata { - return (this._metadata ??= new Metadata(this._options)); - } } diff --git a/seed/ts-sdk/multi-line-docs/src/Client.ts b/seed/ts-sdk/multi-line-docs/src/Client.ts index 171ad8f9792..d13fa629e36 100644 --- a/seed/ts-sdk/multi-line-docs/src/Client.ts +++ b/seed/ts-sdk/multi-line-docs/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedMultiLineDocsClient { } export class SeedMultiLineDocsClient { - constructor(protected readonly _options: SeedMultiLineDocsClient.Options) {} - protected _user: User | undefined; + constructor(protected readonly _options: SeedMultiLineDocsClient.Options) {} + public get user(): User { return (this._user ??= new User(this._options)); } diff --git a/seed/ts-sdk/multi-line-docs/src/api/types/Operand.ts b/seed/ts-sdk/multi-line-docs/src/api/types/Operand.ts index c7565c6f971..aaf4cd3090c 100644 --- a/seed/ts-sdk/multi-line-docs/src/api/types/Operand.ts +++ b/seed/ts-sdk/multi-line-docs/src/api/types/Operand.ts @@ -19,7 +19,6 @@ export type Operand = * The name and value should be similar * are similar for less than. */ | "less_than"; - export const Operand = { GreaterThan: ">", EqualTo: "=", diff --git a/seed/ts-sdk/multi-url-environment-no-default/src/Client.ts b/seed/ts-sdk/multi-url-environment-no-default/src/Client.ts index 66409931816..554992f3f04 100644 --- a/seed/ts-sdk/multi-url-environment-no-default/src/Client.ts +++ b/seed/ts-sdk/multi-url-environment-no-default/src/Client.ts @@ -29,16 +29,15 @@ export declare namespace SeedMultiUrlEnvironmentNoDefaultClient { } export class SeedMultiUrlEnvironmentNoDefaultClient { - constructor(protected readonly _options: SeedMultiUrlEnvironmentNoDefaultClient.Options) {} - protected _ec2: Ec2 | undefined; + protected _s3: S3 | undefined; + + constructor(protected readonly _options: SeedMultiUrlEnvironmentNoDefaultClient.Options) {} public get ec2(): Ec2 { return (this._ec2 ??= new Ec2(this._options)); } - protected _s3: S3 | undefined; - public get s3(): S3 { return (this._s3 ??= new S3(this._options)); } diff --git a/seed/ts-sdk/multi-url-environment/src/Client.ts b/seed/ts-sdk/multi-url-environment/src/Client.ts index 76916a7df87..a10684d594c 100644 --- a/seed/ts-sdk/multi-url-environment/src/Client.ts +++ b/seed/ts-sdk/multi-url-environment/src/Client.ts @@ -28,16 +28,15 @@ export declare namespace SeedMultiUrlEnvironmentClient { } export class SeedMultiUrlEnvironmentClient { - constructor(protected readonly _options: SeedMultiUrlEnvironmentClient.Options) {} - protected _ec2: Ec2 | undefined; + protected _s3: S3 | undefined; + + constructor(protected readonly _options: SeedMultiUrlEnvironmentClient.Options) {} public get ec2(): Ec2 { return (this._ec2 ??= new Ec2(this._options)); } - protected _s3: S3 | undefined; - public get s3(): S3 { return (this._s3 ??= new S3(this._options)); } diff --git a/seed/ts-sdk/no-environment/src/Client.ts b/seed/ts-sdk/no-environment/src/Client.ts index e1f27033c35..c593b72d1ef 100644 --- a/seed/ts-sdk/no-environment/src/Client.ts +++ b/seed/ts-sdk/no-environment/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedNoEnvironmentClient { } export class SeedNoEnvironmentClient { - constructor(protected readonly _options: SeedNoEnvironmentClient.Options) {} - protected _dummy: Dummy | undefined; + constructor(protected readonly _options: SeedNoEnvironmentClient.Options) {} + public get dummy(): Dummy { return (this._dummy ??= new Dummy(this._options)); } diff --git a/seed/ts-sdk/oauth-client-credentials-default/src/Client.ts b/seed/ts-sdk/oauth-client-credentials-default/src/Client.ts index 8b03b81efbc..150ebb19d83 100644 --- a/seed/ts-sdk/oauth-client-credentials-default/src/Client.ts +++ b/seed/ts-sdk/oauth-client-credentials-default/src/Client.ts @@ -26,6 +26,7 @@ export declare namespace SeedOauthClientCredentialsDefaultClient { export class SeedOauthClientCredentialsDefaultClient { private readonly _oauthTokenProvider: core.OAuthTokenProvider; + protected _auth: Auth | undefined; constructor(protected readonly _options: SeedOauthClientCredentialsDefaultClient.Options) { this._oauthTokenProvider = new core.OAuthTokenProvider({ @@ -37,8 +38,6 @@ export class SeedOauthClientCredentialsDefaultClient { }); } - protected _auth: Auth | undefined; - public get auth(): Auth { return (this._auth ??= new Auth({ ...this._options, diff --git a/seed/ts-sdk/oauth-client-credentials-environment-variables/src/Client.ts b/seed/ts-sdk/oauth-client-credentials-environment-variables/src/Client.ts index b859a31d2f8..49e0e32f0c2 100644 --- a/seed/ts-sdk/oauth-client-credentials-environment-variables/src/Client.ts +++ b/seed/ts-sdk/oauth-client-credentials-environment-variables/src/Client.ts @@ -26,6 +26,7 @@ export declare namespace SeedOauthClientCredentialsEnvironmentVariablesClient { export class SeedOauthClientCredentialsEnvironmentVariablesClient { private readonly _oauthTokenProvider: core.OAuthTokenProvider; + protected _auth: Auth | undefined; constructor(protected readonly _options: SeedOauthClientCredentialsEnvironmentVariablesClient.Options) { const clientId = this._options.clientId ?? process.env["CLIENT_ID"]; @@ -51,8 +52,6 @@ export class SeedOauthClientCredentialsEnvironmentVariablesClient { }); } - protected _auth: Auth | undefined; - public get auth(): Auth { return (this._auth ??= new Auth({ ...this._options, diff --git a/seed/ts-sdk/oauth-client-credentials-nested-root/never-throw-errors/src/Client.ts b/seed/ts-sdk/oauth-client-credentials-nested-root/never-throw-errors/src/Client.ts index a370684e3cb..29a66bd2e37 100644 --- a/seed/ts-sdk/oauth-client-credentials-nested-root/never-throw-errors/src/Client.ts +++ b/seed/ts-sdk/oauth-client-credentials-nested-root/never-throw-errors/src/Client.ts @@ -26,6 +26,7 @@ export declare namespace SeedOauthClientCredentialsClient { export class SeedOauthClientCredentialsClient { private readonly _oauthTokenProvider: core.OAuthTokenProvider; + protected _auth: Auth | undefined; constructor(protected readonly _options: SeedOauthClientCredentialsClient.Options) { this._oauthTokenProvider = new core.OAuthTokenProvider({ @@ -37,8 +38,6 @@ export class SeedOauthClientCredentialsClient { }); } - protected _auth: Auth | undefined; - public get auth(): Auth { return (this._auth ??= new Auth({ ...this._options, diff --git a/seed/ts-sdk/oauth-client-credentials-nested-root/never-throw-errors/src/api/resources/auth/client/getToken.ts b/seed/ts-sdk/oauth-client-credentials-nested-root/never-throw-errors/src/api/resources/auth/client/getToken.ts index 87de2a82bc7..18e683969be 100644 --- a/seed/ts-sdk/oauth-client-credentials-nested-root/never-throw-errors/src/api/resources/auth/client/getToken.ts +++ b/seed/ts-sdk/oauth-client-credentials-nested-root/never-throw-errors/src/api/resources/auth/client/getToken.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedOauthClientCredentials.auth.getToken.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { statusCode: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/oauth-client-credentials-nested-root/no-custom-config/src/Client.ts b/seed/ts-sdk/oauth-client-credentials-nested-root/no-custom-config/src/Client.ts index a370684e3cb..29a66bd2e37 100644 --- a/seed/ts-sdk/oauth-client-credentials-nested-root/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/oauth-client-credentials-nested-root/no-custom-config/src/Client.ts @@ -26,6 +26,7 @@ export declare namespace SeedOauthClientCredentialsClient { export class SeedOauthClientCredentialsClient { private readonly _oauthTokenProvider: core.OAuthTokenProvider; + protected _auth: Auth | undefined; constructor(protected readonly _options: SeedOauthClientCredentialsClient.Options) { this._oauthTokenProvider = new core.OAuthTokenProvider({ @@ -37,8 +38,6 @@ export class SeedOauthClientCredentialsClient { }); } - protected _auth: Auth | undefined; - public get auth(): Auth { return (this._auth ??= new Auth({ ...this._options, diff --git a/seed/ts-sdk/oauth-client-credentials/src/Client.ts b/seed/ts-sdk/oauth-client-credentials/src/Client.ts index a370684e3cb..29a66bd2e37 100644 --- a/seed/ts-sdk/oauth-client-credentials/src/Client.ts +++ b/seed/ts-sdk/oauth-client-credentials/src/Client.ts @@ -26,6 +26,7 @@ export declare namespace SeedOauthClientCredentialsClient { export class SeedOauthClientCredentialsClient { private readonly _oauthTokenProvider: core.OAuthTokenProvider; + protected _auth: Auth | undefined; constructor(protected readonly _options: SeedOauthClientCredentialsClient.Options) { this._oauthTokenProvider = new core.OAuthTokenProvider({ @@ -37,8 +38,6 @@ export class SeedOauthClientCredentialsClient { }); } - protected _auth: Auth | undefined; - public get auth(): Auth { return (this._auth ??= new Auth({ ...this._options, diff --git a/seed/ts-sdk/objects-with-imports/src/api/resources/file/types/FileInfo.ts b/seed/ts-sdk/objects-with-imports/src/api/resources/file/types/FileInfo.ts index 26407d4b8aa..f2bc29c15db 100644 --- a/seed/ts-sdk/objects-with-imports/src/api/resources/file/types/FileInfo.ts +++ b/seed/ts-sdk/objects-with-imports/src/api/resources/file/types/FileInfo.ts @@ -16,7 +16,6 @@ export type FileInfo = /** * A directory (e.g. foo/). */ | "DIRECTORY"; - export const FileInfo = { Regular: "REGULAR", Directory: "DIRECTORY", diff --git a/seed/ts-sdk/optional/src/Client.ts b/seed/ts-sdk/optional/src/Client.ts index 96468097b54..fad5fd8d0ea 100644 --- a/seed/ts-sdk/optional/src/Client.ts +++ b/seed/ts-sdk/optional/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedObjectsWithImportsClient { } export class SeedObjectsWithImportsClient { - constructor(protected readonly _options: SeedObjectsWithImportsClient.Options) {} - protected _optional: Optional | undefined; + constructor(protected readonly _options: SeedObjectsWithImportsClient.Options) {} + public get optional(): Optional { return (this._optional ??= new Optional(this._options)); } diff --git a/seed/ts-sdk/package-yml/src/Client.ts b/seed/ts-sdk/package-yml/src/Client.ts index 88c0d2f16c0..74c0d236c13 100644 --- a/seed/ts-sdk/package-yml/src/Client.ts +++ b/seed/ts-sdk/package-yml/src/Client.ts @@ -28,8 +28,14 @@ export declare namespace SeedPackageYmlClient { } export class SeedPackageYmlClient { + protected _service: Service | undefined; + constructor(protected readonly _options: SeedPackageYmlClient.Options) {} + public get service(): Service { + return (this._service ??= new Service(this._options)); + } + /** * @param {SeedPackageYml.EchoRequest} request * @param {SeedPackageYmlClient.RequestOptions} requestOptions - Request-specific configuration. @@ -96,10 +102,4 @@ export class SeedPackageYmlClient { }); } } - - protected _service: Service | undefined; - - public get service(): Service { - return (this._service ??= new Service(this._options)); - } } diff --git a/seed/ts-sdk/pagination/src/Client.ts b/seed/ts-sdk/pagination/src/Client.ts index 327e761ba5b..b7b8d4a8d58 100644 --- a/seed/ts-sdk/pagination/src/Client.ts +++ b/seed/ts-sdk/pagination/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedPaginationClient { } export class SeedPaginationClient { - constructor(protected readonly _options: SeedPaginationClient.Options) {} - protected _users: Users | undefined; + constructor(protected readonly _options: SeedPaginationClient.Options) {} + public get users(): Users { return (this._users ??= new Users(this._options)); } diff --git a/seed/ts-sdk/pagination/src/api/resources/users/types/Order.ts b/seed/ts-sdk/pagination/src/api/resources/users/types/Order.ts index e5763cabff4..a6405828876 100644 --- a/seed/ts-sdk/pagination/src/api/resources/users/types/Order.ts +++ b/seed/ts-sdk/pagination/src/api/resources/users/types/Order.ts @@ -3,7 +3,6 @@ */ export type Order = "asc" | "desc"; - export const Order = { Asc: "asc", Desc: "desc", diff --git a/seed/ts-sdk/path-parameters/src/Client.ts b/seed/ts-sdk/path-parameters/src/Client.ts index 4d69aeee0a4..37998672270 100644 --- a/seed/ts-sdk/path-parameters/src/Client.ts +++ b/seed/ts-sdk/path-parameters/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedPathParametersClient { } export class SeedPathParametersClient { - constructor(protected readonly _options: SeedPathParametersClient.Options) {} - protected _user: User | undefined; + constructor(protected readonly _options: SeedPathParametersClient.Options) {} + public get user(): User { return (this._user ??= new User(this._options)); } diff --git a/seed/ts-sdk/plain-text/src/Client.ts b/seed/ts-sdk/plain-text/src/Client.ts index 5328ade7f16..b53a41c2ae8 100644 --- a/seed/ts-sdk/plain-text/src/Client.ts +++ b/seed/ts-sdk/plain-text/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedPlainTextClient { } export class SeedPlainTextClient { - constructor(protected readonly _options: SeedPlainTextClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedPlainTextClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/query-parameters/no-custom-config/src/Client.ts b/seed/ts-sdk/query-parameters/no-custom-config/src/Client.ts index 52b8a1e8b7a..3ae49d51366 100644 --- a/seed/ts-sdk/query-parameters/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/query-parameters/no-custom-config/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedQueryParametersClient { } export class SeedQueryParametersClient { - constructor(protected readonly _options: SeedQueryParametersClient.Options) {} - protected _user: User | undefined; + constructor(protected readonly _options: SeedQueryParametersClient.Options) {} + public get user(): User { return (this._user ??= new User(this._options)); } diff --git a/seed/ts-sdk/query-parameters/no-serde-layer-query/src/Client.ts b/seed/ts-sdk/query-parameters/no-serde-layer-query/src/Client.ts index 52b8a1e8b7a..3ae49d51366 100644 --- a/seed/ts-sdk/query-parameters/no-serde-layer-query/src/Client.ts +++ b/seed/ts-sdk/query-parameters/no-serde-layer-query/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedQueryParametersClient { } export class SeedQueryParametersClient { - constructor(protected readonly _options: SeedQueryParametersClient.Options) {} - protected _user: User | undefined; + constructor(protected readonly _options: SeedQueryParametersClient.Options) {} + public get user(): User { return (this._user ??= new User(this._options)); } diff --git a/seed/ts-sdk/reserved-keywords/src/Client.ts b/seed/ts-sdk/reserved-keywords/src/Client.ts index 863822b6564..25bb8d7f51e 100644 --- a/seed/ts-sdk/reserved-keywords/src/Client.ts +++ b/seed/ts-sdk/reserved-keywords/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedNurseryApiClient { } export class SeedNurseryApiClient { - constructor(protected readonly _options: SeedNurseryApiClient.Options) {} - protected _package: Package | undefined; + constructor(protected readonly _options: SeedNurseryApiClient.Options) {} + public get package(): Package { return (this._package ??= new Package(this._options)); } diff --git a/seed/ts-sdk/response-property/src/Client.ts b/seed/ts-sdk/response-property/src/Client.ts index d6a900c49d9..95e831fc6e3 100644 --- a/seed/ts-sdk/response-property/src/Client.ts +++ b/seed/ts-sdk/response-property/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedResponsePropertyClient { } export class SeedResponsePropertyClient { - constructor(protected readonly _options: SeedResponsePropertyClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedResponsePropertyClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/seed.yml b/seed/ts-sdk/seed.yml index 0a8984f8e5b..898989cce99 100644 --- a/seed/ts-sdk/seed.yml +++ b/seed/ts-sdk/seed.yml @@ -206,6 +206,15 @@ fixtures: - customConfig: retainOriginalCasing: true outputFolder: retain-original-casing + inline-types: + - customConfig: + noSerdeLayer: true + enableInlineTypes: true + outputFolder: inline + - customConfig: + noSerdeLayer: true + enableInlineTypes: false + outputFolder: no-inline scripts: - docker: fernapi/ts-seed commands: diff --git a/seed/ts-sdk/server-sent-event-examples/src/Client.ts b/seed/ts-sdk/server-sent-event-examples/src/Client.ts index 262e3ccf1e2..77e6ab92912 100644 --- a/seed/ts-sdk/server-sent-event-examples/src/Client.ts +++ b/seed/ts-sdk/server-sent-event-examples/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedServerSentEventsClient { } export class SeedServerSentEventsClient { - constructor(protected readonly _options: SeedServerSentEventsClient.Options) {} - protected _completions: Completions | undefined; + constructor(protected readonly _options: SeedServerSentEventsClient.Options) {} + public get completions(): Completions { return (this._completions ??= new Completions(this._options)); } diff --git a/seed/ts-sdk/server-sent-events/src/Client.ts b/seed/ts-sdk/server-sent-events/src/Client.ts index 262e3ccf1e2..77e6ab92912 100644 --- a/seed/ts-sdk/server-sent-events/src/Client.ts +++ b/seed/ts-sdk/server-sent-events/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedServerSentEventsClient { } export class SeedServerSentEventsClient { - constructor(protected readonly _options: SeedServerSentEventsClient.Options) {} - protected _completions: Completions | undefined; + constructor(protected readonly _options: SeedServerSentEventsClient.Options) {} + public get completions(): Completions { return (this._completions ??= new Completions(this._options)); } diff --git a/seed/ts-sdk/single-url-environment-default/src/Client.ts b/seed/ts-sdk/single-url-environment-default/src/Client.ts index 33641f5a0b8..6602dbe2d42 100644 --- a/seed/ts-sdk/single-url-environment-default/src/Client.ts +++ b/seed/ts-sdk/single-url-environment-default/src/Client.ts @@ -25,10 +25,10 @@ export declare namespace SeedSingleUrlEnvironmentDefaultClient { } export class SeedSingleUrlEnvironmentDefaultClient { - constructor(protected readonly _options: SeedSingleUrlEnvironmentDefaultClient.Options) {} - protected _dummy: Dummy | undefined; + constructor(protected readonly _options: SeedSingleUrlEnvironmentDefaultClient.Options) {} + public get dummy(): Dummy { return (this._dummy ??= new Dummy(this._options)); } diff --git a/seed/ts-sdk/single-url-environment-no-default/src/Client.ts b/seed/ts-sdk/single-url-environment-no-default/src/Client.ts index 5660b88fec7..ed1e9884382 100644 --- a/seed/ts-sdk/single-url-environment-no-default/src/Client.ts +++ b/seed/ts-sdk/single-url-environment-no-default/src/Client.ts @@ -25,10 +25,10 @@ export declare namespace SeedSingleUrlEnvironmentNoDefaultClient { } export class SeedSingleUrlEnvironmentNoDefaultClient { - constructor(protected readonly _options: SeedSingleUrlEnvironmentNoDefaultClient.Options) {} - protected _dummy: Dummy | undefined; + constructor(protected readonly _options: SeedSingleUrlEnvironmentNoDefaultClient.Options) {} + public get dummy(): Dummy { return (this._dummy ??= new Dummy(this._options)); } diff --git a/seed/ts-sdk/streaming/allow-custom-fetcher/src/Client.ts b/seed/ts-sdk/streaming/allow-custom-fetcher/src/Client.ts index b8a3d466961..6e031d82774 100644 --- a/seed/ts-sdk/streaming/allow-custom-fetcher/src/Client.ts +++ b/seed/ts-sdk/streaming/allow-custom-fetcher/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedStreamingClient { } export class SeedStreamingClient { - constructor(protected readonly _options: SeedStreamingClient.Options) {} - protected _dummy: Dummy | undefined; + constructor(protected readonly _options: SeedStreamingClient.Options) {} + public get dummy(): Dummy { return (this._dummy ??= new Dummy(this._options)); } diff --git a/seed/ts-sdk/streaming/no-custom-config/src/Client.ts b/seed/ts-sdk/streaming/no-custom-config/src/Client.ts index a968a322c37..4a12bf2c1a6 100644 --- a/seed/ts-sdk/streaming/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/streaming/no-custom-config/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedStreamingClient { } export class SeedStreamingClient { - constructor(protected readonly _options: SeedStreamingClient.Options) {} - protected _dummy: Dummy | undefined; + constructor(protected readonly _options: SeedStreamingClient.Options) {} + public get dummy(): Dummy { return (this._dummy ??= new Dummy(this._options)); } diff --git a/seed/ts-sdk/trace/exhaustive/src/Client.ts b/seed/ts-sdk/trace/exhaustive/src/Client.ts index 29bb5b0d035..845a9793bbd 100644 --- a/seed/ts-sdk/trace/exhaustive/src/Client.ts +++ b/seed/ts-sdk/trace/exhaustive/src/Client.ts @@ -36,52 +36,45 @@ export declare namespace SeedTraceClient { } export class SeedTraceClient { - constructor(protected readonly _options: SeedTraceClient.Options = {}) {} - protected _v2: V2 | undefined; + protected _admin: Admin | undefined; + protected _homepage: Homepage | undefined; + protected _migration: Migration | undefined; + protected _playlist: Playlist | undefined; + protected _problem: Problem | undefined; + protected _submission: Submission | undefined; + protected _sysprop: Sysprop | undefined; + + constructor(protected readonly _options: SeedTraceClient.Options = {}) {} public get v2(): V2 { return (this._v2 ??= new V2(this._options)); } - protected _admin: Admin | undefined; - public get admin(): Admin { return (this._admin ??= new Admin(this._options)); } - protected _homepage: Homepage | undefined; - public get homepage(): Homepage { return (this._homepage ??= new Homepage(this._options)); } - protected _migration: Migration | undefined; - public get migration(): Migration { return (this._migration ??= new Migration(this._options)); } - protected _playlist: Playlist | undefined; - public get playlist(): Playlist { return (this._playlist ??= new Playlist(this._options)); } - protected _problem: Problem | undefined; - public get problem(): Problem { return (this._problem ??= new Problem(this._options)); } - protected _submission: Submission | undefined; - public get submission(): Submission { return (this._submission ??= new Submission(this._options)); } - protected _sysprop: Sysprop | undefined; - public get sysprop(): Sysprop { return (this._sysprop ??= new Sysprop(this._options)); } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/sendTestSubmissionUpdate.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/sendTestSubmissionUpdate.ts index 147f91056b3..74fcdd73ffd 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/sendTestSubmissionUpdate.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/sendTestSubmissionUpdate.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.sendTestSubmissionUpdate.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/sendWorkspaceSubmissionUpdate.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/sendWorkspaceSubmissionUpdate.ts index a72a13be0f9..09002e8971e 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/sendWorkspaceSubmissionUpdate.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/sendWorkspaceSubmissionUpdate.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.sendWorkspaceSubmissionUpdate.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedTestCase.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedTestCase.ts index dc1b9a34d0e..ecb9e93ccc7 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedTestCase.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedTestCase.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.storeTracedTestCase.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedTestCaseV2.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedTestCaseV2.ts index 407dca30411..0514c9285ce 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedTestCaseV2.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedTestCaseV2.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.storeTracedTestCaseV2.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedWorkspace.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedWorkspace.ts index 9b6e0065622..12239852f23 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedWorkspace.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedWorkspace.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.storeTracedWorkspace.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedWorkspaceV2.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedWorkspaceV2.ts index 1befb67856c..5e627ce0925 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedWorkspaceV2.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/storeTracedWorkspaceV2.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.storeTracedWorkspaceV2.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/updateTestSubmissionStatus.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/updateTestSubmissionStatus.ts index 77a5be41c8c..8a9aaa21074 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/updateTestSubmissionStatus.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/updateTestSubmissionStatus.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.updateTestSubmissionStatus.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/updateWorkspaceSubmissionStatus.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/updateWorkspaceSubmissionStatus.ts index 1276c140fe1..8518a8a1cbe 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/updateWorkspaceSubmissionStatus.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/client/updateWorkspaceSubmissionStatus.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.updateWorkspaceSubmissionStatus.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/types/Test.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/types/Test.ts index b5559a23e83..0325ec2664f 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/types/Test.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/admin/types/Test.ts @@ -6,18 +6,18 @@ import * as SeedTrace from "../../../index"; export type Test = SeedTrace.Test.And | SeedTrace.Test.Or | SeedTrace.Test._Unknown; -export declare namespace Test { - interface And extends _Utils { +export namespace Test { + export interface And extends _Utils { type: "and"; value: boolean; } - interface Or extends _Utils { + export interface Or extends _Utils { type: "or"; value: boolean; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/DebugVariableValue.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/DebugVariableValue.ts index 5f8f7f8619d..bc9d1536b25 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/DebugVariableValue.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/DebugVariableValue.ts @@ -20,66 +20,66 @@ export type DebugVariableValue = | SeedTrace.DebugVariableValue.GenericValue | SeedTrace.DebugVariableValue._Unknown; -export declare namespace DebugVariableValue { - interface IntegerValue extends _Utils { +export namespace DebugVariableValue { + export interface IntegerValue extends _Utils { type: "integerValue"; value: number; } - interface BooleanValue extends _Utils { + export interface BooleanValue extends _Utils { type: "booleanValue"; value: boolean; } - interface DoubleValue extends _Utils { + export interface DoubleValue extends _Utils { type: "doubleValue"; value: number; } - interface StringValue extends _Utils { + export interface StringValue extends _Utils { type: "stringValue"; value: string; } - interface CharValue extends _Utils { + export interface CharValue extends _Utils { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.DebugMapValue, _Utils { + export interface MapValue extends SeedTrace.DebugMapValue, _Utils { type: "mapValue"; } - interface ListValue extends _Utils { + export interface ListValue extends _Utils { type: "listValue"; value: SeedTrace.DebugVariableValue[]; } - interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue, _Utils { + export interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue, _Utils { type: "binaryTreeNodeValue"; } - interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue, _Utils { + export interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue, _Utils { type: "singlyLinkedListNodeValue"; } - interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue, _Utils { + export interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue, _Utils { type: "doublyLinkedListNodeValue"; } - interface UndefinedValue extends _Utils { + export interface UndefinedValue extends _Utils { type: "undefinedValue"; } - interface NullValue extends _Utils { + export interface NullValue extends _Utils { type: "nullValue"; } - interface GenericValue extends SeedTrace.GenericValue, _Utils { + export interface GenericValue extends SeedTrace.GenericValue, _Utils { type: "genericValue"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/Language.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/Language.ts index d8f7b5fa4fc..ad34597dd47 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/Language.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/Language.ts @@ -3,7 +3,6 @@ */ export type Language = "JAVA" | "JAVASCRIPT" | "PYTHON"; - export const Language = { Java: "JAVA", Javascript: "JAVASCRIPT", @@ -22,7 +21,7 @@ export const Language = { }, } as const; -export declare namespace Language { +export namespace Language { interface Visitor { java: () => R; javascript: () => R; diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/VariableType.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/VariableType.ts index 4ca831494bc..fa20b994d5d 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/VariableType.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/VariableType.ts @@ -17,48 +17,48 @@ export type VariableType = | SeedTrace.VariableType.DoublyLinkedListType | SeedTrace.VariableType._Unknown; -export declare namespace VariableType { - interface IntegerType extends _Utils { +export namespace VariableType { + export interface IntegerType extends _Utils { type: "integerType"; } - interface DoubleType extends _Utils { + export interface DoubleType extends _Utils { type: "doubleType"; } - interface BooleanType extends _Utils { + export interface BooleanType extends _Utils { type: "booleanType"; } - interface StringType extends _Utils { + export interface StringType extends _Utils { type: "stringType"; } - interface CharType extends _Utils { + export interface CharType extends _Utils { type: "charType"; } - interface ListType extends SeedTrace.ListType, _Utils { + export interface ListType extends SeedTrace.ListType, _Utils { type: "listType"; } - interface MapType extends SeedTrace.MapType, _Utils { + export interface MapType extends SeedTrace.MapType, _Utils { type: "mapType"; } - interface BinaryTreeType extends _Utils { + export interface BinaryTreeType extends _Utils { type: "binaryTreeType"; } - interface SinglyLinkedListType extends _Utils { + export interface SinglyLinkedListType extends _Utils { type: "singlyLinkedListType"; } - interface DoublyLinkedListType extends _Utils { + export interface DoublyLinkedListType extends _Utils { type: "doublyLinkedListType"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/VariableValue.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/VariableValue.ts index 136c4e89006..a54f0bfcdd8 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/VariableValue.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/commons/types/VariableValue.ts @@ -18,58 +18,58 @@ export type VariableValue = | SeedTrace.VariableValue.NullValue | SeedTrace.VariableValue._Unknown; -export declare namespace VariableValue { - interface IntegerValue extends _Utils { +export namespace VariableValue { + export interface IntegerValue extends _Utils { type: "integerValue"; value: number; } - interface BooleanValue extends _Utils { + export interface BooleanValue extends _Utils { type: "booleanValue"; value: boolean; } - interface DoubleValue extends _Utils { + export interface DoubleValue extends _Utils { type: "doubleValue"; value: number; } - interface StringValue extends _Utils { + export interface StringValue extends _Utils { type: "stringValue"; value: string; } - interface CharValue extends _Utils { + export interface CharValue extends _Utils { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.MapValue, _Utils { + export interface MapValue extends SeedTrace.MapValue, _Utils { type: "mapValue"; } - interface ListValue extends _Utils { + export interface ListValue extends _Utils { type: "listValue"; value: SeedTrace.VariableValue[]; } - interface BinaryTreeValue extends SeedTrace.BinaryTreeValue, _Utils { + export interface BinaryTreeValue extends SeedTrace.BinaryTreeValue, _Utils { type: "binaryTreeValue"; } - interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue, _Utils { + export interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue, _Utils { type: "singlyLinkedListValue"; } - interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue, _Utils { + export interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue, _Utils { type: "doublyLinkedListValue"; } - interface NullValue extends _Utils { + export interface NullValue extends _Utils { type: "nullValue"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/homepage/client/getHomepageProblems.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/homepage/client/getHomepageProblems.ts index 54558828d49..72f03c157c7 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/homepage/client/getHomepageProblems.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/homepage/client/getHomepageProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.homepage.getHomepageProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/homepage/client/setHomepageProblems.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/homepage/client/setHomepageProblems.ts index 387999e36d9..479b34e0422 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/homepage/client/setHomepageProblems.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/homepage/client/setHomepageProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.homepage.setHomepageProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/migration/client/getAttemptedMigrations.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/migration/client/getAttemptedMigrations.ts index 31a52110e81..dc5e5732e4f 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/migration/client/getAttemptedMigrations.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/migration/client/getAttemptedMigrations.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.migration.getAttemptedMigrations.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/migration/types/MigrationStatus.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/migration/types/MigrationStatus.ts index 33b907f3dd3..b04a7740e22 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/migration/types/MigrationStatus.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/migration/types/MigrationStatus.ts @@ -10,7 +10,6 @@ export type MigrationStatus = * The migration is failed */ | "FAILED" | "FINISHED"; - export const MigrationStatus = { Running: "RUNNING", Failed: "FAILED", @@ -29,7 +28,7 @@ export const MigrationStatus = { }, } as const; -export declare namespace MigrationStatus { +export namespace MigrationStatus { interface Visitor { running: () => R; failed: () => R; diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/createPlaylist.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/createPlaylist.ts index eb33077821a..bfc60c5deb5 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/createPlaylist.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/createPlaylist.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.playlist.createPlaylist.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/deletePlaylist.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/deletePlaylist.ts index 4248589f6cd..f3d7342f2aa 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/deletePlaylist.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/deletePlaylist.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.playlist.deletePlaylist.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/getPlaylist.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/getPlaylist.ts index 6304ef2cfd8..4a653c3c304 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/getPlaylist.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/getPlaylist.ts @@ -10,17 +10,17 @@ export type Error = | SeedTrace.playlist.getPlaylist.Error.UnauthorizedError | SeedTrace.playlist.getPlaylist.Error._Unknown; -export declare namespace Error { - interface PlaylistIdNotFoundError extends _Utils { +export namespace Error { + export interface PlaylistIdNotFoundError extends _Utils { errorName: "PlaylistIdNotFoundError"; content: SeedTrace.PlaylistIdNotFoundErrorBody; } - interface UnauthorizedError extends _Utils { + export interface UnauthorizedError extends _Utils { errorName: "UnauthorizedError"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/getPlaylists.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/getPlaylists.ts index 438b873124e..b34ce8e559e 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/getPlaylists.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/getPlaylists.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.playlist.getPlaylists.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/updatePlaylist.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/updatePlaylist.ts index 0cdde0c5a5e..fe014029dea 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/updatePlaylist.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/client/updatePlaylist.ts @@ -9,13 +9,13 @@ export type Error = | SeedTrace.playlist.updatePlaylist.Error.PlaylistIdNotFoundError | SeedTrace.playlist.updatePlaylist.Error._Unknown; -export declare namespace Error { - interface PlaylistIdNotFoundError extends _Utils { +export namespace Error { + export interface PlaylistIdNotFoundError extends _Utils { errorName: "PlaylistIdNotFoundError"; content: SeedTrace.PlaylistIdNotFoundErrorBody; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts index 4ea69cefc3e..6474e557430 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts @@ -8,13 +8,13 @@ export type PlaylistIdNotFoundErrorBody = | SeedTrace.PlaylistIdNotFoundErrorBody.PlaylistId | SeedTrace.PlaylistIdNotFoundErrorBody._Unknown; -export declare namespace PlaylistIdNotFoundErrorBody { - interface PlaylistId extends _Utils { +export namespace PlaylistIdNotFoundErrorBody { + export interface PlaylistId extends _Utils { type: "playlistId"; value: SeedTrace.PlaylistId; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/types/ReservedKeywordEnum.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/types/ReservedKeywordEnum.ts index 4c75fc5b90c..e6150f76233 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/types/ReservedKeywordEnum.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/playlist/types/ReservedKeywordEnum.ts @@ -3,7 +3,6 @@ */ export type ReservedKeywordEnum = "is" | "as"; - export const ReservedKeywordEnum = { Is: "is", As: "as", @@ -19,7 +18,7 @@ export const ReservedKeywordEnum = { }, } as const; -export declare namespace ReservedKeywordEnum { +export namespace ReservedKeywordEnum { interface Visitor { is: () => R; as: () => R; diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/createProblem.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/createProblem.ts index a18d3e0bbbb..0133491ea5d 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/createProblem.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/createProblem.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.problem.createProblem.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/deleteProblem.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/deleteProblem.ts index e4f657caaea..a9f4f4f13d3 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/deleteProblem.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/deleteProblem.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.problem.deleteProblem.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/getDefaultStarterFiles.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/getDefaultStarterFiles.ts index f366512490f..e999b4e2772 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/getDefaultStarterFiles.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/getDefaultStarterFiles.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.problem.getDefaultStarterFiles.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/updateProblem.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/updateProblem.ts index 2ea9c54f4db..76ae2de4881 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/updateProblem.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/client/updateProblem.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.problem.updateProblem.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/CreateProblemError.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/CreateProblemError.ts index f3f5ed8979b..c97f587c9ee 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/CreateProblemError.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/CreateProblemError.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type CreateProblemError = SeedTrace.CreateProblemError.Generic | SeedTrace.CreateProblemError._Unknown; -export declare namespace CreateProblemError { - interface Generic extends SeedTrace.GenericCreateProblemError, _Utils { +export namespace CreateProblemError { + export interface Generic extends SeedTrace.GenericCreateProblemError, _Utils { errorType: "generic"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { errorType: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/CreateProblemResponse.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/CreateProblemResponse.ts index f1dcecb7fe0..c70160160a0 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/CreateProblemResponse.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/CreateProblemResponse.ts @@ -9,18 +9,18 @@ export type CreateProblemResponse = | SeedTrace.CreateProblemResponse.Error_ | SeedTrace.CreateProblemResponse._Unknown; -export declare namespace CreateProblemResponse { - interface Success extends _Utils { +export namespace CreateProblemResponse { + export interface Success extends _Utils { type: "success"; value: SeedTrace.ProblemId; } - interface Error_ extends _Utils { + export interface Error_ extends _Utils { type: "error"; value: SeedTrace.CreateProblemError; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/ProblemDescriptionBoard.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/ProblemDescriptionBoard.ts index f281fecf257..dc3759888a0 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/ProblemDescriptionBoard.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/problem/types/ProblemDescriptionBoard.ts @@ -10,23 +10,23 @@ export type ProblemDescriptionBoard = | SeedTrace.ProblemDescriptionBoard.TestCaseId | SeedTrace.ProblemDescriptionBoard._Unknown; -export declare namespace ProblemDescriptionBoard { - interface Html extends _Utils { +export namespace ProblemDescriptionBoard { + export interface Html extends _Utils { type: "html"; value: string; } - interface Variable extends _Utils { + export interface Variable extends _Utils { type: "variable"; value: SeedTrace.VariableValue; } - interface TestCaseId extends _Utils { + export interface TestCaseId extends _Utils { type: "testCaseId"; value: string; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/createExecutionSession.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/createExecutionSession.ts index 808e0574499..9a18654f084 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/createExecutionSession.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/createExecutionSession.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.submission.createExecutionSession.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/getExecutionSession.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/getExecutionSession.ts index 5c6fd2fe7d0..0f0d43628f1 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/getExecutionSession.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/getExecutionSession.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.submission.getExecutionSession.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/getExecutionSessionsState.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/getExecutionSessionsState.ts index 0cf9d3dd55e..de6ded364d4 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/getExecutionSessionsState.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/getExecutionSessionsState.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.submission.getExecutionSessionsState.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/stopExecutionSession.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/stopExecutionSession.ts index 3de0edaa585..a566b72c0d1 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/stopExecutionSession.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/client/stopExecutionSession.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.submission.stopExecutionSession.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ActualResult.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ActualResult.ts index 852dacd2f26..7324a742d2e 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ActualResult.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ActualResult.ts @@ -10,22 +10,22 @@ export type ActualResult = | SeedTrace.ActualResult.ExceptionV2 | SeedTrace.ActualResult._Unknown; -export declare namespace ActualResult { - interface Value extends _Utils { +export namespace ActualResult { + export interface Value extends _Utils { type: "value"; value: SeedTrace.VariableValue; } - interface Exception extends SeedTrace.ExceptionInfo, _Utils { + export interface Exception extends SeedTrace.ExceptionInfo, _Utils { type: "exception"; } - interface ExceptionV2 extends _Utils { + export interface ExceptionV2 extends _Utils { type: "exceptionV2"; value: SeedTrace.ExceptionV2; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/CodeExecutionUpdate.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/CodeExecutionUpdate.ts index 1f945018800..9e418a7cf48 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/CodeExecutionUpdate.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/CodeExecutionUpdate.ts @@ -40,52 +40,52 @@ export type CodeExecutionUpdate = | SeedTrace.CodeExecutionUpdate.Finished | SeedTrace.CodeExecutionUpdate._Unknown; -export declare namespace CodeExecutionUpdate { - interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse, _Utils { +export namespace CodeExecutionUpdate { + export interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse, _Utils { type: "buildingExecutor"; } - interface Running extends SeedTrace.RunningResponse, _Utils { + export interface Running extends SeedTrace.RunningResponse, _Utils { type: "running"; } - interface Errored extends SeedTrace.ErroredResponse, _Utils { + export interface Errored extends SeedTrace.ErroredResponse, _Utils { type: "errored"; } - interface Stopped extends SeedTrace.StoppedResponse, _Utils { + export interface Stopped extends SeedTrace.StoppedResponse, _Utils { type: "stopped"; } - interface Graded extends SeedTrace.GradedResponse, _Utils { + export interface Graded extends SeedTrace.GradedResponse, _Utils { type: "graded"; } - interface GradedV2 extends SeedTrace.GradedResponseV2, _Utils { + export interface GradedV2 extends SeedTrace.GradedResponseV2, _Utils { type: "gradedV2"; } - interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse, _Utils { + export interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse, _Utils { type: "workspaceRan"; } - interface Recording extends SeedTrace.RecordingResponseNotification, _Utils { + export interface Recording extends SeedTrace.RecordingResponseNotification, _Utils { type: "recording"; } - interface Recorded extends SeedTrace.RecordedResponseNotification, _Utils { + export interface Recorded extends SeedTrace.RecordedResponseNotification, _Utils { type: "recorded"; } - interface InvalidRequest extends SeedTrace.InvalidRequestResponse, _Utils { + export interface InvalidRequest extends SeedTrace.InvalidRequestResponse, _Utils { type: "invalidRequest"; } - interface Finished extends SeedTrace.FinishedResponse, _Utils { + export interface Finished extends SeedTrace.FinishedResponse, _Utils { type: "finished"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ErrorInfo.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ErrorInfo.ts index 189862011e6..bfe5bd5e2ed 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ErrorInfo.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ErrorInfo.ts @@ -16,20 +16,20 @@ export type ErrorInfo = | SeedTrace.ErrorInfo.InternalError | SeedTrace.ErrorInfo._Unknown; -export declare namespace ErrorInfo { - interface CompileError extends SeedTrace.CompileError, _Utils { +export namespace ErrorInfo { + export interface CompileError extends SeedTrace.CompileError, _Utils { type: "compileError"; } - interface RuntimeError extends SeedTrace.RuntimeError, _Utils { + export interface RuntimeError extends SeedTrace.RuntimeError, _Utils { type: "runtimeError"; } - interface InternalError extends SeedTrace.InternalError, _Utils { + export interface InternalError extends SeedTrace.InternalError, _Utils { type: "internalError"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ExceptionV2.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ExceptionV2.ts index ffce92cb128..6fb68797407 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ExceptionV2.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ExceptionV2.ts @@ -9,16 +9,16 @@ export type ExceptionV2 = | SeedTrace.ExceptionV2.Timeout | SeedTrace.ExceptionV2._Unknown; -export declare namespace ExceptionV2 { - interface Generic extends SeedTrace.ExceptionInfo, _Utils { +export namespace ExceptionV2 { + export interface Generic extends SeedTrace.ExceptionInfo, _Utils { type: "generic"; } - interface Timeout extends _Utils { + export interface Timeout extends _Utils { type: "timeout"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ExecutionSessionStatus.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ExecutionSessionStatus.ts index ac12d367212..f9ceddf1e8e 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ExecutionSessionStatus.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/ExecutionSessionStatus.ts @@ -9,7 +9,6 @@ export type ExecutionSessionStatus = | "RUNNING_CONTAINER" | "LIVE_CONTAINER" | "FAILED_TO_LAUNCH"; - export const ExecutionSessionStatus = { CreatingContainer: "CREATING_CONTAINER", ProvisioningContainer: "PROVISIONING_CONTAINER", @@ -37,7 +36,7 @@ export const ExecutionSessionStatus = { }, } as const; -export declare namespace ExecutionSessionStatus { +export namespace ExecutionSessionStatus { interface Visitor { creatingContainer: () => R; provisioningContainer: () => R; diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/InvalidRequestCause.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/InvalidRequestCause.ts index 3b09e71fbd6..aff23851cc6 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/InvalidRequestCause.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/InvalidRequestCause.ts @@ -14,20 +14,20 @@ export type InvalidRequestCause = | SeedTrace.InvalidRequestCause.UnexpectedLanguage | SeedTrace.InvalidRequestCause._Unknown; -export declare namespace InvalidRequestCause { - interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound, _Utils { +export namespace InvalidRequestCause { + export interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound, _Utils { type: "submissionIdNotFound"; } - interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported, _Utils { + export interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported, _Utils { type: "customTestCasesUnsupported"; } - interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError, _Utils { + export interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError, _Utils { type: "unexpectedLanguage"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/RunningSubmissionState.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/RunningSubmissionState.ts index c66c82a3d7c..52ead490ced 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/RunningSubmissionState.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/RunningSubmissionState.ts @@ -8,7 +8,6 @@ export type RunningSubmissionState = | "WRITING_SUBMISSION_TO_FILE" | "COMPILING_SUBMISSION" | "RUNNING_SUBMISSION"; - export const RunningSubmissionState = { QueueingSubmission: "QUEUEING_SUBMISSION", KillingHistoricalSubmissions: "KILLING_HISTORICAL_SUBMISSIONS", @@ -33,7 +32,7 @@ export const RunningSubmissionState = { }, } as const; -export declare namespace RunningSubmissionState { +export namespace RunningSubmissionState { interface Visitor { queueingSubmission: () => R; killingHistoricalSubmissions: () => R; diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionRequest.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionRequest.ts index bb0c7edacc8..63518d03675 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionRequest.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionRequest.ts @@ -12,28 +12,28 @@ export type SubmissionRequest = | SeedTrace.SubmissionRequest.Stop | SeedTrace.SubmissionRequest._Unknown; -export declare namespace SubmissionRequest { - interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest, _Utils { +export namespace SubmissionRequest { + export interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest, _Utils { type: "initializeProblemRequest"; } - interface InitializeWorkspaceRequest extends _Utils { + export interface InitializeWorkspaceRequest extends _Utils { type: "initializeWorkspaceRequest"; } - interface SubmitV2 extends SeedTrace.SubmitRequestV2, _Utils { + export interface SubmitV2 extends SeedTrace.SubmitRequestV2, _Utils { type: "submitV2"; } - interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest, _Utils { + export interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest, _Utils { type: "workspaceSubmit"; } - interface Stop extends SeedTrace.StopRequest, _Utils { + export interface Stop extends SeedTrace.StopRequest, _Utils { type: "stop"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionResponse.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionResponse.ts index 498e739f65e..b24fc4f53c2 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionResponse.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionResponse.ts @@ -13,34 +13,34 @@ export type SubmissionResponse = | SeedTrace.SubmissionResponse.Terminated | SeedTrace.SubmissionResponse._Unknown; -export declare namespace SubmissionResponse { - interface ServerInitialized extends _Utils { +export namespace SubmissionResponse { + export interface ServerInitialized extends _Utils { type: "serverInitialized"; } - interface ProblemInitialized extends _Utils { + export interface ProblemInitialized extends _Utils { type: "problemInitialized"; value: SeedTrace.ProblemId; } - interface WorkspaceInitialized extends _Utils { + export interface WorkspaceInitialized extends _Utils { type: "workspaceInitialized"; } - interface ServerErrored extends SeedTrace.ExceptionInfo, _Utils { + export interface ServerErrored extends SeedTrace.ExceptionInfo, _Utils { type: "serverErrored"; } - interface CodeExecutionUpdate extends _Utils { + export interface CodeExecutionUpdate extends _Utils { type: "codeExecutionUpdate"; value: SeedTrace.CodeExecutionUpdate; } - interface Terminated extends SeedTrace.TerminatedResponse, _Utils { + export interface Terminated extends SeedTrace.TerminatedResponse, _Utils { type: "terminated"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionStatusForTestCase.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionStatusForTestCase.ts index 0168c0717c6..a329cbe4576 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionStatusForTestCase.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionStatusForTestCase.ts @@ -10,21 +10,21 @@ export type SubmissionStatusForTestCase = | SeedTrace.SubmissionStatusForTestCase.Traced | SeedTrace.SubmissionStatusForTestCase._Unknown; -export declare namespace SubmissionStatusForTestCase { - interface Graded extends SeedTrace.TestCaseResultWithStdout, _Utils { +export namespace SubmissionStatusForTestCase { + export interface Graded extends SeedTrace.TestCaseResultWithStdout, _Utils { type: "graded"; } - interface GradedV2 extends _Utils { + export interface GradedV2 extends _Utils { type: "gradedV2"; value: SeedTrace.TestCaseGrade; } - interface Traced extends SeedTrace.TracedTestCase, _Utils { + export interface Traced extends SeedTrace.TracedTestCase, _Utils { type: "traced"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionStatusV2.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionStatusV2.ts index 294f170f0fb..8c0f2f69f0c 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionStatusV2.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionStatusV2.ts @@ -9,16 +9,16 @@ export type SubmissionStatusV2 = | SeedTrace.SubmissionStatusV2.Workspace | SeedTrace.SubmissionStatusV2._Unknown; -export declare namespace SubmissionStatusV2 { - interface Test extends SeedTrace.TestSubmissionStatusV2, _Utils { +export namespace SubmissionStatusV2 { + export interface Test extends SeedTrace.TestSubmissionStatusV2, _Utils { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2, _Utils { + export interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2, _Utils { type: "workspace"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionTypeEnum.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionTypeEnum.ts index 1fde8fc6512..616c71202cc 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionTypeEnum.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionTypeEnum.ts @@ -6,7 +6,6 @@ * Keep in sync with SubmissionType. */ export type SubmissionTypeEnum = "TEST"; - export const SubmissionTypeEnum = { Test: "TEST", _visit: (value: SubmissionTypeEnum, visitor: SubmissionTypeEnum.Visitor) => { @@ -19,7 +18,7 @@ export const SubmissionTypeEnum = { }, } as const; -export declare namespace SubmissionTypeEnum { +export namespace SubmissionTypeEnum { interface Visitor { test: () => R; _other: () => R; diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionTypeState.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionTypeState.ts index f3a3dee8ac6..26f2c6a7149 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionTypeState.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/SubmissionTypeState.ts @@ -9,16 +9,16 @@ export type SubmissionTypeState = | SeedTrace.SubmissionTypeState.Workspace | SeedTrace.SubmissionTypeState._Unknown; -export declare namespace SubmissionTypeState { - interface Test extends SeedTrace.TestSubmissionState, _Utils { +export namespace SubmissionTypeState { + export interface Test extends SeedTrace.TestSubmissionState, _Utils { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionState, _Utils { + export interface Workspace extends SeedTrace.WorkspaceSubmissionState, _Utils { type: "workspace"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestCaseGrade.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestCaseGrade.ts index bde863deac5..3ef51aa1171 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestCaseGrade.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestCaseGrade.ts @@ -9,16 +9,16 @@ export type TestCaseGrade = | SeedTrace.TestCaseGrade.NonHidden | SeedTrace.TestCaseGrade._Unknown; -export declare namespace TestCaseGrade { - interface Hidden extends SeedTrace.TestCaseHiddenGrade, _Utils { +export namespace TestCaseGrade { + export interface Hidden extends SeedTrace.TestCaseHiddenGrade, _Utils { type: "hidden"; } - interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade, _Utils { + export interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade, _Utils { type: "nonHidden"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestSubmissionStatus.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestSubmissionStatus.ts index d6ca9ee22d0..abdd22562e0 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestSubmissionStatus.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestSubmissionStatus.ts @@ -11,27 +11,27 @@ export type TestSubmissionStatus = | SeedTrace.TestSubmissionStatus.TestCaseIdToState | SeedTrace.TestSubmissionStatus._Unknown; -export declare namespace TestSubmissionStatus { - interface Stopped extends _Utils { +export namespace TestSubmissionStatus { + export interface Stopped extends _Utils { type: "stopped"; } - interface Errored extends _Utils { + export interface Errored extends _Utils { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running extends _Utils { + export interface Running extends _Utils { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface TestCaseIdToState extends _Utils { + export interface TestCaseIdToState extends _Utils { type: "testCaseIdToState"; value: Record; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts index 0f1b2e43413..c21c27f1fbd 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts @@ -13,34 +13,34 @@ export type TestSubmissionUpdateInfo = | SeedTrace.TestSubmissionUpdateInfo.Finished | SeedTrace.TestSubmissionUpdateInfo._Unknown; -export declare namespace TestSubmissionUpdateInfo { - interface Running extends _Utils { +export namespace TestSubmissionUpdateInfo { + export interface Running extends _Utils { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Stopped extends _Utils { + export interface Stopped extends _Utils { type: "stopped"; } - interface Errored extends _Utils { + export interface Errored extends _Utils { type: "errored"; value: SeedTrace.ErrorInfo; } - interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate, _Utils { + export interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate, _Utils { type: "gradedTestCase"; } - interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate, _Utils { + export interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate, _Utils { type: "recordedTestCase"; } - interface Finished extends _Utils { + export interface Finished extends _Utils { type: "finished"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts index 2789ee784a4..6b5763a630e 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts @@ -12,30 +12,30 @@ export type WorkspaceSubmissionStatus = | SeedTrace.WorkspaceSubmissionStatus.Traced | SeedTrace.WorkspaceSubmissionStatus._Unknown; -export declare namespace WorkspaceSubmissionStatus { - interface Stopped extends _Utils { +export namespace WorkspaceSubmissionStatus { + export interface Stopped extends _Utils { type: "stopped"; } - interface Errored extends _Utils { + export interface Errored extends _Utils { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running extends _Utils { + export interface Running extends _Utils { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails, _Utils { + export interface Ran extends SeedTrace.WorkspaceRunDetails, _Utils { type: "ran"; } - interface Traced extends SeedTrace.WorkspaceRunDetails, _Utils { + export interface Traced extends SeedTrace.WorkspaceRunDetails, _Utils { type: "traced"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts index 5cb7bbf55ef..44d040d3b79 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts @@ -14,38 +14,38 @@ export type WorkspaceSubmissionUpdateInfo = | SeedTrace.WorkspaceSubmissionUpdateInfo.Finished | SeedTrace.WorkspaceSubmissionUpdateInfo._Unknown; -export declare namespace WorkspaceSubmissionUpdateInfo { - interface Running extends _Utils { +export namespace WorkspaceSubmissionUpdateInfo { + export interface Running extends _Utils { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails, _Utils { + export interface Ran extends SeedTrace.WorkspaceRunDetails, _Utils { type: "ran"; } - interface Stopped extends _Utils { + export interface Stopped extends _Utils { type: "stopped"; } - interface Traced extends _Utils { + export interface Traced extends _Utils { type: "traced"; } - interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate, _Utils { + export interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate, _Utils { type: "tracedV2"; } - interface Errored extends _Utils { + export interface Errored extends _Utils { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Finished extends _Utils { + export interface Finished extends _Utils { type: "finished"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/sysprop/client/getNumWarmInstances.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/sysprop/client/getNumWarmInstances.ts index 2fbe6fe6340..a092e8cbc9d 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/sysprop/client/getNumWarmInstances.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/sysprop/client/getNumWarmInstances.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.sysprop.getNumWarmInstances.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/sysprop/client/setNumWarmInstances.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/sysprop/client/setNumWarmInstances.ts index c05b711ce4b..e76687c82e5 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/sysprop/client/setNumWarmInstances.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/sysprop/client/setNumWarmInstances.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.sysprop.setNumWarmInstances.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/client/Client.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/client/Client.ts index d12b3ac96e0..cdef4245681 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/client/Client.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/client/Client.ts @@ -31,8 +31,19 @@ export declare namespace V2 { } export class V2 { + protected _problem: Problem | undefined; + protected _v3: V3 | undefined; + constructor(protected readonly _options: V2.Options = {}) {} + public get problem(): Problem { + return (this._problem ??= new Problem(this._options)); + } + + public get v3(): V3 { + return (this._v3 ??= new V3(this._options)); + } + /** * @param {V2.RequestOptions} requestOptions - Request-specific configuration. * @@ -77,18 +88,6 @@ export class V2 { }; } - protected _problem: Problem | undefined; - - public get problem(): Problem { - return (this._problem ??= new Problem(this._options)); - } - - protected _v3: V3 | undefined; - - public get v3(): V3 { - return (this._v3 ??= new V3(this._options)); - } - protected async _getAuthorizationHeader(): Promise { const bearer = await core.Supplier.get(this._options.token); if (bearer != null) { diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/client/test.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/client/test.ts index 5489d587dcc..15afe8ecb4a 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/client/test.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/client/test.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.v2.test.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getLatestProblem.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getLatestProblem.ts index bcd228e8d79..e1160446754 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getLatestProblem.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getLatestProblem.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = SeedTrace.v2.problem.getLatestProblem.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getLightweightProblems.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getLightweightProblems.ts index 18e3b2fe8b3..f7fd0419cca 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getLightweightProblems.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getLightweightProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = SeedTrace.v2.problem.getLightweightProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getProblemVersion.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getProblemVersion.ts index 664ea0fb4cd..bb947517665 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getProblemVersion.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getProblemVersion.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = SeedTrace.v2.problem.getProblemVersion.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getProblems.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getProblems.ts index 01c8049b685..1e9745e7690 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getProblems.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/client/getProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = SeedTrace.v2.problem.getProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts index b87837a11e5..ef6278afde5 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts @@ -9,16 +9,16 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.AssertCorrectnessCheck.Custom | SeedTrace.v2.AssertCorrectnessCheck._Unknown; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck, _Utils { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck, _Utils { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult, _Utils { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult, _Utils { type: "custom"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/CustomFiles.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/CustomFiles.ts index 80a50f027ee..cb96ac45c38 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/CustomFiles.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/CustomFiles.ts @@ -9,17 +9,17 @@ export type CustomFiles = | SeedTrace.v2.CustomFiles.Custom | SeedTrace.v2.CustomFiles._Unknown; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.BasicCustomFiles, _Utils { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.BasicCustomFiles, _Utils { type: "basic"; } - interface Custom extends _Utils { + export interface Custom extends _Utils { type: "custom"; value: Record; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/FunctionSignature.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/FunctionSignature.ts index 339d8caeb32..7064e1c93e6 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/FunctionSignature.ts @@ -12,20 +12,20 @@ export type FunctionSignature = | SeedTrace.v2.FunctionSignature.VoidThatTakesActualResult | SeedTrace.v2.FunctionSignature._Unknown; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.VoidFunctionSignature, _Utils { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.VoidFunctionSignature, _Utils { type: "void"; } - interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature, _Utils { + export interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature, _Utils { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult, _Utils { + export interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult, _Utils { type: "voidThatTakesActualResult"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts index 1c960602ef0..a8648c0edbe 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts @@ -9,16 +9,16 @@ export type TestCaseFunction = | SeedTrace.v2.TestCaseFunction.Custom | SeedTrace.v2.TestCaseFunction._Unknown; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation, _Utils { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation, _Utils { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinition, _Utils { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinition, _Utils { type: "custom"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index 100a8e4bc92..0389ab4435f 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -9,18 +9,18 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.TestCaseImplementationDescriptionBoard.ParamId | SeedTrace.v2.TestCaseImplementationDescriptionBoard._Unknown; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html extends _Utils { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html extends _Utils { type: "html"; value: string; } - interface ParamId extends _Utils { + export interface ParamId extends _Utils { type: "paramId"; value: SeedTrace.v2.ParameterId; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts index d1feb62f857..99a1c30cb7f 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts @@ -9,17 +9,17 @@ export type TestCaseImplementationReference = | SeedTrace.v2.TestCaseImplementationReference.Implementation | SeedTrace.v2.TestCaseImplementationReference._Unknown; -export declare namespace TestCaseImplementationReference { - interface TemplateId extends _Utils { +export namespace TestCaseImplementationReference { + export interface TemplateId extends _Utils { type: "templateId"; value: SeedTrace.v2.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.TestCaseImplementation, _Utils { + export interface Implementation extends SeedTrace.v2.TestCaseImplementation, _Utils { type: "implementation"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/client/Client.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/client/Client.ts index faa07d6c9d0..4aa14f494e7 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/client/Client.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/client/Client.ts @@ -29,10 +29,10 @@ export declare namespace V3 { } export class V3 { - constructor(protected readonly _options: V3.Options = {}) {} - protected _problem: Problem | undefined; + constructor(protected readonly _options: V3.Options = {}) {} + public get problem(): Problem { return (this._problem ??= new Problem(this._options)); } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getLatestProblem.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getLatestProblem.ts index ec2892469b6..0e5953ecb81 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getLatestProblem.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getLatestProblem.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../../../core"; export type Error = SeedTrace.v2.v3.problem.getLatestProblem.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getLightweightProblems.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getLightweightProblems.ts index ff69d578898..6a6f577b7f7 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getLightweightProblems.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getLightweightProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../../../core"; export type Error = SeedTrace.v2.v3.problem.getLightweightProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getProblemVersion.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getProblemVersion.ts index e6e69d0f876..4db0092c4fc 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getProblemVersion.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getProblemVersion.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../../../core"; export type Error = SeedTrace.v2.v3.problem.getProblemVersion.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getProblems.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getProblems.ts index 4345097e352..0c76996aa04 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getProblems.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/client/getProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../../../core"; export type Error = SeedTrace.v2.v3.problem.getProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown extends _Utils { +export namespace Error { + export interface _Unknown extends _Utils { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts index 0285cec1783..b3f40f97cc8 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts @@ -9,16 +9,16 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.v3.AssertCorrectnessCheck.Custom | SeedTrace.v2.v3.AssertCorrectnessCheck._Unknown; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck, _Utils { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck, _Utils { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult, _Utils { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult, _Utils { type: "custom"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts index f637f5718d1..9db9cb178c3 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts @@ -9,17 +9,17 @@ export type CustomFiles = | SeedTrace.v2.v3.CustomFiles.Custom | SeedTrace.v2.v3.CustomFiles._Unknown; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.v3.BasicCustomFiles, _Utils { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.v3.BasicCustomFiles, _Utils { type: "basic"; } - interface Custom extends _Utils { + export interface Custom extends _Utils { type: "custom"; value: Record; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts index 12346615b0a..f3ac103b0a8 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts @@ -12,20 +12,22 @@ export type FunctionSignature = | SeedTrace.v2.v3.FunctionSignature.VoidThatTakesActualResult | SeedTrace.v2.v3.FunctionSignature._Unknown; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.v3.VoidFunctionSignature, _Utils { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.v3.VoidFunctionSignature, _Utils { type: "void"; } - interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature, _Utils { + export interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature, _Utils { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult, _Utils { + export interface VoidThatTakesActualResult + extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult, + _Utils { type: "voidThatTakesActualResult"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts index 2f5dbe5686b..c36515bbcd4 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts @@ -9,16 +9,16 @@ export type TestCaseFunction = | SeedTrace.v2.v3.TestCaseFunction.Custom | SeedTrace.v2.v3.TestCaseFunction._Unknown; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation, _Utils { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation, _Utils { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition, _Utils { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition, _Utils { type: "custom"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index 7303457c0ea..201d8ba610d 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -9,18 +9,18 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.ParamId | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard._Unknown; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html extends _Utils { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html extends _Utils { type: "html"; value: string; } - interface ParamId extends _Utils { + export interface ParamId extends _Utils { type: "paramId"; value: SeedTrace.v2.v3.ParameterId; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts index 4f4a6331ca8..33428f2197e 100644 --- a/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-sdk/trace/exhaustive/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts @@ -9,17 +9,17 @@ export type TestCaseImplementationReference = | SeedTrace.v2.v3.TestCaseImplementationReference.Implementation | SeedTrace.v2.v3.TestCaseImplementationReference._Unknown; -export declare namespace TestCaseImplementationReference { - interface TemplateId extends _Utils { +export namespace TestCaseImplementationReference { + export interface TemplateId extends _Utils { type: "templateId"; value: SeedTrace.v2.v3.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation, _Utils { + export interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation, _Utils { type: "implementation"; } - interface _Unknown extends _Utils { + export interface _Unknown extends _Utils { type: void; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/Client.ts b/seed/ts-sdk/trace/no-custom-config/src/Client.ts index 29bb5b0d035..845a9793bbd 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/Client.ts @@ -36,52 +36,45 @@ export declare namespace SeedTraceClient { } export class SeedTraceClient { - constructor(protected readonly _options: SeedTraceClient.Options = {}) {} - protected _v2: V2 | undefined; + protected _admin: Admin | undefined; + protected _homepage: Homepage | undefined; + protected _migration: Migration | undefined; + protected _playlist: Playlist | undefined; + protected _problem: Problem | undefined; + protected _submission: Submission | undefined; + protected _sysprop: Sysprop | undefined; + + constructor(protected readonly _options: SeedTraceClient.Options = {}) {} public get v2(): V2 { return (this._v2 ??= new V2(this._options)); } - protected _admin: Admin | undefined; - public get admin(): Admin { return (this._admin ??= new Admin(this._options)); } - protected _homepage: Homepage | undefined; - public get homepage(): Homepage { return (this._homepage ??= new Homepage(this._options)); } - protected _migration: Migration | undefined; - public get migration(): Migration { return (this._migration ??= new Migration(this._options)); } - protected _playlist: Playlist | undefined; - public get playlist(): Playlist { return (this._playlist ??= new Playlist(this._options)); } - protected _problem: Problem | undefined; - public get problem(): Problem { return (this._problem ??= new Problem(this._options)); } - protected _submission: Submission | undefined; - public get submission(): Submission { return (this._submission ??= new Submission(this._options)); } - protected _sysprop: Sysprop | undefined; - public get sysprop(): Sysprop { return (this._sysprop ??= new Sysprop(this._options)); } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/admin/types/Test.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/admin/types/Test.ts index 70dd2b7fc56..ae63f5ef12d 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/admin/types/Test.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/admin/types/Test.ts @@ -6,13 +6,13 @@ import * as SeedTrace from "../../../index"; export type Test = SeedTrace.Test.And | SeedTrace.Test.Or; -export declare namespace Test { - interface And { +export namespace Test { + export interface And { type: "and"; value: boolean; } - interface Or { + export interface Or { type: "or"; value: boolean; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/DebugVariableValue.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/DebugVariableValue.ts index 7c3eaed6311..ac7f88480fc 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/DebugVariableValue.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/DebugVariableValue.ts @@ -19,62 +19,62 @@ export type DebugVariableValue = | SeedTrace.DebugVariableValue.NullValue | SeedTrace.DebugVariableValue.GenericValue; -export declare namespace DebugVariableValue { - interface IntegerValue { +export namespace DebugVariableValue { + export interface IntegerValue { type: "integerValue"; value: number; } - interface BooleanValue { + export interface BooleanValue { type: "booleanValue"; value: boolean; } - interface DoubleValue { + export interface DoubleValue { type: "doubleValue"; value: number; } - interface StringValue { + export interface StringValue { type: "stringValue"; value: string; } - interface CharValue { + export interface CharValue { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.DebugMapValue { + export interface MapValue extends SeedTrace.DebugMapValue { type: "mapValue"; } - interface ListValue { + export interface ListValue { type: "listValue"; value: SeedTrace.DebugVariableValue[]; } - interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue { + export interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue { type: "binaryTreeNodeValue"; } - interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue { + export interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue { type: "singlyLinkedListNodeValue"; } - interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue { + export interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue { type: "doublyLinkedListNodeValue"; } - interface UndefinedValue { + export interface UndefinedValue { type: "undefinedValue"; } - interface NullValue { + export interface NullValue { type: "nullValue"; } - interface GenericValue extends SeedTrace.GenericValue { + export interface GenericValue extends SeedTrace.GenericValue { type: "genericValue"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/Language.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/Language.ts index 0cc47c2d31f..7f1719a43ea 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/Language.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/Language.ts @@ -3,7 +3,6 @@ */ export type Language = "JAVA" | "JAVASCRIPT" | "PYTHON"; - export const Language = { Java: "JAVA", Javascript: "JAVASCRIPT", diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/VariableType.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/VariableType.ts index 3725c71223d..d38a364dfe5 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/VariableType.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/VariableType.ts @@ -16,44 +16,44 @@ export type VariableType = | SeedTrace.VariableType.SinglyLinkedListType | SeedTrace.VariableType.DoublyLinkedListType; -export declare namespace VariableType { - interface IntegerType { +export namespace VariableType { + export interface IntegerType { type: "integerType"; } - interface DoubleType { + export interface DoubleType { type: "doubleType"; } - interface BooleanType { + export interface BooleanType { type: "booleanType"; } - interface StringType { + export interface StringType { type: "stringType"; } - interface CharType { + export interface CharType { type: "charType"; } - interface ListType extends SeedTrace.ListType { + export interface ListType extends SeedTrace.ListType { type: "listType"; } - interface MapType extends SeedTrace.MapType { + export interface MapType extends SeedTrace.MapType { type: "mapType"; } - interface BinaryTreeType { + export interface BinaryTreeType { type: "binaryTreeType"; } - interface SinglyLinkedListType { + export interface SinglyLinkedListType { type: "singlyLinkedListType"; } - interface DoublyLinkedListType { + export interface DoublyLinkedListType { type: "doublyLinkedListType"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/VariableValue.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/VariableValue.ts index d73c90ca9d7..94240a2c2b4 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/VariableValue.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/commons/types/VariableValue.ts @@ -17,54 +17,54 @@ export type VariableValue = | SeedTrace.VariableValue.DoublyLinkedListValue | SeedTrace.VariableValue.NullValue; -export declare namespace VariableValue { - interface IntegerValue { +export namespace VariableValue { + export interface IntegerValue { type: "integerValue"; value: number; } - interface BooleanValue { + export interface BooleanValue { type: "booleanValue"; value: boolean; } - interface DoubleValue { + export interface DoubleValue { type: "doubleValue"; value: number; } - interface StringValue { + export interface StringValue { type: "stringValue"; value: string; } - interface CharValue { + export interface CharValue { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.MapValue { + export interface MapValue extends SeedTrace.MapValue { type: "mapValue"; } - interface ListValue { + export interface ListValue { type: "listValue"; value: SeedTrace.VariableValue[]; } - interface BinaryTreeValue extends SeedTrace.BinaryTreeValue { + export interface BinaryTreeValue extends SeedTrace.BinaryTreeValue { type: "binaryTreeValue"; } - interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue { + export interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue { type: "singlyLinkedListValue"; } - interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue { + export interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue { type: "doublyLinkedListValue"; } - interface NullValue { + export interface NullValue { type: "nullValue"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/migration/types/MigrationStatus.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/migration/types/MigrationStatus.ts index 0a6bc6f9b03..a38078ae2c0 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/migration/types/MigrationStatus.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/migration/types/MigrationStatus.ts @@ -10,7 +10,6 @@ export type MigrationStatus = * The migration is failed */ | "FAILED" | "FINISHED"; - export const MigrationStatus = { Running: "RUNNING", Failed: "FAILED", diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts index 577034ea128..83901a81226 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts @@ -6,8 +6,8 @@ import * as SeedTrace from "../../../index"; export type PlaylistIdNotFoundErrorBody = SeedTrace.PlaylistIdNotFoundErrorBody.PlaylistId; -export declare namespace PlaylistIdNotFoundErrorBody { - interface PlaylistId { +export namespace PlaylistIdNotFoundErrorBody { + export interface PlaylistId { type: "playlistId"; value: SeedTrace.PlaylistId; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/playlist/types/ReservedKeywordEnum.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/playlist/types/ReservedKeywordEnum.ts index 8ccd3d4c13e..a77a48fd64a 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/playlist/types/ReservedKeywordEnum.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/playlist/types/ReservedKeywordEnum.ts @@ -3,7 +3,6 @@ */ export type ReservedKeywordEnum = "is" | "as"; - export const ReservedKeywordEnum = { Is: "is", As: "as", diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/CreateProblemError.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/CreateProblemError.ts index 3543a716884..b49568ddd08 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/CreateProblemError.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/CreateProblemError.ts @@ -6,8 +6,8 @@ import * as SeedTrace from "../../../index"; export type CreateProblemError = SeedTrace.CreateProblemError.Generic; -export declare namespace CreateProblemError { - interface Generic extends SeedTrace.GenericCreateProblemError { +export namespace CreateProblemError { + export interface Generic extends SeedTrace.GenericCreateProblemError { errorType: "generic"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/CreateProblemResponse.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/CreateProblemResponse.ts index 80f89cfcb84..0e4095cac69 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/CreateProblemResponse.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/CreateProblemResponse.ts @@ -6,13 +6,13 @@ import * as SeedTrace from "../../../index"; export type CreateProblemResponse = SeedTrace.CreateProblemResponse.Success | SeedTrace.CreateProblemResponse.Error_; -export declare namespace CreateProblemResponse { - interface Success { +export namespace CreateProblemResponse { + export interface Success { type: "success"; value: SeedTrace.ProblemId; } - interface Error_ { + export interface Error_ { type: "error"; value: SeedTrace.CreateProblemError; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/ProblemDescriptionBoard.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/ProblemDescriptionBoard.ts index ae5a369c3e7..efcc213fcbb 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/ProblemDescriptionBoard.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/problem/types/ProblemDescriptionBoard.ts @@ -9,18 +9,18 @@ export type ProblemDescriptionBoard = | SeedTrace.ProblemDescriptionBoard.Variable | SeedTrace.ProblemDescriptionBoard.TestCaseId; -export declare namespace ProblemDescriptionBoard { - interface Html { +export namespace ProblemDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface Variable { + export interface Variable { type: "variable"; value: SeedTrace.VariableValue; } - interface TestCaseId { + export interface TestCaseId { type: "testCaseId"; value: string; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ActualResult.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ActualResult.ts index 6986afad702..b78eb0c13b9 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ActualResult.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ActualResult.ts @@ -9,17 +9,17 @@ export type ActualResult = | SeedTrace.ActualResult.Exception | SeedTrace.ActualResult.ExceptionV2; -export declare namespace ActualResult { - interface Value { +export namespace ActualResult { + export interface Value { type: "value"; value: SeedTrace.VariableValue; } - interface Exception extends SeedTrace.ExceptionInfo { + export interface Exception extends SeedTrace.ExceptionInfo { type: "exception"; } - interface ExceptionV2 { + export interface ExceptionV2 { type: "exceptionV2"; value: SeedTrace.ExceptionV2; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/CodeExecutionUpdate.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/CodeExecutionUpdate.ts index 7e17d4aa354..9e41b5a9000 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/CodeExecutionUpdate.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/CodeExecutionUpdate.ts @@ -39,48 +39,48 @@ export type CodeExecutionUpdate = * Sent once a submission is graded and fully recorded. */ | SeedTrace.CodeExecutionUpdate.Finished; -export declare namespace CodeExecutionUpdate { - interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse { +export namespace CodeExecutionUpdate { + export interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse { type: "buildingExecutor"; } - interface Running extends SeedTrace.RunningResponse { + export interface Running extends SeedTrace.RunningResponse { type: "running"; } - interface Errored extends SeedTrace.ErroredResponse { + export interface Errored extends SeedTrace.ErroredResponse { type: "errored"; } - interface Stopped extends SeedTrace.StoppedResponse { + export interface Stopped extends SeedTrace.StoppedResponse { type: "stopped"; } - interface Graded extends SeedTrace.GradedResponse { + export interface Graded extends SeedTrace.GradedResponse { type: "graded"; } - interface GradedV2 extends SeedTrace.GradedResponseV2 { + export interface GradedV2 extends SeedTrace.GradedResponseV2 { type: "gradedV2"; } - interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse { + export interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse { type: "workspaceRan"; } - interface Recording extends SeedTrace.RecordingResponseNotification { + export interface Recording extends SeedTrace.RecordingResponseNotification { type: "recording"; } - interface Recorded extends SeedTrace.RecordedResponseNotification { + export interface Recorded extends SeedTrace.RecordedResponseNotification { type: "recorded"; } - interface InvalidRequest extends SeedTrace.InvalidRequestResponse { + export interface InvalidRequest extends SeedTrace.InvalidRequestResponse { type: "invalidRequest"; } - interface Finished extends SeedTrace.FinishedResponse { + export interface Finished extends SeedTrace.FinishedResponse { type: "finished"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ErrorInfo.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ErrorInfo.ts index ef3283fe81e..ddb886b4c9a 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ErrorInfo.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ErrorInfo.ts @@ -15,16 +15,16 @@ export type ErrorInfo = * */ | SeedTrace.ErrorInfo.InternalError; -export declare namespace ErrorInfo { - interface CompileError extends SeedTrace.CompileError { +export namespace ErrorInfo { + export interface CompileError extends SeedTrace.CompileError { type: "compileError"; } - interface RuntimeError extends SeedTrace.RuntimeError { + export interface RuntimeError extends SeedTrace.RuntimeError { type: "runtimeError"; } - interface InternalError extends SeedTrace.InternalError { + export interface InternalError extends SeedTrace.InternalError { type: "internalError"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ExceptionV2.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ExceptionV2.ts index 880817d708d..f43362137ad 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ExceptionV2.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ExceptionV2.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type ExceptionV2 = SeedTrace.ExceptionV2.Generic | SeedTrace.ExceptionV2.Timeout; -export declare namespace ExceptionV2 { - interface Generic extends SeedTrace.ExceptionInfo { +export namespace ExceptionV2 { + export interface Generic extends SeedTrace.ExceptionInfo { type: "generic"; } - interface Timeout { + export interface Timeout { type: "timeout"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ExecutionSessionStatus.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ExecutionSessionStatus.ts index a14d2035332..3709aaa7a69 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ExecutionSessionStatus.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/ExecutionSessionStatus.ts @@ -9,7 +9,6 @@ export type ExecutionSessionStatus = | "RUNNING_CONTAINER" | "LIVE_CONTAINER" | "FAILED_TO_LAUNCH"; - export const ExecutionSessionStatus = { CreatingContainer: "CREATING_CONTAINER", ProvisioningContainer: "PROVISIONING_CONTAINER", diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/InvalidRequestCause.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/InvalidRequestCause.ts index 3bb60f89b0f..3504cf7eaa3 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/InvalidRequestCause.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/InvalidRequestCause.ts @@ -13,16 +13,16 @@ export type InvalidRequestCause = * The submission request was routed to an incorrect language executor. */ | SeedTrace.InvalidRequestCause.UnexpectedLanguage; -export declare namespace InvalidRequestCause { - interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound { +export namespace InvalidRequestCause { + export interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound { type: "submissionIdNotFound"; } - interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported { + export interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported { type: "customTestCasesUnsupported"; } - interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError { + export interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError { type: "unexpectedLanguage"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/RunningSubmissionState.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/RunningSubmissionState.ts index 5d15c5180a9..38031ccd887 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/RunningSubmissionState.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/RunningSubmissionState.ts @@ -8,7 +8,6 @@ export type RunningSubmissionState = | "WRITING_SUBMISSION_TO_FILE" | "COMPILING_SUBMISSION" | "RUNNING_SUBMISSION"; - export const RunningSubmissionState = { QueueingSubmission: "QUEUEING_SUBMISSION", KillingHistoricalSubmissions: "KILLING_HISTORICAL_SUBMISSIONS", diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionRequest.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionRequest.ts index e63f940c5b8..e4907b98e7c 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionRequest.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionRequest.ts @@ -11,24 +11,24 @@ export type SubmissionRequest = | SeedTrace.SubmissionRequest.WorkspaceSubmit | SeedTrace.SubmissionRequest.Stop; -export declare namespace SubmissionRequest { - interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest { +export namespace SubmissionRequest { + export interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest { type: "initializeProblemRequest"; } - interface InitializeWorkspaceRequest { + export interface InitializeWorkspaceRequest { type: "initializeWorkspaceRequest"; } - interface SubmitV2 extends SeedTrace.SubmitRequestV2 { + export interface SubmitV2 extends SeedTrace.SubmitRequestV2 { type: "submitV2"; } - interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest { + export interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest { type: "workspaceSubmit"; } - interface Stop extends SeedTrace.StopRequest { + export interface Stop extends SeedTrace.StopRequest { type: "stop"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionResponse.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionResponse.ts index d2fb3f8172f..ca463a332a6 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionResponse.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionResponse.ts @@ -12,30 +12,30 @@ export type SubmissionResponse = | SeedTrace.SubmissionResponse.CodeExecutionUpdate | SeedTrace.SubmissionResponse.Terminated; -export declare namespace SubmissionResponse { - interface ServerInitialized { +export namespace SubmissionResponse { + export interface ServerInitialized { type: "serverInitialized"; } - interface ProblemInitialized { + export interface ProblemInitialized { type: "problemInitialized"; value: SeedTrace.ProblemId; } - interface WorkspaceInitialized { + export interface WorkspaceInitialized { type: "workspaceInitialized"; } - interface ServerErrored extends SeedTrace.ExceptionInfo { + export interface ServerErrored extends SeedTrace.ExceptionInfo { type: "serverErrored"; } - interface CodeExecutionUpdate { + export interface CodeExecutionUpdate { type: "codeExecutionUpdate"; value: SeedTrace.CodeExecutionUpdate; } - interface Terminated extends SeedTrace.TerminatedResponse { + export interface Terminated extends SeedTrace.TerminatedResponse { type: "terminated"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionStatusForTestCase.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionStatusForTestCase.ts index 8698643d86b..dd0d6039fee 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionStatusForTestCase.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionStatusForTestCase.ts @@ -9,17 +9,17 @@ export type SubmissionStatusForTestCase = | SeedTrace.SubmissionStatusForTestCase.GradedV2 | SeedTrace.SubmissionStatusForTestCase.Traced; -export declare namespace SubmissionStatusForTestCase { - interface Graded extends SeedTrace.TestCaseResultWithStdout { +export namespace SubmissionStatusForTestCase { + export interface Graded extends SeedTrace.TestCaseResultWithStdout { type: "graded"; } - interface GradedV2 { + export interface GradedV2 { type: "gradedV2"; value: SeedTrace.TestCaseGrade; } - interface Traced extends SeedTrace.TracedTestCase { + export interface Traced extends SeedTrace.TracedTestCase { type: "traced"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionStatusV2.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionStatusV2.ts index 652c732c408..95710f67978 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionStatusV2.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionStatusV2.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type SubmissionStatusV2 = SeedTrace.SubmissionStatusV2.Test | SeedTrace.SubmissionStatusV2.Workspace; -export declare namespace SubmissionStatusV2 { - interface Test extends SeedTrace.TestSubmissionStatusV2 { +export namespace SubmissionStatusV2 { + export interface Test extends SeedTrace.TestSubmissionStatusV2 { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2 { + export interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2 { type: "workspace"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionTypeEnum.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionTypeEnum.ts index bff5583dad7..8414392abfc 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionTypeEnum.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionTypeEnum.ts @@ -6,7 +6,6 @@ * Keep in sync with SubmissionType. */ export type SubmissionTypeEnum = "TEST"; - export const SubmissionTypeEnum = { Test: "TEST", } as const; diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionTypeState.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionTypeState.ts index fa4855ce698..c811ee050db 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionTypeState.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/SubmissionTypeState.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type SubmissionTypeState = SeedTrace.SubmissionTypeState.Test | SeedTrace.SubmissionTypeState.Workspace; -export declare namespace SubmissionTypeState { - interface Test extends SeedTrace.TestSubmissionState { +export namespace SubmissionTypeState { + export interface Test extends SeedTrace.TestSubmissionState { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionState { + export interface Workspace extends SeedTrace.WorkspaceSubmissionState { type: "workspace"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestCaseGrade.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestCaseGrade.ts index 2f02296e05a..901cf5fc6ec 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestCaseGrade.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestCaseGrade.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type TestCaseGrade = SeedTrace.TestCaseGrade.Hidden | SeedTrace.TestCaseGrade.NonHidden; -export declare namespace TestCaseGrade { - interface Hidden extends SeedTrace.TestCaseHiddenGrade { +export namespace TestCaseGrade { + export interface Hidden extends SeedTrace.TestCaseHiddenGrade { type: "hidden"; } - interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade { + export interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade { type: "nonHidden"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestSubmissionStatus.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestSubmissionStatus.ts index da3e7c63984..04dc0c011e9 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestSubmissionStatus.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestSubmissionStatus.ts @@ -10,22 +10,22 @@ export type TestSubmissionStatus = | SeedTrace.TestSubmissionStatus.Running | SeedTrace.TestSubmissionStatus.TestCaseIdToState; -export declare namespace TestSubmissionStatus { - interface Stopped { +export namespace TestSubmissionStatus { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface TestCaseIdToState { + export interface TestCaseIdToState { type: "testCaseIdToState"; value: Record; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts index 69a146a5067..f04f0e0479c 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts @@ -12,30 +12,30 @@ export type TestSubmissionUpdateInfo = | SeedTrace.TestSubmissionUpdateInfo.RecordedTestCase | SeedTrace.TestSubmissionUpdateInfo.Finished; -export declare namespace TestSubmissionUpdateInfo { - interface Running { +export namespace TestSubmissionUpdateInfo { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Stopped { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate { + export interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate { type: "gradedTestCase"; } - interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate { + export interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate { type: "recordedTestCase"; } - interface Finished { + export interface Finished { type: "finished"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts index 5151126e193..cad2d60cdae 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts @@ -11,26 +11,26 @@ export type WorkspaceSubmissionStatus = | SeedTrace.WorkspaceSubmissionStatus.Ran | SeedTrace.WorkspaceSubmissionStatus.Traced; -export declare namespace WorkspaceSubmissionStatus { - interface Stopped { +export namespace WorkspaceSubmissionStatus { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails { + export interface Ran extends SeedTrace.WorkspaceRunDetails { type: "ran"; } - interface Traced extends SeedTrace.WorkspaceRunDetails { + export interface Traced extends SeedTrace.WorkspaceRunDetails { type: "traced"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts index 78c1249225c..a8b008b38fb 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts @@ -13,34 +13,34 @@ export type WorkspaceSubmissionUpdateInfo = | SeedTrace.WorkspaceSubmissionUpdateInfo.Errored | SeedTrace.WorkspaceSubmissionUpdateInfo.Finished; -export declare namespace WorkspaceSubmissionUpdateInfo { - interface Running { +export namespace WorkspaceSubmissionUpdateInfo { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails { + export interface Ran extends SeedTrace.WorkspaceRunDetails { type: "ran"; } - interface Stopped { + export interface Stopped { type: "stopped"; } - interface Traced { + export interface Traced { type: "traced"; } - interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate { + export interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate { type: "tracedV2"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Finished { + export interface Finished { type: "finished"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/client/Client.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/client/Client.ts index ea7ff879e01..627705ac28b 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/client/Client.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/client/Client.ts @@ -31,8 +31,19 @@ export declare namespace V2 { } export class V2 { + protected _problem: Problem | undefined; + protected _v3: V3 | undefined; + constructor(protected readonly _options: V2.Options = {}) {} + public get problem(): Problem { + return (this._problem ??= new Problem(this._options)); + } + + public get v3(): V3 { + return (this._v3 ??= new V3(this._options)); + } + /** * @param {V2.RequestOptions} requestOptions - Request-specific configuration. * @@ -89,18 +100,6 @@ export class V2 { } } - protected _problem: Problem | undefined; - - public get problem(): Problem { - return (this._problem ??= new Problem(this._options)); - } - - protected _v3: V3 | undefined; - - public get v3(): V3 { - return (this._v3 ??= new V3(this._options)); - } - protected async _getAuthorizationHeader(): Promise { const bearer = await core.Supplier.get(this._options.token); if (bearer != null) { diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts index 85c6b996461..d2be6b87b97 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts @@ -8,12 +8,12 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.AssertCorrectnessCheck.DeepEquality | SeedTrace.v2.AssertCorrectnessCheck.Custom; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/CustomFiles.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/CustomFiles.ts index b430b089eaf..06ccba9d49d 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/CustomFiles.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/CustomFiles.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../index"; export type CustomFiles = SeedTrace.v2.CustomFiles.Basic | SeedTrace.v2.CustomFiles.Custom; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.BasicCustomFiles { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.BasicCustomFiles { type: "basic"; } - interface Custom { + export interface Custom { type: "custom"; value: Record; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/FunctionSignature.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/FunctionSignature.ts index 251760cd97e..f4adeea0b90 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/FunctionSignature.ts @@ -11,16 +11,16 @@ export type FunctionSignature = * Useful when specifying custom grading for a testcase where actualResult is defined. */ | SeedTrace.v2.FunctionSignature.VoidThatTakesActualResult; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.VoidFunctionSignature { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.VoidFunctionSignature { type: "void"; } - interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature { + export interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult { + export interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult { type: "voidThatTakesActualResult"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts index c70bdafe6bb..cc8ea6e85c2 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../index"; export type TestCaseFunction = SeedTrace.v2.TestCaseFunction.WithActualResult | SeedTrace.v2.TestCaseFunction.Custom; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinition { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinition { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index af60df46b61..3a83452376c 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.TestCaseImplementationDescriptionBoard.Html | SeedTrace.v2.TestCaseImplementationDescriptionBoard.ParamId; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface ParamId { + export interface ParamId { type: "paramId"; value: SeedTrace.v2.ParameterId; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts index 045115835ab..66182e14e9f 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationReference = | SeedTrace.v2.TestCaseImplementationReference.TemplateId | SeedTrace.v2.TestCaseImplementationReference.Implementation; -export declare namespace TestCaseImplementationReference { - interface TemplateId { +export namespace TestCaseImplementationReference { + export interface TemplateId { type: "templateId"; value: SeedTrace.v2.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.TestCaseImplementation { + export interface Implementation extends SeedTrace.v2.TestCaseImplementation { type: "implementation"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/client/Client.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/client/Client.ts index faa07d6c9d0..4aa14f494e7 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/client/Client.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/client/Client.ts @@ -29,10 +29,10 @@ export declare namespace V3 { } export class V3 { - constructor(protected readonly _options: V3.Options = {}) {} - protected _problem: Problem | undefined; + constructor(protected readonly _options: V3.Options = {}) {} + public get problem(): Problem { return (this._problem ??= new Problem(this._options)); } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts index 79d32643560..2c0e9b49c7c 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts @@ -8,12 +8,12 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.v3.AssertCorrectnessCheck.DeepEquality | SeedTrace.v2.v3.AssertCorrectnessCheck.Custom; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts index 4ac8078742b..c287f6286f3 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../../../index"; export type CustomFiles = SeedTrace.v2.v3.CustomFiles.Basic | SeedTrace.v2.v3.CustomFiles.Custom; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.v3.BasicCustomFiles { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.v3.BasicCustomFiles { type: "basic"; } - interface Custom { + export interface Custom { type: "custom"; value: Record; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts index 548b1d9092b..82243201aba 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts @@ -11,16 +11,16 @@ export type FunctionSignature = * Useful when specifying custom grading for a testcase where actualResult is defined. */ | SeedTrace.v2.v3.FunctionSignature.VoidThatTakesActualResult; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.v3.VoidFunctionSignature { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.v3.VoidFunctionSignature { type: "void"; } - interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature { + export interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult { + export interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult { type: "voidThatTakesActualResult"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts index 2381196a692..031ff15274d 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts @@ -8,12 +8,12 @@ export type TestCaseFunction = | SeedTrace.v2.v3.TestCaseFunction.WithActualResult | SeedTrace.v2.v3.TestCaseFunction.Custom; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index 8d670c214fc..157e99b52ac 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.Html | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.ParamId; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface ParamId { + export interface ParamId { type: "paramId"; value: SeedTrace.v2.v3.ParameterId; } diff --git a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts index 0fad5ef9988..67af0e57047 100644 --- a/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-sdk/trace/no-custom-config/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationReference = | SeedTrace.v2.v3.TestCaseImplementationReference.TemplateId | SeedTrace.v2.v3.TestCaseImplementationReference.Implementation; -export declare namespace TestCaseImplementationReference { - interface TemplateId { +export namespace TestCaseImplementationReference { + export interface TemplateId { type: "templateId"; value: SeedTrace.v2.v3.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation { + export interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation { type: "implementation"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/Client.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/Client.ts index 29bb5b0d035..845a9793bbd 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/Client.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/Client.ts @@ -36,52 +36,45 @@ export declare namespace SeedTraceClient { } export class SeedTraceClient { - constructor(protected readonly _options: SeedTraceClient.Options = {}) {} - protected _v2: V2 | undefined; + protected _admin: Admin | undefined; + protected _homepage: Homepage | undefined; + protected _migration: Migration | undefined; + protected _playlist: Playlist | undefined; + protected _problem: Problem | undefined; + protected _submission: Submission | undefined; + protected _sysprop: Sysprop | undefined; + + constructor(protected readonly _options: SeedTraceClient.Options = {}) {} public get v2(): V2 { return (this._v2 ??= new V2(this._options)); } - protected _admin: Admin | undefined; - public get admin(): Admin { return (this._admin ??= new Admin(this._options)); } - protected _homepage: Homepage | undefined; - public get homepage(): Homepage { return (this._homepage ??= new Homepage(this._options)); } - protected _migration: Migration | undefined; - public get migration(): Migration { return (this._migration ??= new Migration(this._options)); } - protected _playlist: Playlist | undefined; - public get playlist(): Playlist { return (this._playlist ??= new Playlist(this._options)); } - protected _problem: Problem | undefined; - public get problem(): Problem { return (this._problem ??= new Problem(this._options)); } - protected _submission: Submission | undefined; - public get submission(): Submission { return (this._submission ??= new Submission(this._options)); } - protected _sysprop: Sysprop | undefined; - public get sysprop(): Sysprop { return (this._sysprop ??= new Sysprop(this._options)); } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/sendTestSubmissionUpdate.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/sendTestSubmissionUpdate.ts index eec07e30120..b08e04a3524 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/sendTestSubmissionUpdate.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/sendTestSubmissionUpdate.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.sendTestSubmissionUpdate.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/sendWorkspaceSubmissionUpdate.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/sendWorkspaceSubmissionUpdate.ts index b0a56a39870..c2984df097e 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/sendWorkspaceSubmissionUpdate.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/sendWorkspaceSubmissionUpdate.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.sendWorkspaceSubmissionUpdate.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedTestCase.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedTestCase.ts index 19d598e0405..901fc880591 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedTestCase.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedTestCase.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.storeTracedTestCase.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedTestCaseV2.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedTestCaseV2.ts index 0f13ecc153b..3dbefdbb131 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedTestCaseV2.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedTestCaseV2.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.storeTracedTestCaseV2.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedWorkspace.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedWorkspace.ts index a711edee146..c66b90bf64c 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedWorkspace.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedWorkspace.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.storeTracedWorkspace.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedWorkspaceV2.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedWorkspaceV2.ts index 0e0c23976b1..10dc0fe37a4 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedWorkspaceV2.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/storeTracedWorkspaceV2.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.storeTracedWorkspaceV2.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/updateTestSubmissionStatus.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/updateTestSubmissionStatus.ts index 8e83111fdf0..fc534e63a7d 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/updateTestSubmissionStatus.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/updateTestSubmissionStatus.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.updateTestSubmissionStatus.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/updateWorkspaceSubmissionStatus.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/updateWorkspaceSubmissionStatus.ts index 108c80b875d..ede0482f33b 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/updateWorkspaceSubmissionStatus.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/client/updateWorkspaceSubmissionStatus.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.admin.updateWorkspaceSubmissionStatus.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/types/Test.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/types/Test.ts index 70dd2b7fc56..ae63f5ef12d 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/types/Test.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/admin/types/Test.ts @@ -6,13 +6,13 @@ import * as SeedTrace from "../../../index"; export type Test = SeedTrace.Test.And | SeedTrace.Test.Or; -export declare namespace Test { - interface And { +export namespace Test { + export interface And { type: "and"; value: boolean; } - interface Or { + export interface Or { type: "or"; value: boolean; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/DebugVariableValue.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/DebugVariableValue.ts index 7c3eaed6311..ac7f88480fc 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/DebugVariableValue.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/DebugVariableValue.ts @@ -19,62 +19,62 @@ export type DebugVariableValue = | SeedTrace.DebugVariableValue.NullValue | SeedTrace.DebugVariableValue.GenericValue; -export declare namespace DebugVariableValue { - interface IntegerValue { +export namespace DebugVariableValue { + export interface IntegerValue { type: "integerValue"; value: number; } - interface BooleanValue { + export interface BooleanValue { type: "booleanValue"; value: boolean; } - interface DoubleValue { + export interface DoubleValue { type: "doubleValue"; value: number; } - interface StringValue { + export interface StringValue { type: "stringValue"; value: string; } - interface CharValue { + export interface CharValue { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.DebugMapValue { + export interface MapValue extends SeedTrace.DebugMapValue { type: "mapValue"; } - interface ListValue { + export interface ListValue { type: "listValue"; value: SeedTrace.DebugVariableValue[]; } - interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue { + export interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue { type: "binaryTreeNodeValue"; } - interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue { + export interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue { type: "singlyLinkedListNodeValue"; } - interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue { + export interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue { type: "doublyLinkedListNodeValue"; } - interface UndefinedValue { + export interface UndefinedValue { type: "undefinedValue"; } - interface NullValue { + export interface NullValue { type: "nullValue"; } - interface GenericValue extends SeedTrace.GenericValue { + export interface GenericValue extends SeedTrace.GenericValue { type: "genericValue"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/Language.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/Language.ts index 0cc47c2d31f..7f1719a43ea 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/Language.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/Language.ts @@ -3,7 +3,6 @@ */ export type Language = "JAVA" | "JAVASCRIPT" | "PYTHON"; - export const Language = { Java: "JAVA", Javascript: "JAVASCRIPT", diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/VariableType.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/VariableType.ts index 3725c71223d..d38a364dfe5 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/VariableType.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/VariableType.ts @@ -16,44 +16,44 @@ export type VariableType = | SeedTrace.VariableType.SinglyLinkedListType | SeedTrace.VariableType.DoublyLinkedListType; -export declare namespace VariableType { - interface IntegerType { +export namespace VariableType { + export interface IntegerType { type: "integerType"; } - interface DoubleType { + export interface DoubleType { type: "doubleType"; } - interface BooleanType { + export interface BooleanType { type: "booleanType"; } - interface StringType { + export interface StringType { type: "stringType"; } - interface CharType { + export interface CharType { type: "charType"; } - interface ListType extends SeedTrace.ListType { + export interface ListType extends SeedTrace.ListType { type: "listType"; } - interface MapType extends SeedTrace.MapType { + export interface MapType extends SeedTrace.MapType { type: "mapType"; } - interface BinaryTreeType { + export interface BinaryTreeType { type: "binaryTreeType"; } - interface SinglyLinkedListType { + export interface SinglyLinkedListType { type: "singlyLinkedListType"; } - interface DoublyLinkedListType { + export interface DoublyLinkedListType { type: "doublyLinkedListType"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/VariableValue.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/VariableValue.ts index d73c90ca9d7..94240a2c2b4 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/VariableValue.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/commons/types/VariableValue.ts @@ -17,54 +17,54 @@ export type VariableValue = | SeedTrace.VariableValue.DoublyLinkedListValue | SeedTrace.VariableValue.NullValue; -export declare namespace VariableValue { - interface IntegerValue { +export namespace VariableValue { + export interface IntegerValue { type: "integerValue"; value: number; } - interface BooleanValue { + export interface BooleanValue { type: "booleanValue"; value: boolean; } - interface DoubleValue { + export interface DoubleValue { type: "doubleValue"; value: number; } - interface StringValue { + export interface StringValue { type: "stringValue"; value: string; } - interface CharValue { + export interface CharValue { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.MapValue { + export interface MapValue extends SeedTrace.MapValue { type: "mapValue"; } - interface ListValue { + export interface ListValue { type: "listValue"; value: SeedTrace.VariableValue[]; } - interface BinaryTreeValue extends SeedTrace.BinaryTreeValue { + export interface BinaryTreeValue extends SeedTrace.BinaryTreeValue { type: "binaryTreeValue"; } - interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue { + export interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue { type: "singlyLinkedListValue"; } - interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue { + export interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue { type: "doublyLinkedListValue"; } - interface NullValue { + export interface NullValue { type: "nullValue"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/homepage/client/getHomepageProblems.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/homepage/client/getHomepageProblems.ts index 465074e1b40..f1ba1d97bf5 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/homepage/client/getHomepageProblems.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/homepage/client/getHomepageProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.homepage.getHomepageProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/homepage/client/setHomepageProblems.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/homepage/client/setHomepageProblems.ts index 04d6308a84b..cf1ff349c4c 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/homepage/client/setHomepageProblems.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/homepage/client/setHomepageProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.homepage.setHomepageProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/migration/client/getAttemptedMigrations.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/migration/client/getAttemptedMigrations.ts index 0d6dccc0ff9..3a07736e2de 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/migration/client/getAttemptedMigrations.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/migration/client/getAttemptedMigrations.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.migration.getAttemptedMigrations.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/migration/types/MigrationStatus.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/migration/types/MigrationStatus.ts index 0a6bc6f9b03..a38078ae2c0 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/migration/types/MigrationStatus.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/migration/types/MigrationStatus.ts @@ -10,7 +10,6 @@ export type MigrationStatus = * The migration is failed */ | "FAILED" | "FINISHED"; - export const MigrationStatus = { Running: "RUNNING", Failed: "FAILED", diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/createPlaylist.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/createPlaylist.ts index d850bafccf0..18cd93b87fd 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/createPlaylist.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/createPlaylist.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.playlist.createPlaylist.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/deletePlaylist.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/deletePlaylist.ts index 3eeeb7f616d..bfafedbf47a 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/deletePlaylist.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/deletePlaylist.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.playlist.deletePlaylist.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/getPlaylist.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/getPlaylist.ts index 2baeaa1876d..8752fd81406 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/getPlaylist.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/getPlaylist.ts @@ -10,17 +10,17 @@ export type Error = | SeedTrace.playlist.getPlaylist.Error.UnauthorizedError | SeedTrace.playlist.getPlaylist.Error._Unknown; -export declare namespace Error { - interface PlaylistIdNotFoundError { +export namespace Error { + export interface PlaylistIdNotFoundError { errorName: "PlaylistIdNotFoundError"; content: SeedTrace.PlaylistIdNotFoundErrorBody; } - interface UnauthorizedError { + export interface UnauthorizedError { errorName: "UnauthorizedError"; } - interface _Unknown { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/getPlaylists.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/getPlaylists.ts index 6445f8675f5..f53afc34e11 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/getPlaylists.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/getPlaylists.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.playlist.getPlaylists.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/updatePlaylist.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/updatePlaylist.ts index 31b7c6ff14c..52d878912e7 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/updatePlaylist.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/client/updatePlaylist.ts @@ -9,13 +9,13 @@ export type Error = | SeedTrace.playlist.updatePlaylist.Error.PlaylistIdNotFoundError | SeedTrace.playlist.updatePlaylist.Error._Unknown; -export declare namespace Error { - interface PlaylistIdNotFoundError { +export namespace Error { + export interface PlaylistIdNotFoundError { errorName: "PlaylistIdNotFoundError"; content: SeedTrace.PlaylistIdNotFoundErrorBody; } - interface _Unknown { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts index 577034ea128..83901a81226 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts @@ -6,8 +6,8 @@ import * as SeedTrace from "../../../index"; export type PlaylistIdNotFoundErrorBody = SeedTrace.PlaylistIdNotFoundErrorBody.PlaylistId; -export declare namespace PlaylistIdNotFoundErrorBody { - interface PlaylistId { +export namespace PlaylistIdNotFoundErrorBody { + export interface PlaylistId { type: "playlistId"; value: SeedTrace.PlaylistId; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/types/ReservedKeywordEnum.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/types/ReservedKeywordEnum.ts index 8ccd3d4c13e..a77a48fd64a 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/types/ReservedKeywordEnum.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/playlist/types/ReservedKeywordEnum.ts @@ -3,7 +3,6 @@ */ export type ReservedKeywordEnum = "is" | "as"; - export const ReservedKeywordEnum = { Is: "is", As: "as", diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/createProblem.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/createProblem.ts index 4d71e3566b8..b942c582330 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/createProblem.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/createProblem.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.problem.createProblem.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/deleteProblem.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/deleteProblem.ts index 1bb52d4994d..c91bcc1f8d1 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/deleteProblem.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/deleteProblem.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.problem.deleteProblem.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/getDefaultStarterFiles.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/getDefaultStarterFiles.ts index 5d9dab79145..5cb56541d6f 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/getDefaultStarterFiles.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/getDefaultStarterFiles.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.problem.getDefaultStarterFiles.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/updateProblem.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/updateProblem.ts index dae3cef602a..019388eca10 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/updateProblem.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/client/updateProblem.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.problem.updateProblem.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/CreateProblemError.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/CreateProblemError.ts index e764e29d34c..c43c26296dc 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/CreateProblemError.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/CreateProblemError.ts @@ -6,8 +6,8 @@ import * as SeedTrace from "../../../index"; export type CreateProblemError = SeedTrace.CreateProblemError.Generic; -export declare namespace CreateProblemError { - interface Generic extends SeedTrace.GenericCreateProblemError { +export namespace CreateProblemError { + export interface Generic extends SeedTrace.GenericCreateProblemError { _type: "generic"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/CreateProblemResponse.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/CreateProblemResponse.ts index 80f89cfcb84..0e4095cac69 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/CreateProblemResponse.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/CreateProblemResponse.ts @@ -6,13 +6,13 @@ import * as SeedTrace from "../../../index"; export type CreateProblemResponse = SeedTrace.CreateProblemResponse.Success | SeedTrace.CreateProblemResponse.Error_; -export declare namespace CreateProblemResponse { - interface Success { +export namespace CreateProblemResponse { + export interface Success { type: "success"; value: SeedTrace.ProblemId; } - interface Error_ { + export interface Error_ { type: "error"; value: SeedTrace.CreateProblemError; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/ProblemDescriptionBoard.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/ProblemDescriptionBoard.ts index ae5a369c3e7..efcc213fcbb 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/ProblemDescriptionBoard.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/problem/types/ProblemDescriptionBoard.ts @@ -9,18 +9,18 @@ export type ProblemDescriptionBoard = | SeedTrace.ProblemDescriptionBoard.Variable | SeedTrace.ProblemDescriptionBoard.TestCaseId; -export declare namespace ProblemDescriptionBoard { - interface Html { +export namespace ProblemDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface Variable { + export interface Variable { type: "variable"; value: SeedTrace.VariableValue; } - interface TestCaseId { + export interface TestCaseId { type: "testCaseId"; value: string; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/createExecutionSession.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/createExecutionSession.ts index 7474eb137ea..706aed35364 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/createExecutionSession.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/createExecutionSession.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.submission.createExecutionSession.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/getExecutionSession.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/getExecutionSession.ts index e445833f935..227c26b047d 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/getExecutionSession.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/getExecutionSession.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.submission.getExecutionSession.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/getExecutionSessionsState.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/getExecutionSessionsState.ts index 14752d4b6aa..11312af8b2f 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/getExecutionSessionsState.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/getExecutionSessionsState.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.submission.getExecutionSessionsState.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/stopExecutionSession.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/stopExecutionSession.ts index c1409855bcf..7b7f47ce33a 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/stopExecutionSession.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/client/stopExecutionSession.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.submission.stopExecutionSession.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ActualResult.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ActualResult.ts index 6986afad702..b78eb0c13b9 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ActualResult.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ActualResult.ts @@ -9,17 +9,17 @@ export type ActualResult = | SeedTrace.ActualResult.Exception | SeedTrace.ActualResult.ExceptionV2; -export declare namespace ActualResult { - interface Value { +export namespace ActualResult { + export interface Value { type: "value"; value: SeedTrace.VariableValue; } - interface Exception extends SeedTrace.ExceptionInfo { + export interface Exception extends SeedTrace.ExceptionInfo { type: "exception"; } - interface ExceptionV2 { + export interface ExceptionV2 { type: "exceptionV2"; value: SeedTrace.ExceptionV2; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/CodeExecutionUpdate.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/CodeExecutionUpdate.ts index 7e17d4aa354..9e41b5a9000 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/CodeExecutionUpdate.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/CodeExecutionUpdate.ts @@ -39,48 +39,48 @@ export type CodeExecutionUpdate = * Sent once a submission is graded and fully recorded. */ | SeedTrace.CodeExecutionUpdate.Finished; -export declare namespace CodeExecutionUpdate { - interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse { +export namespace CodeExecutionUpdate { + export interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse { type: "buildingExecutor"; } - interface Running extends SeedTrace.RunningResponse { + export interface Running extends SeedTrace.RunningResponse { type: "running"; } - interface Errored extends SeedTrace.ErroredResponse { + export interface Errored extends SeedTrace.ErroredResponse { type: "errored"; } - interface Stopped extends SeedTrace.StoppedResponse { + export interface Stopped extends SeedTrace.StoppedResponse { type: "stopped"; } - interface Graded extends SeedTrace.GradedResponse { + export interface Graded extends SeedTrace.GradedResponse { type: "graded"; } - interface GradedV2 extends SeedTrace.GradedResponseV2 { + export interface GradedV2 extends SeedTrace.GradedResponseV2 { type: "gradedV2"; } - interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse { + export interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse { type: "workspaceRan"; } - interface Recording extends SeedTrace.RecordingResponseNotification { + export interface Recording extends SeedTrace.RecordingResponseNotification { type: "recording"; } - interface Recorded extends SeedTrace.RecordedResponseNotification { + export interface Recorded extends SeedTrace.RecordedResponseNotification { type: "recorded"; } - interface InvalidRequest extends SeedTrace.InvalidRequestResponse { + export interface InvalidRequest extends SeedTrace.InvalidRequestResponse { type: "invalidRequest"; } - interface Finished extends SeedTrace.FinishedResponse { + export interface Finished extends SeedTrace.FinishedResponse { type: "finished"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ErrorInfo.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ErrorInfo.ts index ef3283fe81e..ddb886b4c9a 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ErrorInfo.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ErrorInfo.ts @@ -15,16 +15,16 @@ export type ErrorInfo = * */ | SeedTrace.ErrorInfo.InternalError; -export declare namespace ErrorInfo { - interface CompileError extends SeedTrace.CompileError { +export namespace ErrorInfo { + export interface CompileError extends SeedTrace.CompileError { type: "compileError"; } - interface RuntimeError extends SeedTrace.RuntimeError { + export interface RuntimeError extends SeedTrace.RuntimeError { type: "runtimeError"; } - interface InternalError extends SeedTrace.InternalError { + export interface InternalError extends SeedTrace.InternalError { type: "internalError"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ExceptionV2.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ExceptionV2.ts index 880817d708d..f43362137ad 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ExceptionV2.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ExceptionV2.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type ExceptionV2 = SeedTrace.ExceptionV2.Generic | SeedTrace.ExceptionV2.Timeout; -export declare namespace ExceptionV2 { - interface Generic extends SeedTrace.ExceptionInfo { +export namespace ExceptionV2 { + export interface Generic extends SeedTrace.ExceptionInfo { type: "generic"; } - interface Timeout { + export interface Timeout { type: "timeout"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ExecutionSessionStatus.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ExecutionSessionStatus.ts index a14d2035332..3709aaa7a69 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ExecutionSessionStatus.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/ExecutionSessionStatus.ts @@ -9,7 +9,6 @@ export type ExecutionSessionStatus = | "RUNNING_CONTAINER" | "LIVE_CONTAINER" | "FAILED_TO_LAUNCH"; - export const ExecutionSessionStatus = { CreatingContainer: "CREATING_CONTAINER", ProvisioningContainer: "PROVISIONING_CONTAINER", diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/InvalidRequestCause.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/InvalidRequestCause.ts index 3bb60f89b0f..3504cf7eaa3 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/InvalidRequestCause.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/InvalidRequestCause.ts @@ -13,16 +13,16 @@ export type InvalidRequestCause = * The submission request was routed to an incorrect language executor. */ | SeedTrace.InvalidRequestCause.UnexpectedLanguage; -export declare namespace InvalidRequestCause { - interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound { +export namespace InvalidRequestCause { + export interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound { type: "submissionIdNotFound"; } - interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported { + export interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported { type: "customTestCasesUnsupported"; } - interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError { + export interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError { type: "unexpectedLanguage"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/RunningSubmissionState.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/RunningSubmissionState.ts index 5d15c5180a9..38031ccd887 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/RunningSubmissionState.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/RunningSubmissionState.ts @@ -8,7 +8,6 @@ export type RunningSubmissionState = | "WRITING_SUBMISSION_TO_FILE" | "COMPILING_SUBMISSION" | "RUNNING_SUBMISSION"; - export const RunningSubmissionState = { QueueingSubmission: "QUEUEING_SUBMISSION", KillingHistoricalSubmissions: "KILLING_HISTORICAL_SUBMISSIONS", diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionRequest.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionRequest.ts index e63f940c5b8..e4907b98e7c 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionRequest.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionRequest.ts @@ -11,24 +11,24 @@ export type SubmissionRequest = | SeedTrace.SubmissionRequest.WorkspaceSubmit | SeedTrace.SubmissionRequest.Stop; -export declare namespace SubmissionRequest { - interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest { +export namespace SubmissionRequest { + export interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest { type: "initializeProblemRequest"; } - interface InitializeWorkspaceRequest { + export interface InitializeWorkspaceRequest { type: "initializeWorkspaceRequest"; } - interface SubmitV2 extends SeedTrace.SubmitRequestV2 { + export interface SubmitV2 extends SeedTrace.SubmitRequestV2 { type: "submitV2"; } - interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest { + export interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest { type: "workspaceSubmit"; } - interface Stop extends SeedTrace.StopRequest { + export interface Stop extends SeedTrace.StopRequest { type: "stop"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionResponse.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionResponse.ts index d2fb3f8172f..ca463a332a6 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionResponse.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionResponse.ts @@ -12,30 +12,30 @@ export type SubmissionResponse = | SeedTrace.SubmissionResponse.CodeExecutionUpdate | SeedTrace.SubmissionResponse.Terminated; -export declare namespace SubmissionResponse { - interface ServerInitialized { +export namespace SubmissionResponse { + export interface ServerInitialized { type: "serverInitialized"; } - interface ProblemInitialized { + export interface ProblemInitialized { type: "problemInitialized"; value: SeedTrace.ProblemId; } - interface WorkspaceInitialized { + export interface WorkspaceInitialized { type: "workspaceInitialized"; } - interface ServerErrored extends SeedTrace.ExceptionInfo { + export interface ServerErrored extends SeedTrace.ExceptionInfo { type: "serverErrored"; } - interface CodeExecutionUpdate { + export interface CodeExecutionUpdate { type: "codeExecutionUpdate"; value: SeedTrace.CodeExecutionUpdate; } - interface Terminated extends SeedTrace.TerminatedResponse { + export interface Terminated extends SeedTrace.TerminatedResponse { type: "terminated"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionStatusForTestCase.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionStatusForTestCase.ts index 8698643d86b..dd0d6039fee 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionStatusForTestCase.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionStatusForTestCase.ts @@ -9,17 +9,17 @@ export type SubmissionStatusForTestCase = | SeedTrace.SubmissionStatusForTestCase.GradedV2 | SeedTrace.SubmissionStatusForTestCase.Traced; -export declare namespace SubmissionStatusForTestCase { - interface Graded extends SeedTrace.TestCaseResultWithStdout { +export namespace SubmissionStatusForTestCase { + export interface Graded extends SeedTrace.TestCaseResultWithStdout { type: "graded"; } - interface GradedV2 { + export interface GradedV2 { type: "gradedV2"; value: SeedTrace.TestCaseGrade; } - interface Traced extends SeedTrace.TracedTestCase { + export interface Traced extends SeedTrace.TracedTestCase { type: "traced"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionStatusV2.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionStatusV2.ts index 652c732c408..95710f67978 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionStatusV2.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionStatusV2.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type SubmissionStatusV2 = SeedTrace.SubmissionStatusV2.Test | SeedTrace.SubmissionStatusV2.Workspace; -export declare namespace SubmissionStatusV2 { - interface Test extends SeedTrace.TestSubmissionStatusV2 { +export namespace SubmissionStatusV2 { + export interface Test extends SeedTrace.TestSubmissionStatusV2 { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2 { + export interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2 { type: "workspace"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionTypeEnum.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionTypeEnum.ts index bff5583dad7..8414392abfc 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionTypeEnum.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionTypeEnum.ts @@ -6,7 +6,6 @@ * Keep in sync with SubmissionType. */ export type SubmissionTypeEnum = "TEST"; - export const SubmissionTypeEnum = { Test: "TEST", } as const; diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionTypeState.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionTypeState.ts index fa4855ce698..c811ee050db 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionTypeState.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/SubmissionTypeState.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type SubmissionTypeState = SeedTrace.SubmissionTypeState.Test | SeedTrace.SubmissionTypeState.Workspace; -export declare namespace SubmissionTypeState { - interface Test extends SeedTrace.TestSubmissionState { +export namespace SubmissionTypeState { + export interface Test extends SeedTrace.TestSubmissionState { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionState { + export interface Workspace extends SeedTrace.WorkspaceSubmissionState { type: "workspace"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestCaseGrade.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestCaseGrade.ts index 2f02296e05a..901cf5fc6ec 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestCaseGrade.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestCaseGrade.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type TestCaseGrade = SeedTrace.TestCaseGrade.Hidden | SeedTrace.TestCaseGrade.NonHidden; -export declare namespace TestCaseGrade { - interface Hidden extends SeedTrace.TestCaseHiddenGrade { +export namespace TestCaseGrade { + export interface Hidden extends SeedTrace.TestCaseHiddenGrade { type: "hidden"; } - interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade { + export interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade { type: "nonHidden"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestSubmissionStatus.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestSubmissionStatus.ts index da3e7c63984..04dc0c011e9 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestSubmissionStatus.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestSubmissionStatus.ts @@ -10,22 +10,22 @@ export type TestSubmissionStatus = | SeedTrace.TestSubmissionStatus.Running | SeedTrace.TestSubmissionStatus.TestCaseIdToState; -export declare namespace TestSubmissionStatus { - interface Stopped { +export namespace TestSubmissionStatus { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface TestCaseIdToState { + export interface TestCaseIdToState { type: "testCaseIdToState"; value: Record; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts index 69a146a5067..f04f0e0479c 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts @@ -12,30 +12,30 @@ export type TestSubmissionUpdateInfo = | SeedTrace.TestSubmissionUpdateInfo.RecordedTestCase | SeedTrace.TestSubmissionUpdateInfo.Finished; -export declare namespace TestSubmissionUpdateInfo { - interface Running { +export namespace TestSubmissionUpdateInfo { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Stopped { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate { + export interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate { type: "gradedTestCase"; } - interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate { + export interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate { type: "recordedTestCase"; } - interface Finished { + export interface Finished { type: "finished"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts index 5151126e193..cad2d60cdae 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts @@ -11,26 +11,26 @@ export type WorkspaceSubmissionStatus = | SeedTrace.WorkspaceSubmissionStatus.Ran | SeedTrace.WorkspaceSubmissionStatus.Traced; -export declare namespace WorkspaceSubmissionStatus { - interface Stopped { +export namespace WorkspaceSubmissionStatus { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails { + export interface Ran extends SeedTrace.WorkspaceRunDetails { type: "ran"; } - interface Traced extends SeedTrace.WorkspaceRunDetails { + export interface Traced extends SeedTrace.WorkspaceRunDetails { type: "traced"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts index 78c1249225c..a8b008b38fb 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts @@ -13,34 +13,34 @@ export type WorkspaceSubmissionUpdateInfo = | SeedTrace.WorkspaceSubmissionUpdateInfo.Errored | SeedTrace.WorkspaceSubmissionUpdateInfo.Finished; -export declare namespace WorkspaceSubmissionUpdateInfo { - interface Running { +export namespace WorkspaceSubmissionUpdateInfo { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails { + export interface Ran extends SeedTrace.WorkspaceRunDetails { type: "ran"; } - interface Stopped { + export interface Stopped { type: "stopped"; } - interface Traced { + export interface Traced { type: "traced"; } - interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate { + export interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate { type: "tracedV2"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Finished { + export interface Finished { type: "finished"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/sysprop/client/getNumWarmInstances.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/sysprop/client/getNumWarmInstances.ts index d26a51dc1b9..ea8c71b3a80 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/sysprop/client/getNumWarmInstances.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/sysprop/client/getNumWarmInstances.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.sysprop.getNumWarmInstances.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/sysprop/client/setNumWarmInstances.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/sysprop/client/setNumWarmInstances.ts index 3dff5db21ce..183145b62d1 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/sysprop/client/setNumWarmInstances.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/sysprop/client/setNumWarmInstances.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.sysprop.setNumWarmInstances.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/client/Client.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/client/Client.ts index 525147c83e1..5d9a4606e81 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/client/Client.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/client/Client.ts @@ -31,8 +31,19 @@ export declare namespace V2 { } export class V2 { + protected _problem: Problem | undefined; + protected _v3: V3 | undefined; + constructor(protected readonly _options: V2.Options = {}) {} + public get problem(): Problem { + return (this._problem ??= new Problem(this._options)); + } + + public get v3(): V3 { + return (this._v3 ??= new V3(this._options)); + } + /** * @param {V2.RequestOptions} requestOptions - Request-specific configuration. * @@ -76,18 +87,6 @@ export class V2 { }; } - protected _problem: Problem | undefined; - - public get problem(): Problem { - return (this._problem ??= new Problem(this._options)); - } - - protected _v3: V3 | undefined; - - public get v3(): V3 { - return (this._v3 ??= new V3(this._options)); - } - protected async _getAuthorizationHeader(): Promise { const bearer = await core.Supplier.get(this._options.token); if (bearer != null) { diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/client/test.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/client/test.ts index 8c03d2c72ae..6668706ac9b 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/client/test.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/client/test.ts @@ -7,8 +7,8 @@ import * as core from "../../../../core"; export type Error = SeedTrace.v2.test.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getLatestProblem.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getLatestProblem.ts index a8ee64d9fcf..05cb79e9bfc 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getLatestProblem.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getLatestProblem.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = SeedTrace.v2.problem.getLatestProblem.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getLightweightProblems.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getLightweightProblems.ts index ce449821953..baf227cce5d 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getLightweightProblems.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getLightweightProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = SeedTrace.v2.problem.getLightweightProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getProblemVersion.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getProblemVersion.ts index 02a6825545b..77d38f1efef 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getProblemVersion.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getProblemVersion.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = SeedTrace.v2.problem.getProblemVersion.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getProblems.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getProblems.ts index 8a81e9dfde0..dd7032ef5ae 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getProblems.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/client/getProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../core"; export type Error = SeedTrace.v2.problem.getProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts index 85c6b996461..d2be6b87b97 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts @@ -8,12 +8,12 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.AssertCorrectnessCheck.DeepEquality | SeedTrace.v2.AssertCorrectnessCheck.Custom; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/CustomFiles.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/CustomFiles.ts index b430b089eaf..06ccba9d49d 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/CustomFiles.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/CustomFiles.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../index"; export type CustomFiles = SeedTrace.v2.CustomFiles.Basic | SeedTrace.v2.CustomFiles.Custom; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.BasicCustomFiles { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.BasicCustomFiles { type: "basic"; } - interface Custom { + export interface Custom { type: "custom"; value: Record; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/FunctionSignature.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/FunctionSignature.ts index 251760cd97e..f4adeea0b90 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/FunctionSignature.ts @@ -11,16 +11,16 @@ export type FunctionSignature = * Useful when specifying custom grading for a testcase where actualResult is defined. */ | SeedTrace.v2.FunctionSignature.VoidThatTakesActualResult; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.VoidFunctionSignature { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.VoidFunctionSignature { type: "void"; } - interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature { + export interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult { + export interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult { type: "voidThatTakesActualResult"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts index c70bdafe6bb..cc8ea6e85c2 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../index"; export type TestCaseFunction = SeedTrace.v2.TestCaseFunction.WithActualResult | SeedTrace.v2.TestCaseFunction.Custom; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinition { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinition { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index af60df46b61..3a83452376c 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.TestCaseImplementationDescriptionBoard.Html | SeedTrace.v2.TestCaseImplementationDescriptionBoard.ParamId; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface ParamId { + export interface ParamId { type: "paramId"; value: SeedTrace.v2.ParameterId; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts index 045115835ab..66182e14e9f 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationReference = | SeedTrace.v2.TestCaseImplementationReference.TemplateId | SeedTrace.v2.TestCaseImplementationReference.Implementation; -export declare namespace TestCaseImplementationReference { - interface TemplateId { +export namespace TestCaseImplementationReference { + export interface TemplateId { type: "templateId"; value: SeedTrace.v2.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.TestCaseImplementation { + export interface Implementation extends SeedTrace.v2.TestCaseImplementation { type: "implementation"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/client/Client.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/client/Client.ts index faa07d6c9d0..4aa14f494e7 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/client/Client.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/client/Client.ts @@ -29,10 +29,10 @@ export declare namespace V3 { } export class V3 { - constructor(protected readonly _options: V3.Options = {}) {} - protected _problem: Problem | undefined; + constructor(protected readonly _options: V3.Options = {}) {} + public get problem(): Problem { return (this._problem ??= new Problem(this._options)); } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getLatestProblem.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getLatestProblem.ts index 6719c8d9048..28d41b27542 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getLatestProblem.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getLatestProblem.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../../../core"; export type Error = SeedTrace.v2.v3.problem.getLatestProblem.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getLightweightProblems.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getLightweightProblems.ts index 9d1f82a724f..ec0246578a7 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getLightweightProblems.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getLightweightProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../../../core"; export type Error = SeedTrace.v2.v3.problem.getLightweightProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getProblemVersion.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getProblemVersion.ts index d8bce253f79..56f797f11e4 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getProblemVersion.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getProblemVersion.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../../../core"; export type Error = SeedTrace.v2.v3.problem.getProblemVersion.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getProblems.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getProblems.ts index 080b2c5b870..b7da8da198c 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getProblems.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/client/getProblems.ts @@ -7,8 +7,8 @@ import * as core from "../../../../../../../../core"; export type Error = SeedTrace.v2.v3.problem.getProblems.Error._Unknown; -export declare namespace Error { - interface _Unknown { +export namespace Error { + export interface _Unknown { errorName: void; content: core.Fetcher.Error; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts index 79d32643560..2c0e9b49c7c 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts @@ -8,12 +8,12 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.v3.AssertCorrectnessCheck.DeepEquality | SeedTrace.v2.v3.AssertCorrectnessCheck.Custom; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts index 4ac8078742b..c287f6286f3 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../../../index"; export type CustomFiles = SeedTrace.v2.v3.CustomFiles.Basic | SeedTrace.v2.v3.CustomFiles.Custom; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.v3.BasicCustomFiles { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.v3.BasicCustomFiles { type: "basic"; } - interface Custom { + export interface Custom { type: "custom"; value: Record; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts index 548b1d9092b..82243201aba 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts @@ -11,16 +11,16 @@ export type FunctionSignature = * Useful when specifying custom grading for a testcase where actualResult is defined. */ | SeedTrace.v2.v3.FunctionSignature.VoidThatTakesActualResult; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.v3.VoidFunctionSignature { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.v3.VoidFunctionSignature { type: "void"; } - interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature { + export interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult { + export interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult { type: "voidThatTakesActualResult"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts index 2381196a692..031ff15274d 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts @@ -8,12 +8,12 @@ export type TestCaseFunction = | SeedTrace.v2.v3.TestCaseFunction.WithActualResult | SeedTrace.v2.v3.TestCaseFunction.Custom; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index 8d670c214fc..157e99b52ac 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.Html | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.ParamId; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface ParamId { + export interface ParamId { type: "paramId"; value: SeedTrace.v2.v3.ParameterId; } diff --git a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts index 0fad5ef9988..67af0e57047 100644 --- a/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-sdk/trace/no-zurg-no-throwing/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationReference = | SeedTrace.v2.v3.TestCaseImplementationReference.TemplateId | SeedTrace.v2.v3.TestCaseImplementationReference.Implementation; -export declare namespace TestCaseImplementationReference { - interface TemplateId { +export namespace TestCaseImplementationReference { + export interface TemplateId { type: "templateId"; value: SeedTrace.v2.v3.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation { + export interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation { type: "implementation"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/Client.ts b/seed/ts-sdk/trace/no-zurg-trace/src/Client.ts index 29bb5b0d035..845a9793bbd 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/Client.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/Client.ts @@ -36,52 +36,45 @@ export declare namespace SeedTraceClient { } export class SeedTraceClient { - constructor(protected readonly _options: SeedTraceClient.Options = {}) {} - protected _v2: V2 | undefined; + protected _admin: Admin | undefined; + protected _homepage: Homepage | undefined; + protected _migration: Migration | undefined; + protected _playlist: Playlist | undefined; + protected _problem: Problem | undefined; + protected _submission: Submission | undefined; + protected _sysprop: Sysprop | undefined; + + constructor(protected readonly _options: SeedTraceClient.Options = {}) {} public get v2(): V2 { return (this._v2 ??= new V2(this._options)); } - protected _admin: Admin | undefined; - public get admin(): Admin { return (this._admin ??= new Admin(this._options)); } - protected _homepage: Homepage | undefined; - public get homepage(): Homepage { return (this._homepage ??= new Homepage(this._options)); } - protected _migration: Migration | undefined; - public get migration(): Migration { return (this._migration ??= new Migration(this._options)); } - protected _playlist: Playlist | undefined; - public get playlist(): Playlist { return (this._playlist ??= new Playlist(this._options)); } - protected _problem: Problem | undefined; - public get problem(): Problem { return (this._problem ??= new Problem(this._options)); } - protected _submission: Submission | undefined; - public get submission(): Submission { return (this._submission ??= new Submission(this._options)); } - protected _sysprop: Sysprop | undefined; - public get sysprop(): Sysprop { return (this._sysprop ??= new Sysprop(this._options)); } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/admin/types/Test.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/admin/types/Test.ts index 70dd2b7fc56..ae63f5ef12d 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/admin/types/Test.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/admin/types/Test.ts @@ -6,13 +6,13 @@ import * as SeedTrace from "../../../index"; export type Test = SeedTrace.Test.And | SeedTrace.Test.Or; -export declare namespace Test { - interface And { +export namespace Test { + export interface And { type: "and"; value: boolean; } - interface Or { + export interface Or { type: "or"; value: boolean; } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/DebugVariableValue.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/DebugVariableValue.ts index 7c3eaed6311..ac7f88480fc 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/DebugVariableValue.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/DebugVariableValue.ts @@ -19,62 +19,62 @@ export type DebugVariableValue = | SeedTrace.DebugVariableValue.NullValue | SeedTrace.DebugVariableValue.GenericValue; -export declare namespace DebugVariableValue { - interface IntegerValue { +export namespace DebugVariableValue { + export interface IntegerValue { type: "integerValue"; value: number; } - interface BooleanValue { + export interface BooleanValue { type: "booleanValue"; value: boolean; } - interface DoubleValue { + export interface DoubleValue { type: "doubleValue"; value: number; } - interface StringValue { + export interface StringValue { type: "stringValue"; value: string; } - interface CharValue { + export interface CharValue { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.DebugMapValue { + export interface MapValue extends SeedTrace.DebugMapValue { type: "mapValue"; } - interface ListValue { + export interface ListValue { type: "listValue"; value: SeedTrace.DebugVariableValue[]; } - interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue { + export interface BinaryTreeNodeValue extends SeedTrace.BinaryTreeNodeAndTreeValue { type: "binaryTreeNodeValue"; } - interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue { + export interface SinglyLinkedListNodeValue extends SeedTrace.SinglyLinkedListNodeAndListValue { type: "singlyLinkedListNodeValue"; } - interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue { + export interface DoublyLinkedListNodeValue extends SeedTrace.DoublyLinkedListNodeAndListValue { type: "doublyLinkedListNodeValue"; } - interface UndefinedValue { + export interface UndefinedValue { type: "undefinedValue"; } - interface NullValue { + export interface NullValue { type: "nullValue"; } - interface GenericValue extends SeedTrace.GenericValue { + export interface GenericValue extends SeedTrace.GenericValue { type: "genericValue"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/Language.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/Language.ts index 0cc47c2d31f..7f1719a43ea 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/Language.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/Language.ts @@ -3,7 +3,6 @@ */ export type Language = "JAVA" | "JAVASCRIPT" | "PYTHON"; - export const Language = { Java: "JAVA", Javascript: "JAVASCRIPT", diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/VariableType.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/VariableType.ts index 3725c71223d..d38a364dfe5 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/VariableType.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/VariableType.ts @@ -16,44 +16,44 @@ export type VariableType = | SeedTrace.VariableType.SinglyLinkedListType | SeedTrace.VariableType.DoublyLinkedListType; -export declare namespace VariableType { - interface IntegerType { +export namespace VariableType { + export interface IntegerType { type: "integerType"; } - interface DoubleType { + export interface DoubleType { type: "doubleType"; } - interface BooleanType { + export interface BooleanType { type: "booleanType"; } - interface StringType { + export interface StringType { type: "stringType"; } - interface CharType { + export interface CharType { type: "charType"; } - interface ListType extends SeedTrace.ListType { + export interface ListType extends SeedTrace.ListType { type: "listType"; } - interface MapType extends SeedTrace.MapType { + export interface MapType extends SeedTrace.MapType { type: "mapType"; } - interface BinaryTreeType { + export interface BinaryTreeType { type: "binaryTreeType"; } - interface SinglyLinkedListType { + export interface SinglyLinkedListType { type: "singlyLinkedListType"; } - interface DoublyLinkedListType { + export interface DoublyLinkedListType { type: "doublyLinkedListType"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/VariableValue.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/VariableValue.ts index d73c90ca9d7..94240a2c2b4 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/VariableValue.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/commons/types/VariableValue.ts @@ -17,54 +17,54 @@ export type VariableValue = | SeedTrace.VariableValue.DoublyLinkedListValue | SeedTrace.VariableValue.NullValue; -export declare namespace VariableValue { - interface IntegerValue { +export namespace VariableValue { + export interface IntegerValue { type: "integerValue"; value: number; } - interface BooleanValue { + export interface BooleanValue { type: "booleanValue"; value: boolean; } - interface DoubleValue { + export interface DoubleValue { type: "doubleValue"; value: number; } - interface StringValue { + export interface StringValue { type: "stringValue"; value: string; } - interface CharValue { + export interface CharValue { type: "charValue"; value: string; } - interface MapValue extends SeedTrace.MapValue { + export interface MapValue extends SeedTrace.MapValue { type: "mapValue"; } - interface ListValue { + export interface ListValue { type: "listValue"; value: SeedTrace.VariableValue[]; } - interface BinaryTreeValue extends SeedTrace.BinaryTreeValue { + export interface BinaryTreeValue extends SeedTrace.BinaryTreeValue { type: "binaryTreeValue"; } - interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue { + export interface SinglyLinkedListValue extends SeedTrace.SinglyLinkedListValue { type: "singlyLinkedListValue"; } - interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue { + export interface DoublyLinkedListValue extends SeedTrace.DoublyLinkedListValue { type: "doublyLinkedListValue"; } - interface NullValue { + export interface NullValue { type: "nullValue"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/migration/types/MigrationStatus.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/migration/types/MigrationStatus.ts index 0a6bc6f9b03..a38078ae2c0 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/migration/types/MigrationStatus.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/migration/types/MigrationStatus.ts @@ -10,7 +10,6 @@ export type MigrationStatus = * The migration is failed */ | "FAILED" | "FINISHED"; - export const MigrationStatus = { Running: "RUNNING", Failed: "FAILED", diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts index 577034ea128..83901a81226 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/playlist/types/PlaylistIdNotFoundErrorBody.ts @@ -6,8 +6,8 @@ import * as SeedTrace from "../../../index"; export type PlaylistIdNotFoundErrorBody = SeedTrace.PlaylistIdNotFoundErrorBody.PlaylistId; -export declare namespace PlaylistIdNotFoundErrorBody { - interface PlaylistId { +export namespace PlaylistIdNotFoundErrorBody { + export interface PlaylistId { type: "playlistId"; value: SeedTrace.PlaylistId; } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/playlist/types/ReservedKeywordEnum.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/playlist/types/ReservedKeywordEnum.ts index 8ccd3d4c13e..a77a48fd64a 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/playlist/types/ReservedKeywordEnum.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/playlist/types/ReservedKeywordEnum.ts @@ -3,7 +3,6 @@ */ export type ReservedKeywordEnum = "is" | "as"; - export const ReservedKeywordEnum = { Is: "is", As: "as", diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/CreateProblemError.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/CreateProblemError.ts index e764e29d34c..c43c26296dc 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/CreateProblemError.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/CreateProblemError.ts @@ -6,8 +6,8 @@ import * as SeedTrace from "../../../index"; export type CreateProblemError = SeedTrace.CreateProblemError.Generic; -export declare namespace CreateProblemError { - interface Generic extends SeedTrace.GenericCreateProblemError { +export namespace CreateProblemError { + export interface Generic extends SeedTrace.GenericCreateProblemError { _type: "generic"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/CreateProblemResponse.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/CreateProblemResponse.ts index 80f89cfcb84..0e4095cac69 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/CreateProblemResponse.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/CreateProblemResponse.ts @@ -6,13 +6,13 @@ import * as SeedTrace from "../../../index"; export type CreateProblemResponse = SeedTrace.CreateProblemResponse.Success | SeedTrace.CreateProblemResponse.Error_; -export declare namespace CreateProblemResponse { - interface Success { +export namespace CreateProblemResponse { + export interface Success { type: "success"; value: SeedTrace.ProblemId; } - interface Error_ { + export interface Error_ { type: "error"; value: SeedTrace.CreateProblemError; } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/ProblemDescriptionBoard.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/ProblemDescriptionBoard.ts index ae5a369c3e7..efcc213fcbb 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/ProblemDescriptionBoard.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/problem/types/ProblemDescriptionBoard.ts @@ -9,18 +9,18 @@ export type ProblemDescriptionBoard = | SeedTrace.ProblemDescriptionBoard.Variable | SeedTrace.ProblemDescriptionBoard.TestCaseId; -export declare namespace ProblemDescriptionBoard { - interface Html { +export namespace ProblemDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface Variable { + export interface Variable { type: "variable"; value: SeedTrace.VariableValue; } - interface TestCaseId { + export interface TestCaseId { type: "testCaseId"; value: string; } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ActualResult.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ActualResult.ts index 6986afad702..b78eb0c13b9 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ActualResult.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ActualResult.ts @@ -9,17 +9,17 @@ export type ActualResult = | SeedTrace.ActualResult.Exception | SeedTrace.ActualResult.ExceptionV2; -export declare namespace ActualResult { - interface Value { +export namespace ActualResult { + export interface Value { type: "value"; value: SeedTrace.VariableValue; } - interface Exception extends SeedTrace.ExceptionInfo { + export interface Exception extends SeedTrace.ExceptionInfo { type: "exception"; } - interface ExceptionV2 { + export interface ExceptionV2 { type: "exceptionV2"; value: SeedTrace.ExceptionV2; } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/CodeExecutionUpdate.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/CodeExecutionUpdate.ts index 7e17d4aa354..9e41b5a9000 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/CodeExecutionUpdate.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/CodeExecutionUpdate.ts @@ -39,48 +39,48 @@ export type CodeExecutionUpdate = * Sent once a submission is graded and fully recorded. */ | SeedTrace.CodeExecutionUpdate.Finished; -export declare namespace CodeExecutionUpdate { - interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse { +export namespace CodeExecutionUpdate { + export interface BuildingExecutor extends SeedTrace.BuildingExecutorResponse { type: "buildingExecutor"; } - interface Running extends SeedTrace.RunningResponse { + export interface Running extends SeedTrace.RunningResponse { type: "running"; } - interface Errored extends SeedTrace.ErroredResponse { + export interface Errored extends SeedTrace.ErroredResponse { type: "errored"; } - interface Stopped extends SeedTrace.StoppedResponse { + export interface Stopped extends SeedTrace.StoppedResponse { type: "stopped"; } - interface Graded extends SeedTrace.GradedResponse { + export interface Graded extends SeedTrace.GradedResponse { type: "graded"; } - interface GradedV2 extends SeedTrace.GradedResponseV2 { + export interface GradedV2 extends SeedTrace.GradedResponseV2 { type: "gradedV2"; } - interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse { + export interface WorkspaceRan extends SeedTrace.WorkspaceRanResponse { type: "workspaceRan"; } - interface Recording extends SeedTrace.RecordingResponseNotification { + export interface Recording extends SeedTrace.RecordingResponseNotification { type: "recording"; } - interface Recorded extends SeedTrace.RecordedResponseNotification { + export interface Recorded extends SeedTrace.RecordedResponseNotification { type: "recorded"; } - interface InvalidRequest extends SeedTrace.InvalidRequestResponse { + export interface InvalidRequest extends SeedTrace.InvalidRequestResponse { type: "invalidRequest"; } - interface Finished extends SeedTrace.FinishedResponse { + export interface Finished extends SeedTrace.FinishedResponse { type: "finished"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ErrorInfo.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ErrorInfo.ts index ef3283fe81e..ddb886b4c9a 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ErrorInfo.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ErrorInfo.ts @@ -15,16 +15,16 @@ export type ErrorInfo = * */ | SeedTrace.ErrorInfo.InternalError; -export declare namespace ErrorInfo { - interface CompileError extends SeedTrace.CompileError { +export namespace ErrorInfo { + export interface CompileError extends SeedTrace.CompileError { type: "compileError"; } - interface RuntimeError extends SeedTrace.RuntimeError { + export interface RuntimeError extends SeedTrace.RuntimeError { type: "runtimeError"; } - interface InternalError extends SeedTrace.InternalError { + export interface InternalError extends SeedTrace.InternalError { type: "internalError"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ExceptionV2.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ExceptionV2.ts index 880817d708d..f43362137ad 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ExceptionV2.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ExceptionV2.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type ExceptionV2 = SeedTrace.ExceptionV2.Generic | SeedTrace.ExceptionV2.Timeout; -export declare namespace ExceptionV2 { - interface Generic extends SeedTrace.ExceptionInfo { +export namespace ExceptionV2 { + export interface Generic extends SeedTrace.ExceptionInfo { type: "generic"; } - interface Timeout { + export interface Timeout { type: "timeout"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ExecutionSessionStatus.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ExecutionSessionStatus.ts index a14d2035332..3709aaa7a69 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ExecutionSessionStatus.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/ExecutionSessionStatus.ts @@ -9,7 +9,6 @@ export type ExecutionSessionStatus = | "RUNNING_CONTAINER" | "LIVE_CONTAINER" | "FAILED_TO_LAUNCH"; - export const ExecutionSessionStatus = { CreatingContainer: "CREATING_CONTAINER", ProvisioningContainer: "PROVISIONING_CONTAINER", diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/InvalidRequestCause.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/InvalidRequestCause.ts index 3bb60f89b0f..3504cf7eaa3 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/InvalidRequestCause.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/InvalidRequestCause.ts @@ -13,16 +13,16 @@ export type InvalidRequestCause = * The submission request was routed to an incorrect language executor. */ | SeedTrace.InvalidRequestCause.UnexpectedLanguage; -export declare namespace InvalidRequestCause { - interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound { +export namespace InvalidRequestCause { + export interface SubmissionIdNotFound extends SeedTrace.SubmissionIdNotFound { type: "submissionIdNotFound"; } - interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported { + export interface CustomTestCasesUnsupported extends SeedTrace.CustomTestCasesUnsupported { type: "customTestCasesUnsupported"; } - interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError { + export interface UnexpectedLanguage extends SeedTrace.UnexpectedLanguageError { type: "unexpectedLanguage"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/RunningSubmissionState.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/RunningSubmissionState.ts index 5d15c5180a9..38031ccd887 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/RunningSubmissionState.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/RunningSubmissionState.ts @@ -8,7 +8,6 @@ export type RunningSubmissionState = | "WRITING_SUBMISSION_TO_FILE" | "COMPILING_SUBMISSION" | "RUNNING_SUBMISSION"; - export const RunningSubmissionState = { QueueingSubmission: "QUEUEING_SUBMISSION", KillingHistoricalSubmissions: "KILLING_HISTORICAL_SUBMISSIONS", diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionRequest.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionRequest.ts index e63f940c5b8..e4907b98e7c 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionRequest.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionRequest.ts @@ -11,24 +11,24 @@ export type SubmissionRequest = | SeedTrace.SubmissionRequest.WorkspaceSubmit | SeedTrace.SubmissionRequest.Stop; -export declare namespace SubmissionRequest { - interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest { +export namespace SubmissionRequest { + export interface InitializeProblemRequest extends SeedTrace.InitializeProblemRequest { type: "initializeProblemRequest"; } - interface InitializeWorkspaceRequest { + export interface InitializeWorkspaceRequest { type: "initializeWorkspaceRequest"; } - interface SubmitV2 extends SeedTrace.SubmitRequestV2 { + export interface SubmitV2 extends SeedTrace.SubmitRequestV2 { type: "submitV2"; } - interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest { + export interface WorkspaceSubmit extends SeedTrace.WorkspaceSubmitRequest { type: "workspaceSubmit"; } - interface Stop extends SeedTrace.StopRequest { + export interface Stop extends SeedTrace.StopRequest { type: "stop"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionResponse.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionResponse.ts index d2fb3f8172f..ca463a332a6 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionResponse.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionResponse.ts @@ -12,30 +12,30 @@ export type SubmissionResponse = | SeedTrace.SubmissionResponse.CodeExecutionUpdate | SeedTrace.SubmissionResponse.Terminated; -export declare namespace SubmissionResponse { - interface ServerInitialized { +export namespace SubmissionResponse { + export interface ServerInitialized { type: "serverInitialized"; } - interface ProblemInitialized { + export interface ProblemInitialized { type: "problemInitialized"; value: SeedTrace.ProblemId; } - interface WorkspaceInitialized { + export interface WorkspaceInitialized { type: "workspaceInitialized"; } - interface ServerErrored extends SeedTrace.ExceptionInfo { + export interface ServerErrored extends SeedTrace.ExceptionInfo { type: "serverErrored"; } - interface CodeExecutionUpdate { + export interface CodeExecutionUpdate { type: "codeExecutionUpdate"; value: SeedTrace.CodeExecutionUpdate; } - interface Terminated extends SeedTrace.TerminatedResponse { + export interface Terminated extends SeedTrace.TerminatedResponse { type: "terminated"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionStatusForTestCase.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionStatusForTestCase.ts index 8698643d86b..dd0d6039fee 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionStatusForTestCase.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionStatusForTestCase.ts @@ -9,17 +9,17 @@ export type SubmissionStatusForTestCase = | SeedTrace.SubmissionStatusForTestCase.GradedV2 | SeedTrace.SubmissionStatusForTestCase.Traced; -export declare namespace SubmissionStatusForTestCase { - interface Graded extends SeedTrace.TestCaseResultWithStdout { +export namespace SubmissionStatusForTestCase { + export interface Graded extends SeedTrace.TestCaseResultWithStdout { type: "graded"; } - interface GradedV2 { + export interface GradedV2 { type: "gradedV2"; value: SeedTrace.TestCaseGrade; } - interface Traced extends SeedTrace.TracedTestCase { + export interface Traced extends SeedTrace.TracedTestCase { type: "traced"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionStatusV2.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionStatusV2.ts index 652c732c408..95710f67978 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionStatusV2.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionStatusV2.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type SubmissionStatusV2 = SeedTrace.SubmissionStatusV2.Test | SeedTrace.SubmissionStatusV2.Workspace; -export declare namespace SubmissionStatusV2 { - interface Test extends SeedTrace.TestSubmissionStatusV2 { +export namespace SubmissionStatusV2 { + export interface Test extends SeedTrace.TestSubmissionStatusV2 { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2 { + export interface Workspace extends SeedTrace.WorkspaceSubmissionStatusV2 { type: "workspace"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionTypeEnum.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionTypeEnum.ts index bff5583dad7..8414392abfc 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionTypeEnum.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionTypeEnum.ts @@ -6,7 +6,6 @@ * Keep in sync with SubmissionType. */ export type SubmissionTypeEnum = "TEST"; - export const SubmissionTypeEnum = { Test: "TEST", } as const; diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionTypeState.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionTypeState.ts index fa4855ce698..c811ee050db 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionTypeState.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/SubmissionTypeState.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type SubmissionTypeState = SeedTrace.SubmissionTypeState.Test | SeedTrace.SubmissionTypeState.Workspace; -export declare namespace SubmissionTypeState { - interface Test extends SeedTrace.TestSubmissionState { +export namespace SubmissionTypeState { + export interface Test extends SeedTrace.TestSubmissionState { type: "test"; } - interface Workspace extends SeedTrace.WorkspaceSubmissionState { + export interface Workspace extends SeedTrace.WorkspaceSubmissionState { type: "workspace"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestCaseGrade.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestCaseGrade.ts index 2f02296e05a..901cf5fc6ec 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestCaseGrade.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestCaseGrade.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../index"; export type TestCaseGrade = SeedTrace.TestCaseGrade.Hidden | SeedTrace.TestCaseGrade.NonHidden; -export declare namespace TestCaseGrade { - interface Hidden extends SeedTrace.TestCaseHiddenGrade { +export namespace TestCaseGrade { + export interface Hidden extends SeedTrace.TestCaseHiddenGrade { type: "hidden"; } - interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade { + export interface NonHidden extends SeedTrace.TestCaseNonHiddenGrade { type: "nonHidden"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestSubmissionStatus.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestSubmissionStatus.ts index da3e7c63984..04dc0c011e9 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestSubmissionStatus.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestSubmissionStatus.ts @@ -10,22 +10,22 @@ export type TestSubmissionStatus = | SeedTrace.TestSubmissionStatus.Running | SeedTrace.TestSubmissionStatus.TestCaseIdToState; -export declare namespace TestSubmissionStatus { - interface Stopped { +export namespace TestSubmissionStatus { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface TestCaseIdToState { + export interface TestCaseIdToState { type: "testCaseIdToState"; value: Record; } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts index 69a146a5067..f04f0e0479c 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/TestSubmissionUpdateInfo.ts @@ -12,30 +12,30 @@ export type TestSubmissionUpdateInfo = | SeedTrace.TestSubmissionUpdateInfo.RecordedTestCase | SeedTrace.TestSubmissionUpdateInfo.Finished; -export declare namespace TestSubmissionUpdateInfo { - interface Running { +export namespace TestSubmissionUpdateInfo { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Stopped { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate { + export interface GradedTestCase extends SeedTrace.GradedTestCaseUpdate { type: "gradedTestCase"; } - interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate { + export interface RecordedTestCase extends SeedTrace.RecordedTestCaseUpdate { type: "recordedTestCase"; } - interface Finished { + export interface Finished { type: "finished"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts index 5151126e193..cad2d60cdae 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/WorkspaceSubmissionStatus.ts @@ -11,26 +11,26 @@ export type WorkspaceSubmissionStatus = | SeedTrace.WorkspaceSubmissionStatus.Ran | SeedTrace.WorkspaceSubmissionStatus.Traced; -export declare namespace WorkspaceSubmissionStatus { - interface Stopped { +export namespace WorkspaceSubmissionStatus { + export interface Stopped { type: "stopped"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Running { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails { + export interface Ran extends SeedTrace.WorkspaceRunDetails { type: "ran"; } - interface Traced extends SeedTrace.WorkspaceRunDetails { + export interface Traced extends SeedTrace.WorkspaceRunDetails { type: "traced"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts index 78c1249225c..a8b008b38fb 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/submission/types/WorkspaceSubmissionUpdateInfo.ts @@ -13,34 +13,34 @@ export type WorkspaceSubmissionUpdateInfo = | SeedTrace.WorkspaceSubmissionUpdateInfo.Errored | SeedTrace.WorkspaceSubmissionUpdateInfo.Finished; -export declare namespace WorkspaceSubmissionUpdateInfo { - interface Running { +export namespace WorkspaceSubmissionUpdateInfo { + export interface Running { type: "running"; value: SeedTrace.RunningSubmissionState; } - interface Ran extends SeedTrace.WorkspaceRunDetails { + export interface Ran extends SeedTrace.WorkspaceRunDetails { type: "ran"; } - interface Stopped { + export interface Stopped { type: "stopped"; } - interface Traced { + export interface Traced { type: "traced"; } - interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate { + export interface TracedV2 extends SeedTrace.WorkspaceTracedUpdate { type: "tracedV2"; } - interface Errored { + export interface Errored { type: "errored"; value: SeedTrace.ErrorInfo; } - interface Finished { + export interface Finished { type: "finished"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/client/Client.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/client/Client.ts index ea7ff879e01..627705ac28b 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/client/Client.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/client/Client.ts @@ -31,8 +31,19 @@ export declare namespace V2 { } export class V2 { + protected _problem: Problem | undefined; + protected _v3: V3 | undefined; + constructor(protected readonly _options: V2.Options = {}) {} + public get problem(): Problem { + return (this._problem ??= new Problem(this._options)); + } + + public get v3(): V3 { + return (this._v3 ??= new V3(this._options)); + } + /** * @param {V2.RequestOptions} requestOptions - Request-specific configuration. * @@ -89,18 +100,6 @@ export class V2 { } } - protected _problem: Problem | undefined; - - public get problem(): Problem { - return (this._problem ??= new Problem(this._options)); - } - - protected _v3: V3 | undefined; - - public get v3(): V3 { - return (this._v3 ??= new V3(this._options)); - } - protected async _getAuthorizationHeader(): Promise { const bearer = await core.Supplier.get(this._options.token); if (bearer != null) { diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts index 85c6b996461..d2be6b87b97 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/AssertCorrectnessCheck.ts @@ -8,12 +8,12 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.AssertCorrectnessCheck.DeepEquality | SeedTrace.v2.AssertCorrectnessCheck.Custom; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.DeepEqualityCorrectnessCheck { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinitionThatTakesActualResult { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/CustomFiles.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/CustomFiles.ts index b430b089eaf..06ccba9d49d 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/CustomFiles.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/CustomFiles.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../index"; export type CustomFiles = SeedTrace.v2.CustomFiles.Basic | SeedTrace.v2.CustomFiles.Custom; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.BasicCustomFiles { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.BasicCustomFiles { type: "basic"; } - interface Custom { + export interface Custom { type: "custom"; value: Record; } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/FunctionSignature.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/FunctionSignature.ts index 251760cd97e..f4adeea0b90 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/FunctionSignature.ts @@ -11,16 +11,16 @@ export type FunctionSignature = * Useful when specifying custom grading for a testcase where actualResult is defined. */ | SeedTrace.v2.FunctionSignature.VoidThatTakesActualResult; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.VoidFunctionSignature { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.VoidFunctionSignature { type: "void"; } - interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature { + export interface NonVoid extends SeedTrace.v2.NonVoidFunctionSignature { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult { + export interface VoidThatTakesActualResult extends SeedTrace.v2.VoidFunctionSignatureThatTakesActualResult { type: "voidThatTakesActualResult"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts index c70bdafe6bb..cc8ea6e85c2 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseFunction.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../index"; export type TestCaseFunction = SeedTrace.v2.TestCaseFunction.WithActualResult | SeedTrace.v2.TestCaseFunction.Custom; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.TestCaseWithActualResultImplementation { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.VoidFunctionDefinition { + export interface Custom extends SeedTrace.v2.VoidFunctionDefinition { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index af60df46b61..3a83452376c 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.TestCaseImplementationDescriptionBoard.Html | SeedTrace.v2.TestCaseImplementationDescriptionBoard.ParamId; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface ParamId { + export interface ParamId { type: "paramId"; value: SeedTrace.v2.ParameterId; } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts index 045115835ab..66182e14e9f 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/problem/types/TestCaseImplementationReference.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationReference = | SeedTrace.v2.TestCaseImplementationReference.TemplateId | SeedTrace.v2.TestCaseImplementationReference.Implementation; -export declare namespace TestCaseImplementationReference { - interface TemplateId { +export namespace TestCaseImplementationReference { + export interface TemplateId { type: "templateId"; value: SeedTrace.v2.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.TestCaseImplementation { + export interface Implementation extends SeedTrace.v2.TestCaseImplementation { type: "implementation"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/client/Client.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/client/Client.ts index faa07d6c9d0..4aa14f494e7 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/client/Client.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/client/Client.ts @@ -29,10 +29,10 @@ export declare namespace V3 { } export class V3 { - constructor(protected readonly _options: V3.Options = {}) {} - protected _problem: Problem | undefined; + constructor(protected readonly _options: V3.Options = {}) {} + public get problem(): Problem { return (this._problem ??= new Problem(this._options)); } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts index 79d32643560..2c0e9b49c7c 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/AssertCorrectnessCheck.ts @@ -8,12 +8,12 @@ export type AssertCorrectnessCheck = | SeedTrace.v2.v3.AssertCorrectnessCheck.DeepEquality | SeedTrace.v2.v3.AssertCorrectnessCheck.Custom; -export declare namespace AssertCorrectnessCheck { - interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck { +export namespace AssertCorrectnessCheck { + export interface DeepEquality extends SeedTrace.v2.v3.DeepEqualityCorrectnessCheck { type: "deepEquality"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinitionThatTakesActualResult { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts index 4ac8078742b..c287f6286f3 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/CustomFiles.ts @@ -6,12 +6,12 @@ import * as SeedTrace from "../../../../../../../index"; export type CustomFiles = SeedTrace.v2.v3.CustomFiles.Basic | SeedTrace.v2.v3.CustomFiles.Custom; -export declare namespace CustomFiles { - interface Basic extends SeedTrace.v2.v3.BasicCustomFiles { +export namespace CustomFiles { + export interface Basic extends SeedTrace.v2.v3.BasicCustomFiles { type: "basic"; } - interface Custom { + export interface Custom { type: "custom"; value: Record; } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts index 548b1d9092b..82243201aba 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/FunctionSignature.ts @@ -11,16 +11,16 @@ export type FunctionSignature = * Useful when specifying custom grading for a testcase where actualResult is defined. */ | SeedTrace.v2.v3.FunctionSignature.VoidThatTakesActualResult; -export declare namespace FunctionSignature { - interface Void extends SeedTrace.v2.v3.VoidFunctionSignature { +export namespace FunctionSignature { + export interface Void extends SeedTrace.v2.v3.VoidFunctionSignature { type: "void"; } - interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature { + export interface NonVoid extends SeedTrace.v2.v3.NonVoidFunctionSignature { type: "nonVoid"; } - interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult { + export interface VoidThatTakesActualResult extends SeedTrace.v2.v3.VoidFunctionSignatureThatTakesActualResult { type: "voidThatTakesActualResult"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts index 2381196a692..031ff15274d 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseFunction.ts @@ -8,12 +8,12 @@ export type TestCaseFunction = | SeedTrace.v2.v3.TestCaseFunction.WithActualResult | SeedTrace.v2.v3.TestCaseFunction.Custom; -export declare namespace TestCaseFunction { - interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation { +export namespace TestCaseFunction { + export interface WithActualResult extends SeedTrace.v2.v3.TestCaseWithActualResultImplementation { type: "withActualResult"; } - interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition { + export interface Custom extends SeedTrace.v2.v3.VoidFunctionDefinition { type: "custom"; } } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts index 8d670c214fc..157e99b52ac 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationDescriptionBoard.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationDescriptionBoard = | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.Html | SeedTrace.v2.v3.TestCaseImplementationDescriptionBoard.ParamId; -export declare namespace TestCaseImplementationDescriptionBoard { - interface Html { +export namespace TestCaseImplementationDescriptionBoard { + export interface Html { type: "html"; value: string; } - interface ParamId { + export interface ParamId { type: "paramId"; value: SeedTrace.v2.v3.ParameterId; } diff --git a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts index 0fad5ef9988..67af0e57047 100644 --- a/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts +++ b/seed/ts-sdk/trace/no-zurg-trace/src/api/resources/v2/resources/v3/resources/problem/types/TestCaseImplementationReference.ts @@ -8,13 +8,13 @@ export type TestCaseImplementationReference = | SeedTrace.v2.v3.TestCaseImplementationReference.TemplateId | SeedTrace.v2.v3.TestCaseImplementationReference.Implementation; -export declare namespace TestCaseImplementationReference { - interface TemplateId { +export namespace TestCaseImplementationReference { + export interface TemplateId { type: "templateId"; value: SeedTrace.v2.v3.TestCaseTemplateId; } - interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation { + export interface Implementation extends SeedTrace.v2.v3.TestCaseImplementation { type: "implementation"; } } diff --git a/seed/ts-sdk/ts-express-casing/src/Client.ts b/seed/ts-sdk/ts-express-casing/src/Client.ts index 16058002bad..f31d80e954d 100644 --- a/seed/ts-sdk/ts-express-casing/src/Client.ts +++ b/seed/ts-sdk/ts-express-casing/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedApiClient { } export class SeedApiClient { - constructor(protected readonly _options: SeedApiClient.Options) {} - protected _imdb: Imdb | undefined; + constructor(protected readonly _options: SeedApiClient.Options) {} + public get imdb(): Imdb { return (this._imdb ??= new Imdb(this._options)); } diff --git a/seed/ts-sdk/undiscriminated-unions/no-custom-config/src/Client.ts b/seed/ts-sdk/undiscriminated-unions/no-custom-config/src/Client.ts index 2889e6278b9..2ea9f06ad57 100644 --- a/seed/ts-sdk/undiscriminated-unions/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/undiscriminated-unions/no-custom-config/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedUndiscriminatedUnionsClient { } export class SeedUndiscriminatedUnionsClient { - constructor(protected readonly _options: SeedUndiscriminatedUnionsClient.Options) {} - protected _union: Union | undefined; + constructor(protected readonly _options: SeedUndiscriminatedUnionsClient.Options) {} + public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/undiscriminated-unions/no-custom-config/src/api/resources/union/types/KeyType.ts b/seed/ts-sdk/undiscriminated-unions/no-custom-config/src/api/resources/union/types/KeyType.ts index 90f84c1ff15..e40980b26f7 100644 --- a/seed/ts-sdk/undiscriminated-unions/no-custom-config/src/api/resources/union/types/KeyType.ts +++ b/seed/ts-sdk/undiscriminated-unions/no-custom-config/src/api/resources/union/types/KeyType.ts @@ -3,7 +3,6 @@ */ export type KeyType = "name" | "value"; - export const KeyType = { Name: "name", Value: "value", diff --git a/seed/ts-sdk/undiscriminated-unions/skip-response-validation/src/Client.ts b/seed/ts-sdk/undiscriminated-unions/skip-response-validation/src/Client.ts index 2889e6278b9..2ea9f06ad57 100644 --- a/seed/ts-sdk/undiscriminated-unions/skip-response-validation/src/Client.ts +++ b/seed/ts-sdk/undiscriminated-unions/skip-response-validation/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedUndiscriminatedUnionsClient { } export class SeedUndiscriminatedUnionsClient { - constructor(protected readonly _options: SeedUndiscriminatedUnionsClient.Options) {} - protected _union: Union | undefined; + constructor(protected readonly _options: SeedUndiscriminatedUnionsClient.Options) {} + public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/undiscriminated-unions/skip-response-validation/src/api/resources/union/types/KeyType.ts b/seed/ts-sdk/undiscriminated-unions/skip-response-validation/src/api/resources/union/types/KeyType.ts index 90f84c1ff15..e40980b26f7 100644 --- a/seed/ts-sdk/undiscriminated-unions/skip-response-validation/src/api/resources/union/types/KeyType.ts +++ b/seed/ts-sdk/undiscriminated-unions/skip-response-validation/src/api/resources/union/types/KeyType.ts @@ -3,7 +3,6 @@ */ export type KeyType = "name" | "value"; - export const KeyType = { Name: "name", Value: "value", diff --git a/seed/ts-sdk/unions/src/Client.ts b/seed/ts-sdk/unions/src/Client.ts index fcec22ebc30..dd5a1d445f6 100644 --- a/seed/ts-sdk/unions/src/Client.ts +++ b/seed/ts-sdk/unions/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedUnionsClient { } export class SeedUnionsClient { - constructor(protected readonly _options: SeedUnionsClient.Options) {} - protected _union: Union | undefined; + constructor(protected readonly _options: SeedUnionsClient.Options) {} + public get union(): Union { return (this._union ??= new Union(this._options)); } diff --git a/seed/ts-sdk/unions/src/api/resources/types/types/Union.ts b/seed/ts-sdk/unions/src/api/resources/types/types/Union.ts index 1215df193a6..fec56bcc719 100644 --- a/seed/ts-sdk/unions/src/api/resources/types/types/Union.ts +++ b/seed/ts-sdk/unions/src/api/resources/types/types/Union.ts @@ -9,13 +9,13 @@ import * as SeedUnions from "../../../index"; */ export type Union = SeedUnions.Union.Foo | SeedUnions.Union.Bar; -export declare namespace Union { - interface Foo { +export namespace Union { + export interface Foo { type: "foo"; foo: SeedUnions.Foo; } - interface Bar { + export interface Bar { type: "bar"; bar: SeedUnions.Bar; } diff --git a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithBaseProperties.ts b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithBaseProperties.ts index c70f3054c60..3933d4aa9af 100644 --- a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithBaseProperties.ts +++ b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithBaseProperties.ts @@ -9,18 +9,18 @@ export type UnionWithBaseProperties = | SeedUnions.UnionWithBaseProperties.String | SeedUnions.UnionWithBaseProperties.Foo; -export declare namespace UnionWithBaseProperties { - interface Integer extends _Base { +export namespace UnionWithBaseProperties { + export interface Integer extends _Base { type: "integer"; value: number; } - interface String extends _Base { + export interface String extends _Base { type: "string"; value: string; } - interface Foo extends SeedUnions.Foo, _Base { + export interface Foo extends SeedUnions.Foo, _Base { type: "foo"; } diff --git a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithDiscriminant.ts b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithDiscriminant.ts index a5f1174798a..0d5b2c23e7c 100644 --- a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithDiscriminant.ts +++ b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithDiscriminant.ts @@ -9,13 +9,13 @@ export type UnionWithDiscriminant = * This is a Foo field. */ SeedUnions.UnionWithDiscriminant.Foo | SeedUnions.UnionWithDiscriminant.Bar; -export declare namespace UnionWithDiscriminant { - interface Foo { +export namespace UnionWithDiscriminant { + export interface Foo { type: "foo"; foo: SeedUnions.Foo; } - interface Bar { + export interface Bar { type: "bar"; bar: SeedUnions.Bar; } diff --git a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithLiteral.ts b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithLiteral.ts index 673303d649d..525d54b9031 100644 --- a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithLiteral.ts +++ b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithLiteral.ts @@ -6,8 +6,8 @@ import * as SeedUnions from "../../../index"; export type UnionWithLiteral = SeedUnions.UnionWithLiteral.Fern; -export declare namespace UnionWithLiteral { - interface Fern extends _Base { +export namespace UnionWithLiteral { + export interface Fern extends _Base { type: "fern"; value: "fern"; } diff --git a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithOptionalTime.ts b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithOptionalTime.ts index d5e2ea06176..2bfb3525ca8 100644 --- a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithOptionalTime.ts +++ b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithOptionalTime.ts @@ -6,13 +6,13 @@ import * as SeedUnions from "../../../index"; export type UnionWithOptionalTime = SeedUnions.UnionWithOptionalTime.Date_ | SeedUnions.UnionWithOptionalTime.Dateimte; -export declare namespace UnionWithOptionalTime { - interface Date_ { +export namespace UnionWithOptionalTime { + export interface Date_ { type: "date"; value?: string; } - interface Dateimte { + export interface Dateimte { type: "dateimte"; value?: Date; } diff --git a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithPrimitive.ts b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithPrimitive.ts index a5d0519e952..014c915649f 100644 --- a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithPrimitive.ts +++ b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithPrimitive.ts @@ -6,13 +6,13 @@ import * as SeedUnions from "../../../index"; export type UnionWithPrimitive = SeedUnions.UnionWithPrimitive.Integer | SeedUnions.UnionWithPrimitive.String; -export declare namespace UnionWithPrimitive { - interface Integer { +export namespace UnionWithPrimitive { + export interface Integer { type: "integer"; value: number; } - interface String { + export interface String { type: "string"; value: string; } diff --git a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithSingleElement.ts b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithSingleElement.ts index d5e0f9631ac..4be05880cb1 100644 --- a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithSingleElement.ts +++ b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithSingleElement.ts @@ -6,8 +6,8 @@ import * as SeedUnions from "../../../index"; export type UnionWithSingleElement = SeedUnions.UnionWithSingleElement.Foo; -export declare namespace UnionWithSingleElement { - interface Foo extends SeedUnions.Foo { +export namespace UnionWithSingleElement { + export interface Foo extends SeedUnions.Foo { type: "foo"; } } diff --git a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithTime.ts b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithTime.ts index 210ef6fef03..dd937debe01 100644 --- a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithTime.ts +++ b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithTime.ts @@ -9,18 +9,18 @@ export type UnionWithTime = | SeedUnions.UnionWithTime.Date_ | SeedUnions.UnionWithTime.Datetime; -export declare namespace UnionWithTime { - interface Value { +export namespace UnionWithTime { + export interface Value { type: "value"; value: number; } - interface Date_ { + export interface Date_ { type: "date"; value: string; } - interface Datetime { + export interface Datetime { type: "datetime"; value: Date; } diff --git a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithUnknown.ts b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithUnknown.ts index e05d672181a..59972746956 100644 --- a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithUnknown.ts +++ b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithUnknown.ts @@ -6,12 +6,12 @@ import * as SeedUnions from "../../../index"; export type UnionWithUnknown = SeedUnions.UnionWithUnknown.Foo | SeedUnions.UnionWithUnknown.Unknown; -export declare namespace UnionWithUnknown { - interface Foo extends SeedUnions.Foo { +export namespace UnionWithUnknown { + export interface Foo extends SeedUnions.Foo { type: "foo"; } - interface Unknown { + export interface Unknown { type: "unknown"; } } diff --git a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithoutKey.ts b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithoutKey.ts index 037fb65ab12..b4918e2526f 100644 --- a/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithoutKey.ts +++ b/seed/ts-sdk/unions/src/api/resources/types/types/UnionWithoutKey.ts @@ -10,12 +10,12 @@ export type UnionWithoutKey = * This is a bar field. */ | SeedUnions.UnionWithoutKey.Bar; -export declare namespace UnionWithoutKey { - interface Foo extends SeedUnions.Foo { +export namespace UnionWithoutKey { + export interface Foo extends SeedUnions.Foo { type: "foo"; } - interface Bar extends SeedUnions.Bar { + export interface Bar extends SeedUnions.Bar { type: "bar"; } } diff --git a/seed/ts-sdk/unions/src/api/resources/union/types/Shape.ts b/seed/ts-sdk/unions/src/api/resources/union/types/Shape.ts index 95d573a7a36..d46544c5c5d 100644 --- a/seed/ts-sdk/unions/src/api/resources/union/types/Shape.ts +++ b/seed/ts-sdk/unions/src/api/resources/union/types/Shape.ts @@ -6,12 +6,12 @@ import * as SeedUnions from "../../../index"; export type Shape = SeedUnions.Shape.Circle | SeedUnions.Shape.Square; -export declare namespace Shape { - interface Circle extends SeedUnions.Circle, _Base { +export namespace Shape { + export interface Circle extends SeedUnions.Circle, _Base { type: "circle"; } - interface Square extends SeedUnions.Square, _Base { + export interface Square extends SeedUnions.Square, _Base { type: "square"; } diff --git a/seed/ts-sdk/unknown/no-custom-config/src/Client.ts b/seed/ts-sdk/unknown/no-custom-config/src/Client.ts index 5643ebbfd88..a2b8cb10302 100644 --- a/seed/ts-sdk/unknown/no-custom-config/src/Client.ts +++ b/seed/ts-sdk/unknown/no-custom-config/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedUnknownAsAnyClient { } export class SeedUnknownAsAnyClient { - constructor(protected readonly _options: SeedUnknownAsAnyClient.Options) {} - protected _unknown: Unknown | undefined; + constructor(protected readonly _options: SeedUnknownAsAnyClient.Options) {} + public get unknown(): Unknown { return (this._unknown ??= new Unknown(this._options)); } diff --git a/seed/ts-sdk/unknown/unknown-as-any/src/Client.ts b/seed/ts-sdk/unknown/unknown-as-any/src/Client.ts index 5643ebbfd88..a2b8cb10302 100644 --- a/seed/ts-sdk/unknown/unknown-as-any/src/Client.ts +++ b/seed/ts-sdk/unknown/unknown-as-any/src/Client.ts @@ -23,10 +23,10 @@ export declare namespace SeedUnknownAsAnyClient { } export class SeedUnknownAsAnyClient { - constructor(protected readonly _options: SeedUnknownAsAnyClient.Options) {} - protected _unknown: Unknown | undefined; + constructor(protected readonly _options: SeedUnknownAsAnyClient.Options) {} + public get unknown(): Unknown { return (this._unknown ??= new Unknown(this._options)); } diff --git a/seed/ts-sdk/validation/src/api/types/Shape.ts b/seed/ts-sdk/validation/src/api/types/Shape.ts index 0d256b8b1c4..d80208737b9 100644 --- a/seed/ts-sdk/validation/src/api/types/Shape.ts +++ b/seed/ts-sdk/validation/src/api/types/Shape.ts @@ -3,7 +3,6 @@ */ export type Shape = "SQUARE" | "CIRCLE" | "TRIANGLE"; - export const Shape = { Square: "SQUARE", Circle: "CIRCLE", diff --git a/seed/ts-sdk/variables/src/Client.ts b/seed/ts-sdk/variables/src/Client.ts index 807156edd09..347bde94942 100644 --- a/seed/ts-sdk/variables/src/Client.ts +++ b/seed/ts-sdk/variables/src/Client.ts @@ -24,10 +24,10 @@ export declare namespace SeedVariablesClient { } export class SeedVariablesClient { - constructor(protected readonly _options: SeedVariablesClient.Options) {} - protected _service: Service | undefined; + constructor(protected readonly _options: SeedVariablesClient.Options) {} + public get service(): Service { return (this._service ??= new Service(this._options)); } diff --git a/seed/ts-sdk/version-no-default/src/Client.ts b/seed/ts-sdk/version-no-default/src/Client.ts index 9ca004ffd1a..d920fc35b56 100644 --- a/seed/ts-sdk/version-no-default/src/Client.ts +++ b/seed/ts-sdk/version-no-default/src/Client.ts @@ -27,10 +27,10 @@ export declare namespace SeedVersionClient { } export class SeedVersionClient { - constructor(protected readonly _options: SeedVersionClient.Options) {} - protected _user: User | undefined; + constructor(protected readonly _options: SeedVersionClient.Options) {} + public get user(): User { return (this._user ??= new User(this._options)); } diff --git a/seed/ts-sdk/version/src/Client.ts b/seed/ts-sdk/version/src/Client.ts index de3a2acb811..fcdcc08adc6 100644 --- a/seed/ts-sdk/version/src/Client.ts +++ b/seed/ts-sdk/version/src/Client.ts @@ -27,10 +27,10 @@ export declare namespace SeedVersionClient { } export class SeedVersionClient { - constructor(protected readonly _options: SeedVersionClient.Options) {} - protected _user: User | undefined; + constructor(protected readonly _options: SeedVersionClient.Options) {} + public get user(): User { return (this._user ??= new User(this._options)); } diff --git a/test-definitions-openapi/fern/apis/inline-schema-reference/openapi.yml b/test-definitions-openapi/fern/apis/inline-schema-reference/openapi.yml index 6defb379eb1..fc2b8681d14 100644 --- a/test-definitions-openapi/fern/apis/inline-schema-reference/openapi.yml +++ b/test-definitions-openapi/fern/apis/inline-schema-reference/openapi.yml @@ -79,6 +79,15 @@ components: type: integer name: type: string + inline_union_map: + type: object + additionalProperties: + anyOf: + - type: string + nullable: true + - type: number + - type: boolean + - type: array Schema2: type: object properties: @@ -114,3 +123,13 @@ components: properties: b: type: string + + RootUnionMap: + type: object + additionalProperties: + anyOf: + - type: string + nullable: true + - type: number + - type: boolean + - type: array diff --git a/test-definitions/fern/apis/inline-types/definition/__package__.yml b/test-definitions/fern/apis/inline-types/definition/__package__.yml index a2a0cbfac7c..af14bf356cd 100644 --- a/test-definitions/fern/apis/inline-types/definition/__package__.yml +++ b/test-definitions/fern/apis/inline-types/definition/__package__.yml @@ -8,54 +8,358 @@ service: request: body: properties: - bar: InlineType1 + bar: RequestTypeInlineType1 foo: string content-type: application/json name: PostRootRequest response: RootType1 + getDiscriminatedUnion: + path: /discriminated-union + method: POST + request: + body: + properties: + bar: DiscriminatedUnion1 + foo: string + content-type: application/json + name: GetDiscriminatedUnionRequest + getUndiscriminatedUnion: + path: /undiscriminated-union + method: POST + request: + body: + properties: + bar: UndiscriminatedUnion1 + foo: string + content-type: application/json + name: GetUndiscriminatedUnionRequest types: - RootType1: + # this is also the type that would be produced by + AliasMapInline: map + AliasSetInline: set + AliasListInline: list + + AliasInlineValue: + inline: true properties: foo: string - bar: InlineType1 + bar: string - InlineType1: + RequestTypeInlineType1: inline: true + docs: lorem ipsum properties: - foo: string + foo: + type: string + docs: lorem ipsum + + RootType1: + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum bar: - type: NestedInlineType1 + type: RootType1InlineType1 + docs: lorem ipsum + fooMap: + type: map + docs: lorem ipsum + fooList: + type: list + docs: lorem ipsum + fooSet: + type: set + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum - InlineType2: + RootType1FooMapValue: inline: true + docs: lorem ipsum properties: - baz: string + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum - NestedInlineType1: + RootType1FooListItem: inline: true + docs: lorem ipsum properties: - foo: string - bar: string - myEnum: InlineEnum + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum - InlinedDiscriminatedUnion1: + RootType1FooSetItem: inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: RootType1InlineType1NestedInlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + RootType1InlineType1NestedInlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: string + docs: lorem ipsum + myEnum: + type: InlineEnum1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1: + inline: true + docs: lorem ipsum union: - type1: InlineType1 - type2: InlineType2 + type1: + type: DiscriminatedUnion1InlineType1 + docs: lorem ipsum + type2: + type: DiscriminatedUnion1InlineType2 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: DiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + DiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum - InlinedUndiscriminatedUnion1: + UndiscriminatedUnion1: inline: true + docs: lorem ipsum discriminated: false union: - - type: InlineType1 - - type: InlineType2 + - type: UndiscriminatedUnion1InlineType1 + docs: lorem ipsum + - type: UndiscriminatedUnion1InlineType2 + docs: lorem ipsum + - type: UndiscriminatedUnion1DiscriminatedUnion1 + docs: lorem ipsum + - type: UndiscriminatedUnion1DiscriminatedUnion1 + docs: lorem ipsum + - type: UndiscriminatedUnion1InlineEnum1 + docs: lorem ipsum + - type: UserId + docs: lorem ipsum + - type: list + docs: lorem ipsum + - type: set + docs: lorem ipsum + - type: map + docs: lorem ipsum + - type: ReferenceType + docs: lorem ipsum - InlineEnum: + UndiscriminatedUnion1InlineType1: inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: UndiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + InlineEnum1: + inline: true + docs: lorem ipsum + enum: + - SUNNY + - CLOUDY + - RAINING + - SNOWING + + UndiscriminatedUnion1DiscriminatedUnion1: + inline: true + docs: lorem ipsum + union: + type1: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType1 + docs: lorem ipsum + type2: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType2 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + bar: + type: UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1 + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType1InlineType1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1DiscriminatedUnion1InlineType2: + inline: true + docs: lorem ipsum + properties: + baz: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineEnum1: + inline: true + docs: lorem ipsum enum: - SUNNY - CLOUDY - RAINING - SNOWING + + UserId: + type: string + docs: lorem ipsum + + UndiscriminatedUnion1InlineListItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineSetItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + UndiscriminatedUnion1InlineMapItem1: + inline: true + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum + ref: + type: ReferenceType + docs: lorem ipsum + + ReferenceType: + docs: lorem ipsum + properties: + foo: + type: string + docs: lorem ipsum