GET /v1/youtube/search_suggestions

YouTube autocomplete API: search suggestions for a keyword

Returns the suggestions YouTube's search box shows for a keyword, each with its text and, when YouTube names one, the matching channel. Send keyword, and region as a two-letter country code to localize the list.

Price
$0.0005 per call
Batch
Yes, through /v1/batch
Failed calls
Not charged

Example request

curl
curl 'https://api.virev.ai/v1/youtube/search_suggestions?keyword=mkbhd' \
  -H "Authorization: Bearer $VIREV_API_KEY"
python
import os
import requests

response = requests.request(
    "GET",
    "https://api.virev.ai/v1/youtube/search_suggestions",
    params={
        "keyword": "mkbhd",
    },
    headers={"Authorization": f"Bearer {os.environ['VIREV_API_KEY']}"},
    timeout=60,
)
response.raise_for_status()
print(response.json())

Parameters

NameInTypeDescription
keyword requiredquerystringThe search query, up to 100 characters. Example mkbhd.
region querystringA two-letter country code that localizes the results.
cached queryauto | cache_only | liveauto (default) serves a read saved within the last 24 hours for these exact arguments, otherwise fetches. cache_only never contacts YouTube (404 not_cached when nothing is saved, whatever its age). live always fetches. Anything else is a 400. Default auto.
get_raw querybooleantrue returns the upstream JSON exactly as YouTube answered it instead of the normalized YouTubeSuggestion[]. Default false.

Example response

The example response of the API reference.

json
{
  "data": [
    {
      "text": "marques brownlee",
      "channel": {
        "id": null,
        "username": "American Influencer",
        "full_name": "Marques Brownlee",
        "is_verified": null,
        "is_private": null,
        "avatar_url": "https://encrypted-tbn1.gstatic.com/images?q=tbn:ANd9GcQcUbO3RAkBeZOoWPkaiUjcMPoqxLrApS1IO3NDdN4r9X9YsRxe",
        "latest_story_at": null,
        "extra": {}
      }
    },
    {
      "text": "marques brownlee iphone 17",
      "channel": null
    }
  ],
  "meta": {
    "source": "live",
    "fetched_at": "2026-07-22T10:44:06.776706+00:00",
    "cost": "$0.0005",
    "balance": "$3.3522",
    "request_id": "req_f8c5024ad21c08e0c93032bb03729d5a"
  }
}

How it works

YouTube's autocomplete for a query. Returns YouTubeSuggestion[] under data; with get_raw=true returns the upstream JSON.

A field YouTube does not carry is null, a list it does not carry is [], and YouTube-only facts sit under extra. Unknown, unsupported, and repeated query parameters return 400 before acquisition or billing.

Errors

StatusWhen
400The request parameters are invalid.
401Missing, malformed, or revoked API key.
402Balance is too low for this request.
404cached=cache_only found nothing saved for these arguments (not_cached; call again with cached=auto to fetch it), or the YouTube account or item does not exist (not_found). You are not charged.
429Over the per-minute limit. The limit belongs to your organization and all its API keys share it: 100 requests per minute unless an increase was granted. Wait for the Retry-After seconds, then retry. On a live read, code rate_limited means the platform itself rate-limited this read; retry after the Retry-After seconds. You are not charged.
502The upstream fetch failed. You are not charged.
503Billing could not be confirmed, so no upstream data was returned.
504The upstream request timed out. You are not charged.

YouTube API guide