You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/ai-foundry/openai/api-version-lifecycle.md
+4-2Lines changed: 4 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,7 +27,7 @@ Previously, Azure OpenAI received monthly updates of new API versions. Taking ad
27
27
28
28
Starting in August 2025, you can now opt in to our next generation v1 Azure OpenAI APIs which add support for:
29
29
30
-
- Ongoing access to the latest features with no need specify new `api-version`'s each month.
30
+
- Ongoing access to the latest features with no need to specify new `api-version`'s each month.
31
31
- Faster API release cycle with new features launching more frequently.
32
32
- OpenAI client support with minimal code changes to swap between OpenAI and Azure OpenAI when using key-based authentication.
33
33
- OpenAI client support for token based authentication and automatic token refresh without the need to take a dependency on a separate Azure OpenAI client.
Unlike the Azure OpenAI client libraries for Python and JavaScript, to ensure compatibility the Azure OpenAI Java package is limited to targeting a specific subset of the Azure OpenAI API versions. Generally each Azure OpenAI Java package unlocks access to newer Azure OpenAI API release features. Having access to the latest API versions impacts feature availability.
17
+
- v1 Generally Available (GA) API now allows access to both GA and Preview operations. To learn more, see the [API version lifecycle guide](../../api-version-lifecycle.md).
18
18
19
-
Version selection is controlled by the [`OpenAIServiceVersion`](/java/api/com.azure.ai.openai.openaiserviceversion?view=azure-java-preview&preserve-view=true) enum.
20
-
21
-
The latest Azure OpenAI preview API supported is:
22
-
23
-
-`2025-01-01-preview`
24
-
25
-
The latest stable (GA) release supported is:
19
+
## Installation
26
20
27
-
-`2024-06-01`
21
+
### Gradle
28
22
29
-
## Installation
23
+
```kotlin
24
+
implementation("com.openai:openai-java:4.0.1")
25
+
```
30
26
31
-
### Package details
27
+
### Maven
32
28
33
-
```XML
29
+
```xml
34
30
<dependency>
35
-
<groupId>com.azure</groupId>
36
-
<artifactId>azure-ai-openai</artifactId>
37
-
<version>1.0.0-beta.16</version>
31
+
<groupId>com.openai</groupId>
32
+
<artifactId>openai-java</artifactId>
33
+
<version>4.0.1</version>
38
34
</dependency>
39
35
```
40
36
41
37
## Authentication
42
38
43
-
In order to interact with the Azure OpenAI in Azure AI Foundry Models you'll need to create an instance of client class, [`OpenAIAsyncClient`](https://github.com/Azure/azure-sdk-for-java/blob/azure-ai-openai_1.0.0-beta.12/sdk/openai/azure-ai-openai/src/main/java/com/azure/ai/openai/OpenAIAsyncClient.java) or [`OpenAIClient`](https://github.com/Azure/azure-sdk-for-java/blob/azure-ai-openai_1.0.0-beta.12/sdk/openai/azure-ai-openai/src/main/java/com/azure/ai/openai/OpenAIClient.java) by using [`OpenAIClientBuilder`](https://github.com/Azure/azure-sdk-for-java/blob/azure-ai-openai_1.0.0-beta.12/sdk/openai/azure-ai-openai/src/main/java/com/azure/ai/openai/OpenAIClientBuilder.java). To configure a client for use with Azure OpenAI, provide a valid endpoint URI to an Azure OpenAI resource along with a corresponding key credential, token credential, or Azure Identity credential that's authorized to use the Azure OpenAI resource.
44
-
45
39
# [Microsoft Entra ID](#tab/secure)
46
40
47
41
Authentication with Microsoft Entra ID requires some initial setup:
@@ -52,264 +46,75 @@ Add the Azure Identity package:
52
46
<dependency>
53
47
<groupId>com.azure</groupId>
54
48
<artifactId>azure-identity</artifactId>
55
-
<version>1.13.3</version>
49
+
<version>1.18.0</version>
56
50
</dependency>
57
51
```
58
52
59
53
After setup, you can choose which type of credential from `azure.identity` to use. As an example, `DefaultAzureCredential` can be used to authenticate the client: Set the values of the client ID, tenant ID, and client secret of the Microsoft Entra ID application as environment variables: AZURE_CLIENT_ID, AZURE_TENANT_ID, AZURE_CLIENT_SECRET.
60
54
61
-
Authorization is easiest using DefaultAzureCredential. It finds the best credential to use in its running environment.
55
+
Authorization is easiest using `DefaultAzureCredential`. It finds the best credential to use in its running environment though use of `DefaultAzureCredential` is only recommended for testing, not for production.
For more information about Azure OpenAI keyless authentication, see [Use Azure OpenAI without keys](/azure/developer/ai/keyless-connections?tabs=java%2Cazure-cli).
68
+
For more information about Azure OpenAI keyless authentication, see [Use Azure OpenAI without keys](/azure/developer/ai/keyless-connections?tabs=java%2Cazure-cli).
0 commit comments