AssistantsClient Constructors
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
AssistantsClient() |
Initializes a new instance of AssistantsClient for mocking. |
AssistantsClient(String) |
Creates a new instance of AssistantsClient for use with OpenAI's api.openai.com endpoint. |
AssistantsClient(String, AssistantsClientOptions) |
Creates a new instance of AssistantsClient for use with OpenAI's api.openai.com endpoint. |
AssistantsClient(Uri, AzureKeyCredential) |
Creates a new instance of AssistantsClient for use with an Azure OpenAI resource. |
AssistantsClient(Uri, TokenCredential) |
Creates a new instance of AssistantsClient for use with an Azure OpenAI resource. |
AssistantsClient(Uri, AzureKeyCredential, AssistantsClientOptions) |
Creates a new instance of AssistantsClient for use with an Azure OpenAI resource. |
AssistantsClient(Uri, TokenCredential, AssistantsClientOptions) |
Creates a new instance of AssistantsClient for use with an Azure OpenAI resource. |
AssistantsClient()
- Source:
- AssistantsClient.cs
Initializes a new instance of AssistantsClient for mocking.
protected AssistantsClient ();
Protected Sub New ()
Applies to
AssistantsClient(String)
- Source:
- AssistantsClient.cs
Creates a new instance of AssistantsClient for use with OpenAI's api.openai.com endpoint.
public AssistantsClient (string openAIApiKey);
new Azure.AI.OpenAI.Assistants.AssistantsClient : string -> Azure.AI.OpenAI.Assistants.AssistantsClient
Public Sub New (openAIApiKey As String)
Parameters
- openAIApiKey
- String
An OpenAI API key as obtained from platform.openai.com.
Exceptions
openAIApiKey
is null.
Applies to
AssistantsClient(String, AssistantsClientOptions)
- Source:
- AssistantsClient.cs
Creates a new instance of AssistantsClient for use with OpenAI's api.openai.com endpoint.
public AssistantsClient (string openAIApiKey, Azure.AI.OpenAI.Assistants.AssistantsClientOptions options);
new Azure.AI.OpenAI.Assistants.AssistantsClient : string * Azure.AI.OpenAI.Assistants.AssistantsClientOptions -> Azure.AI.OpenAI.Assistants.AssistantsClient
Public Sub New (openAIApiKey As String, options As AssistantsClientOptions)
Parameters
- openAIApiKey
- String
An OpenAI API key as obtained from platform.openai.com.
- options
- AssistantsClientOptions
Additional options for customizing the behavior of the client.
Exceptions
openAIApiKey
is null.
Applies to
AssistantsClient(Uri, AzureKeyCredential)
- Source:
- AssistantsClient.cs
Creates a new instance of AssistantsClient for use with an Azure OpenAI resource.
public AssistantsClient (Uri endpoint, Azure.AzureKeyCredential keyCredential);
new Azure.AI.OpenAI.Assistants.AssistantsClient : Uri * Azure.AzureKeyCredential -> Azure.AI.OpenAI.Assistants.AssistantsClient
Public Sub New (endpoint As Uri, keyCredential As AzureKeyCredential)
Parameters
- endpoint
- Uri
An Azure OpenAI resource URL, e.g. https://my-resource.openai.azure.com.
- keyCredential
- AzureKeyCredential
The authentication information for the Azure OpenAI resource.
Exceptions
Always thrown until Azure OpenAI support for /assistants is available.
endpoint
or keyCredential
is null.
Applies to
AssistantsClient(Uri, TokenCredential)
- Source:
- AssistantsClient.cs
Creates a new instance of AssistantsClient for use with an Azure OpenAI resource.
public AssistantsClient (Uri endpoint, Azure.Core.TokenCredential tokenCredential);
new Azure.AI.OpenAI.Assistants.AssistantsClient : Uri * Azure.Core.TokenCredential -> Azure.AI.OpenAI.Assistants.AssistantsClient
Public Sub New (endpoint As Uri, tokenCredential As TokenCredential)
Parameters
- endpoint
- Uri
An Azure OpenAI resource URL, e.g. https://my-resource.openai.azure.com.
- tokenCredential
- TokenCredential
The authentication information for the Azure OpenAI resource.
Exceptions
Always thrown until Azure OpenAI support for /assistants is available.
endpoint
is null.
Applies to
AssistantsClient(Uri, AzureKeyCredential, AssistantsClientOptions)
- Source:
- AssistantsClient.cs
Creates a new instance of AssistantsClient for use with an Azure OpenAI resource.
public AssistantsClient (Uri endpoint, Azure.AzureKeyCredential keyCredential, Azure.AI.OpenAI.Assistants.AssistantsClientOptions options);
new Azure.AI.OpenAI.Assistants.AssistantsClient : Uri * Azure.AzureKeyCredential * Azure.AI.OpenAI.Assistants.AssistantsClientOptions -> Azure.AI.OpenAI.Assistants.AssistantsClient
Public Sub New (endpoint As Uri, keyCredential As AzureKeyCredential, options As AssistantsClientOptions)
Parameters
- endpoint
- Uri
An Azure OpenAI resource URL, e.g. https://my-resource.openai.azure.com.
- keyCredential
- AzureKeyCredential
The authentication information for the Azure OpenAI resource.
- options
- AssistantsClientOptions
Additional options for customizing the behavior of the client.
Exceptions
Always thrown until Azure OpenAI support for /assistants is available.
endpoint
or keyCredential
is null.
Applies to
AssistantsClient(Uri, TokenCredential, AssistantsClientOptions)
- Source:
- AssistantsClient.cs
Creates a new instance of AssistantsClient for use with an Azure OpenAI resource.
public AssistantsClient (Uri endpoint, Azure.Core.TokenCredential tokenCredential, Azure.AI.OpenAI.Assistants.AssistantsClientOptions options);
new Azure.AI.OpenAI.Assistants.AssistantsClient : Uri * Azure.Core.TokenCredential * Azure.AI.OpenAI.Assistants.AssistantsClientOptions -> Azure.AI.OpenAI.Assistants.AssistantsClient
Public Sub New (endpoint As Uri, tokenCredential As TokenCredential, options As AssistantsClientOptions)
Parameters
- endpoint
- Uri
An Azure OpenAI resource URL, e.g. https://my-resource.openai.azure.com.
- tokenCredential
- TokenCredential
The authentication information for the Azure OpenAI resource.
- options
- AssistantsClientOptions
Additional options for customizing the behavior of the client.
Exceptions
Always thrown until Azure OpenAI support for /assistants is available.
endpoint
or tokenCredential
is null.
Applies to
Azure SDK for .NET