Soenneker.OpenRouter.OpenApiClient 11.0.118

Prefix Reserved
There is a newer version of this package available.
See the version list below for details.
dotnet add package Soenneker.OpenRouter.OpenApiClient --version 11.0.118
                    
NuGet\Install-Package Soenneker.OpenRouter.OpenApiClient -Version 11.0.118
                    
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="Soenneker.OpenRouter.OpenApiClient" Version="11.0.118" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.OpenRouter.OpenApiClient" Version="11.0.118" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.OpenRouter.OpenApiClient" />
                    
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 Soenneker.OpenRouter.OpenApiClient --version 11.0.118
                    
#r "nuget: Soenneker.OpenRouter.OpenApiClient, 11.0.118"
                    
#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 Soenneker.OpenRouter.OpenApiClient@11.0.118
                    
#: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=Soenneker.OpenRouter.OpenApiClient&version=11.0.118
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.OpenRouter.OpenApiClient&version=11.0.118
                    
Install as a Cake Tool

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

alternate text is missing from this package README image Soenneker.OpenRouter.OpenApiClient

Typed request builders and models for calling OpenRouter's unified AI API from .NET.

Installation

dotnet add package Soenneker.OpenRouter.OpenApiClient

Usage

using System.Net.Http.Headers;
using Microsoft.Kiota.Abstractions.Authentication;
using Microsoft.Kiota.Http.HttpClientLibrary;
using Soenneker.OpenRouter.OpenApiClient;

var httpClient = new HttpClient();
httpClient.DefaultRequestHeaders.Authorization =
    new AuthenticationHeaderValue("Bearer", apiKey);

var adapter = new HttpClientRequestAdapter(
    new AnonymousAuthenticationProvider(),
    httpClient: httpClient);

var client = new OpenRouterOpenApiClient(adapter);
var models = await client.Models.GetAsync(cancellationToken: cancellationToken);

The client defaults to https://openrouter.ai/api/v1. Its request builders cover models, chat completions, responses, embeddings, generation metadata, providers, credits, keys, and workspaces.

For configuration-based credentials and managed client reuse, use Soenneker.OpenRouter.OpenApiClientUtil.

Product Compatible and additional computed target framework versions.
.NET net11.0 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Soenneker.OpenRouter.OpenApiClient:

Package Downloads
Soenneker.OpenRouter.OpenApiClientUtil

Provides a configured OpenRouter API client and reuses it for the lifetime of the registered service.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
11.0.128 0 11/26/2026
11.0.127 98 11/25/2026
11.0.126 113 11/24/2026
11.0.125 107 11/22/2026
11.0.124 111 11/21/2026
11.0.123 107 11/20/2026
11.0.122 132 11/19/2026
11.0.121 139 11/18/2026
11.0.120 101 11/18/2026
11.0.119 145 11/17/2026
11.0.118 114 11/17/2026
11.0.117 117 11/17/2026
11.0.116 137 11/15/2026
11.0.115 150 11/14/2026
11.0.114 161 11/13/2026
11.0.113 475 11/12/2026
11.0.112 168 11/12/2026
11.0.111 178 11/11/2026
11.0.110 104 11/10/2026
11.0.109 3,177 11/10/2026
Loading failed

Updated Multiple NuGet packages