In swagger feature I was able to add operation filter as described below. How would this translate to in OpenAPI?
OperationFilter = op =>
var name = op.Nickname;
if ((name == typeof(UploadRequest).Name
&& op.Method == HttpMethods.Post)
Name = "Upload",
ParamType = "body",
Type = "file",
AllowMultiple = true
But there is no proper name for the operation. Only property that seems usable is OperationId but that appended with property name. Something like
Yes it does but how do I filter the endpoints. Before I was able to do that by comparing the
Type.Name. Now there is no
Nickname property on
OpenApiOperation so I can't really filter the operations.
NickName isn't apart of the OpenApi Specification which is why it doesn't exist on the Open API Operation DTO. The OperationId starts with the name of the request DTO so you could check for that. I've also added a non-serializable RequestType property you can use in this commit.
This change is available from v4.5.13 that's now available on MyGet.