Skip to content
This repository was archived by the owner on Dec 25, 2024. It is now read-only.

Commit 77adb1e

Browse files
authored
Java client, adds responses class + deserializer (#394)
* Removes module-info * Adds responses class with emprt deserialize implmentation * Adds sealed classes for status code and wildcard response deserializers * Adds partial deserialize implementation * Handles returning responses when there is no error * Adds typed response throwing * Adds handling of wildcard responses only * Imrpoves response deserialization handling, adds needed imports, removes unused import * Makes response exceptions sttic * Adds shouldGenerateFile method to all generators * Follows response refs when checking if a response has a body * Adds exception throwing when there is a single response * Generates defaultResponse in responses class * Deserializes default only response * Adds handling of responses default + status and default + wildcard * Samples regenerated * Fixes python files in petstore * Sample regen
1 parent c981617 commit 77adb1e

File tree

203 files changed

+5474
-124
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

203 files changed

+5474
-124
lines changed

samples/client/3_0_3_unit_test/java/.openapi-generator/FILES

+3-1
Original file line numberDiff line numberDiff line change
@@ -179,6 +179,7 @@ src/main/java/org/openapijsonschematools/client/components/schemas/UriTemplateFo
179179
src/main/java/org/openapijsonschematools/client/configurations/ApiConfiguration.java
180180
src/main/java/org/openapijsonschematools/client/configurations/JsonSchemaKeywordFlags.java
181181
src/main/java/org/openapijsonschematools/client/configurations/SchemaConfiguration.java
182+
src/main/java/org/openapijsonschematools/client/exceptions/ApiException.java
182183
src/main/java/org/openapijsonschematools/client/exceptions/BaseException.java
183184
src/main/java/org/openapijsonschematools/client/exceptions/InvalidAdditionalPropertyException.java
184185
src/main/java/org/openapijsonschematools/client/exceptions/InvalidTypeException.java
@@ -191,8 +192,9 @@ src/main/java/org/openapijsonschematools/client/requestbody/GenericRequestBody.j
191192
src/main/java/org/openapijsonschematools/client/requestbody/RequestBodySerializer.java
192193
src/main/java/org/openapijsonschematools/client/requestbody/SerializedRequestBody.java
193194
src/main/java/org/openapijsonschematools/client/response/ApiResponse.java
194-
src/main/java/org/openapijsonschematools/client/response/DeserializedApiResponse.java
195+
src/main/java/org/openapijsonschematools/client/response/DeserializedHttpResponse.java
195196
src/main/java/org/openapijsonschematools/client/response/ResponseDeserializer.java
197+
src/main/java/org/openapijsonschematools/client/response/ResponsesDeserializer.java
196198
src/main/java/org/openapijsonschematools/client/schemas/AnyTypeJsonSchema.java
197199
src/main/java/org/openapijsonschematools/client/schemas/BooleanJsonSchema.java
198200
src/main/java/org/openapijsonschematools/client/schemas/DateJsonSchema.java
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
package org.openapijsonschematools.client.exceptions;
2+
3+
import java.net.http.HttpResponse;
4+
5+
@SuppressWarnings("serial")
6+
public class ApiException extends BaseException {
7+
public HttpResponse<byte[]> response;
8+
9+
public ApiException(String s, HttpResponse<byte[]> response) {
10+
super(s);
11+
this.response = response;
12+
}
13+
}

samples/client/3_0_3_unit_test/java/src/main/java/org/openapijsonschematools/client/exceptions/BaseException.java

+3
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,7 @@
22

33
@SuppressWarnings("serial")
44
public class BaseException extends RuntimeException {
5+
public BaseException(String s) {
6+
super(s);
7+
}
58
}

samples/client/3_0_3_unit_test/java/src/main/java/org/openapijsonschematools/client/exceptions/InvalidAdditionalPropertyException.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
@SuppressWarnings("serial")
44
public class InvalidAdditionalPropertyException extends BaseException {
55
public InvalidAdditionalPropertyException(String s) {
6-
super();
6+
super(s);
77
}
88
}

samples/client/3_0_3_unit_test/java/src/main/java/org/openapijsonschematools/client/exceptions/InvalidTypeException.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
@SuppressWarnings("serial")
44
public class InvalidTypeException extends BaseException {
55
public InvalidTypeException(String s) {
6-
super();
6+
super(s);
77
}
88
}

samples/client/3_0_3_unit_test/java/src/main/java/org/openapijsonschematools/client/exceptions/UnsetPropertyException.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
@SuppressWarnings("serial")
44
public class UnsetPropertyException extends BaseException {
55
public UnsetPropertyException(String s) {
6-
super();
6+
super(s);
77
}
88
}

samples/client/3_0_3_unit_test/java/src/main/java/org/openapijsonschematools/client/exceptions/ValidationException.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
@SuppressWarnings("serial")
44
public class ValidationException extends BaseException {
55
public ValidationException(String s) {
6-
super();
6+
super(s);
77
}
88
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
package org.openapijsonschematools.client.response;
2+
3+
import java.net.http.HttpResponse;
4+
5+
public record DeserializedHttpResponse<SealedBodyOutputClass, HeaderOutputClass>(SealedBodyOutputClass body, HeaderOutputClass headers) {
6+
}

samples/client/3_0_3_unit_test/java/src/main/java/org/openapijsonschematools/client/response/ResponseDeserializer.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ protected <T> T deserializeBody(String contentType, byte[] body, JsonSchema<T> s
6363
throw new RuntimeException("Deserialization for contentType="+contentType+" has not yet been implemented.");
6464
}
6565

66-
public ApiResponse<SealedBodyClass, HeaderClass> deserialize(HttpResponse<byte[]> response, SchemaConfiguration configuration) {
66+
public DeserializedHttpResponse<SealedBodyClass, HeaderClass> deserialize(HttpResponse<byte[]> response, SchemaConfiguration configuration) {
6767
Optional<String> contentTypeInfo = response.headers().firstValue("Content-Type");
6868
if (contentTypeInfo.isEmpty()) {
6969
throw new RuntimeException("Invalid response returned, Content-Type header is missing and it must be included");
@@ -78,6 +78,6 @@ public ApiResponse<SealedBodyClass, HeaderClass> deserialize(HttpResponse<byte[]
7878
byte[] bodyBytes = response.body();
7979
SealedBodyClass body = getBody(contentType, bodyBytes, configuration);
8080
HeaderClass headers = getHeaders(response.headers());
81-
return new DeserializedApiResponse<>(response, body, headers);
81+
return new DeserializedHttpResponse<>(body, headers);
8282
}
8383
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
package org.openapijsonschematools.client.response;
2+
3+
import org.openapijsonschematools.client.configurations.SchemaConfiguration;
4+
import java.net.http.HttpResponse;
5+
6+
public interface ResponsesDeserializer<SealedResponseClass> {
7+
SealedResponseClass deserialize(HttpResponse<byte[]> response, SchemaConfiguration configuration);
8+
}

samples/client/3_0_3_unit_test/java/src/test/java/org/openapijsonschematools/client/response/ResponseDeserializerTest.java

+6-12
Original file line numberDiff line numberDiff line change
@@ -157,8 +157,7 @@ public void testDeserializeApplicationJsonNull() {
157157
byte[] bodyBytes = toJson(null).getBytes(StandardCharsets.UTF_8);
158158
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
159159
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
160-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
161-
Assert.assertEquals(response, apiResponse.response());
160+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
162161
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
163162
throw new RuntimeException("body must be type ApplicationjsonBody");
164163
}
@@ -174,8 +173,7 @@ public void testDeserializeApplicationJsonTrue() {
174173
byte[] bodyBytes = toJson(true).getBytes(StandardCharsets.UTF_8);
175174
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
176175
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
177-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
178-
Assert.assertEquals(response, apiResponse.response());
176+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
179177
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
180178
throw new RuntimeException("body must be type ApplicationjsonBody");
181179
}
@@ -191,8 +189,7 @@ public void testDeserializeApplicationJsonFalse() {
191189
byte[] bodyBytes = toJson(false).getBytes(StandardCharsets.UTF_8);
192190
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
193191
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
194-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
195-
Assert.assertEquals(response, apiResponse.response());
192+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
196193
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
197194
throw new RuntimeException("body must be type ApplicationjsonBody");
198195
}
@@ -208,8 +205,7 @@ public void testDeserializeApplicationJsonInt() {
208205
byte[] bodyBytes = toJson(1).getBytes(StandardCharsets.UTF_8);
209206
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
210207
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
211-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
212-
Assert.assertEquals(response, apiResponse.response());
208+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
213209
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
214210
throw new RuntimeException("body must be type ApplicationjsonBody");
215211
}
@@ -225,8 +221,7 @@ public void testDeserializeApplicationJsonFloat() {
225221
byte[] bodyBytes = toJson(3.14).getBytes(StandardCharsets.UTF_8);
226222
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
227223
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
228-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
229-
Assert.assertEquals(response, apiResponse.response());
224+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
230225
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
231226
throw new RuntimeException("body must be type ApplicationjsonBody");
232227
}
@@ -242,8 +237,7 @@ public void testDeserializeApplicationJsonString() {
242237
byte[] bodyBytes = toJson("a").getBytes(StandardCharsets.UTF_8);
243238
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
244239
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
245-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
246-
Assert.assertEquals(response, apiResponse.response());
240+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
247241
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
248242
throw new RuntimeException("body must be type ApplicationjsonBody");
249243
}

samples/client/3_1_0_unit_test/java/.openapi-generator/FILES

+3-1
Original file line numberDiff line numberDiff line change
@@ -291,6 +291,7 @@ src/main/java/org/openapijsonschematools/client/components/schemas/ValidateAgain
291291
src/main/java/org/openapijsonschematools/client/configurations/ApiConfiguration.java
292292
src/main/java/org/openapijsonschematools/client/configurations/JsonSchemaKeywordFlags.java
293293
src/main/java/org/openapijsonschematools/client/configurations/SchemaConfiguration.java
294+
src/main/java/org/openapijsonschematools/client/exceptions/ApiException.java
294295
src/main/java/org/openapijsonschematools/client/exceptions/BaseException.java
295296
src/main/java/org/openapijsonschematools/client/exceptions/InvalidAdditionalPropertyException.java
296297
src/main/java/org/openapijsonschematools/client/exceptions/InvalidTypeException.java
@@ -303,8 +304,9 @@ src/main/java/org/openapijsonschematools/client/requestbody/GenericRequestBody.j
303304
src/main/java/org/openapijsonschematools/client/requestbody/RequestBodySerializer.java
304305
src/main/java/org/openapijsonschematools/client/requestbody/SerializedRequestBody.java
305306
src/main/java/org/openapijsonschematools/client/response/ApiResponse.java
306-
src/main/java/org/openapijsonschematools/client/response/DeserializedApiResponse.java
307+
src/main/java/org/openapijsonschematools/client/response/DeserializedHttpResponse.java
307308
src/main/java/org/openapijsonschematools/client/response/ResponseDeserializer.java
309+
src/main/java/org/openapijsonschematools/client/response/ResponsesDeserializer.java
308310
src/main/java/org/openapijsonschematools/client/schemas/AnyTypeJsonSchema.java
309311
src/main/java/org/openapijsonschematools/client/schemas/BooleanJsonSchema.java
310312
src/main/java/org/openapijsonschematools/client/schemas/DateJsonSchema.java
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
package org.openapijsonschematools.client.exceptions;
2+
3+
import java.net.http.HttpResponse;
4+
5+
@SuppressWarnings("serial")
6+
public class ApiException extends BaseException {
7+
public HttpResponse<byte[]> response;
8+
9+
public ApiException(String s, HttpResponse<byte[]> response) {
10+
super(s);
11+
this.response = response;
12+
}
13+
}

samples/client/3_1_0_unit_test/java/src/main/java/org/openapijsonschematools/client/exceptions/BaseException.java

+3
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,7 @@
22

33
@SuppressWarnings("serial")
44
public class BaseException extends RuntimeException {
5+
public BaseException(String s) {
6+
super(s);
7+
}
58
}

samples/client/3_1_0_unit_test/java/src/main/java/org/openapijsonschematools/client/exceptions/InvalidAdditionalPropertyException.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
@SuppressWarnings("serial")
44
public class InvalidAdditionalPropertyException extends BaseException {
55
public InvalidAdditionalPropertyException(String s) {
6-
super();
6+
super(s);
77
}
88
}

samples/client/3_1_0_unit_test/java/src/main/java/org/openapijsonschematools/client/exceptions/InvalidTypeException.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
@SuppressWarnings("serial")
44
public class InvalidTypeException extends BaseException {
55
public InvalidTypeException(String s) {
6-
super();
6+
super(s);
77
}
88
}

samples/client/3_1_0_unit_test/java/src/main/java/org/openapijsonschematools/client/exceptions/UnsetPropertyException.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
@SuppressWarnings("serial")
44
public class UnsetPropertyException extends BaseException {
55
public UnsetPropertyException(String s) {
6-
super();
6+
super(s);
77
}
88
}

samples/client/3_1_0_unit_test/java/src/main/java/org/openapijsonschematools/client/exceptions/ValidationException.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
@SuppressWarnings("serial")
44
public class ValidationException extends BaseException {
55
public ValidationException(String s) {
6-
super();
6+
super(s);
77
}
88
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
package org.openapijsonschematools.client.response;
2+
3+
import java.net.http.HttpResponse;
4+
5+
public record DeserializedHttpResponse<SealedBodyOutputClass, HeaderOutputClass>(SealedBodyOutputClass body, HeaderOutputClass headers) {
6+
}

samples/client/3_1_0_unit_test/java/src/main/java/org/openapijsonschematools/client/response/ResponseDeserializer.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ protected <T> T deserializeBody(String contentType, byte[] body, JsonSchema<T> s
6363
throw new RuntimeException("Deserialization for contentType="+contentType+" has not yet been implemented.");
6464
}
6565

66-
public ApiResponse<SealedBodyClass, HeaderClass> deserialize(HttpResponse<byte[]> response, SchemaConfiguration configuration) {
66+
public DeserializedHttpResponse<SealedBodyClass, HeaderClass> deserialize(HttpResponse<byte[]> response, SchemaConfiguration configuration) {
6767
Optional<String> contentTypeInfo = response.headers().firstValue("Content-Type");
6868
if (contentTypeInfo.isEmpty()) {
6969
throw new RuntimeException("Invalid response returned, Content-Type header is missing and it must be included");
@@ -78,6 +78,6 @@ public ApiResponse<SealedBodyClass, HeaderClass> deserialize(HttpResponse<byte[]
7878
byte[] bodyBytes = response.body();
7979
SealedBodyClass body = getBody(contentType, bodyBytes, configuration);
8080
HeaderClass headers = getHeaders(response.headers());
81-
return new DeserializedApiResponse<>(response, body, headers);
81+
return new DeserializedHttpResponse<>(body, headers);
8282
}
8383
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
package org.openapijsonschematools.client.response;
2+
3+
import org.openapijsonschematools.client.configurations.SchemaConfiguration;
4+
import java.net.http.HttpResponse;
5+
6+
public interface ResponsesDeserializer<SealedResponseClass> {
7+
SealedResponseClass deserialize(HttpResponse<byte[]> response, SchemaConfiguration configuration);
8+
}

samples/client/3_1_0_unit_test/java/src/test/java/org/openapijsonschematools/client/response/ResponseDeserializerTest.java

+6-12
Original file line numberDiff line numberDiff line change
@@ -157,8 +157,7 @@ public void testDeserializeApplicationJsonNull() {
157157
byte[] bodyBytes = toJson(null).getBytes(StandardCharsets.UTF_8);
158158
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
159159
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
160-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
161-
Assert.assertEquals(response, apiResponse.response());
160+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
162161
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
163162
throw new RuntimeException("body must be type ApplicationjsonBody");
164163
}
@@ -174,8 +173,7 @@ public void testDeserializeApplicationJsonTrue() {
174173
byte[] bodyBytes = toJson(true).getBytes(StandardCharsets.UTF_8);
175174
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
176175
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
177-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
178-
Assert.assertEquals(response, apiResponse.response());
176+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
179177
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
180178
throw new RuntimeException("body must be type ApplicationjsonBody");
181179
}
@@ -191,8 +189,7 @@ public void testDeserializeApplicationJsonFalse() {
191189
byte[] bodyBytes = toJson(false).getBytes(StandardCharsets.UTF_8);
192190
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
193191
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
194-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
195-
Assert.assertEquals(response, apiResponse.response());
192+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
196193
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
197194
throw new RuntimeException("body must be type ApplicationjsonBody");
198195
}
@@ -208,8 +205,7 @@ public void testDeserializeApplicationJsonInt() {
208205
byte[] bodyBytes = toJson(1).getBytes(StandardCharsets.UTF_8);
209206
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
210207
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
211-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
212-
Assert.assertEquals(response, apiResponse.response());
208+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
213209
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
214210
throw new RuntimeException("body must be type ApplicationjsonBody");
215211
}
@@ -225,8 +221,7 @@ public void testDeserializeApplicationJsonFloat() {
225221
byte[] bodyBytes = toJson(3.14).getBytes(StandardCharsets.UTF_8);
226222
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
227223
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
228-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
229-
Assert.assertEquals(response, apiResponse.response());
224+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
230225
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
231226
throw new RuntimeException("body must be type ApplicationjsonBody");
232227
}
@@ -242,8 +237,7 @@ public void testDeserializeApplicationJsonString() {
242237
byte[] bodyBytes = toJson("a").getBytes(StandardCharsets.UTF_8);
243238
BytesHttpResponse response = new BytesHttpResponse(bodyBytes, "application/json");
244239
SchemaConfiguration configuration = new SchemaConfiguration(JsonSchemaKeywordFlags.ofNone());
245-
ApiResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
246-
Assert.assertEquals(response, apiResponse.response());
240+
DeserializedHttpResponse<SealedResponseBody, Void> apiResponse = deserializer.deserialize(response, configuration);
247241
if (!(apiResponse.body() instanceof ApplicationjsonBody jsonBody)) {
248242
throw new RuntimeException("body must be type ApplicationjsonBody");
249243
}

0 commit comments

Comments
 (0)