How can I catch all requests starts with /X in AttributeRouting
-
02-07-2021 - |
Question
Urls: /X?take=1&skip=4
[GET("X/{request:alpha?}", IsAbsoluteUrl = true)]
[GET("X{request:alpha?}", IsAbsoluteUrl = true)]
[GET("X{request:alpha*}", IsAbsoluteUrl = true)]
does not work.
Solution
Because using POST Attribute is preventing to GET request handling.
I was using both POST and GET. I've changed them to ROUTE.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow