POST
/search
搜尋並蒸餾

針對提供的查詢執行 Google 網頁搜尋,並使用請求的 formats 對每個結果進行蒸餾。每個結果都會回報自己的 success 旗標。

授權

YOUR_API_KEY
授權Bearer <token>

在 Thunderbit Dashboard 取得 API key。標頭格式:Authorization: Bearer YOUR_API_KEY

位置: header

請求體

application/json

TypeScript Definitions

Use the request body type in TypeScript.

query*string必填

搜尋查詢(最多 500 個字元)。

範例:best web scraping tools 2026
limitinteger預設值:5

回傳的結果數量(1–10,預設 5)。

取值範圍:1 <= x <= 10
範例:
5
sitestring

將搜尋限制在單一網域內。

範例:techcrunch.com
formatsany[]

套用於每個結果頁面的輸出格式(與 Distill 的 formats 陣列結構相同)。

範例:
[
  "markdown",
  {
    "type": "summary"
  }
]
timeoutinteger預設值:30000

每個結果的 Distill 逾時時間(毫秒,預設 30000,最大 60000)。

取值範圍:5000 <= x <= 60000

回應

application/json

Search succeeded. Per-result Distill outcomes are reported individually in `data.results[].success`.

successboolean
範例:
true
dataobject
展開子屬性
querystring

輸入查詢的回顯。

totalinteger

回傳的結果數量。

successfulinteger

Distill 階段成功的結果數量。

credits_usedinteger

本次請求收取的總點數。

resultsobject[]
展開子屬性
urlstring

結果的 URL。

titlestring

搜尋結果標題。

snippetstring

來自 Google 的搜尋結果摘要。

positioninteger

搜尋結果中從 1 開始的排名。

successboolean

單一結果的 Distill 是否成功。

markdownstring

此結果的蒸餾 Markdown(請求時回傳)。

summarystring

結果摘要(請求時回傳)。

answerstring

question 格式對應的答案(請求時回傳)。

highlightsstring[]

重點段落(請求時回傳)。

linksobject[]

從結果頁面擷取的連結(請求時回傳)。

展開子屬性
textstring

Visible link text.

範例:Read more
hrefstring

Resolved absolute URL.

範例:https://example.com/article
imagesobject[]

從結果頁面擷取的圖片(請求時回傳)。

展開子屬性
srcstring

Image source URL.

範例:https://example.com/hero.png
altstring

Image alt text.

範例:Hero banner
widthinteger

Image width in pixels.

heightinteger

Image height in pixels.

errorstring

此結果的 Distill 錯誤訊息(僅在 success=false 時)。