Providers

SerpBase

SerpBase's Google SERP endpoints, with a category that picks the web, images, news or videos endpoint.
IDserpbase11 / 13api.serpbase.dev
Provider

SerpBase

  • create("serpbase")
  • SERPBASE_API_KEY
Auth
X-API-Key header
Results
10, up to 20 · paged
Free tier
100 searches to start

Capabilities

  • Searchsearch()
  • Imagenot supported
  • Readnot supported

Options

Filterscategory
FieldspublishedDate, image, favicon, metadata
Categoryimages, image, news, videos, video

Address it

ts
import { create } from "@agntn/web";

const serpbase = await create("serpbase"); // SERPBASE_API_KEY
const results = await serpbase.search("query", { category: "news", maxResults: 10 });

The key goes in the X-API-Key header against api.serpbase.dev.

What it reads

CallEndpoint
searchPOST to the endpoint the category picks: web by default, images/image, news, videos/video

What comes back

publishedDate, image, favicon and metadata.{position, rank, searchType, requestId, elapsedMs, creditsCharged}. Only category is honoured. Paging works, but the next token stays unknown until a page comes back empty, SerpBase does not say when it is done.

Gotchas

  • maxResults is applied on our side to the returned page, the endpoint decides the page size.
  • Credits are charged per request and reported in metadata.creditsCharged. An empty balance answers HTTP 200 with status: 1020. That is PaymentError here, so automatic search tries the next configured provider instead of stopping.

Where it lives

src/providers/serpbase.ts.