Sooo, I'm trying to get swagger to play nice with nancy. Unfortunately, I
get the above error no matter what I do. I am using Nancy v1.4 and Swagger
v2.1 (the last to support Nancy v1.x).
My working Nancy module:
public class General : NancyModule{
public General()
{
Get["/","Home"] = parameters =>
{
try
{
return "home";// View["view/index.html"];
}
catch (Exception ex)
{
return ExceptionHelper.ExceptionResponse(Negotiate, ex);
}
};
Get["/test/", "Test"] = parameters => {
return "testie";
};
}}
My metadata class:
public class GeneralMetadataModule : MetadataModule<PathItem>{
public GeneralMetadataModule(ISwaggerModelCatalog modelCatalog)
{
Describe["Test"] = description => description.AsSwagger(
with => with.Operation(
op => op.OperationId("Test")
.Tag("Users")
.Summary("The list of users")
.Description("This returns a list of users from our
awesome app")));
}}
Looking at the sample apps (bsed on nancy 2.x because that's all that's
available), I can't see that I've missed anything. Where is Paths set?
--
You received this message because you are subscribed to the Google Groups
"Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.