TinyFish:AI Agent 的 Web 基础设施,Search + Fetch 免费,一行装进 Claude Code

TinyFish: Web Infrastructure for AI Agents — Search + Fetch Free, One-Line Skill for Claude Code

Tech-Experiment #TinyFish#AI agent#web scraping#MCP#Claude Code#skill#REST API#agent tools#web search
更新于
🇨🇳 中文

Agent 需要上网,但上网很难

给 AI Agent 提供实时 Web 数据是一个比看起来更难的问题:大多数网页是动态渲染的,有反爬机制,返回的 HTML 里 90% 是导航栏、脚本和广告——直接喂给模型,token 暴涨,信息密度极低。

TinyFish 解决这个问题:它是一套专门为 AI Agent 设计的 Web 基础设施,把「搜索」「抓取」「多步骤自动化」「托管浏览器」打包成四个简洁的端点,背后是真实浏览器渲染 + 内置反检测 + 干净的结构化输出。

客户包括 Google Hotels、DoorDash、ClassPass、Amazon。

好消息:Search 和 Fetch 现在永久免费。


四个端点,四个场景

端点做什么最适合速度价格
Search实时结构化网页搜索,返回 JSON任何需要检索的场景;Drop-in 替代 RAG 检索层< 0.5s免费
Fetch任意 URL → 干净 Markdown/JSON/HTML读取特定页面,给模型喂干净内容几秒免费
AgentURL + 自然语言目标 → 结构化 JSON多步骤流程、复杂任务、结构化数据提取10s-数分钟按量计费
Browser托管云浏览器,接入你的 Playwright/Selenium深度定制 Agent 和脚本实时按量计费

选择逻辑(来自官方文档):

  • 需要搜索结果列表 → Search
  • 已有 URL,要读取页面内容 → Fetch
  • 需要 Agent 在网站上完成一个工作流 → Agent
  • 需要直接控制浏览器跑自定义脚本 → Browser

安装方式一:Agent Skill(Claude Code / Codex / Cursor)

一行命令,把 TinyFish 能力装进任何支持 Skill 的 AI 编码工具:

npx skills add github.com/tinyfish-io/tinyfish-cookbook --skill use-tinyfish

安装后,Agent 会:

  • 自动知道什么时候该用 Search vs Fetch vs Agent
  • 无需用户说「用 TinyFish」——只要请求涉及实时 Web 信息,Skill 就会触发
  • 通过 CLI 调用,结果写到文件系统而不是消耗模型 context window

Skill 的触发词(不需要显式说):

  • 搜索/发现类:search, find, look up, research, compare, latest, current, news, pricing, docs
  • URL/页面类:fetch, read, summarize, extract from this page, inspect this URL
  • 来源支撑类:answer using web sources, verify a fact, check if something changed
  • 网站操作类:interact with a site, click through, fill forms, collect structured data

在 skills.sh/tinyfish-io/tinyfish-cookbook/use-tinyfish 可以预览完整 Skill 内容。


安装方式二:MCP Server

在 Claude Code、Cursor、Codex、ChatGPT Desktop 或任何 MCP-aware 客户端里添加配置:

{
  "mcpServers": {
    "tinyfish": { "url": "https://mcp.tinyfish.ai" }
  }
}

配置后,Claude 可以直接通过 MCP 工具调用 Search 和 Fetch,无需任何额外代码。


安装方式三:CLI

npm install -g @tiny-fish/cli
tinyfish auth login

# 搜索
tinyfish search query "latest Claude model benchmarks"

# 抓取页面
tinyfish fetch content get https://anthropic.com/news

# 搜索学术论文
tinyfish search query "4D Gaussian Splatting 2026" --domain research_paper

CLI 把结果写到文件系统而不是 stdout,token 使用效率更高。


安装方式四:REST API

先拿 API Key:agent.tinyfish.ai(Search + Fetch 永久免费,无需信用卡)

# Search
curl "https://api.search.tinyfish.ai?query=AI+agent+tools+2026" \
  -H "X-API-Key: $TINYFISH_API_KEY"

# Fetch — 单 URL
curl -X POST https://api.fetch.tinyfish.ai \
  -H "X-API-Key: $TINYFISH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"urls": ["https://github.com/trending"]}'

# Agent — 多步骤任务(SSE 流式)
curl -N -X POST https://agent.tinyfish.ai/v1/automation/run-sse \
  -H "X-API-Key: $TINYFISH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://news.ycombinator.com",
    "goal": "Find the top 5 AI-related stories today. Return JSON with title, URL, and points."
  }'

安装方式五:SDK

# Python
pip install tinyfish

# TypeScript
npm install @tiny-fish/sdk
from tinyfish import TinyFish

client = TinyFish(api_key="YOUR_API_KEY")

# Search
results = client.search("best AI coding tools 2026")
for r in results:
    print(r.title, r.url)

# Fetch
pages = client.fetch(["https://anthropic.com/news"])
print(pages[0].markdown)

两个 SDK 完整覆盖 Search、Fetch、Browser、Agent 和 Vault(Agent 级别的认证凭证和会话内存)。


