mirror of
https://github.com/LukeHagar/plexjava.git
synced 2025-12-06 12:37:47 +00:00
ci: regenerated with OpenAPI Doc , Speakeasy CLI 1.615.2
This commit is contained in:
@@ -23,6 +23,7 @@ Get Server Activities
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getServerActivities" method="get" path="/activities" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -37,7 +38,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetServerActivitiesBadRequest, GetServerActivitiesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetServerActivitiesResponse res = sdk.activities().getServerActivities()
|
||||
@@ -68,6 +69,7 @@ Cancel Server Activities
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="cancelServerActivities" method="delete" path="/activities/{activityUUID}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -82,7 +84,7 @@ public class Application {
|
||||
public static void main(String[] args) throws CancelServerActivitiesBadRequest, CancelServerActivitiesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
CancelServerActivitiesResponse res = sdk.activities().cancelServerActivities()
|
||||
|
||||
@@ -20,6 +20,7 @@ This endpoint provides the caller with a temporary token with the same access le
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getTransientToken" method="get" path="/security/token" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -34,7 +35,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetTransientTokenBadRequest, GetTransientTokenUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetTransientTokenResponse res = sdk.authentication().getTransientToken()
|
||||
@@ -74,6 +75,7 @@ Note: requires Plex Media Server >= 1.15.4.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getSourceConnectionInformation" method="get" path="/security/resources" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -88,7 +90,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetSourceConnectionInformationBadRequest, GetSourceConnectionInformationUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetSourceConnectionInformationResponse res = sdk.authentication().getSourceConnectionInformation()
|
||||
@@ -124,6 +126,7 @@ Get the User data from the provided X-Plex-Token
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getTokenDetails" method="get" path="/user" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -138,7 +141,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetTokenDetailsBadRequest, GetTokenDetailsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetTokenDetailsResponse res = sdk.authentication().getTokenDetails()
|
||||
@@ -175,6 +178,7 @@ Sign in user with username and password and return user data with Plex authentic
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="post-users-sign-in-data" method="post" path="/users/signin" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
|
||||
@@ -20,6 +20,7 @@ Returns a list of butler tasks
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getButlerTasks" method="get" path="/butler" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -34,7 +35,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetButlerTasksBadRequest, GetButlerTasksUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetButlerTasksResponse res = sdk.butler().getButlerTasks()
|
||||
@@ -70,6 +71,7 @@ This endpoint will attempt to start all Butler tasks that are enabled in the set
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="startAllTasks" method="post" path="/butler" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -84,7 +86,7 @@ public class Application {
|
||||
public static void main(String[] args) throws StartAllTasksBadRequest, StartAllTasksUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
StartAllTasksResponse res = sdk.butler().startAllTasks()
|
||||
@@ -114,6 +116,7 @@ This endpoint will stop all currently running tasks and remove any scheduled tas
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="stopAllTasks" method="delete" path="/butler" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -128,7 +131,7 @@ public class Application {
|
||||
public static void main(String[] args) throws StopAllTasksBadRequest, StopAllTasksUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
StopAllTasksResponse res = sdk.butler().stopAllTasks()
|
||||
@@ -162,6 +165,7 @@ This endpoint will attempt to start a single Butler task that is enabled in the
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="startTask" method="post" path="/butler/{taskName}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -177,7 +181,7 @@ public class Application {
|
||||
public static void main(String[] args) throws StartTaskBadRequest, StartTaskUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
StartTaskResponse res = sdk.butler().startTask()
|
||||
@@ -214,6 +218,7 @@ This endpoint will stop a currently running task by name, or remove it from the
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="stopTask" method="delete" path="/butler/{taskName}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -229,7 +234,7 @@ public class Application {
|
||||
public static void main(String[] args) throws StopTaskBadRequest, StopTaskUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
StopTaskResponse res = sdk.butler().stopTask()
|
||||
|
||||
@@ -18,6 +18,7 @@ Get Global Hubs filtered by the parameters provided.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getGlobalHubs" method="get" path="/hubs" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -32,7 +33,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetGlobalHubsBadRequest, GetGlobalHubsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetGlobalHubsResponse res = sdk.hubs().getGlobalHubs()
|
||||
@@ -71,6 +72,7 @@ This endpoint will return the recently added content.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-recently-added" method="get" path="/hubs/home/recentlyAdded" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -83,7 +85,7 @@ public class Application {
|
||||
public static void main(String[] args) throws Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetRecentlyAddedRequest req = GetRecentlyAddedRequest.builder()
|
||||
@@ -127,6 +129,7 @@ This endpoint will return a list of library specific hubs
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getLibraryHubs" method="get" path="/hubs/sections/{sectionId}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -141,7 +144,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetLibraryHubsBadRequest, GetLibraryHubsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetLibraryHubsResponse res = sdk.hubs().getLibraryHubs()
|
||||
|
||||
@@ -35,6 +35,7 @@ This resource returns hash values for local files
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getFileHash" method="get" path="/library/hashes" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -49,11 +50,11 @@ public class Application {
|
||||
public static void main(String[] args) throws GetFileHashBadRequest, GetFileHashUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetFileHashResponse res = sdk.library().getFileHash()
|
||||
.url("file://C:\Image.png&type=13")
|
||||
.url("file://C:\\Image.png&type=13")
|
||||
.call();
|
||||
|
||||
// handle response
|
||||
@@ -87,6 +88,7 @@ This endpoint will return the recently added content.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-recently-added-library" method="get" path="/library/recentlyAdded" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -102,7 +104,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetRecentlyAddedLibraryBadRequest, GetRecentlyAddedLibraryUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetRecentlyAddedLibraryRequest req = GetRecentlyAddedLibraryRequest.builder()
|
||||
@@ -166,6 +168,7 @@ This allows a client to provide a rich interface around the media (e.g. allow so
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-all-libraries" method="get" path="/library/sections" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -180,7 +183,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetAllLibrariesBadRequest, GetAllLibrariesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetAllLibrariesResponse res = sdk.library().getAllLibraries()
|
||||
@@ -250,6 +253,7 @@ Each type in the library comes with a set of filters and sorts, aiding in buildi
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-library-details" method="get" path="/library/sections/{sectionKey}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -265,7 +269,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetLibraryDetailsBadRequest, GetLibraryDetailsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetLibraryDetailsResponse res = sdk.library().getLibraryDetails()
|
||||
@@ -305,6 +309,7 @@ Delete a library using a specific section id
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="deleteLibrary" method="delete" path="/library/sections/{sectionKey}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -319,7 +324,7 @@ public class Application {
|
||||
public static void main(String[] args) throws DeleteLibraryBadRequest, DeleteLibraryUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
DeleteLibraryResponse res = sdk.library().deleteLibrary()
|
||||
@@ -376,6 +381,7 @@ Fetches details from a specific section of the library identified by a section k
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-library-items" method="get" path="/library/sections/{sectionKey}/{tag}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -390,7 +396,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetLibraryItemsBadRequest, GetLibraryItemsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetLibraryItemsRequest req = GetLibraryItemsRequest.builder()
|
||||
@@ -437,6 +443,7 @@ Retrieves a list of all general media data for this library.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-library-sections-all" method="get" path="/library/sections/{sectionKey}/all" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -451,7 +458,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetLibrarySectionsAllBadRequest, GetLibrarySectionsAllUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetLibrarySectionsAllRequest req = GetLibrarySectionsAllRequest.builder()
|
||||
@@ -500,6 +507,7 @@ This endpoint Refreshes all the Metadata of the library.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-refresh-library-metadata" method="get" path="/library/sections/{sectionKey}/refresh" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -515,7 +523,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetRefreshLibraryMetadataBadRequest, GetRefreshLibraryMetadataUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetRefreshLibraryMetadataResponse res = sdk.library().getRefreshLibraryMetadata()
|
||||
@@ -571,6 +579,7 @@ Each type in the library comes with a set of filters and sorts, aiding in buildi
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-search-library" method="get" path="/library/sections/{sectionKey}/search" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -586,7 +595,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetSearchLibraryBadRequest, GetSearchLibraryUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetSearchLibraryResponse res = sdk.library().getSearchLibrary()
|
||||
@@ -627,6 +636,7 @@ Retrieves a list of all the genres that are found for the media in this library.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-genres-library" method="get" path="/library/sections/{sectionKey}/genre" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -642,7 +652,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetGenresLibraryBadRequest, GetGenresLibraryUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetGenresLibraryResponse res = sdk.library().getGenresLibrary()
|
||||
@@ -683,6 +693,7 @@ Retrieves a list of all the countries that are found for the media in this libra
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-countries-library" method="get" path="/library/sections/{sectionKey}/country" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -698,7 +709,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetCountriesLibraryBadRequest, GetCountriesLibraryUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetCountriesLibraryResponse res = sdk.library().getCountriesLibrary()
|
||||
@@ -739,6 +750,7 @@ Retrieves a list of all the actors that are found for the media in this library.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-actors-library" method="get" path="/library/sections/{sectionKey}/actor" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -754,7 +766,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetActorsLibraryBadRequest, GetActorsLibraryUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetActorsLibraryResponse res = sdk.library().getActorsLibrary()
|
||||
@@ -795,6 +807,7 @@ Search the provided query across all library sections, or a single section, and
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-search-all-libraries" method="get" path="/library/search" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -810,7 +823,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetSearchAllLibrariesBadRequest, GetSearchAllLibrariesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetSearchAllLibrariesRequest req = GetSearchAllLibrariesRequest.builder()
|
||||
@@ -859,6 +872,7 @@ Multiple rating keys can be provided as a comma-separated list (e.g., "21119,216
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-media-meta-data" method="get" path="/library/metadata/{ratingKey}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -874,7 +888,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetMediaMetaDataBadRequest, GetMediaMetaDataUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetMediaMetaDataRequest req = GetMediaMetaDataRequest.builder()
|
||||
@@ -929,6 +943,7 @@ Returns the background artwork for a library item.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-media-arts" method="get" path="/library/metadata/{ratingKey}/arts" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -941,7 +956,7 @@ public class Application {
|
||||
public static void main(String[] args) throws Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetMediaArtsResponse res = sdk.library().getMediaArts()
|
||||
@@ -977,6 +992,7 @@ Uploads an image to use as the background artwork for a library item, either fro
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="post-media-arts" method="post" path="/library/metadata/{ratingKey}/arts" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -989,7 +1005,7 @@ public class Application {
|
||||
public static void main(String[] args) throws Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
PostMediaArtsResponse res = sdk.library().postMediaArts()
|
||||
@@ -997,7 +1013,6 @@ public class Application {
|
||||
.url("https://api.mediux.pro/assets/fcfdc487-dd07-4993-a0c1-0a3015362e5b")
|
||||
.call();
|
||||
|
||||
// handle response
|
||||
}
|
||||
}
|
||||
```
|
||||
@@ -1008,7 +1023,7 @@ public class Application {
|
||||
| ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ |
|
||||
| `ratingKey` | *long* | :heavy_check_mark: | the id of the library item to return the posters of. | 2268 |
|
||||
| `url` | *Optional\<String>* | :heavy_minus_sign: | The URL of the image, if uploading a remote image | https://api.mediux.pro/assets/fcfdc487-dd07-4993-a0c1-0a3015362e5b |
|
||||
| `requestBody` | *Optional\<byte[]>* | :heavy_minus_sign: | The contents of the image, if uploading a local file | |
|
||||
| `requestBody` | byte[] | :heavy_minus_sign: | The contents of the image, if uploading a local file | |
|
||||
|
||||
### Response
|
||||
|
||||
@@ -1026,6 +1041,7 @@ Returns the available posters for a library item.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-media-posters" method="get" path="/library/metadata/{ratingKey}/posters" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -1038,7 +1054,7 @@ public class Application {
|
||||
public static void main(String[] args) throws Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetMediaPostersResponse res = sdk.library().getMediaPosters()
|
||||
@@ -1074,6 +1090,7 @@ Uploads a poster to a library item, either from a local file or a remote URL
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="post-media-poster" method="post" path="/library/metadata/{ratingKey}/posters" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -1086,7 +1103,7 @@ public class Application {
|
||||
public static void main(String[] args) throws Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
PostMediaPosterResponse res = sdk.library().postMediaPoster()
|
||||
@@ -1094,7 +1111,6 @@ public class Application {
|
||||
.url("https://api.mediux.pro/assets/fcfdc487-dd07-4993-a0c1-0a3015362e5b")
|
||||
.call();
|
||||
|
||||
// handle response
|
||||
}
|
||||
}
|
||||
```
|
||||
@@ -1105,7 +1121,7 @@ public class Application {
|
||||
| ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ | ------------------------------------------------------------------ |
|
||||
| `ratingKey` | *long* | :heavy_check_mark: | the id of the library item to return the posters of. | 2268 |
|
||||
| `url` | *Optional\<String>* | :heavy_minus_sign: | The URL of the image, if uploading a remote image | https://api.mediux.pro/assets/fcfdc487-dd07-4993-a0c1-0a3015362e5b |
|
||||
| `requestBody` | *Optional\<byte[]>* | :heavy_minus_sign: | The contents of the image, if uploading a local file | |
|
||||
| `requestBody` | byte[] | :heavy_minus_sign: | The contents of the image, if uploading a local file | |
|
||||
|
||||
### Response
|
||||
|
||||
@@ -1124,6 +1140,7 @@ This endpoint will return the children of of a library item specified with the r
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getMetadataChildren" method="get" path="/library/metadata/{ratingKey}/children" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -1138,7 +1155,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetMetadataChildrenBadRequest, GetMetadataChildrenUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetMetadataChildrenResponse res = sdk.library().getMetadataChildren()
|
||||
@@ -1179,6 +1196,7 @@ This endpoint will return the top watched content from libraries of a certain ty
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getTopWatchedContent" method="get" path="/library/all/top" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -1193,7 +1211,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetTopWatchedContentBadRequest, GetTopWatchedContentUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetTopWatchedContentResponse res = sdk.library().getTopWatchedContent()
|
||||
|
||||
@@ -19,6 +19,7 @@ This endpoint will write a single-line log message, including a level and source
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="logLine" method="get" path="/log" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -34,7 +35,7 @@ public class Application {
|
||||
public static void main(String[] args) throws LogLineBadRequest, LogLineUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
LogLineResponse res = sdk.log().logLine()
|
||||
@@ -95,6 +96,7 @@ Ensure each parameter is properly URL-encoded to avoid interpretation issues.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="logMultiLine" method="post" path="/log" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -110,7 +112,7 @@ public class Application {
|
||||
public static void main(String[] args) throws LogMultiLineBadRequest, LogMultiLineUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
String req = "level=4&message=Test%20message%201&source=postman\nlevel=3&message=Test%20message%202&source=postman\nlevel=1&message=Test%20message%203&source=postman";
|
||||
@@ -149,6 +151,7 @@ This endpoint will enable all Plex Media Serverlogs to be sent to the Papertrail
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="enablePaperTrail" method="get" path="/log/networked" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -163,7 +166,7 @@ public class Application {
|
||||
public static void main(String[] args) throws EnablePaperTrailBadRequest, EnablePaperTrailUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
EnablePaperTrailResponse res = sdk.log().enablePaperTrail()
|
||||
|
||||
@@ -20,6 +20,7 @@ This will mark the provided media key as Played.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="markPlayed" method="get" path="/:/scrobble" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -34,11 +35,11 @@ public class Application {
|
||||
public static void main(String[] args) throws MarkPlayedBadRequest, MarkPlayedUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
MarkPlayedResponse res = sdk.media().markPlayed()
|
||||
.key(59398)
|
||||
.key(59398d)
|
||||
.call();
|
||||
|
||||
// handle response
|
||||
@@ -70,6 +71,7 @@ This will mark the provided media key as Unplayed.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="markUnplayed" method="get" path="/:/unscrobble" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -84,11 +86,11 @@ public class Application {
|
||||
public static void main(String[] args) throws MarkUnplayedBadRequest, MarkUnplayedUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
MarkUnplayedResponse res = sdk.media().markUnplayed()
|
||||
.key(59398)
|
||||
.key(59398d)
|
||||
.call();
|
||||
|
||||
// handle response
|
||||
@@ -121,6 +123,7 @@ This API command can be used to update the play progress of a media item.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="updatePlayProgress" method="post" path="/:/progress" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -135,12 +138,12 @@ public class Application {
|
||||
public static void main(String[] args) throws UpdatePlayProgressBadRequest, UpdatePlayProgressUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
UpdatePlayProgressResponse res = sdk.media().updatePlayProgress()
|
||||
.key("<key>")
|
||||
.time(90000)
|
||||
.time(90000d)
|
||||
.state("played")
|
||||
.call();
|
||||
|
||||
@@ -175,6 +178,7 @@ Gets the banner image of the media item
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-banner-image" method="get" path="/library/metadata/{ratingKey}/banner" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -190,7 +194,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetBannerImageBadRequest, GetBannerImageUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetBannerImageRequest req = GetBannerImageRequest.builder()
|
||||
@@ -237,6 +241,7 @@ Gets the thumbnail image of the media item
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-thumb-image" method="get" path="/library/metadata/{ratingKey}/thumb" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -252,7 +257,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetThumbImageBadRequest, GetThumbImageUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetThumbImageRequest req = GetThumbImageRequest.builder()
|
||||
|
||||
@@ -30,6 +30,7 @@ Create a new playlist. By default the playlist is blank. To create a playlist al
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="createPlaylist" method="post" path="/playlists" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -44,7 +45,7 @@ public class Application {
|
||||
public static void main(String[] args) throws CreatePlaylistBadRequest, CreatePlaylistUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
CreatePlaylistRequest req = CreatePlaylistRequest.builder()
|
||||
@@ -89,6 +90,7 @@ Get All Playlists given the specified filters.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getPlaylists" method="get" path="/playlists" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -103,7 +105,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetPlaylistsBadRequest, GetPlaylistsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetPlaylistsResponse res = sdk.playlists().getPlaylists()
|
||||
@@ -143,6 +145,7 @@ Smart playlist details contain the `content` attribute. This is the content URI
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getPlaylist" method="get" path="/playlists/{playlistID}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -157,7 +160,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetPlaylistBadRequest, GetPlaylistUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetPlaylistResponse res = sdk.playlists().getPlaylist()
|
||||
@@ -196,6 +199,7 @@ This endpoint will delete a playlist
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="deletePlaylist" method="delete" path="/playlists/{playlistID}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -210,7 +214,7 @@ public class Application {
|
||||
public static void main(String[] args) throws DeletePlaylistBadRequest, DeletePlaylistUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
DeletePlaylistResponse res = sdk.playlists().deletePlaylist()
|
||||
@@ -247,6 +251,7 @@ From PMS version 1.9.1 clients can also edit playlist metadata using this endpoi
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="updatePlaylist" method="put" path="/playlists/{playlistID}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -261,7 +266,7 @@ public class Application {
|
||||
public static void main(String[] args) throws UpdatePlaylistBadRequest, UpdatePlaylistUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
UpdatePlaylistResponse res = sdk.playlists().updatePlaylist()
|
||||
@@ -303,6 +308,7 @@ Note that for dumb playlists, items have a `playlistItemID` attribute which is u
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getPlaylistContents" method="get" path="/playlists/{playlistID}/items" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -318,7 +324,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetPlaylistContentsBadRequest, GetPlaylistContentsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetPlaylistContentsResponse res = sdk.playlists().getPlaylistContents()
|
||||
@@ -359,6 +365,7 @@ Clears a playlist, only works with dumb playlists. Returns the playlist.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="clearPlaylistContents" method="delete" path="/playlists/{playlistID}/items" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -373,7 +380,7 @@ public class Application {
|
||||
public static void main(String[] args) throws ClearPlaylistContentsBadRequest, ClearPlaylistContentsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
ClearPlaylistContentsResponse res = sdk.playlists().clearPlaylistContents()
|
||||
@@ -411,6 +418,7 @@ With a smart playlist, passing a new `uri` parameter replaces the rules for the
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="addPlaylistContents" method="put" path="/playlists/{playlistID}/items" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -425,13 +433,13 @@ public class Application {
|
||||
public static void main(String[] args) throws AddPlaylistContentsBadRequest, AddPlaylistContentsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
AddPlaylistContentsResponse res = sdk.playlists().addPlaylistContents()
|
||||
.playlistID(7013.44)
|
||||
.uri("server://12345/com.plexapp.plugins.library/library/metadata/1")
|
||||
.playQueueID(123)
|
||||
.playQueueID(123d)
|
||||
.call();
|
||||
|
||||
if (res.object().isPresent()) {
|
||||
@@ -468,6 +476,7 @@ Imports m3u playlists by passing a path on the server to scan for m3u-formatted
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="uploadPlaylist" method="post" path="/playlists/upload" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -483,7 +492,7 @@ public class Application {
|
||||
public static void main(String[] args) throws UploadPlaylistBadRequest, UploadPlaylistUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
UploadPlaylistResponse res = sdk.playlists().uploadPlaylist()
|
||||
|
||||
@@ -22,6 +22,7 @@ Get Companions Data
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getCompanionsData" method="get" path="/companions" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -36,7 +37,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetCompanionsDataBadRequest, GetCompanionsDataUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetCompanionsDataResponse res = sdk.plex().getCompanionsData()
|
||||
@@ -73,6 +74,7 @@ Get friends of provided auth token.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getUserFriends" method="get" path="/friends" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -87,7 +89,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetUserFriendsBadRequest, GetUserFriendsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetUserFriendsResponse res = sdk.plex().getUserFriends()
|
||||
@@ -124,6 +126,7 @@ Returns the geolocation and locale data of the caller
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getGeoData" method="get" path="/geoip" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -174,6 +177,7 @@ Retrieves the home data for the authenticated user, including details like home
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getHomeData" method="get" path="/home" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -188,7 +192,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetHomeDataBadRequest, GetHomeDataUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetHomeDataResponse res = sdk.plex().getHomeData()
|
||||
@@ -219,6 +223,7 @@ Get Plex server access tokens and server connections
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-server-resources" method="get" path="/resources" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -233,7 +238,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetServerResourcesBadRequest, GetServerResourcesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetServerResourcesResponse res = sdk.plex().getServerResources()
|
||||
@@ -278,6 +283,7 @@ Retrieve a Pin ID from Plex.tv to use for authentication flows
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getPin" method="post" path="/pins" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -337,6 +343,7 @@ Retrieve an Access Token from Plex.tv after the Pin has been authenticated
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getTokenByPinId" method="get" path="/pins/{pinID}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
|
||||
@@ -30,6 +30,7 @@ This request is intended to be very fast, and called as the user types.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="performSearch" method="get" path="/hubs/search" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -44,12 +45,12 @@ public class Application {
|
||||
public static void main(String[] args) throws PerformSearchBadRequest, PerformSearchUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
PerformSearchResponse res = sdk.search().performSearch()
|
||||
.query("arnold")
|
||||
.limit(5)
|
||||
.limit(5d)
|
||||
.call();
|
||||
|
||||
// handle response
|
||||
@@ -87,6 +88,7 @@ Results, as well as their containing per-type hubs, contain a `distance` attribu
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="performVoiceSearch" method="get" path="/hubs/search/voice" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -101,12 +103,12 @@ public class Application {
|
||||
public static void main(String[] args) throws PerformVoiceSearchBadRequest, PerformVoiceSearchUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
PerformVoiceSearchResponse res = sdk.search().performVoiceSearch()
|
||||
.query("dead+poop")
|
||||
.limit(5)
|
||||
.limit(5d)
|
||||
.call();
|
||||
|
||||
// handle response
|
||||
@@ -140,6 +142,7 @@ This will search the database for the string provided.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getSearchResults" method="get" path="/search" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -154,7 +157,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetSearchResultsBadRequest, GetSearchResultsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetSearchResultsResponse res = sdk.search().getSearchResults()
|
||||
|
||||
@@ -24,6 +24,7 @@ Get Server Capabilities
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getServerCapabilities" method="get" path="/" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -38,7 +39,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetServerCapabilitiesBadRequest, GetServerCapabilitiesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetServerCapabilitiesResponse res = sdk.server().getServerCapabilities()
|
||||
@@ -69,6 +70,7 @@ Get Server Preferences
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getServerPreferences" method="get" path="/:/prefs" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -83,7 +85,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetServerPreferencesBadRequest, GetServerPreferencesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetServerPreferencesResponse res = sdk.server().getServerPreferences()
|
||||
@@ -114,6 +116,7 @@ Get Available Clients
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getAvailableClients" method="get" path="/clients" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -128,7 +131,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetAvailableClientsBadRequest, GetAvailableClientsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetAvailableClientsResponse res = sdk.server().getAvailableClients()
|
||||
@@ -159,6 +162,7 @@ Get Devices
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getDevices" method="get" path="/devices" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -173,7 +177,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetDevicesBadRequest, GetDevicesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetDevicesResponse res = sdk.server().getDevices()
|
||||
@@ -204,6 +208,7 @@ This request is useful to determine if the server is online or offline
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-server-identity" method="get" path="/identity" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -246,6 +251,7 @@ Returns MyPlex Account Information
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getMyPlexAccount" method="get" path="/myplex/account" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -260,7 +266,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetMyPlexAccountBadRequest, GetMyPlexAccountUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetMyPlexAccountResponse res = sdk.server().getMyPlexAccount()
|
||||
@@ -292,6 +298,7 @@ Plex's Photo transcoder is used throughout the service to serve images at specif
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getResizedPhoto" method="get" path="/photo/:/transcode" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -306,14 +313,14 @@ public class Application {
|
||||
public static void main(String[] args) throws GetResizedPhotoBadRequest, GetResizedPhotoUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetResizedPhotoRequest req = GetResizedPhotoRequest.builder()
|
||||
.width(110)
|
||||
.height(165)
|
||||
.width(110d)
|
||||
.height(165d)
|
||||
.opacity(100L)
|
||||
.blur(0)
|
||||
.blur(0d)
|
||||
.minSize(MinSize.ZERO)
|
||||
.upscale(Upscale.ZERO)
|
||||
.url("/library/metadata/49564/thumb/1654258204")
|
||||
@@ -352,6 +359,7 @@ Retrieves media providers and their features from the Plex server.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-media-providers" method="get" path="/media/providers" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -366,7 +374,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetMediaProvidersBadRequest, GetMediaProvidersUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetMediaProvidersResponse res = sdk.server().getMediaProviders()
|
||||
@@ -404,6 +412,7 @@ Get Server List
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getServerList" method="get" path="/servers" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -418,7 +427,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetServerListBadRequest, GetServerListUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetServerListResponse res = sdk.server().getServerList()
|
||||
|
||||
@@ -19,6 +19,7 @@ This will retrieve the "Now Playing" Information of the PMS.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getSessions" method="get" path="/status/sessions" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -33,7 +34,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetSessionsBadRequest, GetSessionsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetSessionsResponse res = sdk.sessions().getSessions()
|
||||
@@ -64,6 +65,7 @@ This will Retrieve a listing of all history views.
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getSessionHistory" method="get" path="/status/sessions/history/all" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -79,7 +81,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetSessionHistoryBadRequest, GetSessionHistoryUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetSessionHistoryResponse res = sdk.sessions().getSessionHistory()
|
||||
@@ -124,6 +126,7 @@ Get Transcode Sessions
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getTranscodeSessions" method="get" path="/transcode/sessions" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -138,7 +141,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetTranscodeSessionsBadRequest, GetTranscodeSessionsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetTranscodeSessionsResponse res = sdk.sessions().getTranscodeSessions()
|
||||
@@ -169,6 +172,7 @@ Stop a Transcode Session
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="stopTranscodeSession" method="delete" path="/transcode/sessions/{sessionKey}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -183,7 +187,7 @@ public class Application {
|
||||
public static void main(String[] args) throws StopTranscodeSessionBadRequest, StopTranscodeSessionUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
StopTranscodeSessionResponse res = sdk.sessions().stopTranscodeSession()
|
||||
|
||||
@@ -18,6 +18,7 @@ This will return the media statistics for the server
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getStatistics" method="get" path="/statistics/media" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -32,7 +33,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetStatisticsBadRequest, GetStatisticsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetStatisticsResponse res = sdk.statistics().getStatistics()
|
||||
@@ -70,6 +71,7 @@ This will return the resources for the server
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getResourcesStatistics" method="get" path="/statistics/resources" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -84,7 +86,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetResourcesStatisticsBadRequest, GetResourcesStatisticsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetResourcesStatisticsResponse res = sdk.statistics().getResourcesStatistics()
|
||||
@@ -122,6 +124,7 @@ This will return the bandwidth statistics for the server
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getBandwidthStatistics" method="get" path="/statistics/bandwidth" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -136,7 +139,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetBandwidthStatisticsBadRequest, GetBandwidthStatisticsUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetBandwidthStatisticsResponse res = sdk.statistics().getBandwidthStatistics()
|
||||
|
||||
@@ -19,6 +19,7 @@ Querying status of updates
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getUpdateStatus" method="get" path="/updater/status" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -33,7 +34,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetUpdateStatusBadRequest, GetUpdateStatusUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetUpdateStatusResponse res = sdk.updater().getUpdateStatus()
|
||||
@@ -64,6 +65,7 @@ Checking for updates
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="checkForUpdates" method="put" path="/updater/check" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -79,7 +81,7 @@ public class Application {
|
||||
public static void main(String[] args) throws CheckForUpdatesBadRequest, CheckForUpdatesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
CheckForUpdatesResponse res = sdk.updater().checkForUpdates()
|
||||
@@ -116,6 +118,7 @@ Note that these two parameters are effectively mutually exclusive. The `tonight`
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="applyUpdates" method="put" path="/updater/apply" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -130,7 +133,7 @@ public class Application {
|
||||
public static void main(String[] args) throws ApplyUpdatesBadRequest, ApplyUpdatesUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
ApplyUpdatesResponse res = sdk.updater().applyUpdates()
|
||||
|
||||
@@ -13,6 +13,7 @@ Get list of all users that are friends and have library access with the provided
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-users" method="get" path="/users" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@ Get the timeline for a media item
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="getTimeline" method="get" path="/:/timeline" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -31,20 +32,20 @@ public class Application {
|
||||
public static void main(String[] args) throws GetTimelineBadRequest, GetTimelineUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetTimelineRequest req = GetTimelineRequest.builder()
|
||||
.ratingKey(23409)
|
||||
.ratingKey(23409d)
|
||||
.key("/library/metadata/23409")
|
||||
.state(State.PLAYING)
|
||||
.hasMDE(1)
|
||||
.time(2000)
|
||||
.duration(10000)
|
||||
.hasMDE(1d)
|
||||
.time(2000d)
|
||||
.duration(10000d)
|
||||
.context("home:hub.continueWatching")
|
||||
.playQueueItemID(1)
|
||||
.playBackTime(2000)
|
||||
.row(1)
|
||||
.playQueueItemID(1d)
|
||||
.playBackTime(2000d)
|
||||
.row(1d)
|
||||
.build();
|
||||
|
||||
GetTimelineResponse res = sdk.video().getTimeline()
|
||||
@@ -80,6 +81,7 @@ Begin a Universal Transcode Session
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="startUniversalTranscode" method="get" path="/video/:/transcode/universal/start.mpd" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -95,26 +97,26 @@ public class Application {
|
||||
public static void main(String[] args) throws StartUniversalTranscodeBadRequest, StartUniversalTranscodeUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
StartUniversalTranscodeRequest req = StartUniversalTranscodeRequest.builder()
|
||||
.hasMDE(1)
|
||||
.hasMDE(1d)
|
||||
.path("/library/metadata/23409")
|
||||
.mediaIndex(0)
|
||||
.partIndex(0)
|
||||
.mediaIndex(0d)
|
||||
.partIndex(0d)
|
||||
.protocol("hls")
|
||||
.fastSeek(0)
|
||||
.directPlay(0)
|
||||
.directStream(0)
|
||||
.subtitleSize(100)
|
||||
.fastSeek(0d)
|
||||
.directPlay(0d)
|
||||
.directStream(0d)
|
||||
.subtitleSize(100d)
|
||||
.subtites("burn")
|
||||
.audioBoost(100)
|
||||
.audioBoost(100d)
|
||||
.location("lan")
|
||||
.mediaBufferSize(102400)
|
||||
.mediaBufferSize(102400d)
|
||||
.session("zvcage8b7rkioqcm8f4uns4c")
|
||||
.addDebugOverlay(0)
|
||||
.autoAdjustQuality(0)
|
||||
.addDebugOverlay(0d)
|
||||
.autoAdjustQuality(0d)
|
||||
.build();
|
||||
|
||||
StartUniversalTranscodeResponse res = sdk.video().startUniversalTranscode()
|
||||
|
||||
@@ -16,6 +16,7 @@ Get User Watchlist
|
||||
|
||||
### Example Usage
|
||||
|
||||
<!-- UsageSnippet language="java" operationID="get-watch-list" method="get" path="/library/sections/watchlist/{filter}" -->
|
||||
```java
|
||||
package hello.world;
|
||||
|
||||
@@ -30,7 +31,7 @@ public class Application {
|
||||
public static void main(String[] args) throws GetWatchListBadRequest, GetWatchListUnauthorized, Exception {
|
||||
|
||||
PlexAPI sdk = PlexAPI.builder()
|
||||
.accessToken("<YOUR_API_KEY_HERE>")
|
||||
.accessToken(System.getenv().getOrDefault("ACCESS_TOKEN", ""))
|
||||
.build();
|
||||
|
||||
GetWatchListRequest req = GetWatchListRequest.builder()
|
||||
|
||||
Reference in New Issue
Block a user