RicoSuter / NSwag

The Swagger/OpenAPI toolchain for .NET, ASP.NET Core and TypeScript.
http://NSwag.org
MIT License
6.61k stars 1.22k forks source link

Support `$ref` in `requestBody` #4917

Open eatdrinksleepcode opened 3 weeks ago

eatdrinksleepcode commented 3 weeks ago

Fixes #2122

This MR adds support for $ref in requestBody, as well as requestBodies in components.

Since the existing implementation does not attempt to do cross-updates between OpenApiRequestBody and a referenced OpenApiParameter, so this MR does not attempt to cross-update the other direction.