Skip to main content
POST
/
api
/
tmdb
/
tv
/
discover
/tmdb/tv/discover
curl --request POST \
  --url https://api.anysite.io/api/tmdb/tv/discover \
  --header 'Content-Type: application/json' \
  --header 'access-token: <api-key>' \
  --data '
{
  "count": 2,
  "timeout": 300,
  "user_score_min": 0,
  "user_score_max": 10,
  "min_votes": 0,
  "runtime_min": 0,
  "runtime_max": 400,
  "original_language": "<string>",
  "keywords": [],
  "watch_providers": [],
  "watch_monetization": [],
  "region": "US",
  "sort": "popularity.desc",
  "genres": [],
  "first_air_date_from": "<string>",
  "first_air_date_to": "<string>",
  "networks": []
}
'
import requests

url = "https://api.anysite.io/api/tmdb/tv/discover"

payload = {
"count": 2,
"timeout": 300,
"user_score_min": 0,
"user_score_max": 10,
"min_votes": 0,
"runtime_min": 0,
"runtime_max": 400,
"original_language": "<string>",
"keywords": [],
"watch_providers": [],
"watch_monetization": [],
"region": "US",
"sort": "popularity.desc",
"genres": [],
"first_air_date_from": "<string>",
"first_air_date_to": "<string>",
"networks": []
}
headers = {
"access-token": "<api-key>",
"Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {'access-token': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
count: 2,
timeout: 300,
user_score_min: 0,
user_score_max: 10,
min_votes: 0,
runtime_min: 0,
runtime_max: 400,
original_language: '<string>',
keywords: [],
watch_providers: [],
watch_monetization: [],
region: 'US',
sort: 'popularity.desc',
genres: [],
first_air_date_from: '<string>',
first_air_date_to: '<string>',
networks: []
})
};

