MVFC.Pack.HttpClient
5.0.0
dotnet add package MVFC.Pack.HttpClient --version 5.0.0
NuGet\Install-Package MVFC.Pack.HttpClient -Version 5.0.0
<PackageReference Include="MVFC.Pack.HttpClient" Version="5.0.0" />
<PackageVersion Include="MVFC.Pack.HttpClient" Version="5.0.0" />
<PackageReference Include="MVFC.Pack.HttpClient" />
paket add MVFC.Pack.HttpClient --version 5.0.0
#r "nuget: MVFC.Pack.HttpClient, 5.0.0"
#:package MVFC.Pack.HttpClient@5.0.0
#addin nuget:?package=MVFC.Pack.HttpClient&version=5.0.0
#tool nuget:?package=MVFC.Pack.HttpClient&version=5.0.0
MVFC.Pack.HttpClient
Metapackage providing dependencies for typed HTTP clients using Refit, HttpClientFactory, and HTTP resilience policies in .NET 9 and 10 applications.
What It Is and What It Is Not
- What it is: A passive dependency metapackage that consolidates and pins the necessary packages to declare typed REST clients (Refit + HttpClientFactory) and configure resilience pipelines (
Microsoft.Extensions.Http.Resilience). - What it is not: An HTTP framework, wrapper library, or automatic runtime service registrar. It contains no runtime code, creates no handlers, and registers no services automatically. The consuming application decides all registrations and pipeline configurations explicitly.
Installation
dotnet add package MVFC.Pack.HttpClient
Included Packages
| Package | Version | Purpose |
|---|---|---|
Refit |
8.0.0 (net9) / 16.4.0 (net10/11) | Declarative, typed REST client for .NET. |
Refit.HttpClientFactory |
8.0.0 (net9) / 16.4.0 (net10/11) | Integrates Refit clients with IHttpClientFactory. |
Microsoft.Extensions.Http |
9.0.2 (net9) / 10.0.14 (net10) / 11.0.0 (net11) | Core IHttpClientFactory abstractions and client configuration. |
Microsoft.Extensions.Http.Resilience |
9.2.0 (net9) / 10.11.0 (net10) / 11.0.0 (net11) | Standard resilience pipelines (retry, circuit breaker, timeout, rate limiter) based on Polly. |
Quick Start
In your application startup / DI configuration:
using Microsoft.Extensions.DependencyInjection;
using Refit;
// 1. Define your typed client interface
public interface IPingApi
{
[Get("/ping")]
Task<string> PingAsync(CancellationToken cancellationToken = default);
}
// 2. Register with HttpClientFactory and resilience
public static class HttpClientSetup
{
public static void Configure(IServiceCollection services)
{
services.AddRefitClient<IPingApi>()
.ConfigureHttpClient(client =>
{
client.BaseAddress = new Uri("https://api.example.com");
})
.AddStandardResilienceHandler();
}
}
Resilience & Idempotency Warning:
The standard resilience handler includes retry policies that may not be safe for non-idempotent HTTP methods (such as POST or operations with side-effects). Ensure your retry strategy is explicitly adapted to each endpoint's semantics to prevent unintentional duplicate requests.
Compatibility
- Supported target frameworks in this release:
net9.0;net10.0. - Compatibility with .NET 9 is aligned with the current repository product line and does not constitute a long-term support commitment.
License
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net9.0 is compatible. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. net11.0 is compatible. |
-
net10.0
- Microsoft.Extensions.Http (= 10.0.14)
- Microsoft.Extensions.Http.Resilience (= 10.11.0)
- Refit (>= 16.4.0)
- Refit.HttpClientFactory (>= 16.4.0)
-
net11.0
- Microsoft.Extensions.Http (>= 11.0.0)
- Microsoft.Extensions.Http.Resilience (>= 11.0.0)
- Refit (>= 16.4.0)
- Refit.HttpClientFactory (>= 16.4.0)
-
net9.0
- Microsoft.Extensions.Http (= 9.0.2)
- Microsoft.Extensions.Http.Resilience (= 9.2.0)
- Refit (= 8.0.0)
- Refit.HttpClientFactory (= 8.0.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 5.0.0 | 109 | 11/15/2026 |