Videos
curl --request GET \
--url https://api.themoviedb.org/3/tv/{series_id}/videos \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.themoviedb.org/3/tv/{series_id}/videos"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.themoviedb.org/3/tv/{series_id}/videos', 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://api.themoviedb.org/3/tv/{series_id}/videos",
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://api.themoviedb.org/3/tv/{series_id}/videos"
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://api.themoviedb.org/3/tv/{series_id}/videos")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.themoviedb.org/3/tv/{series_id}/videos")
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{
"id": 1399,
"results": [
{
"iso_639_1": "en",
"iso_3166_1": "US",
"name": "Inside Game of Thrones: A Story in Camera Work – BTS (HBO)",
"key": "y2ZJ3lTaREY",
"site": "YouTube",
"size": 1080,
"type": "Behind the Scenes",
"official": true,
"published_at": "2019-03-25T14:00:06.000Z",
"id": "5c999b48c3a36863b73b9d42"
},
{
"iso_639_1": "en",
"iso_3166_1": "US",
"name": "Inside Game of Thrones: A Story in Prosthetics – BTS (HBO)",
"key": "f3MUpuRF6Ck",
"site": "YouTube",
"size": 1080,
"type": "Behind the Scenes",
"official": true,
"published_at": "2019-03-11T14:00:03.000Z",
"id": "5c92c2519251412b51773135"
},
{
"iso_639_1": "en",
"iso_3166_1": "US",
"name": "GAME OF THRONES - SEASON 1- TRAILER",
"key": "bjqEWgDVPe0",
"published_at": "2017-02-20T15:25:56.000Z",
"site": "YouTube",
"size": 1080,
"type": "Trailer",
"official": true,
"id": "5b5b91c2925141523700502c"
},
{
"iso_639_1": "en",
"iso_3166_1": "US",
"name": "Official Opening Credits: Game of Thrones (HBO)",
"key": "s7L2PVdrb_8",
"site": "YouTube",
"size": 1080,
"type": "Opening Credits",
"official": true,
"published_at": "2011-04-18T20:20:02.000Z",
"id": "6233756fba131b001f875249"
},
{
"iso_639_1": "en",
"iso_3166_1": "US",
"name": "Game of Thrones | Season 1 | Official Trailer",
"key": "BpJYNVhGf1s",
"site": "YouTube",
"size": 1080,
"type": "Trailer",
"official": true,
"published_at": "2011-03-04T04:21:14.000Z",
"id": "5c9295200e0a267cd8168bd8"
}
]
}TV SERIES
Videos
This endpoint is used to get the videos that belong to a TV show.
GET
/
tv
/
{series_id}
/
videos
Videos
curl --request GET \
--url https://api.themoviedb.org/3/tv/{series_id}/videos \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.themoviedb.org/3/tv/{series_id}/videos"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.themoviedb.org/3/tv/{series_id}/videos', 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://api.themoviedb.org/3/tv/{series_id}/videos",
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://api.themoviedb.org/3/tv/{series_id}/videos"
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://api.themoviedb.org/3/tv/{series_id}/videos")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.themoviedb.org/3/tv/{series_id}/videos")
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{
"id": 1399,
"results": [
{
"iso_639_1": "en",
"iso_3166_1": "US",
"name": "Inside Game of Thrones: A Story in Camera Work – BTS (HBO)",
"key": "y2ZJ3lTaREY",
"site": "YouTube",
"size": 1080,
"type": "Behind the Scenes",
"official": true,
"published_at": "2019-03-25T14:00:06.000Z",
"id": "5c999b48c3a36863b73b9d42"
},
{
"iso_639_1": "en",
"iso_3166_1": "US",
"name": "Inside Game of Thrones: A Story in Prosthetics – BTS (HBO)",
"key": "f3MUpuRF6Ck",
"site": "YouTube",
"size": 1080,
"type": "Behind the Scenes",
"official": true,
"published_at": "2019-03-11T14:00:03.000Z",
"id": "5c92c2519251412b51773135"
},
{
"iso_639_1": "en",
"iso_3166_1": "US",
"name": "GAME OF THRONES - SEASON 1- TRAILER",
"key": "bjqEWgDVPe0",
"published_at": "2017-02-20T15:25:56.000Z",
"site": "YouTube",
"size": 1080,
"type": "Trailer",
"official": true,
"id": "5b5b91c2925141523700502c"
},
{
"iso_639_1": "en",
"iso_3166_1": "US",
"name": "Official Opening Credits: Game of Thrones (HBO)",
"key": "s7L2PVdrb_8",
"site": "YouTube",
"size": 1080,
"type": "Opening Credits",
"official": true,
"published_at": "2011-04-18T20:20:02.000Z",
"id": "6233756fba131b001f875249"
},
{
"iso_639_1": "en",
"iso_3166_1": "US",
"name": "Game of Thrones | Season 1 | Official Trailer",
"key": "BpJYNVhGf1s",
"site": "YouTube",
"size": 1080,
"type": "Trailer",
"official": true,
"published_at": "2011-03-04T04:21:14.000Z",
"id": "5c9295200e0a267cd8168bd8"
}
]
}