> For the complete documentation index, see [llms.txt](https://doc.thordata.com/doc/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://doc.thordata.com/doc/zh-hk/web-scraper-api/ji-cheng/amazon-s3-ji-cheng.md).

# Amazon S3 集成

Amazon S3 集成功能說明\
通過 Amazon S3 集成功能，您可以將 Web Scraper 抓取任務的結果自動上傳到指定的 S3 桶中，方便數據備份、共享或後續處理和分析。

**集成配置：**

1. **集成功能名稱**\
   自定義一個名稱用於此集成任務，以便後續管理和識別。鑒於根據目的或抓取對象命名，例如“將產品評論結果上傳到 S3”。
2. **事件類型設定**\
   您可以根據需求選擇以下兩種方式之一來觸發數據傳送：

  <mark style="background-color:blue;">指定任務 ID</mark>\
  適用於將已知的特定擷取任務結果傳送到 S3。\
  適合處理一個擷取工具的多個任務 ID 結果。\
  多個任務 ID 請使用英文逗號分隔。\
  最多支援 10 個任務 ID。

  <mark style="background-color:blue;">跟隨任務</mark>\
  自動將該擷取工具後續產生的所有結果上傳至 S3。\
  一次設定，持續生效，除非手動關閉或刪除該整合任務。\
  更適合持續性擷取或週期性任務的自動化資料歸檔。

3. **Amazon S3 參數設定**\
   設定以下信息來完成資料上傳設定：

<details>

<summary><code>bucketName</code>，<strong>目標儲存桶名稱（必填）</strong></summary>

目標 Amazon S3 儲存桶的名稱。

</details>

<details>

<summary><code>targetPath</code>，<strong>目標路徑（可選）</strong></summary>

Amazon S3 的目標位置。

</details>

<details>

<summary><code>fileName</code>，<strong>檔案名稱（可選）</strong></summary>

對象在儲存桶中的名稱，預設為您的任務 ID。

</details>

{% tabs %}
{% tab title="訪問金鑰憑證" %}
`awsAccessKey`，**AWS 訪問金鑰（必填）**\
用於授權上傳的 AWS 訪問金鑰 ID。您可以從 AWS 控制台 -> IAM -> 使用者 -> 建立使用者/選擇現有使用者 -> 安全憑證 -> 訪問金鑰 取得。其作用類似使用者名稱。

`awsSecretKey`，**AWS 密鑰（必填）**\
您的 AWS 秘密訪問密鑰用於授權上傳。您可以從 AWS 控制台 -> IAM -> 使用者 -> 建立使用者/選擇現有使用者 -> 安全憑證 -> 訪問金鑰 -> 建立訪問金鑰取得該密鑰。建立訪問金鑰後，該秘密訪問密鑰僅顯示一次。其作用類似密碼。
{% endtab %}

{% tab title="角色令牌憑證" %}
`roleArn`，**角色（必填）**\
RoleArn 是 AWS 中用於角色（Role）授權和切換身份的重要參數。

`externalId`，`外部 ID（必填）`\
ExternalId 是 AWS 中用於提升跨帳戶訪問安全性的一個參數，主要用於第三方服務訪問您帳戶中資源的場景。它與 RoleArn 一起使用。
{% endtab %}
{% endtabs %}

<details>

<summary><code>fileFormat</code>，<strong>檔案格式（必填）</strong></summary>

Amazon 產品的結果可以選擇 JSON 格式或者 CSV 格式傳送。YouTube 產品的結果只能使用檔案格式進行傳送。\
參數值：`JSON` `CSV` `下載鏈接`

</details>

**查看傳輸的檔案：**\
如果您的的集成任務狀態顯示為「成功」，您就可以前往您的 Amazon S3 帳戶中查看。\
或者您可以直接透過鏈接訪問：\
<https://s3.us-east-2.amazonaws.com/downloaddirectory/您填寫的目標路徑/檔案名稱>

例如：您目標路徑填寫的 path/to，文件名稱填寫的 123，傳輸的文件格式是 json。\
您的訪問鏈接就是：\
<https://s3.us-east-2.amazonaws.com/downloaddirectory/path/to/123.json>

如果您需要更多協助，請透過電子郵件 <support@thordata.com> 聯繫我們。


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.thordata.com/doc/zh-hk/web-scraper-api/ji-cheng/amazon-s3-ji-cheng.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
