Soenneker.Kiota.GenericAuthenticationProvider
4.0.56
Prefix Reserved
dotnet add package Soenneker.Kiota.GenericAuthenticationProvider --version 4.0.56
NuGet\Install-Package Soenneker.Kiota.GenericAuthenticationProvider -Version 4.0.56
<PackageReference Include="Soenneker.Kiota.GenericAuthenticationProvider" Version="4.0.56" />
<PackageVersion Include="Soenneker.Kiota.GenericAuthenticationProvider" Version="4.0.56" />
<PackageReference Include="Soenneker.Kiota.GenericAuthenticationProvider" />
paket add Soenneker.Kiota.GenericAuthenticationProvider --version 4.0.56
#r "nuget: Soenneker.Kiota.GenericAuthenticationProvider, 4.0.56"
#:package Soenneker.Kiota.GenericAuthenticationProvider@4.0.56
#addin nuget:?package=Soenneker.Kiota.GenericAuthenticationProvider&version=4.0.56
#tool nuget:?package=Soenneker.Kiota.GenericAuthenticationProvider&version=4.0.56
Soenneker.Kiota.GenericAuthenticationProvider
A Kiota authentication provider for custom credential headers, optional companion headers, and host restrictions.
Install
dotnet add package Soenneker.Kiota.GenericAuthenticationProvider
Usage
using Microsoft.Kiota.Http.HttpClientLibrary;
using Soenneker.Kiota.GenericAuthenticationProvider;
var authentication = new GenericAuthenticationProvider(
headerName: "X-Api-Key",
headerValue: apiKey,
additionalHeaders: new Dictionary<string, string>
{
["Api-Version"] = "2026-01-01"
},
allowedHosts: new[] { "api.example.com" });
var adapter = new HttpClientRequestAdapter(
authentication,
httpClient: httpClient);
Host names do not include a scheme or path. On an allowed HTTPS request, the provider replaces the configured credential header and companion headers with the configured values. On an off-host request, it removes those headers so a reused RequestInformation or Kiota raw-URL call cannot carry credentials elsewhere.
Always supply allowedHosts when the API host is known. For compatibility, omitting it pins the provider to the first HTTPS host it authenticates; later hosts receive no credential headers. An explicit allowlist is safer because it also protects the first request.
Plain HTTP is rejected by default. Set allowInsecureHttp: true only for a controlled local endpoint. The provider snapshots additionalHeaders during construction, so later dictionary changes do not alter live authentication behavior.
| Product | Versions 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. |
-
net10.0
- Microsoft.Kiota.Abstractions (>= 2.1.2)
NuGet packages (30)
Showing the top 5 NuGet packages that depend on Soenneker.Kiota.GenericAuthenticationProvider:
| Package | Downloads |
|---|---|
|
Soenneker.TrustedForm.Certificates.ClientUtil
Provides lazily initialized, authenticated access to the TrustedForm Certificate API v4 client. |
|
|
Soenneker.Calendly.OpenApiClientUtil
A thread-safe utility for obtaining Calendly's OpenApiClient singleton. |
|
|
Soenneker.Asana.OpenApiClientUtil
A thread-safe utility for obtaining Asana's OpenApiClient singleton. |
|
|
Soenneker.Bandwidth.OpenApiClientUtil
A thread-safe utility for obtaining Bandwidth's OpenApiClient singleton. |
|
|
Soenneker.Twilio.OpenApiClientUtil
Provides an authenticated, cached Twilio OpenAPI client |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 4.0.56 | 1,043 | 10/14/2026 |
| 4.0.55 | 395 | 10/14/2026 |
| 4.0.50 | 550 | 10/12/2026 |
| 4.0.49 | 985 | 10/12/2026 |
| 4.0.48 | 1,534 | 10/11/2026 |
| 4.0.47 | 5,933 | 9/24/2026 |
| 4.0.46 | 2,803 | 9/15/2026 |
| 4.0.45 | 2,697 | 9/12/2026 |
| 4.0.44 | 1,985 | 9/8/2026 |
| 4.0.43 | 2,808 | 9/4/2026 |
| 4.0.42 | 1,944 | 9/3/2026 |
| 4.0.41 | 3,179 | 8/30/2026 |
| 4.0.40 | 4,068 | 8/29/2026 |
| 4.0.39 | 137 | 8/29/2026 |
| 4.0.38 | 44,392 | 7/28/2026 |
| 4.0.37 | 6,390 | 7/21/2026 |
| 4.0.36 | 14,612 | 7/16/2026 |
| 4.0.35 | 27,111 | 6/18/2026 |
| 4.0.34 | 21,113 | 6/5/2026 |
| 4.0.33 | 151 | 6/5/2026 |
Update dependency dotnet-sdk to v10.0.402 (#410)
Automatically merged