fetch('https://api.anysite.io/api/tmdb/tv/discover', 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.anysite.io/api/tmdb/tv/discover",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'count' => 2,
'timeout' => 300,
'user_score_min' => 0,
'user_score_max' => 10,
'min_votes' => 0,
'runtime_min' => 0,
'runtime_max' => 400,
'original_language' => '<string>',
'keywords' => [

],
'watch_providers' => [

],
'watch_monetization' => [

],
'region' => 'US',
'sort' => 'popularity.desc',
'genres' => [

],
'first_air_date_from' => '<string>',
'first_air_date_to' => '<string>',
'networks' => [

]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"access-token: <api-key>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://api.anysite.io/api/tmdb/tv/discover"

payload := strings.NewReader("{\n \"count\": 2,\n \"timeout\": 300,\n \"user_score_min\": 0,\n \"user_score_max\": 10,\n \"min_votes\": 0,\n \"runtime_min\": 0,\n \"runtime_max\": 400,\n \"original_language\": \"<string>\",\n \"keywords\": [],\n \"watch_providers\": [],\n \"watch_monetization\": [],\n \"region\": \"US\",\n \"sort\": \"popularity.desc\",\n \"genres\": [],\n \"first_air_date_from\": \"<string>\",\n \"first_air_date_to\": \"<string>\",\n \"networks\": []\n}")

req, _ := http.NewRequest("POST", url, payload)

req.Header.Add("access-token", "<api-key>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.post("https://api.anysite.io/api/tmdb/tv/discover")
.header("access-token", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"count\": 2,\n \"timeout\": 300,\n \"user_score_min\": 0,\n \"user_score_max\": 10,\n \"min_votes\": 0,\n \"runtime_min\": 0,\n \"runtime_max\": 400,\n \"original_language\": \"<string>\",\n \"keywords\": [],\n \"watch_providers\": [],\n \"watch_monetization\": [],\n \"region\": \"US\",\n \"sort\": \"popularity.desc\",\n \"genres\": [],\n \"first_air_date_from\": \"<string>\",\n \"first_air_date_to\": \"<string>\",\n \"networks\": []\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.anysite.io/api/tmdb/tv/discover")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Post.new(url)
request["access-token"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"count\": 2,\n \"timeout\": 300,\n \"user_score_min\": 0,\n \"user_score_max\": 10,\n \"min_votes\": 0,\n \"runtime_min\": 0,\n \"runtime_max\": 400,\n \"original_language\": \"<string>\",\n \"keywords\": [],\n \"watch_providers\": [],\n \"watch_monetization\": [],\n \"region\": \"US\",\n \"sort\": \"popularity.desc\",\n \"genres\": [],\n \"first_air_date_from\": \"<string>\",\n \"first_air_date_to\": \"<string>\",\n \"networks\": []\n}"

response = http.request(request)
puts response.read_body
[
  {
    "id": 123,
    "media_type": "<string>",
    "url": "<string>",
    "@type": "TmdbMediaItem",
    "document_title": "<string>",
    "date": "<string>",
    "image": "<string>"
  }
]
{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}

Authorizations

access-token
string
header
required

API token from the dashboard

Headers

access-token
string
required

Body

application/json
count
integer
required
Required range: x >= 1
timeout
integer
default:300
Required range: 20 <= x <= 1500
user_score_min
number
default:0
Required range: 0 <= x <= 10
user_score_max
number
default:10
Required range: 0 <= x <= 10
min_votes
integer
default:0
Required range: x >= 0
runtime_min
integer
default:0
Required range: x >= 0
runtime_max
integer
default:400
Required range: x >= 0
original_language
string | null
Pattern: ^[a-z]{2}$
keywords
integer[]
watch_providers
integer[]
watch_monetization
enum<string>[]
Available options:
flatrate,
free,
ads,
rent,
buy
region
enum<string>
default:US
Available options:
AL,
DZ,
AD,
AO,
AG,
AR,
AU,
AT,
AZ,
BS,
BH,
BB,
BY,
BE,
BZ,
BM,
BO,
BA,
BR,
BG,
BF,
CM,
CA,
CV,
TD,
CL,
CO,
CR,
HR,
CU,
CY,
CZ,
CI,
CD,
DK,
DO,
EC,
EG,
SV,
GQ,
EE,
FJ,
FI,
FR,
GF,
PF,
DE,
GH,
GI,
GR,
GP,
GT,
GG,
GY,
HN,
HK,
HU,
IS,
IN,
ID,
IQ,
IE,
IL,
IT,
JM,
JP,
JO,
KE,
XK,
KW,
LV,
LB,
LY,
LI,
LT,
LU,
MK,
MG,
MW,
MY,
ML,
MT,
MU,
MX,
MD,
MC,
ME,
MA,
MZ,
NL,
NZ,
NI,
NE,
NG,
NO,
OM,
PK,
PS,
PA,
PG,
PY,
PE,
PH,
PL,
PT,
QA,
RO,
RU,
SM,
SA,
SN,
RS,
SC,
SG,
SK,
SI,
ZA,
KR,
ES,
LC,
SE,
CH,
TW,
TZ,
TH,
TT,
TN,
TR,
TC,
UG,
UA,
AE,
GB,
US,
UY,
VA,
VE,
YE,
ZM,
ZW
sort
enum<string>
default:popularity.desc
Available options:
popularity.desc,
popularity.asc,
vote_average.desc,
vote_average.asc,
first_air_date.desc,
first_air_date.asc,
name.asc,
name.desc
genres
enum<string>[]
Available options:
Action & Adventure,
Animation,
Comedy,
Crime,
Documentary,
Drama,
Family,
Kids,
Mystery,
News,
Reality,
Sci-Fi & Fantasy,
Soap,
Talk,
War & Politics,
Western
certification
enum<string> | null
Available options:
NR,
TV-Y,
TV-Y7,
TV-G,
TV-PG,
TV-14,
TV-MA
first_air_date_from
string | null
Pattern: ^\d{4}-\d{2}-\d{2}$
first_air_date_to
string | null
Pattern: ^\d{4}-\d{2}-\d{2}$
networks
integer[]

Response

Successful Response

id
integer
required
media_type
string
required
url
string
required
@type
string
default:TmdbMediaItem
document_title
string | null
date
string | null
image
string | null