semust logo
YouTube API

YouTube API

Pull YouTube search rankings, video details, transcripts and comments for any public video programmatically. Four reports behind one endpoint with no daily quotas — and transcripts work for any video, not only your own.

One Endpoint, Four Reports Transcripts With Translation No Daily Quotas Desktop and Mobile Search Never Charged for Errors
Python API Example
import requests

response = requests.post(
    "https://data.semust.com/v1/youtube",
    headers={
        "SEMUST-API-USER": "your_username",
        "SEMUST-API-PASSWORD": "your_password",
    },
    json={
        "type": "search",
        "keyword": "seo nedir",
        "country": "TR",
        "device": "mobile",
        "limit": 20,
    },
    timeout=90,  # longer than ?wait= (60 seconds by default)
)

data = response.json()
if response.status_code == 202:
    # Still running: collect it later from data["poll_url"]
    print(f"Task {data['task_id']} is still running")
elif response.status_code == 200:
    for row in data["items"]:
        print(f"{row['position']}. [{row['type']}] {row['title']}")
        print(f"   Channel: {row['channel_name']}")
        print(f"   Views: {row['views']}")
Cookshop
ideasoft
Yapı Kredi
beko logo
vialand
defacto
koton
venividi logo
Cookshop
ideasoft
Yapı Kredi
beko logo
vialand
defacto
koton
venividi logo

Meet Semust, trusted by 12.000+ brands.

One Endpoint

Search, video, transcript and comments are all selected with the `type` parameter. One request shape to learn, one authentication, one price list.

Any Public Video

Read the transcript, details and comments of any public video, not only your own channel's. Send the 11-character video ID or simply paste a YouTube link.

Clear Pricing

20 search results or comments for $0.0022; a video's details or its transcript for $0.0066. Errors are never charged.

What Can You Build With the YouTube API?

Reach YouTube search, video, transcript and comment data through the data.semust.com/v1/youtube endpoint.

Get the YouTube results for a keyword in ranking order, as a real viewer sees them: videos, Shorts, playlists, channels and ads, each with its position. Choose the country the search runs from, the interface language, and desktop or mobile. Every row carries the title, canonical link, channel, view count, duration and live status — up to 200 results in a single request.

// POST /v1/youtube
// { "type": "search", "keyword": "seo nedir", "limit": 20 }
{
  "type": "search",
  "keyword": "seo nedir",
  "country": "TR",
  "device": "desktop",
  "total": 628065,
  "items": [
    {
      "position": 1,
      "type": "video",
      "title": "SEO Nedir? Yeni Başlayanlar İçin",
      "video_id": "Xk9mP2qR7tA",
      "channel_name": "Example Channel",
      "views": 241552,
      "duration_seconds": 180,
      "is_live": false
    },
    {
      "position": 2,
      "type": "playlist",
      "title": "SEO Eğitimi Serisi",
      "views": null,
      "video_count": 20
    }
  ],
  "cost": 0.0022
}

One platform,Organic success stories:

Batuhan Durmaz

Batuhan Durmaz

SEO Specialist

SEMUST is a powerful tool for SEO professionals. It provides valuable data in a simple and easy‑to‑understand format, making it a great choice for both local and global projects. I use it for keyword analysis, Google Search Console data, ranking tracking, and content creation. I'm very satisfied with it.

Selen Çetin

Selen Çetin

SEO Specialist

I first came across Semust on LinkedIn, back when it was just starting to gain attention. Curious, I decided to give it a try—and it’s now become one of my favorite tools. What I appreciate most is how it handles many tasks that I used to perform manually with a single click, which makes my job significantly easier. Seeing how quickly it has evolved since the first time I used it also inspires confidence.

Aykut Özcan

Aykut Özcan

SEO Director – Digital UP

At Digital UP SEO Agency, we rely heavily on the analysis and reporting tools Semust provides throughout our SEO workflows. From keyword tracking and competitor analysis to site‑health scans and backlink audits, it brings both speed and depth to many critical areas. Thanks to the comprehensive, data‑driven insights it offers, we consistently boost our clients' search‑engine performance. Semust is a powerful partner on our agency's growth journey.

YouTube API Frequently Asked Questions

What Is a YouTube API and How Does It Work?

