v2 新增功能
同时搜索多个来源
响应格式已变更
新功能
- 按时间范围筛选(“past week”、“past month”)
- 目标定位至特定国家/地区
- 分类筛选:在 GitHub 仓库或研究类网站内搜索
- Alpha 阶段结果上限为 500
scrapeOptions
,并设置 formats: [{"type": "markdown"}]
,即可为每个搜索结果获取完整的 Markdown 内容;否则将默认仅返回 SERP 结果(url、title、description)。你也可以使用其他 formats,例如 {"type": "summary"}
来获取精简内容。
支持的查询运算符
运算符 | 功能 | 示例 |
---|---|---|
"" | 精确(非模糊)匹配一段文本 | "Firecrawl" |
- | 排除特定关键词或对其他运算符取反 | -bad , -site:firecrawl.dev |
site: | 仅返回来自指定网站的结果 | site:firecrawl.dev |
inurl: | 仅返回在 URL 中包含某个词的结果 | inurl:firecrawl |
allinurl: | 仅返回在 URL 中包含多个词的结果 | allinurl:git firecrawl |
intitle: | 仅返回在页面标题中包含某个词的结果 | intitle:Firecrawl |
allintitle: | 仅返回在页面标题中包含多个词的结果 | allintitle:firecrawl playground |
related: | 仅返回与特定域相关的结果 | related:firecrawl.dev |
imagesize: | 仅返回尺寸完全匹配的图片 | imagesize:1920x1080 |
larger: | 仅返回大于指定尺寸的图片 | larger:1920x1080 |
location 参数
location
参数获取按地理位置定向的搜索结果。格式:“string”。示例:“Germany”、“San Francisco,California,United States”。
查看支持的位置完整列表,了解所有可用的国家和语言。
categories 参数
categories
参数按特定类别筛选搜索结果:
github
:在 GitHub 的仓库、代码、议题和文档中搜索research
:搜索学术与科研类网站(arXiv、Nature、IEEE、PubMed 等)
使用示例
类别响应
category
字段,用于标示其来源:
基于时间的搜索
tbs
参数按时间范围筛选结果,支持自定义日期区间。详见搜索功能文档,其中包含详细示例和支持的 formats。Authorizations
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
Body
application/json
The search query
Maximum number of results to return
Required range:
1 <= x <= 100
Sources to search. Will determine the arrays available in the response.
Categories to filter results by
Time-based search parameter. Supports predefined time ranges (qdr:h
, qdr:d
, qdr:w
, qdr:m
, qdr:y
) and custom date ranges (cdr:1,cd_min:MM/DD/YYYY,cd_max:MM/DD/YYYY
)
Location parameter for search results
Timeout in milliseconds
Excludes URLs from the search results that are invalid for other Firecrawl endpoints. This helps reduce errors if you are piping data from search into other Firecrawl API endpoints.
Options for scraping search results