MicroCloud.Swagger
7.0.0.9
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package MicroCloud.Swagger --version 7.0.0.9
NuGet\Install-Package MicroCloud.Swagger -Version 7.0.0.9
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="MicroCloud.Swagger" Version="7.0.0.9" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add MicroCloud.Swagger --version 7.0.0.9
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: MicroCloud.Swagger, 7.0.0.9"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install MicroCloud.Swagger as a Cake Addin #addin nuget:?package=MicroCloud.Swagger&version=7.0.0.9 // Install MicroCloud.Swagger as a Cake Tool #tool nuget:?package=MicroCloud.Swagger&version=7.0.0.9
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
MicroCloud Swagger API 文档生成组件
说明
集成 Swagger
API 文档生成组件,方便前后端分离的开发模式中前后端开发人员的数据接口对接工作。基于Swagger
的工作原理,API的输入输出都需使用强类型
的数据类型,Swagger
才能发挥更好的作用,而MicroCloud框架通过AutoMapper
的ProjectTo
对业务实体到输出DTOIOutputDto
提供了自动映射功能,能有效减轻后端开发中数据对象属性映射的工作量。
用法
可按照如下配置方式使用:
- 通过nuget引用
MicroCloud.Swagger
程序集
Install-Package MicroCloud.Swagger 2. 在
appsettings.json
中 的MicroCloud
节点下添加如下配置节点
{
//Swagger选项
"Swagger": {
"UI": "swagger", //界面样式:knife4j、swagger(默认)。
"DocumentTitle": "接口文档", //界面标题
"HeadContent": "", //标头内容
"RoutePrefix": "swagger", //路由前缀
"IsHideSchemas": false, //隐藏架构
"MiniProfiler": true, //启用轻量级工具分析
// 注释文档
"CommentDoc": {
"SearchPattern": "MicroCloud*.xml", //与要搜索的文件名匹配的搜索字符串。此参数可以包含有效文本路径和通配符(*和?)的组合字符,但它不支持正则表达式。默认"MicroCloud*.xml"。
"FilterExpression": "" //过滤文档文件的正则表达式,用于筛选后的特殊过滤。
},
//分组集合
"Groups": [
{
"Name": "api", //名称
"Title": "框架API", //标题
"Description": "框架API", //描述
"Url": "", //Url
// 联系人
"Contact": {
"Name": "MicroCloud", //联系人名称
"Url": "https://toscode.gitee.com/MicroCloud", //联系人链接
"Email": "union@sanqing.tech" //联系人邮箱
},
// 许可
"License": {
"Name": "Apache", //许可名称
"Url": "https://www.apache.org/licenses/LICENSE-2.0" //许可链接
},
"Visible": true //是否可见
},
{
"Name": "buss", //名称
"Title": "业务API", //标题
"Description": "业务API", //描述
"Url": "/swagger/buss/swagger.json", //Url
// 联系人
"Contact": {
"Name": "MicroCloud", //联系人名称
"Url": "https://toscode.gitee.com/MicroCloud", //联系人链接
"Email": "union@sanqing.tech" //联系人邮箱
},
// 许可
"License": {
"Name": "MIT", //许可名称
"Url": "https://opensource.org/licenses/MIT" //许可链接
},
"Visible": false //是否可见
}
],
"Enabled": true //是否启用
},
}
- 要禁用Swagger,可以设置
Enabled: false
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net7.0 is compatible. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net7.0
- MicroCloud.AspNetCore (>= 7.0.0.9)
- MicroCloud.MiniProfiler (>= 7.0.0.9)
- Swashbuckle.AspNetCore (>= 6.5.0)
- Swashbuckle.AspNetCore.Newtonsoft (>= 6.5.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Version | Downloads | Last updated |
---|---|---|
8.0.3.1 | 99 | 9/9/2024 |
8.0.2.9 | 110 | 9/5/2024 |
8.0.2.8 | 96 | 8/31/2024 |
8.0.2.7 | 96 | 8/31/2024 |
8.0.2.6 | 124 | 8/21/2024 |
8.0.2.5 | 133 | 8/21/2024 |
8.0.2.4 | 120 | 8/12/2024 |
8.0.2.3 | 105 | 8/8/2024 |
8.0.2.2 | 107 | 7/14/2024 |
8.0.2.1 | 94 | 6/7/2024 |
8.0.1.9 | 90 | 6/6/2024 |
8.0.1.8 | 91 | 6/6/2024 |
8.0.1.7 | 114 | 5/15/2024 |
8.0.1.6 | 98 | 5/15/2024 |
8.0.1.5 | 120 | 5/15/2024 |
8.0.1.4 | 108 | 5/14/2024 |
8.0.1.3 | 107 | 5/10/2024 |
8.0.1.2 | 135 | 5/8/2024 |
8.0.1.1 | 110 | 5/7/2024 |
8.0.0.9 | 111 | 5/1/2024 |
8.0.0.8 | 114 | 5/1/2024 |
8.0.0.7 | 131 | 4/30/2024 |
8.0.0.5 | 115 | 4/19/2024 |
8.0.0.4 | 109 | 4/18/2024 |
8.0.0.3 | 128 | 4/15/2024 |
8.0.0.2 | 125 | 4/12/2024 |
8.0.0.1 | 120 | 4/12/2024 |
7.2.0.8 | 119 | 4/12/2024 |
7.2.0.7 | 112 | 4/12/2024 |
7.2.0.6 | 122 | 4/12/2024 |
7.2.0.5 | 121 | 4/12/2024 |
7.2.0.4 | 133 | 4/11/2024 |
7.2.0.2 | 138 | 4/7/2024 |
7.2.0.1 | 313 | 10/26/2023 |
7.1.2.9 | 139 | 11/7/2023 |
7.1.2.8 | 153 | 10/19/2023 |
7.1.2.7 | 152 | 10/19/2023 |
7.1.2.6 | 150 | 10/18/2023 |
7.1.2.4 | 159 | 9/13/2023 |
7.1.2.3 | 139 | 9/13/2023 |
7.1.2.2 | 133 | 9/12/2023 |
7.1.2.1 | 130 | 9/4/2023 |
7.1.1.9 | 175 | 8/31/2023 |
7.1.1.6 | 156 | 8/29/2023 |
7.1.1.5 | 138 | 8/25/2023 |
7.1.1.4 | 138 | 8/25/2023 |
7.1.1.3 | 164 | 8/25/2023 |
7.1.1.2 | 160 | 8/24/2023 |
7.1.1.1 | 152 | 8/24/2023 |
7.0.3.1 | 162 | 8/24/2023 |
7.0.2.7 | 144 | 5/12/2023 |
7.0.2.6 | 173 | 5/11/2023 |
7.0.1.7 | 153 | 5/9/2023 |
7.0.1.6 | 147 | 5/9/2023 |
7.0.1.4 | 183 | 4/24/2023 |
7.0.1.3 | 192 | 4/19/2023 |
7.0.1.2 | 194 | 4/19/2023 |
7.0.0.9 | 186 | 4/18/2023 |
7.0.0.8 | 194 | 4/17/2023 |
7.0.0.7 | 186 | 4/12/2023 |
7.0.0.6 | 193 | 4/8/2023 |
7.0.0.5 | 197 | 4/7/2023 |
7.0.0.4 | 209 | 4/7/2023 |
7.0.0.3 | 193 | 4/7/2023 |