dotnet / dotnet/AspNetCore.Docs
Need help understanding how to describe my API for Visual Studio
- Dominant language
- C#
- Stars
- 13.1k
- Forks
- 24.6k
- Avg merge
- 1d 3h
- Merged PRs (30d)
- 97
Description
I want to build a Web API that has the metadata required for Visual Studio's connected service wizard (NSwagClient) to generate usable client code. Is there a doc that describes what attributes I should be using to describe my API?
As an example:
It looks like API Conventions would be part of that recommendation, but I believe the _RouteName_ of an `[HttpGet]` attribute will be used in the Swagger description as "operation name" which is used to describe the names of the methods generated by NSwagClient.
---
#### Document Details
⚠ *Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.*
* ID: 9d14d206-7998-2031-d1d7-f8c8dbecf54a
* Version Independent ID: 3071c40e-f08b-555e-4fe7-dc3828f5828e
* Content: [Use web API conventions](https://docs.microsoft.com/en-us/aspnet/core/web-api/advanced/conventions?view=aspnetcore-6.0)
* Content Source: [aspnetcore/web-api/advanced/conventions.md](https://github.com/dotnet/AspNetCore.Docs/blob/main/aspnetcore/web-api/advanced/conventions.md)
* Product: **aspnet-core**
* Technology: **aspnetcore-webapi**
* GitHub Login: @pranavkm
* Microsoft Alias: **scaddie**
Contributor guide
Assessment
This issue has not been assessed yet.