Normalized imports, regenerated

This commit is contained in:
Luke Hagar
2024-09-08 03:06:14 +00:00
parent 4d8ee6c199
commit 244adab882
1008 changed files with 21410 additions and 19981 deletions

View File

@@ -31,7 +31,8 @@ Create a new playlist. By default the playlist is blank. To create a playlist al
### Example Usage
```typescript
import { CreatePlaylistQueryParamType, PlexAPI, Smart } from "@lukehagar/plexjs";
import { PlexAPI } from "@lukehagar/plexjs";
import { CreatePlaylistQueryParamType, Smart } from "@lukehagar/plexjs/sdk/models/operations";
const plexAPI = new PlexAPI({
accessToken: "<YOUR_API_KEY_HERE>",
@@ -58,9 +59,9 @@ run();
The standalone function version of this method:
```typescript
import { CreatePlaylistQueryParamType, Smart } from "@lukehagar/plexjs";
import { PlexAPICore } from "@lukehagar/plexjs/core.js";
import { playlistsCreatePlaylist } from "@lukehagar/plexjs/funcs/playlistsCreatePlaylist.js";
import { CreatePlaylistQueryParamType, Smart } from "@lukehagar/plexjs/sdk/models/operations";
// Use `PlexAPICore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
@@ -72,9 +73,9 @@ const plexAPI = new PlexAPICore({
async function run() {
const res = await playlistsCreatePlaylist(plexAPI, {
title: "<value>",
type: CreatePlaylistQueryParamType.Video,
smart: Smart.Zero,
uri: "http://doting-hake.biz",
type: CreatePlaylistQueryParamType.Photo,
smart: Smart.One,
uri: "https://inborn-brochure.biz",
});
if (!res.ok) {
@@ -94,21 +95,21 @@ run();
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `request` | [models.CreatePlaylistRequest](../../models/createplaylistrequest.md) | :heavy_check_mark: | The request object to use for the request. |
| `request` | [operations.CreatePlaylistRequest](../../sdk/models/operations/createplaylistrequest.md) | :heavy_check_mark: | The request object to use for the request. |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<[models.CreatePlaylistResponse](../../models/createplaylistresponse.md)\>**
**Promise\<[operations.CreatePlaylistResponse](../../sdk/models/operations/createplaylistresponse.md)\>**
### Errors
| Error Object | Status Code | Content Type |
| ------------------------------------------ | ------------------------------------------ | ------------------------------------------ |
| models.CreatePlaylistPlaylistsResponseBody | 401 | application/json |
| models.SDKError | 4xx-5xx | */* |
| Error Object | Status Code | Content Type |
| --------------------------------- | --------------------------------- | --------------------------------- |
| errors.CreatePlaylistResponseBody | 401 | application/json |
| errors.SDKError | 4xx-5xx | */* |
## getPlaylists
@@ -170,22 +171,22 @@ run();
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `playlistType` | [models.PlaylistType](../../models/playlisttype.md) | :heavy_minus_sign: | limit to a type of playlist. |
| `smart` | [models.QueryParamSmart](../../models/queryparamsmart.md) | :heavy_minus_sign: | type of playlists to return (default is all). |
| `playlistType` | [operations.PlaylistType](../../sdk/models/operations/playlisttype.md) | :heavy_minus_sign: | limit to a type of playlist. |
| `smart` | [operations.QueryParamSmart](../../sdk/models/operations/queryparamsmart.md) | :heavy_minus_sign: | type of playlists to return (default is all). |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<[models.GetPlaylistsResponse](../../models/getplaylistsresponse.md)\>**
**Promise\<[operations.GetPlaylistsResponse](../../sdk/models/operations/getplaylistsresponse.md)\>**
### Errors
| Error Object | Status Code | Content Type |
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
| models.GetPlaylistsPlaylistsResponseBody | 401 | application/json |
| models.SDKError | 4xx-5xx | */* |
| Error Object | Status Code | Content Type |
| ------------------------------- | ------------------------------- | ------------------------------- |
| errors.GetPlaylistsResponseBody | 401 | application/json |
| errors.SDKError | 4xx-5xx | */* |
## getPlaylist
@@ -230,7 +231,7 @@ const plexAPI = new PlexAPICore({
});
async function run() {
const res = await playlistsGetPlaylist(plexAPI, 7975.52);
const res = await playlistsGetPlaylist(plexAPI, 4109.48);
if (!res.ok) {
throw res.error;
@@ -256,14 +257,14 @@ run();
### Response
**Promise\<[models.GetPlaylistResponse](../../models/getplaylistresponse.md)\>**
**Promise\<[operations.GetPlaylistResponse](../../sdk/models/operations/getplaylistresponse.md)\>**
### Errors
| Error Object | Status Code | Content Type |
| --------------------------------------- | --------------------------------------- | --------------------------------------- |
| models.GetPlaylistPlaylistsResponseBody | 401 | application/json |
| models.SDKError | 4xx-5xx | */* |
| Error Object | Status Code | Content Type |
| ------------------------------ | ------------------------------ | ------------------------------ |
| errors.GetPlaylistResponseBody | 401 | application/json |
| errors.SDKError | 4xx-5xx | */* |
## deletePlaylist
@@ -307,7 +308,7 @@ const plexAPI = new PlexAPICore({
});
async function run() {
const res = await playlistsDeletePlaylist(plexAPI, 8383.28);
const res = await playlistsDeletePlaylist(plexAPI, 216.22);
if (!res.ok) {
throw res.error;
@@ -333,14 +334,14 @@ run();
### Response
**Promise\<[models.DeletePlaylistResponse](../../models/deleteplaylistresponse.md)\>**
**Promise\<[operations.DeletePlaylistResponse](../../sdk/models/operations/deleteplaylistresponse.md)\>**
### Errors
| Error Object | Status Code | Content Type |
| --------------------------------- | --------------------------------- | --------------------------------- |
| models.DeletePlaylistResponseBody | 401 | application/json |
| models.SDKError | 4xx-5xx | */* |
| errors.DeletePlaylistResponseBody | 401 | application/json |
| errors.SDKError | 4xx-5xx | */* |
## updatePlaylist
@@ -384,7 +385,7 @@ const plexAPI = new PlexAPICore({
});
async function run() {
const res = await playlistsUpdatePlaylist(plexAPI, 9776.24);
const res = await playlistsUpdatePlaylist(plexAPI, 3915);
if (!res.ok) {
throw res.error;
@@ -412,14 +413,14 @@ run();
### Response
**Promise\<[models.UpdatePlaylistResponse](../../models/updateplaylistresponse.md)\>**
**Promise\<[operations.UpdatePlaylistResponse](../../sdk/models/operations/updateplaylistresponse.md)\>**
### Errors
| Error Object | Status Code | Content Type |
| --------------------------------- | --------------------------------- | --------------------------------- |
| models.UpdatePlaylistResponseBody | 401 | application/json |
| models.SDKError | 4xx-5xx | */* |
| errors.UpdatePlaylistResponseBody | 401 | application/json |
| errors.SDKError | 4xx-5xx | */* |
## getPlaylistContents
@@ -433,7 +434,8 @@ Note that for dumb playlists, items have a `playlistItemID` attribute which is u
### Example Usage
```typescript
import { GetPlaylistContentsQueryParamType, PlexAPI } from "@lukehagar/plexjs";
import { PlexAPI } from "@lukehagar/plexjs";
import { GetPlaylistContentsQueryParamType } from "@lukehagar/plexjs/sdk/models/operations";
const plexAPI = new PlexAPI({
accessToken: "<YOUR_API_KEY_HERE>",
@@ -455,9 +457,9 @@ run();
The standalone function version of this method:
```typescript
import { GetPlaylistContentsQueryParamType } from "@lukehagar/plexjs";
import { PlexAPICore } from "@lukehagar/plexjs/core.js";
import { playlistsGetPlaylistContents } from "@lukehagar/plexjs/funcs/playlistsGetPlaylistContents.js";
import { GetPlaylistContentsQueryParamType } from "@lukehagar/plexjs/sdk/models/operations";
// Use `PlexAPICore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
@@ -467,7 +469,7 @@ const plexAPI = new PlexAPICore({
});
async function run() {
const res = await playlistsGetPlaylistContents(plexAPI, 2778.32, GetPlaylistContentsQueryParamType.Two);
const res = await playlistsGetPlaylistContents(plexAPI, 5004.46, GetPlaylistContentsQueryParamType.Two);
if (!res.ok) {
throw res.error;
@@ -487,21 +489,21 @@ run();
| Parameter | Type | Required | Description | Example |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `playlistID` | *number* | :heavy_check_mark: | the ID of the playlist | |
| `type` | [models.GetPlaylistContentsQueryParamType](../../models/getplaylistcontentsqueryparamtype.md) | :heavy_check_mark: | The type of media to retrieve.<br/>1 = movie<br/>2 = show<br/>3 = season<br/>4 = episode<br/>E.g. A movie library will not return anything with type 3 as there are no seasons for movie libraries<br/> | [object Object] |
| `type` | [operations.GetPlaylistContentsQueryParamType](../../sdk/models/operations/getplaylistcontentsqueryparamtype.md) | :heavy_check_mark: | The type of media to retrieve.<br/>1 = movie<br/>2 = show<br/>3 = season<br/>4 = episode<br/>E.g. A movie library will not return anything with type 3 as there are no seasons for movie libraries<br/> | [object Object] |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | |
### Response
**Promise\<[models.GetPlaylistContentsResponse](../../models/getplaylistcontentsresponse.md)\>**
**Promise\<[operations.GetPlaylistContentsResponse](../../sdk/models/operations/getplaylistcontentsresponse.md)\>**
### Errors
| Error Object | Status Code | Content Type |
| ----------------------------------------------- | ----------------------------------------------- | ----------------------------------------------- |
| models.GetPlaylistContentsPlaylistsResponseBody | 401 | application/json |
| models.SDKError | 4xx-5xx | */* |
| Error Object | Status Code | Content Type |
| -------------------------------------- | -------------------------------------- | -------------------------------------- |
| errors.GetPlaylistContentsResponseBody | 401 | application/json |
| errors.SDKError | 4xx-5xx | */* |
## clearPlaylistContents
@@ -545,7 +547,7 @@ const plexAPI = new PlexAPICore({
});
async function run() {
const res = await playlistsClearPlaylistContents(plexAPI, 8890.12);
const res = await playlistsClearPlaylistContents(plexAPI, 1893.18);
if (!res.ok) {
throw res.error;
@@ -571,14 +573,14 @@ run();
### Response
**Promise\<[models.ClearPlaylistContentsResponse](../../models/clearplaylistcontentsresponse.md)\>**
**Promise\<[operations.ClearPlaylistContentsResponse](../../sdk/models/operations/clearplaylistcontentsresponse.md)\>**
### Errors
| Error Object | Status Code | Content Type |
| ---------------------------------------- | ---------------------------------------- | ---------------------------------------- |
| models.ClearPlaylistContentsResponseBody | 401 | application/json |
| models.SDKError | 4xx-5xx | */* |
| errors.ClearPlaylistContentsResponseBody | 401 | application/json |
| errors.SDKError | 4xx-5xx | */* |
## addPlaylistContents
@@ -623,7 +625,7 @@ const plexAPI = new PlexAPICore({
});
async function run() {
const res = await playlistsAddPlaylistContents(plexAPI, 4298.05, "server://12345/com.plexapp.plugins.library/library/metadata/1", 123);
const res = await playlistsAddPlaylistContents(plexAPI, 8502.01, "server://12345/com.plexapp.plugins.library/library/metadata/1", 123);
if (!res.ok) {
throw res.error;
@@ -651,14 +653,14 @@ run();
### Response
**Promise\<[models.AddPlaylistContentsResponse](../../models/addplaylistcontentsresponse.md)\>**
**Promise\<[operations.AddPlaylistContentsResponse](../../sdk/models/operations/addplaylistcontentsresponse.md)\>**
### Errors
| Error Object | Status Code | Content Type |
| ----------------------------------------------- | ----------------------------------------------- | ----------------------------------------------- |
| models.AddPlaylistContentsPlaylistsResponseBody | 401 | application/json |
| models.SDKError | 4xx-5xx | */* |
| Error Object | Status Code | Content Type |
| -------------------------------------- | -------------------------------------- | -------------------------------------- |
| errors.AddPlaylistContentsResponseBody | 401 | application/json |
| errors.SDKError | 4xx-5xx | */* |
## uploadPlaylist
@@ -669,7 +671,8 @@ Imports m3u playlists by passing a path on the server to scan for m3u-formatted
### Example Usage
```typescript
import { PlexAPI, QueryParamForce } from "@lukehagar/plexjs";
import { PlexAPI } from "@lukehagar/plexjs";
import { QueryParamForce } from "@lukehagar/plexjs/sdk/models/operations";
const plexAPI = new PlexAPI({
accessToken: "<YOUR_API_KEY_HERE>",
@@ -691,9 +694,9 @@ run();
The standalone function version of this method:
```typescript
import { QueryParamForce } from "@lukehagar/plexjs";
import { PlexAPICore } from "@lukehagar/plexjs/core.js";
import { playlistsUploadPlaylist } from "@lukehagar/plexjs/funcs/playlistsUploadPlaylist.js";
import { QueryParamForce } from "@lukehagar/plexjs/sdk/models/operations";
// Use `PlexAPICore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
@@ -723,18 +726,18 @@ run();
| Parameter | Type | Required | Description | Example |
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `path` | *string* | :heavy_check_mark: | absolute path to a directory on the server where m3u files are stored, or the absolute path to a playlist file on the server. <br/>If the `path` argument is a directory, that path will be scanned for playlist files to be processed. <br/>Each file in that directory creates a separate playlist, with a name based on the filename of the file that created it. <br/>The GUID of each playlist is based on the filename. <br/>If the `path` argument is a file, that file will be used to create a new playlist, with the name based on the filename of the file that created it. <br/>The GUID of each playlist is based on the filename.<br/> | [object Object] |
| `force` | [models.QueryParamForce](../../models/queryparamforce.md) | :heavy_check_mark: | Force overwriting of duplicate playlists. <br/>By default, a playlist file uploaded with the same path will overwrite the existing playlist. <br/>The `force` argument is used to disable overwriting. <br/>If the `force` argument is set to 0, a new playlist will be created suffixed with the date and time that the duplicate was uploaded.<br/> | |
| `force` | [operations.QueryParamForce](../../sdk/models/operations/queryparamforce.md) | :heavy_check_mark: | Force overwriting of duplicate playlists. <br/>By default, a playlist file uploaded with the same path will overwrite the existing playlist. <br/>The `force` argument is used to disable overwriting. <br/>If the `force` argument is set to 0, a new playlist will be created suffixed with the date and time that the duplicate was uploaded.<br/> | |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. | |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. | |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. | |
### Response
**Promise\<[models.UploadPlaylistResponse](../../models/uploadplaylistresponse.md)\>**
**Promise\<[operations.UploadPlaylistResponse](../../sdk/models/operations/uploadplaylistresponse.md)\>**
### Errors
| Error Object | Status Code | Content Type |
| --------------------------------- | --------------------------------- | --------------------------------- |
| models.UploadPlaylistResponseBody | 401 | application/json |
| models.SDKError | 4xx-5xx | */* |
| errors.UploadPlaylistResponseBody | 401 | application/json |
| errors.SDKError | 4xx-5xx | */* |