keywordstringobrigatório
Search keyword (required)
https://api.sandbase.ai/v1/api/youtube/web-v2/search-suggestionsReturns YouTube autocomplete search suggestions for a given keyword query. Supports optional geographic region and language filtering.
[
{
"data": {
"keyword": "OpenAI",
"suggestions": [
"openai",
"openai dots",
"openai hugging face",
"… 11 more items in the full response"
],
"total_count": 14
}
}
]Selecione um exemplo para carregar as entradas e o resultado no playground.
Returns YouTube autocomplete suggestions for a search keyword. You send a keyword and can set region and language to localize the results.
OpenAI, to plan video titles.keyword across different region and language values to see how searches differ by market.curl -X POST "https://api.sandbase.ai/v1/api/youtube/web-v2/search-suggestions" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"keyword": "OpenAI"}'
The result is returned in outputs[0].data.
| Name | Type | Required | Description |
|---|---|---|---|
keyword | string | Yes | Search keyword (required) |
language | string | No | Language code (optional, default en) |
region | string | No | Region code (optional, default US) |
Real response for the request above, trimmed: lists keep their first item and long strings are cut.
{
"keyword": "OpenAI",
"suggestions": [
"openai"
],
"total_count": 14
}
| Field | Meaning |
|---|---|
keyword | The search term the suggestions were requested for. It matches the keyword you sent. |
suggestions[] | List of autocomplete phrases, as plain strings. The first item in the example is the keyword itself in lowercase, followed by longer phrases that start with it. |
total_count | Number of suggestions reported for the query. In the example it is 14, while the list is trimmed to a few items. |
keyword is required and can be up to 200 characters. region defaults to US and language defaults to en.$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.
Comece a construir
Endpoint da API da plataforma com autenticação unificada e rastreamento de uso.
curl -X POST "https://api.sandbase.ai/v1/api/youtube/web-v2/search-suggestions" \
-H "Authorization: Bearer $SANDBASE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"region": "US",
"keyword": "OpenAI",
"language": "en"
}'Defina sua chave da API SandBase no ambiente do seu servidor. As requisições usam autenticação Bearer.
export SANDBASE_API_KEY="YOUR_API_KEY"Mantenha sua chave no servidor. Não a exponha em código do navegador.
keywordstringobrigatórioSearch keyword (required)
languagestringLanguage code (optional, default en)
Padrão: "en"
regionstringRegion code (optional, default US)
Padrão: "US"
Resposta de exemplo salva para esta API; nenhuma requisição ao vivo é feita ao visualizá-la.
[
{
"data": {
"keyword": "OpenAI",
"suggestions": [
"openai",
"openai dots",
"openai hugging face",
"… 11 more items in the full response"
],
"total_count": 14
}
}
]Explorar mais
| API | Preço | Resposta |
|---|---|---|
YouTube Search SuggestionsEsta API YouTube | $0.001 por chamada | JSON |
YouTube | $0.001 por chamada | JSON |
YouTube | $0.001 por chamada | JSON |
YouTube | $0.001 por chamada | JSON |
YouTube | $0.001 por chamada | JSON |
YouTube | $0.001 por chamada | JSON |
Perguntas
Envie uma solicitação POST para https://api.sandbase.ai/v1/api/youtube/web-v2/search-suggestions com sua chave de API da SandBase no cabeçalho Authorization (Bearer) e os parâmetros no corpo JSON. Você também pode testar no Playground desta página sem escrever código.
$0.001 por chamada. Cada organização recebe 100 chamadas grátis por dia UTC, compartilhadas entre as APIs elegíveis da SandBase, incluindo esta; depois disso, cada chamada é cobrada nesse valor do seu saldo SandBase. Não há assinatura.
Obrigatórios: keyword (string). Opcionais: language (string) e region (string). A tabela de Parâmetros e o Playground nesta página listam todos os campos.
Uma resposta JSON retornada na mesma solicitação HTTP (síncrona). O README desta página inclui um exemplo de resposta.
Não. YouTube Search Suggestions funciona via SandBase, então uma única chave de API da SandBase cobre este endpoint e todas as outras APIs e modelos do catálogo. Você não precisa solicitar acesso à API do YouTube separadamente.