ReadableHttp.AspNetCore 2.1.0

dotnet add package ReadableHttp.AspNetCore --version 2.1.0
                    
NuGet\Install-Package ReadableHttp.AspNetCore -Version 2.1.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="ReadableHttp.AspNetCore" Version="2.1.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ReadableHttp.AspNetCore" Version="2.1.0" />
                    
Directory.Packages.props
<PackageReference Include="ReadableHttp.AspNetCore" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add ReadableHttp.AspNetCore --version 2.1.0
                    
#r "nuget: ReadableHttp.AspNetCore, 2.1.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package ReadableHttp.AspNetCore@2.1.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=ReadableHttp.AspNetCore&version=2.1.0
                    
Install as a Cake Addin
#tool nuget:?package=ReadableHttp.AspNetCore&version=2.1.0
                    
Install as a Cake Tool

ReadableHttp.AspNetCore

.NET 10 dependency injection and IHttpClientFactory integration for ReadableHttp. Works with ASP.NET Core and other hosts using Microsoft.Extensions.DependencyInjection.

dotnet add package ReadableHttp.AspNetCore --version 2.1.0

Default client

using ReadableHttp.AspNetCore;

builder.Services.AddReadableHttp(client =>
{
    client.BaseAddress = new Uri("https://api.example.com/");
    client.Timeout = TimeSpan.FromSeconds(30);
});

Inject IReadableHttpExecutor for the default client, or IReadableHttpFactory to select named clients. Existing SendAsync(request, context, token) and SendExchangeAsync model APIs remain available.

Named fluent requests

using ReadableHttp;
using ReadableHttp.AspNetCore;

builder.Services.AddReadableHttpClient("billing", client =>
{
    client.BaseAddress = new Uri("https://billing.example.com/");
});

app.MapGet("/invoices/{id}", async (
    string id, IReadableHttpFactory factory, CancellationToken cancellationToken) =>
    await factory.Request("invoices/{id}", "billing")
        .WithPathParameter("id", id)
        .SendAsync<InvoiceDto>(cancellationToken));

AddReadableHttpClient returns IHttpClientBuilder, so handler configuration can be chained. The SDK registration disables automatic redirects and cookie storage on the standard primary handler. This keeps SDK redirect handling active and avoids pooled cookie state between requests. If you replace the primary handler afterward, configure these policies on your replacement.

For existing AddHttpClient(name) registrations, call factory.CreateExecutor(name) or factory.Request(url, name). Their handler configuration remains application-owned; disable automatic redirects for SDK redirect tracking and credential handling. Proxy/TLS/cookie options in an execution context do not reconfigure an external handler.

The factory creates and disposes an HttpClient per call while IHttpClientFactory pools handlers. Configure credentials per request instead of DefaultRequestHeaders when following cross-origin redirects. SendAsync throws ReadableHttpException on HTTP/transport failures; SendExchangeAsync retains the response and error. Cancellation continues to propagate. Streaming is available on the same fluent builder.

Product Compatible and additional computed target framework versions.
.NET 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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

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
2.1.0 96 9/5/2026
2.0.0 131 6/23/2026