RepreZen API Studio supports the NSwag code generators for .NET, Web API and TypeScript.
To use the NSwag GenTemplates, you'll need to configure your environment as follows:
- RepreZen API Studio has been tested with versions 8.x and 9.x of of NSwag on Windows only. Please make sure you have one of the supported versions installed. You can find these on the releases page of the NSwag project.
- Make sure NSwag is on your path, or configure the NSwag directory in Window > Preferences > RepreZen > Code Generation:
With your OpenAPI 2.0 (Swagger) document open in the editor, use the New GenTarget command on the toolbar, dashboard or menu to add one of the NSwag generators to your project. Current GenTemplates include:
C# Client by NSwag
C# Server for ASP.NET Web API 2.0 by NSwag
TypeScript Client by NSwag
Run your new NSwag GenTarget using the Code Generation control in the toolbar.
See the code generation video to learn more about how code generation works in RepreZen API Studio.