By default, the ASP. NET Web API does not generate a Help document from the controller's comments. If you want to use annotations as part of the Web API help document, such as displaying the summary in the method comments in the Description column of the Help document, you need to do some configuration.
First open the property page for the Web API project in Visual Studio, on the Build Settings page, select the XML document file, and enter the path to the XML file that will be generated, for example: App_data\openapi.xml.
The project is then compiled, and the XML file is generated under the corresponding path.
Then open the Areas\helppage\app_start\helppageconfig.cs file and cancel config. Setdocumentationprovider code comments, modify the path:
Config. Setdocumentationprovider (new Xmldocumentationprovider (HttpContext.Current.Server.MapPath (" ~/app_data/openapi.xml ")));
Then recompile and visit the/help page to see the effect.
ASP. NET Web API generates help documents from annotations