declare(strict_types=1);
require 'vendor/autoload.php';
use LukeHagar\Plex_API;
$sdk = Plex_API\PlexAPI::builder()
->setSecurity(
'<YOUR_API_KEY_HERE>'
)
->build();
$response = $sdk->updater->getUpdateStatus(
);
if ($response->object !== null) {
// handle response
}{
"MediaContainer": {
"autoUpdateVersion": 123,
"canInstall": true,
"checkedAt": 123,
"downloadURL": "<string>",
"Release": [
{
"added": "<string>",
"downloadURL": "<string>",
"fixed": "<string>",
"key": "<string>",
"state": "available",
"version": "<string>"
}
],
"status": 123
}
}Get the status of updating the server
declare(strict_types=1);
require 'vendor/autoload.php';
use LukeHagar\Plex_API;
$sdk = Plex_API\PlexAPI::builder()
->setSecurity(
'<YOUR_API_KEY_HERE>'
)
->build();
$response = $sdk->updater->getUpdateStatus(
);
if ($response->object !== null) {
// handle response
}{
"MediaContainer": {
"autoUpdateVersion": 123,
"canInstall": true,
"checkedAt": 123,
"downloadURL": "<string>",
"Release": [
{
"added": "<string>",
"downloadURL": "<string>",
"fixed": "<string>",
"key": "<string>",
"state": "available",
"version": "<string>"
}
],
"status": 123
}
}The token which identifies the user accessing the PMS. This can be either:
JWT tokens provide better security with:
OK
Show child attributes
The version of the updater (currently 1)
Indicates whether this install can be updated through these endpoints (typically only on MacOS and Windows)
The last time a check for updates was performed
The URL where the update is available
Show child attributes
A list of what has been added in this version
The URL of where this update is available
A list of what has been fixed in this version
The URL key of the update
The status of this update.
available, downloading, downloaded, installing, tonight, skipped, error, notify, done The version available
The current error code (0 means no error)
Was this page helpful?