News search (/news)

Reference for /news: news search parameters, response fields, code in 5 languages, GET and POST forms, and a sample response.

Updated View as Markdown

The Google News tab, with source, publish time and site icon. Results are in news. The product page is Google News API.

Try in PlaygroundOpens the dashboard playground with this request filled in (sign in first).

Request

POST https://api.bestserp.com/news with a JSON body, or GET https://api.bestserp.com/news with the same parameters in the query string. The key goes in the X-API-KEY header either way (authentication).

POST
curl -X POST 'https://api.bestserp.com/news' \
  -H 'X-API-KEY: YOUR_API_KEY' \
  -H 'Content-Type: application/json' \
  -d '{"q":"electric vehicles"}'
GET
curl -G 'https://api.bestserp.com/news' \
  -H 'X-API-KEY: YOUR_API_KEY' \
  --data-urlencode 'q=electric vehicles'

Parameters

Unknown parameters are refused (unknown_parameter), so a typo never goes unnoticed.

ParameterTypeDefaultDescription
qrequiredstringSearch query (1–256 characters).
glstringusCountry, 2-letter code (us, gb, vn, de…). The search runs from an IP in that country when one is free, else from another one (see ipCountry).
hlstringenInterface language (en, vi, de…).
numinteger10Maximum results per page: 10, 20, 30, 40 or 50 (Google may return fewer, e.g. 8 or 9 of 10). Each 10 costs 1 credit.
pageinteger1Page to return, 1–5 (page × num/10 ≤ 5). Pages 1…page are fetched and charged.
tbsstringRecency: qdr:h (hour), qdr:d (day), qdr:w (week), qdr:m (month), qdr:y (year). Also accepted: timeRange = hour|day|week|month|year.
resolveLinksbooleantrueReplace Google redirect links with final URLs. Results come back at once with linksPending: true; poll the request for final links.
includeThumbnailsbooleanfalseInclude inline base64 thumbnails (~20 KB each).
noCachebooleanfalseSkip the 1-hour result cache (5 minutes for news).
asyncbooleanfalseAnswer 202 immediately with a requestId to poll.
timeoutnumber60Seconds to wait before answering 202 (1–120).
autocorrectbooleanAccepted for compatibility; no effect.

Response fields

Empty fields are left out of each item.

news[]

FieldMeaning
positionRank of the article, from 1.
titleHeadline.
linkArticle URL (Google redirect links are resolved as for web results).
snippetSummary shown under the headline, when there is one.
datePublish time as displayed, e.g. "2 hours ago" (ISO 8601 when the RSS fallback was used).
publishedAtPublish time in ISO 8601 UTC, when it can be determined.
sourcePublisher name.
imageUrlThumbnail as an inline data: URI, only with includeThumbnails: true (about 20 KB each).
domainHost name of the article, without www.
faviconPublisher icon.
origingoogle_search for the News tab; google_news_rss when the News tab was blocked and the Google News RSS feed was used instead (its ranking differs).

Every response

FieldMeaning
searchParametersYour request after validation, with defaults filled in (q, gl, hl, type, page or pages...).
requestIdID of this request. Poll GET /requests/{requestId} for async requests and for final links.
creditsCredits charged for this request (refunded automatically if it fails).
cachedtrue when the answer came from the recent-result cache (1 hour, 5 minutes for news).
linksPendingtrue while Google redirect links are being replaced by final URLs; poll the request to get them.
unresolvedLinksLinks that are still Google redirects: they work, but are not the final URL.
durationMsTime the search took, in milliseconds.
ipCountryCountry of the IP the search ran from (same code as gl). Another country than gl when no IP there was free: the search runs anyway instead of waiting. Missing when unknown.

Sample response

200 OK
{
  "searchParameters": {
    "q": "electric vehicles",
    "gl": "us",
    "hl": "en",
    "type": "news",
    "num": 10,
    "page": 1,
    "engine": "google"
  },
  "news": [
    {
      "position": 1,
      "title": "Electric vehicle sales hit a record in October",
      "link": "https://www.autonewsdaily.com/ev-sales-record",
      "snippet": "Global EV sales rose 31% year over year as cheaper models reached showrooms.",
      "date": "2 hours ago",
      "publishedAt": "2026-11-14T06:10:00+00:00",
      "source": "Auto News Daily",
      "domain": "autonewsdaily.com",
      "favicon": "https://www.google.com/s2/favicons?domain=autonewsdaily.com&sz=64",
      "origin": "google_search"
    },
    {
      "position": 2,
      "title": "New solid-state battery promises a 600-mile range",
      "link": "https://www.techcurrent.com/solid-state-range",
      "snippet": "The startup says its cells charge from 10% to 80% in 12 minutes.",
      "date": "5 hours ago",
      "publishedAt": "2026-11-14T03:00:00+00:00",
      "source": "Tech Current",
      "domain": "techcurrent.com",
      "favicon": "https://www.google.com/s2/favicons?domain=techcurrent.com&sz=64",
      "origin": "google_search"
    },
    {
      "position": 3,
      "title": "Cities expand fast-charging networks ahead of winter",
      "link": "https://www.citywire.news/fast-charging",
      "snippet": "More than 2,000 new chargers will open by January, officials said.",
      "date": "1 day ago",
      "publishedAt": "2026-11-13T09:30:00+00:00",
      "source": "CityWire",
      "domain": "citywire.news",
      "favicon": "https://www.google.com/s2/favicons?domain=citywire.news&sz=64",
      "origin": "google_search"
    }
  ],
  "requestId": "5b0c8a52-3f0e-4d55-9a2a-0f3a8e2d1c11",
  "credits": 1,
  "cached": false,
  "linksPending": false,
  "unresolvedLinks": 0,
  "durationMs": 1620
}

Limits

  • When Google blocks the News tab, results come from the Google News RSS feed instead. Those items carry origin: google_news_rss and their ranking differs from the News tab.
  • Cached news results are kept for 5 minutes (1 hour for other types); send noCache: true for a fresh page.
  • Article thumbnails are returned only with includeThumbnails: true.
  • Targeting is by country (gl) and interface language (hl). City-level location is not supported yet: a request with location is refused with an explicit error.
  • Results are what a desktop browser sees. There is no mobile SERP option yet.
  • 60 searches per minute per account by default; ask on Telegram for more.

Errors and their credit rules are on the errors page.