A YouTube API is an interface that gives you programmatic access to YouTube search results, video information, transcripts and comments. Instead of running searches on YouTube one by one or watching videos to take notes, you make a single HTTP request from your own application and receive that data as structured JSON. It is a strong building block for content teams, agencies and brands that want to run their video strategy on data.

The Semust YouTube API works through a single endpoint: you POST to data.semust.com/v1/youtube and choose the search, video, transcript or comments report with the type parameter. Authentication uses the SEMUST-API-USER and SEMUST-API-PASSWORD headers. A request that runs longer than 60 seconds returns a task_id instead of holding the connection open, and you collect the result later.

Why YouTube Data Matters for SEO and Content Strategy

For many topics, people run their searches directly on YouTube. Which videos rank at the top for a keyword, whether Shorts or long-form videos lead the results, and which channels show up again and again tell you directly what content to produce and in which format.

Collecting this data regularly lets you notice the moment a competitor's video overtakes yours, or a new channel climbing fast in your topic. Once tracking is automated through the API, you catch those changes without anyone having to check by hand.

Tracking YouTube Search Rankings

The search report returns the results for a keyword in ranking order: videos, Shorts, playlists, channels and ads, each with its position. Use country to choose where the search runs from, language for the interface language, and device for the desktop or mobile view. limit returns up to 200 results in a single request, and the total field gives the result count YouTube reports.

Because YouTube shows relative dates in search results ("5 years ago"), published_at is approximate there; when you need a video's exact publish date, the video report provides it. Knowing which values are exact and which are approximate matters when you build reports that combine ranking data with video details.

Turning Video Into Text With Transcripts

The transcript report returns a video's transcript as one plain-text string and as timed segments made of start, end and text fields. You no longer need to watch a video from start to finish to read what a competitor covers and in what order, to turn a video into a blog post or summary, or to analyse the topics and phrases that come up in videos.

Transcripts work for any public video, not only your own. The video report lists the languages a video has transcripts in; choose one with transcript_language and receive it translated into another language with translate_to. Transcripts are cached for 30 days.

YouTube API Pricing

The search and comments reports cost $0.0022 per started block of 20 results, which makes 20 and 40 the most economical limit values. The largest search, 200 results, costs $0.022. The video and transcript reports cost $0.0066 per request. When you send a request, the cost of its limit is held from your balance and anything unused is refunded immediately.

A search or comment list with no results is a valid answer and is billed as one block. Search results, video details and comments are cached for 24 hours and transcripts for 30 days; a cached answer is marked "cached": true and billed at the same price as a live one. You are never charged for an error, and a failed task is refunded in full.

Video and Comment Analysis

The video report sums up a video's performance in one call: view, like and comment counts, the channel's subscriber count, the exact publish date, duration, category and the tags the uploader added. From this data you can read which tags competitors use, and what length and category of content they produce.

The comments report returns a video's top comments with the author, text, likes and reply count, and the total field gives the video's overall comment count. The questions viewers ask and the needs they voice are a direct source for the topic of your next video or your FAQ page.

Countries, Languages and Clean Data

The GET /v1/youtube/markets endpoint lists every supported country and search language, free of charge. country defaults to TR; the search interface language and the transcript language default to tr for TR and en elsewhere. In the video_id field you can send the 11-character ID or any YouTube link in the watch?v=, youtu.be/, shorts/, embed/ or live/ form.

Responses are ready to use: a value that does not exist or does not apply is null, never 0 — a playlist, for example, has views set to null. URLs are canonical, without tracking parameters, and dates are ISO 8601 in UTC, so you do not have to clean the data on your side.

Integrating the YouTube API

All you need to integrate is an API username and password, which you create from the API Access page in your account. Requests are standard HTTP POST, responses are JSON, and the API can be called from any language. The documentation carries cURL and Python examples, and the Tasks page has a ready-made call() helper for Python and Node.js that follows 202 responses for you.

So that a timed-out request can be retried safely, there is idempotency_key support: repeating a request with the same key returns the same task and is charged only once. A parameter that does not apply to the chosen report is rejected rather than ignored, and a misspelled one is named in the error with a suggestion. Each API user can run up to 10 requests at the same time.

More organic traffic 

  • 14-day free trial
  • No setup required
  • Search Console integration