POST
/
search
Search and optionally scrape search results
curl --request POST \
  --url https://api.firecrawl.dev/v1/search \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "query": "<string>",
  "limit": 5,
  "tbs": "<string>",
  "location": "<string>",
  "timeout": 60000,
  "ignoreInvalidURLs": false,
  "scrapeOptions": {
    "onlyMainContent": true,
    "includeTags": [
      "<string>"
    ],
    "excludeTags": [
      "<string>"
    ],
    "maxAge": 0,
    "headers": {},
    "waitFor": 0,
    "mobile": false,
    "skipTlsVerification": false,
    "timeout": 30000,
    "parsePDF": true,
    "jsonOptions": {
      "schema": {},
      "systemPrompt": "<string>",
      "prompt": "<string>"
    },
    "actions": [
      {
        "type": "wait",
        "milliseconds": 2,
        "selector": "#my-element"
      }
    ],
    "location": {
      "country": "US",
      "languages": [
        "en-US"
      ]
    },
    "removeBase64Images": true,
    "blockAds": true,
    "proxy": "basic",
    "storeInCache": true,
    "formats": []
  }
}'
{
  "success": true,
  "data": [
    {
      "title": "<string>",
      "description": "<string>",
      "url": "<string>",
      "markdown": "<string>",
      "html": "<string>",
      "rawHtml": "<string>",
      "links": [
        "<string>"
      ],
      "screenshot": "<string>",
      "metadata": {
        "title": "<string>",
        "description": "<string>",
        "sourceURL": "<string>",
        "statusCode": 123,
        "error": "<string>"
      }
    }
  ],
  "warning": "<string>"
}
注意: 機能とパフォーマンスが向上したnew v2 version of this APIが利用可能です。
search エンドポイントは、ウェブ検索(SERP)と Firecrawl のスクレイピング機能を組み合わせ、任意のクエリに対してページ全体のコンテンツを返します。 各検索結果の完全な Markdown コンテンツを取得するには、scrapeOptionsformats: ["markdown"] を指定してください。指定しない場合は、既定で SERP の結果(url、title、description)のみが返されます。

サポートされているクエリ演算子

検索をより適切に絞り込める、さまざまなクエリ演算子をサポートしています。
OperatorFunctionalityExamples
""文字列を厳密一致させる"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

Location パラメータ

location パラメータを使うと、地域に最適化された検索結果を取得できます。形式: "string"。例: "Germany""San Francisco,California,United States" 利用可能なすべての国と言語は、サポート対象ロケーションの一覧をご覧ください。 tbs パラメータを使うと、カスタムの日付範囲を含む期間で結果を絞り込めます。具体例や対応フォーマットは、検索機能のドキュメントを参照してください。

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
query
string
required

The search query

limit
integer
default:5

Maximum number of results to return

Required range: 1 <= x <= 100
tbs
string

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
string

Location parameter for search results

timeout
integer
default:60000

Timeout in milliseconds

ignoreInvalidURLs
boolean
default:false

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.

scrapeOptions
object

Options for scraping search results

Response

Successful response

success
boolean
data
object[]
warning
string | null

Warning message if any issues occurred