> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stophy.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Video

> Search YouTube, TikTok, and Kick, and open any video, channel, or playlist. Get transcripts, comments, and clip details as JSON or markdown.

Search YouTube, TikTok, and Kick, and open any video, channel, or playlist. Get transcripts, comments, and clip details as JSON or markdown. See every field in the [Video reference](/api-reference/endpoint/youtube-search), or try it in the [playground](https://stophy.dev/playground).

## Search YouTube videos, channels, playlists and shorts

<CodeGroup>
  ```typescript TypeScript icon="https://mintcdn.com/sirathic/7E4w9-IC4ysabjfc/images/icons/typescript.svg?fit=max&auto=format&n=7E4w9-IC4ysabjfc&q=85&s=d8272a85e64145620f1fbbfcf7932986" theme={null}
  import { Stophy } from "stophy";

  const stophy = new Stophy({ apiKey: process.env.STOPHY_API_KEY });
  const result = await stophy.youtube.search({ query: "rust tutorial" });
  console.log(result.data.results);
  ```

  ```python Python icon="python" theme={null}
  from stophy import Stophy

  stophy = Stophy()  # reads STOPHY_API_KEY
  result = stophy.youtube.search(query="rust tutorial")
  print(result["data"]["results"])
  ```

  ```bash cURL icon="terminal" theme={null}
  curl -X POST https://api.stophy.dev/v1/youtube/search \
    -H "Authorization: Bearer $STOPHY_API_KEY" \
    -H "content-type: application/json" \
    -d '{"query":"rust tutorial"}'
  ```

  ```bash CLI icon="square-terminal" theme={null}
  stophy youtube search "rust tutorial"
  ```
</CodeGroup>

The response:

```json theme={null}
{
  "success": true,
  "data": {
    "results": [
      {
        "type": "video",
        "id": "Wc0ZJo06oAw",
        "url": "https://www.youtube.com/watch?v=Wc0ZJo06oAw",
        "title": "The Ultimate Rust Beginners Guide (2026)",
        "channel": {
          "id": "UCt6XPuD8u3YjvybuT-Xnj5A",
          "username": "SBJake",
          "name": "SBJake",
          "url": "https://www.youtube.com/channel/UCt6XPuD8u3YjvybuT-Xnj5A"
        },
        "durationSeconds": 422,
        "views": 543208,
        "thumbnail": "https://i.ytimg.com/vi/Wc0ZJo06oAw/hqdefault.jpg",
        "isShort": false,
        "isLive": false,
        "createdAt": "2025-09-28T13:19:10.000Z"
      },
      {
        "type": "video",
        "id": "5C_HPTJg5ek",
        "url": "https://www.youtube.com/watch?v=5C_HPTJg5ek",
        "title": "Rust in 100 Seconds",
        "channel": {
          "id": "UCsBjURrPoezykLs9EqgamOA",
          "username": "Fireship",
          "name": "Fireship",
          "url": "https://www.youtube.com/channel/UCsBjURrPoezykLs9EqgamOA"
        },
        "durationSeconds": 149,
        "views": 2518131,
        "thumbnail": "https://i.ytimg.com/vi/5C_HPTJg5ek/hqdefault.jpg",
        "isShort": false,
        "isLive": false,
        "createdAt": "2022-09-28T19:51:34.000Z"
      }
    ]
  },
  "creditsUsed": 0,
  "requestId": "5fb0898a-3983-4f30-ae3e-3146c406ccd1"
}
```

## Endpoints

| Endpoint | Cost |
| - | - |
| [Search YouTube videos, channels, playlists and shorts](/api-reference/endpoint/youtube-search) | 1 credit per 20 items, at least 1 credit (no key needed) |
| [Get a video's title, channel, views, likes and description](/api-reference/endpoint/youtube-video) | 1 credit |
| [Get a video's transcript, with optional timestamps](/api-reference/endpoint/youtube-transcript) | 3 credits (no key needed) |
| [Get a video's comments](/api-reference/endpoint/youtube-comments) | 1 credit per 20 items, at least 1 credit |
| [Get the replies to a video comment](/api-reference/endpoint/youtube-comments-replies) | 1 credit per 10 items, at least 1 credit |
| [Get a channel's videos, shorts, playlists and about info](/api-reference/endpoint/youtube-channel) | 1 credit per 30 items, at least 1 credit |
| [Get the videos in a playlist](/api-reference/endpoint/youtube-playlist) | 1 credit per 100 items, at least 1 credit |
| [Get YouTube search suggestions for a keyword](/api-reference/endpoint/youtube-suggest) | 1 credit per 50 items, at least 1 credit |
| [Get a profile's bio and stats](/api-reference/endpoint/tiktok-profile) | 1 credit |
| [Get a video's caption, stats and music](/api-reference/endpoint/tiktok-video) | 1 credit |
| [Get any TikTok profile or video from its link](/api-reference/endpoint/tiktok-url) | 1 credit |
| [Get a video's transcript, with optional timestamps](/api-reference/endpoint/tiktok-transcript) | 5 credits |
| [Get a profile's videos](/api-reference/endpoint/tiktok-posts) | 1 credit per 30 items, at least 1 credit |
| [Get videos for a hashtag](/api-reference/endpoint/tiktok-hashtag) | 1 credit per 30 items, at least 1 credit |
| [Get a video's comments](/api-reference/endpoint/tiktok-comments) | 1 credit per 20 items, at least 1 credit |
| [Get the replies to a video comment](/api-reference/endpoint/tiktok-comments-replies) | 1 credit per 20 items, at least 1 credit |
| [Search TikTok videos and users](/api-reference/endpoint/tiktok-search) | 1 credit per 12 items, at least 1 credit |
| [Get a channel's info and stats](/api-reference/endpoint/kick-channel) | 1 credit |
| [Get a channel's past streams](/api-reference/endpoint/kick-videos) | 1 credit |
| [Get a channel's clips](/api-reference/endpoint/kick-clips) | 1 credit per 20 items, at least 1 credit |

## More ways to call it

### Get a video's transcript, with optional timestamps

<CodeGroup>
  ```typescript TypeScript icon="https://mintcdn.com/sirathic/7E4w9-IC4ysabjfc/images/icons/typescript.svg?fit=max&auto=format&n=7E4w9-IC4ysabjfc&q=85&s=d8272a85e64145620f1fbbfcf7932986" theme={null}
  import { Stophy } from "stophy";

  const stophy = new Stophy({ apiKey: process.env.STOPHY_API_KEY });
  const result = await stophy.youtube.transcript({ video: "dQw4w9WgXcQ" });
  console.log(result.data.text);
  ```

  ```python Python icon="python" theme={null}
  from stophy import Stophy

  stophy = Stophy()  # reads STOPHY_API_KEY
  result = stophy.youtube.transcript(video="dQw4w9WgXcQ")
  print(result["data"]["text"])
  ```

  ```bash cURL icon="terminal" theme={null}
  curl -X POST https://api.stophy.dev/v1/youtube/transcript \
    -H "Authorization: Bearer $STOPHY_API_KEY" \
    -H "content-type: application/json" \
    -d '{"video":"dQw4w9WgXcQ"}'
  ```

  ```bash CLI icon="square-terminal" theme={null}
  stophy youtube transcript dQw4w9WgXcQ
  ```
</CodeGroup>

### Get a profile's bio and stats

<CodeGroup>
  ```typescript TypeScript icon="https://mintcdn.com/sirathic/7E4w9-IC4ysabjfc/images/icons/typescript.svg?fit=max&auto=format&n=7E4w9-IC4ysabjfc&q=85&s=d8272a85e64145620f1fbbfcf7932986" theme={null}
  import { Stophy } from "stophy";

  const stophy = new Stophy({ apiKey: process.env.STOPHY_API_KEY });
  const result = await stophy.tiktok.profile({ user: "khaby.lame" });
  console.log(result.data.profile);
  ```

  ```python Python icon="python" theme={null}
  from stophy import Stophy

  stophy = Stophy()  # reads STOPHY_API_KEY
  result = stophy.tiktok.profile(user="khaby.lame")
  print(result["data"]["profile"])
  ```

  ```bash cURL icon="terminal" theme={null}
  curl -X POST https://api.stophy.dev/v1/tiktok/profile \
    -H "Authorization: Bearer $STOPHY_API_KEY" \
    -H "content-type: application/json" \
    -d '{"user":"khaby.lame"}'
  ```

  ```bash CLI icon="square-terminal" theme={null}
  stophy tiktok profile khaby.lame
  ```
</CodeGroup>

### Get a channel's info and stats

<CodeGroup>
  ```typescript TypeScript icon="https://mintcdn.com/sirathic/7E4w9-IC4ysabjfc/images/icons/typescript.svg?fit=max&auto=format&n=7E4w9-IC4ysabjfc&q=85&s=d8272a85e64145620f1fbbfcf7932986" theme={null}
  import { Stophy } from "stophy";

  const stophy = new Stophy({ apiKey: process.env.STOPHY_API_KEY });
  const result = await stophy.kick.channel({ channel: "xqc" });
  console.log(result.data.channel);
  ```

  ```python Python icon="python" theme={null}
  from stophy import Stophy

  stophy = Stophy()  # reads STOPHY_API_KEY
  result = stophy.kick.channel(channel="xqc")
  print(result["data"]["channel"])
  ```

  ```bash cURL icon="terminal" theme={null}
  curl -X POST https://api.stophy.dev/v1/kick/channel \
    -H "Authorization: Bearer $STOPHY_API_KEY" \
    -H "content-type: application/json" \
    -d '{"channel":"xqc"}'
  ```

  ```bash CLI icon="square-terminal" theme={null}
  stophy kick channel xqc
  ```
</CodeGroup>

<Tip>YouTube search, YouTube transcripts, and web search work without a key. Every other endpoint on this page needs one.</Tip>
