diff --git a/README.md b/README.md
index 56024ea..d49dbab 100644
--- a/README.md
+++ b/README.md
@@ -58,7 +58,8 @@ builder.Services.AddChatGpt(options =>
- 2023-10-01-preview
- 2024-02-15-preview
- 2024-03-01-preview
- - 2024-04-01-preview (default)
+ - 2024-04-01-preview
+ - 2024-05-01-preview (default)
- 2024-02-01
- _AuthenticationType_: it specifies if the key is an actual API Key or an [Azure Active Directory token](https://learn.microsoft.com/azure/cognitive-services/openai/how-to/managed-identity) (optional, default: "ApiKey").
diff --git a/docs/ChatGptNet/ChatGptOptionsBuilderExtensions/UseAzure.md b/docs/ChatGptNet/ChatGptOptionsBuilderExtensions/UseAzure.md
index aacd116..cd71d01 100644
--- a/docs/ChatGptNet/ChatGptOptionsBuilderExtensions/UseAzure.md
+++ b/docs/ChatGptNet/ChatGptOptionsBuilderExtensions/UseAzure.md
@@ -4,7 +4,7 @@ Configures Azure OpenAI Service settings.
```csharp
public static ChatGptOptionsBuilder UseAzure(this ChatGptOptionsBuilder builder,
- string resourceName, string apiKey, string apiVersion = "2024-04-01-preview",
+ string resourceName, string apiKey, string apiVersion = "2024-05-01-preview",
AzureAuthenticationType authenticationType = AzureAuthenticationType.ApiKey)
```
diff --git a/samples/ChatGptApi/ChatGptApi.csproj b/samples/ChatGptApi/ChatGptApi.csproj
index 4eaec32..66b87eb 100644
--- a/samples/ChatGptApi/ChatGptApi.csproj
+++ b/samples/ChatGptApi/ChatGptApi.csproj
@@ -7,11 +7,11 @@
-
-
+
+
-
-
+
+
diff --git a/samples/ChatGptApi/appsettings.json b/samples/ChatGptApi/appsettings.json
index 3c0afcc..a652b62 100644
--- a/samples/ChatGptApi/appsettings.json
+++ b/samples/ChatGptApi/appsettings.json
@@ -4,7 +4,7 @@
"ApiKey": "", // Required
//"Organization": "", // Optional, used only by OpenAI
"ResourceName": "", // Required when using Azure OpenAI Service
- "ApiVersion": "2024-04-01-preview", // Optional, used only by Azure OpenAI Service (default: 2024-04-01-preview)
+ "ApiVersion": "2024-05-01-preview", // Optional, used only by Azure OpenAI Service (default: 2024-05-01-preview)
"AuthenticationType": "ApiKey", // Optional, used only by Azure OpenAI Service. Allowed values: ApiKey (default) or ActiveDirectory
"DefaultModel": "my-model",
diff --git a/samples/ChatGptBlazor.Wasm/ChatGptBlazor.Wasm.csproj b/samples/ChatGptBlazor.Wasm/ChatGptBlazor.Wasm.csproj
index 611c80c..0ec58e2 100644
--- a/samples/ChatGptBlazor.Wasm/ChatGptBlazor.Wasm.csproj
+++ b/samples/ChatGptBlazor.Wasm/ChatGptBlazor.Wasm.csproj
@@ -9,9 +9,9 @@
-
-
-
+
+
+
diff --git a/samples/ChatGptConsole/ChatGptConsole.csproj b/samples/ChatGptConsole/ChatGptConsole.csproj
index 7f72f3f..3453c18 100644
--- a/samples/ChatGptConsole/ChatGptConsole.csproj
+++ b/samples/ChatGptConsole/ChatGptConsole.csproj
@@ -9,7 +9,7 @@
-
+
diff --git a/samples/ChatGptConsole/appsettings.json b/samples/ChatGptConsole/appsettings.json
index 2fb4aad..8391a2b 100644
--- a/samples/ChatGptConsole/appsettings.json
+++ b/samples/ChatGptConsole/appsettings.json
@@ -4,7 +4,7 @@
"ApiKey": "", // Required
//"Organization": "", // Optional, used only by OpenAI
"ResourceName": "", // Required when using Azure OpenAI Service
- "ApiVersion": "2024-04-01-preview", // Optional, used only by Azure OpenAI Service (default: 2024-04-01-preview)
+ "ApiVersion": "2024-05-01-preview", // Optional, used only by Azure OpenAI Service (default: 2024-05-01-preview)
"AuthenticationType": "ApiKey", // Optional, used only by Azure OpenAI Service. Allowed values: ApiKey (default) or ActiveDirectory
"DefaultModel": "my-model",
diff --git a/samples/ChatGptFunctionCallingConsole/ChatGptFunctionCallingConsole.csproj b/samples/ChatGptFunctionCallingConsole/ChatGptFunctionCallingConsole.csproj
index 205ffd8..833960e 100644
--- a/samples/ChatGptFunctionCallingConsole/ChatGptFunctionCallingConsole.csproj
+++ b/samples/ChatGptFunctionCallingConsole/ChatGptFunctionCallingConsole.csproj
@@ -9,7 +9,7 @@
-
+
diff --git a/samples/ChatGptFunctionCallingConsole/appsettings.json b/samples/ChatGptFunctionCallingConsole/appsettings.json
index 37d9b84..5b3db33 100644
--- a/samples/ChatGptFunctionCallingConsole/appsettings.json
+++ b/samples/ChatGptFunctionCallingConsole/appsettings.json
@@ -4,7 +4,7 @@
"ApiKey": "", // Required
//"Organization": "", // Optional, used only by OpenAI
"ResourceName": "", // Required when using Azure OpenAI Service
- "ApiVersion": "2024-04-01-preview", // Optional, used only by Azure OpenAI Service (default: 2024-04-01-preview)
+ "ApiVersion": "2024-05-01-preview", // Optional, used only by Azure OpenAI Service (default: 2024-05-01-preview)
"AuthenticationType": "ApiKey", // Optional, used only by Azure OpenAI Service. Allowed values: ApiKey (default) or ActiveDirectory
"DefaultModel": "my-model",
diff --git a/samples/ChatGptStreamConsole/ChatGptStreamConsole.csproj b/samples/ChatGptStreamConsole/ChatGptStreamConsole.csproj
index 66be1c8..dc946e0 100644
--- a/samples/ChatGptStreamConsole/ChatGptStreamConsole.csproj
+++ b/samples/ChatGptStreamConsole/ChatGptStreamConsole.csproj
@@ -9,7 +9,7 @@
-
+
diff --git a/samples/ChatGptStreamConsole/appsettings.json b/samples/ChatGptStreamConsole/appsettings.json
index 0ac1de6..f0a0095 100644
--- a/samples/ChatGptStreamConsole/appsettings.json
+++ b/samples/ChatGptStreamConsole/appsettings.json
@@ -4,7 +4,7 @@
"ApiKey": "", // Required
//"Organization": "", // Optional, used only by OpenAI
"ResourceName": "", // Required when using Azure OpenAI Service
- "ApiVersion": "2024-04-01-preview", // Optional, used only by Azure OpenAI Service (default: 2024-04-01-preview)
+ "ApiVersion": "2024-05-01-preview", // Optional, used only by Azure OpenAI Service (default: 2024-05-01-preview)
"AuthenticationType": "ApiKey", // Optional, used only by Azure OpenAI Service. Allowed values: ApiKey (default) or ActiveDirectory
"DefaultModel": "my-model",
diff --git a/src/ChatGptNet/ServiceConfigurations/AzureChatGptServiceConfiguration.cs b/src/ChatGptNet/ServiceConfigurations/AzureChatGptServiceConfiguration.cs
index 4202003..3385199 100644
--- a/src/ChatGptNet/ServiceConfigurations/AzureChatGptServiceConfiguration.cs
+++ b/src/ChatGptNet/ServiceConfigurations/AzureChatGptServiceConfiguration.cs
@@ -10,7 +10,7 @@ internal class AzureChatGptServiceConfiguration : ChatGptServiceConfiguration
///
/// The default API version for Azure OpenAI service.
///
- public const string DefaultApiVersion = "2024-04-01-preview";
+ public const string DefaultApiVersion = "2024-05-01-preview";
///
/// Gets or sets the name of the Azure OpenAI Resource.
@@ -18,7 +18,7 @@ internal class AzureChatGptServiceConfiguration : ChatGptServiceConfiguration
public string? ResourceName { get; set; }
///
- /// Gets or sets the API version of the Azure OpenAI service (Default: 2024-04-01-preview).
+ /// Gets or sets the API version of the Azure OpenAI service (Default: 2024-05-01-preview).
///
///
/// Currently supported versions are:
@@ -48,6 +48,10 @@ internal class AzureChatGptServiceConfiguration : ChatGptServiceConfiguration
/// Swagger spec
///
/// -
+ /// 2024-05-01-preview
+ /// Swagger spec
+ ///
+ /// -
/// 2023-02-01
/// Swagger spec
///
diff --git a/src/Directory.Build.props b/src/Directory.Build.props
index b928dd5..603e0ed 100644
--- a/src/Directory.Build.props
+++ b/src/Directory.Build.props
@@ -9,7 +9,7 @@
-
+