Search API 的高级参数

Search 不只是简单检索,有几个实用的进阶参数:

# 地理定向(中文结果,针对中国市场)
curl "https://api.search.tinyfish.ai?query=AI工具&location=CN&language=zh-CN" \
  -H "X-API-Key: $TINYFISH_API_KEY"

# 新鲜度过滤(最近 24 小时)
curl "https://api.search.tinyfish.ai?query=claude+model+update&recency_minutes=1440" \
  -H "X-API-Key: $TINYFISH_API_KEY"

# 学术论文搜索
curl "https://api.search.tinyfish.ai?query=4DGS+reconstruction&domain_type=research_paper&pub_year_min=2025" \
  -H "X-API-Key: $TINYFISH_API_KEY"

# 新闻搜索
curl "https://api.search.tinyfish.ai?query=Anthropic+Claude&domain_type=news&after_date=2026-08-01" \
  -H "X-API-Key: $TINYFISH_API_KEY"

# 附加搜索意图(帮助系统更准确理解需求)
curl "https://api.search.tinyfish.ai?query=tinyfish+SDK&purpose=Find+installation+guide+for+Python" \
  -H "X-API-Key: $TINYFISH_API_KEY"

实用场景

竞品价格监控:Fetch 定期抓取竞品定价页 → 结构化 JSON → 送进数据库

研究 Pipeline:Search 检索 ArXiv 论文 → Fetch 获取摘要全文 → 模型总结

GitHub 趋势追踪:每天跑 Fetch 抓 GitHub Trending → 对比昨日结果,提取新上榜项目

多步骤表单填写:Agent 端点处理需要登录和点击的工作流,直接返回结果 JSON

Cookbook 里的现成 demo:

  • lego-hunter — 跨 15+ 零售商追踪稀有乐高库存
  • silicon-signal — 半导体供应链 + 交货期信号
  • research-sentry — 语音优先的学术研究助手,扫描 ArXiv 和 PubMed
  • tinyskills — 从文档、GitHub 和博客生成 SKILL.md(正是 TinyFish 的自指 demo)

总结

TinyFish 做了一件对 AI Agent 开发者很实际的事:把访问 Web 从「需要自己搭」变成「API 调用」,内置真实浏览器渲染、反检测、token 效率优化。Search 和 Fetch 永久免费,意味着大多数使用场景(检索 + 读页面)零成本。

对于 Claude Code 用户,一行 npx skills add 就能让 Agent 在需要时自动拿到实时 Web 数据,不需要手动触发,不需要写额外代码。

官网: tinyfish.io
文档: docs.tinyfish.ai
Cookbook: github.com/tinyfish-io/tinyfish-cookbook
Skill: skills.sh/tinyfish-io/tinyfish-cookbook/use-tinyfish
Discord: discord.gg/tinyfish

🇬🇧 English

AI Agents Need the Web — But the Web Is Hard

Giving AI agents real-time web data is harder than it looks: most pages are dynamically rendered, have anti-bot measures, and return HTML where 90% is nav bars, scripts, and ads — feed that directly to a model and tokens spike while information density collapses.

TinyFish solves this: web infrastructure purpose-built for AI agents, packaging “search,” “fetch,” “multi-step automation,” and “managed browser” into four clean endpoints, backed by real browser rendering, built-in stealth, and structured clean output.

Customers include Google Hotels, DoorDash, ClassPass, and Amazon.

Key news: Search and Fetch are now permanently free.


Four Endpoints, Four Scenarios

EndpointDoesBest forSpeedPrice
SearchReal-time structured web search → JSONAny retrieval task; drop-in for RAG retrieval< 0.5sFree
FetchAny URL → clean Markdown/JSON/HTMLReading specific pages, token-efficient LLM inputSecondsFree
AgentURL + natural language goal → structured JSONMulti-step flows, complex tasks, data extraction10s–minutesMetered
BrowserManaged cloud browser for your Playwright/SeleniumDeep-custom agents and scriptsReal-timeMetered

Decision logic:

  • Need a list of search results → Search
  • Have the URL, want to read the page → Fetch
  • Need an agent to complete a workflow on a site → Agent
  • Need direct browser control for custom scripts → Browser

Install Option 1: Agent Skill (Claude Code / Codex / Cursor)

One command, TinyFish capabilities installed into any Skill-aware AI coding tool:

npx skills add github.com/tinyfish-io/tinyfish-cookbook --skill use-tinyfish

After install, the agent will:

  • Know when to use Search vs Fetch vs Agent automatically
  • Trigger without the user saying “use TinyFish” — any request involving live web info activates it
  • Write results to the filesystem instead of consuming model context window tokens

Skill auto-triggers on: search/find/research/compare/latest/news/pricing, fetch/read/summarize/extract from URL, answer using web sources, interact with a site.

Browse the full Skill at skills.sh/tinyfish-io/tinyfish-cookbook/use-tinyfish.


Install Option 2: MCP Server

Add to Claude Code, Cursor, Codex, ChatGPT Desktop, or any MCP-aware client:

