liveBook · Manning

IHttpClientFactory

IHttpClientFactory is a .NET dependency-injection abstraction for creating configured HttpClient instances while managing their underlying handlers.

How 2 Manning books explain it

ASP.NET Core in Action, 3e

IHttpClientFactory is the .NET dependency-injection service for creating configured HttpClient instances and managing their underlying handlers.

How it is used
Creates configured HttpClient instances for outgoing API calls while managing handler lifetimes.
How deep it goes
Explains handler pooling and replacement, then shows registration, named and typed clients, retries, and custom handlers.
Examples
Uses a minimal API calling an exchange-rate endpoint and a custom handler that attaches an API-key header.
What you can do after
Operate/configure it to register named or typed clients, add outgoing handlers, and choose a transient-error retry policy.

Read how ASP.NET Core in Action, 3e explains IHttpClientFactory →

.NET MAUI in Action

IHttpClientFactory is a .NET dependency-injection service for creating configured HttpClient instances and managing their underlying handlers.

How it is used
Configures and resolves purpose-specific HttpClient instances through .NET dependency injection.
How deep it goes
Explains registration, naming, handler chaining, and resolution, but does not detail HttpClient internals.
Examples
Uses AuthHandler, AUTHENTICATED_CLIENT, AddApiClientServices, and BaseService as concrete configuration and consumption examples.
What you can do after
Operate/configure named HttpClient instances and attach reusable handlers for authenticated requests.

Read how .NET MAUI in Action explains IHttpClientFactory →

Related concepts

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.