[Route Groups] Add default metadata to endpoints exposing group structure
- Dominant language
- C#
- Stars
- 38.4k
- Forks
- 10.9k
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 281
Description
### Is there an existing issue for this?
- [X] I have searched the existing issues
### Is your feature request related to a problem? Please describe the problem.
Currently the `MapGroup` API described in #36007 does not add any default metadata enabling endpoint to observe what groups they're in if any.
### Describe the solution you'd like
`MapGroup` should add default metadata. It's tempting to use `EndpointGroupNameAttribute` like `WithGroupName`, but this implications on the swagger.json produced by Swashbuckle and NSwag (see https://github.com/dotnet/aspnetcore/issues/36414), so we want to be careful here.
We also need to consider what the default group name should be (just the prefix?) and whether nested groups should add multiple pieced of metadata or if the nested group structure can be encapsulated in a single object.
Contributor guide
Assessment
This issue has not been assessed yet.