Swagger 虚张声势/虚张声势不在根元素处生成标记
我们在.NETAPI(不是核心)上使用Swashback进行了Swagger设置 我正在寻找LucyBot来制作一个外观更好的文档页面。看看他们的示例,他们的OpenAPI文件在根目录下有一个“tags”元素,用于将显示拆分为多个组。我们的(/swagger/docs/v1)没有这样的元素。我试着在swagggerconfig.cs中玩我能看到的所有东西,但是运气不好 有没有简单的自动生成方法?一些选择,或者评论,或者我忽略的东西Swagger 虚张声势/虚张声势不在根元素处生成标记,swagger,openapi,swashbuckle,Swagger,Openapi,Swashbuckle,我们在.NETAPI(不是核心)上使用Swashback进行了Swagger设置 我正在寻找LucyBot来制作一个外观更好的文档页面。看看他们的示例,他们的OpenAPI文件在根目录下有一个“tags”元素,用于将显示拆分为多个组。我们的(/swagger/docs/v1)没有这样的元素。我试着在swagggerconfig.cs中玩我能看到的所有东西,但是运气不好 有没有简单的自动生成方法?一些选择,或者评论,或者我忽略的东西 "swagger": "2.0", "info": {
"swagger": "2.0",
"info": {
"description": "This is a demo of [LucyBot's API Documentation](http:\/\/lucybot.com) using swagger.io's Petstore server. You can find out more about Swagger at [http:\/\/swagger.io](http:\/\/swagger.io) or on [irc.freenode.net, #swagger](http:\/\/swagger.io\/irc\/). For this sample, you can use the api key `special-key` to test the authorization filters.\n\nTo use this documentation for your own API, visit [http:\/\/lucybot.com](http:\/\/lucybot.com)",
"version": "1.0.0",
"title": "Swagger Petstore",
"termsOfService": "http:\/\/swagger.io\/terms\/",
"contact": {
"email": "apiteam@swagger.io"
},
"license": {
"name": "Apache 2.0",
"url": "http:\/\/www.apache.org\/licenses\/LICENSE-2.0.html"
}
},
"host": "petstore.swagger.io",
"basePath": "\/v2",
"tags": [
{
"name": "pet",
"description": "Everything about your Pets",
"externalDocs": {
"description": "Find out more",
"url": "http:\/\/swagger.io"
}
},
{
"name": "store",
"description": "Access to Petstore orders"
},
{
"name": "user",
"description": "Operations about user",
"externalDocs": {
"description": "Find out more about our store",
"url": "http:\/\/swagger.io"
}
}
],```
查看外部文档的代码Swashback代码:
好东西在定义中有,但没有在任何地方使用 我认为您唯一的选择是使用和IDocumentFilter并注入缺少的标记。
以下是如何使用这些过滤器的示例:
查看外部文档的代码Swashback代码:
好东西在定义中有,但没有在任何地方使用 我认为您唯一的选择是使用和IDocumentFilter并注入缺少的标记。
以下是如何使用这些过滤器的示例: