OpenApiSpecToModelConverter 1.0.0
dotnet tool install --global OpenApiSpecToModelConverter --version 1.0.0
dotnet new tool-manifest
dotnet tool install --local OpenApiSpecToModelConverter --version 1.0.0
#tool dotnet:?package=OpenApiSpecToModelConverter&version=1.0.0
nuke :add-package OpenApiSpecToModelConverter --version 1.0.0
OpenApiSpecToModelConverter
OpenApiSpecToModelConverter
is a .NET tool designed to convert OpenAPI specifications into strongly-typed type script models, making it easier to integrate APIs into your .NET or client side applications.
Installation
To install the OpenApiSpecToModelConverter
tool globally, use the following command:
dotnet tool install -g OpenApiSpecToModelConverter
Usage
Once the tool is installed, you can use it to generate models from an OpenAPI specification file (YAML format).
Basic Command
generate-model --InputFile <path-to-openapi-spec> --OutputFileName <output-filename>
Parameters
--InputFile
or-i
: Specifies the path to the OpenAPI specification file. This can be a local file path or a URL to the specification.--OutputFileName
or-o
: Specifies the output file name where the generated models will be saved.
Example
Here’s an example command that converts an OpenAPI spec located at ./openapi.yaml
into Type script models in the output
file:
generate-model --InputFile ./openapi.yaml --OutputFileName output
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
This package has no dependencies.
Version | Downloads | Last Updated |
---|---|---|
1.0.0 | 151 | 10/26/2024 |