Search
Search the web
Search the web for a query and get back ranked results: title, url and snippet. Costs 1 credit. Set scrapeResults to true to also fetch each result as clean data, which costs 1 additional credit per page scraped.
post/v1/web/search
Request
- Base URL: https://api.hydrafetch.com
- URL: https://api.hydrafetch.com/v1/web/search
- Auth: API key in header X-API-Key
Request body
Example request
{
"query": "best open source vector databases",
"limit": 5,
"scrapeOptions": {
"formats": [
"markdown"
],
"location": {
"country": "us",
"languages": [
"en-US",
"en"
]
}
},
"timeRange": "week",
"country": "us",
"includeDomains": [
"github.com",
"arxiv.org"
],
"excludeDomains": [
"pinterest.com"
]
}Response
The ranked search results.
Example response
{
"data": {
"query": "best open source vector databases",
"status": "ok",
"results": [
{
"title": "Best open source vector databases",
"url": "https://example.com/vector-databases",
"snippet": "A rundown of the leading open source vector databases and how they compare.",
"rank": 1,
"data": {
"url": "https://example.com",
"finalUrl": "https://example.com/",
"status": 200,
"metadata": {
"structure": "markdown",
"pageType": "article",
"wordCount": 214
},
"usage": {
"creditsUsed": 1,
"creditsRemaining": 4999,
"freshness": "fresh"
},
"quality": {
"confidence": 0.94,
"complete": true
},
"structured": {
"entities": [
{
"type": "Product"
}
]
}
}
}
]
}
}Changes
No recorded changes to this operation across all 1 revision of this API.