{
  "mcpServers": {
    "tinyfish": { "url": "https://mcp.tinyfish.ai" }
  }
}

Claude can then call Search and Fetch directly as MCP tools, no extra code needed.


Install Option 3: CLI

npm install -g @tiny-fish/cli
tinyfish auth login

tinyfish search query "latest Claude benchmarks"
tinyfish fetch content get https://anthropic.com/news
tinyfish search query "4D Gaussian Splatting" --domain research_paper

CLI writes results to the filesystem rather than stdout — better for token efficiency.


Install Option 4: REST API

Get a free API key at agent.tinyfish.ai (no credit card for Search + Fetch):

# Search
curl "https://api.search.tinyfish.ai?query=AI+agent+tools+2026" \
  -H "X-API-Key: $TINYFISH_API_KEY"

# Fetch
curl -X POST https://api.fetch.tinyfish.ai \
  -H "X-API-Key: $TINYFISH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"urls": ["https://github.com/trending"]}'

# Agent (streaming SSE)
curl -N -X POST https://agent.tinyfish.ai/v1/automation/run-sse \
  -H "X-API-Key: $TINYFISH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://news.ycombinator.com",
    "goal": "Find top 5 AI stories today. Return JSON with title, URL, points."
  }'

Install Option 5: SDK

from tinyfish import TinyFish

client = TinyFish(api_key="YOUR_API_KEY")

results = client.search("best AI coding tools 2026")
for r in results:
    print(r.title, r.url)

pages = client.fetch(["https://anthropic.com/news"])
print(pages[0].markdown)

Both Python and TypeScript SDKs cover all four endpoints plus Vault (agent-grade credential storage and encrypted session reuse).


Advanced Search Parameters

# Geo-targeted (Chinese results for China market)
?query=AI工具&location=CN&language=zh-CN

# Freshness filter (last 24 hours)
?query=claude+update&recency_minutes=1440

# Academic papers
?query=4DGS+reconstruction&domain_type=research_paper&pub_year_min=2025

# News with date range
?query=Anthropic+Claude&domain_type=news&after_date=2026-08-01

# Search intent (helps system understand the goal behind the query)
?query=tinyfish+SDK&purpose=Find+Python+installation+guide

Cookbook Demos Worth Running

  • tinyskills — generates a SKILL.md from docs, GitHub, and blogs — TinyFish’s self-referential demo
  • silicon-signal — semiconductor supply chain + lead-time signals
  • research-sentry — voice-first academic research assistant scanning ArXiv and PubMed
  • competitor-analysis — live competitive pricing intelligence dashboard

Summary

TinyFish does one practically useful thing for AI agent developers: turns accessing the web from “build it yourself” into an API call, with real browser rendering, stealth, and token efficiency built in. Search and Fetch are permanently free, which covers the majority of use cases (retrieval + page reading) at zero cost.

For Claude Code users, one npx skills add line gives the agent automatic access to live web data whenever it needs it — no explicit trigger required, no extra code.

Website: tinyfish.io
Docs: docs.tinyfish.ai
Cookbook: github.com/tinyfish-io/tinyfish-cookbook
Skill: skills.sh/tinyfish-io/tinyfish-cookbook/use-tinyfish
Discord: discord.gg/tinyfish

💬 评论与讨论

使用 GitHub 账号登录后发表评论

关于本站 · 免责声明

🍄 Mushroom Research Blog 是非营利、免费公开的个人科技观察博客与公众号 XStack18,不接受商业合作、不代表任何企业或机构立场,也不谋求商业利益。我们以个人视角客观中立地记录和分析 AI、Web3 等领域的最新模型发布与技术动态——不止转述新闻标题或二手信息,而是给出有独立思考的深入分析,希望帮更多人获得有价值的一手科技认知。

⚠️ 文中介绍的开源代码与模型,仅供学习交流与技术借鉴。它们大多仍处于早期阶段,有待进一步研究和验证,请勿直接用于工作或生产环境;如需采用,请先自行充分测试,并核实其许可证与安全性。
Open-source code and models featured here are shared for learning and reference only. Most are early-stage and still need further study and verification — please don't use them directly in your work or in production. Test them thoroughly and check their licenses and security first.

  1. 本站文章均为作者基于公开信息的个人研究与观点整理,不代表文中提及的任何公司、产品、模型的官方立场,未与其构成商业关联或合作关系。
  2. 科技行业信息更新极快,我们尽力保证内容准确、及时,但不对完整性、实时性做绝对保证,具体请以相关企业/项目官方公告为准。
  3. 文中引用的第三方商标、产品名称、图片、数据等版权归原权利人所有,我们会尽量注明来源;如你认为存在版权疑问或侵权,请通过下方邮箱联系我们,收到通知后会尽快核实处理(更正、加注来源或删除)。
  4. 文章内容仅为技术科普与个人观点,不构成投资、法律或其他专业建议,据此进行任何决策的后果需自行判断和承担。

📮 侵权 / 勘误 / 合作咨询:hello@mushroom.cv