Reputation: 3364
Let's say I have an instance of HttpClient
which is already configured. And now I want to use it for Flurl requests. I'd like to do something like this:
var poco = await httpClient.GetJsonAsync<POCO>();
Is this possible?
Upvotes: 3
Views: 2137
Reputation: 39319
Sure...
var flurlClient = new FlurlClient(httpClient);
var poco = await flurlClient.Request(url).GetJsonAsync<POCO>();
Upvotes: 2