Soenneker.Kiota.BearerAuthenticationProvider
4.0.48
Prefix Reserved
See the version list below for details.
dotnet add package Soenneker.Kiota.BearerAuthenticationProvider --version 4.0.48
NuGet\Install-Package Soenneker.Kiota.BearerAuthenticationProvider -Version 4.0.48
<PackageReference Include="Soenneker.Kiota.BearerAuthenticationProvider" Version="4.0.48" />
<PackageVersion Include="Soenneker.Kiota.BearerAuthenticationProvider" Version="4.0.48" />
<PackageReference Include="Soenneker.Kiota.BearerAuthenticationProvider" />
paket add Soenneker.Kiota.BearerAuthenticationProvider --version 4.0.48
#r "nuget: Soenneker.Kiota.BearerAuthenticationProvider, 4.0.48"
#:package Soenneker.Kiota.BearerAuthenticationProvider@4.0.48
#addin nuget:?package=Soenneker.Kiota.BearerAuthenticationProvider&version=4.0.48
#tool nuget:?package=Soenneker.Kiota.BearerAuthenticationProvider&version=4.0.48
Soenneker.Kiota.BearerAuthenticationProvider
A host-restricted Kiota authentication provider for static bearer tokens.
Install
dotnet add package Soenneker.Kiota.BearerAuthenticationProvider
Usage
using Microsoft.Kiota.Http.HttpClientLibrary;
using Soenneker.Kiota.BearerAuthenticationProvider;
var authentication = new BearerAuthenticationProvider(
accessToken,
"api.example.com");
var adapter = new HttpClientRequestAdapter(
authentication,
httpClient: httpClient);
Supply host names without a scheme or path. The multiple-host constructor accepts an IEnumerable<string>.
The provider replaces Authorization with Bearer <token> only when the final request URI uses HTTPS and its host is allowed. It removes an existing authorization header when the URI is not allowed, preventing a reused RequestInformation or Kiota raw-URL request from carrying the token to another host.
Plain HTTP is rejected by default. allowInsecureHttp: true exists for controlled local development only. This provider stores one static token; create a new provider when it changes, or use a Kiota access-token provider for refreshable OAuth credentials.
| 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.0)
NuGet packages (2)
Showing the top 2 NuGet packages that depend on Soenneker.Kiota.BearerAuthenticationProvider:
| Package | Downloads |
|---|---|
|
Soenneker.Cloudflare.Utils.Client
Thread-safe caching and configuration for generated Cloudflare OpenAPI clients. |
|
|
Soenneker.X.ClientUtil
Provides a cached X OpenAPI client authenticated with a configured bearer token. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 4.0.62 | 962 | 10/14/2026 |
| 4.0.61 | 325 | 10/14/2026 |
| 4.0.56 | 577 | 10/12/2026 |
| 4.0.55 | 192 | 10/12/2026 |
| 4.0.54 | 1,476 | 10/11/2026 |
| 4.0.53 | 6,303 | 9/24/2026 |
| 4.0.52 | 1,925 | 9/15/2026 |
| 4.0.51 | 2,875 | 9/12/2026 |
| 4.0.50 | 2,110 | 9/8/2026 |
| 4.0.49 | 3,270 | 9/4/2026 |
| 4.0.48 | 1,562 | 9/3/2026 |
| 4.0.47 | 288 | 8/30/2026 |
| 4.0.46 | 6,756 | 8/29/2026 |
| 4.0.45 | 1,089 | 8/29/2026 |
| 4.0.44 | 87,268 | 7/28/2026 |
| 4.0.43 | 36,048 | 7/16/2026 |
| 4.0.42 | 47,132 | 6/18/2026 |
| 4.0.41 | 43,651 | 6/5/2026 |
| 4.0.40 | 136 | 6/5/2026 |
| 4.0.39 | 41,711 | 5/7/2026 |
Update dependency Microsoft.Kiota.Abstractions to 2.1.0 (#588)