SwaggerSource.

ToTypeScriptClient(FilePath, Action<TypeScriptGeneratorSettings>) Method

Summary

Generates a TypeScript API client at the given path with the specified settings
Assembly
Cake.NSwag.dll
Namespace
Cake.NSwag.Sources
Containing Type
SwaggerSource

Syntax

public SwaggerSource ToTypeScriptClient(FilePath outputFile, Action<TypeScriptGeneratorSettings> configure = null)

Examples

NSwag.FromSwaggerSpecification("./swagger.json").ToTypeScriptClient("./client.ts");

Parameters

Name Type Description
outputFile FilePath File path for the generated client code
configure Action<TypeScriptGeneratorSettings> Optional settings to further control the code generation process

Return Value

Type Description
SwaggerSource The metadata source