Video Search
curl --request GET \
--url https://scrapebadger.com/v1/yahoo/videos \
--header 'X-API-Key: <x-api-key>'import requests
url = "https://scrapebadger.com/v1/yahoo/videos"
headers = {"X-API-Key": "<x-api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<x-api-key>'}};
fetch('https://scrapebadger.com/v1/yahoo/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://scrapebadger.com/v1/yahoo/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 => [
"X-API-Key: <x-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"
"net/http"
"io"
)
func main() {
url := "https://scrapebadger.com/v1/yahoo/videos"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<x-api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://scrapebadger.com/v1/yahoo/videos")
.header("X-API-Key", "<x-api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://scrapebadger.com/v1/yahoo/videos")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body{
"query": "<string>",
"market": "<string>",
"result_count": 123,
"results": [
{
"position": 123,
"title": "<string>",
"url": "<string>",
"thumbnail_url": "<string>",
"duration": "<string>",
"source": "<string>",
"source_domain": "<string>",
"description": "<string>",
"views": "<string>"
}
]
}Search
Video Search
Search Yahoo Videos — title, thumbnail, duration, source platform, description and views per result.
GET
/
v1
/
yahoo
/
videos
Video Search
curl --request GET \
--url https://scrapebadger.com/v1/yahoo/videos \
--header 'X-API-Key: <x-api-key>'import requests
url = "https://scrapebadger.com/v1/yahoo/videos"
headers = {"X-API-Key": "<x-api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<x-api-key>'}};
fetch('https://scrapebadger.com/v1/yahoo/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://scrapebadger.com/v1/yahoo/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 => [
"X-API-Key: <x-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"
"net/http"
"io"
)
func main() {
url := "https://scrapebadger.com/v1/yahoo/videos"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<x-api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://scrapebadger.com/v1/yahoo/videos")
.header("X-API-Key", "<x-api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://scrapebadger.com/v1/yahoo/videos")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body{
"query": "<string>",
"market": "<string>",
"result_count": 123,
"results": [
{
"position": 123,
"title": "<string>",
"url": "<string>",
"thumbnail_url": "<string>",
"duration": "<string>",
"source": "<string>",
"source_domain": "<string>",
"description": "<string>",
"views": "<string>"
}
]
}Search Yahoo Videos. Each result carries the destination watch URL, thumbnail,
duration, the host platform (e.g. YouTube), a description, and views as
displayed.
Credits: 5
Authorization
string
required
Your ScrapeBadger API key.
Query Parameters
string
required
Search keywords, e.g.
espresso tutorial.string
default:"us"
Response
string
Echo of the requested query.
string
The market the results were fetched for.
integer
Videos returned.
VideoResult[]
Example
curl "https://scrapebadger.com/v1/yahoo/videos?query=espresso+tutorial&count=10" \
-H "X-API-Key: YOUR_API_KEY"
const res = await fetch(
"https://scrapebadger.com/v1/yahoo/videos?" +
new URLSearchParams({ query: "espresso tutorial", count: "10" }),
{ headers: { "X-API-Key": process.env.SCRAPEBADGER_API_KEY } },
);
const data = await res.json();
import requests
res = requests.get(
"https://scrapebadger.com/v1/yahoo/videos",
headers={"X-API-Key": "YOUR_API_KEY"},
params={"query": "espresso tutorial", "count": 10},
)
data = res.json()
Response
{
"query": "espresso tutorial",
"market": "us",
"result_count": 10,
"results": [
{
"position": 1,
"title": "How to Make Espresso — Beginner's Guide",
"url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
"thumbnail_url": "https://tse2.mm.bing.net/th?id=OVP.abc123",
"duration": "13:47",
"source": "YouTube",
"source_domain": "youtube.com",
"description": "Everything you need to pull a good shot at home, start to finish.",
"views": "1.8M views"
}
]
}
duration and views are returned as Yahoo displays them (13:47,
1.8M views) — they are display strings, not numbers.Page size
Yahoo renders roughly 60 tiles into the first response and has no native
page-size parameter, so
count trims that list rather than paginating.The video vertical only exists on video.search.yahoo.com, so results are
fetched from that fixed US host regardless of the market you pass; the
value is echoed back for consistency.
