API · Cross-platform search
GET /search/forums
Reddit, Hacker News and Stack Overflow searched together, with top comments on the most discussed threads. Metered.
| Request | GET /v1/search/forums |
| Operation id | search.forums.get |
| Cost | 10 credits, refunded if the call fails |
| Auth | API key: Authorization: Bearer <key> or x-api-key. |
Reddit, Hacker News and Stack Overflow searched together, with top comments on the most discussed threads. Metered.
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
query | string | yes | Search words. Example: postgres vs mysql. |
sources | string | string[] | no | Any of reddit, hackernews, stackoverflow (default all). |
exclude | string | string[] | no | Sources to leave out. |
comments | integer | null | no | Threads to open for top comments (default 3). |
timeframe | "day" | "week" | "month" | "year" | "all" | no | Window, from now. One of day, week, month, year, all. |
lookback_days | integer | no | Window in days, from now. |
sort | "relevance" | "date" | "engagement" | no | relevance (default, each platform’s own ranking), date (newest first) or engagement. One of relevance, date, engagement. |
Responses
| Status | Meaning | Schema |
|---|---|---|
200 | Forum threads, with top comments on the hero threads. | |
400 | Invalid input. Nothing was charged. | Error |
401 | Missing or invalid API key. | Error |
402 | Not enough credits, a spend cap was reached, or payment is required. | Error |
403 | The target is private, or the account is suspended. | Error |
404 | Nothing matched on any platform. | Error |
429 | Too many requests. Wait for Retry-After seconds. | Error |
503 | Cross-platform search is temporarily unavailable. Retryable; nothing was charged. | Error |
Errors use one shape everywhere; see Errors for every code and what to do.