Authorizations
Headers
Available options:
application/json, application/xml Example:
Example:
Example:
Example:
Example:
Example:
Example:
Example:
Example:
Example:
declare(strict_types=1);
require 'vendor/autoload.php';
use LukeHagar\Plex_API;
use LukeHagar\Plex_API\Models\Operations;
$sdk = Plex_API\PlexAPI::builder()
->setSecurity(
'<YOUR_API_KEY_HERE>'
)
->build();
$response = $sdk->playlists->uploadPlaylist(
path: '/home/barkley/playlist.m3u',
force: Operations\QueryParamForce::One,
sectionID: 1
);
if ($response->statusCode === 200) {
// handle response
}This response does not have an example.Imports m3u playlists by passing a path on the server to scan for m3u-formatted playlist files, or a path to a single playlist file.
declare(strict_types=1);
require 'vendor/autoload.php';
use LukeHagar\Plex_API;
use LukeHagar\Plex_API\Models\Operations;
$sdk = Plex_API\PlexAPI::builder()
->setSecurity(
'<YOUR_API_KEY_HERE>'
)
->build();
$response = $sdk->playlists->uploadPlaylist(
path: '/home/barkley/playlist.m3u',
force: Operations\QueryParamForce::One,
sectionID: 1
);
if ($response->statusCode === 200) {
// handle response
}This response does not have an example.application/json, application/xml Was this page helpful?