Is there a way to query a web api through "GET", but with complex object in its parameter?
All the examples I have seen so far seems to indicate I would have to use "POST". But I don't want to use "POST", because this is a query, at the same time I don't want a function with 16 arguments because that just screams brittle.
public Product Get(int id, string name, DateTime createdBy, string stockNumber, ... )
{
...
}
I want the above to be turned into:
public Product Get(ProductQuery query)
{
...
}
Is there a way to do this? And how do you make the HttpClient work with the above service.