> For the complete documentation index, see [llms.txt](https://help.impact.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.impact.com/partner/zh/ni-xiang-liao-jie-shen-me/platform-features/tracking/website-crawling-requirements-for-partners.md).

# 合作伙伴的网站抓取要求

作为合作伙伴，您可能需要采取某些步骤，例如配置 User-Agent 标识，以确保 impact.com 的受管制合规爬虫能够在不中断且具备适当授权的情况下，以编程方式访问并从您的网站检索数据。本指南主要面向负责管理网站访问和安全设置的开发人员、IT 管理员和技术团队。

#### 如何允许 impact.com 的受管制合规机器人

作为合作伙伴，您的网站可能会受到 impact.com 的受管制合规机器人的监控，以确保特定内容与您和品牌方的协议一致。每个被监控的项目都需要单独访问您的网站，因此，被监控内容量较高的网站将相应收到更多请求。

如果 impact.com 的受管制合规机器人受到限制（例如返回 HTTP 429 – 请求过多 或 HTTP 403 – 禁止访问），我们可能无法审核和验证您的内容，这可能会影响合规可见性。

**为确保监控不间断：**

* 使用提供的 User-Agent 将 impact.com 受管制合规机器人加入允许名单。
* 避免阻止或限制来自 impact.com 受管制合规机器人的合法请求。
* 使用请求头中包含的签名验证 impact.com 受管制合规机器人，以确认真实性并防止伪造。
* 通过允许并验证 impact.com 受管制合规机器人，您有助于确保您的内容在 impact.com 系统中被准确审核并如实反映。

#### User-Agent 标识

我们的爬虫使用自定义 `User-Agent` 来在 Web 请求期间标识自身。这使您作为合作伙伴能够将 impact.com 合规流量与其他机器人和爬虫区分开来。

要加入允许名单的 User-Agent 字符串（请严格按所示使用）：

```programlisting
Mozilla/5.0 (compatible;Impact.com Agent) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36
```

**验证 impact.com 爬虫请求**

为确认传入流量来自 impact.com 爬虫，每个请求都包含一个自定义的 HMAC 签名头：

```programlisting
X-Impact-Crawler-Signature: <hmac 签名>
```

该签名允许您使用已知的密钥和共享算法对请求进行身份验证。它确保该请求源自 impact.com，且未被篡改。

<details>

<summary>签名构造</summary>

**签名构造**

我们使用以下过程计算签名：

* **密钥**: `/impact/crawler/signature/`
* **待签名数据**: `User-Agent`
* **HMAC 算法：** `HMAC-SHA256`
* **签名输出**: `十六进制字符串`

</details>

<details>

<summary>如何验证（伪代码）</summary>

```programlisting
const crypto = require('crypto');

// 从传入请求中提取头部
const userAgent = req.headers['user-agent'];
const signature = req.headers['x-impact-crawler-signature'];

const secret = '/impact/crawler/signature/';

// 重新计算签名
const expectedSignature = crypto
  .createHmac('sha256', secret)
  .update(userAgent)
  .digest('hex');

// 比较签名
if (signature === expectedSignature) {
  // ✅ 已验证
} else {
  // ❌ 拒绝或记录以供审查
}
```

{% hint style="danger" %}
**警告：** 请务必使用请求中接收到的确切 `User-Agent` 值。任何修改，例如裁剪、解码或重新格式化，都会导致签名不匹配。
{% endhint %}

</details>

#### 受管制合规监控的 IP 允许名单

为支持持续的受管制合规监控，请将以下 IP 地址范围加入允许名单。这可确保来自 impact.com 的流量不会被意外阻止，并且站点监控可以不间断地继续。

**允许以下 IP 范围：**

* 163.116.128.0/17
* 162.10.0.0/17
* 31.186.239.0/24
* 8.39.144.0/24
* 8.36.116.0/24
* 34.145.188.137
* 35.245.212.57
* 34.21.56.213
* 34.48.90.233
* 35.245.229.167
* 34.150.151.151
* 35.245.185.65
* 35.188.242.212
* 34.86.33.122
* 34.145.224.193
* 35.245.135.218
* 35.221.1.178
* 34.150.217.77
* 107.175.80.80
* 162.212.175.22
* 107.172.69.119

我们建议更新您的防火墙或访问控制列表，以允许来自以下 impact.com IP 地址范围的传入流量。

{% hint style="success" icon="memo-circle-info" %}
**推荐：** 如需与受管制合规监控和机器人访问相关的技术协调或问题， [联系支持](https://app.impact.com/secure/advertiser/support/customer-support-portal-flow.ihtml).
{% endhint %}


---

# 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, and the optional `goal` query parameter:

```
GET https://help.impact.com/partner/zh/ni-xiang-liao-jie-shen-me/platform-features/tracking/website-crawling-requirements-for-partners.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
