Results already read
No second round of fetching and parsing for every link.
The search API takes a query and returns ranked results from the live web. Ask for the pages too and each result comes back already read as clean markdown, in the same call. A search costs 1 credit, plus 1 credit for each page read.
**Authors:** Chris House
**Published:** 2021-05-12
# A Complete CSS Grid Layout Guide
Our comprehensive guide to CSS Grid layout, focusing on all the settings both for the grid parent container and the grid child elements with examples and tutorials.
## Introduction
CSS Grid Layout (aka “Grid” or “CSS Grid”), is a two-dimensional grid-based layout system that, compared to any web layout system of the past, completely changes the way we design user interfaces.
{
"query": "css grid layout guide",
"status": "ok",
"results": [
{
"rank": 1,
"title": "A Complete Guide to CSS Grid Layout | CSS-Tricks",
"url": "https://css-tricks.com/complete-guide-css-grid-layout/"
},
{
"rank": 2,
"title": "CSS grid layout - Learn web development | MDN",
"url": "https://developer.mozilla.org/en-US/docs/Learn_web_development/Core/CSS_layout/Grids"
}
]
}**Authors:** Fili
**Published:** 2022-06-18
# HTTP Caching
HTTP caching stores responses so future requests for the same resource are served from a local or intermediate copy instead of the origin server. Caches appear at every layer of the HTTP chain: inside the browser (private cache), at corporate proxies (shared cache), and across CDN edge nodes (reverse cache).
## Cache types
### Private cache
A private cache belongs to a single client, typically the browser.
{
"query": "http caching explained",
"status": "ok",
"results": [
{
"rank": 1,
"title": "HTTP Caching explained",
"url": "https://http.dev/caching"
},
{
"rank": 2,
"title": "HTTP caching - HTTP | MDN - MDN Web Docs",
"url": "https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/Caching"
}
]
}01Options
curl https://api.hydrafetch.com/v1/web/search \
-H "X-API-Key: $HYDRAFETCH_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"query": "http caching explained",
"limit": 3,
"scrapeResults": true
}'{
"data": {
"query": "http caching explained",
"status": "ok",
"results": [
{
"rank": 1,
"title": "HTTP Caching explained",
"url": "https://http.dev/caching",
"snippet": "HTTP caching stores responses…",
"data": { "markdown": "# HTTP Caching…" }
}
]
}
}02Handled
No second round of fetching and parsing for every link.
Keep a search inside the sources you name.
Limit a search to a window of time.
An empty search says so and costs nothing.
03Connect
For agents
One MCP server. Every endpoint is a tool.
Add Hydrafetch from your terminal.
claude mcp add --scope user --transport http hydrafetch https://api.hydrafetch.com/mcpStart Claude Code, run /mcp, choose hydrafetch and then Authenticate. Your browser opens: sign in, pick a workspace and approve.
Open Hydrafetch in Claude's connector directory and choose Connect.
Open in ClaudeSign in to Hydrafetch and approve in the window that opens.
Open Hydrafetch in ChatGPT's apps and choose Connect.
Open in ChatGPTSign in to Hydrafetch and approve.
Add Hydrafetch to ~/.cursor/mcp.json. Create the file if it does not exist.
{
"mcpServers": {
"hydrafetch": { "url": "https://api.hydrafetch.com/mcp" }
}
}Open Cursor Settings, then MCP. Hydrafetch asks you to sign in: choose Connect and approve in your browser.
Add Hydrafetch to .vscode/mcp.json in your workspace.
{
"servers": {
"hydrafetch": { "type": "http", "url": "https://api.hydrafetch.com/mcp" }
}
}Choose Start above the server in that file, then sign in and approve when VS Code asks.
Add Hydrafetch from your terminal.
codex mcp add hydrafetch --url https://api.hydrafetch.com/mcpStart Codex. The first time it uses Hydrafetch, your browser opens to sign in.
Add Hydrafetch from your terminal.
gemini mcp add hydrafetch --url https://api.hydrafetch.com/mcp --scope userStart Gemini CLI. The first time it uses Hydrafetch, your browser opens to sign in.
Open the MCP Servers panel and choose Configure to open the settings file.
Add Hydrafetch to it. Replace hf_your_key with a key from the API keys page.
{
"mcpServers": {
"hydrafetch": {
"type": "streamableHttp",
"url": "https://api.hydrafetch.com/mcp",
"headers": { "Authorization": "Bearer hf_your_key" },
"disabled": false,
"autoApprove": []
}
}
}Add Hydrafetch to your global OpenCode config.
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"hydrafetch": { "type": "remote", "url": "https://api.hydrafetch.com/mcp", "enabled": true }
}
}Start OpenCode. It sees that Hydrafetch needs a sign-in and opens your browser.
For your code
An official client in 6 languages, or plain HTTP.
curl https://api.hydrafetch.com/v1/web/search \
-H "X-API-Key: $HYDRAFETCH_API_KEY" \
-H "Content-Type: application/json" \
-d '{"query": "http caching explained", "scrapeResults": true}'import { Hydrafetch } from "@hydrafetch/node-sdk";
const hf = new Hydrafetch(process.env.HYDRAFETCH_API_KEY);
const { results } = await hf.search("http caching explained", {
scrapeResults: true,
});
for (const result of results) console.log(result.title, result.url);from hydrafetch import Hydrafetch
hf = Hydrafetch()
res = hf.search("http caching explained", scrapeResults=True)
for result in res["results"]:
print(result["title"], result["url"])Working in a coding agent? Hand it this.
04Price
05Questions
Ranked results from the live web, each with a title, a URL and a snippet. Set scrapeResults and every result also carries its page, already read as clean markdown.
1 credit a search. Reading the results adds 1 credit for each page read, and a search that finds nothing costs nothing.
A search that returns only links needs a fetch and a parser for every result, which is several round trips. Here it is one call, and the page text arrives with each result.
Yes. includeDomains and excludeDomains keep or drop sites, timeRange limits results to the last day, week, month or year, and country leans results toward one region.
Yes. Search is a tool on our MCP server, so an agent in Claude, ChatGPT, Cursor or your own harness can search and read the pages in one turn.