> For the complete documentation index, see [llms.txt](https://developers.oxylabs.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developers.oxylabs.io/integrations/cn/proxy-integrations/octoparse.md).

# Octoparse

将 Octoparse 与 Oxylabs 代理集成，用于无代码网页爬取。设置自动 IP 轮换并处理常见爬取挑战。

[**Octoparse**](https://www.octoparse.com/) 是一款数据提取工具。它允许你无需编写代码即可抓取公开数据，并通过自动 IP 轮换和延长会话时间来应对大多数抓取挑战。

按照以下步骤将 Octoparse 与以下 Oxylabs 代理集成：

* [**住宅与移动代理**](#residential-and-mobile-proxies)
* [**数据中心代理**](#datacenter-proxies)
* [**独享数据中心代理（企业版）**](#dedicated-datacenter-proxies-enterprise)
* [**独享数据中心代理（自助服务版）**](#dedicated-datacenter-proxies-self-service)
* [**ISP代理**](#isp-proxies)
* [**独享ISP代理**](#dedicated-isp-proxies)

### **步骤 1**

[**下载**](https://www.octoparse.com/download/mac)、安装，然后打开 Octoparse。

### **步骤 2**

通过点击 **+New** 按钮（位于左上角），然后选择 **自定义任务。**

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-bda3d68a84769536228e8e0ef0b4d699345190e4%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

### **步骤 3**

在 **URL 输入框** 中输入你要提取数据的网页 URL，然后点击 **保存** 按钮。我们将以 [**Oxylabs 抓取沙盒**](https://sandbox.oxylabs.io/products/category/pc) 为例。

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-94a23b5471c974ec0f619093cf613656c700a768%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

### **步骤 4**

加载所选 URL 后，转到 **"任务设置"** 并选择 **"防封锁"**.

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-d6059fc248a4cc709adcfa800165d8af8102e1bc%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-4f2bdcc474717a8d429743cf335b72ab252f5571%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

### **步骤 5**

现在，勾选 **通过代理访问网站**，启用 **使用我自己的代理，** 然后点击 **配置**.

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-b7661b7f2386ea421cd26524bf7bf5ca2c3398d6%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

### **步骤 6**

当你点击 **配置** 按钮时，会弹出一个窗口。请在 `IP/host:port:username:password` 格式中指定你选择的代理详细信息：

* [住宅与移动代理](#residential-and-mobile-proxies)
* [数据中心代理](#datacenter-proxies)
* [独享数据中心代理（企业版）](#dedicated-datacenter-proxies-enterprise)
* [独享数据中心代理（自助服务版）](#dedicated-datacenter-proxies-self-service)
* [ISP代理](#isp-proxies)
* [独享ISP代理](#dedicated-isp-proxies)

#### 住宅与移动代理

**IP/host:** `pr.oxylabs.io`

**端口：** `7777`

**用户名：** `customer-username`

**密码：** `password`

{% hint style="warning" %}
别忘了添加 `customer-` 该部分到您的用户名中。
{% endhint %}

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-2ab7fe33e2f6ca420ea2dbf9d90f9114c8e8262f%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
你也可以使用按国家/地区的条目，通过粘性会话获取所需国家/地区的出口节点。例如，要使用美国出口节点，请 `us-pr.oxylabs.io` 在 **Host or IP Address** 和 `10001` 在 **端口**旁边输入。你可以在我们的 [文档](https://developers.oxylabs.io/products/cn/proxies/residential-proxies/location-settings.md).
{% endhint %}

#### 数据中心代理

**IP/host:** `dc.oxylabs.io`

**端口：** `8001`

**用户名：** `user-username`

**密码：** `password`

{% hint style="info" %}
别忘了添加 `user-` 前缀添加到用户名中。
{% endhint %}

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-d31dac5c0197bc1f018bb3b408fb8dadbe940a5a%2Foctoparse_dc_details.png?alt=media" alt=""><figcaption></figcaption></figure>

对于 **按 IP 计费** 订阅，端口是分配给给定列表中某个 IP 地址的顺序编号。因此，端口 `8001` 使用你列表中的第一个 IP 地址。

对于 **按流量计费** 订阅，端口 `8001` 会随机选择一个 IP 地址，但在会话期间保持一致。

{% hint style="info" %}
你也可以在用户认证字符串中指定地理位置，例如美国： `user-USERNAME-country-US:PASSWORD`。参阅我们的 [文档](https://developers.oxylabs.io/products/cn/proxies/datacenter-proxies.md) 了解更多详情。
{% endhint %}

#### 独享数据中心代理（企业版）

**IP/host:** 特定 IP 地址（例如， `1.2.3.4`)

**端口：** `60000`

**用户名：** `username`

**密码：** `password`

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-7af2f27bb3a28768093ff7d8d5ddf5be284c07f4%2Foctoparse_ddc-e_details.png?alt=media" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
对于 Enterprise 独享数据中心代理，你需要从 [**已获取列表**](https://developers.oxylabs.io/products/cn/proxies/dedicated-datacenter-proxies/enterprise/proxy-lists.md).
{% endhint %}

#### 独享数据中心代理（自助服务版）

**IP/host:** `ddc.oxylabs.io`

**端口：** `8001`

**用户名：** `user-username`

**密码：** `password`

{% hint style="warning" %}
别忘了添加 `user-` 该部分到您的用户名中。
{% endhint %}

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-1f5cfc55670f481ad4df2023a200e6d0492e5625%2Foctoparse_ddc-ss_details.png?alt=media" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
你需要选择一个分配给已购买的 IP 地址的端口，来自 [**代理列表**](https://developers.oxylabs.io/products/cn/proxies/dedicated-datacenter-proxies/self-service/proxy-list.md)**,** 你可以在 Oxylabs 仪表板中找到。
{% endhint %}

#### ISP代理

**IP/host:** `isp.oxylabs.io`

**端口：** `8001`

**用户名：** `user-username`

**密码：** `password`

{% hint style="warning" %}
别忘了添加 `user-` 该部分到您的用户名中。
{% endhint %}

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-7544ae0f0655359c03b83157fa2b9576cba73493%2Foctoparse_isp.png?alt=media" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
你需要选择分配给已购买的 IP 地址的端口， [**代理列表**](https://developers.oxylabs.io/products/cn/proxies/isp-proxies/proxy-list.md)**,** 你可以在 Oxylabs 仪表板中找到。该 `8001` 端口会为所有请求从你的列表中选取第一个 IP 地址。
{% endhint %}

#### 独享ISP代理

**IP/host**: `disp.oxylabs.io`

**端口**: `8001`

**用户名：** `user-USERNAME`

**密码：** `PASSWORD`

{% hint style="warning" %}
**注意：** 别忘了添加 `user-` 前缀到您的用户名中。
{% endhint %}

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-fb651f1c8ef9ff7a0789ae166e3d2272909f17a7%2Foctoparse-1.png?alt=media" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
端口号表示你已购买的代理中的哪个 IP 地址 [代理列表](https://developers.oxylabs.io/products/cn/proxies/dedicated-isp-proxies/self-service/proxy-list.md) 中的哪个 IP 地址。请使用端口 `8000` 用于自动 [代理 IP 轮换](https://developers.oxylabs.io/products/cn/proxies/dedicated-isp-proxies/self-service/proxy-rotation.md).
{% endhint %}

### **步骤 7**

设置 **切换** 间隔，具体取决于你使用的是轮换会话类型还是粘性会话类型。

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-8f3efff6cae07d1f24ce75de6d00fc6733c1de4c%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

### **步骤 8**

通过点击 **确认** 按钮保存更改，然后点击 **保存**.

你的代理现在已设置完成！

### 如何开始使用 Octoparse 进行抓取

**步骤 1。** 选择你想抓取的目标元素（电子游戏标题）。要提取同一类别中的所有元素，请选择 **选择所有相似元素** 并指定 **文本**.

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-5193c197dbf02340d0dff814dc08ed73f3cc8a3f%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-601479acff48a598fec181f8cb6d728c41e9e827%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

**步骤 2。** 设置分页以抓取多个页面。此网站使用数字分页，因此会提示你选择 **下一页按钮**.

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-d2cd7d6725e951f9831e22146eccaa3c24ce8c99%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

**步骤 3。** 选择页面布局中打开下一页的确切按钮—— **前进** ——以自动分页。

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-dcf20caeb6fad59e52187dd234f31252bae87e18%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

**步骤 4。** 完成抓取设置并按下 **▶运行**.

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-391aa7f0b6e1bd1ebac7d94c044097d61d9b30b3%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

**步骤 5。** 选择 **在你的设备上运行** 并使用 **标准模式** ，以将数据作为文件接收在你的电脑上。

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-57cf8bc0711769ed00913b4b7b8f119535be4232%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

**步骤 6。** 让抓取过程运行直至完成。当到达最终产品页面或你手动停止时，流程就会结束。

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-024a6ff9f3dee3c6127d452cb7f02a501291e34f%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

**步骤 7。** 导出已收集的数据并选择文件格式。

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-c1a80882d1038da6c432a9c08e29ace0bfd92fd4%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-3178b33144d3018fa18bdae33d961491653defd7%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

以下是电子表格中的最终结果。

<figure><img src="https://1216392379-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU4lV7kLC2Df45W0aLQlX%2Fuploads%2Fgit-blob-b815cc6e0f6eadca21ac3c0fdaf4cc1a80c8dc57%2Fimage.png?alt=media" alt=""><figcaption></figcaption></figure>

就是这样——你已经全部设置完毕，可以专注于使用 Octoparse 进行网页抓取任务了。


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://developers.oxylabs.io/integrations/cn/proxy-integrations/octoparse.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
