Soenneker.Groq.OpenApiClientUtil
11.0.144
Prefix Reserved
dotnet add package Soenneker.Groq.OpenApiClientUtil --version 11.0.144
NuGet\Install-Package Soenneker.Groq.OpenApiClientUtil -Version 11.0.144
<PackageReference Include="Soenneker.Groq.OpenApiClientUtil" Version="11.0.144" />
<PackageVersion Include="Soenneker.Groq.OpenApiClientUtil" Version="11.0.144" />
<PackageReference Include="Soenneker.Groq.OpenApiClientUtil" />
paket add Soenneker.Groq.OpenApiClientUtil --version 11.0.144
#r "nuget: Soenneker.Groq.OpenApiClientUtil, 11.0.144"
#:package Soenneker.Groq.OpenApiClientUtil@11.0.144
#addin nuget:?package=Soenneker.Groq.OpenApiClientUtil&version=11.0.144
#tool nuget:?package=Soenneker.Groq.OpenApiClientUtil&version=11.0.144
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.107)
- Soenneker.Groq.OpenApiClient (>= 11.0.68)
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.144 | 45 | 11/23/2026 |
| 11.0.143 | 59 | 11/22/2026 |
| 11.0.142 | 62 | 11/21/2026 |
| 11.0.141 | 76 | 11/20/2026 |
| 11.0.140 | 105 | 11/19/2026 |
| 11.0.139 | 73 | 11/19/2026 |
| 11.0.138 | 69 | 11/18/2026 |
| 11.0.137 | 79 | 11/18/2026 |
| 11.0.136 | 74 | 11/18/2026 |
| 11.0.134 | 91 | 11/18/2026 |
| 11.0.133 | 97 | 11/17/2026 |
| 11.0.132 | 93 | 11/17/2026 |
| 11.0.131 | 110 | 11/16/2026 |
| 11.0.130 | 97 | 11/15/2026 |
| 11.0.129 | 90 | 11/15/2026 |
| 11.0.128 | 115 | 11/15/2026 |
| 11.0.127 | 111 | 11/14/2026 |
| 11.0.126 | 506 | 11/13/2026 |
| 11.0.125 | 146 | 11/12/2026 |
| 11.0.124 | 95 | 11/11/2026 |
Update dependency Soenneker.Groq.OpenApiClient to 11.0.68 (#119)