← 返回
未分类 Key 中文

Tinyfish Browser

Spin up a remote browser session via the TinyFish Browser API and get a CDP URL for driving it. Use when you need an automatable Chromium session (Playwright...
通过 TinyFish Browser API 启动远程浏览器会话并获取 CDP URL,以便自动化控制。适用于需要可自动化的Chromium 会话(Playwright)。
bunsdev
未分类 clawhub v1.0.0 1 版本 100000 Key: 需要
★ 0
Stars
📥 392
下载
💾 0
安装
1
版本
#latest

概述

TinyFish Browser

Create a remote Chromium browser session. Returns a session_id, a cdp_url for driving the browser over the DevTools Protocol, and an authenticated base_url for polling session state.

Requires: TINYFISH_API_KEY environment variable.

Pre-flight Check (REQUIRED)

Before calling the API, verify the key is present:

[ -n "$TINYFISH_API_KEY" ] && echo "TINYFISH_API_KEY is set" || echo "TINYFISH_API_KEY is NOT set"

If the key is not set, stop and ask the user to add it. Get one at . Do NOT fall back to other browser tools.

Create a Session

curl -X POST "https://api.browser.tinyfish.ai" \
  -H "X-API-Key: $TINYFISH_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{ "url": "https://example.com" }'

Helper Script

scripts/browser.sh wraps the curl call:

scripts/browser.sh https://example.com

Response Shape

{
  "session_id": "sess_abc123",
  "cdp_url": "wss://browser.tinyfish.ai/devtools/browser/…",
  "base_url": "https://api.browser.tinyfish.ai/sessions/sess_abc123"
}

Using the Session

  • cdp_url is a DevTools Protocol websocket — connect with Playwright/Puppeteer/chrome-remote-interface to drive the page.
  • base_url is an authenticated polling endpoint (requires the X-API-Key header). It is NOT browsable in a normal web view.

Session Lifecycle

Sessions auto-close after ~1 hour of idleness. There is no explicit terminate endpoint — avoid creating one session per user action; reuse sessions keyed by target URL when possible.

版本历史

共 1 个版本

  • v1.0.0 当前
    2026-05-07 05:31 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

Tinyfish Agent Run

bunsdev
对 URL 运行 TinyFish 自动化代理,并以单行 JSON 形式流式返回实时进度事件(STARTED / PROGRESS / COMPLETE)。在你想要…时使用。
★ 0 📥 403

Tinyfish Search

bunsdev
通过 TinyFish Search API 执行网页搜索,获取结构化 JSON 结果(标题、摘要、URL),可直接供 LLM 使用。适用于需要最新网页搜索的场景。
★ 0 📥 452

EPUB ↔ PDF Converter

bunsdev
双向互转 EPUB 与 PDF。EPUB→PDF 保持排版便于分析;PDF→EPUB 压缩重排用于分发和阅读器。
★ 0 📥 335