querystringобязательно
The video search query.
https://api.sandbase.ai/v1/api/google/videosSearch Google for video results (YouTube and others) with title, link, thumbnail, and source.
Ваш результат появится здесь
Заполните входные данные, затем нажмите «Запустить».
Returns Google video search results for a text query. Each result has a title, link, position, snippet, and thumbnail image. The only required input is query.
timeframe to 7d or 1y.curl -X POST "https://api.sandbase.ai/v1/api/google/videos" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"gl": "us", "hl": "en", "query": "lofi hip hop"}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
query | string | Yes | The video search query. |
autocorrect | boolean | No | Toggle Google spelling autocorrect (default true). Set false to search the exact query without correction. |
gl | string | No | Two-letter country code for result localization (e.g. us, gb, de). |
hl | string | No | Two-letter interface and results language code (e.g. en, es, de). |
location | string | No | Fine-grained location for result localization, given as a canonical Google location string (e.g. 'New York, United States', 'London, United Kingdom'). More specific than the country-level gl. |
requireFields | array | No | Optional; omit it and routing is unchanged, with the cheapest source serving. Name the output fields this request must be able to return, for example source, and it is served only by a source that returns every one of |
timeframe | string | No | Restrict results to a recent time window: 1h, 1d, 7d, 1y, or all. Default all (no time restriction). |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"data": {
"query": "lofi hip hop",
"results": [
{
"image": "",
"link": "https://www.youtube.com/watch?v=rFZHOHl-L8A",
"position": 1,
"snippet": "Spooky season is officially upon us 2026 Halloween playlist available now: https…",
"title": "lofi hip hop radio beats to relax/study to"
}
]
},
"found": true
}
| Field | Meaning |
|---|---|
data.query | The search query that Google ran. It can differ from your input if autocorrect changed it. |
data.results[].position | Rank of the video in the result list, starting at 1. |
data.results[].title | Title of the video result. |
data.results[].link | URL of the video page, such as a YouTube watch link. |
data.results[].snippet | Text shown under the result. It can include the description start, the site name, the channel name, and a date. |
data.results[].image | Thumbnail of the video. It is either an empty string or an inline base64 data:image/jpeg value. |
found | true when the search returned results. |
source field is not in this response. Pass requireFields: ["source"] if you need it. This can change the price.snippet, after the description text.gl, hl, and location to localize results. Use location for city-level targeting.Billed at the actual cost of each call, about $0.00085 for the request above. Failed calls are not charged.
Начните разработку
Конечная точка платформенного API с единообразной аутентификацией и учётом использования.
curl -X POST "https://api.sandbase.ai/v1/api/google/videos" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"gl": "us",
"hl": "en",
"query": "lofi hip hop"
}'Укажите свой ключ SandBase API в окружении сервера. Запросы используют аутентификацию Bearer.
export SANDBASE_API_KEY="YOUR_API_KEY"Храните ключ на сервере. Не раскрывайте его в коде браузера.
querystringобязательноThe video search query.
glstringTwo-letter country code for result localization (e.g. us, gb, de).
По умолчанию: "us"
hlstringTwo-letter interface and results language code (e.g. en, es, de).
По умолчанию: "en"
locationstringFine-grained location for result localization, given as a canonical Google location string (e.g. 'New York, United States', 'London, United Kingdom'). More specific than the country-level gl.
timeframestringRestrict results to a recent time window: 1h, 1d, 7d, 1y, or all. Default all (no time restriction).
Возможные значения: 1h, 1d, 7d, 1y, all
autocorrectbooleanToggle Google spelling autocorrect (default true). Set false to search the exact query without correction.
requireFieldsarrayOptional; omit it and routing is unchanged, with the cheapest source serving. Name the output fields this request must be able to return, for example `source`, and it is served only by a source that returns every one of them. Fields you do not name are still returned whenever the serving source has them. This can raise your price: when the cheapest source cannot return a named field, a dearer source serves, and you are quoted and charged its price. A named field can still be absent on a record that genuinely lacks it. Naming a combination that no single source returns together is refused as invalid input, with no charge.
Сохранённый пример ответа для этого API; при просмотре живой запрос не выполняется.
Сохранённый ответ не опубликован. Запустите API в Playground, чтобы посмотреть его ответ.
Посмотреть больше
| API | Цена | Ответ |
|---|---|---|
Google VideosЭтот API Google | От $0.00085 за запрос | JSON |
Google | $0.01 за запрос | JSON |
Google | $0.015 за запрос | JSON |
Google | От $0.002 за запрос | JSON |
Google | От $0.0015 за запрос | JSON |
Google | $0.01 за запрос | JSON |
Руководства:Best Google API in 2026: Pricing Compared
Вопросы
Отправьте POST-запрос на https://api.sandbase.ai/v1/api/google/videos, указав ключ SandBase API в заголовке Authorization (Bearer), а параметры — в теле JSON. Вы также можете попробовать это в Playground на этой странице без написания кода.
От $0.00085 за вызов, списывается с баланса SandBase. Оплата взимается только за сделанные вызовы; подписка не требуется.
Обязательные: query (string). Необязательные: gl (string), hl (string), location (string), timeframe (один из 1h, 1d, 7d, 1y, all), autocorrect (boolean) и requireFields (array). В таблице Parameters и в Playground на этой странице перечислены все поля.
JSON-ответ, возвращаемый в том же HTTP-запросе (синхронно). В README на этой странице приведен пример ответа.
Нет. Google Videos работает через SandBase, поэтому один API key SandBase покрывает этот endpoint и все остальные API и модели в каталоге. Вам не нужно отдельно запрашивать доступ к API Google.