From 21501a9a15c4b97591c9b81ef7922a70dcad08c2 Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 6 Feb 2026 14:48:07 +0000 Subject: [PATCH 1/3] codegen metadata --- .stats.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.stats.yml b/.stats.yml index 766c6aef..9d37c7df 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 136 openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/openai%2Fopenai-64c3a646eb5dcad2b7ff7bd976c0e312b886676a542f6ffcd9a6c8503ae24c58.yml openapi_spec_hash: 91b1b7bf3c1a6b6c9c7507d4cac8fe2a -config_hash: f8e6baff429cf000b8e4ba1da08dff47 +config_hash: e7976c555732f55dc92f3aa09558ef9d From edd4e7bbd6f1df190eac87daad32a55c0794ac4d Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Fri, 6 Feb 2026 20:02:06 +0000 Subject: [PATCH 2/3] feat(api): add webhook signature verification --- .../services/async/WebhookServiceAsyncTest.kt | 30 ++++++++++++++++ .../services/blocking/WebhookServiceTest.kt | 34 +++++++++++++++++++ 2 files changed, 64 insertions(+) create mode 100644 openai-java-core/src/test/kotlin/com/openai/services/async/WebhookServiceAsyncTest.kt diff --git a/openai-java-core/src/test/kotlin/com/openai/services/async/WebhookServiceAsyncTest.kt b/openai-java-core/src/test/kotlin/com/openai/services/async/WebhookServiceAsyncTest.kt new file mode 100644 index 00000000..255b0231 --- /dev/null +++ b/openai-java-core/src/test/kotlin/com/openai/services/async/WebhookServiceAsyncTest.kt @@ -0,0 +1,30 @@ +// File generated from our OpenAPI spec by Stainless. + +package com.openai.services.async + +import com.openai.TestServerExtension +import com.openai.client.okhttp.OpenAIOkHttpClientAsync +import com.openai.core.http.Headers +import org.junit.jupiter.api.Test +import org.junit.jupiter.api.extension.ExtendWith + +@ExtendWith(TestServerExtension::class) +internal class WebhookServiceAsyncTest { + + @Test + fun unwrap() { + val client = + OpenAIOkHttpClientAsync.builder() + .baseUrl(TestServerExtension.BASE_URL) + .apiKey("My API Key") + .build() + val webhookServiceAsync = client.webhooks() + + val payload = + "{\"id\":\"id\",\"created_at\":0,\"data\":{\"id\":\"id\"},\"type\":\"batch.cancelled\",\"object\":\"event\"}" + val webhookSecret = "whsec_c2VjcmV0Cg==" + val headers = Headers.builder().build() + + webhookServiceAsync.unwrap(payload).validate() + } +} diff --git a/openai-java-core/src/test/kotlin/com/openai/services/blocking/WebhookServiceTest.kt b/openai-java-core/src/test/kotlin/com/openai/services/blocking/WebhookServiceTest.kt index 3b20eba4..6938c9c3 100644 --- a/openai-java-core/src/test/kotlin/com/openai/services/blocking/WebhookServiceTest.kt +++ b/openai-java-core/src/test/kotlin/com/openai/services/blocking/WebhookServiceTest.kt @@ -1,3 +1,4 @@ +<<<<<<< HEAD // File generated from our OpenAPI spec by Stainless. package com.openai.services.blocking @@ -226,3 +227,36 @@ internal class WebhookServiceTest { } } } +||||||| parent of 8235a47f (feat(api): add webhook signature verification) +======= +// File generated from our OpenAPI spec by Stainless. + +package com.openai.services.blocking + +import com.openai.TestServerExtension +import com.openai.client.okhttp.OpenAIOkHttpClient +import com.openai.core.http.Headers +import org.junit.jupiter.api.Test +import org.junit.jupiter.api.extension.ExtendWith + +@ExtendWith(TestServerExtension::class) +internal class WebhookServiceTest { + + @Test + fun unwrap() { + val client = + OpenAIOkHttpClient.builder() + .baseUrl(TestServerExtension.BASE_URL) + .apiKey("My API Key") + .build() + val webhookService = client.webhooks() + + val payload = + "{\"id\":\"id\",\"created_at\":0,\"data\":{\"id\":\"id\"},\"type\":\"batch.cancelled\",\"object\":\"event\"}" + val webhookSecret = "whsec_c2VjcmV0Cg==" + val headers = Headers.builder().build() + + webhookService.unwrap(payload).validate() + } +} +>>>>>>> 8235a47f (feat(api): add webhook signature verification) From 9c745664b8c257b88296b02427c95bf44e64d4ca Mon Sep 17 00:00:00 2001 From: "stainless-app[bot]" <142633134+stainless-app[bot]@users.noreply.github.com> Date: Sun, 8 Feb 2026 05:31:26 +0000 Subject: [PATCH 3/3] release: 4.19.0 --- .release-please-manifest.json | 2 +- CHANGELOG.md | 8 ++++++++ README.md | 14 +++++++------- build.gradle.kts | 2 +- 4 files changed, 17 insertions(+), 9 deletions(-) diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 052d78b7..647ed9ca 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "4.18.0" + ".": "4.19.0" } \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 090330c7..e7a88911 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,13 @@ # Changelog +## 4.19.0 (2026-02-08) + +Full Changelog: [v4.18.0...v4.19.0](https://github.com/openai/openai-java/compare/v4.18.0...v4.19.0) + +### Features + +* **api:** add webhook signature verification ([edd4e7b](https://github.com/openai/openai-java/commit/edd4e7bbd6f1df190eac87daad32a55c0794ac4d)) + ## 4.18.0 (2026-02-05) Full Changelog: [v4.17.0...v4.18.0](https://github.com/openai/openai-java/compare/v4.17.0...v4.18.0) diff --git a/README.md b/README.md index be008a1e..bad6ed44 100644 --- a/README.md +++ b/README.md @@ -2,8 +2,8 @@ -[![Maven Central](https://img.shields.io/maven-central/v/com.openai/openai-java)](https://central.sonatype.com/artifact/com.openai/openai-java/4.18.0) -[![javadoc](https://javadoc.io/badge2/com.openai/openai-java/4.18.0/javadoc.svg)](https://javadoc.io/doc/com.openai/openai-java/4.18.0) +[![Maven Central](https://img.shields.io/maven-central/v/com.openai/openai-java)](https://central.sonatype.com/artifact/com.openai/openai-java/4.19.0) +[![javadoc](https://javadoc.io/badge2/com.openai/openai-java/4.19.0/javadoc.svg)](https://javadoc.io/doc/com.openai/openai-java/4.19.0) @@ -11,7 +11,7 @@ The OpenAI Java SDK provides convenient access to the [OpenAI REST API](https:// -The REST API documentation can be found on [platform.openai.com](https://platform.openai.com/docs). Javadocs are available on [javadoc.io](https://javadoc.io/doc/com.openai/openai-java/4.18.0). +The REST API documentation can be found on [platform.openai.com](https://platform.openai.com/docs). Javadocs are available on [javadoc.io](https://javadoc.io/doc/com.openai/openai-java/4.19.0). @@ -24,7 +24,7 @@ The REST API documentation can be found on [platform.openai.com](https://platfor ### Gradle ```kotlin -implementation("com.openai:openai-java:4.18.0") +implementation("com.openai:openai-java:4.19.0") ``` ### Maven @@ -33,7 +33,7 @@ implementation("com.openai:openai-java:4.18.0") com.openai openai-java - 4.18.0 + 4.19.0 ``` @@ -1342,7 +1342,7 @@ If you're using Spring Boot, then you can use the SDK's [Spring Boot starter](ht #### Gradle ```kotlin -implementation("com.openai:openai-java-spring-boot-starter:4.18.0") +implementation("com.openai:openai-java-spring-boot-starter:4.19.0") ``` #### Maven @@ -1351,7 +1351,7 @@ implementation("com.openai:openai-java-spring-boot-starter:4.18.0") com.openai openai-java-spring-boot-starter - 4.18.0 + 4.19.0 ``` diff --git a/build.gradle.kts b/build.gradle.kts index bbfa8a07..1a7dcb63 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -8,7 +8,7 @@ repositories { allprojects { group = "com.openai" - version = "4.18.0" // x-release-please-version + version = "4.19.0" // x-release-please-version } subprojects {