ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.396.6

This commit is contained in:
speakeasybot
2024-09-13 00:25:35 +00:00
parent f83d7949e1
commit 5585a18ab9
652 changed files with 34020 additions and 4554 deletions

View File

@@ -5,8 +5,15 @@
package dev.plexapi.sdk;
import com.fasterxml.jackson.core.type.TypeReference;
import dev.plexapi.sdk.models.errors.GetSessionHistoryBadRequest;
import dev.plexapi.sdk.models.errors.GetSessionHistoryUnauthorized;
import dev.plexapi.sdk.models.errors.GetSessionsBadRequest;
import dev.plexapi.sdk.models.errors.GetSessionsUnauthorized;
import dev.plexapi.sdk.models.errors.GetTranscodeSessionsBadRequest;
import dev.plexapi.sdk.models.errors.GetTranscodeSessionsUnauthorized;
import dev.plexapi.sdk.models.errors.SDKError;
import dev.plexapi.sdk.models.errors.StopTranscodeSessionResponseBody;
import dev.plexapi.sdk.models.errors.StopTranscodeSessionBadRequest;
import dev.plexapi.sdk.models.errors.StopTranscodeSessionUnauthorized;
import dev.plexapi.sdk.models.operations.GetSessionHistoryRequest;
import dev.plexapi.sdk.models.operations.GetSessionHistoryRequestBuilder;
import dev.plexapi.sdk.models.operations.GetSessionHistoryResponse;
@@ -152,19 +159,11 @@ public class Sessions implements
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "400", "4XX", "5XX")) {
// no content
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"API error occurred",
Utils.extractByteArrayFromBody(_httpRes));
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "401")) {
if (Utils.statusCodeMatches(_httpRes.statusCode(), "400")) {
if (Utils.contentTypeMatches(_contentType, "application/json")) {
dev.plexapi.sdk.models.errors.GetSessionsResponseBody _out = Utils.mapper().readValue(
GetSessionsBadRequest _out = Utils.mapper().readValue(
Utils.toUtf8AndClose(_httpRes.body()),
new TypeReference<dev.plexapi.sdk.models.errors.GetSessionsResponseBody>() {});
new TypeReference<GetSessionsBadRequest>() {});
_out.withRawResponse(Optional.ofNullable(_httpRes));
throw _out;
@@ -176,6 +175,30 @@ public class Sessions implements
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "401")) {
if (Utils.contentTypeMatches(_contentType, "application/json")) {
GetSessionsUnauthorized _out = Utils.mapper().readValue(
Utils.toUtf8AndClose(_httpRes.body()),
new TypeReference<GetSessionsUnauthorized>() {});
_out.withRawResponse(Optional.ofNullable(_httpRes));
throw _out;
} else {
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"Unexpected content-type received: " + _contentType,
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "4XX", "5XX")) {
// no content
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"API error occurred",
Utils.extractByteArrayFromBody(_httpRes));
}
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
@@ -320,19 +343,11 @@ public class Sessions implements
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "400", "4XX", "5XX")) {
// no content
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"API error occurred",
Utils.extractByteArrayFromBody(_httpRes));
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "401")) {
if (Utils.statusCodeMatches(_httpRes.statusCode(), "400")) {
if (Utils.contentTypeMatches(_contentType, "application/json")) {
dev.plexapi.sdk.models.errors.GetSessionHistoryResponseBody _out = Utils.mapper().readValue(
GetSessionHistoryBadRequest _out = Utils.mapper().readValue(
Utils.toUtf8AndClose(_httpRes.body()),
new TypeReference<dev.plexapi.sdk.models.errors.GetSessionHistoryResponseBody>() {});
new TypeReference<GetSessionHistoryBadRequest>() {});
_out.withRawResponse(Optional.ofNullable(_httpRes));
throw _out;
@@ -344,6 +359,30 @@ public class Sessions implements
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "401")) {
if (Utils.contentTypeMatches(_contentType, "application/json")) {
GetSessionHistoryUnauthorized _out = Utils.mapper().readValue(
Utils.toUtf8AndClose(_httpRes.body()),
new TypeReference<GetSessionHistoryUnauthorized>() {});
_out.withRawResponse(Optional.ofNullable(_httpRes));
throw _out;
} else {
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"Unexpected content-type received: " + _contentType,
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "4XX", "5XX")) {
// no content
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"API error occurred",
Utils.extractByteArrayFromBody(_httpRes));
}
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
@@ -451,19 +490,11 @@ public class Sessions implements
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "400", "4XX", "5XX")) {
// no content
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"API error occurred",
Utils.extractByteArrayFromBody(_httpRes));
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "401")) {
if (Utils.statusCodeMatches(_httpRes.statusCode(), "400")) {
if (Utils.contentTypeMatches(_contentType, "application/json")) {
dev.plexapi.sdk.models.errors.GetTranscodeSessionsResponseBody _out = Utils.mapper().readValue(
GetTranscodeSessionsBadRequest _out = Utils.mapper().readValue(
Utils.toUtf8AndClose(_httpRes.body()),
new TypeReference<dev.plexapi.sdk.models.errors.GetTranscodeSessionsResponseBody>() {});
new TypeReference<GetTranscodeSessionsBadRequest>() {});
_out.withRawResponse(Optional.ofNullable(_httpRes));
throw _out;
@@ -475,6 +506,30 @@ public class Sessions implements
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "401")) {
if (Utils.contentTypeMatches(_contentType, "application/json")) {
GetTranscodeSessionsUnauthorized _out = Utils.mapper().readValue(
Utils.toUtf8AndClose(_httpRes.body()),
new TypeReference<GetTranscodeSessionsUnauthorized>() {});
_out.withRawResponse(Optional.ofNullable(_httpRes));
throw _out;
} else {
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"Unexpected content-type received: " + _contentType,
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "4XX", "5XX")) {
// no content
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"API error occurred",
Utils.extractByteArrayFromBody(_httpRes));
}
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
@@ -581,19 +636,11 @@ public class Sessions implements
// no content
return _res;
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "400", "4XX", "5XX")) {
// no content
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"API error occurred",
Utils.extractByteArrayFromBody(_httpRes));
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "401")) {
if (Utils.statusCodeMatches(_httpRes.statusCode(), "400")) {
if (Utils.contentTypeMatches(_contentType, "application/json")) {
StopTranscodeSessionResponseBody _out = Utils.mapper().readValue(
StopTranscodeSessionBadRequest _out = Utils.mapper().readValue(
Utils.toUtf8AndClose(_httpRes.body()),
new TypeReference<StopTranscodeSessionResponseBody>() {});
new TypeReference<StopTranscodeSessionBadRequest>() {});
_out.withRawResponse(Optional.ofNullable(_httpRes));
throw _out;
@@ -605,6 +652,30 @@ public class Sessions implements
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "401")) {
if (Utils.contentTypeMatches(_contentType, "application/json")) {
StopTranscodeSessionUnauthorized _out = Utils.mapper().readValue(
Utils.toUtf8AndClose(_httpRes.body()),
new TypeReference<StopTranscodeSessionUnauthorized>() {});
_out.withRawResponse(Optional.ofNullable(_httpRes));
throw _out;
} else {
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"Unexpected content-type received: " + _contentType,
Utils.extractByteArrayFromBody(_httpRes));
}
}
if (Utils.statusCodeMatches(_httpRes.statusCode(), "4XX", "5XX")) {
// no content
throw new SDKError(
_httpRes,
_httpRes.statusCode(),
"API error occurred",
Utils.extractByteArrayFromBody(_httpRes));
}
throw new SDKError(
_httpRes,
_httpRes.statusCode(),