Minimal APIs doesn't support binding to StringValues from query or headers #36726
Labels
area-minimal
Includes minimal APIs, endpoint filters, parameter binding, request delegate generator etc
feature-minimal-actions
Controller-like actions for endpoint routing
old-area-web-frameworks-do-not-use
*DEPRECATED* This label is deprecated in favor of the area-mvc and area-minimal labels
Priority:2
Work that is important, but not critical for the release
triage-focus
Add this label to flag the issue for focus at triage
Milestone
Describe the bug
Parameter binding doesn't support StringValues (which is ASP.NET Core's native representation of both query string and header values).
To Reproduce
OR
Exceptions (if any)
The first fails parameter binding things that
StringValues
is a body parameter.When adding
[FromQuery]
, it also fails but it's becauseStringValues
doesn't have aTryParse
method:It feels bad that our native representation doesn't work...
The text was updated successfully, but these errors were encountered: