A .NET object model for OpenAPI documents, with JSON and YAML readers and writers
open sourceMITfree
OpenAPI.NET is Microsoft's .NET SDK for OpenAPI descriptions: one shared object model for OpenAPI documents, readers that load JSON and YAML documents in both version 2 (Swagger) and version 3 formats, and writers that produce either. Version 3 of the library adds OpenAPI 3.2. Separate processor projects build documents from C# comments and from OData CSDL.
Problems it solves
- read an OpenAPI YAML file into C# objects so I can inspect its endpoints
- build an OpenAPI document in code from my .NET service and write it out as JSON
- convert a Swagger 2.0 description to OpenAPI 3 in .NET
- validate and walk an OpenAPI description in a C# tool
Features
- a .NET object model for OpenAPI documents
- readers for JSON and YAML in OpenAPI 2 and 3 formats
- writers for OpenAPI 2 and 3, including 3.2
- processors for C# comments and OData CSDL in separate projects
