Sand AISand AI MAGI-2MAGI-2 kini tersedia di SandBase: video 1080p dengan audio nativeCoba sekarang

YouTube Shorts Search

Dokumentasi API
https://api.sandbase.ai/v1/api/youtube/search-shorts

Search YouTube Shorts by keyword and get matching Shorts (title, views, URL) with cursor pagination as normalized JSON.

Harga
Dari $0.0012USD / panggilan
Metode
POST
Respons
JSON
Parameter
1 wajib · 3 opsional

Playground

Input
The keyword to search Shorts for.
Continuation token from a previous response for pagination.
Sort order: "relevance" (default) or "popular" (most-viewed).
Filter by upload recency. Omit for any time.
OutputSiap

Output Anda akan muncul di sini

Lengkapi input, lalu klik Run.

README API

YouTube Shorts Search API

Returns YouTube Shorts that match a keyword. Each result has an ID, title, URL and view count. You only need a query, and you can sort, filter by upload date and page through results.

Use cases

  • Find the most-viewed Shorts for a topic by setting sortBy to popular.
  • Track new Shorts about a brand or keyword by setting uploadDate to today or this_week.
  • Build a list of Short URLs and IDs to pass to a video details lookup.
  • Compare view counts across Shorts that cover the same topic.

Request

curl -X POST "https://api.sandbase.ai/v1/api/youtube/search-shorts" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"query": "cats"}'

The result is returned in outputs[0].data.

Parameters

NameTypeRequiredDescription
querystringYesThe keyword to search Shorts for.
cursorstringNoContinuation token from a previous response for pagination.
sortBystringNoSort order: "relevance" (default) or "popular" (most-viewed).
uploadDatestringNoFilter by upload recency. Omit for any time.

Example response

Real response for the request above, trimmed: lists keep their first item and long strings are cut.

{
  "data": {
    "nextCursor": "cur_fPTLy4Ok3x74uh2aBTeYXQ",
    "shorts": [
      {
        "contentType": "short",
        "id": "M93h41hyPsM",
        "title": "Ranking Funny Cat Moment",
        "url": "https://www.youtube.com/watch?v=M93h41hyPsM",
        "views": 17000000,
        "viewsAvailable": true
      }
    ]
  },
  "found": true
}

Response fields

FieldMeaning
data.shorts[]List of Shorts that match the query.
data.shorts[].idYouTube video ID of the Short.
data.shorts[].titleTitle of the Short. It can include hashtags and emoji.
data.shorts[].urlWatch URL for the Short, in the form https://www.youtube.com/watch?v=<id>.
data.shorts[].viewsView count as a number.
data.shorts[].viewsAvailabletrue when a view count was found for the Short. Check it before you use views.
data.shorts[].contentTypeType of the result. The value is short for these results.
data.nextCursorToken for the next page of results. Send it as cursor in the next request.
foundtrue when the search returned results.

Notes

  • For the next page, repeat the same request and add cursor with the value of data.nextCursor.
  • Use the id value with YouTube Video Details to get more data about a single Short.
  • To list the Shorts of one channel instead of searching by keyword, use YouTube Channel Shorts.

Pricing

Billed at the actual cost of each call, about $0.0012 for the request above. Failed calls are not charged.

Jelajahi lebih lanjut

API Terkait

Semua APIs
APIHargaRespons
YouTubeDari $0.0012 per panggilanJSON
YouTubeDari $0.00045 per panggilanJSON
YouTubeDari $0.0012 per panggilanJSON
YouTubeDari $0.0012 per panggilanJSON
YouTubeDari $0.0012 per panggilanJSON
YouTube$0.014286 per panggilanJSON

Panduan:Best YouTube API in 2026: Pricing Compared

Pertanyaan

FAQ

Bagaimana cara menggunakan API YouTube Shorts Search?

Kirim permintaan POST ke https://api.sandbase.ai/v1/api/youtube/search-shorts dengan kunci API SandBase Anda di header Authorization (Bearer) dan parameter sebagai body JSON. Anda juga dapat mencobanya di Playground di halaman ini tanpa menulis kode.

Berapa biaya API YouTube Shorts Search?

Mulai dari $0.0012 per panggilan, ditagihkan dari saldo SandBase Anda. Anda hanya dikenai biaya untuk panggilan yang Anda lakukan; tidak ada langganan.

Parameter apa yang diterima API YouTube Shorts Search?

Wajib: query (string). Opsional: cursor (string), sortBy (salah satu dari relevance, popular) dan uploadDate (salah satu dari today, this_week, this_month, this_year). Tabel Parameters dan Playground di halaman ini mencantumkan setiap field.

Apa yang dikembalikan API YouTube Shorts Search?

Respons JSON yang dikembalikan dalam permintaan HTTP yang sama (sinkron). README di halaman ini menyertakan contoh respons.

Apakah saya memerlukan akun developer atau kunci API YouTube?

Tidak. YouTube Shorts Search berjalan melalui SandBase, jadi satu kunci API SandBase mencakup endpoint ini dan setiap API serta model lain di katalog. Anda tidak perlu mendaftar akses API YouTube secara terpisah.