Soenneker.Groq.OpenApiClientUtil
11.0.95
Prefix Reserved
dotnet add package Soenneker.Groq.OpenApiClientUtil --version 11.0.95
NuGet\Install-Package Soenneker.Groq.OpenApiClientUtil -Version 11.0.95
<PackageReference Include="Soenneker.Groq.OpenApiClientUtil" Version="11.0.95" />
<PackageVersion Include="Soenneker.Groq.OpenApiClientUtil" Version="11.0.95" />
<PackageReference Include="Soenneker.Groq.OpenApiClientUtil" />
paket add Soenneker.Groq.OpenApiClientUtil --version 11.0.95
#r "nuget: Soenneker.Groq.OpenApiClientUtil, 11.0.95"
#:package Soenneker.Groq.OpenApiClientUtil@11.0.95
#addin nuget:?package=Soenneker.Groq.OpenApiClientUtil&version=11.0.95
#tool nuget:?package=Soenneker.Groq.OpenApiClientUtil&version=11.0.95
Soenneker.Groq.OpenApiClientUtil
Provides a lazily created Groq Kiota client over a shared, configured Groq HttpClient.
Installation
dotnet add package Soenneker.Groq.OpenApiClientUtil
Configuration
{
"Groq": {
"ApiKey": "gsk_...",
"ClientBaseUrl": "https://api.groq.com",
"AuthHeaderName": "Authorization",
"AuthHeaderValueTemplate": "Bearer {token}"
}
}
Only ApiKey is required. The other values show their defaults, and {token} is replaced with the API key.
Registration
using Soenneker.Groq.OpenApiClientUtil.Registrars;
services.AddGroqOpenApiClientUtilAsScoped();
The scoped registration is deliberate: each scope can release its generated-client utility while the singleton HTTP client remains available to later scopes. Use AddGroqOpenApiClientUtilAsSingleton() when the utility and generated client should also live for the application lifetime.
Usage
using Soenneker.Groq.OpenApiClient;
using Soenneker.Groq.OpenApiClient.Models;
using Soenneker.Groq.OpenApiClientUtil.Abstract;
GroqOpenApiClient client = await clientUtil.Get(cancellationToken);
ListModelsResponse? result = await client.Openai.V1.Models.GetAsync(
cancellationToken: cancellationToken);
Repeated and concurrent Get() calls on the same utility reuse one lazily initialized generated client. Cancellation can stop first-time initialization; pass a cancellation token separately to each generated API operation.
Authentication is supplied by the underlying HTTP provider, so the Kiota adapter does not add a second authorization header.
Let the service container dispose the utility. Do not dispose the shared HttpClient returned by the lower-level HTTP-client provider.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net11.0 is compatible. |
-
net11.0
- Soenneker.Groq.HttpClients (>= 11.0.89)
- Soenneker.Groq.OpenApiClient (>= 11.0.32)
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 |
|---|---|---|
| 11.0.95 | 0 | 10/27/2026 |
| 11.0.94 | 0 | 10/27/2026 |
| 11.0.93 | 4 | 10/26/2026 |
| 11.0.92 | 42 | 10/26/2026 |
| 11.0.91 | 56 | 10/26/2026 |
| 4.0.90 | 82 | 10/25/2026 |
| 4.0.89 | 127 | 10/15/2026 |
| 4.0.88 | 81 | 10/15/2026 |
| 4.0.87 | 83 | 10/14/2026 |
| 4.0.86 | 87 | 10/14/2026 |
| 4.0.84 | 89 | 10/14/2026 |
| 4.0.83 | 86 | 10/14/2026 |
| 4.0.77 | 78 | 10/13/2026 |
| 4.0.76 | 85 | 10/13/2026 |
| 4.0.74 | 88 | 10/12/2026 |
| 4.0.73 | 97 | 10/11/2026 |
| 4.0.72 | 102 | 10/11/2026 |
| 4.0.71 | 90 | 10/11/2026 |
| 4.0.70 | 504 | 10/10/2026 |
| 4.0.69 | 62,319 | 10/1/2026 |
Updated Soenneker.Groq.HttpClients to 11.0.89