API para Hacker News: Buscar
Busque no Hacker News por palavra-chave: posts correspondentes com título, link, autor, pontos e número de comentários em JSON limpo.
Rede de provedores
Provedores ordenados por tráfego
Teste
Faça sua primeira requisição
{
"data": {
"results": [
{
"author": "Alex Rivera",
"comments": 12500,
"createdUtc": 12.5,
"id": "a1b2c3d4",
"permalink": "https://example.com/page",
"points": 42,
"title": "Example title",
"url": "https://example.com/page"
}
]
},
"found": true,
"reason": "not_found"
}interface HackernewsSearchResponse {
data: {
results: {
author: string;
comments: number;
createdUtc: number;
id: string;
permalink?: string;
points: number;
title: string;
url: string;
}[];
} | null;
found: boolean;
reason?: "not_found";
}Referência completa de parâmetros e resposta - todos os campos, tipos e exemplos deste endpoint.
Referência
Requisição, resposta e preço
Última verificação em 2026-09-29 · disponibilidade e latência medidas em 30dcurl -X POST https://api.getanyapi.com/v1/run/hackernews.search \
-H "Authorization: Bearer $ANYAPI_KEY" \
-H "Content-Type: application/json" \
-d '{"query":"ai"}'| Campo | Tipo | Valor de exemplo |
|---|---|---|
| Corpo da requisição | ||
| query | string | "ai"Palavra-chave da busca, por exemplo "ai". |
| tags | string | Filtro opcional de resultados, por exemplo "story" ou "comment". |
| Resposta | ||
| data | object | Result payload, or null when nothing was found. |
| data.results | object[] | Matching Hacker News stories. Populated whenever the provider has data for the entity. |
| data.results[].author | string | Submitting user's username. Populated whenever the provider has data for the entity. |
| data.results[].comments | integer | Number of comments on the story. |
| data.results[].createdUtc | number | UTC epoch timestamp in seconds (Unix time). Multiply by 1000 for a JS Date in milliseconds. Populated whenever the provider has data for the entity. |
| data.results[].id | string | Hacker News item id. Populated whenever the provider has data for the entity. |
| data.results[].permalink | string | Permalink to the item on news.ycombinator.com. |
| data.results[].points | integer | Story score (upvotes). |
| data.results[].title | string | Story title. Populated whenever the provider has data for the entity. |
| data.results[].url | string | Story link. |
| found | boolean | True when the search returned at least one story. |
| reason | "not_found" | Present only when `found` is false, and says why there is no result. `not_found`: the source states the target does not exist, or returned nothing for it. A `found: false` answer is a successful call, not an error, and `costUsd` is what it actually cost. |
| Preço | ||
| Preço por requisição | USD | US$ 0,0015 |
| Preço /mil req. | USD | US$ 1,50 |
Dúvidas frequentes
Sobre o endpoint Buscar da API para Hacker News
O endpoint Buscar da AnyAPI para Hacker News retorna dados de Hacker News em JSON normalizado com uma chamada POST para /v1/run/hackernews.search. Busque no Hacker News por palavra-chave: posts correspondentes com título, link, autor, pontos e número de comentários em JSON limpo. A AnyAPI distribui cada requisição entre 2 fontes, com failover automático quando uma falha. Custa a partir de US$ 1,50 por mil requisições, em dólares, sem assinatura e sem mínimo mensal. Nos últimos 30 dias, 100,0% das chamadas ao endpoint Buscar da API para Hacker News feitas pela AnyAPI tiveram sucesso, com tempo de resposta mediano de 0,5 segundos, em 664 chamadas medidas.