mirror of
https://github.com/LukeHagar/plexphp.git
synced 2025-12-06 04:20:51 +00:00
ci: regenerated with OpenAPI Doc 0.0.3, Speakeasy CLI 1.193.0
This commit is contained in:
@@ -1,18 +1,18 @@
|
||||
lockVersion: 2.0.0
|
||||
id: 01a51eb2-5d90-4a24-b154-68e491d02c36
|
||||
management:
|
||||
docChecksum: 099fc5bbb987ae7e391f7f07b4212860
|
||||
docChecksum: 278d186496d83d5830ba4870f8cad39d
|
||||
docVersion: 0.0.3
|
||||
speakeasyVersion: internal
|
||||
generationVersion: 2.249.1
|
||||
releaseVersion: 0.3.0
|
||||
configChecksum: 73678e6800bc86c17da7081b9d5a1b97
|
||||
generationVersion: 2.269.0
|
||||
releaseVersion: 0.3.1
|
||||
configChecksum: 114512b0b3bdc6ff6cb307b1ac592df2
|
||||
repoURL: https://github.com/LukeHagar/plexphp.git
|
||||
repoSubDirectory: .
|
||||
installationURL: https://github.com/LukeHagar/plexphp
|
||||
features:
|
||||
php:
|
||||
core: 3.3.0
|
||||
core: 3.3.2
|
||||
flattening: 2.81.1
|
||||
globalSecurity: 2.81.3
|
||||
globalServerURLs: 2.82.1
|
||||
@@ -22,6 +22,7 @@ generatedFiles:
|
||||
- src/SDKConfiguration.php
|
||||
- src/Server.php
|
||||
- src/Media.php
|
||||
- src/Video.php
|
||||
- src/Activities.php
|
||||
- src/Butler.php
|
||||
- src/Hubs.php
|
||||
@@ -31,14 +32,15 @@ generatedFiles:
|
||||
- src/Plex.php
|
||||
- src/Playlists.php
|
||||
- src/Security.php
|
||||
- src/Statistics.php
|
||||
- src/Sessions.php
|
||||
- src/Updater.php
|
||||
- src/Video.php
|
||||
- src/PlexAPI.php
|
||||
- src/ServerProtocol.php
|
||||
- src/PlexAPIBuilder.php
|
||||
- composer.json
|
||||
- phpstan.neon
|
||||
- rector.php
|
||||
- src/Utils/EnumHandler.php
|
||||
- src/Utils/FormMetadata.php
|
||||
- src/Utils/Headers.php
|
||||
@@ -63,6 +65,7 @@ generatedFiles:
|
||||
- src/Models/Operations/GetServerCapabilitiesResponse.php
|
||||
- src/Models/Operations/GetServerPreferencesErrors.php
|
||||
- src/Models/Operations/GetServerPreferencesServerResponseBody.php
|
||||
- src/Models/Operations/Setting.php
|
||||
- src/Models/Operations/GetServerPreferencesMediaContainer.php
|
||||
- src/Models/Operations/GetServerPreferencesResponseBody.php
|
||||
- src/Models/Operations/GetServerPreferencesResponse.php
|
||||
@@ -112,6 +115,15 @@ generatedFiles:
|
||||
- src/Models/Operations/UpdatePlayProgressErrors.php
|
||||
- src/Models/Operations/UpdatePlayProgressResponseBody.php
|
||||
- src/Models/Operations/UpdatePlayProgressResponse.php
|
||||
- src/Models/Operations/State.php
|
||||
- src/Models/Operations/GetTimelineRequest.php
|
||||
- src/Models/Operations/GetTimelineErrors.php
|
||||
- src/Models/Operations/GetTimelineResponseBody.php
|
||||
- src/Models/Operations/GetTimelineResponse.php
|
||||
- src/Models/Operations/StartUniversalTranscodeRequest.php
|
||||
- src/Models/Operations/StartUniversalTranscodeErrors.php
|
||||
- src/Models/Operations/StartUniversalTranscodeResponseBody.php
|
||||
- src/Models/Operations/StartUniversalTranscodeResponse.php
|
||||
- src/Models/Operations/GetServerActivitiesErrors.php
|
||||
- src/Models/Operations/GetServerActivitiesActivitiesResponseBody.php
|
||||
- src/Models/Operations/Context.php
|
||||
@@ -388,6 +400,15 @@ generatedFiles:
|
||||
- src/Models/Operations/GetSourceConnectionInformationErrors.php
|
||||
- src/Models/Operations/GetSourceConnectionInformationResponseBody.php
|
||||
- src/Models/Operations/GetSourceConnectionInformationResponse.php
|
||||
- src/Models/Operations/GetStatisticsRequest.php
|
||||
- src/Models/Operations/GetStatisticsErrors.php
|
||||
- src/Models/Operations/GetStatisticsStatisticsResponseBody.php
|
||||
- src/Models/Operations/GetStatisticsDevice.php
|
||||
- src/Models/Operations/Account.php
|
||||
- src/Models/Operations/StatisticsMedia.php
|
||||
- src/Models/Operations/GetStatisticsMediaContainer.php
|
||||
- src/Models/Operations/GetStatisticsResponseBody.php
|
||||
- src/Models/Operations/GetStatisticsResponse.php
|
||||
- src/Models/Operations/GetSessionsErrors.php
|
||||
- src/Models/Operations/GetSessionsSessionsResponseBody.php
|
||||
- src/Models/Operations/GetSessionsStream.php
|
||||
@@ -433,15 +454,6 @@ generatedFiles:
|
||||
- src/Models/Operations/ApplyUpdatesErrors.php
|
||||
- src/Models/Operations/ApplyUpdatesResponseBody.php
|
||||
- src/Models/Operations/ApplyUpdatesResponse.php
|
||||
- src/Models/Operations/StartUniversalTranscodeRequest.php
|
||||
- src/Models/Operations/StartUniversalTranscodeErrors.php
|
||||
- src/Models/Operations/StartUniversalTranscodeResponseBody.php
|
||||
- src/Models/Operations/StartUniversalTranscodeResponse.php
|
||||
- src/Models/Operations/State.php
|
||||
- src/Models/Operations/GetTimelineRequest.php
|
||||
- src/Models/Operations/GetTimelineErrors.php
|
||||
- src/Models/Operations/GetTimelineResponseBody.php
|
||||
- src/Models/Operations/GetTimelineResponse.php
|
||||
- src/Models/Components/Security.php
|
||||
- docs/Models/Operations/Errors.md
|
||||
- docs/Models/Operations/GetServerCapabilitiesServerResponseBody.md
|
||||
@@ -451,6 +463,7 @@ generatedFiles:
|
||||
- docs/Models/Operations/GetServerCapabilitiesResponse.md
|
||||
- docs/Models/Operations/GetServerPreferencesErrors.md
|
||||
- docs/Models/Operations/GetServerPreferencesServerResponseBody.md
|
||||
- docs/Models/Operations/Setting.md
|
||||
- docs/Models/Operations/GetServerPreferencesMediaContainer.md
|
||||
- docs/Models/Operations/GetServerPreferencesResponseBody.md
|
||||
- docs/Models/Operations/GetServerPreferencesResponse.md
|
||||
@@ -500,6 +513,15 @@ generatedFiles:
|
||||
- docs/Models/Operations/UpdatePlayProgressErrors.md
|
||||
- docs/Models/Operations/UpdatePlayProgressResponseBody.md
|
||||
- docs/Models/Operations/UpdatePlayProgressResponse.md
|
||||
- docs/Models/Operations/State.md
|
||||
- docs/Models/Operations/GetTimelineRequest.md
|
||||
- docs/Models/Operations/GetTimelineErrors.md
|
||||
- docs/Models/Operations/GetTimelineResponseBody.md
|
||||
- docs/Models/Operations/GetTimelineResponse.md
|
||||
- docs/Models/Operations/StartUniversalTranscodeRequest.md
|
||||
- docs/Models/Operations/StartUniversalTranscodeErrors.md
|
||||
- docs/Models/Operations/StartUniversalTranscodeResponseBody.md
|
||||
- docs/Models/Operations/StartUniversalTranscodeResponse.md
|
||||
- docs/Models/Operations/GetServerActivitiesErrors.md
|
||||
- docs/Models/Operations/GetServerActivitiesActivitiesResponseBody.md
|
||||
- docs/Models/Operations/Context.md
|
||||
@@ -776,6 +798,15 @@ generatedFiles:
|
||||
- docs/Models/Operations/GetSourceConnectionInformationErrors.md
|
||||
- docs/Models/Operations/GetSourceConnectionInformationResponseBody.md
|
||||
- docs/Models/Operations/GetSourceConnectionInformationResponse.md
|
||||
- docs/Models/Operations/GetStatisticsRequest.md
|
||||
- docs/Models/Operations/GetStatisticsErrors.md
|
||||
- docs/Models/Operations/GetStatisticsStatisticsResponseBody.md
|
||||
- docs/Models/Operations/GetStatisticsDevice.md
|
||||
- docs/Models/Operations/Account.md
|
||||
- docs/Models/Operations/StatisticsMedia.md
|
||||
- docs/Models/Operations/GetStatisticsMediaContainer.md
|
||||
- docs/Models/Operations/GetStatisticsResponseBody.md
|
||||
- docs/Models/Operations/GetStatisticsResponse.md
|
||||
- docs/Models/Operations/GetSessionsErrors.md
|
||||
- docs/Models/Operations/GetSessionsSessionsResponseBody.md
|
||||
- docs/Models/Operations/GetSessionsStream.md
|
||||
@@ -821,19 +852,11 @@ generatedFiles:
|
||||
- docs/Models/Operations/ApplyUpdatesErrors.md
|
||||
- docs/Models/Operations/ApplyUpdatesResponseBody.md
|
||||
- docs/Models/Operations/ApplyUpdatesResponse.md
|
||||
- docs/Models/Operations/StartUniversalTranscodeRequest.md
|
||||
- docs/Models/Operations/StartUniversalTranscodeErrors.md
|
||||
- docs/Models/Operations/StartUniversalTranscodeResponseBody.md
|
||||
- docs/Models/Operations/StartUniversalTranscodeResponse.md
|
||||
- docs/Models/Operations/State.md
|
||||
- docs/Models/Operations/GetTimelineRequest.md
|
||||
- docs/Models/Operations/GetTimelineErrors.md
|
||||
- docs/Models/Operations/GetTimelineResponseBody.md
|
||||
- docs/Models/Operations/GetTimelineResponse.md
|
||||
- docs/Models/Components/Security.md
|
||||
- docs/sdks/plexapi/README.md
|
||||
- docs/sdks/server/README.md
|
||||
- docs/sdks/media/README.md
|
||||
- docs/sdks/video/README.md
|
||||
- docs/sdks/activities/README.md
|
||||
- docs/sdks/butler/README.md
|
||||
- docs/sdks/hubs/README.md
|
||||
@@ -843,8 +866,8 @@ generatedFiles:
|
||||
- docs/sdks/plex/README.md
|
||||
- docs/sdks/playlists/README.md
|
||||
- docs/sdks/security/README.md
|
||||
- docs/sdks/statistics/README.md
|
||||
- docs/sdks/sessions/README.md
|
||||
- docs/sdks/updater/README.md
|
||||
- docs/sdks/video/README.md
|
||||
- USAGE.md
|
||||
- .gitattributes
|
||||
|
||||
20
README.md
20
README.md
@@ -62,7 +62,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
|
||||
@@ -89,6 +89,11 @@ try {
|
||||
* [markUnplayed](docs/sdks/media/README.md#markunplayed) - Mark Media Unplayed
|
||||
* [updatePlayProgress](docs/sdks/media/README.md#updateplayprogress) - Update Media Play Progress
|
||||
|
||||
### [Video](docs/sdks/video/README.md)
|
||||
|
||||
* [getTimeline](docs/sdks/video/README.md#gettimeline) - Get the timeline for a media item
|
||||
* [startUniversalTranscode](docs/sdks/video/README.md#startuniversaltranscode) - Start Universal Transcode
|
||||
|
||||
### [Activities](docs/sdks/activities/README.md)
|
||||
|
||||
* [getServerActivities](docs/sdks/activities/README.md#getserveractivities) - Get Server Activities
|
||||
@@ -155,6 +160,10 @@ try {
|
||||
* [getTransientToken](docs/sdks/security/README.md#gettransienttoken) - Get a Transient Token.
|
||||
* [getSourceConnectionInformation](docs/sdks/security/README.md#getsourceconnectioninformation) - Get Source Connection Information
|
||||
|
||||
### [Statistics](docs/sdks/statistics/README.md)
|
||||
|
||||
* [getStatistics](docs/sdks/statistics/README.md#getstatistics) - Get Media Statistics
|
||||
|
||||
### [Sessions](docs/sdks/sessions/README.md)
|
||||
|
||||
* [getSessions](docs/sdks/sessions/README.md#getsessions) - Get Active Sessions
|
||||
@@ -167,11 +176,6 @@ try {
|
||||
* [getUpdateStatus](docs/sdks/updater/README.md#getupdatestatus) - Querying status of updates
|
||||
* [checkForUpdates](docs/sdks/updater/README.md#checkforupdates) - Checking for updates
|
||||
* [applyUpdates](docs/sdks/updater/README.md#applyupdates) - Apply Updates
|
||||
|
||||
### [Video](docs/sdks/video/README.md)
|
||||
|
||||
* [startUniversalTranscode](docs/sdks/video/README.md#startuniversaltranscode) - Start Universal Transcode
|
||||
* [getTimeline](docs/sdks/video/README.md#gettimeline) - Get the timeline for a media item
|
||||
<!-- End Available Resources and Operations [operations] -->
|
||||
|
||||
<!-- Start Server Selection [server] -->
|
||||
@@ -222,12 +226,12 @@ $sdk = Plex_API\PlexAPI::builder()
|
||||
->build();
|
||||
|
||||
try {
|
||||
$response = $sdk->plex->getPin('https://plex.tv/api/v2', 'string', false);
|
||||
$response = $sdk->plex->getPin('https://plex.tv/api/v2', '<value>', false);
|
||||
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
|
||||
|
||||
10
RELEASES.md
10
RELEASES.md
@@ -86,4 +86,12 @@ 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] .
|
||||
- [php v0.3.0] .
|
||||
|
||||
## 2024-02-23 14:46:24
|
||||
### Changes
|
||||
Based on:
|
||||
- OpenAPI Doc 0.0.3
|
||||
- Speakeasy CLI 1.193.0 (2.269.0) https://github.com/speakeasy-api/speakeasy
|
||||
### Generated
|
||||
- [php v0.3.1] .
|
||||
2
USAGE.md
2
USAGE.md
@@ -21,7 +21,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
|
||||
|
||||
@@ -8,12 +8,33 @@
|
||||
},
|
||||
"license": "MIT",
|
||||
"require": {
|
||||
"php": ">=8.1.0",
|
||||
"php": "^8.1",
|
||||
"guzzlehttp/guzzle": "^7.0",
|
||||
"jms/serializer": "^3.22"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpstan/phpstan": "^1.9",
|
||||
"phpunit/phpunit": "^10"
|
||||
"phpunit/phpunit": "^10",
|
||||
"rector/rector": "^0.18.13",
|
||||
"roave/security-advisories": "dev-latest"
|
||||
},
|
||||
"minimum-stability": "stable",
|
||||
"prefer-stable": true,
|
||||
"config": {
|
||||
"optimize-autoloader": true,
|
||||
"classmap-authoritative": true,
|
||||
"sort-packages": true
|
||||
},
|
||||
"scripts": {
|
||||
"test": [
|
||||
"./vendor/bin/phpunit --testdox"
|
||||
],
|
||||
"stan": [
|
||||
"./vendor/bin/phpstan analyse --memory-limit=2g"
|
||||
]
|
||||
},
|
||||
"script-descriptions": {
|
||||
"test": "Run PhpUnit test scripts.",
|
||||
"stan": "Run PhpStan static analysis."
|
||||
}
|
||||
}
|
||||
|
||||
15
docs/Models/Operations/Account.md
Normal file
15
docs/Models/Operations/Account.md
Normal file
@@ -0,0 +1,15 @@
|
||||
# Account
|
||||
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- | ---------------------------------------------------------- |
|
||||
| `id` | *?int* | :heavy_minus_sign: | N/A | 238960586 |
|
||||
| `key` | *?string* | :heavy_minus_sign: | N/A | /accounts/238960586 |
|
||||
| `name` | *?string* | :heavy_minus_sign: | N/A | Diane |
|
||||
| `defaultAudioLanguage` | *?string* | :heavy_minus_sign: | N/A | en |
|
||||
| `autoSelectAudio` | *?bool* | :heavy_minus_sign: | N/A | true |
|
||||
| `defaultSubtitleLanguage` | *?string* | :heavy_minus_sign: | N/A | en |
|
||||
| `subtitleMode` | *?int* | :heavy_minus_sign: | N/A | 1 |
|
||||
| `thumb` | *?string* | :heavy_minus_sign: | N/A | https://plex.tv/users/50d83634246da1de/avatar?c=1707110967 |
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||
| `size` | *?int* | :heavy_minus_sign: | N/A | 161 |
|
||||
| `setting` | array<*mixed*> | :heavy_minus_sign: | N/A | [{"advanced":false,"default":"","group":"general","hidden":false,"id":"FriendlyName","label":"Friendly name","summary":"This name will be used to identify this media server to other computers on your network. If you leave it blank, your computer's name will be used instead.","type":"text","value":"Hera"},{"advanced":false,"default":3600,"enumValues":"900:every 15 minutes\|1800:every 30 minutes\|3600:hourly\|7200:every 2 hours\|21600:every 6 hours\|43200:every 12 hours\|86400:daily","group":"library","hidden":false,"id":"ScheduledLibraryUpdateInterval","label":"Library scan interval","summary":"","type":"int","value":3600}] |
|
||||
| Field | Type | Required | Description | Example |
|
||||
| ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `size` | *?int* | :heavy_minus_sign: | N/A | 161 |
|
||||
| `setting` | array<[\LukeHagar\Plex_API\Models\Operations\Setting](../../Models/Operations/Setting.md)> | :heavy_minus_sign: | N/A | [{"advanced":false,"default":false,"enumValues":"1:admin only\|2:everyone","group":"","hidden":true,"id":"EnableDatabaseTrace","label":"","summary":"","type":"bool","value":false}] |
|
||||
12
docs/Models/Operations/GetStatisticsDevice.md
Normal file
12
docs/Models/Operations/GetStatisticsDevice.md
Normal file
@@ -0,0 +1,12 @@
|
||||
# GetStatisticsDevice
|
||||
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| -------------------------------- | -------------------------------- | -------------------------------- | -------------------------------- | -------------------------------- |
|
||||
| `id` | *?int* | :heavy_minus_sign: | N/A | 208 |
|
||||
| `name` | *?string* | :heavy_minus_sign: | N/A | Roku Express |
|
||||
| `platform` | *?string* | :heavy_minus_sign: | N/A | Roku |
|
||||
| `clientIdentifier` | *?string* | :heavy_minus_sign: | N/A | 793095d235660625108ef785cc7646e9 |
|
||||
| `createdAt` | *?int* | :heavy_minus_sign: | N/A | 1706470556 |
|
||||
10
docs/Models/Operations/GetStatisticsErrors.md
Normal file
10
docs/Models/Operations/GetStatisticsErrors.md
Normal file
@@ -0,0 +1,10 @@
|
||||
# GetStatisticsErrors
|
||||
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| ------------------------------- | ------------------------------- | ------------------------------- | ------------------------------- | ------------------------------- |
|
||||
| `code` | *?float* | :heavy_minus_sign: | N/A | 1001 |
|
||||
| `message` | *?string* | :heavy_minus_sign: | N/A | User could not be authenticated |
|
||||
| `status` | *?float* | :heavy_minus_sign: | N/A | 401 |
|
||||
11
docs/Models/Operations/GetStatisticsMediaContainer.md
Normal file
11
docs/Models/Operations/GetStatisticsMediaContainer.md
Normal file
@@ -0,0 +1,11 @@
|
||||
# GetStatisticsMediaContainer
|
||||
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `size` | *?int* | :heavy_minus_sign: | N/A | 5497 |
|
||||
| `device` | array<[\LukeHagar\Plex_API\Models\Operations\GetStatisticsDevice](../../Models/Operations/GetStatisticsDevice.md)> | :heavy_minus_sign: | N/A | [{"clientIdentifier":"793095d235660625108ef785cc7646e9","createdAt":1706470556,"id":208,"name":"Roku Express","platform":"Roku"}] |
|
||||
| `account` | array<[\LukeHagar\Plex_API\Models\Operations\Account](../../Models/Operations/Account.md)> | :heavy_minus_sign: | N/A | [{"autoSelectAudio":true,"defaultAudioLanguage":"en","defaultSubtitleLanguage":"en","id":238960586,"key":"/accounts/238960586","name":"Diane","subtitleMode":1,"thumb":"https://plex.tv/users/50d83634246da1de/avatar?c=1707110967"}] |
|
||||
| `statisticsMedia` | array<[\LukeHagar\Plex_API\Models\Operations\StatisticsMedia](../../Models/Operations/StatisticsMedia.md)> | :heavy_minus_sign: | N/A | [{"accountID":1,"at":1707141600,"count":1,"deviceID":13,"duration":1555,"metadataType":4,"timespan":4}] |
|
||||
8
docs/Models/Operations/GetStatisticsRequest.md
Normal file
8
docs/Models/Operations/GetStatisticsRequest.md
Normal file
@@ -0,0 +1,8 @@
|
||||
# GetStatisticsRequest
|
||||
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description |
|
||||
| ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- |
|
||||
| `timespan` | *?int* | :heavy_minus_sign: | The timespan to retrieve statistics for<br/>the exact meaning of this parameter is not known<br/> |
|
||||
12
docs/Models/Operations/GetStatisticsResponse.md
Normal file
12
docs/Models/Operations/GetStatisticsResponse.md
Normal file
@@ -0,0 +1,12 @@
|
||||
# GetStatisticsResponse
|
||||
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description |
|
||||
| -------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `contentType` | *string* | :heavy_check_mark: | HTTP response content type 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 |
|
||||
| `twoHundredApplicationJsonObject` | [?\LukeHagar\Plex_API\Models\Operations\GetStatisticsResponseBody](../../Models/Operations/GetStatisticsResponseBody.md) | :heavy_minus_sign: | Media Statistics |
|
||||
| `fourHundredAndOneApplicationJsonObject` | [?\LukeHagar\Plex_API\Models\Operations\GetStatisticsStatisticsResponseBody](../../Models/Operations/GetStatisticsStatisticsResponseBody.md) | :heavy_minus_sign: | Unauthorized - Returned if the X-Plex-Token is missing from the header or query. |
|
||||
10
docs/Models/Operations/GetStatisticsResponseBody.md
Normal file
10
docs/Models/Operations/GetStatisticsResponseBody.md
Normal file
@@ -0,0 +1,10 @@
|
||||
# GetStatisticsResponseBody
|
||||
|
||||
Media Statistics
|
||||
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description |
|
||||
| ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `mediaContainer` | [?\LukeHagar\Plex_API\Models\Operations\GetStatisticsMediaContainer](../../Models/Operations/GetStatisticsMediaContainer.md) | :heavy_minus_sign: | N/A |
|
||||
@@ -0,0 +1,10 @@
|
||||
# GetStatisticsStatisticsResponseBody
|
||||
|
||||
Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
|
||||
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description |
|
||||
| ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------ |
|
||||
| `errors` | array<[\LukeHagar\Plex_API\Models\Operations\GetStatisticsErrors](../../Models/Operations/GetStatisticsErrors.md)> | :heavy_minus_sign: | N/A |
|
||||
17
docs/Models/Operations/Setting.md
Normal file
17
docs/Models/Operations/Setting.md
Normal file
@@ -0,0 +1,17 @@
|
||||
# Setting
|
||||
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| ----------------------- | ----------------------- | ----------------------- | ----------------------- | ----------------------- |
|
||||
| `id` | *?string* | :heavy_minus_sign: | N/A | EnableDatabaseTrace |
|
||||
| `label` | *?string* | :heavy_minus_sign: | N/A | |
|
||||
| `summary` | *?string* | :heavy_minus_sign: | N/A | |
|
||||
| `type` | *?string* | :heavy_minus_sign: | N/A | bool |
|
||||
| `default` | *?bool* | :heavy_minus_sign: | N/A | false |
|
||||
| `value` | *?bool* | :heavy_minus_sign: | N/A | false |
|
||||
| `hidden` | *?bool* | :heavy_minus_sign: | N/A | true |
|
||||
| `advanced` | *?bool* | :heavy_minus_sign: | N/A | false |
|
||||
| `group` | *?string* | :heavy_minus_sign: | N/A | |
|
||||
| `enumValues` | *?string* | :heavy_minus_sign: | N/A | 1:admin only\|2:everyone |
|
||||
14
docs/Models/Operations/StatisticsMedia.md
Normal file
14
docs/Models/Operations/StatisticsMedia.md
Normal file
@@ -0,0 +1,14 @@
|
||||
# StatisticsMedia
|
||||
|
||||
|
||||
## Fields
|
||||
|
||||
| Field | Type | Required | Description | Example |
|
||||
| ------------------ | ------------------ | ------------------ | ------------------ | ------------------ |
|
||||
| `accountID` | *?int* | :heavy_minus_sign: | N/A | 1 |
|
||||
| `deviceID` | *?int* | :heavy_minus_sign: | N/A | 13 |
|
||||
| `timespan` | *?int* | :heavy_minus_sign: | N/A | 4 |
|
||||
| `at` | *?int* | :heavy_minus_sign: | N/A | 1707141600 |
|
||||
| `metadataType` | *?int* | :heavy_minus_sign: | N/A | 4 |
|
||||
| `count` | *?int* | :heavy_minus_sign: | N/A | 1 |
|
||||
| `duration` | *?int* | :heavy_minus_sign: | N/A | 1555 |
|
||||
@@ -43,7 +43,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -78,12 +78,12 @@ $sdk = Plex_API\PlexAPI::builder()->setSecurity($security)->build();
|
||||
try {
|
||||
|
||||
|
||||
$response = $sdk->activities->cancelServerActivities('string');
|
||||
$response = $sdk->activities->cancelServerActivities('<value>');
|
||||
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -40,7 +40,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -82,7 +82,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -120,7 +120,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -165,7 +165,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -212,7 +212,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -40,7 +40,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -88,7 +88,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -49,7 +49,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -94,7 +94,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -137,7 +137,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -216,7 +216,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -263,7 +263,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -329,7 +329,7 @@ try {
|
||||
if ($response->object !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -377,7 +377,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -441,7 +441,7 @@ try {
|
||||
if ($response->object !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -489,7 +489,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -536,7 +536,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -580,7 +580,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -42,7 +42,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -112,7 +112,7 @@ level=1&message=Test%20message%203&source=postman';
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -156,7 +156,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -41,7 +41,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -87,7 +87,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -129,12 +129,12 @@ $sdk = Plex_API\PlexAPI::builder()->setSecurity($security)->build();
|
||||
try {
|
||||
|
||||
|
||||
$response = $sdk->media->updatePlayProgress('string', 6900.91, 'string');
|
||||
$response = $sdk->media->updatePlayProgress('<value>', 6900.91, '<value>');
|
||||
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -47,7 +47,7 @@ $sdk = Plex_API\PlexAPI::builder()->setSecurity($security)->build();
|
||||
|
||||
try {
|
||||
$request = new Operations\CreatePlaylistRequest();
|
||||
$request->title = 'string';
|
||||
$request->title = '<value>';
|
||||
$request->type = Operations\QueryParamType::Photo;
|
||||
$request->smart = Operations\Smart::One;
|
||||
$request->uri = 'https://inborn-brochure.biz';
|
||||
@@ -58,7 +58,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -104,7 +104,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -153,7 +153,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -200,7 +200,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -242,12 +242,12 @@ $sdk = Plex_API\PlexAPI::builder()->setSecurity($security)->build();
|
||||
try {
|
||||
|
||||
|
||||
$response = $sdk->playlists->updatePlaylist(3915, 'string', 'string');
|
||||
$response = $sdk->playlists->updatePlaylist(3915, '<value>', '<value>');
|
||||
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -299,7 +299,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -347,7 +347,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -395,7 +395,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -444,7 +444,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -35,12 +35,12 @@ $sdk = Plex_API\PlexAPI::builder()->setSecurity($security)->build();
|
||||
try {
|
||||
|
||||
|
||||
$response = $sdk->plex->getPin('string', false);
|
||||
$response = $sdk->plex->getPin('<value>', false);
|
||||
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -83,12 +83,12 @@ $sdk = Plex_API\PlexAPI::builder()->setSecurity($security)->build();
|
||||
try {
|
||||
|
||||
|
||||
$response = $sdk->plex->getToken('string', 'string');
|
||||
$response = $sdk->plex->getToken('<value>', '<value>');
|
||||
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -53,7 +53,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -105,7 +105,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -153,7 +153,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -41,7 +41,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -90,7 +90,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -43,7 +43,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -80,7 +80,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -117,7 +117,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -154,7 +154,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -191,7 +191,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -228,7 +228,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -276,7 +276,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -319,7 +319,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -39,7 +39,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -76,7 +76,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -113,7 +113,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -153,7 +153,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
57
docs/sdks/statistics/README.md
Normal file
57
docs/sdks/statistics/README.md
Normal file
@@ -0,0 +1,57 @@
|
||||
# Statistics
|
||||
|
||||
|
||||
## Overview
|
||||
|
||||
API Calls that perform operations with Plex Media Server Statistics
|
||||
|
||||
|
||||
### Available Operations
|
||||
|
||||
* [getStatistics](#getstatistics) - Get Media Statistics
|
||||
|
||||
## getStatistics
|
||||
|
||||
This will return the media statistics for the server
|
||||
|
||||
### 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->statistics->getStatistics(411769);
|
||||
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------- |
|
||||
| `timespan` | *int* | :heavy_minus_sign: | The timespan to retrieve statistics for<br/>the exact meaning of this parameter is not known<br/> |
|
||||
|
||||
|
||||
### Response
|
||||
|
||||
**[?\LukeHagar\Plex_API\Models\Operations\GetStatisticsResponse](../../Models/Operations/GetStatisticsResponse.md)**
|
||||
|
||||
@@ -39,7 +39,7 @@ try {
|
||||
if ($response->twoHundredApplicationJsonObject !== null) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -79,7 +79,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -126,7 +126,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
@@ -8,70 +8,8 @@ API Calls that perform operations with Plex Media Server Videos
|
||||
|
||||
### Available Operations
|
||||
|
||||
* [startUniversalTranscode](#startuniversaltranscode) - Start Universal Transcode
|
||||
* [getTimeline](#gettimeline) - Get the timeline for a media item
|
||||
|
||||
## startUniversalTranscode
|
||||
|
||||
Begin a Universal Transcode Session
|
||||
|
||||
### 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 {
|
||||
$request = new Operations\StartUniversalTranscodeRequest();
|
||||
$request->hasMDE = 8924.99;
|
||||
$request->path = '/etc/mail';
|
||||
$request->mediaIndex = 9962.95;
|
||||
$request->partIndex = 1232.82;
|
||||
$request->protocol = 'string';
|
||||
$request->fastSeek = 1630.75;
|
||||
$request->directPlay = 4531.53;
|
||||
$request->directStream = 4877.48;
|
||||
$request->subtitleSize = 3383.01;
|
||||
$request->subtites = 'string';
|
||||
$request->audioBoost = 7970.18;
|
||||
$request->location = 'string';
|
||||
$request->mediaBufferSize = 2664.33;
|
||||
$request->session = 'string';
|
||||
$request->addDebugOverlay = 4930.91;
|
||||
$request->autoAdjustQuality = 2087.17;;
|
||||
|
||||
$response = $sdk->video->startUniversalTranscode($request);
|
||||
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `$request` | [\LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeRequest](../../Models/Operations/StartUniversalTranscodeRequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
||||
|
||||
|
||||
### Response
|
||||
|
||||
**[?\LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeResponse](../../Models/Operations/StartUniversalTranscodeResponse.md)**
|
||||
|
||||
* [startUniversalTranscode](#startuniversaltranscode) - Start Universal Transcode
|
||||
|
||||
## getTimeline
|
||||
|
||||
@@ -102,7 +40,7 @@ try {
|
||||
$request->hasMDE = 7574.33;
|
||||
$request->time = 3327.51;
|
||||
$request->duration = 7585.39;
|
||||
$request->context = 'string';
|
||||
$request->context = '<value>';
|
||||
$request->playQueueItemID = 1406.21;
|
||||
$request->playBackTime = 2699.34;
|
||||
$request->row = 3536.42;;
|
||||
@@ -112,7 +50,7 @@ try {
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Exception $e) {
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
@@ -128,3 +66,65 @@ try {
|
||||
|
||||
**[?\LukeHagar\Plex_API\Models\Operations\GetTimelineResponse](../../Models/Operations/GetTimelineResponse.md)**
|
||||
|
||||
|
||||
## startUniversalTranscode
|
||||
|
||||
Begin a Universal Transcode Session
|
||||
|
||||
### 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 {
|
||||
$request = new Operations\StartUniversalTranscodeRequest();
|
||||
$request->hasMDE = 8924.99;
|
||||
$request->path = '/etc/mail';
|
||||
$request->mediaIndex = 9962.95;
|
||||
$request->partIndex = 1232.82;
|
||||
$request->protocol = '<value>';
|
||||
$request->fastSeek = 1630.75;
|
||||
$request->directPlay = 4531.53;
|
||||
$request->directStream = 4877.48;
|
||||
$request->subtitleSize = 3383.01;
|
||||
$request->subtites = '<value>';
|
||||
$request->audioBoost = 7970.18;
|
||||
$request->location = '<value>';
|
||||
$request->mediaBufferSize = 2664.33;
|
||||
$request->session = '<value>';
|
||||
$request->addDebugOverlay = 4930.91;
|
||||
$request->autoAdjustQuality = 2087.17;;
|
||||
|
||||
$response = $sdk->video->startUniversalTranscode($request);
|
||||
|
||||
if ($response->statusCode === 200) {
|
||||
// handle response
|
||||
}
|
||||
} catch (Throwable $e) {
|
||||
// handle exception
|
||||
}
|
||||
```
|
||||
|
||||
### Parameters
|
||||
|
||||
| Parameter | Type | Required | Description |
|
||||
| --------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| `$request` | [\LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeRequest](../../Models/Operations/StartUniversalTranscodeRequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
||||
|
||||
|
||||
### Response
|
||||
|
||||
**[?\LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeResponse](../../Models/Operations/StartUniversalTranscodeResponse.md)**
|
||||
|
||||
|
||||
3
gen.yaml
3
gen.yaml
@@ -8,8 +8,9 @@ generation:
|
||||
fixes:
|
||||
nameResolutionDec2023: false
|
||||
parameterOrderingFeb2024: false
|
||||
requestResponseComponentNamesFeb2024: false
|
||||
php:
|
||||
version: 0.3.0
|
||||
version: 0.3.1
|
||||
imports:
|
||||
option: openapi
|
||||
paths:
|
||||
|
||||
@@ -1,5 +1,12 @@
|
||||
parameters:
|
||||
|
||||
paths:
|
||||
- src/
|
||||
|
||||
reportUnmatchedIgnoredErrors: false
|
||||
|
||||
checkGenericClassInNonGenericObjectType: false
|
||||
|
||||
ignoreErrors:
|
||||
- '#.*?class ReflectionProperty constructor expects object\|string.*?#'
|
||||
- '#^Strict comparison using === between .*? will always evaluate to false\.$#'
|
||||
29
rector.php
Normal file
29
rector.php
Normal file
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
use Rector\CodeQuality\Rector\Class_\InlineConstructorDefaultToPropertyRector;
|
||||
use Rector\Config\RectorConfig;
|
||||
use Rector\Set\ValueObject\LevelSetList;
|
||||
use Rector\Set\ValueObject\SetList;
|
||||
|
||||
return static function (RectorConfig $rectorConfig): void {
|
||||
$rectorConfig->paths([
|
||||
__DIR__ . '/src',
|
||||
]);
|
||||
|
||||
$rectorConfig->rules([
|
||||
InlineConstructorDefaultToPropertyRector::class,
|
||||
]);
|
||||
|
||||
$rectorConfig->sets([
|
||||
LevelSetList::UP_TO_PHP_82,
|
||||
SetList::CODE_QUALITY,
|
||||
SetList::DEAD_CODE,
|
||||
SetList::EARLY_RETURN,
|
||||
SetList::TYPE_DECLARATION,
|
||||
SetList::PRIVATIZATION,
|
||||
]);
|
||||
};
|
||||
65
src/Models/Operations/Account.php
Normal file
65
src/Models/Operations/Account.php
Normal file
@@ -0,0 +1,65 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API\Models\Operations;
|
||||
|
||||
|
||||
class Account
|
||||
{
|
||||
#[\JMS\Serializer\Annotation\SerializedName('id')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $id = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('key')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $key = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('name')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $name = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('defaultAudioLanguage')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $defaultAudioLanguage = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('autoSelectAudio')]
|
||||
#[\JMS\Serializer\Annotation\Type('bool')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?bool $autoSelectAudio = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('defaultSubtitleLanguage')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $defaultSubtitleLanguage = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('subtitleMode')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $subtitleMode = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('thumb')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $thumb = null;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->id = null;
|
||||
$this->key = null;
|
||||
$this->name = null;
|
||||
$this->defaultAudioLanguage = null;
|
||||
$this->autoSelectAudio = null;
|
||||
$this->defaultSubtitleLanguage = null;
|
||||
$this->subtitleMode = null;
|
||||
$this->thumb = null;
|
||||
}
|
||||
}
|
||||
@@ -19,10 +19,10 @@ class GetServerPreferencesMediaContainer
|
||||
/**
|
||||
* $setting
|
||||
*
|
||||
* @var ?array<mixed> $setting
|
||||
* @var ?array<\LukeHagar\Plex_API\Models\Operations\Setting> $setting
|
||||
*/
|
||||
#[\JMS\Serializer\Annotation\SerializedName('Setting')]
|
||||
#[\JMS\Serializer\Annotation\Type('array<mixed>')]
|
||||
#[\JMS\Serializer\Annotation\Type('array<LukeHagar\Plex_API\Models\Operations\Setting>')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?array $setting = null;
|
||||
|
||||
|
||||
47
src/Models/Operations/GetStatisticsDevice.php
Normal file
47
src/Models/Operations/GetStatisticsDevice.php
Normal file
@@ -0,0 +1,47 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API\Models\Operations;
|
||||
|
||||
|
||||
class GetStatisticsDevice
|
||||
{
|
||||
#[\JMS\Serializer\Annotation\SerializedName('id')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $id = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('name')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $name = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('platform')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $platform = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('clientIdentifier')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $clientIdentifier = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('createdAt')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $createdAt = null;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->id = null;
|
||||
$this->name = null;
|
||||
$this->platform = null;
|
||||
$this->clientIdentifier = null;
|
||||
$this->createdAt = null;
|
||||
}
|
||||
}
|
||||
35
src/Models/Operations/GetStatisticsErrors.php
Normal file
35
src/Models/Operations/GetStatisticsErrors.php
Normal file
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API\Models\Operations;
|
||||
|
||||
|
||||
class GetStatisticsErrors
|
||||
{
|
||||
#[\JMS\Serializer\Annotation\SerializedName('code')]
|
||||
#[\JMS\Serializer\Annotation\Type('float')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?float $code = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('message')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $message = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('status')]
|
||||
#[\JMS\Serializer\Annotation\Type('float')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?float $status = null;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->code = null;
|
||||
$this->message = null;
|
||||
$this->status = null;
|
||||
}
|
||||
}
|
||||
56
src/Models/Operations/GetStatisticsMediaContainer.php
Normal file
56
src/Models/Operations/GetStatisticsMediaContainer.php
Normal file
@@ -0,0 +1,56 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API\Models\Operations;
|
||||
|
||||
|
||||
class GetStatisticsMediaContainer
|
||||
{
|
||||
#[\JMS\Serializer\Annotation\SerializedName('size')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $size = null;
|
||||
|
||||
/**
|
||||
* $device
|
||||
*
|
||||
* @var ?array<\LukeHagar\Plex_API\Models\Operations\GetStatisticsDevice> $device
|
||||
*/
|
||||
#[\JMS\Serializer\Annotation\SerializedName('Device')]
|
||||
#[\JMS\Serializer\Annotation\Type('array<LukeHagar\Plex_API\Models\Operations\GetStatisticsDevice>')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?array $device = null;
|
||||
|
||||
/**
|
||||
* $account
|
||||
*
|
||||
* @var ?array<\LukeHagar\Plex_API\Models\Operations\Account> $account
|
||||
*/
|
||||
#[\JMS\Serializer\Annotation\SerializedName('Account')]
|
||||
#[\JMS\Serializer\Annotation\Type('array<LukeHagar\Plex_API\Models\Operations\Account>')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?array $account = null;
|
||||
|
||||
/**
|
||||
* $statisticsMedia
|
||||
*
|
||||
* @var ?array<\LukeHagar\Plex_API\Models\Operations\StatisticsMedia> $statisticsMedia
|
||||
*/
|
||||
#[\JMS\Serializer\Annotation\SerializedName('StatisticsMedia')]
|
||||
#[\JMS\Serializer\Annotation\Type('array<LukeHagar\Plex_API\Models\Operations\StatisticsMedia>')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?array $statisticsMedia = null;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->size = null;
|
||||
$this->device = null;
|
||||
$this->account = null;
|
||||
$this->statisticsMedia = null;
|
||||
}
|
||||
}
|
||||
29
src/Models/Operations/GetStatisticsRequest.php
Normal file
29
src/Models/Operations/GetStatisticsRequest.php
Normal file
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API\Models\Operations;
|
||||
|
||||
use \LukeHagar\Plex_API\Utils\SpeakeasyMetadata;
|
||||
class GetStatisticsRequest
|
||||
{
|
||||
/**
|
||||
* The timespan to retrieve statistics for
|
||||
*
|
||||
* the exact meaning of this parameter is not known
|
||||
*
|
||||
*
|
||||
* @var ?int $timespan
|
||||
*/
|
||||
#[SpeakeasyMetadata('queryParam:style=form,explode=true,name=Timespan')]
|
||||
public ?int $timespan = null;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->timespan = null;
|
||||
}
|
||||
}
|
||||
62
src/Models/Operations/GetStatisticsResponse.php
Normal file
62
src/Models/Operations/GetStatisticsResponse.php
Normal file
@@ -0,0 +1,62 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API\Models\Operations;
|
||||
|
||||
|
||||
class GetStatisticsResponse
|
||||
{
|
||||
/**
|
||||
* HTTP response content type for this operation
|
||||
*
|
||||
* @var string $contentType
|
||||
*/
|
||||
|
||||
public string $contentType;
|
||||
|
||||
/**
|
||||
* HTTP response status code for this operation
|
||||
*
|
||||
* @var int $statusCode
|
||||
*/
|
||||
|
||||
public int $statusCode;
|
||||
|
||||
/**
|
||||
* Raw HTTP response; suitable for custom response parsing
|
||||
*
|
||||
* @var ?\Psr\Http\Message\ResponseInterface $rawResponse
|
||||
*/
|
||||
|
||||
public ?\Psr\Http\Message\ResponseInterface $rawResponse;
|
||||
|
||||
/**
|
||||
* Media Statistics
|
||||
*
|
||||
* @var ?\LukeHagar\Plex_API\Models\Operations\GetStatisticsResponseBody $twoHundredApplicationJsonObject
|
||||
*/
|
||||
|
||||
public ?GetStatisticsResponseBody $twoHundredApplicationJsonObject = null;
|
||||
|
||||
/**
|
||||
* Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
|
||||
*
|
||||
* @var ?\LukeHagar\Plex_API\Models\Operations\GetStatisticsStatisticsResponseBody $fourHundredAndOneApplicationJsonObject
|
||||
*/
|
||||
|
||||
public ?GetStatisticsStatisticsResponseBody $fourHundredAndOneApplicationJsonObject = null;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->contentType = "";
|
||||
$this->statusCode = 0;
|
||||
$this->rawResponse = null;
|
||||
$this->twoHundredApplicationJsonObject = null;
|
||||
$this->fourHundredAndOneApplicationJsonObject = null;
|
||||
}
|
||||
}
|
||||
29
src/Models/Operations/GetStatisticsResponseBody.php
Normal file
29
src/Models/Operations/GetStatisticsResponseBody.php
Normal file
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API\Models\Operations;
|
||||
|
||||
|
||||
/**
|
||||
* GetStatisticsResponseBody - Media Statistics
|
||||
*
|
||||
* @package LukeHagar\Plex_API\Models\Operations
|
||||
* @access public
|
||||
*/
|
||||
class GetStatisticsResponseBody
|
||||
{
|
||||
#[\JMS\Serializer\Annotation\SerializedName('MediaContainer')]
|
||||
#[\JMS\Serializer\Annotation\Type('LukeHagar\Plex_API\Models\Operations\GetStatisticsMediaContainer')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?GetStatisticsMediaContainer $mediaContainer = null;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->mediaContainer = null;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API\Models\Operations;
|
||||
|
||||
|
||||
/**
|
||||
* GetStatisticsStatisticsResponseBody - Unauthorized - Returned if the X-Plex-Token is missing from the header or query.
|
||||
*
|
||||
* @package LukeHagar\Plex_API\Models\Operations
|
||||
* @access public
|
||||
*/
|
||||
class GetStatisticsStatisticsResponseBody
|
||||
{
|
||||
/**
|
||||
* $errors
|
||||
*
|
||||
* @var ?array<\LukeHagar\Plex_API\Models\Operations\GetStatisticsErrors> $errors
|
||||
*/
|
||||
#[\JMS\Serializer\Annotation\SerializedName('errors')]
|
||||
#[\JMS\Serializer\Annotation\Type('array<LukeHagar\Plex_API\Models\Operations\GetStatisticsErrors>')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?array $errors = null;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->errors = null;
|
||||
}
|
||||
}
|
||||
77
src/Models/Operations/Setting.php
Normal file
77
src/Models/Operations/Setting.php
Normal file
@@ -0,0 +1,77 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API\Models\Operations;
|
||||
|
||||
|
||||
class Setting
|
||||
{
|
||||
#[\JMS\Serializer\Annotation\SerializedName('id')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $id = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('label')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $label = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('summary')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $summary = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('type')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $type = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('default')]
|
||||
#[\JMS\Serializer\Annotation\Type('bool')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?bool $default = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('value')]
|
||||
#[\JMS\Serializer\Annotation\Type('bool')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?bool $value = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('hidden')]
|
||||
#[\JMS\Serializer\Annotation\Type('bool')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?bool $hidden = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('advanced')]
|
||||
#[\JMS\Serializer\Annotation\Type('bool')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?bool $advanced = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('group')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $group = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('enumValues')]
|
||||
#[\JMS\Serializer\Annotation\Type('string')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?string $enumValues = null;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->id = null;
|
||||
$this->label = null;
|
||||
$this->summary = null;
|
||||
$this->type = null;
|
||||
$this->default = null;
|
||||
$this->value = null;
|
||||
$this->hidden = null;
|
||||
$this->advanced = null;
|
||||
$this->group = null;
|
||||
$this->enumValues = null;
|
||||
}
|
||||
}
|
||||
59
src/Models/Operations/StatisticsMedia.php
Normal file
59
src/Models/Operations/StatisticsMedia.php
Normal file
@@ -0,0 +1,59 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API\Models\Operations;
|
||||
|
||||
|
||||
class StatisticsMedia
|
||||
{
|
||||
#[\JMS\Serializer\Annotation\SerializedName('accountID')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $accountID = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('deviceID')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $deviceID = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('timespan')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $timespan = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('at')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $at = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('metadataType')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $metadataType = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('count')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $count = null;
|
||||
|
||||
#[\JMS\Serializer\Annotation\SerializedName('duration')]
|
||||
#[\JMS\Serializer\Annotation\Type('int')]
|
||||
#[\JMS\Serializer\Annotation\SkipWhenEmpty]
|
||||
public ?int $duration = null;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->accountID = null;
|
||||
$this->deviceID = null;
|
||||
$this->timespan = null;
|
||||
$this->at = null;
|
||||
$this->metadataType = null;
|
||||
$this->count = null;
|
||||
$this->duration = null;
|
||||
}
|
||||
}
|
||||
@@ -41,6 +41,15 @@ class PlexAPI
|
||||
*/
|
||||
public Media $media;
|
||||
|
||||
/**
|
||||
* API Calls that perform operations with Plex Media Server Videos
|
||||
*
|
||||
*
|
||||
*
|
||||
* @var Video $$video
|
||||
*/
|
||||
public Video $video;
|
||||
|
||||
/**
|
||||
* Activities are awesome. They provide a way to monitor and control asynchronous operations on the server. In order to receive real-time updates for activities, a client would normally subscribe via either EventSource or Websocket endpoints.
|
||||
*
|
||||
@@ -131,6 +140,15 @@ class PlexAPI
|
||||
*/
|
||||
public Security $security;
|
||||
|
||||
/**
|
||||
* API Calls that perform operations with Plex Media Server Statistics
|
||||
*
|
||||
*
|
||||
*
|
||||
* @var Statistics $$statistics
|
||||
*/
|
||||
public Statistics $statistics;
|
||||
|
||||
/**
|
||||
* API Calls that perform search operations with Plex Media Server Sessions
|
||||
*
|
||||
@@ -149,15 +167,6 @@ class PlexAPI
|
||||
* @var Updater $$updater
|
||||
*/
|
||||
public Updater $updater;
|
||||
|
||||
/**
|
||||
* API Calls that perform operations with Plex Media Server Videos
|
||||
*
|
||||
*
|
||||
*
|
||||
* @var Video $$video
|
||||
*/
|
||||
public Video $video;
|
||||
|
||||
private SDKConfiguration $sdkConfiguration;
|
||||
|
||||
@@ -182,6 +191,8 @@ class PlexAPI
|
||||
|
||||
$this->media = new Media($this->sdkConfiguration);
|
||||
|
||||
$this->video = new Video($this->sdkConfiguration);
|
||||
|
||||
$this->activities = new Activities($this->sdkConfiguration);
|
||||
|
||||
$this->butler = new Butler($this->sdkConfiguration);
|
||||
@@ -200,10 +211,10 @@ class PlexAPI
|
||||
|
||||
$this->security = new Security($this->sdkConfiguration);
|
||||
|
||||
$this->statistics = new Statistics($this->sdkConfiguration);
|
||||
|
||||
$this->sessions = new Sessions($this->sdkConfiguration);
|
||||
|
||||
$this->updater = new Updater($this->sdkConfiguration);
|
||||
|
||||
$this->video = new Video($this->sdkConfiguration);
|
||||
}
|
||||
}
|
||||
@@ -25,9 +25,9 @@ class SDKConfiguration
|
||||
];
|
||||
public string $language = 'php';
|
||||
public string $openapiDocVersion = '0.0.3';
|
||||
public string $sdkVersion = '0.3.0';
|
||||
public string $genVersion = '2.249.1';
|
||||
public string $userAgent = 'speakeasy-sdk/php 0.3.0 2.249.1 0.0.3 lukehagar/plex-api';
|
||||
public string $sdkVersion = '0.3.1';
|
||||
public string $genVersion = '2.269.0';
|
||||
public string $userAgent = 'speakeasy-sdk/php 0.3.1 2.269.0 0.0.3 lukehagar/plex-api';
|
||||
|
||||
|
||||
public function getServerUrl(): string
|
||||
|
||||
75
src/Statistics.php
Normal file
75
src/Statistics.php
Normal file
@@ -0,0 +1,75 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Code generated by Speakeasy (https://speakeasyapi.dev). DO NOT EDIT.
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace LukeHagar\Plex_API;
|
||||
|
||||
class Statistics
|
||||
{
|
||||
|
||||
private SDKConfiguration $sdkConfiguration;
|
||||
|
||||
/**
|
||||
* @param SDKConfiguration $sdkConfig
|
||||
*/
|
||||
public function __construct(SDKConfiguration $sdkConfig)
|
||||
{
|
||||
$this->sdkConfiguration = $sdkConfig;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get Media Statistics
|
||||
*
|
||||
* This will return the media statistics for the server
|
||||
*
|
||||
* @param ?int $timespan
|
||||
* @return \LukeHagar\Plex_API\Models\Operations\GetStatisticsResponse
|
||||
*/
|
||||
public function getStatistics(
|
||||
?int $timespan = null,
|
||||
): \LukeHagar\Plex_API\Models\Operations\GetStatisticsResponse
|
||||
{
|
||||
$request = new \LukeHagar\Plex_API\Models\Operations\GetStatisticsRequest();
|
||||
$request->timespan = $timespan;
|
||||
|
||||
$baseUrl = Utils\Utils::templateUrl($this->sdkConfiguration->getServerUrl(), $this->sdkConfiguration->getServerDefaults());
|
||||
$url = Utils\Utils::generateUrl($baseUrl, '/statistics/media');
|
||||
|
||||
$options = ['http_errors' => false];
|
||||
$options = array_merge_recursive($options, Utils\Utils::getQueryParams(\LukeHagar\Plex_API\Models\Operations\GetStatisticsRequest::class, $request, null));
|
||||
$options['headers']['Accept'] = 'application/json';
|
||||
$options['headers']['user-agent'] = $this->sdkConfiguration->userAgent;
|
||||
|
||||
$httpResponse = $this->sdkConfiguration->securityClient->request('GET', $url, $options);
|
||||
|
||||
$contentType = $httpResponse->getHeader('Content-Type')[0] ?? '';
|
||||
|
||||
$statusCode = $httpResponse->getStatusCode();
|
||||
|
||||
$response = new \LukeHagar\Plex_API\Models\Operations\GetStatisticsResponse();
|
||||
$response->statusCode = $statusCode;
|
||||
$response->contentType = $contentType;
|
||||
$response->rawResponse = $httpResponse;
|
||||
|
||||
if ($httpResponse->getStatusCode() === 200) {
|
||||
if (Utils\Utils::matchContentType($contentType, 'application/json')) {
|
||||
$serializer = Utils\JSON::createSerializer();
|
||||
$response->twoHundredApplicationJsonObject = $serializer->deserialize((string)$httpResponse->getBody(), 'LukeHagar\Plex_API\Models\Operations\GetStatisticsResponseBody', 'json');
|
||||
}
|
||||
}
|
||||
else if ($httpResponse->getStatusCode() === 400) {
|
||||
}
|
||||
else if ($httpResponse->getStatusCode() === 401) {
|
||||
if (Utils\Utils::matchContentType($contentType, 'application/json')) {
|
||||
$serializer = Utils\JSON::createSerializer();
|
||||
$response->fourHundredAndOneApplicationJsonObject = $serializer->deserialize((string)$httpResponse->getBody(), 'LukeHagar\Plex_API\Models\Operations\GetStatisticsStatisticsResponseBody', 'json');
|
||||
}
|
||||
}
|
||||
|
||||
return $response;
|
||||
}
|
||||
}
|
||||
@@ -21,49 +21,6 @@ class Video
|
||||
$this->sdkConfiguration = $sdkConfig;
|
||||
}
|
||||
|
||||
/**
|
||||
* Start Universal Transcode
|
||||
*
|
||||
* Begin a Universal Transcode Session
|
||||
*
|
||||
* @param \LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeRequest $request
|
||||
* @return \LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeResponse
|
||||
*/
|
||||
public function startUniversalTranscode(
|
||||
?\LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeRequest $request,
|
||||
): \LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeResponse
|
||||
{
|
||||
$baseUrl = Utils\Utils::templateUrl($this->sdkConfiguration->getServerUrl(), $this->sdkConfiguration->getServerDefaults());
|
||||
$url = Utils\Utils::generateUrl($baseUrl, '/video/:/transcode/universal/start.mpd');
|
||||
|
||||
$options = ['http_errors' => false];
|
||||
$options = array_merge_recursive($options, Utils\Utils::getQueryParams(\LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeRequest::class, $request, null));
|
||||
$options['headers']['Accept'] = 'application/json';
|
||||
$options['headers']['user-agent'] = $this->sdkConfiguration->userAgent;
|
||||
|
||||
$httpResponse = $this->sdkConfiguration->securityClient->request('GET', $url, $options);
|
||||
|
||||
$contentType = $httpResponse->getHeader('Content-Type')[0] ?? '';
|
||||
|
||||
$statusCode = $httpResponse->getStatusCode();
|
||||
|
||||
$response = new \LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeResponse();
|
||||
$response->statusCode = $statusCode;
|
||||
$response->contentType = $contentType;
|
||||
$response->rawResponse = $httpResponse;
|
||||
|
||||
if ($httpResponse->getStatusCode() === 200 or $httpResponse->getStatusCode() === 400) {
|
||||
}
|
||||
else if ($httpResponse->getStatusCode() === 401) {
|
||||
if (Utils\Utils::matchContentType($contentType, 'application/json')) {
|
||||
$serializer = Utils\JSON::createSerializer();
|
||||
$response->object = $serializer->deserialize((string)$httpResponse->getBody(), 'LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeResponseBody', 'json');
|
||||
}
|
||||
}
|
||||
|
||||
return $response;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the timeline for a media item
|
||||
*
|
||||
@@ -106,4 +63,47 @@ class Video
|
||||
|
||||
return $response;
|
||||
}
|
||||
|
||||
/**
|
||||
* Start Universal Transcode
|
||||
*
|
||||
* Begin a Universal Transcode Session
|
||||
*
|
||||
* @param \LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeRequest $request
|
||||
* @return \LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeResponse
|
||||
*/
|
||||
public function startUniversalTranscode(
|
||||
?\LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeRequest $request,
|
||||
): \LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeResponse
|
||||
{
|
||||
$baseUrl = Utils\Utils::templateUrl($this->sdkConfiguration->getServerUrl(), $this->sdkConfiguration->getServerDefaults());
|
||||
$url = Utils\Utils::generateUrl($baseUrl, '/video/:/transcode/universal/start.mpd');
|
||||
|
||||
$options = ['http_errors' => false];
|
||||
$options = array_merge_recursive($options, Utils\Utils::getQueryParams(\LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeRequest::class, $request, null));
|
||||
$options['headers']['Accept'] = 'application/json';
|
||||
$options['headers']['user-agent'] = $this->sdkConfiguration->userAgent;
|
||||
|
||||
$httpResponse = $this->sdkConfiguration->securityClient->request('GET', $url, $options);
|
||||
|
||||
$contentType = $httpResponse->getHeader('Content-Type')[0] ?? '';
|
||||
|
||||
$statusCode = $httpResponse->getStatusCode();
|
||||
|
||||
$response = new \LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeResponse();
|
||||
$response->statusCode = $statusCode;
|
||||
$response->contentType = $contentType;
|
||||
$response->rawResponse = $httpResponse;
|
||||
|
||||
if ($httpResponse->getStatusCode() === 200 or $httpResponse->getStatusCode() === 400) {
|
||||
}
|
||||
else if ($httpResponse->getStatusCode() === 401) {
|
||||
if (Utils\Utils::matchContentType($contentType, 'application/json')) {
|
||||
$serializer = Utils\JSON::createSerializer();
|
||||
$response->object = $serializer->deserialize((string)$httpResponse->getBody(), 'LukeHagar\Plex_API\Models\Operations\StartUniversalTranscodeResponseBody', 'json');
|
||||
}
|
||||
}
|
||||
|
||||
return $response;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user