mirror of
https://github.com/LukeHagar/plexphp.git
synced 2025-12-06 12:37:47 +00:00
ci: regenerated with OpenAPI Doc 0.0.3, Speakeasy CLI 1.166.1
This commit is contained in:
@@ -1,12 +1,12 @@
|
|||||||
lockVersion: 2.0.0
|
lockVersion: 2.0.0
|
||||||
id: 01a51eb2-5d90-4a24-b154-68e491d02c36
|
id: 01a51eb2-5d90-4a24-b154-68e491d02c36
|
||||||
management:
|
management:
|
||||||
docChecksum: 94439465ae5d544f0e52b00719af05ee
|
docChecksum: 099fc5bbb987ae7e391f7f07b4212860
|
||||||
docVersion: 0.0.3
|
docVersion: 0.0.3
|
||||||
speakeasyVersion: internal
|
speakeasyVersion: internal
|
||||||
generationVersion: 2.239.4
|
generationVersion: 2.249.1
|
||||||
releaseVersion: 0.2.0
|
releaseVersion: 0.3.0
|
||||||
configChecksum: 2152a875267760fe36d5b306ee7366ad
|
configChecksum: 73678e6800bc86c17da7081b9d5a1b97
|
||||||
repoURL: https://github.com/LukeHagar/plexphp.git
|
repoURL: https://github.com/LukeHagar/plexphp.git
|
||||||
repoSubDirectory: .
|
repoSubDirectory: .
|
||||||
installationURL: https://github.com/LukeHagar/plexphp
|
installationURL: https://github.com/LukeHagar/plexphp
|
||||||
@@ -28,7 +28,7 @@ generatedFiles:
|
|||||||
- src/Search.php
|
- src/Search.php
|
||||||
- src/Library.php
|
- src/Library.php
|
||||||
- src/Log.php
|
- src/Log.php
|
||||||
- src/PlexTv.php
|
- src/Plex.php
|
||||||
- src/Playlists.php
|
- src/Playlists.php
|
||||||
- src/Security.php
|
- src/Security.php
|
||||||
- src/Sessions.php
|
- src/Sessions.php
|
||||||
@@ -307,7 +307,7 @@ generatedFiles:
|
|||||||
- src/Models/Operations/EnablePaperTrailResponse.php
|
- src/Models/Operations/EnablePaperTrailResponse.php
|
||||||
- src/Models/Operations/GetPinRequest.php
|
- src/Models/Operations/GetPinRequest.php
|
||||||
- src/Models/Operations/GetPinErrors.php
|
- src/Models/Operations/GetPinErrors.php
|
||||||
- src/Models/Operations/GetPinPlexTvResponseBody.php
|
- src/Models/Operations/GetPinPlexResponseBody.php
|
||||||
- src/Models/Operations/Location.php
|
- src/Models/Operations/Location.php
|
||||||
- src/Models/Operations/GetPinResponseBody.php
|
- src/Models/Operations/GetPinResponseBody.php
|
||||||
- src/Models/Operations/GetPinResponse.php
|
- src/Models/Operations/GetPinResponse.php
|
||||||
@@ -695,7 +695,7 @@ generatedFiles:
|
|||||||
- docs/Models/Operations/EnablePaperTrailResponse.md
|
- docs/Models/Operations/EnablePaperTrailResponse.md
|
||||||
- docs/Models/Operations/GetPinRequest.md
|
- docs/Models/Operations/GetPinRequest.md
|
||||||
- docs/Models/Operations/GetPinErrors.md
|
- docs/Models/Operations/GetPinErrors.md
|
||||||
- docs/Models/Operations/GetPinPlexTvResponseBody.md
|
- docs/Models/Operations/GetPinPlexResponseBody.md
|
||||||
- docs/Models/Operations/Location.md
|
- docs/Models/Operations/Location.md
|
||||||
- docs/Models/Operations/GetPinResponseBody.md
|
- docs/Models/Operations/GetPinResponseBody.md
|
||||||
- docs/Models/Operations/GetPinResponse.md
|
- docs/Models/Operations/GetPinResponse.md
|
||||||
@@ -840,7 +840,7 @@ generatedFiles:
|
|||||||
- docs/sdks/search/README.md
|
- docs/sdks/search/README.md
|
||||||
- docs/sdks/library/README.md
|
- docs/sdks/library/README.md
|
||||||
- docs/sdks/log/README.md
|
- docs/sdks/log/README.md
|
||||||
- docs/sdks/plextv/README.md
|
- docs/sdks/plex/README.md
|
||||||
- docs/sdks/playlists/README.md
|
- docs/sdks/playlists/README.md
|
||||||
- docs/sdks/security/README.md
|
- docs/sdks/security/README.md
|
||||||
- docs/sdks/sessions/README.md
|
- docs/sdks/sessions/README.md
|
||||||
|
|||||||
@@ -133,10 +133,10 @@ try {
|
|||||||
* [logMultiLine](docs/sdks/log/README.md#logmultiline) - Logging a multi-line message
|
* [logMultiLine](docs/sdks/log/README.md#logmultiline) - Logging a multi-line message
|
||||||
* [enablePaperTrail](docs/sdks/log/README.md#enablepapertrail) - Enabling Papertrail
|
* [enablePaperTrail](docs/sdks/log/README.md#enablepapertrail) - Enabling Papertrail
|
||||||
|
|
||||||
### [PlexTv](docs/sdks/plextv/README.md)
|
### [Plex](docs/sdks/plex/README.md)
|
||||||
|
|
||||||
* [getPin](docs/sdks/plextv/README.md#getpin) - Get a Pin
|
* [getPin](docs/sdks/plex/README.md#getpin) - Get a Pin
|
||||||
* [getToken](docs/sdks/plextv/README.md#gettoken) - Get Access Token
|
* [getToken](docs/sdks/plex/README.md#gettoken) - Get Access Token
|
||||||
|
|
||||||
### [Playlists](docs/sdks/playlists/README.md)
|
### [Playlists](docs/sdks/playlists/README.md)
|
||||||
|
|
||||||
@@ -222,7 +222,7 @@ $sdk = Plex_API\PlexAPI::builder()
|
|||||||
->build();
|
->build();
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$response = $sdk->plexTv->getPin('https://plex.tv/api/v2', 'string', false);
|
$response = $sdk->plex->getPin('https://plex.tv/api/v2', 'string', false);
|
||||||
|
|
||||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||||
// handle response
|
// handle response
|
||||||
|
|||||||
10
RELEASES.md
10
RELEASES.md
@@ -78,4 +78,12 @@ Based on:
|
|||||||
- OpenAPI Doc 0.0.3
|
- OpenAPI Doc 0.0.3
|
||||||
- Speakeasy CLI 1.158.0 (2.239.4) https://github.com/speakeasy-api/speakeasy
|
- Speakeasy CLI 1.158.0 (2.239.4) https://github.com/speakeasy-api/speakeasy
|
||||||
### Generated
|
### Generated
|
||||||
- [php v0.2.0] .
|
- [php v0.2.0] .
|
||||||
|
|
||||||
|
## 2024-02-05 14:23:53
|
||||||
|
### Changes
|
||||||
|
Based on:
|
||||||
|
- OpenAPI Doc 0.0.3
|
||||||
|
- Speakeasy CLI 1.166.1 (2.249.1) https://github.com/speakeasy-api/speakeasy
|
||||||
|
### Generated
|
||||||
|
- [php v0.3.0] .
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
# GetPinPlexTvResponseBody
|
# GetPinPlexResponseBody
|
||||||
|
|
||||||
X-Plex-Client-Identifier is missing
|
X-Plex-Client-Identifier is missing
|
||||||
|
|
||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
| Field | Type | Required | Description |
|
||||||
| ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `xPlexClientIdentifier` | *string* | :heavy_check_mark: | Plex Authentication Token |
|
| `xPlexClientIdentifier` | *string* | :heavy_check_mark: | 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/> |
|
||||||
| `strong` | *?bool* | :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/> |
|
| `strong` | *?bool* | :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/> |
|
||||||
@@ -3,10 +3,10 @@
|
|||||||
|
|
||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
| Field | Type | Required | Description |
|
||||||
| ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ |
|
||||||
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type for this operation |
|
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type for this operation |
|
||||||
| `statusCode` | *int* | :heavy_check_mark: | HTTP response status code for this operation |
|
| `statusCode` | *int* | :heavy_check_mark: | HTTP response status code for this operation |
|
||||||
| `rawResponse` | [\Psr\Http\Message\ResponseInterface](https://www.php-fig.org/psr/psr-7/#33-psrhttpmessageresponseinterface) | :heavy_check_mark: | Raw HTTP response; suitable for custom response parsing |
|
| `rawResponse` | [\Psr\Http\Message\ResponseInterface](https://www.php-fig.org/psr/psr-7/#33-psrhttpmessageresponseinterface) | :heavy_check_mark: | Raw HTTP response; suitable for custom response parsing |
|
||||||
| `twoHundredApplicationJsonObject` | [?\LukeHagar\Plex_API\Models\Operations\GetPinResponseBody](../../Models/Operations/GetPinResponseBody.md) | :heavy_minus_sign: | The Pin |
|
| `twoHundredApplicationJsonObject` | [?\LukeHagar\Plex_API\Models\Operations\GetPinResponseBody](../../Models/Operations/GetPinResponseBody.md) | :heavy_minus_sign: | The Pin |
|
||||||
| `fourHundredApplicationJsonObject` | [?\LukeHagar\Plex_API\Models\Operations\GetPinPlexTvResponseBody](../../Models/Operations/GetPinPlexTvResponseBody.md) | :heavy_minus_sign: | X-Plex-Client-Identifier is missing |
|
| `fourHundredApplicationJsonObject` | [?\LukeHagar\Plex_API\Models\Operations\GetPinPlexResponseBody](../../Models/Operations/GetPinPlexResponseBody.md) | :heavy_minus_sign: | X-Plex-Client-Identifier is missing |
|
||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
## Fields
|
## Fields
|
||||||
|
|
||||||
| Field | Type | Required | Description |
|
| Field | Type | Required | Description |
|
||||||
| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- | ----------------------------------------- |
|
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
| `pinID` | *string* | :heavy_check_mark: | The PinID to retrieve an access token for |
|
| `pinID` | *string* | :heavy_check_mark: | The PinID to retrieve an access token for |
|
||||||
| `xPlexClientIdentifier` | *string* | :heavy_check_mark: | Plex Authentication Token |
|
| `xPlexClientIdentifier` | *string* | :heavy_check_mark: | 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/> |
|
||||||
108
docs/sdks/plex/README.md
Normal file
108
docs/sdks/plex/README.md
Normal file
@@ -0,0 +1,108 @@
|
|||||||
|
# Plex
|
||||||
|
|
||||||
|
|
||||||
|
## Overview
|
||||||
|
|
||||||
|
API Calls that perform operations directly against https://Plex.tv
|
||||||
|
|
||||||
|
|
||||||
|
### Available Operations
|
||||||
|
|
||||||
|
* [getPin](#getpin) - Get a Pin
|
||||||
|
* [getToken](#gettoken) - Get Access Token
|
||||||
|
|
||||||
|
## getPin
|
||||||
|
|
||||||
|
Retrieve a Pin from Plex.tv for authentication flows
|
||||||
|
|
||||||
|
### Example Usage
|
||||||
|
|
||||||
|
```php
|
||||||
|
<?php
|
||||||
|
|
||||||
|
declare(strict_types=1);
|
||||||
|
require_once 'vendor/autoload.php';
|
||||||
|
|
||||||
|
use \LukeHagar\Plex_API;
|
||||||
|
use \LukeHagar\Plex_API\Models\Components;
|
||||||
|
use \LukeHagar\Plex_API\Models\Operations;
|
||||||
|
|
||||||
|
$security = new Components\Security();
|
||||||
|
$security->accessToken = '<YOUR_API_KEY_HERE>';
|
||||||
|
|
||||||
|
$sdk = Plex_API\PlexAPI::builder()->setSecurity($security)->build();
|
||||||
|
|
||||||
|
try {
|
||||||
|
|
||||||
|
|
||||||
|
$response = $sdk->plex->getPin('string', false);
|
||||||
|
|
||||||
|
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||||
|
// handle response
|
||||||
|
}
|
||||||
|
} catch (Exception $e) {
|
||||||
|
// handle exception
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
### Parameters
|
||||||
|
|
||||||
|
| Parameter | Type | Required | Description |
|
||||||
|
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
|
| `xPlexClientIdentifier` | *string* | :heavy_check_mark: | 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/> |
|
||||||
|
| `strong` | *bool* | :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/> |
|
||||||
|
| `$serverURL` | *string* | :heavy_minus_sign: | An optional server URL to use. |
|
||||||
|
|
||||||
|
|
||||||
|
### Response
|
||||||
|
|
||||||
|
**[?\LukeHagar\Plex_API\Models\Operations\GetPinResponse](../../Models/Operations/GetPinResponse.md)**
|
||||||
|
|
||||||
|
|
||||||
|
## getToken
|
||||||
|
|
||||||
|
Retrieve an Access Token from Plex.tv after the Pin has already been authenticated
|
||||||
|
|
||||||
|
### Example Usage
|
||||||
|
|
||||||
|
```php
|
||||||
|
<?php
|
||||||
|
|
||||||
|
declare(strict_types=1);
|
||||||
|
require_once 'vendor/autoload.php';
|
||||||
|
|
||||||
|
use \LukeHagar\Plex_API;
|
||||||
|
use \LukeHagar\Plex_API\Models\Components;
|
||||||
|
use \LukeHagar\Plex_API\Models\Operations;
|
||||||
|
|
||||||
|
$security = new Components\Security();
|
||||||
|
$security->accessToken = '<YOUR_API_KEY_HERE>';
|
||||||
|
|
||||||
|
$sdk = Plex_API\PlexAPI::builder()->setSecurity($security)->build();
|
||||||
|
|
||||||
|
try {
|
||||||
|
|
||||||
|
|
||||||
|
$response = $sdk->plex->getToken('string', 'string');
|
||||||
|
|
||||||
|
if ($response->statusCode === 200) {
|
||||||
|
// handle response
|
||||||
|
}
|
||||||
|
} catch (Exception $e) {
|
||||||
|
// handle exception
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
### Parameters
|
||||||
|
|
||||||
|
| Parameter | Type | Required | Description |
|
||||||
|
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
|
| `pinID` | *string* | :heavy_check_mark: | The PinID to retrieve an access token for |
|
||||||
|
| `xPlexClientIdentifier` | *string* | :heavy_check_mark: | 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/> |
|
||||||
|
| `$serverURL` | *string* | :heavy_minus_sign: | An optional server URL to use. |
|
||||||
|
|
||||||
|
|
||||||
|
### Response
|
||||||
|
|
||||||
|
**[?\LukeHagar\Plex_API\Models\Operations\GetTokenResponse](../../Models/Operations/GetTokenResponse.md)**
|
||||||
|
|
||||||
@@ -1,103 +0,0 @@
|
|||||||
# PlexTv
|
|
||||||
|
|
||||||
|
|
||||||
### Available Operations
|
|
||||||
|
|
||||||
* [getPin](#getpin) - Get a Pin
|
|
||||||
* [getToken](#gettoken) - Get Access Token
|
|
||||||
|
|
||||||
## getPin
|
|
||||||
|
|
||||||
Retrieve a Pin from Plex.tv for authentication flows
|
|
||||||
|
|
||||||
### Example Usage
|
|
||||||
|
|
||||||
```php
|
|
||||||
<?php
|
|
||||||
|
|
||||||
declare(strict_types=1);
|
|
||||||
require_once 'vendor/autoload.php';
|
|
||||||
|
|
||||||
use \LukeHagar\Plex_API;
|
|
||||||
use \LukeHagar\Plex_API\Models\Components;
|
|
||||||
use \LukeHagar\Plex_API\Models\Operations;
|
|
||||||
|
|
||||||
$security = new Components\Security();
|
|
||||||
$security->accessToken = '<YOUR_API_KEY_HERE>';
|
|
||||||
|
|
||||||
$sdk = Plex_API\PlexAPI::builder()->setSecurity($security)->build();
|
|
||||||
|
|
||||||
try {
|
|
||||||
|
|
||||||
|
|
||||||
$response = $sdk->plexTv->getPin('string', false);
|
|
||||||
|
|
||||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
|
||||||
// handle response
|
|
||||||
}
|
|
||||||
} catch (Exception $e) {
|
|
||||||
// handle exception
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
### Parameters
|
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
|
||||||
| ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
||||||
| `xPlexClientIdentifier` | *string* | :heavy_check_mark: | Plex Authentication Token |
|
|
||||||
| `strong` | *bool* | :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/> |
|
|
||||||
| `$serverURL` | *string* | :heavy_minus_sign: | An optional server URL to use. |
|
|
||||||
|
|
||||||
|
|
||||||
### Response
|
|
||||||
|
|
||||||
**[?\LukeHagar\Plex_API\Models\Operations\GetPinResponse](../../Models/Operations/GetPinResponse.md)**
|
|
||||||
|
|
||||||
|
|
||||||
## getToken
|
|
||||||
|
|
||||||
Retrieve an Access Token from Plex.tv after the Pin has already been authenticated
|
|
||||||
|
|
||||||
### Example Usage
|
|
||||||
|
|
||||||
```php
|
|
||||||
<?php
|
|
||||||
|
|
||||||
declare(strict_types=1);
|
|
||||||
require_once 'vendor/autoload.php';
|
|
||||||
|
|
||||||
use \LukeHagar\Plex_API;
|
|
||||||
use \LukeHagar\Plex_API\Models\Components;
|
|
||||||
use \LukeHagar\Plex_API\Models\Operations;
|
|
||||||
|
|
||||||
$security = new Components\Security();
|
|
||||||
$security->accessToken = '<YOUR_API_KEY_HERE>';
|
|
||||||
|
|
||||||
$sdk = Plex_API\PlexAPI::builder()->setSecurity($security)->build();
|
|
||||||
|
|
||||||
try {
|
|
||||||
|
|
||||||
|
|
||||||
$response = $sdk->plexTv->getToken('string', 'string');
|
|
||||||
|
|
||||||
if ($response->statusCode === 200) {
|
|
||||||
// handle response
|
|
||||||
}
|
|
||||||
} catch (Exception $e) {
|
|
||||||
// handle exception
|
|
||||||
}
|
|
||||||
```
|
|
||||||
|
|
||||||
### Parameters
|
|
||||||
|
|
||||||
| Parameter | Type | Required | Description |
|
|
||||||
| ----------------------------------------- | ----------------------------------------- | ----------------------------------------- | ----------------------------------------- |
|
|
||||||
| `pinID` | *string* | :heavy_check_mark: | The PinID to retrieve an access token for |
|
|
||||||
| `xPlexClientIdentifier` | *string* | :heavy_check_mark: | Plex Authentication Token |
|
|
||||||
| `$serverURL` | *string* | :heavy_minus_sign: | An optional server URL to use. |
|
|
||||||
|
|
||||||
|
|
||||||
### Response
|
|
||||||
|
|
||||||
**[?\LukeHagar\Plex_API\Models\Operations\GetTokenResponse](../../Models/Operations/GetTokenResponse.md)**
|
|
||||||
|
|
||||||
3
gen.yaml
3
gen.yaml
@@ -7,8 +7,9 @@ generation:
|
|||||||
useClassNamesForArrayFields: true
|
useClassNamesForArrayFields: true
|
||||||
fixes:
|
fixes:
|
||||||
nameResolutionDec2023: false
|
nameResolutionDec2023: false
|
||||||
|
parameterOrderingFeb2024: false
|
||||||
php:
|
php:
|
||||||
version: 0.2.0
|
version: 0.3.0
|
||||||
imports:
|
imports:
|
||||||
option: openapi
|
option: openapi
|
||||||
paths:
|
paths:
|
||||||
|
|||||||
@@ -10,12 +10,12 @@ namespace LukeHagar\Plex_API\Models\Operations;
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* GetPinPlexTvResponseBody - X-Plex-Client-Identifier is missing
|
* GetPinPlexResponseBody - X-Plex-Client-Identifier is missing
|
||||||
*
|
*
|
||||||
* @package LukeHagar\Plex_API\Models\Operations
|
* @package LukeHagar\Plex_API\Models\Operations
|
||||||
* @access public
|
* @access public
|
||||||
*/
|
*/
|
||||||
class GetPinPlexTvResponseBody
|
class GetPinPlexResponseBody
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* $errors
|
* $errors
|
||||||
@@ -12,7 +12,11 @@ use \LukeHagar\Plex_API\Utils\SpeakeasyMetadata;
|
|||||||
class GetPinRequest
|
class GetPinRequest
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* Plex Authentication Token
|
* 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)
|
||||||
|
*
|
||||||
*
|
*
|
||||||
* @var string $xPlexClientIdentifier
|
* @var string $xPlexClientIdentifier
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -46,10 +46,10 @@ class GetPinResponse
|
|||||||
/**
|
/**
|
||||||
* X-Plex-Client-Identifier is missing
|
* X-Plex-Client-Identifier is missing
|
||||||
*
|
*
|
||||||
* @var ?\LukeHagar\Plex_API\Models\Operations\GetPinPlexTvResponseBody $fourHundredApplicationJsonObject
|
* @var ?\LukeHagar\Plex_API\Models\Operations\GetPinPlexResponseBody $fourHundredApplicationJsonObject
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public ?GetPinPlexTvResponseBody $fourHundredApplicationJsonObject = null;
|
public ?GetPinPlexResponseBody $fourHundredApplicationJsonObject = null;
|
||||||
|
|
||||||
public function __construct()
|
public function __construct()
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -20,7 +20,11 @@ class GetTokenRequest
|
|||||||
public string $pinID;
|
public string $pinID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Plex Authentication Token
|
* 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)
|
||||||
|
*
|
||||||
*
|
*
|
||||||
* @var string $xPlexClientIdentifier
|
* @var string $xPlexClientIdentifier
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ declare(strict_types=1);
|
|||||||
|
|
||||||
namespace LukeHagar\Plex_API;
|
namespace LukeHagar\Plex_API;
|
||||||
|
|
||||||
class PlexTv
|
class Plex
|
||||||
{
|
{
|
||||||
|
|
||||||
public const GET_PIN_SERVERS = [
|
public const GET_PIN_SERVERS = [
|
||||||
@@ -49,7 +49,7 @@ class PlexTv
|
|||||||
$request->xPlexClientIdentifier = $xPlexClientIdentifier;
|
$request->xPlexClientIdentifier = $xPlexClientIdentifier;
|
||||||
$request->strong = $strong;
|
$request->strong = $strong;
|
||||||
|
|
||||||
$baseUrl = Utils\Utils::templateUrl(PlexTv::GET_PIN_SERVERS[0], array(
|
$baseUrl = Utils\Utils::templateUrl(Plex::GET_PIN_SERVERS[0], array(
|
||||||
));
|
));
|
||||||
if (!empty($serverURL)) {
|
if (!empty($serverURL)) {
|
||||||
$baseUrl = $serverURL;
|
$baseUrl = $serverURL;
|
||||||
@@ -86,7 +86,7 @@ class PlexTv
|
|||||||
else if ($httpResponse->getStatusCode() === 400) {
|
else if ($httpResponse->getStatusCode() === 400) {
|
||||||
if (Utils\Utils::matchContentType($contentType, 'application/json')) {
|
if (Utils\Utils::matchContentType($contentType, 'application/json')) {
|
||||||
$serializer = Utils\JSON::createSerializer();
|
$serializer = Utils\JSON::createSerializer();
|
||||||
$response->fourHundredApplicationJsonObject = $serializer->deserialize((string)$httpResponse->getBody(), 'LukeHagar\Plex_API\Models\Operations\GetPinPlexTvResponseBody', 'json');
|
$response->fourHundredApplicationJsonObject = $serializer->deserialize((string)$httpResponse->getBody(), 'LukeHagar\Plex_API\Models\Operations\GetPinPlexResponseBody', 'json');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -113,7 +113,7 @@ class PlexTv
|
|||||||
$request->pinID = $pinID;
|
$request->pinID = $pinID;
|
||||||
$request->xPlexClientIdentifier = $xPlexClientIdentifier;
|
$request->xPlexClientIdentifier = $xPlexClientIdentifier;
|
||||||
|
|
||||||
$baseUrl = Utils\Utils::templateUrl(PlexTv::GET_TOKEN_SERVERS[0], array(
|
$baseUrl = Utils\Utils::templateUrl(Plex::GET_TOKEN_SERVERS[0], array(
|
||||||
));
|
));
|
||||||
if (!empty($serverURL)) {
|
if (!empty($serverURL)) {
|
||||||
$baseUrl = $serverURL;
|
$baseUrl = $serverURL;
|
||||||
@@ -101,7 +101,14 @@ class PlexAPI
|
|||||||
*/
|
*/
|
||||||
public Log $log;
|
public Log $log;
|
||||||
|
|
||||||
public PlexTv $plexTv;
|
/**
|
||||||
|
* API Calls that perform operations directly against https://Plex.tv
|
||||||
|
*
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* @var Plex $$plex
|
||||||
|
*/
|
||||||
|
public Plex $plex;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Playlists are ordered collections of media. They can be dumb (just a list of media) or smart (based on a media query, such as "all albums from 2017").
|
* Playlists are ordered collections of media. They can be dumb (just a list of media) or smart (based on a media query, such as "all albums from 2017").
|
||||||
@@ -187,7 +194,7 @@ class PlexAPI
|
|||||||
|
|
||||||
$this->log = new Log($this->sdkConfiguration);
|
$this->log = new Log($this->sdkConfiguration);
|
||||||
|
|
||||||
$this->plexTv = new PlexTv($this->sdkConfiguration);
|
$this->plex = new Plex($this->sdkConfiguration);
|
||||||
|
|
||||||
$this->playlists = new Playlists($this->sdkConfiguration);
|
$this->playlists = new Playlists($this->sdkConfiguration);
|
||||||
|
|
||||||
|
|||||||
@@ -25,9 +25,9 @@ class SDKConfiguration
|
|||||||
];
|
];
|
||||||
public string $language = 'php';
|
public string $language = 'php';
|
||||||
public string $openapiDocVersion = '0.0.3';
|
public string $openapiDocVersion = '0.0.3';
|
||||||
public string $sdkVersion = '0.2.0';
|
public string $sdkVersion = '0.3.0';
|
||||||
public string $genVersion = '2.239.4';
|
public string $genVersion = '2.249.1';
|
||||||
public string $userAgent = 'speakeasy-sdk/php 0.2.0 2.239.4 0.0.3 lukehagar/plex-api';
|
public string $userAgent = 'speakeasy-sdk/php 0.3.0 2.249.1 0.0.3 lukehagar/plex-api';
|
||||||
|
|
||||||
|
|
||||||
public function getServerUrl(): string
|
public function getServerUrl(): string
|
||||||
|
|||||||
Reference in New Issue
Block a user