Guest User

Untitled

a guest
Oct 15th, 2018
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.79 KB | None | 0 0
  1. services.AddSwaggerGen(c =>
  2. {
  3. c.SwaggerDoc("v1", new Info { Title = "aa.IM.CustomerApi", Version = "v1" });
  4. var basePath = Path.GetDirectoryName(typeof(Program).Assembly.Location);
  5. var controllerXmlPath = Path.Combine(basePath, "aa.IM.CustomerApi.xml");
  6. var entityXmlPath = Path.Combine(basePath, "aa.IM.Entity.xml");
  7. c.IncludeXmlComments(controllerXmlPath);
  8. c.IncludeXmlComments(entityXmlPath);
  9. //c.DescribeAllEnumsAsStrings();
  10. });
  11.  
  12. app.UseSwagger(c =>
  13. {
  14. });
  15. app.UseSwaggerUI(c =>
  16. {
  17. c.SwaggerEndpoint("v1/swagger.json", "Wingontravel.IM.CustomerApi");
  18. });
Add Comment
Please, Sign In to add comment