I have following method definition in a web api controller:
[Route("collections")]
public HttpResponseMessage Collections(int c = 50, int p = 0)
and usually I call it like this
api/collections?count=10&page=0.
Are there any way to call that method as
api/collections?count&page
without getting BadRequest?
I think as "c" param has default value = 50 and "p" param has default value = 0 then api/collections?count&page should be transformed to api/collections?count=50&page=0. But asp.net web api didn't understand that.
Are there any way to make asp.net web api understand url api/collections?count&page?
Thank you.