Get a playlist
curl --request GET \
--url https://app.trackplay.io/api/v1/playlists/{playlist} \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.trackplay.io/api/v1/playlists/{playlist}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.trackplay.io/api/v1/playlists/{playlist}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.trackplay.io/api/v1/playlists/{playlist}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.trackplay.io/api/v1/playlists/{playlist}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.trackplay.io/api/v1/playlists/{playlist}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.trackplay.io/api/v1/playlists/{playlist}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"playlist": {
"video_id": 123,
"video_code": "<string>",
"title": "<string>",
"playback_mode": "linear",
"playlist_code": "<string>",
"item_count": 123,
"auto_advance": true,
"loop": true,
"lesson_navigation": "sidebar"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"message": "No query results for model [App\\\\Models\\\\WorkspaceVideo] 481"
}Playlists
Get a playlist
Reads one playlist by the numeric ID of the video it lives on.
Requires a token with the videos:read scope.
GET
/
playlists
/
{playlist}
Get a playlist
curl --request GET \
--url https://app.trackplay.io/api/v1/playlists/{playlist} \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.trackplay.io/api/v1/playlists/{playlist}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.trackplay.io/api/v1/playlists/{playlist}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.trackplay.io/api/v1/playlists/{playlist}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://app.trackplay.io/api/v1/playlists/{playlist}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.trackplay.io/api/v1/playlists/{playlist}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.trackplay.io/api/v1/playlists/{playlist}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"playlist": {
"video_id": 123,
"video_code": "<string>",
"title": "<string>",
"playback_mode": "linear",
"playlist_code": "<string>",
"item_count": 123,
"auto_advance": true,
"loop": true,
"lesson_navigation": "sidebar"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"error": {
"code": "<string>",
"message": "<string>"
}
}{
"message": "No query results for model [App\\\\Models\\\\WorkspaceVideo] 481"
}Authorizations
A scoped token minted in Settings → API tokens. Send it as Authorization: Bearer tplt_… or X-API-Key: tplt_….
Path Parameters
The numeric ID of the video the playlist lives on. A playlist has no ID of its own: it is settings stored on a video row, so this is that video's id, the same value you would pass to GET /videos/{video}.
Response
The playlist.
Show child attributes
Show child attributes