替你操作网页的 AI 智能体
发送任务和网址。真实的 Chrome 浏览器会点击、输入、填写表单、登录并返回答案,以及符合你结构的 JSON。
一个请求,返回 JSON
curl https://lovelyrouter.com/v1/browser/runs \
-H "Authorization: Bearer $LOVELY_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"goal": "Get the top 3 stories on the front page",
"start_url": "https://news.ycombinator.com/",
"output_schema": { "stories": [{ "title": "string", "url": "string", "points": "integer" }] }
}'{
"id": "brun_8f3c…",
"status": "succeeded",
"steps": 1,
"answer": "The top 3 stories are …",
"data": {
"stories": [
{ "title": "Bitwarden Dual License Model", "url": "https://community.bitwarden.com/…", "points": 95 },
{ "title": "Talorys – A self-hosted personal AI agent…", "url": "https://github.com/rociiu/talorys", "points": 57 },
{ "title": "REA Reverse – Engineer Anything", "url": "https://rea.tools/", "points": 498 }
]
},
"charge_usd": 0.006
}交给你的 AI 智能体
把这段提示词复制到 Claude Code、Cursor、Codex 或任何编程智能体中。它会告诉智能体文档在哪里,以及如何使用你的 API 密钥。
Use the Lovely Router browser agent API: a real browser that clicks, types, fills forms and logs in for a task, and returns an answer plus JSON in a schema I choose.
- Docs (read first): https://lovelyrouter.com/docs/browser-agent.md and https://lovelyrouter.com/docs/api/browser.md
- Start a run: POST https://lovelyrouter.com/v1/browser/runs with `{"goal": "...", "start_url": "https://...", "output_schema": {...}}`. Put every value the task needs in the goal. It returns 202 at once; poll the `poll` path (or stream `events`) until the run ends, then read `answer` and `data`.
- Billed per step (fast mode by default). Set `max_steps` to cap a run. For unattended runs send `"human": false`; by default the agent pauses before purchases, sending or deleting (`approve`).
- If you support MCP, you can instead connect the server https://lovelyrouter.com/mcp (Streamable HTTP, same key; https://lovelyrouter.com/docs/tools/mcp.md) and use suggest_tools, get_tool and run_tool.
- Auth: read my API key from the LOVELY_API_KEY environment variable and send it as `Authorization: Bearer $LOVELY_API_KEY`. Never print or commit the key. If it is not set, ask me to create one at https://lovelyrouter.com/app/keys.
- Billing is prepaid: every call is charged to my balance, so test with a small request before running anything large.
- Every docs page is plain Markdown; the full index is https://lovelyrouter.com/llms.txt.
My task: <describe the site and what the agent should do or extract>为真实网站而生
在智能体工作时,实时获取每个操作、每个完成的步骤和浏览器屏幕画面,可在控制台中查看,也可通过 API 获取。
传入输出结构,即可在 data 中得到经过校验的 JSON,数据只取自智能体访问过的页面——包括真实的链接网址。
只写的保险库密钥,只会在你允许的网站上输入。TOTP 种子会转换为 6 位验证码;保存会话后,之后的运行可直接以登录状态开始。模型永远看不到密钥值。
智能体可以向你提问、在购买前等待你批准,或在遇到验证码时把实时画面交给你处理。
只需上传一次文件;智能体会为每个上传字段选出正确的文件(是简历,而不是报税单)。
点击提交前,智能体会逐项核对字段与任务,并修正错误或预填的值。
我们测试过的最快的浏览器智能体 API
快 5 倍,成本只是零头。 2026-10-10 用相同的六个公开任务、默认设置测试,计时从发起请求到拿到结果。对比对象是 Apify Store 上使用最多的按步计费浏览器智能体。
| 任务 | Lovely Router | 主流浏览器智能体 | 快多少 |
|---|---|---|---|
| Hacker News 头条 | 3.7s · $0.006 | 22.5s · $0.038 | 6.1× |
| 两次点击后的商品页 | 7.3s · $0.018 | 63.7s · $0.095 | 8.7× |
| 查询图书价格 | 8.9s · $0.009 | 38.2s · $0.038 | 4.3× |
| 维基百科搜索并阅读 | 9.9s · $0.018 | 79.5s · $0.114 | 8.0× |
| 登录后读取页面 | 12.1s · $0.033 | 52.7s · $0.105 | 4.4× |
| 三步保险报价表单(17 个字段) | 21.3s · $0.126 | 199.6s · $0.988 | 9.4× |
价格
精准模式在拿不准时还会查看截图,并能运行只读代码读取数据。
- ✓ 无运行费、无订阅
- ✓ 已包含 AI 模型——无需 LLM 密钥
- ✓ 包含结构化 JSON 输出
- ✓ 只为实际执行的步数付费
- 每步含 1 分钟;超出部分(例如等待你批准)按每分钟 $0.005 计费
- 可选用我们的任意模型:token 按正常价格 × 1.2 计费
| 示例任务 | 步骤 | 快速 | 精准 |
|---|---|---|---|
| 从页面读取一个值 | 1–3 | $0.006–$0.018 | $0.012–$0.036 |
| 搜索网站并读取结果 | 2–6 | $0.012–$0.036 | $0.024–$0.072 |
| 登录并读取账户数据 | 4–8 | $0.024–$0.048 | $0.048–$0.096 |
| 填写并提交多步骤长表单 | 15–25 | $0.090–$0.150 | $0.180–$0.300 |
API 参考
与 Lovely Router 其他服务共用 API 密钥和余额。基础 URL https://lovelyrouter.com
运行参数
运行以 succeeded、failed、timed_out 或 stopped 结束,期间可能暂停为 waiting_for_human。结果包含 answer(文本)、data(JSON 或 null)、steps 和 charge_usd。
常见问题
在控制台运行,查看每一步,然后复制 API 调用。