Skip to content
Docs Try Aspire

AspireAzureOpenAIClientBuilder Constructors

Class Constructors 1 member
A builder for configuring an OpenAI.AzureOpenAIClient service registration. Constructs a new instance of AspireAzureOpenAIClientBuilder.
Constructor(IHostApplicationBuilder, string, string?, bool, bool) Section titled Constructor(IHostApplicationBuilder, string, string?, bool, bool)
A builder for configuring an OpenAI.AzureOpenAIClient service registration. Constructs a new instance of AspireAzureOpenAIClientBuilder.
public class AspireAzureOpenAIClientBuilder
{
public AspireAzureOpenAIClientBuilder(
IHostApplicationBuilder hostBuilder,
string connectionName,
string? serviceKey,
bool disableTracing,
bool enableSensitiveTelemetryData)
{
// ...
}
}
hostBuilder IHostApplicationBuilder The Hosting.IHostApplicationBuilder with which services are being registered.
connectionName string The name used to retrieve the connection string from the ConnectionStrings configuration section.
serviceKey string? The service key used to register the OpenAI.AzureOpenAIClient service, if any.
disableTracing bool A flag to indicate whether tracing should be disabled.
enableSensitiveTelemetryData bool A flag indicating whether potentially sensitive information should be included in telemetry.