Skip to content

Endpoints

Search

Web search results, optionally scraped to full markdown in the same request.

POST/v1/search

ReferenceTry it ▸

Search queries the web and returns ranked results with titles and snippets. Add scrapeOptions and every result is also scraped, so you get full markdown for each hit in one round trip. 5 credits per 10 results (rounded up), plus normal scrape credits for each result scraped successfully. Results that fail to scrape come back without a document and cost nothing extra. Identical queries are cached for about 10 minutes.

Example#

curl -X POST "https://api.vermin.dev/v1/search" \
  -H "Authorization: Bearer $VERMIN_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "query": "open source web scrapers",
    "limit": 5,
    "scrapeOptions": { "formats": ["markdown"] }
  }'

Request#

SearchRequest
  • querystringrequiredmax 500 chars
  • limitintegerdefault 101–50
  • countrystring
  • languagestring
  • timeRange"day" | "week" | "month" | "year"
  • scrapeOptionsScrapeOptions
    If set, each result is scraped (billed as scrapes)

Response#

200 OK
{
  "success": true,
  "results": [
    {
      "position": 1,
      "url": "https://github.com/topics/web-scraping",
      "title": "web-scraping · GitHub Topics",
      "snippet": "Web scraping is the process of extracting data from websites…",
      "source": "GitHub",
      "document": { "url": "https://github.com/topics/web-scraping", "markdown": "# web-scraping\n…", "tier": "fetch" }
    }
  ],
  "credits_used": 9,
  "request_id": "req_01J9V6C8LM"
}

Here 5 results cost 5 credits, plus 5 successful scrapes at 1 each.

SearchResponse
  • successbooleanrequired
  • resultsobject[]required
    Show 7 fields
    • urlstringrequired
    • titlestringrequired
    • snippetstring
    • positioninteger
    • datestring
      Publication date as reported by the search provider (ISO 8601 when available, otherwise its text such as 3 days ago)
    • sourcestring
      Site or publisher name when the provider reports one
    • documentDocument
  • credits_usedintegerrequired
  • request_idstring