Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,11 @@ The SDK's primary artifacts are:
- Does not have its own logic
- `openai-java-bedrock`
- Adds optional Amazon Bedrock authentication and credential-provider integration
- `openai-java-spring-boot-starter`
- Provides the legacy Spring Boot 2 integration
- Is retained to verify the final 4.45.0 release, but is OpenAI EOL and no longer published

The retired Spring Boot 2 starter is not part of the active build. Its final source remains available
in the [`v4.45.0` tag](https://github.com/openai/openai-java/tree/v4.45.0/openai-java-spring-boot-starter),
and its lifecycle history and consumer migration path are documented in the
[Spring Boot 2 EOL decision](docs/spring-boot-2-eol.md).

`openai-java-runtime-compatibility` is a non-published fixture that exercises representative
behavior for each supported artifact on an isolated runtime classpath. Its JVM matrix and each
Expand Down
74 changes: 5 additions & 69 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -1455,79 +1455,15 @@ GraalVM should automatically detect and use the published metadata, but [manual
> [!WARNING]
> `openai-java-spring-boot-starter` targets Spring Boot 2.7 and is OpenAI EOL as of 2026-07-27.
> Version 4.45.0 is the final supported, tested, and published release. The artifact remains
> downloadable but receives no fixes, testing, or compatibility support. See the
> downloadable but receives no fixes, testing, or compatibility support, and its source is no
> longer part of the active build. See the
> [Spring Boot 2 EOL decision and migration path](docs/spring-boot-2-eol.md). New Spring
> applications should depend on `openai-java` directly and provide an `OpenAIClient` bean until a
> supported, generation-specific integration is available.

Existing Spring Boot 2 applications can use the legacy starter to simplify configuration.

### Installation

#### Gradle

```kotlin
implementation("com.openai:openai-java-spring-boot-starter:4.45.0")
```

#### Maven

```xml
<dependency>
<groupId>com.openai</groupId>
<artifactId>openai-java-spring-boot-starter</artifactId>
<version>4.45.0</version>
</dependency>
```

### Configuration

The [client's environment variable options](#client-configuration) can be configured in [`application.properties` or `application.yml`](https://docs.spring.io/spring-boot/how-to/properties-and-configuration.html).

#### `application.properties`

```properties
openai.base-url=https://api.openai.com/v1
openai.api-key=My API Key
openai.admin-key=My Admin API Key
openai.org-id=My Organization
openai.project-id=My Project
openai.webhook-secret=My Webhook Secret
```

#### `application.yml`

```yaml
openai:
base-url: https://api.openai.com/v1
api-key: My API Key
admin-key: My Admin API Key
org-id: My Organization
project-id: My Project
webhook-secret: My Webhook Secret
```

#### Other configuration

Configure any other client option by providing one or more instances of [`OpenAIClientCustomizer`](openai-java-spring-boot-starter/src/main/kotlin/com/openai/springboot/OpenAIClientCustomizer.kt). For example, here's how you'd set [`maxRetries`](#retries):

```java
import com.openai.springboot.OpenAIClientCustomizer;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

@Configuration
public class OpenAIConfig {
@Bean
public OpenAIClientCustomizer customizer() {
return builder -> builder.maxRetries(3);
}
}
```

### Usage

[Inject](https://docs.spring.io/spring-framework/reference/core/beans/dependencies/factory-collaborators.html) [`OpenAIClient`](openai-java-core/src/main/kotlin/com/openai/client/OpenAIClient.kt) anywhere and start using it!
Existing Spring Boot 2 users can refer to the
[`v4.45.0` Spring Boot documentation](https://github.com/openai/openai-java/blob/v4.45.0/README.md#spring-boot)
for the final legacy configuration and usage instructions.

## Jackson

Expand Down
21 changes: 21 additions & 0 deletions docs/spring-boot-2-eol.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,27 @@ floor, or changing the same coordinate to a newer Spring generation would requir
A future supported Spring integration must use generation-specific coordinates and independently
pass the policy's 12-month admission gate.

## History and source removal

The starter was introduced in SDK 2.18.0 after
[an external request](https://github.com/openai/openai-java/issues/480) for Spring Boot
`application.properties` and `application.yml` support. It was a customer-facing convenience
artifact, not a test fixture: it bound `openai.*` configuration, created an injectable
`OpenAIClient` bean, and allowed applications to customize the client builder.

The starter's source was removed from the active build after its final release. Keeping that source
on the default branch did not verify 4.45.0: the module depended on the current checkout's
`openai-java` project and therefore compiled and tested an unpublished, changing combination of the
current SDK with Spring Boot 2.7.18. It also kept the EOL Spring dependency graph active for
repository security scanning.

Removing the active source does not withdraw the released artifact. Version 4.45.0 remains on Maven
Central, and its exact implementation and tests remain available in the
[`v4.45.0` source tag](https://github.com/openai/openai-java/tree/v4.45.0/openai-java-spring-boot-starter).
The tagged
[`v4.45.0` README](https://github.com/openai/openai-java/blob/v4.45.0/README.md#spring-boot)
preserves its final installation and configuration instructions.

## Consumer migration

Applications that cannot leave Boot 2 may pin the starter to 4.45.0, but do so without OpenAI or
Expand Down
2 changes: 1 addition & 1 deletion docs/version-support-policy.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ that apply this policy.
| Surface | Decision | Next action |
| --- | --- | --- |
| Framework-neutral artifacts | Keep Java 8 through SDK v4. | Raise the floor only in an SDK major; first prefer replacing or isolating a constraining dependency. |
| Existing Spring Boot 2 starter | OpenAI EOL as of 2026-07-27; 4.45.0 is the final supported and published release. | Follow the [Spring Boot 2 EOL decision](spring-boot-2-eol.md); publish no later versions. |
| Retired Spring Boot 2 starter | OpenAI EOL as of 2026-07-27; 4.45.0 is the final supported and published release, and its source is no longer in the active build. | Keep the final artifact and tagged source available; follow the [Spring Boot 2 EOL decision](spring-boot-2-eol.md); publish no later versions. |
| Potential Spring Boot 4 integration | Candidate Java 17 integration using a new generation-specific artifact. | Pass the admission gate and Spring ADR before implementation. |

Do not publish an OpenAI Java BOM until independently versioned artifacts or demonstrated consumer
Expand Down
2 changes: 0 additions & 2 deletions gradle/version-support.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@ artifact.openai-java-client-okhttp.runtime=8
artifact.openai-java-client-okhttp.lifecycle=active
artifact.openai-java-core.runtime=8
artifact.openai-java-core.lifecycle=active
artifact.openai-java-spring-boot-starter.runtime=8
artifact.openai-java-spring-boot-starter.lifecycle=eol
40 changes: 0 additions & 40 deletions openai-java-spring-boot-starter/build.gradle.kts

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Loading
Loading