Bart Koelman
Bart Koelman
Thanks. I'll try to find some time, though I wouldn't mind if someone else picked this up. Perhaps label with "help wanted" and "good first issue"?
This warning is currently suppressed at: https://github.com/json-api-dotnet/JsonApiDotNetCore/blob/0c79d355946bc1f4099d684c40ef55603af55d08/Directory.Build.props#L14
Thanks for trying the preview and reporting back. It's already possible to serialize as strings. Did you add the last line from https://github.com/json-api-dotnet/JsonApiDotNetCore/blob/master/test/OpenApiTests/LegacyOpenApi/LegacyStartup.cs? I don't remember enum description handling, but...
Here an enum is serialized with names: https://github.com/json-api-dotnet/JsonApiDotNetCore/blob/master/test/OpenApiTests/LegacyOpenApi/GeneratedSwagger/swagger.g.json#L6030
According to https://github.com/microsoft/kiota/issues/90, kiota looks for `x-ms-enum`, which is described at https://azure.github.io/autorest/extensions/#x-ms-enum.
Seems that Swashbuckle doesn't support doc-comments on enum members, according to https://github.com/domaindrivendev/Swashbuckle.WebApi/issues/1290. There it is mentioned the problem can be worked around with a custom schema filter.
Yeah, this is one of those gaps in the OpenAPI spec. At least a way is provided in the OpenAPI v3.1 spec: https://spec.openapis.org/oas/v3.1.1.html#x4-8-24-6-4-model-with-annotated-enumeration.
As indicated at https://github.com/json-api-dotnet/JsonApiDotNetCore/issues/1731#issuecomment-2941908912, there are additional costs to fetching this information. I suppose it could be implemented, though I never expected users to actually paginate through related resources, because...
Well, that's trading a _potential_ extra query (namely, only when the page is full) for _always_ doing an extra query to determine the related count. This multiplies per top-level resource....
Sure. Do you want to open a PR?