> For the complete documentation index, see [llms.txt](https://docs.talordata.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.talordata.com/cn-tw/serp-api/query-parameters/google-serp-api/google-finance-serp-api.md).

# Google Finance SERP API 參數指南

透過 Talordata SERP API，您可以配置 Google 財經搜索查詢，包括本地化、進階參數等輸出選項。

<details>

<summary><strong><code>q</code> ，搜尋查詢必填)</strong></summary>

此參數定義了爬取時的搜尋結果，預設值為 pizza。您可以輸入任何想查詢的關鍵字，也可以使用任何語言。

**範例請求：**\
使用參數`q=pizza` 的範例值

```sh
curl -X POST https://serpapi.talordata.net/serp/v1/request \
 -H "Content-Type: application/x-www-form-urlencoded" \
 -H "Authorization: Bearer token" \
 -d "engine=google_finance" \
 -d "q=pizza" \
 -d "json=1"
```

</details>

## 本地化

<details>

<summary><strong><code>hl</code> ，</strong>語言<strong>（非必填）</strong></summary>

该參數定義了爬取時搜尋結果所使用的語言，預設值為 en。為兩位英文字母語言代碼（如：en, ru, es）。

**完整语言代码支持列表**\
请参阅 [Google官方语言代码表](https://developers.google.com/custom-search/docs/xml_results_appendices#interfaceLanguages)

**範例請求：**\
使用參數询`q` ：<mark style="color:blue;">pizza</mark>,`hl`： <mark style="color:blue;">es</mark>的範例值

```sh
curl -X POST https://serpapi.talordata.net/serp/v1/request \
 -H "Content-Type: application/x-www-form-urlencoded" \
 -H "Authorization: Bearer token" \
 -d "engine=google_finance" \
 -d "q=pizza" \
 -d "json=1" \
 -d "hl=es"
```

</details>

## 高級參數

<details>

<summary><strong><code>window</code> ,</strong>時間範圍<strong>(非必填)</strong></summary>

參數用來設定圖形的時間範圍。可設定為：

`1D` - 1 天（預設）

`5D` - 5 天

`1M` - 1 個月

`6M` - 6 個月

`YTD` - 年初至今

`1Y` - 1 年

`5Y` - 5 年

`MAX` - 最大值

**範例請求**

使用參數的範例值： `q=GOOGL:NASDAQ`,`window`:6M

```sh
curl -X POST https://serpapi.talordata.net/serp/v1/request \
 -H "Content-Type: application/x-www-form-urlencoded" \
 -H "Authorization: Bearer token" \
 -d "engine=google_finance" \
 -d "q=GOOGL:NASDAQ" \
 -d "json=1" \
 -d "window=6M "
```

</details>

如果您需要更多幫助，請隨時通過在線客服或 <support@talordata.com>聯繫我們。
