Skip to content
John Schottler edited this page May 5, 2017 · 6 revisions

This document specifies how to get started with Nancy.Swagger. The quickest way to get started is to look at one of the sample projects; they will show you the alternative methods for describing your routes. This document also quickly explains some of the different methods you can approach.

Witnessing Nancy.Swagger in Action

If you would like to see Nancy.Swagger in action, download this repo and the swagger-ui project. Place swagger-ui's dist folder in the examples' folder such that the following folder structure exists: Nancy.Swagger/samples/Nancy.Swagger.*.Example/swagger-ui/dist. After that, debug one of the sample projects in Visual Studio. When the server starts, it should direct you to the swagger-ui page in your browser that displays all of the route information; you may need to redirect the swagger-ui's target at the top of the page to point to your local machine, (e.g., http://localhost:50967/swagger.json).

If you would like to view the swagger JSON document, hit the following route /api-docs!

Creating Your Own Nancy.Swagger Project.

To proceed with this section, make sure you already have a NancyFx project already set up and running. If you want to create a new one, feel free to use one of our sample projects as a base. The following pages are designed to support your intended NancyFx version.

Clone this wiki locally