mirror of
https://github.com/LukeHagar/plexjava.git
synced 2025-12-06 20:47:45 +00:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
fa542f04e1 | ||
|
|
64bc159be2 |
@@ -1,23 +1,23 @@
|
||||
lockVersion: 2.0.0
|
||||
id: 1732900d-e173-47c1-a90d-d45182eb35d9
|
||||
management:
|
||||
docChecksum: 9f62ea35c6168986c8e3557d5df50b99
|
||||
docChecksum: f12b653820ae77ca3b2820bc9459d866
|
||||
docVersion: 0.0.3
|
||||
speakeasyVersion: 1.404.5
|
||||
generationVersion: 2.426.2
|
||||
releaseVersion: 0.6.1
|
||||
configChecksum: e9f20ce216bd3a2498c0708299b08208
|
||||
speakeasyVersion: 1.405.6
|
||||
generationVersion: 2.428.1
|
||||
releaseVersion: 0.7.0
|
||||
configChecksum: 778e40a6f6ea35580b5da4c033f0b08f
|
||||
repoURL: https://github.com/LukeHagar/plexjava.git
|
||||
published: true
|
||||
features:
|
||||
java:
|
||||
additionalDependencies: 0.1.0
|
||||
constsAndDefaults: 0.1.1
|
||||
core: 3.30.3
|
||||
core: 3.30.4
|
||||
deprecations: 2.81.1
|
||||
downloadStreams: 0.1.1
|
||||
enums: 2.81.2
|
||||
errors: 0.1.3
|
||||
errors: 0.1.4
|
||||
flattening: 2.81.1
|
||||
globalSecurity: 2.82.7
|
||||
globalSecurityCallbacks: 0.1.0
|
||||
@@ -28,7 +28,6 @@ features:
|
||||
nameOverrides: 2.81.3
|
||||
nullables: 0.1.0
|
||||
sdkHooks: 0.1.0
|
||||
tests: 0.1.0
|
||||
generatedFiles:
|
||||
- .gitattributes
|
||||
- CONTRIBUTING.md
|
||||
@@ -1714,22 +1713,6 @@ generatedFiles:
|
||||
- src/main/java/dev/plexapi/sdk/utils/TypedObject.java
|
||||
- src/main/java/dev/plexapi/sdk/utils/Types.java
|
||||
- src/main/java/dev/plexapi/sdk/utils/Utils.java
|
||||
- src/test/java/dev/plexapi/sdk/ActivitiesTests.java
|
||||
- src/test/java/dev/plexapi/sdk/AuthenticationTests.java
|
||||
- src/test/java/dev/plexapi/sdk/ButlerTests.java
|
||||
- src/test/java/dev/plexapi/sdk/HubsTests.java
|
||||
- src/test/java/dev/plexapi/sdk/LibraryTests.java
|
||||
- src/test/java/dev/plexapi/sdk/LogTests.java
|
||||
- src/test/java/dev/plexapi/sdk/MediaTests.java
|
||||
- src/test/java/dev/plexapi/sdk/PlaylistsTests.java
|
||||
- src/test/java/dev/plexapi/sdk/PlexTests.java
|
||||
- src/test/java/dev/plexapi/sdk/SearchTests.java
|
||||
- src/test/java/dev/plexapi/sdk/ServerTests.java
|
||||
- src/test/java/dev/plexapi/sdk/SessionsTests.java
|
||||
- src/test/java/dev/plexapi/sdk/StatisticsTests.java
|
||||
- src/test/java/dev/plexapi/sdk/UpdaterTests.java
|
||||
- src/test/java/dev/plexapi/sdk/VideoTests.java
|
||||
- src/test/java/dev/plexapi/sdk/WatchlistTests.java
|
||||
examples:
|
||||
getServerCapabilities:
|
||||
speakeasy-default-get-server-capabilities:
|
||||
@@ -2034,6 +2017,7 @@ examples:
|
||||
includeHttps: 1
|
||||
includeRelay: 1
|
||||
includeIPv6: 1
|
||||
X-Plex-Client-Identifier: "gcgzw5rz2xovp84b4vha3a40"
|
||||
responses:
|
||||
"401":
|
||||
application/json: {"errors": []}
|
||||
|
||||
@@ -12,7 +12,7 @@ generation:
|
||||
auth:
|
||||
oAuth2ClientCredentialsEnabled: true
|
||||
java:
|
||||
version: 0.6.1
|
||||
version: 0.7.0
|
||||
additionalDependencies: []
|
||||
additionalPlugins: []
|
||||
artifactID: plexapi
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
speakeasyVersion: 1.404.5
|
||||
speakeasyVersion: 1.405.6
|
||||
sources:
|
||||
my-source:
|
||||
sourceNamespace: my-source
|
||||
@@ -8,8 +8,8 @@ sources:
|
||||
- latest
|
||||
plexapi:
|
||||
sourceNamespace: plexapi
|
||||
sourceRevisionDigest: sha256:ed1af8e79d553cc0bf2f8f7975f445d80cb8bd58390bca18d1352577da5ec5ed
|
||||
sourceBlobDigest: sha256:157db2a169209c18fdca786b671c5da8d2b14dc3005574d08c9d667320869093
|
||||
sourceRevisionDigest: sha256:b377f79289070406b0d4adcf59fa6886c6c90cb13a7893c07b44cae956ee25e4
|
||||
sourceBlobDigest: sha256:92072097f693005146db1ceb5728eee08693d61bb5578b26c32dcbe1cc32927f
|
||||
tags:
|
||||
- latest
|
||||
- main
|
||||
@@ -17,10 +17,10 @@ targets:
|
||||
plexjava:
|
||||
source: plexapi
|
||||
sourceNamespace: plexapi
|
||||
sourceRevisionDigest: sha256:ed1af8e79d553cc0bf2f8f7975f445d80cb8bd58390bca18d1352577da5ec5ed
|
||||
sourceBlobDigest: sha256:157db2a169209c18fdca786b671c5da8d2b14dc3005574d08c9d667320869093
|
||||
sourceRevisionDigest: sha256:b377f79289070406b0d4adcf59fa6886c6c90cb13a7893c07b44cae956ee25e4
|
||||
sourceBlobDigest: sha256:92072097f693005146db1ceb5728eee08693d61bb5578b26c32dcbe1cc32927f
|
||||
codeSamplesNamespace: code-samples-java-plexjava
|
||||
codeSamplesRevisionDigest: sha256:e01f78cd36aeb5eb46235c59f38fe7c81fa8b7b0b56fb76cf9c56af914f8e3a5
|
||||
codeSamplesRevisionDigest: sha256:ad2e918f9c50ecf860a405c94410f64a3ad90197c672258c177fd2e9d1f3d9a6
|
||||
workflow:
|
||||
workflowVersion: 1.0.0
|
||||
speakeasyVersion: latest
|
||||
|
||||
43
README.md
43
README.md
@@ -62,7 +62,7 @@ The samples below show how a published SDK artifact is used:
|
||||
|
||||
Gradle:
|
||||
```groovy
|
||||
implementation 'dev.plexapi:plexapi:0.6.1'
|
||||
implementation 'dev.plexapi:plexapi:0.7.0'
|
||||
```
|
||||
|
||||
Maven:
|
||||
@@ -70,7 +70,7 @@ Maven:
|
||||
<dependency>
|
||||
<groupId>dev.plexapi</groupId>
|
||||
<artifactId>plexapi</artifactId>
|
||||
<version>0.6.1</version>
|
||||
<version>0.7.0</version>
|
||||
</dependency>
|
||||
```
|
||||
|
||||
@@ -265,7 +265,7 @@ public class Application {
|
||||
|
||||
Certain parameters are configured globally. These parameters may be set on the SDK client instance itself during initialization. When configured as an option during SDK initialization, These global values will be used as defaults on the operations that use them. When such operations are called, there is a place in each to override the global value, if needed.
|
||||
|
||||
For example, you can set `ClientID` to `"gcgzw5rz2xovp84b4vha3a40"` at SDK initialization and then you do not have to pass the same value on calls to operations like `getPin`. But if you want to do so you may, which will locally override the global setting. See the example code below for a demonstration.
|
||||
For example, you can set `ClientID` to `"gcgzw5rz2xovp84b4vha3a40"` at SDK initialization and then you do not have to pass the same value on calls to operations like `getServerResources`. But if you want to do so you may, which will locally override the global setting. See the example code below for a demonstration.
|
||||
|
||||
|
||||
### Available Globals
|
||||
@@ -274,10 +274,7 @@ The following global parameters are available.
|
||||
|
||||
| Name | Type | Required | Description |
|
||||
| ---- | ---- |:--------:| ----------- |
|
||||
| clientID | java.lang.String | | The unique identifier for the client application
|
||||
This is used to track the client application and its usage
|
||||
(UUID, serial number, or other number unique per device)
|
||||
|
|
||||
| clientID | java.lang.String | | The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device) |
|
||||
| clientName | java.lang.String | | The clientName parameter. |
|
||||
| clientVersion | java.lang.String | | The clientVersion parameter. |
|
||||
| clientPlatform | java.lang.String | | The clientPlatform parameter. |
|
||||
@@ -290,16 +287,20 @@ This is used to track the client application and its usage
|
||||
package hello.world;
|
||||
|
||||
import dev.plexapi.sdk.PlexAPI;
|
||||
import dev.plexapi.sdk.models.errors.GetPinBadRequest;
|
||||
import dev.plexapi.sdk.models.operations.GetPinRequest;
|
||||
import dev.plexapi.sdk.models.operations.GetPinResponse;
|
||||
import dev.plexapi.sdk.models.errors.GetServerResourcesBadRequest;
|
||||
import dev.plexapi.sdk.models.errors.GetServerResourcesUnauthorized;
|
||||
import dev.plexapi.sdk.models.operations.GetServerResourcesResponse;
|
||||
import dev.plexapi.sdk.models.operations.IncludeHttps;
|
||||
import dev.plexapi.sdk.models.operations.IncludeIPv6;
|
||||
import dev.plexapi.sdk.models.operations.IncludeRelay;
|
||||
import java.lang.Exception;
|
||||
|
||||
public class Application {
|
||||
|
||||
public static void main(String[] args) throws GetPinBadRequest, Exception {
|
||||
public static void main(String[] args) throws GetServerResourcesBadRequest, GetServerResourcesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
@@ -307,14 +308,14 @@ public class Application {
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetPinRequest req = GetPinRequest.builder()
|
||||
.build();
|
||||
|
||||
GetPinResponse res = sdk.plex().getPin()
|
||||
.request(req)
|
||||
GetServerResourcesResponse res = sdk.plex().getServerResources()
|
||||
.includeHttps(IncludeHttps.Enable)
|
||||
.includeRelay(IncludeRelay.Enable)
|
||||
.includeIPv6(IncludeIPv6.Enable)
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.call();
|
||||
|
||||
if (res.authPinContainer().isPresent()) {
|
||||
if (res.plexDevices().isPresent()) {
|
||||
// handle response
|
||||
}
|
||||
}
|
||||
@@ -325,13 +326,15 @@ public class Application {
|
||||
<!-- Start Error Handling [errors] -->
|
||||
## Error Handling
|
||||
|
||||
Handling errors in this SDK should largely match your expectations. All operations return a response object or raise an error. If Error objects are specified in your OpenAPI Spec, the SDK will throw the appropriate Exception type.
|
||||
Handling errors in this SDK should largely match your expectations. All operations return a response object or raise an exception.
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
By default, an API error will throw a `models/errors/SDKError` exception. When custom error responses are specified for an operation, the SDK may also throw their associated exception. You can refer to respective *Errors* tables in SDK docs for more details on possible exception types for each operation. For example, the `getServerCapabilities` method throws the following exceptions:
|
||||
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------------------- | ----------------------------------------------- | ----------------------------------------------- |
|
||||
| models/errors/GetServerCapabilitiesBadRequest | 400 | application/json |
|
||||
| models/errors/GetServerCapabilitiesUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
### Example
|
||||
|
||||
|
||||
20
RELEASES.md
20
RELEASES.md
@@ -119,3 +119,23 @@ Based on:
|
||||
- [java v0.6.1] .
|
||||
### Releases
|
||||
- [Maven Central v0.6.1] https://central.sonatype.com/artifact/dev.plexapi/plexapi/0.6.1 - .
|
||||
|
||||
## 2024-09-30 00:26:54
|
||||
### Changes
|
||||
Based on:
|
||||
- OpenAPI Doc
|
||||
- Speakeasy CLI 1.404.5 (2.426.2) https://github.com/speakeasy-api/speakeasy
|
||||
### Generated
|
||||
- [java v0.6.2] .
|
||||
### Releases
|
||||
- [Maven Central v0.6.2] https://central.sonatype.com/artifact/dev.plexapi/plexapi/0.6.2 - .
|
||||
|
||||
## 2024-10-01 00:28:45
|
||||
### Changes
|
||||
Based on:
|
||||
- OpenAPI Doc
|
||||
- Speakeasy CLI 1.405.6 (2.428.1) https://github.com/speakeasy-api/speakeasy
|
||||
### Generated
|
||||
- [java v0.7.0] .
|
||||
### Releases
|
||||
- [Maven Central v0.7.0] https://central.sonatype.com/artifact/dev.plexapi/plexapi/0.7.0 - .
|
||||
@@ -63,7 +63,7 @@ tasks.withType(Javadoc) {
|
||||
}
|
||||
|
||||
group = "dev.plexapi"
|
||||
version = "0.6.1"
|
||||
version = "0.7.0"
|
||||
|
||||
sourcesJar {
|
||||
archiveBaseName = "plexapi"
|
||||
@@ -101,7 +101,7 @@ publishing {
|
||||
maven(MavenPublication) {
|
||||
groupId = 'dev.plexapi'
|
||||
artifactId = 'plexapi'
|
||||
version = '0.6.1'
|
||||
version = '0.7.0'
|
||||
|
||||
from components.java
|
||||
|
||||
@@ -152,9 +152,6 @@ dependencies {
|
||||
implementation 'org.apache.httpcomponents:httpclient:4.5.14'
|
||||
implementation 'org.apache.httpcomponents:httpmime:4.5.14'
|
||||
implementation 'commons-io:commons-io:2.15.1'
|
||||
testImplementation 'org.junit.jupiter:junit-jupiter:5.10.2'
|
||||
testImplementation 'org.mockito:mockito-core:5.12.0'
|
||||
testRuntimeOnly 'org.junit.platform:junit-platform-launcher:1.10.2'
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -2191,6 +2191,7 @@ actions:
|
||||
.includeHttps(IncludeHttps.Enable)
|
||||
.includeRelay(IncludeRelay.Enable)
|
||||
.includeIPv6(IncludeIPv6.Enable)
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.call();
|
||||
|
||||
if (res.plexDevices().isPresent()) {
|
||||
|
||||
@@ -12,28 +12,43 @@
|
||||
| `TREBLE_SHOW_FEATURES` | TREBLE-show-features |
|
||||
| `AD_COUNTDOWN_TIMER` | ad-countdown-timer |
|
||||
| `ADAPTIVE_BITRATE` | adaptive_bitrate |
|
||||
| `ALBUM_TYPES` | album-types |
|
||||
| `ALLOW_DVR` | allow_dvr |
|
||||
| `AMAZON_LOOP_DEBUG` | amazon-loop-debug |
|
||||
| `AVOD_AD_ANALYSIS` | avod-ad-analysis |
|
||||
| `AVOD_NEW_MEDIA` | avod-new-media |
|
||||
| `BLACKLIST_GET_SIGNIN` | blacklist_get_signin |
|
||||
| `BOOST_VOICES` | boost-voices |
|
||||
| `CAMERA_UPLOAD` | camera_upload |
|
||||
| `CLIENT_RADIO_STATIONS` | client-radio-stations |
|
||||
| `CLOUDFLARE_TURNSTILE_REQUIRED` | cloudflare-turnstile-required |
|
||||
| `CLOUDSYNC` | cloudsync |
|
||||
| `COLLECTIONS` | collections |
|
||||
| `COMMENTS_AND_REPLIES_PUSH_NOTIFICATIONS` | comments_and_replies_push_notifications |
|
||||
| `COMMUNITY_ACCESS_PLEX_TV` | community_access_plex_tv |
|
||||
| `COMPANIONS_SONOS` | companions_sonos |
|
||||
| `CONTENT_FILTER` | content_filter |
|
||||
| `CUSTOM_HOME_REMOVAL` | custom-home-removal |
|
||||
| `DISABLE_HOME_USER_FRIENDSHIPS` | disable_home_user_friendships |
|
||||
| `DISABLE_SHARING_FRIENDSHIPS` | disable_sharing_friendships |
|
||||
| `DOWNLOADS_GATING` | downloads-gating |
|
||||
| `DRM_SUPPORT` | drm_support |
|
||||
| `DVR` | dvr |
|
||||
| `DVR_BLOCK_UNSUPPORTED_COUNTRIES` | dvr-block-unsupported-countries |
|
||||
| `EPG_RECENT_CHANNELS` | epg-recent-channels |
|
||||
| `EXCLUDE_RESTRICTIONS` | exclude restrictions |
|
||||
| `FEDERATED_AUTH` | federated-auth |
|
||||
| `FRIEND_REQUEST_PUSH_NOTIFICATIONS` | friend_request_push_notifications |
|
||||
| `GRANDFATHER_SYNC` | grandfather-sync |
|
||||
| `GUIDED_UPGRADE` | guided-upgrade |
|
||||
| `HARDWARE_TRANSCODING` | hardware_transcoding |
|
||||
| `HOME` | home |
|
||||
| `HWTRANSCODE` | hwtranscode |
|
||||
| `IMAGGA_V2` | imagga-v2 |
|
||||
| `INCREASE_PASSWORD_COMPLEXITY` | increase-password-complexity |
|
||||
| `IOS14_PRIVACY_BANNER` | ios14-privacy-banner |
|
||||
| `ITERABLE_NOTIFICATION_TOKENS` | iterable-notification-tokens |
|
||||
| `ITEM_CLUSTERS` | item_clusters |
|
||||
| `KEEP_PAYMENT_METHOD` | keep-payment-method |
|
||||
| `KEVIN_BACON` | kevin-bacon |
|
||||
| `KOREA_CONSENT` | korea-consent |
|
||||
@@ -42,25 +57,46 @@
|
||||
| `LIGHTNING_DVR_PIVOT` | lightning-dvr-pivot |
|
||||
| `LIVE_TV_SUPPORT_INCOMPLETE_SEGMENTS` | live-tv-support-incomplete-segments |
|
||||
| `LIVETV` | livetv |
|
||||
| `LYRICS` | lyrics |
|
||||
| `METADATA_SEARCH` | metadata_search |
|
||||
| `MUSIC_ANALYSIS` | music-analysis |
|
||||
| `MUSIC_VIDEOS` | music_videos |
|
||||
| `NEW_PLEX_PASS_PRICES` | new_plex_pass_prices |
|
||||
| `NEWS_PROVIDER_SUNSET_MODAL` | news-provider-sunset-modal |
|
||||
| `NOMINATIM` | nominatim |
|
||||
| `PASS` | pass |
|
||||
| `PHOTOS_FAVORITES` | photos-favorites |
|
||||
| `PHOTOS_METADATA_EDITION` | photos-metadata-edition |
|
||||
| `PHOTOS_V6_EDIT` | photosV6-edit |
|
||||
| `PHOTOS_V6_TV_ALBUMS` | photosV6-tv-albums |
|
||||
| `PMS_HEALTH` | pms_health |
|
||||
| `PREMIUM_DASHBOARD` | premium-dashboard |
|
||||
| `PREMIUM_MUSIC_METADATA` | premium_music_metadata |
|
||||
| `RADIO` | radio |
|
||||
| `RATE_LIMIT_CLIENT_TOKEN` | rate-limit-client-token |
|
||||
| `SCROBBLING_SERVICE_PLEX_TV` | scrobbling-service-plex-tv |
|
||||
| `SESSION_BANDWIDTH_RESTRICTIONS` | session_bandwidth_restrictions |
|
||||
| `SESSION_KICK` | session_kick |
|
||||
| `SHARED_SERVER_NOTIFICATION` | shared_server_notification |
|
||||
| `SHARED_SOURCE_NOTIFICATION` | shared_source_notification |
|
||||
| `SIGNIN_NOTIFICATION` | signin_notification |
|
||||
| `SIGNIN_WITH_APPLE` | signin_with_apple |
|
||||
| `SILENCE_REMOVAL` | silence-removal |
|
||||
| `SLEEP_TIMER` | sleep-timer |
|
||||
| `SPRING_SERVE_AD_PROVIDER` | spring_serve_ad_provider |
|
||||
| `SYNC` | sync |
|
||||
| `SWEET_FADES` | sweet-fades |
|
||||
| `TRANSCODER_CACHE` | transcoder_cache |
|
||||
| `TRAILERS` | trailers |
|
||||
| `TUNER_SHARING` | tuner-sharing |
|
||||
| `TWO_FACTOR_AUTHENTICATION` | two-factor-authentication |
|
||||
| `UNSUPPORTEDTUNERS` | unsupportedtuners |
|
||||
| `UPGRADE3DS2` | upgrade-3ds2 |
|
||||
| `VISUALIZERS` | visualizers |
|
||||
| `VOD_SCHEMA` | vod-schema |
|
||||
| `VOD_CLOUDFLARE` | vod_cloudflare |
|
||||
| `VOLUME_LEVELING` | volume-leveling |
|
||||
| `WATCH_TOGETHER_INVITE` | watch-together-invite |
|
||||
| `WATCHLIST_RSS` | watchlist-rss |
|
||||
| `WEB_SERVER_DASHBOARD` | web_server_dashboard |
|
||||
| `WEBHOOKS` | webhooks |
|
||||
@@ -4,9 +4,9 @@
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `strong` | *Optional<Boolean>* | :heavy_minus_sign: | Determines the kind of code returned by the API call<br/>Strong codes are used for Pin authentication flows<br/>Non-Strong codes are used for `Plex.tv/link`<br/> | |
|
||||
| `clientID` | *Optional<String>* | :heavy_minus_sign: | The unique identifier for the client application<br/>This is used to track the client application and its usage<br/>(UUID, serial number, or other number unique per device)<br/> | gcgzw5rz2xovp84b4vha3a40 |
|
||||
| `clientID` | *Optional<String>* | :heavy_minus_sign: | The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device) | gcgzw5rz2xovp84b4vha3a40 |
|
||||
| `clientName` | *Optional<String>* | :heavy_minus_sign: | N/A | Plex Web |
|
||||
| `deviceName` | *Optional<String>* | :heavy_minus_sign: | N/A | Linux |
|
||||
| `clientVersion` | *Optional<String>* | :heavy_minus_sign: | N/A | 4.133.0 |
|
||||
|
||||
@@ -4,7 +4,8 @@
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ |
|
||||
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `includeHttps` | [Optional<IncludeHttps>](../../models/operations/IncludeHttps.md) | :heavy_minus_sign: | Include Https entries in the results | 1 |
|
||||
| `includeRelay` | [Optional<IncludeRelay>](../../models/operations/IncludeRelay.md) | :heavy_minus_sign: | Include Relay addresses in the results <br/>E.g: https://10-0-0-25.bbf8e10c7fa20447cacee74cd9914cde.plex.direct:32400<br/> | 1 |
|
||||
| `includeIPv6` | [Optional<IncludeIPv6>](../../models/operations/IncludeIPv6.md) | :heavy_minus_sign: | Include IPv6 entries in the results | 1 |
|
||||
| `clientID` | *Optional<String>* | :heavy_minus_sign: | The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device) | gcgzw5rz2xovp84b4vha3a40 |
|
||||
@@ -4,9 +4,9 @@
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `pinID` | *long* | :heavy_check_mark: | The PinID to retrieve an access token for | |
|
||||
| `clientID` | *Optional<String>* | :heavy_minus_sign: | The unique identifier for the client application<br/>This is used to track the client application and its usage<br/>(UUID, serial number, or other number unique per device)<br/> | gcgzw5rz2xovp84b4vha3a40 |
|
||||
| `clientID` | *Optional<String>* | :heavy_minus_sign: | The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device) | gcgzw5rz2xovp84b4vha3a40 |
|
||||
| `clientName` | *Optional<String>* | :heavy_minus_sign: | N/A | Plex Web |
|
||||
| `deviceName` | *Optional<String>* | :heavy_minus_sign: | N/A | Linux |
|
||||
| `clientVersion` | *Optional<String>* | :heavy_minus_sign: | N/A | 4.133.0 |
|
||||
|
||||
@@ -12,28 +12,43 @@
|
||||
| `TREBLE_SHOW_FEATURES` | TREBLE-show-features |
|
||||
| `AD_COUNTDOWN_TIMER` | ad-countdown-timer |
|
||||
| `ADAPTIVE_BITRATE` | adaptive_bitrate |
|
||||
| `ALBUM_TYPES` | album-types |
|
||||
| `ALLOW_DVR` | allow_dvr |
|
||||
| `AMAZON_LOOP_DEBUG` | amazon-loop-debug |
|
||||
| `AVOD_AD_ANALYSIS` | avod-ad-analysis |
|
||||
| `AVOD_NEW_MEDIA` | avod-new-media |
|
||||
| `BLACKLIST_GET_SIGNIN` | blacklist_get_signin |
|
||||
| `BOOST_VOICES` | boost-voices |
|
||||
| `CAMERA_UPLOAD` | camera_upload |
|
||||
| `CLIENT_RADIO_STATIONS` | client-radio-stations |
|
||||
| `CLOUDFLARE_TURNSTILE_REQUIRED` | cloudflare-turnstile-required |
|
||||
| `CLOUDSYNC` | cloudsync |
|
||||
| `COLLECTIONS` | collections |
|
||||
| `COMMENTS_AND_REPLIES_PUSH_NOTIFICATIONS` | comments_and_replies_push_notifications |
|
||||
| `COMMUNITY_ACCESS_PLEX_TV` | community_access_plex_tv |
|
||||
| `COMPANIONS_SONOS` | companions_sonos |
|
||||
| `CONTENT_FILTER` | content_filter |
|
||||
| `CUSTOM_HOME_REMOVAL` | custom-home-removal |
|
||||
| `DISABLE_HOME_USER_FRIENDSHIPS` | disable_home_user_friendships |
|
||||
| `DISABLE_SHARING_FRIENDSHIPS` | disable_sharing_friendships |
|
||||
| `DOWNLOADS_GATING` | downloads-gating |
|
||||
| `DRM_SUPPORT` | drm_support |
|
||||
| `DVR` | dvr |
|
||||
| `DVR_BLOCK_UNSUPPORTED_COUNTRIES` | dvr-block-unsupported-countries |
|
||||
| `EPG_RECENT_CHANNELS` | epg-recent-channels |
|
||||
| `EXCLUDE_RESTRICTIONS` | exclude restrictions |
|
||||
| `FEDERATED_AUTH` | federated-auth |
|
||||
| `FRIEND_REQUEST_PUSH_NOTIFICATIONS` | friend_request_push_notifications |
|
||||
| `GRANDFATHER_SYNC` | grandfather-sync |
|
||||
| `GUIDED_UPGRADE` | guided-upgrade |
|
||||
| `HARDWARE_TRANSCODING` | hardware_transcoding |
|
||||
| `HOME` | home |
|
||||
| `HWTRANSCODE` | hwtranscode |
|
||||
| `IMAGGA_V2` | imagga-v2 |
|
||||
| `INCREASE_PASSWORD_COMPLEXITY` | increase-password-complexity |
|
||||
| `IOS14_PRIVACY_BANNER` | ios14-privacy-banner |
|
||||
| `ITERABLE_NOTIFICATION_TOKENS` | iterable-notification-tokens |
|
||||
| `ITEM_CLUSTERS` | item_clusters |
|
||||
| `KEEP_PAYMENT_METHOD` | keep-payment-method |
|
||||
| `KEVIN_BACON` | kevin-bacon |
|
||||
| `KOREA_CONSENT` | korea-consent |
|
||||
@@ -42,25 +57,46 @@
|
||||
| `LIGHTNING_DVR_PIVOT` | lightning-dvr-pivot |
|
||||
| `LIVE_TV_SUPPORT_INCOMPLETE_SEGMENTS` | live-tv-support-incomplete-segments |
|
||||
| `LIVETV` | livetv |
|
||||
| `LYRICS` | lyrics |
|
||||
| `METADATA_SEARCH` | metadata_search |
|
||||
| `MUSIC_ANALYSIS` | music-analysis |
|
||||
| `MUSIC_VIDEOS` | music_videos |
|
||||
| `NEW_PLEX_PASS_PRICES` | new_plex_pass_prices |
|
||||
| `NEWS_PROVIDER_SUNSET_MODAL` | news-provider-sunset-modal |
|
||||
| `NOMINATIM` | nominatim |
|
||||
| `PASS` | pass |
|
||||
| `PHOTOS_FAVORITES` | photos-favorites |
|
||||
| `PHOTOS_METADATA_EDITION` | photos-metadata-edition |
|
||||
| `PHOTOS_V6_EDIT` | photosV6-edit |
|
||||
| `PHOTOS_V6_TV_ALBUMS` | photosV6-tv-albums |
|
||||
| `PMS_HEALTH` | pms_health |
|
||||
| `PREMIUM_DASHBOARD` | premium-dashboard |
|
||||
| `PREMIUM_MUSIC_METADATA` | premium_music_metadata |
|
||||
| `RADIO` | radio |
|
||||
| `RATE_LIMIT_CLIENT_TOKEN` | rate-limit-client-token |
|
||||
| `SCROBBLING_SERVICE_PLEX_TV` | scrobbling-service-plex-tv |
|
||||
| `SESSION_BANDWIDTH_RESTRICTIONS` | session_bandwidth_restrictions |
|
||||
| `SESSION_KICK` | session_kick |
|
||||
| `SHARED_SERVER_NOTIFICATION` | shared_server_notification |
|
||||
| `SHARED_SOURCE_NOTIFICATION` | shared_source_notification |
|
||||
| `SIGNIN_NOTIFICATION` | signin_notification |
|
||||
| `SIGNIN_WITH_APPLE` | signin_with_apple |
|
||||
| `SILENCE_REMOVAL` | silence-removal |
|
||||
| `SLEEP_TIMER` | sleep-timer |
|
||||
| `SPRING_SERVE_AD_PROVIDER` | spring_serve_ad_provider |
|
||||
| `SYNC` | sync |
|
||||
| `SWEET_FADES` | sweet-fades |
|
||||
| `TRANSCODER_CACHE` | transcoder_cache |
|
||||
| `TRAILERS` | trailers |
|
||||
| `TUNER_SHARING` | tuner-sharing |
|
||||
| `TWO_FACTOR_AUTHENTICATION` | two-factor-authentication |
|
||||
| `UNSUPPORTEDTUNERS` | unsupportedtuners |
|
||||
| `UPGRADE3DS2` | upgrade-3ds2 |
|
||||
| `VISUALIZERS` | visualizers |
|
||||
| `VOD_SCHEMA` | vod-schema |
|
||||
| `VOD_CLOUDFLARE` | vod_cloudflare |
|
||||
| `VOLUME_LEVELING` | volume-leveling |
|
||||
| `WATCH_TOGETHER_INVITE` | watch-together-invite |
|
||||
| `WATCHLIST_RSS` | watchlist-rss |
|
||||
| `WEB_SERVER_DASHBOARD` | web_server_dashboard |
|
||||
| `WEBHOOKS` | webhooks |
|
||||
@@ -12,28 +12,43 @@
|
||||
| `TREBLE_SHOW_FEATURES` | TREBLE-show-features |
|
||||
| `AD_COUNTDOWN_TIMER` | ad-countdown-timer |
|
||||
| `ADAPTIVE_BITRATE` | adaptive_bitrate |
|
||||
| `ALBUM_TYPES` | album-types |
|
||||
| `ALLOW_DVR` | allow_dvr |
|
||||
| `AMAZON_LOOP_DEBUG` | amazon-loop-debug |
|
||||
| `AVOD_AD_ANALYSIS` | avod-ad-analysis |
|
||||
| `AVOD_NEW_MEDIA` | avod-new-media |
|
||||
| `BLACKLIST_GET_SIGNIN` | blacklist_get_signin |
|
||||
| `BOOST_VOICES` | boost-voices |
|
||||
| `CAMERA_UPLOAD` | camera_upload |
|
||||
| `CLIENT_RADIO_STATIONS` | client-radio-stations |
|
||||
| `CLOUDFLARE_TURNSTILE_REQUIRED` | cloudflare-turnstile-required |
|
||||
| `CLOUDSYNC` | cloudsync |
|
||||
| `COLLECTIONS` | collections |
|
||||
| `COMMENTS_AND_REPLIES_PUSH_NOTIFICATIONS` | comments_and_replies_push_notifications |
|
||||
| `COMMUNITY_ACCESS_PLEX_TV` | community_access_plex_tv |
|
||||
| `COMPANIONS_SONOS` | companions_sonos |
|
||||
| `CONTENT_FILTER` | content_filter |
|
||||
| `CUSTOM_HOME_REMOVAL` | custom-home-removal |
|
||||
| `DISABLE_HOME_USER_FRIENDSHIPS` | disable_home_user_friendships |
|
||||
| `DISABLE_SHARING_FRIENDSHIPS` | disable_sharing_friendships |
|
||||
| `DOWNLOADS_GATING` | downloads-gating |
|
||||
| `DRM_SUPPORT` | drm_support |
|
||||
| `DVR` | dvr |
|
||||
| `DVR_BLOCK_UNSUPPORTED_COUNTRIES` | dvr-block-unsupported-countries |
|
||||
| `EPG_RECENT_CHANNELS` | epg-recent-channels |
|
||||
| `EXCLUDE_RESTRICTIONS` | exclude restrictions |
|
||||
| `FEDERATED_AUTH` | federated-auth |
|
||||
| `FRIEND_REQUEST_PUSH_NOTIFICATIONS` | friend_request_push_notifications |
|
||||
| `GRANDFATHER_SYNC` | grandfather-sync |
|
||||
| `GUIDED_UPGRADE` | guided-upgrade |
|
||||
| `HARDWARE_TRANSCODING` | hardware_transcoding |
|
||||
| `HOME` | home |
|
||||
| `HWTRANSCODE` | hwtranscode |
|
||||
| `IMAGGA_V2` | imagga-v2 |
|
||||
| `INCREASE_PASSWORD_COMPLEXITY` | increase-password-complexity |
|
||||
| `IOS14_PRIVACY_BANNER` | ios14-privacy-banner |
|
||||
| `ITERABLE_NOTIFICATION_TOKENS` | iterable-notification-tokens |
|
||||
| `ITEM_CLUSTERS` | item_clusters |
|
||||
| `KEEP_PAYMENT_METHOD` | keep-payment-method |
|
||||
| `KEVIN_BACON` | kevin-bacon |
|
||||
| `KOREA_CONSENT` | korea-consent |
|
||||
@@ -42,25 +57,46 @@
|
||||
| `LIGHTNING_DVR_PIVOT` | lightning-dvr-pivot |
|
||||
| `LIVE_TV_SUPPORT_INCOMPLETE_SEGMENTS` | live-tv-support-incomplete-segments |
|
||||
| `LIVETV` | livetv |
|
||||
| `LYRICS` | lyrics |
|
||||
| `METADATA_SEARCH` | metadata_search |
|
||||
| `MUSIC_ANALYSIS` | music-analysis |
|
||||
| `MUSIC_VIDEOS` | music_videos |
|
||||
| `NEW_PLEX_PASS_PRICES` | new_plex_pass_prices |
|
||||
| `NEWS_PROVIDER_SUNSET_MODAL` | news-provider-sunset-modal |
|
||||
| `NOMINATIM` | nominatim |
|
||||
| `PASS` | pass |
|
||||
| `PHOTOS_FAVORITES` | photos-favorites |
|
||||
| `PHOTOS_METADATA_EDITION` | photos-metadata-edition |
|
||||
| `PHOTOS_V6_EDIT` | photosV6-edit |
|
||||
| `PHOTOS_V6_TV_ALBUMS` | photosV6-tv-albums |
|
||||
| `PMS_HEALTH` | pms_health |
|
||||
| `PREMIUM_DASHBOARD` | premium-dashboard |
|
||||
| `PREMIUM_MUSIC_METADATA` | premium_music_metadata |
|
||||
| `RADIO` | radio |
|
||||
| `RATE_LIMIT_CLIENT_TOKEN` | rate-limit-client-token |
|
||||
| `SCROBBLING_SERVICE_PLEX_TV` | scrobbling-service-plex-tv |
|
||||
| `SESSION_BANDWIDTH_RESTRICTIONS` | session_bandwidth_restrictions |
|
||||
| `SESSION_KICK` | session_kick |
|
||||
| `SHARED_SERVER_NOTIFICATION` | shared_server_notification |
|
||||
| `SHARED_SOURCE_NOTIFICATION` | shared_source_notification |
|
||||
| `SIGNIN_NOTIFICATION` | signin_notification |
|
||||
| `SIGNIN_WITH_APPLE` | signin_with_apple |
|
||||
| `SILENCE_REMOVAL` | silence-removal |
|
||||
| `SLEEP_TIMER` | sleep-timer |
|
||||
| `SPRING_SERVE_AD_PROVIDER` | spring_serve_ad_provider |
|
||||
| `SYNC` | sync |
|
||||
| `SWEET_FADES` | sweet-fades |
|
||||
| `TRANSCODER_CACHE` | transcoder_cache |
|
||||
| `TRAILERS` | trailers |
|
||||
| `TUNER_SHARING` | tuner-sharing |
|
||||
| `TWO_FACTOR_AUTHENTICATION` | two-factor-authentication |
|
||||
| `UNSUPPORTEDTUNERS` | unsupportedtuners |
|
||||
| `UPGRADE3DS2` | upgrade-3ds2 |
|
||||
| `VISUALIZERS` | visualizers |
|
||||
| `VOD_SCHEMA` | vod-schema |
|
||||
| `VOD_CLOUDFLARE` | vod_cloudflare |
|
||||
| `VOLUME_LEVELING` | volume-leveling |
|
||||
| `WATCH_TOGETHER_INVITE` | watch-together-invite |
|
||||
| `WATCHLIST_RSS` | watchlist-rss |
|
||||
| `WEB_SERVER_DASHBOARD` | web_server_dashboard |
|
||||
| `WEBHOOKS` | webhooks |
|
||||
@@ -12,28 +12,43 @@
|
||||
| `TREBLE_SHOW_FEATURES` | TREBLE-show-features |
|
||||
| `AD_COUNTDOWN_TIMER` | ad-countdown-timer |
|
||||
| `ADAPTIVE_BITRATE` | adaptive_bitrate |
|
||||
| `ALBUM_TYPES` | album-types |
|
||||
| `ALLOW_DVR` | allow_dvr |
|
||||
| `AMAZON_LOOP_DEBUG` | amazon-loop-debug |
|
||||
| `AVOD_AD_ANALYSIS` | avod-ad-analysis |
|
||||
| `AVOD_NEW_MEDIA` | avod-new-media |
|
||||
| `BLACKLIST_GET_SIGNIN` | blacklist_get_signin |
|
||||
| `BOOST_VOICES` | boost-voices |
|
||||
| `CAMERA_UPLOAD` | camera_upload |
|
||||
| `CLIENT_RADIO_STATIONS` | client-radio-stations |
|
||||
| `CLOUDFLARE_TURNSTILE_REQUIRED` | cloudflare-turnstile-required |
|
||||
| `CLOUDSYNC` | cloudsync |
|
||||
| `COLLECTIONS` | collections |
|
||||
| `COMMENTS_AND_REPLIES_PUSH_NOTIFICATIONS` | comments_and_replies_push_notifications |
|
||||
| `COMMUNITY_ACCESS_PLEX_TV` | community_access_plex_tv |
|
||||
| `COMPANIONS_SONOS` | companions_sonos |
|
||||
| `CONTENT_FILTER` | content_filter |
|
||||
| `CUSTOM_HOME_REMOVAL` | custom-home-removal |
|
||||
| `DISABLE_HOME_USER_FRIENDSHIPS` | disable_home_user_friendships |
|
||||
| `DISABLE_SHARING_FRIENDSHIPS` | disable_sharing_friendships |
|
||||
| `DOWNLOADS_GATING` | downloads-gating |
|
||||
| `DRM_SUPPORT` | drm_support |
|
||||
| `DVR` | dvr |
|
||||
| `DVR_BLOCK_UNSUPPORTED_COUNTRIES` | dvr-block-unsupported-countries |
|
||||
| `EPG_RECENT_CHANNELS` | epg-recent-channels |
|
||||
| `EXCLUDE_RESTRICTIONS` | exclude restrictions |
|
||||
| `FEDERATED_AUTH` | federated-auth |
|
||||
| `FRIEND_REQUEST_PUSH_NOTIFICATIONS` | friend_request_push_notifications |
|
||||
| `GRANDFATHER_SYNC` | grandfather-sync |
|
||||
| `GUIDED_UPGRADE` | guided-upgrade |
|
||||
| `HARDWARE_TRANSCODING` | hardware_transcoding |
|
||||
| `HOME` | home |
|
||||
| `HWTRANSCODE` | hwtranscode |
|
||||
| `IMAGGA_V2` | imagga-v2 |
|
||||
| `INCREASE_PASSWORD_COMPLEXITY` | increase-password-complexity |
|
||||
| `IOS14_PRIVACY_BANNER` | ios14-privacy-banner |
|
||||
| `ITERABLE_NOTIFICATION_TOKENS` | iterable-notification-tokens |
|
||||
| `ITEM_CLUSTERS` | item_clusters |
|
||||
| `KEEP_PAYMENT_METHOD` | keep-payment-method |
|
||||
| `KEVIN_BACON` | kevin-bacon |
|
||||
| `KOREA_CONSENT` | korea-consent |
|
||||
@@ -42,25 +57,46 @@
|
||||
| `LIGHTNING_DVR_PIVOT` | lightning-dvr-pivot |
|
||||
| `LIVE_TV_SUPPORT_INCOMPLETE_SEGMENTS` | live-tv-support-incomplete-segments |
|
||||
| `LIVETV` | livetv |
|
||||
| `LYRICS` | lyrics |
|
||||
| `METADATA_SEARCH` | metadata_search |
|
||||
| `MUSIC_ANALYSIS` | music-analysis |
|
||||
| `MUSIC_VIDEOS` | music_videos |
|
||||
| `NEW_PLEX_PASS_PRICES` | new_plex_pass_prices |
|
||||
| `NEWS_PROVIDER_SUNSET_MODAL` | news-provider-sunset-modal |
|
||||
| `NOMINATIM` | nominatim |
|
||||
| `PASS` | pass |
|
||||
| `PHOTOS_FAVORITES` | photos-favorites |
|
||||
| `PHOTOS_METADATA_EDITION` | photos-metadata-edition |
|
||||
| `PHOTOS_V6_EDIT` | photosV6-edit |
|
||||
| `PHOTOS_V6_TV_ALBUMS` | photosV6-tv-albums |
|
||||
| `PMS_HEALTH` | pms_health |
|
||||
| `PREMIUM_DASHBOARD` | premium-dashboard |
|
||||
| `PREMIUM_MUSIC_METADATA` | premium_music_metadata |
|
||||
| `RADIO` | radio |
|
||||
| `RATE_LIMIT_CLIENT_TOKEN` | rate-limit-client-token |
|
||||
| `SCROBBLING_SERVICE_PLEX_TV` | scrobbling-service-plex-tv |
|
||||
| `SESSION_BANDWIDTH_RESTRICTIONS` | session_bandwidth_restrictions |
|
||||
| `SESSION_KICK` | session_kick |
|
||||
| `SHARED_SERVER_NOTIFICATION` | shared_server_notification |
|
||||
| `SHARED_SOURCE_NOTIFICATION` | shared_source_notification |
|
||||
| `SIGNIN_NOTIFICATION` | signin_notification |
|
||||
| `SIGNIN_WITH_APPLE` | signin_with_apple |
|
||||
| `SILENCE_REMOVAL` | silence-removal |
|
||||
| `SLEEP_TIMER` | sleep-timer |
|
||||
| `SPRING_SERVE_AD_PROVIDER` | spring_serve_ad_provider |
|
||||
| `SYNC` | sync |
|
||||
| `SWEET_FADES` | sweet-fades |
|
||||
| `TRANSCODER_CACHE` | transcoder_cache |
|
||||
| `TRAILERS` | trailers |
|
||||
| `TUNER_SHARING` | tuner-sharing |
|
||||
| `TWO_FACTOR_AUTHENTICATION` | two-factor-authentication |
|
||||
| `UNSUPPORTEDTUNERS` | unsupportedtuners |
|
||||
| `UPGRADE3DS2` | upgrade-3ds2 |
|
||||
| `VISUALIZERS` | visualizers |
|
||||
| `VOD_SCHEMA` | vod-schema |
|
||||
| `VOD_CLOUDFLARE` | vod_cloudflare |
|
||||
| `VOLUME_LEVELING` | volume-leveling |
|
||||
| `WATCH_TOGETHER_INVITE` | watch-together-invite |
|
||||
| `WATCHLIST_RSS` | watchlist-rss |
|
||||
| `WEB_SERVER_DASHBOARD` | web_server_dashboard |
|
||||
| `WEBHOOKS` | webhooks |
|
||||
@@ -4,8 +4,8 @@
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `clientID` | *Optional<String>* | :heavy_minus_sign: | The unique identifier for the client application<br/>This is used to track the client application and its usage<br/>(UUID, serial number, or other number unique per device)<br/> | gcgzw5rz2xovp84b4vha3a40 |
|
||||
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `clientID` | *Optional<String>* | :heavy_minus_sign: | The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device) | gcgzw5rz2xovp84b4vha3a40 |
|
||||
| `clientName` | *Optional<String>* | :heavy_minus_sign: | N/A | Plex Web |
|
||||
| `deviceName` | *Optional<String>* | :heavy_minus_sign: | N/A | Linux |
|
||||
| `clientVersion` | *Optional<String>* | :heavy_minus_sign: | N/A | 4.133.0 |
|
||||
|
||||
@@ -61,12 +61,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||
| models/errors/GetServerActivitiesBadRequest | 400 | application/json |
|
||||
| models/errors/GetServerActivitiesUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## cancelServerActivities
|
||||
|
||||
@@ -117,8 +116,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ |
|
||||
| models/errors/CancelServerActivitiesBadRequest | 400 | application/json |
|
||||
| models/errors/CancelServerActivitiesUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -67,12 +67,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------- | ------------------------------------------- | ------------------------------------------- |
|
||||
| models/errors/GetTransientTokenBadRequest | 400 | application/json |
|
||||
| models/errors/GetTransientTokenUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getSourceConnectionInformation
|
||||
|
||||
@@ -125,12 +124,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| -------------------------------------------------------- | -------------------------------------------------------- | -------------------------------------------------------- |
|
||||
| models/errors/GetSourceConnectionInformationBadRequest | 400 | application/json |
|
||||
| models/errors/GetSourceConnectionInformationUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getTokenDetails
|
||||
|
||||
@@ -182,12 +180,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- |
|
||||
| models/errors/GetTokenDetailsBadRequest | 400 | application/json |
|
||||
| models/errors/GetTokenDetailsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## postUsersSignInData
|
||||
|
||||
@@ -250,8 +247,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||
| models/errors/PostUsersSignInDataBadRequest | 400 | application/json |
|
||||
| models/errors/PostUsersSignInDataUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -58,12 +58,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
|
||||
| models/errors/GetButlerTasksBadRequest | 400 | application/json |
|
||||
| models/errors/GetButlerTasksUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## startAllTasks
|
||||
|
||||
@@ -112,12 +111,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------- | --------------------------------------- | --------------------------------------- |
|
||||
| models/errors/StartAllTasksBadRequest | 400 | application/json |
|
||||
| models/errors/StartAllTasksUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## stopAllTasks
|
||||
|
||||
@@ -162,12 +160,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| -------------------------------------- | -------------------------------------- | -------------------------------------- |
|
||||
| models/errors/StopAllTasksBadRequest | 400 | application/json |
|
||||
| models/errors/StopAllTasksUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## startTask
|
||||
|
||||
@@ -224,12 +221,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------- | ----------------------------------- | ----------------------------------- |
|
||||
| models/errors/StartTaskBadRequest | 400 | application/json |
|
||||
| models/errors/StartTaskUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## stopTask
|
||||
|
||||
@@ -282,8 +278,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------- | ---------------------------------- | ---------------------------------- |
|
||||
| models/errors/StopTaskBadRequest | 400 | application/json |
|
||||
| models/errors/StopTaskUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -66,12 +66,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------- | --------------------------------------- | --------------------------------------- |
|
||||
| models/errors/GetGlobalHubsBadRequest | 400 | application/json |
|
||||
| models/errors/GetGlobalHubsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getRecentlyAdded
|
||||
|
||||
@@ -135,10 +134,9 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------- | ---------------------- | ---------------------- |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getLibraryHubs
|
||||
|
||||
@@ -197,8 +195,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
|
||||
| models/errors/GetLibraryHubsBadRequest | 400 | application/json |
|
||||
| models/errors/GetLibraryHubsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -72,12 +72,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------- | ------------------------------------- | ------------------------------------- |
|
||||
| models/errors/GetFileHashBadRequest | 400 | application/json |
|
||||
| models/errors/GetFileHashUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getRecentlyAddedLibrary
|
||||
|
||||
@@ -157,12 +156,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------------- | ------------------------------------------------- | ------------------------------------------------- |
|
||||
| models/errors/GetRecentlyAddedLibraryBadRequest | 400 | application/json |
|
||||
| models/errors/GetRecentlyAddedLibraryUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getAllLibraries
|
||||
|
||||
@@ -214,12 +212,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- |
|
||||
| models/errors/GetAllLibrariesBadRequest | 400 | application/json |
|
||||
| models/errors/GetAllLibrariesUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getLibraryDetails
|
||||
|
||||
@@ -314,12 +311,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------- | ------------------------------------------- | ------------------------------------------- |
|
||||
| models/errors/GetLibraryDetailsBadRequest | 400 | application/json |
|
||||
| models/errors/GetLibraryDetailsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## deleteLibrary
|
||||
|
||||
@@ -370,12 +366,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------- | --------------------------------------- | --------------------------------------- |
|
||||
| models/errors/DeleteLibraryBadRequest | 400 | application/json |
|
||||
| models/errors/DeleteLibraryUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getLibraryItems
|
||||
|
||||
@@ -463,12 +458,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- |
|
||||
| models/errors/GetLibraryItemsBadRequest | 400 | application/json |
|
||||
| models/errors/GetLibraryItemsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getRefreshLibraryMetadata
|
||||
|
||||
@@ -523,12 +517,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------------------- | --------------------------------------------------- | --------------------------------------------------- |
|
||||
| models/errors/GetRefreshLibraryMetadataBadRequest | 400 | application/json |
|
||||
| models/errors/GetRefreshLibraryMetadataUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getSearchLibrary
|
||||
|
||||
@@ -602,12 +595,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------ | ------------------------------------------ | ------------------------------------------ |
|
||||
| models/errors/GetSearchLibraryBadRequest | 400 | application/json |
|
||||
| models/errors/GetSearchLibraryUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getMetaDataByRatingKey
|
||||
|
||||
@@ -661,12 +653,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ |
|
||||
| models/errors/GetMetaDataByRatingKeyBadRequest | 400 | application/json |
|
||||
| models/errors/GetMetaDataByRatingKeyUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getMetadataChildren
|
||||
|
||||
@@ -722,12 +713,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||
| models/errors/GetMetadataChildrenBadRequest | 400 | application/json |
|
||||
| models/errors/GetMetadataChildrenUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getTopWatchedContent
|
||||
|
||||
@@ -784,12 +774,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------------- | ---------------------------------------------- | ---------------------------------------------- |
|
||||
| models/errors/GetTopWatchedContentBadRequest | 400 | application/json |
|
||||
| models/errors/GetTopWatchedContentUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getOnDeck
|
||||
|
||||
@@ -836,8 +825,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------- | ----------------------------------- | ----------------------------------- |
|
||||
| models/errors/GetOnDeckBadRequest | 400 | application/json |
|
||||
| models/errors/GetOnDeckUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -67,12 +67,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------- | --------------------------------- | --------------------------------- |
|
||||
| models/errors/LogLineBadRequest | 400 | application/json |
|
||||
| models/errors/LogLineUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## logMultiLine
|
||||
|
||||
@@ -148,12 +147,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| -------------------------------------- | -------------------------------------- | -------------------------------------- |
|
||||
| models/errors/LogMultiLineBadRequest | 400 | application/json |
|
||||
| models/errors/LogMultiLineUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## enablePaperTrail
|
||||
|
||||
@@ -198,8 +196,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------ | ------------------------------------------ | ------------------------------------------ |
|
||||
| models/errors/EnablePaperTrailBadRequest | 400 | application/json |
|
||||
| models/errors/EnablePaperTrailUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -63,12 +63,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------ | ------------------------------------ | ------------------------------------ |
|
||||
| models/errors/MarkPlayedBadRequest | 400 | application/json |
|
||||
| models/errors/MarkPlayedUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## markUnplayed
|
||||
|
||||
@@ -119,12 +118,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| -------------------------------------- | -------------------------------------- | -------------------------------------- |
|
||||
| models/errors/MarkUnplayedBadRequest | 400 | application/json |
|
||||
| models/errors/MarkUnplayedUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## updatePlayProgress
|
||||
|
||||
@@ -180,12 +178,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| -------------------------------------------- | -------------------------------------------- | -------------------------------------------- |
|
||||
| models/errors/UpdatePlayProgressBadRequest | 400 | application/json |
|
||||
| models/errors/UpdatePlayProgressUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getBannerImage
|
||||
|
||||
@@ -248,12 +245,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
|
||||
| models/errors/GetBannerImageBadRequest | 400 | application/json |
|
||||
| models/errors/GetBannerImageUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getThumbImage
|
||||
|
||||
@@ -316,8 +312,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------- | --------------------------------------- | --------------------------------------- |
|
||||
| models/errors/GetThumbImageBadRequest | 400 | application/json |
|
||||
| models/errors/GetThumbImageUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -85,12 +85,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
|
||||
| models/errors/CreatePlaylistBadRequest | 400 | application/json |
|
||||
| models/errors/CreatePlaylistUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getPlaylists
|
||||
|
||||
@@ -147,12 +146,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| -------------------------------------- | -------------------------------------- | -------------------------------------- |
|
||||
| models/errors/GetPlaylistsBadRequest | 400 | application/json |
|
||||
| models/errors/GetPlaylistsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getPlaylist
|
||||
|
||||
@@ -207,12 +205,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------- | ------------------------------------- | ------------------------------------- |
|
||||
| models/errors/GetPlaylistBadRequest | 400 | application/json |
|
||||
| models/errors/GetPlaylistUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## deletePlaylist
|
||||
|
||||
@@ -264,12 +261,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
|
||||
| models/errors/DeletePlaylistBadRequest | 400 | application/json |
|
||||
| models/errors/DeletePlaylistUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## updatePlaylist
|
||||
|
||||
@@ -325,12 +321,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
|
||||
| models/errors/UpdatePlaylistBadRequest | 400 | application/json |
|
||||
| models/errors/UpdatePlaylistUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getPlaylistContents
|
||||
|
||||
@@ -390,12 +385,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||
| models/errors/GetPlaylistContentsBadRequest | 400 | application/json |
|
||||
| models/errors/GetPlaylistContentsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## clearPlaylistContents
|
||||
|
||||
@@ -447,12 +441,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------------------- | ----------------------------------------------- | ----------------------------------------------- |
|
||||
| models/errors/ClearPlaylistContentsBadRequest | 400 | application/json |
|
||||
| models/errors/ClearPlaylistContentsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## addPlaylistContents
|
||||
|
||||
@@ -511,12 +504,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||
| models/errors/AddPlaylistContentsBadRequest | 400 | application/json |
|
||||
| models/errors/AddPlaylistContentsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## uploadPlaylist
|
||||
|
||||
@@ -573,8 +565,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
|
||||
| models/errors/UploadPlaylistBadRequest | 400 | application/json |
|
||||
| models/errors/UploadPlaylistUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -66,12 +66,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------- | ------------------------------------------- | ------------------------------------------- |
|
||||
| models/errors/GetCompanionsDataBadRequest | 400 | application/json |
|
||||
| models/errors/GetCompanionsDataUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getUserFriends
|
||||
|
||||
@@ -123,12 +122,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
|
||||
| models/errors/GetUserFriendsBadRequest | 400 | application/json |
|
||||
| models/errors/GetUserFriendsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getGeoData
|
||||
|
||||
@@ -179,12 +177,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------ | ------------------------------------ | ------------------------------------ |
|
||||
| models/errors/GetGeoDataBadRequest | 400 | application/json |
|
||||
| models/errors/GetGeoDataUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getHomeData
|
||||
|
||||
@@ -230,12 +227,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------- | ------------------------------------- | ------------------------------------- |
|
||||
| models/errors/GetHomeDataBadRequest | 400 | application/json |
|
||||
| models/errors/GetHomeDataUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getServerResources
|
||||
|
||||
@@ -272,6 +268,7 @@ public class Application {
|
||||
.includeHttps(IncludeHttps.Enable)
|
||||
.includeRelay(IncludeRelay.Enable)
|
||||
.includeIPv6(IncludeIPv6.Enable)
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.call();
|
||||
|
||||
if (res.plexDevices().isPresent()) {
|
||||
@@ -284,10 +281,11 @@ public class Application {
|
||||
### Parameters
|
||||
|
||||
| Parameter | Type | Required | Description | Example |
|
||||
| ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ |
|
||||
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `includeHttps` | [Optional<IncludeHttps>](../../models/operations/IncludeHttps.md) | :heavy_minus_sign: | Include Https entries in the results | 1 |
|
||||
| `includeRelay` | [Optional<IncludeRelay>](../../models/operations/IncludeRelay.md) | :heavy_minus_sign: | Include Relay addresses in the results <br/>E.g: https://10-0-0-25.bbf8e10c7fa20447cacee74cd9914cde.plex.direct:32400<br/> | 1 |
|
||||
| `includeIPv6` | [Optional<IncludeIPv6>](../../models/operations/IncludeIPv6.md) | :heavy_minus_sign: | Include IPv6 entries in the results | 1 |
|
||||
| `clientID` | *Optional<String>* | :heavy_minus_sign: | The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device) | gcgzw5rz2xovp84b4vha3a40 |
|
||||
| `serverURL` | *String* | :heavy_minus_sign: | An optional server URL to use. | http://localhost:8080 |
|
||||
|
||||
### Response
|
||||
@@ -296,12 +294,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| -------------------------------------------- | -------------------------------------------- | -------------------------------------------- |
|
||||
| models/errors/GetServerResourcesBadRequest | 400 | application/json |
|
||||
| models/errors/GetServerResourcesUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getPin
|
||||
|
||||
@@ -357,11 +354,10 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------ | ------------------------------ | ------------------------------ |
|
||||
| models/errors/GetPinBadRequest | 400 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getTokenByPinId
|
||||
|
||||
@@ -419,8 +415,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- |
|
||||
| models/errors/GetTokenByPinIdBadRequest | 400 | application/json |
|
||||
| models/errors/GetTokenByPinIdResponseBody | 404 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -77,12 +77,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------- | --------------------------------------- | --------------------------------------- |
|
||||
| models/errors/PerformSearchBadRequest | 400 | application/json |
|
||||
| models/errors/PerformSearchUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## performVoiceSearch
|
||||
|
||||
@@ -141,12 +140,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| -------------------------------------------- | -------------------------------------------- | -------------------------------------------- |
|
||||
| models/errors/PerformVoiceSearchBadRequest | 400 | application/json |
|
||||
| models/errors/PerformVoiceSearchUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getSearchResults
|
||||
|
||||
@@ -199,8 +197,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------ | ------------------------------------------ | ------------------------------------------ |
|
||||
| models/errors/GetSearchResultsBadRequest | 400 | application/json |
|
||||
| models/errors/GetSearchResultsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -62,12 +62,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------------------- | ----------------------------------------------- | ----------------------------------------------- |
|
||||
| models/errors/GetServerCapabilitiesBadRequest | 400 | application/json |
|
||||
| models/errors/GetServerCapabilitiesUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getServerPreferences
|
||||
|
||||
@@ -113,12 +112,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------------- | ---------------------------------------------- | ---------------------------------------------- |
|
||||
| models/errors/GetServerPreferencesBadRequest | 400 | application/json |
|
||||
| models/errors/GetServerPreferencesUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getAvailableClients
|
||||
|
||||
@@ -164,12 +162,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||
| models/errors/GetAvailableClientsBadRequest | 400 | application/json |
|
||||
| models/errors/GetAvailableClientsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getDevices
|
||||
|
||||
@@ -215,12 +212,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------ | ------------------------------------ | ------------------------------------ |
|
||||
| models/errors/GetDevicesBadRequest | 400 | application/json |
|
||||
| models/errors/GetDevicesUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getServerIdentity
|
||||
|
||||
@@ -264,11 +260,10 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------------- | --------------------------------------------- | --------------------------------------------- |
|
||||
| models/errors/GetServerIdentityRequestTimeout | 408 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getMyPlexAccount
|
||||
|
||||
@@ -314,12 +309,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------ | ------------------------------------------ | ------------------------------------------ |
|
||||
| models/errors/GetMyPlexAccountBadRequest | 400 | application/json |
|
||||
| models/errors/GetMyPlexAccountUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getResizedPhoto
|
||||
|
||||
@@ -384,12 +378,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- |
|
||||
| models/errors/GetResizedPhotoBadRequest | 400 | application/json |
|
||||
| models/errors/GetResizedPhotoUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getMediaProviders
|
||||
|
||||
@@ -442,12 +435,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------- | ------------------------------------------- | ------------------------------------------- |
|
||||
| models/errors/GetMediaProvidersBadRequest | 400 | application/json |
|
||||
| models/errors/GetMediaProvidersUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getServerList
|
||||
|
||||
@@ -493,8 +485,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------- | --------------------------------------- | --------------------------------------- |
|
||||
| models/errors/GetServerListBadRequest | 400 | application/json |
|
||||
| models/errors/GetServerListUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -57,12 +57,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------- | ------------------------------------- | ------------------------------------- |
|
||||
| models/errors/GetSessionsBadRequest | 400 | application/json |
|
||||
| models/errors/GetSessionsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getSessionHistory
|
||||
|
||||
@@ -123,12 +122,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------- | ------------------------------------------- | ------------------------------------------- |
|
||||
| models/errors/GetSessionHistoryBadRequest | 400 | application/json |
|
||||
| models/errors/GetSessionHistoryUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getTranscodeSessions
|
||||
|
||||
@@ -174,12 +172,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------------- | ---------------------------------------------- | ---------------------------------------------- |
|
||||
| models/errors/GetTranscodeSessionsBadRequest | 400 | application/json |
|
||||
| models/errors/GetTranscodeSessionsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## stopTranscodeSession
|
||||
|
||||
@@ -230,8 +227,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ---------------------------------------------- | ---------------------------------------------- | ---------------------------------------------- |
|
||||
| models/errors/StopTranscodeSessionBadRequest | 400 | application/json |
|
||||
| models/errors/StopTranscodeSessionUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -63,12 +63,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| --------------------------------------- | --------------------------------------- | --------------------------------------- |
|
||||
| models/errors/GetStatisticsBadRequest | 400 | application/json |
|
||||
| models/errors/GetStatisticsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getResourcesStatistics
|
||||
|
||||
@@ -121,12 +120,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ |
|
||||
| models/errors/GetResourcesStatisticsBadRequest | 400 | application/json |
|
||||
| models/errors/GetResourcesStatisticsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## getBandwidthStatistics
|
||||
|
||||
@@ -179,8 +177,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------------ | ------------------------------------------------ | ------------------------------------------------ |
|
||||
| models/errors/GetBandwidthStatisticsBadRequest | 400 | application/json |
|
||||
| models/errors/GetBandwidthStatisticsUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -57,12 +57,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- |
|
||||
| models/errors/GetUpdateStatusBadRequest | 400 | application/json |
|
||||
| models/errors/GetUpdateStatusUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## checkForUpdates
|
||||
|
||||
@@ -114,12 +113,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- |
|
||||
| models/errors/CheckForUpdatesBadRequest | 400 | application/json |
|
||||
| models/errors/CheckForUpdatesUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## applyUpdates
|
||||
|
||||
@@ -175,8 +173,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| -------------------------------------- | -------------------------------------- | -------------------------------------- |
|
||||
| models/errors/ApplyUpdatesBadRequest | 400 | application/json |
|
||||
| models/errors/ApplyUpdatesUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -75,12 +75,11 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------- | ------------------------------------- | ------------------------------------- |
|
||||
| models/errors/GetTimelineBadRequest | 400 | application/json |
|
||||
| models/errors/GetTimelineUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
|
||||
## startUniversalTranscode
|
||||
|
||||
@@ -151,8 +150,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| ------------------------------------------------- | ------------------------------------------------- | ------------------------------------------------- |
|
||||
| models/errors/StartUniversalTranscodeBadRequest | 400 | application/json |
|
||||
| models/errors/StartUniversalTranscodeUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -71,8 +71,8 @@ public class Application {
|
||||
|
||||
### Errors
|
||||
|
||||
| Error Object | Status Code | Content Type |
|
||||
| Error Type | Status Code | Content Type |
|
||||
| -------------------------------------- | -------------------------------------- | -------------------------------------- |
|
||||
| models/errors/GetWatchListBadRequest | 400 | application/json |
|
||||
| models/errors/GetWatchListUnauthorized | 401 | application/json |
|
||||
| models/errors/SDKError | 4xx-5xx | \*\/* |
|
||||
| models/errors/SDKError | 4XX, 5XX | \*/\* |
|
||||
@@ -767,7 +767,7 @@ public class Plex implements
|
||||
* @throws Exception if the API call fails
|
||||
*/
|
||||
public GetServerResourcesResponse getServerResourcesDirect() throws Exception {
|
||||
return getServerResources(Optional.empty(), Optional.empty(), Optional.empty(), Optional.empty());
|
||||
return getServerResources(Optional.empty(), Optional.empty(), Optional.empty(), Optional.empty(), Optional.empty());
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -778,6 +778,7 @@ public class Plex implements
|
||||
E.g: https://10-0-0-25.bbf8e10c7fa20447cacee74cd9914cde.plex.direct:32400
|
||||
|
||||
* @param includeIPv6 Include IPv6 entries in the results
|
||||
* @param clientID The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
* @param serverURL Overrides the server URL.
|
||||
* @return The response from the API call
|
||||
* @throws Exception if the API call fails
|
||||
@@ -786,6 +787,7 @@ public class Plex implements
|
||||
Optional<? extends IncludeHttps> includeHttps,
|
||||
Optional<? extends IncludeRelay> includeRelay,
|
||||
Optional<? extends IncludeIPv6> includeIPv6,
|
||||
Optional<String> clientID,
|
||||
Optional<String> serverURL) throws Exception {
|
||||
GetServerResourcesRequest request =
|
||||
GetServerResourcesRequest
|
||||
@@ -793,6 +795,7 @@ public class Plex implements
|
||||
.includeHttps(includeHttps)
|
||||
.includeRelay(includeRelay)
|
||||
.includeIPv6(includeIPv6)
|
||||
.clientID(clientID)
|
||||
.build();
|
||||
|
||||
String _baseUrl = Utils.templateUrl(GET_SERVER_RESOURCES_SERVERS[0], new HashMap<String, String>());
|
||||
|
||||
@@ -36,8 +36,8 @@ class SDKConfiguration {
|
||||
} };
|
||||
private static final String LANGUAGE = "java";
|
||||
public static final String OPENAPI_DOC_VERSION = "0.0.3";
|
||||
public static final String SDK_VERSION = "0.6.1";
|
||||
public static final String GEN_VERSION = "2.426.2";
|
||||
public static final String SDK_VERSION = "0.7.0";
|
||||
public static final String GEN_VERSION = "2.428.1";
|
||||
private static final String BASE_PACKAGE = "dev.plexapi.sdk";
|
||||
public static final String USER_AGENT =
|
||||
String.format("speakeasy-sdk/%s %s %s %s %s",
|
||||
|
||||
@@ -15,28 +15,43 @@ public enum Features {
|
||||
TREBLE_SHOW_FEATURES("TREBLE-show-features"),
|
||||
AD_COUNTDOWN_TIMER("ad-countdown-timer"),
|
||||
ADAPTIVE_BITRATE("adaptive_bitrate"),
|
||||
ALBUM_TYPES("album-types"),
|
||||
ALLOW_DVR("allow_dvr"),
|
||||
AMAZON_LOOP_DEBUG("amazon-loop-debug"),
|
||||
AVOD_AD_ANALYSIS("avod-ad-analysis"),
|
||||
AVOD_NEW_MEDIA("avod-new-media"),
|
||||
BLACKLIST_GET_SIGNIN("blacklist_get_signin"),
|
||||
BOOST_VOICES("boost-voices"),
|
||||
CAMERA_UPLOAD("camera_upload"),
|
||||
CLIENT_RADIO_STATIONS("client-radio-stations"),
|
||||
CLOUDFLARE_TURNSTILE_REQUIRED("cloudflare-turnstile-required"),
|
||||
CLOUDSYNC("cloudsync"),
|
||||
COLLECTIONS("collections"),
|
||||
COMMENTS_AND_REPLIES_PUSH_NOTIFICATIONS("comments_and_replies_push_notifications"),
|
||||
COMMUNITY_ACCESS_PLEX_TV("community_access_plex_tv"),
|
||||
COMPANIONS_SONOS("companions_sonos"),
|
||||
CONTENT_FILTER("content_filter"),
|
||||
CUSTOM_HOME_REMOVAL("custom-home-removal"),
|
||||
DISABLE_HOME_USER_FRIENDSHIPS("disable_home_user_friendships"),
|
||||
DISABLE_SHARING_FRIENDSHIPS("disable_sharing_friendships"),
|
||||
DOWNLOADS_GATING("downloads-gating"),
|
||||
DRM_SUPPORT("drm_support"),
|
||||
DVR("dvr"),
|
||||
DVR_BLOCK_UNSUPPORTED_COUNTRIES("dvr-block-unsupported-countries"),
|
||||
EPG_RECENT_CHANNELS("epg-recent-channels"),
|
||||
EXCLUDE_RESTRICTIONS("exclude restrictions"),
|
||||
FEDERATED_AUTH("federated-auth"),
|
||||
FRIEND_REQUEST_PUSH_NOTIFICATIONS("friend_request_push_notifications"),
|
||||
GRANDFATHER_SYNC("grandfather-sync"),
|
||||
GUIDED_UPGRADE("guided-upgrade"),
|
||||
HARDWARE_TRANSCODING("hardware_transcoding"),
|
||||
HOME("home"),
|
||||
HWTRANSCODE("hwtranscode"),
|
||||
IMAGGA_V2("imagga-v2"),
|
||||
INCREASE_PASSWORD_COMPLEXITY("increase-password-complexity"),
|
||||
IOS14_PRIVACY_BANNER("ios14-privacy-banner"),
|
||||
ITERABLE_NOTIFICATION_TOKENS("iterable-notification-tokens"),
|
||||
ITEM_CLUSTERS("item_clusters"),
|
||||
KEEP_PAYMENT_METHOD("keep-payment-method"),
|
||||
KEVIN_BACON("kevin-bacon"),
|
||||
KOREA_CONSENT("korea-consent"),
|
||||
@@ -45,28 +60,49 @@ public enum Features {
|
||||
LIGHTNING_DVR_PIVOT("lightning-dvr-pivot"),
|
||||
LIVE_TV_SUPPORT_INCOMPLETE_SEGMENTS("live-tv-support-incomplete-segments"),
|
||||
LIVETV("livetv"),
|
||||
LYRICS("lyrics"),
|
||||
METADATA_SEARCH("metadata_search"),
|
||||
MUSIC_ANALYSIS("music-analysis"),
|
||||
MUSIC_VIDEOS("music_videos"),
|
||||
NEW_PLEX_PASS_PRICES("new_plex_pass_prices"),
|
||||
NEWS_PROVIDER_SUNSET_MODAL("news-provider-sunset-modal"),
|
||||
NOMINATIM("nominatim"),
|
||||
PASS("pass"),
|
||||
PHOTOS_FAVORITES("photos-favorites"),
|
||||
PHOTOS_METADATA_EDITION("photos-metadata-edition"),
|
||||
PHOTOS_V6_EDIT("photosV6-edit"),
|
||||
PHOTOS_V6_TV_ALBUMS("photosV6-tv-albums"),
|
||||
PMS_HEALTH("pms_health"),
|
||||
PREMIUM_DASHBOARD("premium-dashboard"),
|
||||
PREMIUM_MUSIC_METADATA("premium_music_metadata"),
|
||||
RADIO("radio"),
|
||||
RATE_LIMIT_CLIENT_TOKEN("rate-limit-client-token"),
|
||||
SCROBBLING_SERVICE_PLEX_TV("scrobbling-service-plex-tv"),
|
||||
SESSION_BANDWIDTH_RESTRICTIONS("session_bandwidth_restrictions"),
|
||||
SESSION_KICK("session_kick"),
|
||||
SHARED_SERVER_NOTIFICATION("shared_server_notification"),
|
||||
SHARED_SOURCE_NOTIFICATION("shared_source_notification"),
|
||||
SIGNIN_NOTIFICATION("signin_notification"),
|
||||
SIGNIN_WITH_APPLE("signin_with_apple"),
|
||||
SILENCE_REMOVAL("silence-removal"),
|
||||
SLEEP_TIMER("sleep-timer"),
|
||||
SPRING_SERVE_AD_PROVIDER("spring_serve_ad_provider"),
|
||||
SYNC("sync"),
|
||||
SWEET_FADES("sweet-fades"),
|
||||
TRANSCODER_CACHE("transcoder_cache"),
|
||||
TRAILERS("trailers"),
|
||||
TUNER_SHARING("tuner-sharing"),
|
||||
TWO_FACTOR_AUTHENTICATION("two-factor-authentication"),
|
||||
UNSUPPORTEDTUNERS("unsupportedtuners"),
|
||||
UPGRADE3DS2("upgrade-3ds2"),
|
||||
VISUALIZERS("visualizers"),
|
||||
VOD_SCHEMA("vod-schema"),
|
||||
VOD_CLOUDFLARE("vod_cloudflare"),
|
||||
VOLUME_LEVELING("volume-leveling"),
|
||||
WATCH_TOGETHER_INVITE("watch-together-invite"),
|
||||
WEB_SERVER_DASHBOARD("web_server_dashboard");
|
||||
WATCHLIST_RSS("watchlist-rss"),
|
||||
WEB_SERVER_DASHBOARD("web_server_dashboard"),
|
||||
WEBHOOKS("webhooks");
|
||||
|
||||
@JsonValue
|
||||
private final String value;
|
||||
|
||||
@@ -30,10 +30,7 @@ public class GetPinRequest {
|
||||
private Optional<Boolean> strong;
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
@SpeakeasyMetadata("queryParam:style=form,explode=true,name=X-Plex-Client-Identifier")
|
||||
private Optional<String> clientID;
|
||||
@@ -88,10 +85,7 @@ public class GetPinRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
@JsonIgnore
|
||||
public Optional<String> clientID() {
|
||||
@@ -147,10 +141,7 @@ public class GetPinRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public GetPinRequest withClientID(String clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
@@ -159,10 +150,7 @@ public class GetPinRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public GetPinRequest withClientID(Optional<String> clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
@@ -301,10 +289,7 @@ public class GetPinRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public Builder clientID(String clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
@@ -313,10 +298,7 @@ public class GetPinRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public Builder clientID(Optional<String> clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
|
||||
@@ -40,21 +40,30 @@ public class GetServerResourcesRequest {
|
||||
@SpeakeasyMetadata("queryParam:style=form,explode=true,name=includeIPv6")
|
||||
private Optional<? extends IncludeIPv6> includeIPv6;
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
@SpeakeasyMetadata("queryParam:style=form,explode=true,name=X-Plex-Client-Identifier")
|
||||
private Optional<String> clientID;
|
||||
|
||||
@JsonCreator
|
||||
public GetServerResourcesRequest(
|
||||
Optional<? extends IncludeHttps> includeHttps,
|
||||
Optional<? extends IncludeRelay> includeRelay,
|
||||
Optional<? extends IncludeIPv6> includeIPv6) {
|
||||
Optional<? extends IncludeIPv6> includeIPv6,
|
||||
Optional<String> clientID) {
|
||||
Utils.checkNotNull(includeHttps, "includeHttps");
|
||||
Utils.checkNotNull(includeRelay, "includeRelay");
|
||||
Utils.checkNotNull(includeIPv6, "includeIPv6");
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
this.includeHttps = includeHttps;
|
||||
this.includeRelay = includeRelay;
|
||||
this.includeIPv6 = includeIPv6;
|
||||
this.clientID = clientID;
|
||||
}
|
||||
|
||||
public GetServerResourcesRequest() {
|
||||
this(Optional.empty(), Optional.empty(), Optional.empty());
|
||||
this(Optional.empty(), Optional.empty(), Optional.empty(), Optional.empty());
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -86,6 +95,14 @@ public class GetServerResourcesRequest {
|
||||
return (Optional<IncludeIPv6>) includeIPv6;
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
@JsonIgnore
|
||||
public Optional<String> clientID() {
|
||||
return clientID;
|
||||
}
|
||||
|
||||
public final static Builder builder() {
|
||||
return new Builder();
|
||||
}
|
||||
@@ -148,6 +165,24 @@ public class GetServerResourcesRequest {
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public GetServerResourcesRequest withClientID(String clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
this.clientID = Optional.ofNullable(clientID);
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public GetServerResourcesRequest withClientID(Optional<String> clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
this.clientID = clientID;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean equals(java.lang.Object o) {
|
||||
if (this == o) {
|
||||
@@ -160,7 +195,8 @@ public class GetServerResourcesRequest {
|
||||
return
|
||||
Objects.deepEquals(this.includeHttps, other.includeHttps) &&
|
||||
Objects.deepEquals(this.includeRelay, other.includeRelay) &&
|
||||
Objects.deepEquals(this.includeIPv6, other.includeIPv6);
|
||||
Objects.deepEquals(this.includeIPv6, other.includeIPv6) &&
|
||||
Objects.deepEquals(this.clientID, other.clientID);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -168,7 +204,8 @@ public class GetServerResourcesRequest {
|
||||
return Objects.hash(
|
||||
includeHttps,
|
||||
includeRelay,
|
||||
includeIPv6);
|
||||
includeIPv6,
|
||||
clientID);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -176,7 +213,8 @@ public class GetServerResourcesRequest {
|
||||
return Utils.toString(GetServerResourcesRequest.class,
|
||||
"includeHttps", includeHttps,
|
||||
"includeRelay", includeRelay,
|
||||
"includeIPv6", includeIPv6);
|
||||
"includeIPv6", includeIPv6,
|
||||
"clientID", clientID);
|
||||
}
|
||||
|
||||
public final static class Builder {
|
||||
@@ -187,6 +225,8 @@ public class GetServerResourcesRequest {
|
||||
|
||||
private Optional<? extends IncludeIPv6> includeIPv6;
|
||||
|
||||
private Optional<String> clientID = Optional.empty();
|
||||
|
||||
private Builder() {
|
||||
// force use of static builder() method
|
||||
}
|
||||
@@ -249,6 +289,24 @@ public class GetServerResourcesRequest {
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public Builder clientID(String clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
this.clientID = Optional.ofNullable(clientID);
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public Builder clientID(Optional<String> clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
this.clientID = clientID;
|
||||
return this;
|
||||
}
|
||||
|
||||
public GetServerResourcesRequest build() {
|
||||
if (includeHttps == null) {
|
||||
includeHttps = _SINGLETON_VALUE_IncludeHttps.value();
|
||||
@@ -261,7 +319,8 @@ public class GetServerResourcesRequest {
|
||||
} return new GetServerResourcesRequest(
|
||||
includeHttps,
|
||||
includeRelay,
|
||||
includeIPv6);
|
||||
includeIPv6,
|
||||
clientID);
|
||||
}
|
||||
|
||||
private static final LazySingletonValue<Optional<? extends IncludeHttps>> _SINGLETON_VALUE_IncludeHttps =
|
||||
|
||||
@@ -24,6 +24,7 @@ public class GetServerResourcesRequestBuilder {
|
||||
"includeIPv6",
|
||||
"0",
|
||||
new TypeReference<Optional<? extends IncludeIPv6>>() {});
|
||||
private Optional<String> clientID = Optional.empty();
|
||||
private Optional<String> serverURL = Optional.empty();
|
||||
private final SDKMethodInterfaces.MethodCallGetServerResources sdk;
|
||||
|
||||
@@ -67,6 +68,18 @@ public class GetServerResourcesRequestBuilder {
|
||||
return this;
|
||||
}
|
||||
|
||||
public GetServerResourcesRequestBuilder clientID(String clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
this.clientID = Optional.of(clientID);
|
||||
return this;
|
||||
}
|
||||
|
||||
public GetServerResourcesRequestBuilder clientID(Optional<String> clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
this.clientID = clientID;
|
||||
return this;
|
||||
}
|
||||
|
||||
public GetServerResourcesRequestBuilder serverURL(String serverURL) {
|
||||
Utils.checkNotNull(serverURL, "serverURL");
|
||||
this.serverURL = Optional.of(serverURL);
|
||||
@@ -93,6 +106,7 @@ public class GetServerResourcesRequestBuilder {
|
||||
includeHttps,
|
||||
includeRelay,
|
||||
includeIPv6,
|
||||
clientID,
|
||||
serverURL);
|
||||
}
|
||||
|
||||
|
||||
@@ -25,10 +25,7 @@ public class GetTokenByPinIdRequest {
|
||||
private long pinID;
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
@SpeakeasyMetadata("queryParam:style=form,explode=true,name=X-Plex-Client-Identifier")
|
||||
private Optional<String> clientID;
|
||||
@@ -81,10 +78,7 @@ public class GetTokenByPinIdRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
@JsonIgnore
|
||||
public Optional<String> clientID() {
|
||||
@@ -125,10 +119,7 @@ public class GetTokenByPinIdRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public GetTokenByPinIdRequest withClientID(String clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
@@ -137,10 +128,7 @@ public class GetTokenByPinIdRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public GetTokenByPinIdRequest withClientID(Optional<String> clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
@@ -264,10 +252,7 @@ public class GetTokenByPinIdRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public Builder clientID(String clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
@@ -276,10 +261,7 @@ public class GetTokenByPinIdRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public Builder clientID(Optional<String> clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
|
||||
@@ -15,28 +15,43 @@ public enum GetTokenDetailsFeatures {
|
||||
TREBLE_SHOW_FEATURES("TREBLE-show-features"),
|
||||
AD_COUNTDOWN_TIMER("ad-countdown-timer"),
|
||||
ADAPTIVE_BITRATE("adaptive_bitrate"),
|
||||
ALBUM_TYPES("album-types"),
|
||||
ALLOW_DVR("allow_dvr"),
|
||||
AMAZON_LOOP_DEBUG("amazon-loop-debug"),
|
||||
AVOD_AD_ANALYSIS("avod-ad-analysis"),
|
||||
AVOD_NEW_MEDIA("avod-new-media"),
|
||||
BLACKLIST_GET_SIGNIN("blacklist_get_signin"),
|
||||
BOOST_VOICES("boost-voices"),
|
||||
CAMERA_UPLOAD("camera_upload"),
|
||||
CLIENT_RADIO_STATIONS("client-radio-stations"),
|
||||
CLOUDFLARE_TURNSTILE_REQUIRED("cloudflare-turnstile-required"),
|
||||
CLOUDSYNC("cloudsync"),
|
||||
COLLECTIONS("collections"),
|
||||
COMMENTS_AND_REPLIES_PUSH_NOTIFICATIONS("comments_and_replies_push_notifications"),
|
||||
COMMUNITY_ACCESS_PLEX_TV("community_access_plex_tv"),
|
||||
COMPANIONS_SONOS("companions_sonos"),
|
||||
CONTENT_FILTER("content_filter"),
|
||||
CUSTOM_HOME_REMOVAL("custom-home-removal"),
|
||||
DISABLE_HOME_USER_FRIENDSHIPS("disable_home_user_friendships"),
|
||||
DISABLE_SHARING_FRIENDSHIPS("disable_sharing_friendships"),
|
||||
DOWNLOADS_GATING("downloads-gating"),
|
||||
DRM_SUPPORT("drm_support"),
|
||||
DVR("dvr"),
|
||||
DVR_BLOCK_UNSUPPORTED_COUNTRIES("dvr-block-unsupported-countries"),
|
||||
EPG_RECENT_CHANNELS("epg-recent-channels"),
|
||||
EXCLUDE_RESTRICTIONS("exclude restrictions"),
|
||||
FEDERATED_AUTH("federated-auth"),
|
||||
FRIEND_REQUEST_PUSH_NOTIFICATIONS("friend_request_push_notifications"),
|
||||
GRANDFATHER_SYNC("grandfather-sync"),
|
||||
GUIDED_UPGRADE("guided-upgrade"),
|
||||
HARDWARE_TRANSCODING("hardware_transcoding"),
|
||||
HOME("home"),
|
||||
HWTRANSCODE("hwtranscode"),
|
||||
IMAGGA_V2("imagga-v2"),
|
||||
INCREASE_PASSWORD_COMPLEXITY("increase-password-complexity"),
|
||||
IOS14_PRIVACY_BANNER("ios14-privacy-banner"),
|
||||
ITERABLE_NOTIFICATION_TOKENS("iterable-notification-tokens"),
|
||||
ITEM_CLUSTERS("item_clusters"),
|
||||
KEEP_PAYMENT_METHOD("keep-payment-method"),
|
||||
KEVIN_BACON("kevin-bacon"),
|
||||
KOREA_CONSENT("korea-consent"),
|
||||
@@ -45,28 +60,49 @@ public enum GetTokenDetailsFeatures {
|
||||
LIGHTNING_DVR_PIVOT("lightning-dvr-pivot"),
|
||||
LIVE_TV_SUPPORT_INCOMPLETE_SEGMENTS("live-tv-support-incomplete-segments"),
|
||||
LIVETV("livetv"),
|
||||
LYRICS("lyrics"),
|
||||
METADATA_SEARCH("metadata_search"),
|
||||
MUSIC_ANALYSIS("music-analysis"),
|
||||
MUSIC_VIDEOS("music_videos"),
|
||||
NEW_PLEX_PASS_PRICES("new_plex_pass_prices"),
|
||||
NEWS_PROVIDER_SUNSET_MODAL("news-provider-sunset-modal"),
|
||||
NOMINATIM("nominatim"),
|
||||
PASS("pass"),
|
||||
PHOTOS_FAVORITES("photos-favorites"),
|
||||
PHOTOS_METADATA_EDITION("photos-metadata-edition"),
|
||||
PHOTOS_V6_EDIT("photosV6-edit"),
|
||||
PHOTOS_V6_TV_ALBUMS("photosV6-tv-albums"),
|
||||
PMS_HEALTH("pms_health"),
|
||||
PREMIUM_DASHBOARD("premium-dashboard"),
|
||||
PREMIUM_MUSIC_METADATA("premium_music_metadata"),
|
||||
RADIO("radio"),
|
||||
RATE_LIMIT_CLIENT_TOKEN("rate-limit-client-token"),
|
||||
SCROBBLING_SERVICE_PLEX_TV("scrobbling-service-plex-tv"),
|
||||
SESSION_BANDWIDTH_RESTRICTIONS("session_bandwidth_restrictions"),
|
||||
SESSION_KICK("session_kick"),
|
||||
SHARED_SERVER_NOTIFICATION("shared_server_notification"),
|
||||
SHARED_SOURCE_NOTIFICATION("shared_source_notification"),
|
||||
SIGNIN_NOTIFICATION("signin_notification"),
|
||||
SIGNIN_WITH_APPLE("signin_with_apple"),
|
||||
SILENCE_REMOVAL("silence-removal"),
|
||||
SLEEP_TIMER("sleep-timer"),
|
||||
SPRING_SERVE_AD_PROVIDER("spring_serve_ad_provider"),
|
||||
SYNC("sync"),
|
||||
SWEET_FADES("sweet-fades"),
|
||||
TRANSCODER_CACHE("transcoder_cache"),
|
||||
TRAILERS("trailers"),
|
||||
TUNER_SHARING("tuner-sharing"),
|
||||
TWO_FACTOR_AUTHENTICATION("two-factor-authentication"),
|
||||
UNSUPPORTEDTUNERS("unsupportedtuners"),
|
||||
UPGRADE3DS2("upgrade-3ds2"),
|
||||
VISUALIZERS("visualizers"),
|
||||
VOD_SCHEMA("vod-schema"),
|
||||
VOD_CLOUDFLARE("vod_cloudflare"),
|
||||
VOLUME_LEVELING("volume-leveling"),
|
||||
WATCH_TOGETHER_INVITE("watch-together-invite"),
|
||||
WEB_SERVER_DASHBOARD("web_server_dashboard");
|
||||
WATCHLIST_RSS("watchlist-rss"),
|
||||
WEB_SERVER_DASHBOARD("web_server_dashboard"),
|
||||
WEBHOOKS("webhooks");
|
||||
|
||||
@JsonValue
|
||||
private final String value;
|
||||
|
||||
@@ -15,28 +15,43 @@ public enum PostUsersSignInDataAuthenticationFeatures {
|
||||
TREBLE_SHOW_FEATURES("TREBLE-show-features"),
|
||||
AD_COUNTDOWN_TIMER("ad-countdown-timer"),
|
||||
ADAPTIVE_BITRATE("adaptive_bitrate"),
|
||||
ALBUM_TYPES("album-types"),
|
||||
ALLOW_DVR("allow_dvr"),
|
||||
AMAZON_LOOP_DEBUG("amazon-loop-debug"),
|
||||
AVOD_AD_ANALYSIS("avod-ad-analysis"),
|
||||
AVOD_NEW_MEDIA("avod-new-media"),
|
||||
BLACKLIST_GET_SIGNIN("blacklist_get_signin"),
|
||||
BOOST_VOICES("boost-voices"),
|
||||
CAMERA_UPLOAD("camera_upload"),
|
||||
CLIENT_RADIO_STATIONS("client-radio-stations"),
|
||||
CLOUDFLARE_TURNSTILE_REQUIRED("cloudflare-turnstile-required"),
|
||||
CLOUDSYNC("cloudsync"),
|
||||
COLLECTIONS("collections"),
|
||||
COMMENTS_AND_REPLIES_PUSH_NOTIFICATIONS("comments_and_replies_push_notifications"),
|
||||
COMMUNITY_ACCESS_PLEX_TV("community_access_plex_tv"),
|
||||
COMPANIONS_SONOS("companions_sonos"),
|
||||
CONTENT_FILTER("content_filter"),
|
||||
CUSTOM_HOME_REMOVAL("custom-home-removal"),
|
||||
DISABLE_HOME_USER_FRIENDSHIPS("disable_home_user_friendships"),
|
||||
DISABLE_SHARING_FRIENDSHIPS("disable_sharing_friendships"),
|
||||
DOWNLOADS_GATING("downloads-gating"),
|
||||
DRM_SUPPORT("drm_support"),
|
||||
DVR("dvr"),
|
||||
DVR_BLOCK_UNSUPPORTED_COUNTRIES("dvr-block-unsupported-countries"),
|
||||
EPG_RECENT_CHANNELS("epg-recent-channels"),
|
||||
EXCLUDE_RESTRICTIONS("exclude restrictions"),
|
||||
FEDERATED_AUTH("federated-auth"),
|
||||
FRIEND_REQUEST_PUSH_NOTIFICATIONS("friend_request_push_notifications"),
|
||||
GRANDFATHER_SYNC("grandfather-sync"),
|
||||
GUIDED_UPGRADE("guided-upgrade"),
|
||||
HARDWARE_TRANSCODING("hardware_transcoding"),
|
||||
HOME("home"),
|
||||
HWTRANSCODE("hwtranscode"),
|
||||
IMAGGA_V2("imagga-v2"),
|
||||
INCREASE_PASSWORD_COMPLEXITY("increase-password-complexity"),
|
||||
IOS14_PRIVACY_BANNER("ios14-privacy-banner"),
|
||||
ITERABLE_NOTIFICATION_TOKENS("iterable-notification-tokens"),
|
||||
ITEM_CLUSTERS("item_clusters"),
|
||||
KEEP_PAYMENT_METHOD("keep-payment-method"),
|
||||
KEVIN_BACON("kevin-bacon"),
|
||||
KOREA_CONSENT("korea-consent"),
|
||||
@@ -45,28 +60,49 @@ public enum PostUsersSignInDataAuthenticationFeatures {
|
||||
LIGHTNING_DVR_PIVOT("lightning-dvr-pivot"),
|
||||
LIVE_TV_SUPPORT_INCOMPLETE_SEGMENTS("live-tv-support-incomplete-segments"),
|
||||
LIVETV("livetv"),
|
||||
LYRICS("lyrics"),
|
||||
METADATA_SEARCH("metadata_search"),
|
||||
MUSIC_ANALYSIS("music-analysis"),
|
||||
MUSIC_VIDEOS("music_videos"),
|
||||
NEW_PLEX_PASS_PRICES("new_plex_pass_prices"),
|
||||
NEWS_PROVIDER_SUNSET_MODAL("news-provider-sunset-modal"),
|
||||
NOMINATIM("nominatim"),
|
||||
PASS("pass"),
|
||||
PHOTOS_FAVORITES("photos-favorites"),
|
||||
PHOTOS_METADATA_EDITION("photos-metadata-edition"),
|
||||
PHOTOS_V6_EDIT("photosV6-edit"),
|
||||
PHOTOS_V6_TV_ALBUMS("photosV6-tv-albums"),
|
||||
PMS_HEALTH("pms_health"),
|
||||
PREMIUM_DASHBOARD("premium-dashboard"),
|
||||
PREMIUM_MUSIC_METADATA("premium_music_metadata"),
|
||||
RADIO("radio"),
|
||||
RATE_LIMIT_CLIENT_TOKEN("rate-limit-client-token"),
|
||||
SCROBBLING_SERVICE_PLEX_TV("scrobbling-service-plex-tv"),
|
||||
SESSION_BANDWIDTH_RESTRICTIONS("session_bandwidth_restrictions"),
|
||||
SESSION_KICK("session_kick"),
|
||||
SHARED_SERVER_NOTIFICATION("shared_server_notification"),
|
||||
SHARED_SOURCE_NOTIFICATION("shared_source_notification"),
|
||||
SIGNIN_NOTIFICATION("signin_notification"),
|
||||
SIGNIN_WITH_APPLE("signin_with_apple"),
|
||||
SILENCE_REMOVAL("silence-removal"),
|
||||
SLEEP_TIMER("sleep-timer"),
|
||||
SPRING_SERVE_AD_PROVIDER("spring_serve_ad_provider"),
|
||||
SYNC("sync"),
|
||||
SWEET_FADES("sweet-fades"),
|
||||
TRANSCODER_CACHE("transcoder_cache"),
|
||||
TRAILERS("trailers"),
|
||||
TUNER_SHARING("tuner-sharing"),
|
||||
TWO_FACTOR_AUTHENTICATION("two-factor-authentication"),
|
||||
UNSUPPORTEDTUNERS("unsupportedtuners"),
|
||||
UPGRADE3DS2("upgrade-3ds2"),
|
||||
VISUALIZERS("visualizers"),
|
||||
VOD_SCHEMA("vod-schema"),
|
||||
VOD_CLOUDFLARE("vod_cloudflare"),
|
||||
VOLUME_LEVELING("volume-leveling"),
|
||||
WATCH_TOGETHER_INVITE("watch-together-invite"),
|
||||
WEB_SERVER_DASHBOARD("web_server_dashboard");
|
||||
WATCHLIST_RSS("watchlist-rss"),
|
||||
WEB_SERVER_DASHBOARD("web_server_dashboard"),
|
||||
WEBHOOKS("webhooks");
|
||||
|
||||
@JsonValue
|
||||
private final String value;
|
||||
|
||||
@@ -15,28 +15,43 @@ public enum PostUsersSignInDataFeatures {
|
||||
TREBLE_SHOW_FEATURES("TREBLE-show-features"),
|
||||
AD_COUNTDOWN_TIMER("ad-countdown-timer"),
|
||||
ADAPTIVE_BITRATE("adaptive_bitrate"),
|
||||
ALBUM_TYPES("album-types"),
|
||||
ALLOW_DVR("allow_dvr"),
|
||||
AMAZON_LOOP_DEBUG("amazon-loop-debug"),
|
||||
AVOD_AD_ANALYSIS("avod-ad-analysis"),
|
||||
AVOD_NEW_MEDIA("avod-new-media"),
|
||||
BLACKLIST_GET_SIGNIN("blacklist_get_signin"),
|
||||
BOOST_VOICES("boost-voices"),
|
||||
CAMERA_UPLOAD("camera_upload"),
|
||||
CLIENT_RADIO_STATIONS("client-radio-stations"),
|
||||
CLOUDFLARE_TURNSTILE_REQUIRED("cloudflare-turnstile-required"),
|
||||
CLOUDSYNC("cloudsync"),
|
||||
COLLECTIONS("collections"),
|
||||
COMMENTS_AND_REPLIES_PUSH_NOTIFICATIONS("comments_and_replies_push_notifications"),
|
||||
COMMUNITY_ACCESS_PLEX_TV("community_access_plex_tv"),
|
||||
COMPANIONS_SONOS("companions_sonos"),
|
||||
CONTENT_FILTER("content_filter"),
|
||||
CUSTOM_HOME_REMOVAL("custom-home-removal"),
|
||||
DISABLE_HOME_USER_FRIENDSHIPS("disable_home_user_friendships"),
|
||||
DISABLE_SHARING_FRIENDSHIPS("disable_sharing_friendships"),
|
||||
DOWNLOADS_GATING("downloads-gating"),
|
||||
DRM_SUPPORT("drm_support"),
|
||||
DVR("dvr"),
|
||||
DVR_BLOCK_UNSUPPORTED_COUNTRIES("dvr-block-unsupported-countries"),
|
||||
EPG_RECENT_CHANNELS("epg-recent-channels"),
|
||||
EXCLUDE_RESTRICTIONS("exclude restrictions"),
|
||||
FEDERATED_AUTH("federated-auth"),
|
||||
FRIEND_REQUEST_PUSH_NOTIFICATIONS("friend_request_push_notifications"),
|
||||
GRANDFATHER_SYNC("grandfather-sync"),
|
||||
GUIDED_UPGRADE("guided-upgrade"),
|
||||
HARDWARE_TRANSCODING("hardware_transcoding"),
|
||||
HOME("home"),
|
||||
HWTRANSCODE("hwtranscode"),
|
||||
IMAGGA_V2("imagga-v2"),
|
||||
INCREASE_PASSWORD_COMPLEXITY("increase-password-complexity"),
|
||||
IOS14_PRIVACY_BANNER("ios14-privacy-banner"),
|
||||
ITERABLE_NOTIFICATION_TOKENS("iterable-notification-tokens"),
|
||||
ITEM_CLUSTERS("item_clusters"),
|
||||
KEEP_PAYMENT_METHOD("keep-payment-method"),
|
||||
KEVIN_BACON("kevin-bacon"),
|
||||
KOREA_CONSENT("korea-consent"),
|
||||
@@ -45,28 +60,49 @@ public enum PostUsersSignInDataFeatures {
|
||||
LIGHTNING_DVR_PIVOT("lightning-dvr-pivot"),
|
||||
LIVE_TV_SUPPORT_INCOMPLETE_SEGMENTS("live-tv-support-incomplete-segments"),
|
||||
LIVETV("livetv"),
|
||||
LYRICS("lyrics"),
|
||||
METADATA_SEARCH("metadata_search"),
|
||||
MUSIC_ANALYSIS("music-analysis"),
|
||||
MUSIC_VIDEOS("music_videos"),
|
||||
NEW_PLEX_PASS_PRICES("new_plex_pass_prices"),
|
||||
NEWS_PROVIDER_SUNSET_MODAL("news-provider-sunset-modal"),
|
||||
NOMINATIM("nominatim"),
|
||||
PASS("pass"),
|
||||
PHOTOS_FAVORITES("photos-favorites"),
|
||||
PHOTOS_METADATA_EDITION("photos-metadata-edition"),
|
||||
PHOTOS_V6_EDIT("photosV6-edit"),
|
||||
PHOTOS_V6_TV_ALBUMS("photosV6-tv-albums"),
|
||||
PMS_HEALTH("pms_health"),
|
||||
PREMIUM_DASHBOARD("premium-dashboard"),
|
||||
PREMIUM_MUSIC_METADATA("premium_music_metadata"),
|
||||
RADIO("radio"),
|
||||
RATE_LIMIT_CLIENT_TOKEN("rate-limit-client-token"),
|
||||
SCROBBLING_SERVICE_PLEX_TV("scrobbling-service-plex-tv"),
|
||||
SESSION_BANDWIDTH_RESTRICTIONS("session_bandwidth_restrictions"),
|
||||
SESSION_KICK("session_kick"),
|
||||
SHARED_SERVER_NOTIFICATION("shared_server_notification"),
|
||||
SHARED_SOURCE_NOTIFICATION("shared_source_notification"),
|
||||
SIGNIN_NOTIFICATION("signin_notification"),
|
||||
SIGNIN_WITH_APPLE("signin_with_apple"),
|
||||
SILENCE_REMOVAL("silence-removal"),
|
||||
SLEEP_TIMER("sleep-timer"),
|
||||
SPRING_SERVE_AD_PROVIDER("spring_serve_ad_provider"),
|
||||
SYNC("sync"),
|
||||
SWEET_FADES("sweet-fades"),
|
||||
TRANSCODER_CACHE("transcoder_cache"),
|
||||
TRAILERS("trailers"),
|
||||
TUNER_SHARING("tuner-sharing"),
|
||||
TWO_FACTOR_AUTHENTICATION("two-factor-authentication"),
|
||||
UNSUPPORTEDTUNERS("unsupportedtuners"),
|
||||
UPGRADE3DS2("upgrade-3ds2"),
|
||||
VISUALIZERS("visualizers"),
|
||||
VOD_SCHEMA("vod-schema"),
|
||||
VOD_CLOUDFLARE("vod_cloudflare"),
|
||||
VOLUME_LEVELING("volume-leveling"),
|
||||
WATCH_TOGETHER_INVITE("watch-together-invite"),
|
||||
WEB_SERVER_DASHBOARD("web_server_dashboard");
|
||||
WATCHLIST_RSS("watchlist-rss"),
|
||||
WEB_SERVER_DASHBOARD("web_server_dashboard"),
|
||||
WEBHOOKS("webhooks");
|
||||
|
||||
@JsonValue
|
||||
private final String value;
|
||||
|
||||
@@ -19,10 +19,7 @@ import java.util.Optional;
|
||||
public class PostUsersSignInDataRequest {
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
@SpeakeasyMetadata("queryParam:style=form,explode=true,name=X-Plex-Client-Identifier")
|
||||
private Optional<String> clientID;
|
||||
@@ -72,10 +69,7 @@ public class PostUsersSignInDataRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
@JsonIgnore
|
||||
public Optional<String> clientID() {
|
||||
@@ -116,10 +110,7 @@ public class PostUsersSignInDataRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public PostUsersSignInDataRequest withClientID(String clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
@@ -128,10 +119,7 @@ public class PostUsersSignInDataRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public PostUsersSignInDataRequest withClientID(Optional<String> clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
@@ -264,10 +252,7 @@ public class PostUsersSignInDataRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public Builder clientID(String clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
@@ -276,10 +261,7 @@ public class PostUsersSignInDataRequest {
|
||||
}
|
||||
|
||||
/**
|
||||
* The unique identifier for the client application
|
||||
* This is used to track the client application and its usage
|
||||
* (UUID, serial number, or other number unique per device)
|
||||
*
|
||||
* The unique identifier for the client application. This is used to track the client application and its usage. (UUID, serial number, or other number unique per device)
|
||||
*/
|
||||
public Builder clientID(Optional<String> clientID) {
|
||||
Utils.checkNotNull(clientID, "clientID");
|
||||
|
||||
@@ -170,6 +170,7 @@ public class SDKMethodInterfaces {
|
||||
Optional<? extends IncludeHttps> includeHttps,
|
||||
Optional<? extends IncludeRelay> includeRelay,
|
||||
Optional<? extends IncludeIPv6> includeIPv6,
|
||||
Optional<String> clientID,
|
||||
Optional<String> serverURL) throws Exception;
|
||||
}
|
||||
|
||||
|
||||
@@ -1,56 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.CancelServerActivitiesResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetServerActivitiesResponse;
|
||||
import java.lang.Exception;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class ActivitiesTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testActivities_GetServerActivities() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetServerActivitiesResponse res = sdk.activities().getServerActivities()
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testActivities_CancelServerActivities_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
CancelServerActivitiesResponse res = sdk.activities().cancelServerActivities()
|
||||
.activityUUID("25b71ed5-0f9d-461c-baa7-d404e9e10d3e")
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,441 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.AutoSelectSubtitle;
|
||||
import dev.plexapi.sdk.models.operations.Billing;
|
||||
import dev.plexapi.sdk.models.operations.DefaultSubtitleAccessibility;
|
||||
import dev.plexapi.sdk.models.operations.DefaultSubtitleForced;
|
||||
import dev.plexapi.sdk.models.operations.GetSourceConnectionInformationResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetTokenDetailsAuthenticationResponseStatus;
|
||||
import dev.plexapi.sdk.models.operations.GetTokenDetailsAuthenticationStatus;
|
||||
import dev.plexapi.sdk.models.operations.GetTokenDetailsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetTokenDetailsStatus;
|
||||
import dev.plexapi.sdk.models.operations.GetTokenDetailsSubscription;
|
||||
import dev.plexapi.sdk.models.operations.GetTokenDetailsUserPlexAccount;
|
||||
import dev.plexapi.sdk.models.operations.GetTransientTokenQueryParamType;
|
||||
import dev.plexapi.sdk.models.operations.GetTransientTokenResponse;
|
||||
import dev.plexapi.sdk.models.operations.InternalPaymentMethod;
|
||||
import dev.plexapi.sdk.models.operations.MailingListStatus;
|
||||
import dev.plexapi.sdk.models.operations.MediaReviewsVisibility;
|
||||
import dev.plexapi.sdk.models.operations.PastSubscription;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataAuthenticationResponseStatus;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataAuthenticationStatus;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataAuthenticationSubscription;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataAutoSelectSubtitle;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataDefaultSubtitleAccessibility;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataDefaultSubtitleForced;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataMailingListStatus;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataMediaReviewsVisibility;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataRequest;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataRequestBody;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataResponse;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataServices;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataState;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataStatus;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataSubscription;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataUserPlexAccount;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataUserProfile;
|
||||
import dev.plexapi.sdk.models.operations.PostUsersSignInDataWatchedIndicator;
|
||||
import dev.plexapi.sdk.models.operations.Scope;
|
||||
import dev.plexapi.sdk.models.operations.Services;
|
||||
import dev.plexapi.sdk.models.operations.Subscription;
|
||||
import dev.plexapi.sdk.models.operations.Trials;
|
||||
import dev.plexapi.sdk.models.operations.UserProfile;
|
||||
import dev.plexapi.sdk.models.operations.WatchedIndicator;
|
||||
import java.lang.Exception;
|
||||
import java.time.OffsetDateTime;
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class AuthenticationTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testAuthentication_GetTransientToken() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetTransientTokenResponse res = sdk.authentication().getTransientToken()
|
||||
.type(GetTransientTokenQueryParamType.DELEGATION)
|
||||
.scope(Scope.ALL)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testAuthentication_GetSourceConnectionInformation() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetSourceConnectionInformationResponse res = sdk.authentication().getSourceConnectionInformation()
|
||||
.source("server://client-identifier")
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testAuthentication_GetTokenDetails() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetTokenDetailsResponse res = sdk.authentication().getTokenDetails()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetTokenDetailsUserPlexAccount.builder()
|
||||
.adsConsent(false)
|
||||
.adsConsentReminderAt(OffsetDateTime.parse("2022-06-24T05:32:09.341Z"))
|
||||
.adsConsentSetAt(OffsetDateTime.parse("2022-05-01T23:18:27.767Z"))
|
||||
.authToken("CxoUzBTSV5hsxjTpFKaf")
|
||||
.country("US")
|
||||
.email("username@email.com")
|
||||
.friendlyName("friendlyUsername")
|
||||
.entitlements(List.of(
|
||||
"[]"))
|
||||
.homeSize(1)
|
||||
.id(13692262)
|
||||
.joinedAt(1556281940L)
|
||||
.locale("sv")
|
||||
.mailingListStatus(MailingListStatus.ACTIVE)
|
||||
.maxHomeSize(15)
|
||||
.profile(UserProfile.builder()
|
||||
.defaultAudioLanguage("ja")
|
||||
.defaultSubtitleLanguage("en")
|
||||
.autoSelectAudio(true)
|
||||
.autoSelectSubtitle(AutoSelectSubtitle.Enable)
|
||||
.defaultSubtitleAccessibility(DefaultSubtitleAccessibility.Enable)
|
||||
.defaultSubtitleForced(DefaultSubtitleForced.Enable)
|
||||
.watchedIndicator(WatchedIndicator.Enable)
|
||||
.mediaReviewsVisibility(MediaReviewsVisibility.Enable)
|
||||
.build())
|
||||
.rememberExpiresAt(1556281940L)
|
||||
.scrobbleTypes("<value>")
|
||||
.services(List.of(
|
||||
Services.builder()
|
||||
.identifier("metadata-dev")
|
||||
.endpoint("https://epg.provider.plex.tv")
|
||||
.token("DjoMtqFAGRL1uVtCyF1dKIorTbShJeqv")
|
||||
.secret("<value>")
|
||||
.status(GetTokenDetailsStatus.ONLINE)
|
||||
.build()))
|
||||
.subscription(Subscription.builder()
|
||||
.active(true)
|
||||
.subscribedAt("2021-04-12T18:21:12Z")
|
||||
.status(GetTokenDetailsAuthenticationStatus.INACTIVE)
|
||||
.build())
|
||||
.subscriptionDescription("<value>")
|
||||
.subscriptions(List.of(
|
||||
GetTokenDetailsSubscription.builder()
|
||||
.active(true)
|
||||
.subscribedAt("2021-04-12T18:21:12Z")
|
||||
.status(GetTokenDetailsAuthenticationResponseStatus.INACTIVE)
|
||||
.build()))
|
||||
.thumb("https://plex.tv/users/a4f43c1ebfde43a5/avatar?c=8372075101")
|
||||
.title("UsernameTitle")
|
||||
.username("Username")
|
||||
.uuid("dae343c1f45beb4f")
|
||||
.attributionPartner(Optional.empty())
|
||||
.anonymous(false)
|
||||
.backupCodesCreated(false)
|
||||
.confirmed(false)
|
||||
.emailOnlyAuth(false)
|
||||
.experimentalFeatures(false)
|
||||
.guest(false)
|
||||
.hasPassword(true)
|
||||
.home(false)
|
||||
.homeAdmin(false)
|
||||
.mailingListActive(false)
|
||||
.pin("string")
|
||||
.protected_(false)
|
||||
.restricted(false)
|
||||
.roles(List.of(
|
||||
"string"))
|
||||
.twoFactorEnabled(false)
|
||||
.build(),
|
||||
res.userPlexAccount().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testAuthentication_PostUsersSignInData() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
PostUsersSignInDataRequest req = PostUsersSignInDataRequest.builder()
|
||||
.requestBody(PostUsersSignInDataRequestBody.builder()
|
||||
.login("username@email.com")
|
||||
.password("password123")
|
||||
.verificationCode("123456")
|
||||
.build())
|
||||
.build();
|
||||
|
||||
PostUsersSignInDataResponse res = sdk.authentication().postUsersSignInData()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
PostUsersSignInDataUserPlexAccount.builder()
|
||||
.adsConsent(false)
|
||||
.adsConsentReminderAt(OffsetDateTime.parse("2022-06-01T10:45:51.668Z"))
|
||||
.adsConsentSetAt(OffsetDateTime.parse("2022-08-04T10:54:08.790Z"))
|
||||
.authToken("CxoUzBTSV5hsxjTpFKaf")
|
||||
.country("US")
|
||||
.email("username@email.com")
|
||||
.friendlyName("friendlyUsername")
|
||||
.entitlements(List.of(
|
||||
"[]"))
|
||||
.homeSize(1)
|
||||
.id(13692262)
|
||||
.joinedAt(1556281940L)
|
||||
.locale("ja")
|
||||
.mailingListStatus(PostUsersSignInDataMailingListStatus.ACTIVE)
|
||||
.maxHomeSize(15)
|
||||
.profile(PostUsersSignInDataUserProfile.builder()
|
||||
.defaultAudioLanguage("ja")
|
||||
.defaultSubtitleLanguage("en")
|
||||
.autoSelectAudio(true)
|
||||
.autoSelectSubtitle(PostUsersSignInDataAutoSelectSubtitle.Enable)
|
||||
.defaultSubtitleAccessibility(PostUsersSignInDataDefaultSubtitleAccessibility.Enable)
|
||||
.defaultSubtitleForced(PostUsersSignInDataDefaultSubtitleForced.Enable)
|
||||
.watchedIndicator(PostUsersSignInDataWatchedIndicator.Enable)
|
||||
.mediaReviewsVisibility(PostUsersSignInDataMediaReviewsVisibility.Enable)
|
||||
.build())
|
||||
.rememberExpiresAt(1556281940L)
|
||||
.scrobbleTypes("<value>")
|
||||
.services(List.of(
|
||||
PostUsersSignInDataServices.builder()
|
||||
.identifier("metadata-dev")
|
||||
.endpoint("https://epg.provider.plex.tv")
|
||||
.token("DjoMtqFAGRL1uVtCyF1dKIorTbShJeqv")
|
||||
.secret("<value>")
|
||||
.status(PostUsersSignInDataStatus.ONLINE)
|
||||
.build()))
|
||||
.subscription(PostUsersSignInDataSubscription.builder()
|
||||
.active(true)
|
||||
.subscribedAt("2021-04-12T18:21:12Z")
|
||||
.status(PostUsersSignInDataAuthenticationStatus.INACTIVE)
|
||||
.build())
|
||||
.subscriptionDescription("<value>")
|
||||
.subscriptions(List.of(
|
||||
PostUsersSignInDataAuthenticationSubscription.builder()
|
||||
.active(true)
|
||||
.subscribedAt("2021-04-12T18:21:12Z")
|
||||
.status(PostUsersSignInDataAuthenticationResponseStatus.INACTIVE)
|
||||
.build()))
|
||||
.thumb("https://plex.tv/users/a4f43c1ebfde43a5/avatar?c=8372075101")
|
||||
.title("UsernameTitle")
|
||||
.username("Username")
|
||||
.uuid("dae343c1f45beb4f")
|
||||
.attributionPartner(Optional.empty())
|
||||
.pastSubscriptions(List.of(
|
||||
PastSubscription.builder()
|
||||
.id("<id>")
|
||||
.mode("<value>")
|
||||
.renewsAt(1556281940L)
|
||||
.endsAt(1556281940L)
|
||||
.type("plexpass")
|
||||
.transfer("<value>")
|
||||
.state(PostUsersSignInDataState.ENDED)
|
||||
.billing(Billing.builder()
|
||||
.internalPaymentMethod(InternalPaymentMethod.builder()
|
||||
.build())
|
||||
.paymentMethodId(820994L)
|
||||
.build())
|
||||
.canceled(false)
|
||||
.gracePeriod(false)
|
||||
.onHold(false)
|
||||
.canReactivate(false)
|
||||
.canUpgrade(false)
|
||||
.canDowngrade(false)
|
||||
.canConvert(false)
|
||||
.build()))
|
||||
.trials(List.of(
|
||||
Trials.builder()
|
||||
.build()))
|
||||
.anonymous(false)
|
||||
.backupCodesCreated(false)
|
||||
.confirmed(false)
|
||||
.emailOnlyAuth(false)
|
||||
.experimentalFeatures(false)
|
||||
.guest(false)
|
||||
.hasPassword(true)
|
||||
.home(false)
|
||||
.homeAdmin(false)
|
||||
.mailingListActive(false)
|
||||
.pin("string")
|
||||
.protected_(false)
|
||||
.restricted(false)
|
||||
.roles(List.of(
|
||||
"string"))
|
||||
.twoFactorEnabled(false)
|
||||
.build(),
|
||||
res.userPlexAccount().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testAuthentication_PostUsersSignInData_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
PostUsersSignInDataRequest req = PostUsersSignInDataRequest.builder()
|
||||
.requestBody(PostUsersSignInDataRequestBody.builder()
|
||||
.login("username@email.com")
|
||||
.password("password123")
|
||||
.verificationCode("123456")
|
||||
.build())
|
||||
.build();
|
||||
|
||||
PostUsersSignInDataResponse res = sdk.authentication().postUsersSignInData()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
PostUsersSignInDataUserPlexAccount.builder()
|
||||
.adsConsent(false)
|
||||
.adsConsentReminderAt(OffsetDateTime.parse("2022-04-17T10:09:07.050Z"))
|
||||
.adsConsentSetAt(OffsetDateTime.parse("2024-07-07T09:18:10.249Z"))
|
||||
.authToken("CxoUzBTSV5hsxjTpFKaf")
|
||||
.country("US")
|
||||
.email("username@email.com")
|
||||
.friendlyName("friendlyUsername")
|
||||
.entitlements(List.of(
|
||||
"[]"))
|
||||
.homeSize(1)
|
||||
.id(13692262)
|
||||
.joinedAt(1556281940L)
|
||||
.locale("es")
|
||||
.mailingListStatus(PostUsersSignInDataMailingListStatus.ACTIVE)
|
||||
.maxHomeSize(15)
|
||||
.profile(PostUsersSignInDataUserProfile.builder()
|
||||
.defaultAudioLanguage("ja")
|
||||
.defaultSubtitleLanguage("en")
|
||||
.autoSelectAudio(true)
|
||||
.autoSelectSubtitle(PostUsersSignInDataAutoSelectSubtitle.Enable)
|
||||
.defaultSubtitleAccessibility(PostUsersSignInDataDefaultSubtitleAccessibility.Enable)
|
||||
.defaultSubtitleForced(PostUsersSignInDataDefaultSubtitleForced.Enable)
|
||||
.watchedIndicator(PostUsersSignInDataWatchedIndicator.Enable)
|
||||
.mediaReviewsVisibility(PostUsersSignInDataMediaReviewsVisibility.Enable)
|
||||
.build())
|
||||
.rememberExpiresAt(1556281940L)
|
||||
.scrobbleTypes("<value>")
|
||||
.services(List.of(
|
||||
PostUsersSignInDataServices.builder()
|
||||
.identifier("metadata-dev")
|
||||
.endpoint("https://epg.provider.plex.tv")
|
||||
.token("DjoMtqFAGRL1uVtCyF1dKIorTbShJeqv")
|
||||
.secret("<value>")
|
||||
.status(PostUsersSignInDataStatus.ONLINE)
|
||||
.build()))
|
||||
.subscription(PostUsersSignInDataSubscription.builder()
|
||||
.active(true)
|
||||
.subscribedAt("2021-04-12T18:21:12Z")
|
||||
.status(PostUsersSignInDataAuthenticationStatus.INACTIVE)
|
||||
.build())
|
||||
.subscriptionDescription("<value>")
|
||||
.subscriptions(List.of(
|
||||
PostUsersSignInDataAuthenticationSubscription.builder()
|
||||
.active(true)
|
||||
.subscribedAt("2021-04-12T18:21:12Z")
|
||||
.status(PostUsersSignInDataAuthenticationResponseStatus.INACTIVE)
|
||||
.build()))
|
||||
.thumb("https://plex.tv/users/a4f43c1ebfde43a5/avatar?c=8372075101")
|
||||
.title("UsernameTitle")
|
||||
.username("Username")
|
||||
.uuid("dae343c1f45beb4f")
|
||||
.attributionPartner(Optional.empty())
|
||||
.pastSubscriptions(List.of(
|
||||
PastSubscription.builder()
|
||||
.id("<id>")
|
||||
.mode("<value>")
|
||||
.renewsAt(1556281940L)
|
||||
.endsAt(1556281940L)
|
||||
.type("plexpass")
|
||||
.transfer("<value>")
|
||||
.state(PostUsersSignInDataState.ENDED)
|
||||
.billing(Billing.builder()
|
||||
.internalPaymentMethod(InternalPaymentMethod.builder()
|
||||
.build())
|
||||
.paymentMethodId(976460L)
|
||||
.build())
|
||||
.canceled(false)
|
||||
.gracePeriod(false)
|
||||
.onHold(false)
|
||||
.canReactivate(false)
|
||||
.canUpgrade(false)
|
||||
.canDowngrade(false)
|
||||
.canConvert(false)
|
||||
.build()))
|
||||
.trials(List.of(
|
||||
Trials.builder()
|
||||
.build()))
|
||||
.anonymous(false)
|
||||
.backupCodesCreated(false)
|
||||
.confirmed(false)
|
||||
.emailOnlyAuth(false)
|
||||
.experimentalFeatures(false)
|
||||
.guest(false)
|
||||
.hasPassword(true)
|
||||
.home(false)
|
||||
.homeAdmin(false)
|
||||
.mailingListActive(false)
|
||||
.pin("string")
|
||||
.protected_(false)
|
||||
.restricted(false)
|
||||
.roles(List.of(
|
||||
"string"))
|
||||
.twoFactorEnabled(false)
|
||||
.build(),
|
||||
res.userPlexAccount().get());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,140 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.ButlerTask;
|
||||
import dev.plexapi.sdk.models.operations.ButlerTasks;
|
||||
import dev.plexapi.sdk.models.operations.GetButlerTasksResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetButlerTasksResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.PathParamTaskName;
|
||||
import dev.plexapi.sdk.models.operations.StartAllTasksResponse;
|
||||
import dev.plexapi.sdk.models.operations.StartTaskResponse;
|
||||
import dev.plexapi.sdk.models.operations.StopAllTasksResponse;
|
||||
import dev.plexapi.sdk.models.operations.StopTaskResponse;
|
||||
import dev.plexapi.sdk.models.operations.TaskName;
|
||||
import java.lang.Exception;
|
||||
import java.util.List;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class ButlerTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testButler_GetButlerTasks() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetButlerTasksResponse res = sdk.butler().getButlerTasks()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetButlerTasksResponseBody.builder()
|
||||
.butlerTasks(ButlerTasks.builder()
|
||||
.butlerTask(List.of(
|
||||
ButlerTask.builder()
|
||||
.name("BackupDatabase")
|
||||
.interval(3d)
|
||||
.title("Backup Database")
|
||||
.description("Create a backup copy of the server's database in the configured backup directory")
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testButler_StartAllTasks() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
StartAllTasksResponse res = sdk.butler().startAllTasks()
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testButler_StopAllTasks() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
StopAllTasksResponse res = sdk.butler().stopAllTasks()
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testButler_StartTask() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
StartTaskResponse res = sdk.butler().startTask()
|
||||
.taskName(TaskName.GENERATE_CHAPTER_THUMBS)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testButler_StopTask() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
StopTaskResponse res = sdk.butler().stopTask()
|
||||
.taskName(PathParamTaskName.DEEP_MEDIA_ANALYSIS)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,761 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.Collection;
|
||||
import dev.plexapi.sdk.models.operations.Country;
|
||||
import dev.plexapi.sdk.models.operations.Director;
|
||||
import dev.plexapi.sdk.models.operations.FlattenSeasons;
|
||||
import dev.plexapi.sdk.models.operations.Genre;
|
||||
import dev.plexapi.sdk.models.operations.GetGlobalHubsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetGlobalHubsMetadata;
|
||||
import dev.plexapi.sdk.models.operations.GetGlobalHubsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetGlobalHubsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsCountry;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsDirector;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsGenre;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsHub;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsMedia;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsMetadata;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsPart;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsRole;
|
||||
import dev.plexapi.sdk.models.operations.GetLibraryHubsWriter;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedActiveDirection;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedDefaultDirection;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedField;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedFieldType;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedFilter;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedHubsResponseType;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedHubsType;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedImage;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedMetadata;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedOperator;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedRequest;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedSort;
|
||||
import dev.plexapi.sdk.models.operations.GetRecentlyAddedType;
|
||||
import dev.plexapi.sdk.models.operations.HasThumbnail;
|
||||
import dev.plexapi.sdk.models.operations.Hub;
|
||||
import dev.plexapi.sdk.models.operations.IncludeMeta;
|
||||
import dev.plexapi.sdk.models.operations.Media;
|
||||
import dev.plexapi.sdk.models.operations.MediaGuid;
|
||||
import dev.plexapi.sdk.models.operations.Meta;
|
||||
import dev.plexapi.sdk.models.operations.MetaDataRating;
|
||||
import dev.plexapi.sdk.models.operations.OnlyTransient;
|
||||
import dev.plexapi.sdk.models.operations.OptimizedForStreaming;
|
||||
import dev.plexapi.sdk.models.operations.Part;
|
||||
import dev.plexapi.sdk.models.operations.QueryParamOnlyTransient;
|
||||
import dev.plexapi.sdk.models.operations.Role;
|
||||
import dev.plexapi.sdk.models.operations.ShowOrdering;
|
||||
import dev.plexapi.sdk.models.operations.Stream;
|
||||
import dev.plexapi.sdk.models.operations.Type;
|
||||
import dev.plexapi.sdk.models.operations.UltraBlurColors;
|
||||
import dev.plexapi.sdk.models.operations.Writer;
|
||||
import java.lang.Exception;
|
||||
import java.time.LocalDate;
|
||||
import java.util.List;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class HubsTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testHubs_GetGlobalHubs() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetGlobalHubsResponse res = sdk.hubs().getGlobalHubs()
|
||||
.count(6399.21d)
|
||||
.onlyTransient(OnlyTransient.ZERO)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetGlobalHubsResponseBody.builder()
|
||||
.mediaContainer(GetGlobalHubsMediaContainer.builder()
|
||||
.size(8)
|
||||
.allowSync(true)
|
||||
.identifier("com.plexapp.plugins.library")
|
||||
.hub(List.of(
|
||||
Hub.builder()
|
||||
.hubKey("/library/metadata/50768,65523,58188,57341,57302,57070")
|
||||
.key("/playlists/all?type=15&sort=lastViewedAt:desc&playlistType=video,audio")
|
||||
.title("Recent Playlists")
|
||||
.type("playlist")
|
||||
.hubIdentifier("home.playlists")
|
||||
.context("hub.home.playlists")
|
||||
.size(6)
|
||||
.more(true)
|
||||
.style("shelf")
|
||||
.promoted(true)
|
||||
.metadata(List.of(
|
||||
GetGlobalHubsMetadata.builder()
|
||||
.ratingKey("57070")
|
||||
.key("/playlists/57070/items")
|
||||
.guid("com.plexapp.agents.none://9fee6c5b-3143-4923-813e-57bd0190056c")
|
||||
.type("playlist")
|
||||
.title("November Movie Day")
|
||||
.titleSort("Tracks")
|
||||
.summary("")
|
||||
.smart(false)
|
||||
.playlistType("video")
|
||||
.composite("/playlists/57070/composite/1668787730")
|
||||
.icon("playlist://image.smart")
|
||||
.viewCount(2)
|
||||
.lastViewedAt(1668787732)
|
||||
.duration(16873000)
|
||||
.leafCount(3)
|
||||
.addedAt(1668779618)
|
||||
.updatedAt(1668787730)
|
||||
.build()))
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testHubs_GetRecentlyAdded() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetRecentlyAddedRequest req = GetRecentlyAddedRequest.builder()
|
||||
.contentDirectoryID(944669L)
|
||||
.type(Type.TvShow)
|
||||
.sectionID(2L)
|
||||
.includeMeta(IncludeMeta.Enable)
|
||||
.xPlexContainerStart(0)
|
||||
.xPlexContainerSize(50)
|
||||
.build();
|
||||
|
||||
GetRecentlyAddedResponse res = sdk.hubs().getRecentlyAdded()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetRecentlyAddedResponseBody.builder()
|
||||
.mediaContainer(GetRecentlyAddedMediaContainer.builder()
|
||||
.size(50d)
|
||||
.identifier("com.plexapp.plugins.library")
|
||||
.meta(Meta.builder()
|
||||
.type(List.of(
|
||||
GetRecentlyAddedType.builder()
|
||||
.key("/library/sections/2/all?type=2")
|
||||
.type("show")
|
||||
.title("TV Shows")
|
||||
.active(false)
|
||||
.filter(List.of(
|
||||
GetRecentlyAddedFilter.builder()
|
||||
.filter("genre")
|
||||
.filterType("string")
|
||||
.key("/library/sections/2/genre?type=2")
|
||||
.title("Genre")
|
||||
.type("filter")
|
||||
.build(),
|
||||
GetRecentlyAddedFilter.builder()
|
||||
.filter("genre")
|
||||
.filterType("string")
|
||||
.key("/library/sections/2/genre?type=2")
|
||||
.title("Genre")
|
||||
.type("filter")
|
||||
.build(),
|
||||
GetRecentlyAddedFilter.builder()
|
||||
.filter("genre")
|
||||
.filterType("string")
|
||||
.key("/library/sections/2/genre?type=2")
|
||||
.title("Genre")
|
||||
.type("filter")
|
||||
.build()))
|
||||
.sort(List.of(
|
||||
GetRecentlyAddedSort.builder()
|
||||
.key("titleSort")
|
||||
.title("Title")
|
||||
.default_("asc")
|
||||
.active(false)
|
||||
.activeDirection(GetRecentlyAddedActiveDirection.Ascending)
|
||||
.defaultDirection(GetRecentlyAddedDefaultDirection.Ascending)
|
||||
.descKey("titleSort:desc")
|
||||
.firstCharacterKey("/library/sections/2/firstCharacter")
|
||||
.build()))
|
||||
.field(List.of(
|
||||
GetRecentlyAddedField.builder()
|
||||
.key("show.title")
|
||||
.title("Show Title")
|
||||
.type("string")
|
||||
.subType("rating")
|
||||
.build(),
|
||||
GetRecentlyAddedField.builder()
|
||||
.key("show.title")
|
||||
.title("Show Title")
|
||||
.type("string")
|
||||
.subType("rating")
|
||||
.build(),
|
||||
GetRecentlyAddedField.builder()
|
||||
.key("show.title")
|
||||
.title("Show Title")
|
||||
.type("string")
|
||||
.subType("rating")
|
||||
.build()))
|
||||
.build(),
|
||||
GetRecentlyAddedType.builder()
|
||||
.key("/library/sections/2/all?type=2")
|
||||
.type("show")
|
||||
.title("TV Shows")
|
||||
.active(false)
|
||||
.filter(List.of(
|
||||
GetRecentlyAddedFilter.builder()
|
||||
.filter("genre")
|
||||
.filterType("string")
|
||||
.key("/library/sections/2/genre?type=2")
|
||||
.title("Genre")
|
||||
.type("filter")
|
||||
.build(),
|
||||
GetRecentlyAddedFilter.builder()
|
||||
.filter("genre")
|
||||
.filterType("string")
|
||||
.key("/library/sections/2/genre?type=2")
|
||||
.title("Genre")
|
||||
.type("filter")
|
||||
.build(),
|
||||
GetRecentlyAddedFilter.builder()
|
||||
.filter("genre")
|
||||
.filterType("string")
|
||||
.key("/library/sections/2/genre?type=2")
|
||||
.title("Genre")
|
||||
.type("filter")
|
||||
.build()))
|
||||
.sort(List.of(
|
||||
GetRecentlyAddedSort.builder()
|
||||
.key("titleSort")
|
||||
.title("Title")
|
||||
.default_("asc")
|
||||
.active(false)
|
||||
.activeDirection(GetRecentlyAddedActiveDirection.Ascending)
|
||||
.defaultDirection(GetRecentlyAddedDefaultDirection.Ascending)
|
||||
.descKey("titleSort:desc")
|
||||
.firstCharacterKey("/library/sections/2/firstCharacter")
|
||||
.build(),
|
||||
GetRecentlyAddedSort.builder()
|
||||
.key("titleSort")
|
||||
.title("Title")
|
||||
.default_("asc")
|
||||
.active(false)
|
||||
.activeDirection(GetRecentlyAddedActiveDirection.Ascending)
|
||||
.defaultDirection(GetRecentlyAddedDefaultDirection.Ascending)
|
||||
.descKey("titleSort:desc")
|
||||
.firstCharacterKey("/library/sections/2/firstCharacter")
|
||||
.build(),
|
||||
GetRecentlyAddedSort.builder()
|
||||
.key("titleSort")
|
||||
.title("Title")
|
||||
.default_("asc")
|
||||
.active(false)
|
||||
.activeDirection(GetRecentlyAddedActiveDirection.Ascending)
|
||||
.defaultDirection(GetRecentlyAddedDefaultDirection.Ascending)
|
||||
.descKey("titleSort:desc")
|
||||
.firstCharacterKey("/library/sections/2/firstCharacter")
|
||||
.build()))
|
||||
.field(List.of(
|
||||
GetRecentlyAddedField.builder()
|
||||
.key("show.title")
|
||||
.title("Show Title")
|
||||
.type("string")
|
||||
.subType("rating")
|
||||
.build(),
|
||||
GetRecentlyAddedField.builder()
|
||||
.key("show.title")
|
||||
.title("Show Title")
|
||||
.type("string")
|
||||
.subType("rating")
|
||||
.build(),
|
||||
GetRecentlyAddedField.builder()
|
||||
.key("show.title")
|
||||
.title("Show Title")
|
||||
.type("string")
|
||||
.subType("rating")
|
||||
.build()))
|
||||
.build(),
|
||||
GetRecentlyAddedType.builder()
|
||||
.key("/library/sections/2/all?type=2")
|
||||
.type("show")
|
||||
.title("TV Shows")
|
||||
.active(false)
|
||||
.filter(List.of(
|
||||
GetRecentlyAddedFilter.builder()
|
||||
.filter("genre")
|
||||
.filterType("string")
|
||||
.key("/library/sections/2/genre?type=2")
|
||||
.title("Genre")
|
||||
.type("filter")
|
||||
.build(),
|
||||
GetRecentlyAddedFilter.builder()
|
||||
.filter("genre")
|
||||
.filterType("string")
|
||||
.key("/library/sections/2/genre?type=2")
|
||||
.title("Genre")
|
||||
.type("filter")
|
||||
.build(),
|
||||
GetRecentlyAddedFilter.builder()
|
||||
.filter("genre")
|
||||
.filterType("string")
|
||||
.key("/library/sections/2/genre?type=2")
|
||||
.title("Genre")
|
||||
.type("filter")
|
||||
.build()))
|
||||
.sort(List.of(
|
||||
GetRecentlyAddedSort.builder()
|
||||
.key("titleSort")
|
||||
.title("Title")
|
||||
.default_("asc")
|
||||
.active(false)
|
||||
.activeDirection(GetRecentlyAddedActiveDirection.Ascending)
|
||||
.defaultDirection(GetRecentlyAddedDefaultDirection.Ascending)
|
||||
.descKey("titleSort:desc")
|
||||
.firstCharacterKey("/library/sections/2/firstCharacter")
|
||||
.build(),
|
||||
GetRecentlyAddedSort.builder()
|
||||
.key("titleSort")
|
||||
.title("Title")
|
||||
.default_("asc")
|
||||
.active(false)
|
||||
.activeDirection(GetRecentlyAddedActiveDirection.Ascending)
|
||||
.defaultDirection(GetRecentlyAddedDefaultDirection.Ascending)
|
||||
.descKey("titleSort:desc")
|
||||
.firstCharacterKey("/library/sections/2/firstCharacter")
|
||||
.build()))
|
||||
.field(List.of(
|
||||
GetRecentlyAddedField.builder()
|
||||
.key("show.title")
|
||||
.title("Show Title")
|
||||
.type("string")
|
||||
.subType("rating")
|
||||
.build(),
|
||||
GetRecentlyAddedField.builder()
|
||||
.key("show.title")
|
||||
.title("Show Title")
|
||||
.type("string")
|
||||
.subType("rating")
|
||||
.build(),
|
||||
GetRecentlyAddedField.builder()
|
||||
.key("show.title")
|
||||
.title("Show Title")
|
||||
.type("string")
|
||||
.subType("rating")
|
||||
.build()))
|
||||
.build()))
|
||||
.fieldType(List.of(
|
||||
GetRecentlyAddedFieldType.builder()
|
||||
.type("tag")
|
||||
.operator(List.of(
|
||||
GetRecentlyAddedOperator.builder()
|
||||
.key("=")
|
||||
.title("is")
|
||||
.build()))
|
||||
.build(),
|
||||
GetRecentlyAddedFieldType.builder()
|
||||
.type("tag")
|
||||
.operator(List.of(
|
||||
GetRecentlyAddedOperator.builder()
|
||||
.key("=")
|
||||
.title("is")
|
||||
.build()))
|
||||
.build(),
|
||||
GetRecentlyAddedFieldType.builder()
|
||||
.type("tag")
|
||||
.operator(List.of(
|
||||
GetRecentlyAddedOperator.builder()
|
||||
.key("=")
|
||||
.title("is")
|
||||
.build()))
|
||||
.build()))
|
||||
.build())
|
||||
.metadata(List.of(
|
||||
GetRecentlyAddedMetadata.builder()
|
||||
.ratingKey("58683")
|
||||
.key("/library/metadata/58683")
|
||||
.guid("plex://movie/5d7768ba96b655001fdc0408")
|
||||
.type(GetRecentlyAddedHubsType.Movie)
|
||||
.title("Avatar: The Way of Water")
|
||||
.summary("Jake Sully lives with his newfound family formed on the extrasolar moon Pandora. Once a familiar threat returns to finish what was previously started, Jake must work with Neytiri and the army of the Na'vi race to protect their home.")
|
||||
.addedAt(1556281940L)
|
||||
.studio("20th Century Studios")
|
||||
.skipChildren(false)
|
||||
.librarySectionID(1L)
|
||||
.librarySectionTitle("Movies")
|
||||
.librarySectionKey("/library/sections/1")
|
||||
.slug("4-for-texas")
|
||||
.contentRating("PG-13")
|
||||
.rating(7.6d)
|
||||
.audienceRating(9.2d)
|
||||
.year(2022)
|
||||
.seasonCount(2022)
|
||||
.tagline("Return to Pandora.")
|
||||
.flattenSeasons(FlattenSeasons.True)
|
||||
.showOrdering(ShowOrdering.Dvd)
|
||||
.thumb("/library/metadata/58683/thumb/1703239236")
|
||||
.art("/library/metadata/58683/art/1703239236")
|
||||
.banner("/library/metadata/58683/banner/1703239236")
|
||||
.duration(11558112)
|
||||
.originallyAvailableAt(LocalDate.parse("2022-12-14T00:00:00Z"))
|
||||
.updatedAt(1556281940L)
|
||||
.audienceRatingImage("rottentomatoes://image.rating.upright")
|
||||
.chapterSource("media")
|
||||
.primaryExtraKey("/library/metadata/58684")
|
||||
.ratingImage("rottentomatoes://image.rating.ripe")
|
||||
.grandparentRatingKey("66")
|
||||
.grandparentGuid("plex://show/5d9c081b170e24001f2a7be4")
|
||||
.grandparentKey("/library/metadata/66")
|
||||
.grandparentTitle("Caprica")
|
||||
.grandparentThumb("/library/metadata/66/thumb/1705716261")
|
||||
.parentSlug("alice-in-borderland-2020")
|
||||
.grandparentSlug("alice-in-borderland-2020")
|
||||
.grandparentArt("/library/metadata/66/art/1705716261")
|
||||
.grandparentTheme("/library/metadata/66/theme/1705716261")
|
||||
.media(List.of(
|
||||
Media.builder()
|
||||
.id(119534)
|
||||
.duration(11558112)
|
||||
.bitrate(25025)
|
||||
.width(3840)
|
||||
.height(2072)
|
||||
.aspectRatio(1.85d)
|
||||
.audioChannels(6)
|
||||
.audioCodec("eac3")
|
||||
.videoCodec("hevc")
|
||||
.videoResolution("4k")
|
||||
.container("mkv")
|
||||
.videoFrameRate("24p")
|
||||
.videoProfile("main 10")
|
||||
.part(List.of(
|
||||
Part.builder()
|
||||
.id(119542)
|
||||
.key("/library/parts/119542/1680457526/file.mkv")
|
||||
.duration(11558112)
|
||||
.file("/movies/Avatar The Way of Water (2022)/Avatar.The.Way.of.Water.2022.2160p.WEB-DL.DDP5.1.Atmos.DV.HDR10.HEVC-CMRG.mkv")
|
||||
.size(36158371307L)
|
||||
.container("mkv")
|
||||
.videoProfile("main 10")
|
||||
.audioProfile("dts")
|
||||
.has64bitOffsets(false)
|
||||
.optimizedForStreaming(false)
|
||||
.indexes("sd")
|
||||
.hasThumbnail(HasThumbnail.True)
|
||||
.stream(List.of(
|
||||
Stream.builder()
|
||||
.id(272796L)
|
||||
.streamType(1L)
|
||||
.codec("h264")
|
||||
.index(0L)
|
||||
.default_(true)
|
||||
.selected(true)
|
||||
.bitrate(6273L)
|
||||
.colorPrimaries("bt709")
|
||||
.colorRange("tv")
|
||||
.colorSpace("bt709")
|
||||
.colorTrc("bt709")
|
||||
.bitDepth(8L)
|
||||
.chromaLocation("left")
|
||||
.streamIdentifier("2")
|
||||
.chromaSubsampling("4:2:0")
|
||||
.codedHeight(1088L)
|
||||
.codedWidth(1920L)
|
||||
.frameRate(29.97d)
|
||||
.hasScalingMatrix(false)
|
||||
.hearingImpaired(false)
|
||||
.closedCaptions(false)
|
||||
.embeddedInVideo("1")
|
||||
.height(1080L)
|
||||
.level(40L)
|
||||
.profile("main")
|
||||
.refFrames(4L)
|
||||
.scanType("progressive")
|
||||
.width(1920L)
|
||||
.displayTitle("1080p (H.264)")
|
||||
.extendedDisplayTitle("1080p (H.264)")
|
||||
.channels(2L)
|
||||
.language("English")
|
||||
.languageTag("en")
|
||||
.languageCode("eng")
|
||||
.audioChannelLayout("stereo")
|
||||
.samplingRate(48000L)
|
||||
.title("English")
|
||||
.canAutoSync(false)
|
||||
.build()))
|
||||
.build()))
|
||||
.audioProfile("dts")
|
||||
.hasVoiceActivity(false)
|
||||
.optimizedForStreaming(OptimizedForStreaming.Enable)
|
||||
.has64bitOffsets(false)
|
||||
.build()))
|
||||
.genre(List.of(
|
||||
Genre.builder()
|
||||
.tag("Adventure")
|
||||
.build()))
|
||||
.country(List.of(
|
||||
Country.builder()
|
||||
.tag("United States of America")
|
||||
.build()))
|
||||
.director(List.of(
|
||||
Director.builder()
|
||||
.tag("James Cameron")
|
||||
.build(),
|
||||
Director.builder()
|
||||
.tag("James Cameron")
|
||||
.build()))
|
||||
.writer(List.of(
|
||||
Writer.builder()
|
||||
.tag("James Cameron")
|
||||
.build()))
|
||||
.collection(List.of(
|
||||
Collection.builder()
|
||||
.tag("Working NL Subs")
|
||||
.build()))
|
||||
.role(List.of(
|
||||
Role.builder()
|
||||
.id(294129L)
|
||||
.filter("actor=294129")
|
||||
.thumb("https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg")
|
||||
.tag("Mike Smith")
|
||||
.tagKey("668e7e7b22bcad9064350c91")
|
||||
.role("Self")
|
||||
.build(),
|
||||
Role.builder()
|
||||
.id(294129L)
|
||||
.filter("actor=294129")
|
||||
.thumb("https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg")
|
||||
.tag("Mike Smith")
|
||||
.tagKey("668e7e7b22bcad9064350c91")
|
||||
.role("Self")
|
||||
.build(),
|
||||
Role.builder()
|
||||
.id(294129L)
|
||||
.filter("actor=294129")
|
||||
.thumb("https://metadata-static.plex.tv/2/people/27b85844536c39f3f9ac943aaad46608.jpg")
|
||||
.tag("Mike Smith")
|
||||
.tagKey("668e7e7b22bcad9064350c91")
|
||||
.role("Self")
|
||||
.build()))
|
||||
.mediaGuid(List.of(
|
||||
MediaGuid.builder()
|
||||
.id("imdb://tt13015952")
|
||||
.build(),
|
||||
MediaGuid.builder()
|
||||
.id("imdb://tt13015952")
|
||||
.build(),
|
||||
MediaGuid.builder()
|
||||
.id("imdb://tt13015952")
|
||||
.build()))
|
||||
.ultraBlurColors(UltraBlurColors.builder()
|
||||
.topLeft("11333b")
|
||||
.topRight("0a232d")
|
||||
.bottomRight("73958")
|
||||
.bottomLeft("1f5066")
|
||||
.build())
|
||||
.metaDataRating(List.of(
|
||||
MetaDataRating.builder()
|
||||
.image("themoviedb://image.rating")
|
||||
.value(3f)
|
||||
.type("audience")
|
||||
.build()))
|
||||
.image(List.of(
|
||||
GetRecentlyAddedImage.builder()
|
||||
.alt("Episode 1")
|
||||
.type(GetRecentlyAddedHubsResponseType.BACKGROUND)
|
||||
.url("/library/metadata/45521/thumb/1644710589")
|
||||
.build(),
|
||||
GetRecentlyAddedImage.builder()
|
||||
.alt("Episode 1")
|
||||
.type(GetRecentlyAddedHubsResponseType.BACKGROUND)
|
||||
.url("/library/metadata/45521/thumb/1644710589")
|
||||
.build(),
|
||||
GetRecentlyAddedImage.builder()
|
||||
.alt("Episode 1")
|
||||
.type(GetRecentlyAddedHubsResponseType.BACKGROUND)
|
||||
.url("/library/metadata/45521/thumb/1644710589")
|
||||
.build()))
|
||||
.titleSort("Whale")
|
||||
.viewCount(1)
|
||||
.lastViewedAt(1682752242)
|
||||
.originalTitle("映画 ブラッククローバー 魔法帝の剣")
|
||||
.viewOffset(5222500)
|
||||
.skipCount(1)
|
||||
.index(1)
|
||||
.theme("/library/metadata/1/theme/1705636920")
|
||||
.leafCount(14)
|
||||
.viewedLeafCount(0)
|
||||
.childCount(1)
|
||||
.hasPremiumExtras("1")
|
||||
.hasPremiumPrimaryExtra("1")
|
||||
.parentRatingKey("66")
|
||||
.parentGuid("plex://show/5d9c081b170e24001f2a7be4")
|
||||
.parentStudio("UCP")
|
||||
.parentKey("/library/metadata/66")
|
||||
.parentTitle("Caprica")
|
||||
.parentIndex(1)
|
||||
.parentYear(2010)
|
||||
.parentThumb("/library/metadata/66/thumb/1705716261")
|
||||
.parentTheme("/library/metadata/66/theme/1705716261")
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testHubs_GetLibraryHubs() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetLibraryHubsResponse res = sdk.hubs().getLibraryHubs()
|
||||
.sectionId(5218.48d)
|
||||
.count(4146.62d)
|
||||
.onlyTransient(QueryParamOnlyTransient.ZERO)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetLibraryHubsResponseBody.builder()
|
||||
.mediaContainer(GetLibraryHubsMediaContainer.builder()
|
||||
.size(7)
|
||||
.allowSync(true)
|
||||
.identifier("com.plexapp.plugins.library")
|
||||
.librarySectionID(1)
|
||||
.librarySectionTitle("Movies")
|
||||
.librarySectionUUID("322a231a-b7f7-49f5-920f-14c61199cd30")
|
||||
.hub(List.of(
|
||||
GetLibraryHubsHub.builder()
|
||||
.key("/library/sections/1/all?sort=lastViewedAt:desc&unwatched=0&viewOffset=0")
|
||||
.title("Recently Played Movies")
|
||||
.type("movie")
|
||||
.hubIdentifier("movie.recentlyviewed.1")
|
||||
.context("hub.movie.recentlyviewed")
|
||||
.size(6)
|
||||
.more(true)
|
||||
.style("shelf")
|
||||
.hubKey("/library/metadata/66485,66098,57249,11449,5858,14944")
|
||||
.metadata(List.of(
|
||||
GetLibraryHubsMetadata.builder()
|
||||
.ratingKey("14944")
|
||||
.key("/library/metadata/14944")
|
||||
.guid("plex://movie/5d77686eeb5d26001f1eb339")
|
||||
.studio("Walt Disney Animation Studios")
|
||||
.type("movie")
|
||||
.title("Tangled")
|
||||
.librarySectionTitle("Movies")
|
||||
.librarySectionID(1)
|
||||
.librarySectionKey("/library/sections/1")
|
||||
.contentRating("PG")
|
||||
.summary("The magically long-haired Rapunzel has spent her entire life in a tower, but now that a runaway thief has stumbled upon her, she is about to discover the world for the first time, and who she really is.")
|
||||
.rating(8.9d)
|
||||
.audienceRating(8.7d)
|
||||
.viewCount(1)
|
||||
.lastViewedAt(1704936047)
|
||||
.year(2010)
|
||||
.tagline("They're taking adventure to new lengths.")
|
||||
.thumb("/library/metadata/14944/thumb/1705739847")
|
||||
.art("/library/metadata/14944/art/1705739847")
|
||||
.duration(6017237)
|
||||
.originallyAvailableAt(LocalDate.parse("2010-11-24T00:00:00Z"))
|
||||
.addedAt(1589412494)
|
||||
.updatedAt(1705739847)
|
||||
.audienceRatingImage("rottentomatoes://image.rating.upright")
|
||||
.primaryExtraKey("/library/metadata/14952")
|
||||
.ratingImage("rottentomatoes://image.rating.ripe")
|
||||
.media(List.of(
|
||||
GetLibraryHubsMedia.builder()
|
||||
.id(38247)
|
||||
.duration(6017237)
|
||||
.bitrate(2051)
|
||||
.width(1920)
|
||||
.height(1080)
|
||||
.aspectRatio(1.78d)
|
||||
.audioChannels(2)
|
||||
.audioCodec("aac")
|
||||
.videoCodec("h264")
|
||||
.videoResolution("1080")
|
||||
.container("mp4")
|
||||
.videoFrameRate("24p")
|
||||
.optimizedForStreaming(1)
|
||||
.audioProfile("lc")
|
||||
.has64bitOffsets(false)
|
||||
.videoProfile("high")
|
||||
.part(List.of(
|
||||
GetLibraryHubsPart.builder()
|
||||
.id(38247)
|
||||
.key("/library/parts/38247/1589412494/file.mp4")
|
||||
.duration(6017237)
|
||||
.file("/movies/Tangled (2010)/Tangled (2010) Bluray-1080p.mp4")
|
||||
.size(1545647447)
|
||||
.audioProfile("lc")
|
||||
.container("mp4")
|
||||
.has64bitOffsets(false)
|
||||
.optimizedForStreaming(true)
|
||||
.videoProfile("high")
|
||||
.build()))
|
||||
.build()))
|
||||
.genre(List.of(
|
||||
GetLibraryHubsGenre.builder()
|
||||
.tag("Animation")
|
||||
.build()))
|
||||
.country(List.of(
|
||||
GetLibraryHubsCountry.builder()
|
||||
.tag("United States of America")
|
||||
.build()))
|
||||
.director(List.of(
|
||||
GetLibraryHubsDirector.builder()
|
||||
.tag("Nathan Greno")
|
||||
.build()))
|
||||
.role(List.of(
|
||||
GetLibraryHubsRole.builder()
|
||||
.tag("Donna Murphy")
|
||||
.build()))
|
||||
.writer(List.of(
|
||||
GetLibraryHubsWriter.builder()
|
||||
.tag("Wilhelm Grimm")
|
||||
.build()))
|
||||
.skipCount(1)
|
||||
.chapterSource("media")
|
||||
.build()))
|
||||
.promoted(true)
|
||||
.random(true)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,85 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.EnablePaperTrailResponse;
|
||||
import dev.plexapi.sdk.models.operations.Level;
|
||||
import dev.plexapi.sdk.models.operations.LogLineResponse;
|
||||
import dev.plexapi.sdk.models.operations.LogMultiLineResponse;
|
||||
import java.lang.Exception;
|
||||
import java.lang.String;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class LogTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testLog_LogLine() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
LogLineResponse res = sdk.log().logLine()
|
||||
.level(Level.ZERO)
|
||||
.message("Test log message")
|
||||
.source("Postman")
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testLog_LogMultiLine() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
String req = "level=4&message=Test%20message%201&source=postman\nlevel=3&message=Test%20message%202&source=postman
|
||||
level=1&message=Test%20message%203&source=postman";
|
||||
|
||||
LogMultiLineResponse res = sdk.log().logMultiLine()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testLog_EnablePaperTrail() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
EnablePaperTrailResponse res = sdk.log().enablePaperTrail()
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,145 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.GetBannerImageRequest;
|
||||
import dev.plexapi.sdk.models.operations.GetBannerImageResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetThumbImageRequest;
|
||||
import dev.plexapi.sdk.models.operations.GetThumbImageResponse;
|
||||
import dev.plexapi.sdk.models.operations.MarkPlayedResponse;
|
||||
import dev.plexapi.sdk.models.operations.MarkUnplayedResponse;
|
||||
import dev.plexapi.sdk.models.operations.UpdatePlayProgressResponse;
|
||||
import java.lang.Exception;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class MediaTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testMedia_MarkPlayed() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
MarkPlayedResponse res = sdk.media().markPlayed()
|
||||
.key(59398d)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testMedia_MarkUnplayed() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
MarkUnplayedResponse res = sdk.media().markUnplayed()
|
||||
.key(59398d)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testMedia_UpdatePlayProgress_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
UpdatePlayProgressResponse res = sdk.media().updatePlayProgress()
|
||||
.key("<key>")
|
||||
.time(90000d)
|
||||
.state("played")
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testMedia_GetBannerImage() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetBannerImageRequest req = GetBannerImageRequest.builder()
|
||||
.ratingKey(9518L)
|
||||
.width(396L)
|
||||
.height(396L)
|
||||
.minSize(1L)
|
||||
.upscale(1L)
|
||||
.xPlexToken("CV5xoxjTpFKUzBTShsaf")
|
||||
.build();
|
||||
|
||||
GetBannerImageResponse res = sdk.media().getBannerImage()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testMedia_GetThumbImage() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetThumbImageRequest req = GetThumbImageRequest.builder()
|
||||
.ratingKey(9518L)
|
||||
.width(396L)
|
||||
.height(396L)
|
||||
.minSize(1L)
|
||||
.upscale(1L)
|
||||
.xPlexToken("CV5xoxjTpFKUzBTShsaf")
|
||||
.build();
|
||||
|
||||
GetThumbImageResponse res = sdk.media().getThumbImage()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,451 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.AddPlaylistContentsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.AddPlaylistContentsMetadata;
|
||||
import dev.plexapi.sdk.models.operations.AddPlaylistContentsResponse;
|
||||
import dev.plexapi.sdk.models.operations.AddPlaylistContentsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.ClearPlaylistContentsResponse;
|
||||
import dev.plexapi.sdk.models.operations.CreatePlaylistMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.CreatePlaylistMetadata;
|
||||
import dev.plexapi.sdk.models.operations.CreatePlaylistQueryParamType;
|
||||
import dev.plexapi.sdk.models.operations.CreatePlaylistRequest;
|
||||
import dev.plexapi.sdk.models.operations.CreatePlaylistResponse;
|
||||
import dev.plexapi.sdk.models.operations.CreatePlaylistResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.DeletePlaylistResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsCountry;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsDirector;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsGenre;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsMedia;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsMetadata;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsPart;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsQueryParamType;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsRole;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistContentsWriter;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistMetadata;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistsMetadata;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetPlaylistsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.PlaylistType;
|
||||
import dev.plexapi.sdk.models.operations.QueryParamForce;
|
||||
import dev.plexapi.sdk.models.operations.QueryParamSmart;
|
||||
import dev.plexapi.sdk.models.operations.Smart;
|
||||
import dev.plexapi.sdk.models.operations.UpdatePlaylistResponse;
|
||||
import dev.plexapi.sdk.models.operations.UploadPlaylistResponse;
|
||||
import java.lang.Exception;
|
||||
import java.time.LocalDate;
|
||||
import java.util.List;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class PlaylistsTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlaylists_CreatePlaylist() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
CreatePlaylistRequest req = CreatePlaylistRequest.builder()
|
||||
.title("<value>")
|
||||
.type(CreatePlaylistQueryParamType.PHOTO)
|
||||
.smart(Smart.ONE)
|
||||
.uri("https://comfortable-eyebrow.info/")
|
||||
.build();
|
||||
|
||||
CreatePlaylistResponse res = sdk.playlists().createPlaylist()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
CreatePlaylistResponseBody.builder()
|
||||
.mediaContainer(CreatePlaylistMediaContainer.builder()
|
||||
.size(7)
|
||||
.metadata(List.of(
|
||||
CreatePlaylistMetadata.builder()
|
||||
.ratingKey("96")
|
||||
.key("/playlists/96/items")
|
||||
.guid("com.plexapp.agents.none://a2f92937-1408-40e2-b022-63a8a9377e55")
|
||||
.type("playlist")
|
||||
.title("A Great Playlist")
|
||||
.summary("What a great playlist")
|
||||
.smart(false)
|
||||
.playlistType("video")
|
||||
.icon("playlist://image.smart")
|
||||
.viewCount(1)
|
||||
.lastViewedAt(1705719589)
|
||||
.leafCount(1)
|
||||
.addedAt(1705719589)
|
||||
.updatedAt(1705724593)
|
||||
.composite("/playlists/96/composite/1705724593")
|
||||
.duration(141000)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlaylists_GetPlaylists() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetPlaylistsResponse res = sdk.playlists().getPlaylists()
|
||||
.playlistType(PlaylistType.VIDEO)
|
||||
.smart(QueryParamSmart.ZERO)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetPlaylistsResponseBody.builder()
|
||||
.mediaContainer(GetPlaylistsMediaContainer.builder()
|
||||
.size(4)
|
||||
.metadata(List.of(
|
||||
GetPlaylistsMetadata.builder()
|
||||
.ratingKey("92")
|
||||
.key("/playlists/92/items")
|
||||
.guid("com.plexapp.agents.none://7ca5aaef-58e8-4828-9e21-c009c97f2903")
|
||||
.type("playlist")
|
||||
.title("Static Playlist")
|
||||
.summary("A Great Playlist")
|
||||
.smart(false)
|
||||
.playlistType("video")
|
||||
.composite("/playlists/92/composite/1705716440")
|
||||
.icon("playlist://image.smart")
|
||||
.viewCount(1)
|
||||
.lastViewedAt(1705716298)
|
||||
.duration(7328000)
|
||||
.leafCount(32)
|
||||
.addedAt(1705716298)
|
||||
.updatedAt(1705716440)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlaylists_GetPlaylist() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetPlaylistResponse res = sdk.playlists().getPlaylist()
|
||||
.playlistID(9883.74d)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetPlaylistResponseBody.builder()
|
||||
.mediaContainer(GetPlaylistMediaContainer.builder()
|
||||
.size(1)
|
||||
.metadata(List.of(
|
||||
GetPlaylistMetadata.builder()
|
||||
.content("library://x/directory/%2Flibrary%2Fsections%2F1%2Fall%3Ftype%3D1%26push%3D1%26title%3D2%26or%3D1%26title%3DSerenity%26pop%3D1")
|
||||
.ratingKey("95")
|
||||
.key("/playlists/95/items")
|
||||
.guid("com.plexapp.agents.none://87425529-380f-44b8-a689-9a0537e7ec91")
|
||||
.type("playlist")
|
||||
.title("Smart Movie Playlist")
|
||||
.summary("")
|
||||
.smart(true)
|
||||
.playlistType("video")
|
||||
.composite("/playlists/95/composite/1705717387")
|
||||
.icon("playlist://image.smart")
|
||||
.duration(282000)
|
||||
.leafCount(2)
|
||||
.addedAt(1705716493)
|
||||
.updatedAt(1705717387)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlaylists_DeletePlaylist() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
DeletePlaylistResponse res = sdk.playlists().deletePlaylist()
|
||||
.playlistID(1020.45d)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlaylists_UpdatePlaylist() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
UpdatePlaylistResponse res = sdk.playlists().updatePlaylist()
|
||||
.playlistID(2088.77d)
|
||||
.title("<value>")
|
||||
.summary("<value>")
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlaylists_GetPlaylistContents() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetPlaylistContentsResponse res = sdk.playlists().getPlaylistContents()
|
||||
.playlistID(1613.10d)
|
||||
.type(GetPlaylistContentsQueryParamType.TvShow)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetPlaylistContentsResponseBody.builder()
|
||||
.mediaContainer(GetPlaylistContentsMediaContainer.builder()
|
||||
.size(2)
|
||||
.composite("/playlists/95/composite/1705717521")
|
||||
.duration(282)
|
||||
.leafCount(2)
|
||||
.playlistType("video")
|
||||
.ratingKey("95")
|
||||
.smart(true)
|
||||
.title("Smart Movie Playlist")
|
||||
.metadata(List.of(
|
||||
GetPlaylistContentsMetadata.builder()
|
||||
.ratingKey("17")
|
||||
.key("/library/metadata/17")
|
||||
.guid("plex://movie/5d77683f6f4521001ea9dc53")
|
||||
.studio("Universal Pictures")
|
||||
.type("movie")
|
||||
.title("Serenity")
|
||||
.titleSort("Amazing Spider-Man 2")
|
||||
.librarySectionTitle("Movies")
|
||||
.librarySectionID(1)
|
||||
.librarySectionKey("/library/sections/1")
|
||||
.contentRating("PG-13")
|
||||
.summary("Serenity continues the story of the TV series it was based upon (\"Firefly\"). River Tam had a secret - one in which she's not even aware - so dangerous, no one's safe, as an Alliance operative's sent to capture her, and all others are considered irrelevant to his job.")
|
||||
.rating(8.2d)
|
||||
.audienceRating(9.1d)
|
||||
.year(2005)
|
||||
.tagline("They aim to misbehave.")
|
||||
.thumb("/library/metadata/17/thumb/1705637165")
|
||||
.art("/library/metadata/17/art/1705637165")
|
||||
.duration(141416)
|
||||
.originallyAvailableAt(LocalDate.parse("2005-09-29T00:00:00Z"))
|
||||
.addedAt(1705637164)
|
||||
.updatedAt(1705637165)
|
||||
.audienceRatingImage("rottentomatoes://image.rating.upright")
|
||||
.hasPremiumExtras("1")
|
||||
.hasPremiumPrimaryExtra("1")
|
||||
.ratingImage("rottentomatoes://image.rating.ripe")
|
||||
.media(List.of(
|
||||
GetPlaylistContentsMedia.builder()
|
||||
.id(15)
|
||||
.duration(141416)
|
||||
.bitrate(2273)
|
||||
.width(1920)
|
||||
.height(814)
|
||||
.aspectRatio(2.35d)
|
||||
.audioChannels(2)
|
||||
.audioCodec("aac")
|
||||
.videoCodec("h264")
|
||||
.videoResolution("1080")
|
||||
.container("mp4")
|
||||
.videoFrameRate("24p")
|
||||
.optimizedForStreaming(0)
|
||||
.audioProfile("lc")
|
||||
.has64bitOffsets(false)
|
||||
.videoProfile("high")
|
||||
.part(List.of(
|
||||
GetPlaylistContentsPart.builder()
|
||||
.id(15)
|
||||
.key("/library/parts/15/1705637151/file.mp4")
|
||||
.duration(141416)
|
||||
.file("/movies/Serenity (2005)/Serenity (2005).mp4")
|
||||
.size(40271948)
|
||||
.audioProfile("lc")
|
||||
.container("mp4")
|
||||
.has64bitOffsets(false)
|
||||
.optimizedForStreaming(false)
|
||||
.videoProfile("high")
|
||||
.build()))
|
||||
.build()))
|
||||
.genre(List.of(
|
||||
GetPlaylistContentsGenre.builder()
|
||||
.tag("Action")
|
||||
.build()))
|
||||
.country(List.of(
|
||||
GetPlaylistContentsCountry.builder()
|
||||
.tag("United States of America")
|
||||
.build()))
|
||||
.director(List.of(
|
||||
GetPlaylistContentsDirector.builder()
|
||||
.tag("Joss Whedon")
|
||||
.build()))
|
||||
.writer(List.of(
|
||||
GetPlaylistContentsWriter.builder()
|
||||
.tag("Joss Whedon")
|
||||
.build()))
|
||||
.role(List.of(
|
||||
GetPlaylistContentsRole.builder()
|
||||
.tag("Gina Torres")
|
||||
.build()))
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlaylists_ClearPlaylistContents() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
ClearPlaylistContentsResponse res = sdk.playlists().clearPlaylistContents()
|
||||
.playlistID(6531.08d)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlaylists_AddPlaylistContents() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
AddPlaylistContentsResponse res = sdk.playlists().addPlaylistContents()
|
||||
.playlistID(2532.92d)
|
||||
.uri("server://12345/com.plexapp.plugins.library/library/metadata/1")
|
||||
.playQueueID(123d)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
AddPlaylistContentsResponseBody.builder()
|
||||
.mediaContainer(AddPlaylistContentsMediaContainer.builder()
|
||||
.size(1)
|
||||
.leafCountAdded(1)
|
||||
.leafCountRequested(1)
|
||||
.metadata(List.of(
|
||||
AddPlaylistContentsMetadata.builder()
|
||||
.ratingKey("94")
|
||||
.key("/playlists/94/items")
|
||||
.guid("com.plexapp.agents.none://972e3047-83d6-4848-a000-261f0af26ba2")
|
||||
.type("playlist")
|
||||
.title("A great playlist")
|
||||
.summary("One of my great playlists")
|
||||
.smart(false)
|
||||
.playlistType("video")
|
||||
.composite("/playlists/94/composite/1705800070")
|
||||
.duration(423000)
|
||||
.leafCount(3)
|
||||
.addedAt(1705716458)
|
||||
.updatedAt(1705800070)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlaylists_UploadPlaylist() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
UploadPlaylistResponse res = sdk.playlists().uploadPlaylist()
|
||||
.path("/home/barkley/playlist.m3u")
|
||||
.force(QueryParamForce.ZERO)
|
||||
.sectionID(1L)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,336 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.Connections;
|
||||
import dev.plexapi.sdk.models.operations.Friend;
|
||||
import dev.plexapi.sdk.models.operations.GeoData;
|
||||
import dev.plexapi.sdk.models.operations.GetCompanionsDataResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetGeoDataGeoData;
|
||||
import dev.plexapi.sdk.models.operations.GetGeoDataResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetHomeDataResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetHomeDataResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetPinAuthPinContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetPinRequest;
|
||||
import dev.plexapi.sdk.models.operations.GetPinResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetServerResourcesResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetTokenByPinIdAuthPinContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetTokenByPinIdGeoData;
|
||||
import dev.plexapi.sdk.models.operations.GetTokenByPinIdRequest;
|
||||
import dev.plexapi.sdk.models.operations.GetTokenByPinIdResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetUserFriendsResponse;
|
||||
import dev.plexapi.sdk.models.operations.IncludeHttps;
|
||||
import dev.plexapi.sdk.models.operations.IncludeIPv6;
|
||||
import dev.plexapi.sdk.models.operations.IncludeRelay;
|
||||
import dev.plexapi.sdk.models.operations.PlexDevice;
|
||||
import dev.plexapi.sdk.models.operations.Protocol;
|
||||
import dev.plexapi.sdk.models.operations.ResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.SharedServers;
|
||||
import dev.plexapi.sdk.models.operations.SharedSources;
|
||||
import dev.plexapi.sdk.models.operations.Status;
|
||||
import java.lang.Exception;
|
||||
import java.time.OffsetDateTime;
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.openapitools.jackson.nullable.JsonNullable;
|
||||
|
||||
public class PlexTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlex_GetCompanionsData() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetCompanionsDataResponse res = sdk.plex().getCompanionsData()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
List.of(
|
||||
ResponseBody.builder()
|
||||
.identifier("tv.plex.sonos")
|
||||
.baseURL("https://sonos.plex.tv")
|
||||
.title("Sonos")
|
||||
.linkURL("https://sonos.plex.tv/link")
|
||||
.provides("client,player")
|
||||
.token("<value>")
|
||||
.build()),
|
||||
res.responseBodies().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlex_GetUserFriends() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetUserFriendsResponse res = sdk.plex().getUserFriends()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
List.of(
|
||||
Friend.builder()
|
||||
.email("username@email.com")
|
||||
.friendlyName(Optional.empty())
|
||||
.home(false)
|
||||
.id(437587)
|
||||
.sharedServers(List.of(
|
||||
SharedServers.builder()
|
||||
.build()))
|
||||
.sharedSources(List.of(
|
||||
SharedSources.builder()
|
||||
.build()))
|
||||
.status(Status.ACCEPTED)
|
||||
.thumb("https://plex.tv/users/7d1916e0d8f6e76b/avatar?c=1694481578")
|
||||
.title("username123")
|
||||
.username("username123")
|
||||
.uuid("7d1916e0d8f6e76b")
|
||||
.restricted(false)
|
||||
.build()),
|
||||
res.friends().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlex_GetGeoData() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetGeoDataResponse res = sdk.plex().getGeoData()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetGeoDataGeoData.builder()
|
||||
.code("VI")
|
||||
.continentCode("NA")
|
||||
.country("United States Virgin Islands")
|
||||
.city("Amsterdam")
|
||||
.timeZone("America/St_Thomas")
|
||||
.postalCode("802")
|
||||
.subdivisions("Saint Thomas")
|
||||
.coordinates("18.3381, -64.8941")
|
||||
.europeanUnionMember(true)
|
||||
.inPrivacyRestrictedCountry(true)
|
||||
.inPrivacyRestrictedRegion(true)
|
||||
.build(),
|
||||
res.geoData().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlex_GetHomeData() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetHomeDataResponse res = sdk.plex().getHomeData()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetHomeDataResponseBody.builder()
|
||||
.id(1841489d)
|
||||
.name("Blindkitty38's home")
|
||||
.guestUserID(58815432d)
|
||||
.guestUserUUID("f3df4e01bfca0787")
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlex_GetServerResources() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetServerResourcesResponse res = sdk.plex().getServerResources()
|
||||
.includeHttps(IncludeHttps.Enable)
|
||||
.includeRelay(IncludeRelay.Enable)
|
||||
.includeIPv6(IncludeIPv6.Enable)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
List.of(
|
||||
PlexDevice.builder()
|
||||
.name("<value>")
|
||||
.product("Small Wooden Fish")
|
||||
.productVersion("<value>")
|
||||
.platform("<value>")
|
||||
.platformVersion("<value>")
|
||||
.device("Mobile")
|
||||
.clientIdentifier("<value>")
|
||||
.createdAt(OffsetDateTime.parse("2019-06-24T11:38:02Z"))
|
||||
.lastSeenAt(OffsetDateTime.parse("2019-06-24T11:38:02Z"))
|
||||
.provides("<value>")
|
||||
.ownerId(528895L)
|
||||
.sourceTitle("<value>")
|
||||
.publicAddress("<value>")
|
||||
.accessToken("<value>")
|
||||
.owned(false)
|
||||
.home(false)
|
||||
.synced(false)
|
||||
.relay(false)
|
||||
.presence(false)
|
||||
.httpsRequired(false)
|
||||
.publicAddressMatches(false)
|
||||
.dnsRebindingProtection(false)
|
||||
.natLoopbackSupported(false)
|
||||
.connections(List.of(
|
||||
Connections.builder()
|
||||
.protocol(Protocol.HTTP)
|
||||
.address("9000 Station Road")
|
||||
.port(57017)
|
||||
.uri("https://steep-independence.net")
|
||||
.local(false)
|
||||
.relay(false)
|
||||
.iPv6(false)
|
||||
.build()))
|
||||
.build()),
|
||||
res.plexDevices().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlex_GetPin_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetPinRequest req = GetPinRequest.builder()
|
||||
.build();
|
||||
|
||||
GetPinResponse res = sdk.plex().getPin()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetPinAuthPinContainer.builder()
|
||||
.id(308667304L)
|
||||
.code("7RQZ")
|
||||
.product("Tautulli")
|
||||
.qr("https://plex.tv/api/v2/pins/qr/7RQZ")
|
||||
.clientIdentifier("Tautulli")
|
||||
.location(GeoData.builder()
|
||||
.code("VI")
|
||||
.continentCode("NA")
|
||||
.country("United States Virgin Islands")
|
||||
.city("Amsterdam")
|
||||
.timeZone("America/St_Thomas")
|
||||
.postalCode("802")
|
||||
.subdivisions("Saint Thomas")
|
||||
.coordinates("18.3381, -64.8941")
|
||||
.europeanUnionMember(true)
|
||||
.inPrivacyRestrictedCountry(true)
|
||||
.inPrivacyRestrictedRegion(true)
|
||||
.build())
|
||||
.createdAt(OffsetDateTime.parse("2024-07-16T17:03:05Z"))
|
||||
.expiresAt(OffsetDateTime.parse("2024-07-16T17:18:05Z"))
|
||||
.trusted(false)
|
||||
.expiresIn(876L)
|
||||
.authToken(JsonNullable.of(null))
|
||||
.newRegistration(JsonNullable.of(null))
|
||||
.build(),
|
||||
res.authPinContainer().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testPlex_GetTokenByPinId_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetTokenByPinIdRequest req = GetTokenByPinIdRequest.builder()
|
||||
.pinID(118274L)
|
||||
.build();
|
||||
|
||||
GetTokenByPinIdResponse res = sdk.plex().getTokenByPinId()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetTokenByPinIdAuthPinContainer.builder()
|
||||
.id(308667304L)
|
||||
.code("7RQZ")
|
||||
.product("Tautulli")
|
||||
.qr("https://plex.tv/api/v2/pins/qr/7RQZ")
|
||||
.clientIdentifier("Tautulli")
|
||||
.location(GetTokenByPinIdGeoData.builder()
|
||||
.code("VI")
|
||||
.continentCode("NA")
|
||||
.country("United States Virgin Islands")
|
||||
.city("Amsterdam")
|
||||
.timeZone("America/St_Thomas")
|
||||
.postalCode("802")
|
||||
.subdivisions("Saint Thomas")
|
||||
.coordinates("18.3381, -64.8941")
|
||||
.europeanUnionMember(true)
|
||||
.inPrivacyRestrictedCountry(true)
|
||||
.inPrivacyRestrictedRegion(true)
|
||||
.build())
|
||||
.createdAt(OffsetDateTime.parse("2024-07-16T17:03:05Z"))
|
||||
.expiresAt(OffsetDateTime.parse("2024-07-16T17:18:05Z"))
|
||||
.trusted(false)
|
||||
.expiresIn(876L)
|
||||
.authToken(JsonNullable.of(null))
|
||||
.newRegistration(JsonNullable.of(null))
|
||||
.build(),
|
||||
res.authPinContainer().get());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,190 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsCountry;
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsDirector;
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsGenre;
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsMedia;
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsMetadata;
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsPart;
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsRole;
|
||||
import dev.plexapi.sdk.models.operations.GetSearchResultsWriter;
|
||||
import dev.plexapi.sdk.models.operations.PerformSearchResponse;
|
||||
import dev.plexapi.sdk.models.operations.PerformVoiceSearchResponse;
|
||||
import dev.plexapi.sdk.models.operations.Provider;
|
||||
import java.lang.Exception;
|
||||
import java.time.OffsetDateTime;
|
||||
import java.util.List;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class SearchTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSearch_PerformSearch() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
PerformSearchResponse res = sdk.search().performSearch()
|
||||
.query("dylan")
|
||||
.sectionId(4561.50d)
|
||||
.limit(5d)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSearch_PerformVoiceSearch() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
PerformVoiceSearchResponse res = sdk.search().performVoiceSearch()
|
||||
.query("dead+poop")
|
||||
.sectionId(5684.34d)
|
||||
.limit(5d)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSearch_GetSearchResults() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetSearchResultsResponse res = sdk.search().getSearchResults()
|
||||
.query("110")
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetSearchResultsResponseBody.builder()
|
||||
.mediaContainer(GetSearchResultsMediaContainer.builder()
|
||||
.size(26d)
|
||||
.identifier("com.plexapp.plugins.library")
|
||||
.mediaTagPrefix("/system/bundle/media/flags/")
|
||||
.mediaTagVersion(1680021154d)
|
||||
.metadata(List.of(
|
||||
GetSearchResultsMetadata.builder()
|
||||
.librarySectionID(1d)
|
||||
.librarySectionTitle("Movies")
|
||||
.librarySectionUUID("322a231a-b7f7-49f5-920f-14c61199cd30")
|
||||
.sourceTitle("Hera")
|
||||
.ratingKey(10398d)
|
||||
.key("/library/metadata/10398")
|
||||
.guid("plex://movie/5d7768284de0ee001fcc8f52")
|
||||
.studio("Paramount")
|
||||
.type("movie")
|
||||
.title("Mission: Impossible")
|
||||
.contentRating("PG-13")
|
||||
.summary("When Ethan Hunt the leader of a crack espionage team whose perilous operation has gone awry with no explanation discovers that a mole has penetrated the CIA he's surprised to learn that he's the No. 1 suspect. To clear his name Hunt now must ferret out the real double agent and in the process even the score.")
|
||||
.rating(6.6d)
|
||||
.audienceRating(7.1d)
|
||||
.year(1996d)
|
||||
.tagline("Expect the impossible.")
|
||||
.thumb("/library/metadata/10398/thumb/1679505055")
|
||||
.art("/library/metadata/10398/art/1679505055")
|
||||
.duration(6612628d)
|
||||
.originallyAvailableAt(OffsetDateTime.parse("1996-05-22T00:00:00Z"))
|
||||
.addedAt(1589234571d)
|
||||
.updatedAt(1679505055d)
|
||||
.audienceRatingImage("rottentomatoes://image.rating.upright")
|
||||
.chapterSource("media")
|
||||
.primaryExtraKey("/library/metadata/10501")
|
||||
.ratingImage("rottentomatoes://image.rating.ripe")
|
||||
.media(List.of(
|
||||
GetSearchResultsMedia.builder()
|
||||
.id(26610d)
|
||||
.duration(6612628d)
|
||||
.bitrate(4751d)
|
||||
.width(1916d)
|
||||
.height(796d)
|
||||
.aspectRatio(2.35d)
|
||||
.audioChannels(6d)
|
||||
.audioCodec("aac")
|
||||
.videoCodec("hevc")
|
||||
.videoResolution(1080d)
|
||||
.container("mkv")
|
||||
.videoFrameRate("24p")
|
||||
.audioProfile("lc")
|
||||
.videoProfile("main 10")
|
||||
.part(List.of(
|
||||
GetSearchResultsPart.builder()
|
||||
.id(26610d)
|
||||
.key("/library/parts/26610/1589234571/file.mkv")
|
||||
.duration(6612628d)
|
||||
.file("/movies/Mission Impossible (1996)/Mission Impossible (1996) Bluray-1080p.mkv")
|
||||
.size(3926903851d)
|
||||
.audioProfile("lc")
|
||||
.container("mkv")
|
||||
.videoProfile("main 10")
|
||||
.build()))
|
||||
.build()))
|
||||
.genre(List.of(
|
||||
GetSearchResultsGenre.builder()
|
||||
.tag("Action")
|
||||
.build()))
|
||||
.director(List.of(
|
||||
GetSearchResultsDirector.builder()
|
||||
.tag("Brian De Palma")
|
||||
.build()))
|
||||
.writer(List.of(
|
||||
GetSearchResultsWriter.builder()
|
||||
.tag("David Koepp")
|
||||
.build()))
|
||||
.country(List.of(
|
||||
GetSearchResultsCountry.builder()
|
||||
.tag("United States of America")
|
||||
.build()))
|
||||
.role(List.of(
|
||||
GetSearchResultsRole.builder()
|
||||
.tag("Tom Cruise")
|
||||
.build()))
|
||||
.build()))
|
||||
.provider(List.of(
|
||||
Provider.builder()
|
||||
.key("/system/search")
|
||||
.title("Local Network")
|
||||
.type("mixed")
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,381 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.Action;
|
||||
import dev.plexapi.sdk.models.operations.Device;
|
||||
import dev.plexapi.sdk.models.operations.Feature;
|
||||
import dev.plexapi.sdk.models.operations.GetAvailableClientsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetAvailableClientsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetAvailableClientsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetDevicesMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetDevicesResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetDevicesResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetMediaProvidersMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetMediaProvidersResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetMediaProvidersResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetMyPlexAccountResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetMyPlexAccountResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetResizedPhotoRequest;
|
||||
import dev.plexapi.sdk.models.operations.GetResizedPhotoResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetServerCapabilitiesResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetServerIdentityMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetServerIdentityResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetServerIdentityResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetServerListMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetServerListResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetServerListResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetServerListServer;
|
||||
import dev.plexapi.sdk.models.operations.GetServerPreferencesMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetServerPreferencesResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetServerPreferencesResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.MediaProvider;
|
||||
import dev.plexapi.sdk.models.operations.MinSize;
|
||||
import dev.plexapi.sdk.models.operations.MyPlex;
|
||||
import dev.plexapi.sdk.models.operations.Server;
|
||||
import dev.plexapi.sdk.models.operations.Setting;
|
||||
import dev.plexapi.sdk.models.operations.Upscale;
|
||||
import java.lang.Exception;
|
||||
import java.util.List;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class ServerTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testServer_GetServerCapabilities() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetServerCapabilitiesResponse res = sdk.server().getServerCapabilities()
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testServer_GetServerPreferences() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetServerPreferencesResponse res = sdk.server().getServerPreferences()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetServerPreferencesResponseBody.builder()
|
||||
.mediaContainer(GetServerPreferencesMediaContainer.builder()
|
||||
.size(161)
|
||||
.setting(List.of(
|
||||
Setting.builder()
|
||||
.id("EnableDatabaseTrace")
|
||||
.label("")
|
||||
.summary("")
|
||||
.type("bool")
|
||||
.default_(false)
|
||||
.value(false)
|
||||
.hidden(true)
|
||||
.advanced(false)
|
||||
.group("")
|
||||
.enumValues("1:admin only|2:everyone")
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testServer_GetAvailableClients() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetAvailableClientsResponse res = sdk.server().getAvailableClients()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetAvailableClientsResponseBody.builder()
|
||||
.mediaContainer(GetAvailableClientsMediaContainer.builder()
|
||||
.size(1d)
|
||||
.server(List.of(
|
||||
Server.builder()
|
||||
.name("iPad")
|
||||
.host("10.10.10.102")
|
||||
.address("10.10.10.102")
|
||||
.port(32500d)
|
||||
.machineIdentifier("A2E901F8-E016-43A7-ADFB-EF8CA8A4AC05")
|
||||
.version("8.17")
|
||||
.protocol("plex")
|
||||
.product("Plex for iOS")
|
||||
.deviceClass("tablet")
|
||||
.protocolVersion(2d)
|
||||
.protocolCapabilities("playback,playqueues,timeline,provider-playback")
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testServer_GetDevices() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetDevicesResponse res = sdk.server().getDevices()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetDevicesResponseBody.builder()
|
||||
.mediaContainer(GetDevicesMediaContainer.builder()
|
||||
.size(151d)
|
||||
.identifier("com.plexapp.system.devices")
|
||||
.device(List.of(
|
||||
Device.builder()
|
||||
.id(1d)
|
||||
.name("iPhone")
|
||||
.platform("iOS")
|
||||
.createdAt(1654131230d)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testServer_GetServerIdentity() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetServerIdentityResponse res = sdk.server().getServerIdentity()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetServerIdentityResponseBody.builder()
|
||||
.mediaContainer(GetServerIdentityMediaContainer.builder()
|
||||
.size(0d)
|
||||
.machineIdentifier("96f2fe7a78c9dc1f16a16bedbe90f98149be16b4")
|
||||
.version("1.31.3.6868-28fc46b27")
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testServer_GetMyPlexAccount() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetMyPlexAccountResponse res = sdk.server().getMyPlexAccount()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetMyPlexAccountResponseBody.builder()
|
||||
.myPlex(MyPlex.builder()
|
||||
.authToken("Z5v-PrNASDFpsaCi3CPK7")
|
||||
.username("example.email@mail.com")
|
||||
.mappingState("mapped")
|
||||
.signInState("ok")
|
||||
.publicAddress("140.20.68.140")
|
||||
.publicPort(32400d)
|
||||
.privateAddress("10.10.10.47")
|
||||
.privatePort(32400d)
|
||||
.subscriptionFeatures("federated-auth,hardware_transcoding,home,hwtranscode,item_clusters,kevin-bacon,livetv,loudness,lyrics,music-analysis,music_videos,pass,photo_autotags,photos-v5,photosV6-edit,photosV6-tv-albums,premium_music_metadata,radio,server-manager,session_bandwidth_restrictions,session_kick,shared-radio,sync,trailers,tuner-sharing,type-first,unsupportedtuners,webhooks")
|
||||
.subscriptionState("Active")
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testServer_GetResizedPhoto() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetResizedPhotoRequest req = GetResizedPhotoRequest.builder()
|
||||
.width(110d)
|
||||
.height(165d)
|
||||
.opacity(100L)
|
||||
.blur(20d)
|
||||
.minSize(MinSize.ONE)
|
||||
.upscale(Upscale.ONE)
|
||||
.url("/library/metadata/49564/thumb/1654258204")
|
||||
.build();
|
||||
|
||||
GetResizedPhotoResponse res = sdk.server().getResizedPhoto()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testServer_GetMediaProviders() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetMediaProvidersResponse res = sdk.server().getMediaProviders()
|
||||
.xPlexToken("CV5xoxjTpFKUzBTShsaf")
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetMediaProvidersResponseBody.builder()
|
||||
.mediaContainer(GetMediaProvidersMediaContainer.builder()
|
||||
.mediaProvider(List.of(
|
||||
MediaProvider.builder()
|
||||
.feature(List.of(
|
||||
Feature.builder()
|
||||
.type("<value>")
|
||||
.flavor("global")
|
||||
.scrobbleKey("/:/scrobble/new")
|
||||
.unscrobbleKey("/:/unscrobble/new")
|
||||
.action(List.of(
|
||||
Action.builder()
|
||||
.id("addToContinueWatching")
|
||||
.key("/actions/addToContinueWatching")
|
||||
.build()))
|
||||
.build(),
|
||||
Feature.builder()
|
||||
.type("<value>")
|
||||
.flavor("global")
|
||||
.scrobbleKey("/:/scrobble/new")
|
||||
.unscrobbleKey("/:/unscrobble/new")
|
||||
.action(List.of(
|
||||
Action.builder()
|
||||
.id("addToContinueWatching")
|
||||
.key("/actions/addToContinueWatching")
|
||||
.build(),
|
||||
Action.builder()
|
||||
.id("addToContinueWatching")
|
||||
.key("/actions/addToContinueWatching")
|
||||
.build()))
|
||||
.build(),
|
||||
Feature.builder()
|
||||
.type("<value>")
|
||||
.flavor("global")
|
||||
.scrobbleKey("/:/scrobble/new")
|
||||
.unscrobbleKey("/:/unscrobble/new")
|
||||
.action(List.of(
|
||||
Action.builder()
|
||||
.id("addToContinueWatching")
|
||||
.key("/actions/addToContinueWatching")
|
||||
.build(),
|
||||
Action.builder()
|
||||
.id("addToContinueWatching")
|
||||
.key("/actions/addToContinueWatching")
|
||||
.build()))
|
||||
.build()))
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testServer_GetServerList() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetServerListResponse res = sdk.server().getServerList()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetServerListResponseBody.builder()
|
||||
.mediaContainer(GetServerListMediaContainer.builder()
|
||||
.size(1d)
|
||||
.server(List.of(
|
||||
GetServerListServer.builder()
|
||||
.name("Hera")
|
||||
.host("10.10.10.47")
|
||||
.address("10.10.10.47")
|
||||
.port(32400d)
|
||||
.machineIdentifier("96f2fe7a78c9dc1f16a16bedbe90f98149be16b4")
|
||||
.version("1.31.3.6868-28fc46b27")
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,563 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.GetSessionHistoryMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionHistoryMetadata;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionHistoryResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionHistoryResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionsMedia;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionsMetadata;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionsPart;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionsStream;
|
||||
import dev.plexapi.sdk.models.operations.GetSessionsUser;
|
||||
import dev.plexapi.sdk.models.operations.GetTranscodeSessionsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetTranscodeSessionsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetTranscodeSessionsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.Player;
|
||||
import dev.plexapi.sdk.models.operations.QueryParamFilter;
|
||||
import dev.plexapi.sdk.models.operations.Session;
|
||||
import dev.plexapi.sdk.models.operations.StopTranscodeSessionResponse;
|
||||
import dev.plexapi.sdk.models.operations.TranscodeSession;
|
||||
import java.lang.Exception;
|
||||
import java.time.LocalDate;
|
||||
import java.util.List;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class SessionsTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSessions_GetSessions() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetSessionsResponse res = sdk.sessions().getSessions()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetSessionsResponseBody.builder()
|
||||
.mediaContainer(GetSessionsMediaContainer.builder()
|
||||
.size(1)
|
||||
.metadata(List.of(
|
||||
GetSessionsMetadata.builder()
|
||||
.addedAt(1705543312)
|
||||
.art("/library/metadata/39904/art/1705310687")
|
||||
.duration(186240)
|
||||
.grandparentArt("/library/metadata/39904/art/1705310687")
|
||||
.grandparentGuid("plex://artist/5d07bbfd403c6402904a6480")
|
||||
.grandparentKey("/library/metadata/39904")
|
||||
.grandparentRatingKey("39904")
|
||||
.grandparentThumb("/library/metadata/39904/thumb/1705310687")
|
||||
.grandparentTitle("Green Day")
|
||||
.guid("plex://track/6535834f71f22f36f71a8e8f")
|
||||
.index(1)
|
||||
.key("/library/metadata/67085")
|
||||
.librarySectionID("3")
|
||||
.librarySectionKey("/library/sections/3")
|
||||
.librarySectionTitle("Music")
|
||||
.musicAnalysisVersion("1")
|
||||
.parentGuid("plex://album/65394d6d472b8ab03ef47f12")
|
||||
.parentIndex(1)
|
||||
.parentKey("/library/metadata/67084")
|
||||
.parentRatingKey("67084")
|
||||
.parentStudio("Reprise Records")
|
||||
.parentThumb("/library/metadata/67084/thumb/1705543314")
|
||||
.parentTitle("Saviors")
|
||||
.parentYear(2024)
|
||||
.ratingCount(45885)
|
||||
.ratingKey("67085")
|
||||
.sessionKey("203")
|
||||
.thumb("/library/metadata/67084/thumb/1705543314")
|
||||
.title("The American Dream Is Killing Me")
|
||||
.titleSort("American Dream Is Killing Me")
|
||||
.type("track")
|
||||
.updatedAt(1705543314)
|
||||
.viewOffset(1000)
|
||||
.media(List.of(
|
||||
GetSessionsMedia.builder()
|
||||
.audioChannels(2)
|
||||
.audioCodec("flac")
|
||||
.bitrate(1014)
|
||||
.container("flac")
|
||||
.duration(186240)
|
||||
.id("130355")
|
||||
.selected(true)
|
||||
.part(List.of(
|
||||
GetSessionsPart.builder()
|
||||
.container("flac")
|
||||
.duration(186240)
|
||||
.file("/music/Green Day/Saviors (2024)/Green Day - Saviors - 01 - The American Dream Is Killing Me.flac")
|
||||
.hasThumbnail("1")
|
||||
.id("130625")
|
||||
.key("/library/parts/130625/1705543268/file.flac")
|
||||
.size(23644000)
|
||||
.decision("directplay")
|
||||
.selected(true)
|
||||
.stream(List.of(
|
||||
GetSessionsStream.builder()
|
||||
.albumGain("-12.94")
|
||||
.albumPeak("1.000000")
|
||||
.albumRange("4.751014")
|
||||
.audioChannelLayout("stereo")
|
||||
.bitDepth(16)
|
||||
.bitrate(1014)
|
||||
.channels(2)
|
||||
.codec("flac")
|
||||
.displayTitle("FLAC (Stereo)")
|
||||
.extendedDisplayTitle("FLAC (Stereo)")
|
||||
.gain("-12.94")
|
||||
.id("352487")
|
||||
.index(0)
|
||||
.loudness("-5.94")
|
||||
.lra("1.74")
|
||||
.peak("1.000000")
|
||||
.samplingRate(44100)
|
||||
.selected(true)
|
||||
.streamType(2)
|
||||
.location("direct")
|
||||
.build()))
|
||||
.build()))
|
||||
.build()))
|
||||
.user(GetSessionsUser.builder()
|
||||
.id("1")
|
||||
.thumb("https://plex.tv/users/844780fc6f8a26b5/avatar?c=1705853661")
|
||||
.title("Blindkitty38")
|
||||
.build())
|
||||
.player(Player.builder()
|
||||
.address("10.10.10.171")
|
||||
.machineIdentifier("3tsdzir85m2onc3qyr255aq1")
|
||||
.model("standalone")
|
||||
.platform("windows")
|
||||
.platformVersion("10.0.22621")
|
||||
.product("Plex for Windows")
|
||||
.profile("Plex Desktop")
|
||||
.remotePublicAddress("68.248.140.20")
|
||||
.state("playing")
|
||||
.title("DESKTOP-BL80MTD")
|
||||
.version("1.85.0.4071-21128b56")
|
||||
.local(true)
|
||||
.relayed(false)
|
||||
.secure(true)
|
||||
.userID(1)
|
||||
.build())
|
||||
.session(Session.builder()
|
||||
.id("93h7e00ncblxncqw9lkfaoxi")
|
||||
.bandwidth(1050)
|
||||
.location("lan")
|
||||
.build())
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSessions_GetSessionHistory_ViewedAtDescending() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetSessionHistoryResponse res = sdk.sessions().getSessionHistory()
|
||||
.sort("<value>")
|
||||
.accountId(1L)
|
||||
.filter(QueryParamFilter.builder()
|
||||
.build())
|
||||
.librarySectionID(12L)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetSessionHistoryResponseBody.builder()
|
||||
.mediaContainer(GetSessionHistoryMediaContainer.builder()
|
||||
.size(10855)
|
||||
.metadata(List.of(
|
||||
GetSessionHistoryMetadata.builder()
|
||||
.historyKey("/status/sessions/history/1")
|
||||
.key("/library/metadata/32171")
|
||||
.ratingKey("32171")
|
||||
.librarySectionID("2")
|
||||
.parentKey("/library/metadata/32170")
|
||||
.grandparentKey("/library/metadata/32132")
|
||||
.title("The Noise That Blue Makes")
|
||||
.grandparentTitle("Taskmaster")
|
||||
.type("episode")
|
||||
.thumb("/library/metadata/32171/thumb/-1")
|
||||
.parentThumb("/library/metadata/32170/thumb/1654134301")
|
||||
.grandparentThumb("/library/metadata/32132/thumb/1703933346")
|
||||
.grandparentArt("/library/metadata/32132/art/1703933346")
|
||||
.index(1)
|
||||
.parentIndex(13)
|
||||
.originallyAvailableAt(LocalDate.parse("2022-04-14T00:00:00Z"))
|
||||
.viewedAt(1654139223)
|
||||
.accountID(1)
|
||||
.deviceID(5)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSessions_GetSessionHistory_ViewedAtAscending() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetSessionHistoryResponse res = sdk.sessions().getSessionHistory()
|
||||
.sort("<value>")
|
||||
.accountId(1L)
|
||||
.filter(QueryParamFilter.builder()
|
||||
.build())
|
||||
.librarySectionID(12L)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetSessionHistoryResponseBody.builder()
|
||||
.mediaContainer(GetSessionHistoryMediaContainer.builder()
|
||||
.size(10855)
|
||||
.metadata(List.of(
|
||||
GetSessionHistoryMetadata.builder()
|
||||
.historyKey("/status/sessions/history/1")
|
||||
.key("/library/metadata/32171")
|
||||
.ratingKey("32171")
|
||||
.librarySectionID("2")
|
||||
.parentKey("/library/metadata/32170")
|
||||
.grandparentKey("/library/metadata/32132")
|
||||
.title("The Noise That Blue Makes")
|
||||
.grandparentTitle("Taskmaster")
|
||||
.type("episode")
|
||||
.thumb("/library/metadata/32171/thumb/-1")
|
||||
.parentThumb("/library/metadata/32170/thumb/1654134301")
|
||||
.grandparentThumb("/library/metadata/32132/thumb/1703933346")
|
||||
.grandparentArt("/library/metadata/32132/art/1703933346")
|
||||
.index(1)
|
||||
.parentIndex(13)
|
||||
.originallyAvailableAt(LocalDate.parse("2022-04-14T00:00:00Z"))
|
||||
.viewedAt(1654139223)
|
||||
.accountID(1)
|
||||
.deviceID(5)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSessions_GetSessionHistory_RatingDescending() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetSessionHistoryResponse res = sdk.sessions().getSessionHistory()
|
||||
.sort("<value>")
|
||||
.accountId(1L)
|
||||
.filter(QueryParamFilter.builder()
|
||||
.build())
|
||||
.librarySectionID(12L)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetSessionHistoryResponseBody.builder()
|
||||
.mediaContainer(GetSessionHistoryMediaContainer.builder()
|
||||
.size(10855)
|
||||
.metadata(List.of(
|
||||
GetSessionHistoryMetadata.builder()
|
||||
.historyKey("/status/sessions/history/1")
|
||||
.key("/library/metadata/32171")
|
||||
.ratingKey("32171")
|
||||
.librarySectionID("2")
|
||||
.parentKey("/library/metadata/32170")
|
||||
.grandparentKey("/library/metadata/32132")
|
||||
.title("The Noise That Blue Makes")
|
||||
.grandparentTitle("Taskmaster")
|
||||
.type("episode")
|
||||
.thumb("/library/metadata/32171/thumb/-1")
|
||||
.parentThumb("/library/metadata/32170/thumb/1654134301")
|
||||
.grandparentThumb("/library/metadata/32132/thumb/1703933346")
|
||||
.grandparentArt("/library/metadata/32132/art/1703933346")
|
||||
.index(1)
|
||||
.parentIndex(13)
|
||||
.originallyAvailableAt(LocalDate.parse("2022-04-14T00:00:00Z"))
|
||||
.viewedAt(1654139223)
|
||||
.accountID(1)
|
||||
.deviceID(5)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSessions_GetSessionHistory_RatingAscending() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetSessionHistoryResponse res = sdk.sessions().getSessionHistory()
|
||||
.sort("<value>")
|
||||
.accountId(1L)
|
||||
.filter(QueryParamFilter.builder()
|
||||
.build())
|
||||
.librarySectionID(12L)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetSessionHistoryResponseBody.builder()
|
||||
.mediaContainer(GetSessionHistoryMediaContainer.builder()
|
||||
.size(10855)
|
||||
.metadata(List.of(
|
||||
GetSessionHistoryMetadata.builder()
|
||||
.historyKey("/status/sessions/history/1")
|
||||
.key("/library/metadata/32171")
|
||||
.ratingKey("32171")
|
||||
.librarySectionID("2")
|
||||
.parentKey("/library/metadata/32170")
|
||||
.grandparentKey("/library/metadata/32132")
|
||||
.title("The Noise That Blue Makes")
|
||||
.grandparentTitle("Taskmaster")
|
||||
.type("episode")
|
||||
.thumb("/library/metadata/32171/thumb/-1")
|
||||
.parentThumb("/library/metadata/32170/thumb/1654134301")
|
||||
.grandparentThumb("/library/metadata/32132/thumb/1703933346")
|
||||
.grandparentArt("/library/metadata/32132/art/1703933346")
|
||||
.index(1)
|
||||
.parentIndex(13)
|
||||
.originallyAvailableAt(LocalDate.parse("2022-04-14T00:00:00Z"))
|
||||
.viewedAt(1654139223)
|
||||
.accountID(1)
|
||||
.deviceID(5)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSessions_GetSessionHistory_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetSessionHistoryResponse res = sdk.sessions().getSessionHistory()
|
||||
.sort("<value>")
|
||||
.accountId(1L)
|
||||
.filter(QueryParamFilter.builder()
|
||||
.build())
|
||||
.librarySectionID(12L)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetSessionHistoryResponseBody.builder()
|
||||
.mediaContainer(GetSessionHistoryMediaContainer.builder()
|
||||
.size(10855)
|
||||
.metadata(List.of(
|
||||
GetSessionHistoryMetadata.builder()
|
||||
.historyKey("/status/sessions/history/1")
|
||||
.key("/library/metadata/32171")
|
||||
.ratingKey("32171")
|
||||
.librarySectionID("2")
|
||||
.parentKey("/library/metadata/32170")
|
||||
.grandparentKey("/library/metadata/32132")
|
||||
.title("The Noise That Blue Makes")
|
||||
.grandparentTitle("Taskmaster")
|
||||
.type("episode")
|
||||
.thumb("/library/metadata/32171/thumb/-1")
|
||||
.parentThumb("/library/metadata/32170/thumb/1654134301")
|
||||
.grandparentThumb("/library/metadata/32132/thumb/1703933346")
|
||||
.grandparentArt("/library/metadata/32132/art/1703933346")
|
||||
.index(1)
|
||||
.parentIndex(13)
|
||||
.originallyAvailableAt(LocalDate.parse("2022-04-14T00:00:00Z"))
|
||||
.viewedAt(1654139223)
|
||||
.accountID(1)
|
||||
.deviceID(5)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSessions_GetSessionHistory_ViewedAt() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetSessionHistoryResponse res = sdk.sessions().getSessionHistory()
|
||||
.sort("<value>")
|
||||
.accountId(1L)
|
||||
.filter(QueryParamFilter.builder()
|
||||
.build())
|
||||
.librarySectionID(12L)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetSessionHistoryResponseBody.builder()
|
||||
.mediaContainer(GetSessionHistoryMediaContainer.builder()
|
||||
.size(10855)
|
||||
.metadata(List.of(
|
||||
GetSessionHistoryMetadata.builder()
|
||||
.historyKey("/status/sessions/history/1")
|
||||
.key("/library/metadata/32171")
|
||||
.ratingKey("32171")
|
||||
.librarySectionID("2")
|
||||
.parentKey("/library/metadata/32170")
|
||||
.grandparentKey("/library/metadata/32132")
|
||||
.title("The Noise That Blue Makes")
|
||||
.grandparentTitle("Taskmaster")
|
||||
.type("episode")
|
||||
.thumb("/library/metadata/32171/thumb/-1")
|
||||
.parentThumb("/library/metadata/32170/thumb/1654134301")
|
||||
.grandparentThumb("/library/metadata/32132/thumb/1703933346")
|
||||
.grandparentArt("/library/metadata/32132/art/1703933346")
|
||||
.index(1)
|
||||
.parentIndex(13)
|
||||
.originallyAvailableAt(LocalDate.parse("2022-04-14T00:00:00Z"))
|
||||
.viewedAt(1654139223)
|
||||
.accountID(1)
|
||||
.deviceID(5)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSessions_GetTranscodeSessions() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetTranscodeSessionsResponse res = sdk.sessions().getTranscodeSessions()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetTranscodeSessionsResponseBody.builder()
|
||||
.mediaContainer(GetTranscodeSessionsMediaContainer.builder()
|
||||
.size(1)
|
||||
.transcodeSession(List.of(
|
||||
TranscodeSession.builder()
|
||||
.key("vv3i2q2lax92qlzul1hbd4bx")
|
||||
.throttled(false)
|
||||
.complete(false)
|
||||
.progress(1.7999999523162842d)
|
||||
.size(-22)
|
||||
.speed(25.100000381469727d)
|
||||
.error(false)
|
||||
.duration(1445695)
|
||||
.remaining(53)
|
||||
.context("streaming")
|
||||
.sourceVideoCodec("h264")
|
||||
.sourceAudioCodec("aac")
|
||||
.videoDecision("transcode")
|
||||
.audioDecision("transcode")
|
||||
.subtitleDecision("burn")
|
||||
.protocol("http")
|
||||
.container("mkv")
|
||||
.videoCodec("h264")
|
||||
.audioCodec("opus")
|
||||
.audioChannels(1)
|
||||
.transcodeHwRequested(true)
|
||||
.timeStamp(1705895805.4919229d)
|
||||
.maxOffsetAvailable(29.53d)
|
||||
.minOffsetAvailable(3.003000020980835d)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testSessions_StopTranscodeSession() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
StopTranscodeSessionResponse res = sdk.sessions().stopTranscodeSession()
|
||||
.sessionKey("zz7llzqlx8w9vnrsbnwhbmep")
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,179 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.Account;
|
||||
import dev.plexapi.sdk.models.operations.GetBandwidthStatisticsAccount;
|
||||
import dev.plexapi.sdk.models.operations.GetBandwidthStatisticsDevice;
|
||||
import dev.plexapi.sdk.models.operations.GetBandwidthStatisticsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetBandwidthStatisticsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetBandwidthStatisticsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetResourcesStatisticsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetResourcesStatisticsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetResourcesStatisticsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.GetStatisticsDevice;
|
||||
import dev.plexapi.sdk.models.operations.GetStatisticsMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetStatisticsResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetStatisticsResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.StatisticsBandwidth;
|
||||
import dev.plexapi.sdk.models.operations.StatisticsMedia;
|
||||
import dev.plexapi.sdk.models.operations.StatisticsResources;
|
||||
import java.lang.Exception;
|
||||
import java.util.List;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class StatisticsTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testStatistics_GetStatistics_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetStatisticsResponse res = sdk.statistics().getStatistics()
|
||||
.timespan(4L)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetStatisticsResponseBody.builder()
|
||||
.mediaContainer(GetStatisticsMediaContainer.builder()
|
||||
.size(5497)
|
||||
.device(List.of(
|
||||
GetStatisticsDevice.builder()
|
||||
.id(208)
|
||||
.name("Roku Express")
|
||||
.platform("Roku")
|
||||
.clientIdentifier("793095d235660625108ef785cc7646e9")
|
||||
.createdAt(1706470556)
|
||||
.build()))
|
||||
.account(List.of(
|
||||
Account.builder()
|
||||
.id(238960586)
|
||||
.key("/accounts/238960586")
|
||||
.name("Diane")
|
||||
.defaultAudioLanguage("en")
|
||||
.autoSelectAudio(true)
|
||||
.defaultSubtitleLanguage("en")
|
||||
.subtitleMode(1)
|
||||
.thumb("https://plex.tv/users/50d83634246da1de/avatar?c=1707110967")
|
||||
.build()))
|
||||
.statisticsMedia(List.of(
|
||||
StatisticsMedia.builder()
|
||||
.accountID(1)
|
||||
.deviceID(13)
|
||||
.timespan(4)
|
||||
.at(1707141600)
|
||||
.metadataType(4)
|
||||
.count(1)
|
||||
.duration(1555)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testStatistics_GetResourcesStatistics_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetResourcesStatisticsResponse res = sdk.statistics().getResourcesStatistics()
|
||||
.timespan(4L)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetResourcesStatisticsResponseBody.builder()
|
||||
.mediaContainer(GetResourcesStatisticsMediaContainer.builder()
|
||||
.size(5497)
|
||||
.statisticsResources(List.of(
|
||||
StatisticsResources.builder()
|
||||
.timespan(6L)
|
||||
.at(1718384427L)
|
||||
.hostCpuUtilization(1.276f)
|
||||
.processCpuUtilization(0.025f)
|
||||
.hostMemoryUtilization(17.026f)
|
||||
.processMemoryUtilization(0.493f)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testStatistics_GetBandwidthStatistics_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetBandwidthStatisticsResponse res = sdk.statistics().getBandwidthStatistics()
|
||||
.timespan(4L)
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetBandwidthStatisticsResponseBody.builder()
|
||||
.mediaContainer(GetBandwidthStatisticsMediaContainer.builder()
|
||||
.size(5497)
|
||||
.device(List.of(
|
||||
GetBandwidthStatisticsDevice.builder()
|
||||
.id(208)
|
||||
.name("Roku Express")
|
||||
.platform("Roku")
|
||||
.clientIdentifier("793095d235660625108ef785cc7646e9")
|
||||
.createdAt(1706470556)
|
||||
.build()))
|
||||
.account(List.of(
|
||||
GetBandwidthStatisticsAccount.builder()
|
||||
.id(238960586)
|
||||
.key("/accounts/238960586")
|
||||
.name("Diane")
|
||||
.defaultAudioLanguage("en")
|
||||
.autoSelectAudio(true)
|
||||
.defaultSubtitleLanguage("en")
|
||||
.subtitleMode(1)
|
||||
.thumb("https://plex.tv/users/50d83634246da1de/avatar?c=1707110967")
|
||||
.build()))
|
||||
.statisticsBandwidth(List.of(
|
||||
StatisticsBandwidth.builder()
|
||||
.accountID(238960586)
|
||||
.deviceID(208)
|
||||
.timespan(6L)
|
||||
.at(1718387650)
|
||||
.lan(true)
|
||||
.bytes(22L)
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,120 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.ApplyUpdatesResponse;
|
||||
import dev.plexapi.sdk.models.operations.CheckForUpdatesResponse;
|
||||
import dev.plexapi.sdk.models.operations.Download;
|
||||
import dev.plexapi.sdk.models.operations.GetUpdateStatusMediaContainer;
|
||||
import dev.plexapi.sdk.models.operations.GetUpdateStatusResponse;
|
||||
import dev.plexapi.sdk.models.operations.GetUpdateStatusResponseBody;
|
||||
import dev.plexapi.sdk.models.operations.Release;
|
||||
import dev.plexapi.sdk.models.operations.Skip;
|
||||
import dev.plexapi.sdk.models.operations.Tonight;
|
||||
import java.lang.Exception;
|
||||
import java.util.List;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class UpdaterTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testUpdater_GetUpdateStatus() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetUpdateStatusResponse res = sdk.updater().getUpdateStatus()
|
||||
.call();
|
||||
|
||||
assertEquals(
|
||||
GetUpdateStatusResponseBody.builder()
|
||||
.mediaContainer(GetUpdateStatusMediaContainer.builder()
|
||||
.size(1)
|
||||
.canInstall(false)
|
||||
.checkedAt(1705801232)
|
||||
.downloadURL("https://plex.tv/downloads/latest/5?channel=8&build=linux-x86_64&distro=redhat&X-Plex-Token=xxxxxxxxxxxxxxxxxxxx")
|
||||
.status(0)
|
||||
.release(List.of(
|
||||
Release.builder()
|
||||
.key("https://plex.tv/updater/releases/5136")
|
||||
.version("1.40.0.7775-456fbaf97")
|
||||
.added("(PLEASE NOTE) This version makes changes to the database which will make it compatible only with server versions 1.31.2 or higher (released March 14). You will not be able to use your database on Plex Media Server versions lower than this after this update. Please also be patient when updating to this version if you have a very large database and allow the upgrade process to finish.\n(Collections) Items added to a collection from the item context menu will now lock the collection field on the items (#12793)
|
||||
(Music) Store track genres and add filtering options (#14653)
|
||||
(Music) Support ID3v2.4 null-separated tags for genres and release type (#14653)
|
||||
(View History) No longer create a view history entry for items marked as played (#10888)
|
||||
(Web) Updated to 4.118.0")
|
||||
.fixed("(Agents) Changing a 'Other Videos' type library to the modern movie agent would fail (#14483)\n(Agents) It is possible that agents are not initialised during startup on rare occasions (#14654)
|
||||
(Agents) Remove the legacy OpenSubtitles agent which is no longer supported upstream (#14667)
|
||||
(Collection) Server could become unresponsive when collection membership changes (#14612)
|
||||
(DVR) Previously watched recordings could be deleted without being watched again (#13779)
|
||||
(Libraries) When performing fix match on items from certain music libraries the language would default to Arabic (#14501)
|
||||
(Library) The Content Rating not equal to None filter does not work (#14620)
|
||||
(Search) Album search results could contain all the album's tracks too (#14486)
|
||||
(Subtitles) In some circumstances, sidecar subtitles can show up for media when they're no longer available (#14674)
|
||||
(Transcoder) HW encoding would fail on devices with no rate control (#14222)
|
||||
(Transcoder) Software transcoding on Ubuntu could cause unexpected behavior (#14605)")
|
||||
.downloadURL("https://plex.tv/downloads/latest/5?channel=8&build=linux-x86_64&distro=redhat&X-Plex-Token=xxxxxxxxxxxxxxxxxxxx")
|
||||
.state("notify")
|
||||
.build()))
|
||||
.build())
|
||||
.build(),
|
||||
res.object().get());
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testUpdater_CheckForUpdates_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
CheckForUpdatesResponse res = sdk.updater().checkForUpdates()
|
||||
.download(Download.ONE)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testUpdater_ApplyUpdates_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
ApplyUpdatesResponse res = sdk.updater().applyUpdates()
|
||||
.tonight(Tonight.ONE)
|
||||
.skip(Skip.ONE)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,92 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.GetTimelineRequest;
|
||||
import dev.plexapi.sdk.models.operations.GetTimelineResponse;
|
||||
import dev.plexapi.sdk.models.operations.StartUniversalTranscodeRequest;
|
||||
import dev.plexapi.sdk.models.operations.StartUniversalTranscodeResponse;
|
||||
import dev.plexapi.sdk.models.operations.State;
|
||||
import java.lang.Exception;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class VideoTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testVideo_GetTimeline_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetTimelineRequest req = GetTimelineRequest.builder()
|
||||
.ratingKey(23409d)
|
||||
.key("/library/metadata/23409")
|
||||
.state(State.PLAYING)
|
||||
.hasMDE(1d)
|
||||
.time(2000d)
|
||||
.duration(10000d)
|
||||
.context("home:hub.continueWatching")
|
||||
.playQueueItemID(1d)
|
||||
.playBackTime(2000d)
|
||||
.row(1d)
|
||||
.build();
|
||||
|
||||
GetTimelineResponse res = sdk.video().getTimeline()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testVideo_StartUniversalTranscode_() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
StartUniversalTranscodeRequest req = StartUniversalTranscodeRequest.builder()
|
||||
.hasMDE(1d)
|
||||
.path("/library/metadata/23409")
|
||||
.mediaIndex(0d)
|
||||
.partIndex(0d)
|
||||
.protocol("hls")
|
||||
.fastSeek(0d)
|
||||
.directPlay(0d)
|
||||
.directStream(0d)
|
||||
.subtitleSize(100d)
|
||||
.subtites("burn")
|
||||
.audioBoost(100d)
|
||||
.location("lan")
|
||||
.mediaBufferSize(102400d)
|
||||
.session("zvcage8b7rkioqcm8f4uns4c")
|
||||
.addDebugOverlay(0d)
|
||||
.autoAdjustQuality(0d)
|
||||
.build();
|
||||
|
||||
StartUniversalTranscodeResponse res = sdk.video().startUniversalTranscode()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,44 +0,0 @@
|
||||
/*
|
||||
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
package dev.plexapi.sdk;
|
||||
|
||||
import dev.plexapi.sdk.models.operations.Filter;
|
||||
import dev.plexapi.sdk.models.operations.GetWatchListRequest;
|
||||
import dev.plexapi.sdk.models.operations.GetWatchListResponse;
|
||||
import java.lang.Exception;
|
||||
import org.junit.jupiter.api.Disabled;
|
||||
import org.junit.jupiter.api.Test;
|
||||
|
||||
public class WatchlistTests {
|
||||
|
||||
@Disabled // test marked as skipped for java or generated unit tests not production ready yet
|
||||
@Test
|
||||
public void testWatchlist_GetWatchList() throws Exception {
|
||||
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.clientID("gcgzw5rz2xovp84b4vha3a40")
|
||||
.clientName("Plex Web")
|
||||
.clientVersion("4.133.0")
|
||||
.clientPlatform("Chrome")
|
||||
.deviceName("Linux")
|
||||
.build();
|
||||
|
||||
GetWatchListRequest req = GetWatchListRequest.builder()
|
||||
.filter(Filter.RELEASED)
|
||||
.xPlexToken("CV5xoxjTpFKUzBTShsaf")
|
||||
.xPlexContainerStart(0)
|
||||
.xPlexContainerSize(50)
|
||||
.build();
|
||||
|
||||
GetWatchListResponse res = sdk.watchlist().getWatchList()
|
||||
.request(req)
|
||||
.call();
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user