SerpBase

API reference · Search engines

Google Videos Search

Search Google video results by query. This discovers video listings, not a video download or watermark-removal service.

POSThttps://api.serpbase.dev/google/videos/search
1 creditOpen in Playground

Example

BASH
curl -X POST 'https://api.serpbase.dev/google/videos/search' \
  -H "Content-Type: application/json" \
  -H 'X-API-Key: YOUR_API_KEY' \
  --max-time 60 \
  -d '{"query":"how espresso machines work"}'
Response · real, shortened
{
  "status": 0,
  "credits_charged": 1,
  "request_id": "r-4b27fe8a36d9ac303a5da7dd",
  "product_id": "google_videos_search",
  "query": "how espresso machines work",
  "page": 1,
  "search_type": "videos",
  "videos": [
    {
      "display_link": "www.youtube.com",
      "display_url": "www.youtube.com",
      "duration": "4:09",
      "link": "https://www.youtube.com/watch?v=bbIFKjyyLew",
      "position": 1,
      "published_at": "Oct 15, 2015",
      "rank": 1,
      "source": "YouTube",
      "source_url": "https://www.google.com/goto?url=CAESZgHrOzAVHoIgq_4pyPKW3wk0K59nV_cxYZH3C-hAne4naEUunKnMaaT_FSKPw4uv…",
      "thumbnail": "data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wCEAAkGBwgHBgkIBwgKCgkLDRYPDQwMDRsUFRAWIB0iIiAdH…",
      "thumbnail_url": "data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wCEAAkGBwgHBgkIBwgKCgkLDRYPDQwMDRsUFRAWIB0iIiAdH…",
      "time": "Oct 15, 2015",
      "title": "How A Coffee Machine Works | Mike Cooper",
      "url": "https://www.youtube.com/watch?v=bbIFKjyyLew"
    },
    {
      "display_link": "www.youtube.com",
      "display_url": "www.youtube.com",
      "duration": "17:38",
      "link": "https://www.youtube.com/watch?v=5igXx83J_Iw",
      "position": 2,
      "published_at": "Mar 9, 2016",
      "rank": 2,
      "source": "YouTube",
      "source_url": "https://www.google.com/goto?url=CAESZgHrOzAVkT938-XmxiN3hhv79FUC6ib8mIiTCHDnUyf8s8LvsDsM0921iTJGNxV6…",
      "thumbnail": "data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wCEAAkGBwgHBgkIBwgKCgkLDRYPDQwMDRsUFRAWIB0iIiAdH…",
      "thumbnail_url": "data:image/jpeg;base64,/9j/4AAQSkZJRgABAQAAAQABAAD/2wCEAAkGBwgHBgkIBwgKCgkLDRYPDQwMDRsUFRAWIB0iIiAdH…",
      "time": "Mar 9, 2016",
      "title": "How it Works: Deep Inside a Cutaway Espresso Machine",
      "url": "https://www.youtube.com/watch?v=5igXx83J_Iw"
    }
  ]
}

Parameters

qrequired
string
Search query string.
hl
string
Language code.
More

Defaults to en.

gl
string
Country code.
More

Defaults to us.

page
number
1-based page number.
More

Defaults to 1.

format
"json" | "markdown"
json (default) returns the parsed result.
More

markdown returns the same result as Markdown text (text/markdown) for language models: no envelope, no duplicate alias fields, no inline images. Same credits; failures keep the JSON envelope.

timeout
number
How many seconds you will wait, 1 to 30 (decimals allowed).
More

Optional; without it the platform spends up to 30 seconds. With it, retries on other routes start earlier so an answer can still arrive inside your budget, and when the budget runs out the request ends with status 1504 and is not charged, instead of being cut off by your HTTP client. Keep your client's own timeout above this value.

query
string
Example: "how espresso machines work"

If no dedicated video cards are parsed, the parser falls back to news-style extraction for compatible Google layouts.

What comes back

Fields that are not on the page for a given request are left out rather than sent empty.

query
required
string

required

Normalized query from the request.

page
required
number

required

Current 1-based page number.

videos
optional
VideoResult[]

When video results are parsed.

Google Videos results.

VideoResult Result item schema

rank
required
number

required

1-based place of the item within its own module (the 3rd organic result has rank 3).

position
optional
number (integer)

On every item and module of Google web search except the plain-text lists related_searches and people_also_search_for; elsewhere when available.

Where the item's module sits on the results page: its block number from the top (1 = first). Each organic result is one block and every other module one block, so all items of a module share its number. Use rank for the order within a module. On products that show a single list, position equals rank.

title
required
string

required

Result title.

link
required
string

required

Primary link returned by the parser.

url
optional
string

Present for normalized result links.

Canonical target URL, usually the same value as link.

source_url
optional
string

Only when Google redirect/source URL is observed.

Original Google URL kept for debugging and provenance.

display_url
optional
string

When Google display text or a domain can be derived.

Display URL or source domain.

source
optional
string

When source/channel can be parsed.

Video source or channel label.

duration
optional
string

When duration appears in result text.

Video duration text.

time
optional
string

When posted time can be parsed.

Raw posted time text.

published_at
optional
string

Alias for parsed time when available.

Normalized posted time alias.

thumbnail_url
optional
string

When Google exposes a thumbnail.

Thumbnail URL.

thumbnail
optional
string

Alias for thumbnail_url when available.

Normalized thumbnail alias.

If it fails

A failed request has a non-zero status and an error, and is not charged. The ones you will see here:

1000A parameter is missing or wrongFix the request
1020No credits leftTop up
1029Over your requests per secondWait Retry-After seconds
1502 · 1504The source could not be read this timeRetry
All status codes →