Soenneker.Asana.HttpClients
11.0.161
Prefix Reserved
See the version list below for details.
dotnet add package Soenneker.Asana.HttpClients --version 11.0.161
NuGet\Install-Package Soenneker.Asana.HttpClients -Version 11.0.161
<PackageReference Include="Soenneker.Asana.HttpClients" Version="11.0.161" />
<PackageVersion Include="Soenneker.Asana.HttpClients" Version="11.0.161" />
<PackageReference Include="Soenneker.Asana.HttpClients" />
paket add Soenneker.Asana.HttpClients --version 11.0.161
#r "nuget: Soenneker.Asana.HttpClients, 11.0.161"
#:package Soenneker.Asana.HttpClients@11.0.161
#addin nuget:?package=Soenneker.Asana.HttpClients&version=11.0.161
#tool nuget:?package=Soenneker.Asana.HttpClients&version=11.0.161
Soenneker.Asana.HttpClients
Provides a cached, authenticated HttpClient for the Asana OpenAPI client.
Installation
dotnet add package Soenneker.Asana.HttpClients
Configuration
{
"Asana": {
"ApiKey": "your-personal-access-token"
}
}
Asana:ApiKey is required. The client uses https://app.asana.com/api/1.0 and Authorization: Bearer {token} by default. These optional settings override that behavior:
{
"Asana": {
"ClientBaseUrl": "https://proxy.example.com/asana/",
"AuthHeaderName": "Authorization",
"AuthHeaderValueTemplate": "Bearer {token}"
}
}
Registration
using Soenneker.Asana.HttpClients.Registrars;
services.AddAsanaOpenApiHttpClientAsSingleton();
AddAsanaOpenApiHttpClientAsScoped() is also available. Both registrations reuse the singleton HTTP-client cache.
Usage
using Soenneker.Asana.HttpClients.Abstract;
public sealed class AsanaTransport
{
private readonly IAsanaOpenApiHttpClient _clientProvider;
public AsanaTransport(IAsanaOpenApiHttpClient clientProvider)
{
_clientProvider = clientProvider;
}
public async Task<HttpResponseMessage> Send(HttpRequestMessage request, CancellationToken cancellationToken = default)
{
HttpClient client = await _clientProvider.Get(cancellationToken);
return await client.SendAsync(request, cancellationToken);
}
}
Get() creates the named client on first use and returns it afterward. Configuration changes do not rebuild an existing client. Do not dispose the returned HttpClient per request. Disposing the provider removes and disposes its named client from the shared cache.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net11.0 is compatible. |
-
net11.0
- Soenneker.Extensions.Configuration (>= 11.0.914)
- Soenneker.Utils.HttpClientCache (>= 4.0.2128)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Soenneker.Asana.HttpClients:
| Package | Downloads |
|---|---|
|
Soenneker.Asana.OpenApiClientUtil
A thread-safe utility for obtaining Asana's OpenApiClient singleton. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 11.0.162 | 0 | 10/26/2026 |
| 11.0.161 | 0 | 10/26/2026 |
| 11.0.160 | 32 | 10/26/2026 |
| 4.0.159 | 143 | 10/15/2026 |
| 4.0.158 | 83 | 10/14/2026 |
| 4.0.157 | 101 | 10/14/2026 |
| 4.0.155 | 98 | 10/14/2026 |
| 4.0.154 | 96 | 10/14/2026 |
| 4.0.147 | 103 | 10/13/2026 |
| 4.0.146 | 85 | 10/13/2026 |
| 4.0.144 | 128 | 10/12/2026 |
| 4.0.143 | 119 | 10/11/2026 |
| 4.0.142 | 98 | 10/11/2026 |
| 4.0.141 | 89 | 10/11/2026 |
| 4.0.140 | 151 | 10/9/2026 |
| 4.0.139 | 190 | 10/1/2026 |
| 4.0.138 | 131 | 9/29/2026 |
| 4.0.137 | 113 | 9/29/2026 |
| 4.0.136 | 133 | 9/26/2026 |
| 4.0.135 | 115 | 9/26/2026 |
Update dependency Soenneker.Extensions.Configuration to 11.0.914 (#323)